Bug 400279

Summary: vex amd64->IR: unhandled instruction bytes: 0xF 0xC7 0xF0 0xBA 0x1 0x0 0x0 0x0 0x89 0x3
Product: [Developer tools] valgrind Reporter: Sebastian Groth <sebastian.groth>
Component: generalAssignee: Julian Seward <jseward>
Status: RESOLVED DUPLICATE    
Severity: normal CC: mark
Priority: NOR    
Version: 3.14 SVN   
Target Milestone: ---   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed In:

Description Sebastian Groth 2018-10-25 08:26:34 UTC
vex amd64->IR: unhandled instruction bytes: 0xF 0xC7 0xF0 0xBA 0x1 0x0 0x0 0x0 0x89 0x3
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=0F
vex amd64->IR:   PFX.66=0 PFX.F2=0 PFX.F3=0
==4764== valgrind: Unrecognised instruction at address 0xbc09743.
==4764==    at 0xBC09743: QRandomGenerator::SystemGenerator::generate(unsigned int*, unsigned int*) (in /usr/lib64/libQt5Core.so.5.11.1)

QtCore has been build with: x86_64-pc-linux-gnu-g++ -march=skylake -O2 (gcc version: Gentoo 7.3.0-r3 p1.4)
Comment 1 Mark Wielaard 2018-10-25 17:34:33 UTC
(In reply to Sebastian Groth from comment #0)
> vex amd64->IR: unhandled instruction bytes: 0xF 0xC7 0xF0 0xBA 0x1 0x0 0x0
> 0x0 0x89 0x3
> 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=0F
> vex amd64->IR:   PFX.66=0 PFX.F2=0 PFX.F3=0
> ==4764== valgrind: Unrecognised instruction at address 0xbc09743.
> ==4764==    at 0xBC09743:
> QRandomGenerator::SystemGenerator::generate(unsigned int*, unsigned int*)
> (in /usr/lib64/libQt5Core.so.5.11.1)

That is the RDRAND instruction.

> QtCore has been build with: x86_64-pc-linux-gnu-g++ -march=skylake -O2

Don't use -march=skylake, the program needs to check whether or not the processor (that valgrind emulates) support rdrand (valgrind doesn't).

*** This bug has been marked as a duplicate of bug 353370 ***