mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-19 00:54:41 +08:00
KVM: x86 emulator: Use a register for ____emulate_2op() destination
Most x86 two operand instructions allow the destination to be a memory operand, but IMUL (for example) requires that the destination be a register. Change ____emulate_2op() to take a register for both source and destination so we can invoke IMUL. Signed-off-by: Avi Kivity <avi@redhat.com>
This commit is contained in:
parent
b3b3d25a12
commit
fb2c264105
@ -200,7 +200,7 @@ struct group_dual {
|
|||||||
_PRE_EFLAGS("0", "4", "2") \
|
_PRE_EFLAGS("0", "4", "2") \
|
||||||
_op _suffix " %"_x"3,%1; " \
|
_op _suffix " %"_x"3,%1; " \
|
||||||
_POST_EFLAGS("0", "4", "2") \
|
_POST_EFLAGS("0", "4", "2") \
|
||||||
: "=m" (_eflags), "=m" (*(_dsttype*)&(_dst).val),\
|
: "=m" (_eflags), "+q" (*(_dsttype*)&(_dst).val),\
|
||||||
"=&r" (_tmp) \
|
"=&r" (_tmp) \
|
||||||
: _y ((_src).val), "i" (EFLAGS_MASK)); \
|
: _y ((_src).val), "i" (EFLAGS_MASK)); \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
Loading…
Reference in New Issue
Block a user