forked from OSchip/llvm-project
Thumb assembly parsing and encoding for ADR.
llvm-svn: 137864
This commit is contained in:
parent
a9ee09f4be
commit
e2a0404a69
|
@ -1189,7 +1189,7 @@ let usesCustomInserter = 1 in // Expanded after instruction selection.
|
|||
// assembler.
|
||||
|
||||
def tADR : T1I<(outs tGPR:$Rd), (ins t_adrlabel:$addr, pred:$p),
|
||||
IIC_iALUi, "adr{$p}\t$Rd, #$addr", []>,
|
||||
IIC_iALUi, "adr{$p}\t$Rd, $addr", []>,
|
||||
T1Encoding<{1,0,1,0,0,?}> {
|
||||
bits<3> Rd;
|
||||
bits<8> addr;
|
||||
|
|
|
@ -81,7 +81,7 @@ define double @f7(double %a, double %b) {
|
|||
; CHECK-NEON-NEXT: cmp r0, [[REGISTER_1]]
|
||||
; CHECK-NEON-NEXT: it eq
|
||||
; CHECK-NEON-NEXT: moveq [[REGISTER_2]], #4
|
||||
; CHECK-NEON-NEXT: adr [[REGISTER_3:r[0-9]+]], #LCPI
|
||||
; CHECK-NEON-NEXT: adr [[REGISTER_3:r[0-9]+]], LCPI
|
||||
; CHECK-NEON-NEXT: ldr
|
||||
; CHECK-NEON: bx
|
||||
|
||||
|
|
|
@ -47,3 +47,12 @@ _func:
|
|||
@------------------------------------------------------------------------------
|
||||
@ FIXME: ADD (SP plus register)
|
||||
@------------------------------------------------------------------------------
|
||||
|
||||
|
||||
@------------------------------------------------------------------------------
|
||||
@ ADR
|
||||
@------------------------------------------------------------------------------
|
||||
adr r2, _baz
|
||||
|
||||
@ CHECK: adr r2, _baz @ encoding: [A,0xa2]
|
||||
@ fixup A - offset: 0, value: _baz, kind: fixup_thumb_adr_pcrel_10
|
||||
|
|
Loading…
Reference in New Issue