x86emul: support BMI2 insns
authorJan Beulich <jbeulich@suse.com>
Thu, 19 Jan 2017 09:28:28 +0000 (10:28 +0100)
committerJan Beulich <jbeulich@suse.com>
Thu, 19 Jan 2017 09:28:28 +0000 (10:28 +0100)
commit8e20924de13db59413ab56c4850a2153dc587be1
tree7fe1148a0c0bc0c1c43d0cd679da9309e70d04b8
parent771daacd197a0f636fb246b68eb7c2ba3954fe2d
x86emul: support BMI2 insns

Note that the adjustment to the mode_64bit() definition is so that we
can avoid "#ifdef __x86_64__" around the 64-bit asm() portions. An
alternative would be single asm()s with a conditional branch over the
(manually encoded) REX64 prefix.

Note that RORX raising #UD when VEX.VVVV is not all ones is matching
observed behavior rather than what the SDM says.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
tools/tests/x86_emulator/test_x86_emulator.c
tools/tests/x86_emulator/x86_emulate.h
xen/arch/x86/x86_emulate/x86_emulate.c
xen/include/asm-x86/cpufeature.h