mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-14 16:33:28 +00:00
Fix single word and unsigned byte data transfer instruction encodings so that
Inst{4} = 0. rdar://problem/9213022 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@128662 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
a6f7499244
commit
a52d7da1d8
@ -991,6 +991,7 @@ multiclass AI_ldr1<bit isByte, string opc, InstrItinClass iii,
|
|||||||
[(set GPR:$Rt, (opnode ldst_so_reg:$shift))]> {
|
[(set GPR:$Rt, (opnode ldst_so_reg:$shift))]> {
|
||||||
bits<4> Rt;
|
bits<4> Rt;
|
||||||
bits<17> shift;
|
bits<17> shift;
|
||||||
|
let shift{4} = 0; // Inst{4} = 0
|
||||||
let Inst{23} = shift{12}; // U (add = ('U' == 1))
|
let Inst{23} = shift{12}; // U (add = ('U' == 1))
|
||||||
let Inst{19-16} = shift{16-13}; // Rn
|
let Inst{19-16} = shift{16-13}; // Rn
|
||||||
let Inst{15-12} = Rt;
|
let Inst{15-12} = Rt;
|
||||||
@ -1020,6 +1021,7 @@ multiclass AI_str1<bit isByte, string opc, InstrItinClass iii,
|
|||||||
[(opnode GPR:$Rt, ldst_so_reg:$shift)]> {
|
[(opnode GPR:$Rt, ldst_so_reg:$shift)]> {
|
||||||
bits<4> Rt;
|
bits<4> Rt;
|
||||||
bits<17> shift;
|
bits<17> shift;
|
||||||
|
let shift{4} = 0; // Inst{4} = 0
|
||||||
let Inst{23} = shift{12}; // U (add = ('U' == 1))
|
let Inst{23} = shift{12}; // U (add = ('U' == 1))
|
||||||
let Inst{19-16} = shift{16-13}; // Rn
|
let Inst{19-16} = shift{16-13}; // Rn
|
||||||
let Inst{15-12} = Rt;
|
let Inst{15-12} = Rt;
|
||||||
|
4
test/MC/Disassembler/ARM/invalid-LDRrs-arm.txt
Normal file
4
test/MC/Disassembler/ARM/invalid-LDRrs-arm.txt
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
# RUN: llvm-mc --disassemble %s -triple=arm-apple-darwin9 |& grep {invalid instruction encoding}
|
||||||
|
|
||||||
|
# LDR (register) has encoding Inst{4} = 0.
|
||||||
|
0xba 0xae 0x9f 0x57
|
Loading…
x
Reference in New Issue
Block a user