mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-24 13:18:17 +00:00
Fix llvm-mc handing of x86 instructions that take 8-bit unsigned immediates.
llvm-mc gives an "invalid operand" error for instructions that take an unsigned
immediate which have the high bit set such as:
pblendw $0xc5, %xmm2, %xmm1
llvm-mc treats all x86 immediates as signed values and range checks them.
A small number of x86 instructions use the imm8 field as a set of bits.
This change only changes those instructions and where the high bit is not
ignored. The others remain unchanged.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136287 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -279,6 +279,7 @@ static int X86TypeFromOpName(LiteralConstantEmitter *type,
|
||||
IMM("i16i8imm");
|
||||
IMM("i32imm");
|
||||
IMM("i32i8imm");
|
||||
IMM("u32u8imm");
|
||||
IMM("i64imm");
|
||||
IMM("i64i8imm");
|
||||
IMM("i64i32imm");
|
||||
|
||||
Reference in New Issue
Block a user