mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-16 14:31:59 +00:00
Make sure MTSPR instruction is inserted into the BasicBlock
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14822 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
33af23d902
commit
5f8cce1348
@ -1437,7 +1437,7 @@ void ISel::visitCallInst(CallInst &CI) {
|
||||
TheCall = BuildMI(PPC32::CALLpcrel, 1).addGlobalAddress(F, true);
|
||||
} else { // Emit an indirect call through the CTR
|
||||
unsigned Reg = getReg(CI.getCalledValue());
|
||||
BuildMI(PPC32::MTSPR, 2).addZImm(9).addReg(Reg);
|
||||
BuildMI(BB, PPC32::MTSPR, 2).addZImm(9).addReg(Reg);
|
||||
TheCall = BuildMI(PPC32::CALLindirect, 1).addZImm(20).addZImm(0);
|
||||
}
|
||||
|
||||
|
@ -1437,7 +1437,7 @@ void ISel::visitCallInst(CallInst &CI) {
|
||||
TheCall = BuildMI(PPC32::CALLpcrel, 1).addGlobalAddress(F, true);
|
||||
} else { // Emit an indirect call through the CTR
|
||||
unsigned Reg = getReg(CI.getCalledValue());
|
||||
BuildMI(PPC32::MTSPR, 2).addZImm(9).addReg(Reg);
|
||||
BuildMI(BB, PPC32::MTSPR, 2).addZImm(9).addReg(Reg);
|
||||
TheCall = BuildMI(PPC32::CALLindirect, 1).addZImm(20).addZImm(0);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user