diff options
author | Richard Osborne <richard@xmos.com> | 2013-07-03 07:48:50 +0000 |
---|---|---|
committer | Richard Osborne <richard@xmos.com> | 2013-07-03 07:48:50 +0000 |
commit | 79186beb28b94c587714cc4b854389348a869b82 (patch) | |
tree | 42803e4c9b7d31314ee2466a884e319d56a59390 /lib/Target/XCore | |
parent | 32bdf82b9fbe88687be160863a6d221fe692c58b (diff) | |
download | external_llvm-79186beb28b94c587714cc4b854389348a869b82.zip external_llvm-79186beb28b94c587714cc4b854389348a869b82.tar.gz external_llvm-79186beb28b94c587714cc4b854389348a869b82.tar.bz2 |
[XCore] Add ISel pattern for LDWCP
Patch by Robert Lytton.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185518 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/XCore')
-rw-r--r-- | lib/Target/XCore/XCoreInstrInfo.td | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/lib/Target/XCore/XCoreInstrInfo.td b/lib/Target/XCore/XCoreInstrInfo.td index be152ae..529fa13 100644 --- a/lib/Target/XCore/XCoreInstrInfo.td +++ b/lib/Target/XCore/XCoreInstrInfo.td @@ -279,12 +279,6 @@ multiclass FRU6_LRU6_backwards_branch<bits<6> opc, string OpcStr> { !strconcat(OpcStr, " $a, $b"), []>; } -multiclass FRU6_LRU6_cp<bits<6> opc, string OpcStr> { - def _ru6: _FRU6<opc, (outs RRegs:$a), (ins i32imm:$b), - !strconcat(OpcStr, " $a, cp[$b]"), []>; - def _lru6: _FLRU6<opc, (outs RRegs:$a), (ins i32imm:$b), - !strconcat(OpcStr, " $a, cp[$b]"), []>; -} // U6 multiclass FU6_LU6<bits<10> opc, string OpcStr, SDNode OpNode> { @@ -539,8 +533,13 @@ def STWDP_lru6 : _FLRU6<0b010100, (outs), (ins RRegs:$a, i32imm:$b), [(store RRegs:$a, (dprelwrapper tglobaladdr:$b))]>; //let Uses = [CP] in .. -let mayLoad = 1, isReMaterializable = 1, neverHasSideEffects = 1 in -defm LDWCP : FRU6_LRU6_cp<0b011011, "ldw">; +let mayLoad = 1, isReMaterializable = 1, neverHasSideEffects = 1 in { +def LDWCP_ru6 : _FRU6<0b011011, (outs RRegs:$a), (ins i32imm:$b), + "ldw $a, cp[$b]", []>; +def LDWCP_lru6: _FLRU6<0b011011, (outs RRegs:$a), (ins i32imm:$b), + "ldw $a, cp[$b]", + [(set RRegs:$a, (load (cprelwrapper tglobaladdr:$b)))]>; +} let Uses = [SP] in { let mayStore=1 in { |