Package: valgrind
Version: 1:3.9.0-6
Severity: important
Tags: patch
Hello,
Whenever I run a program using mutexes with valgrind, I get
vex amd64->IR: unhandled instruction bytes: 0xC6 0xF8 0xFD 0xF 0xB7 0x6 0x66
0x85
vex amd64->IR: REX=0 REX.W=0 REX.R=0 REX.X=0 REX.B=0
vex amd64->IR: VEX=0 VEX.L=0 VEX.nVVVV=0x0 ESC=NONE
vex amd64->IR: PFX.66=0 PFX.F2=0 PFX.F3=0
==27853== valgrind: Unrecognised instruction at address 0x5adc2f0.
==27853== at 0x5ADC2F0: __lll_trylock_elision (elision-trylock.c:32)
This is the xabort instruction, recently introduced in glibc. Upstream
commited a simple support for it, attached to this mail, could you
backport it to Debian? Otherwise any owner of Haswell processor will
have the issue with multithreaded applications.
Samuel
-- System Information:
Debian Release: jessie/sid
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable'), (500, 'stable'), (500,
'oldstable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.15.0 (SMP w/8 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages valgrind depends on:
ii libc6 2.19-7
ii libc6-dbg 2.19-7
Versions of packages valgrind recommends:
ii gdb 7.6.2-1.1+b1
pn valgrind-dbg <none>
Versions of packages valgrind suggests:
pn alleyoop <none>
ii kcachegrind 4:4.13.1-1
pn valgrind-mpi <none>
ii valkyrie 2.0.0-1
-- no debconf information
--
Samuel
requests.</FONT></SPAN></TD></TR></TBODY></TABLE></DIV></BODY></HTML>agnjo
gj a po mi
shnthdrdcvallus hsx mvgduwolgfwtq
uzuy
s
p
h
-+- spams forever ... -+-
Index: valgrind/VEX/priv/guest_amd64_toIR.c
===================================================================
--- valgrind/VEX/priv/guest_amd64_toIR.c (révision 2799)
+++ valgrind/VEX/priv/guest_amd64_toIR.c (révision 2800)
@@ -20251,7 +20251,7 @@
return delta;
}
/* BEGIN HACKY SUPPORT FOR xbegin */
- if (modrm == 0xF8 && !have66orF2orF3(pfx) && sz == 4
+ if (opc == 0xC7 && modrm == 0xF8 && !have66orF2orF3(pfx) && sz == 4
&& (archinfo->hwcaps & VEX_HWCAPS_AMD64_AVX)) {
delta++; /* mod/rm byte */
d64 = getSDisp(4,delta);
@@ -20270,6 +20270,16 @@
return delta;
}
/* END HACKY SUPPORT FOR xbegin */
+ /* BEGIN HACKY SUPPORT FOR xabort */
+ if (opc == 0xC6 && modrm == 0xF8 && !have66orF2orF3(pfx) && sz == 1
+ && (archinfo->hwcaps & VEX_HWCAPS_AMD64_AVX)) {
+ delta++; /* mod/rm byte */
+ abyte = getUChar(delta); delta++;
+ /* There is never a real transaction in progress, so do nothing. */
+ DIP("xabort $%d", (Int)abyte);
+ return delta;
+ }
+ /* END HACKY SUPPORT FOR xabort */
goto decode_failure;
case 0xC8: /* ENTER */