From: Carl Love Date: Fri, 21 Feb 2020 23:22:26 +0000 (-0600) Subject: PPC64, fix for alignment of the rt_sigframe data structure. X-Git-Tag: VALGRIND_3_16_0~96 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6f8920fd8f9381cf75f5dd0c3c65ac5d86c0a537;p=thirdparty%2Fvalgrind.git PPC64, fix for alignment of the rt_sigframe data structure. The PPC64 implementation checks that the data structure is aligned. The changes in commit listed below breaks the alignment. This patch adds an explicit alignment directive to ensure the data structure is allocated with the required alignment. This fixes 31 stderr failures, 10 stdout failures on the Power 7, Power 8 and Power 9 platforms. commit 3bac39a10abf292d332bb20ab58c6dd5c28f9108 Author: Eugene Syromyatnikov Date: Fri Mar 8 04:07:00 2019 +0100 include/vki: fix vki_siginfo_t definition on amd64, arm64, and ppc64 As it turned out, the size of vki_siginfo_t is incorrect on these 64-bit architectures: (gdb) p sizeof(vki_siginfo_t) $1 = 136 (gdb) ptype struct vki_siginfo type = struct vki_siginfo { int si_signo; int si_errno; int si_code; union { int _pad[29]; struct {...} _kill; struct {...} _timer; struct {...} _rt; struct {...} _sigchld; struct {...} _sigfault; struct {...} _sigpoll; } _sifields; } etc. --- diff --git a/NEWS b/NEWS index 5dbb014c40..84e08409db 100644 --- a/NEWS +++ b/NEWS @@ -123,6 +123,8 @@ n-i-bz Add support for the Linux io_uring system calls n-i-bz sys_statx: don't complain if both |filename| and |buf| are NULL. n-i-bz Fix non-glibc build of test suite with s390x_features 416667 gcc10 ppc64le impossible constraint in 'asm' in test_isa. +417427 commit to fix vki_siginfo_t definition created numerous regression + errors on ppc64 417452 s390_insn_store_emit: dst->tag for HRcVec128 417906 clone with CLONE_VFORK and no CLONE_VM fails diff --git a/coregrind/m_sigframe/sigframe-ppc64-linux.c b/coregrind/m_sigframe/sigframe-ppc64-linux.c index 0406f3c450..b54c4e0be0 100644 --- a/coregrind/m_sigframe/sigframe-ppc64-linux.c +++ b/coregrind/m_sigframe/sigframe-ppc64-linux.c @@ -112,7 +112,7 @@ struct rt_sigframe { vki_siginfo_t info; struct vg_sig_private priv; UChar abigap[288]; // unused -}; +} __attribute__ ((aligned (16))); #define SET_SIGNAL_LR(zztst, zzval) \ do { tst->arch.vex.guest_LR = (zzval); \