mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-21 18:29:46 +00:00
Exapnd br_jt into indirect branch. Provide pattern for indirect branches.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75983 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
57b04e6fa7
commit
983d3a1ee5
@ -62,6 +62,7 @@ SystemZTargetLowering::SystemZTargetLowering(SystemZTargetMachine &tm) :
|
||||
|
||||
setOperationAction(ISD::RET, MVT::Other, Custom);
|
||||
|
||||
setOperationAction(ISD::BR_JT, MVT::Other, Expand);
|
||||
setOperationAction(ISD::BRCOND, MVT::Other, Expand);
|
||||
setOperationAction(ISD::BR_CC, MVT::i32, Custom);
|
||||
setOperationAction(ISD::BR_CC, MVT::i64, Custom);
|
||||
|
@ -99,6 +99,12 @@ let isBranch = 1, isTerminator = 1 in {
|
||||
let isBarrier = 1 in
|
||||
def JMP : Pseudo<(outs), (ins brtarget:$dst), "j\t{$dst}", [(br bb:$dst)]>;
|
||||
|
||||
let isBarrier = 1, isIndirectBranch = 1 in {
|
||||
def JMPr : Pseudo<(outs), (ins GR64:$dst), "br\t{$dst}", [(brind GR64:$dst)]>;
|
||||
// FIXME: displacement here is 12 bits
|
||||
def JMPrri : Pseudo<(outs), (ins rriaddr:$dst), "b\t{$dst}", [(brind rriaddr:$dst)]>;
|
||||
}
|
||||
|
||||
let Uses = [PSW] in {
|
||||
def JE : Pseudo<(outs), (ins brtarget:$dst),
|
||||
"je\t$dst",
|
||||
|
Loading…
Reference in New Issue
Block a user