mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-26 21:32:10 +00:00
X86Disassembler - fixed a bug in immediate print
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@206953 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
8c5b3146ed
commit
3890a42255
@ -319,7 +319,7 @@ static void translateImmediate(MCInst &mcInst, uint64_t immediate,
|
||||
}
|
||||
// By default sign-extend all X86 immediates based on their encoding.
|
||||
else if (type == TYPE_IMM8 || type == TYPE_IMM16 || type == TYPE_IMM32 ||
|
||||
type == TYPE_IMM64) {
|
||||
type == TYPE_IMM64 || type == TYPE_IMMv) {
|
||||
uint32_t Opcode = mcInst.getOpcode();
|
||||
switch (operand.encoding) {
|
||||
default:
|
||||
|
@ -44,6 +44,10 @@
|
||||
# CHECK-NEXT: nop
|
||||
0xf0 0x90
|
||||
|
||||
# Test that immediate is printed correctly within opsize prefix
|
||||
# CHECK: addw $-12, %ax
|
||||
0x66,0x83,0xc0,0xf4
|
||||
|
||||
# Test that multiple redundant prefixes work (redundant, but valid x86).
|
||||
# CHECK: rep
|
||||
# CHECK-NEXT: rep
|
||||
|
Loading…
Reference in New Issue
Block a user