unicorn/qemu/target/i386
David Greenaway 0c1c359b5c target/i386: Fix decoding of certain BMI instructions
This patch fixes a translation bug for a subset of x86 BMI instructions
such as the following:

c4 e2 f9 f7 c0 shlxq %rax, %rax, %rax

Currently, these incorrectly generate an undefined instruction exception
when SSE is disabled via CR4, while instructions like "shrxq" work fine.

The problem appears to be related to BMI instructions encoded using VEX
and with a mandatory prefix of "0x66" (data). Instructions with this
data prefix (such as shlxq) are currently rejected. Instructions with
other mandatory prefixes (such as shrxq) translate as expected.

This patch removes the incorrect check in "gen_sse" that causes the
exception to be generated. For the non-BMI cases, the check is
redundant: prefixes are already checked at line 3696.

Buglink: https://bugs.launchpad.net/qemu/+bug/1748296

Backports 51909241d26fe6fe18a08def93ccc8273f61a8b3
2021-03-04 18:08:47 -05:00
..
arch_memory_mapping.c target/i386: enable A20 automatically in system management mode 2018-03-03 14:33:09 -05:00
bpt_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
cc_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
cc_helper_template.h x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
cpu-param.h tcg: Split out target/arch/cpu-param.h 2019-06-10 19:35:46 -04:00
cpu-qom.h i386: Register versioned CPU models 2019-08-08 19:01:35 -04:00
cpu.c target/i386: do not set LM for 32-bit emulation '-cpu host/max' 2021-03-04 18:07:38 -05:00
cpu.h x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
excp_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
fpu_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
helper.h target/i386: fix IEEE SSE floating-point exception raising 2021-02-25 23:21:32 -05:00
int_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
Makefile.objs target/i386: add the CONFIG_TCG into Makefiles 2018-03-03 21:57:22 -05:00
mem_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
misc_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
mpx_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
ops_sse.h x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
ops_sse_header.h x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
seg_helper.c target/i386: Check privilege level for protected mode 'int N' task gate 2021-03-03 19:32:10 -05:00
shift_helper_template.h x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
smm_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
svm.h target-i386: Add NPT support 2018-07-03 19:52:56 -04:00
svm_helper.c x86 tcg cpus: Fix Lesser GPL version number 2021-03-02 13:33:10 -05:00
topology.h i386: Update new x86_apicid parsing rules with die_offset support 2019-08-08 18:22:03 -04:00
translate.c target/i386: Fix decoding of certain BMI instructions 2021-03-04 18:08:47 -05:00
unicorn.c check arguments, return error instead of raising exceptions. (#1125) 2020-01-14 09:00:11 -05:00
unicorn.h Move target-* CPU file into a target/ folder 2018-03-01 22:50:58 -05:00