From: Paul Floyd Date: Sat, 22 Mar 2025 07:15:35 +0000 (+0100) Subject: Bug 501850 - FreeBSD syscall arguments 7 and 8 incorrect. X-Git-Tag: VALGRIND_3_25_0~93 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5334917c8e0e44e6a98657050a66bc28fa638165;p=thirdparty%2Fvalgrind.git Bug 501850 - FreeBSD syscall arguments 7 and 8 incorrect. --- diff --git a/NEWS b/NEWS index 7c0bba577..741ea7319 100644 --- a/NEWS +++ b/NEWS @@ -59,12 +59,13 @@ are not entered into bugzilla tend to get forgotten about or ignored. 499183 FreeBSD: differences in avx-vmovq output 499212 mmap() with MAP_ALIGNED() returns unaligned pointer 501119 memcheck/tests/pointer-trace fails when run on NFS filesystem -501194 Fix ML_(check_macho_and_get_rw_loads) so that it is correct for any number of segment commands +501194 Fix ML_(check_macho_and_get_rw_loads) so that it is correct for + any number of segment commands 501348 glibc built with -march=x86-64-v3 does not work due to ld.so memcmp 501479 Illumos DRD pthread_mutex_init wrapper errors 501365 syscall userfaultfd not wrapped 501846 Add x86 Linux shm wrappers - +501850 FreeBSD syscall arguments 7 and 8 incorrect. To see details of a given bug, visit https://bugs.kde.org/show_bug.cgi?id=XXXXXX diff --git a/coregrind/m_syscall.c b/coregrind/m_syscall.c index 8ff9c90bd..54c7bd895 100644 --- a/coregrind/m_syscall.c +++ b/coregrind/m_syscall.c @@ -783,9 +783,9 @@ asm( " movq %r8, %r10\n" /* a4 */ " movq %r9, %r8\n" /* a5 */ " movq 16(%rbp), %r9\n" /* a6 last arg from stack, account for %rbp */ -" movq 24(%rbp), %r11\n" /* a7 from stack */ +" movq 32(%rbp), %r11\n" /* a7 from stack */ " pushq %r11\n" -" movq 32(%rbp), %r11\n" /* a8 from stack */ +" movq 24(%rbp), %r11\n" /* a8 from stack */ " pushq %r11\n" " subq $8,%rsp\n" /* fake return addr */ " syscall\n"