mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-09-01 04:29:57 +00:00
Add some missing patterns now that tLDRB and tLDRH are split into reg and
immediate versions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121819 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
86e8a700f5
commit
415af3452e
@ -1433,17 +1433,27 @@ def : T1Pat<(extloadi16 t_addrmode_is2:$addr), (tLDRHi t_addrmode_is2:$addr)>;
|
||||
|
||||
// If it's impossible to use [r,r] address mode for sextload, select to
|
||||
// ldr{b|h} + sxt{b|h} instead.
|
||||
def : T1Pat<(sextloadi8 t_addrmode_is1:$addr),
|
||||
(tSXTB (tLDRBi t_addrmode_is1:$addr))>,
|
||||
Requires<[IsThumb, IsThumb1Only, HasV6]>;
|
||||
def : T1Pat<(sextloadi8 t_addrmode_rrs1:$addr),
|
||||
(tSXTB (tLDRBr t_addrmode_rrs1:$addr))>,
|
||||
Requires<[IsThumb, IsThumb1Only, HasV6]>;
|
||||
def : T1Pat<(sextloadi16 t_addrmode_is2:$addr),
|
||||
(tSXTH (tLDRHi t_addrmode_is2:$addr))>,
|
||||
Requires<[IsThumb, IsThumb1Only, HasV6]>;
|
||||
def : T1Pat<(sextloadi16 t_addrmode_rrs2:$addr),
|
||||
(tSXTH (tLDRHr t_addrmode_rrs2:$addr))>,
|
||||
Requires<[IsThumb, IsThumb1Only, HasV6]>;
|
||||
|
||||
def : T1Pat<(sextloadi8 t_addrmode_rrs1:$addr),
|
||||
(tASRri (tLSLri (tLDRBr t_addrmode_rrs1:$addr), 24), 24)>;
|
||||
def : T1Pat<(sextloadi16 t_addrmode_rrs1:$addr),
|
||||
(tASRri (tLSLri (tLDRHr t_addrmode_rrs1:$addr), 16), 16)>;
|
||||
def : T1Pat<(sextloadi8 t_addrmode_is1:$addr),
|
||||
(tASRri (tLSLri (tLDRBi t_addrmode_is1:$addr), 24), 24)>;
|
||||
def : T1Pat<(sextloadi16 t_addrmode_rrs2:$addr),
|
||||
(tASRri (tLSLri (tLDRHr t_addrmode_rrs2:$addr), 16), 16)>;
|
||||
def : T1Pat<(sextloadi16 t_addrmode_is2:$addr),
|
||||
(tASRri (tLSLri (tLDRHi t_addrmode_is2:$addr), 16), 16)>;
|
||||
|
||||
// Large immediate handling.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user