mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-26 12:20:42 +00:00
Add an MF argument to TRI::getPointerRegClass() and TII::getRegClass().
The getPointerRegClass() hook can return register classes that depend on the calling convention of the current function (ptr_rc_tailcall). So far, we have been able to infer the calling convention from the subtarget alone, but as we add support for multiple calling conventions per target, that no longer works. Patch by Yiannis Tsiouris! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156328 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -208,7 +208,7 @@ void CriticalAntiDepBreaker::PrescanInstruction(MachineInstr *MI) {
|
||||
const TargetRegisterClass *NewRC = 0;
|
||||
|
||||
if (i < MI->getDesc().getNumOperands())
|
||||
NewRC = TII->getRegClass(MI->getDesc(), i, TRI);
|
||||
NewRC = TII->getRegClass(MI->getDesc(), i, TRI, MF);
|
||||
|
||||
// For now, only allow the register to be changed if its register
|
||||
// class is consistent across all uses.
|
||||
@@ -308,7 +308,7 @@ void CriticalAntiDepBreaker::ScanInstruction(MachineInstr *MI,
|
||||
|
||||
const TargetRegisterClass *NewRC = 0;
|
||||
if (i < MI->getDesc().getNumOperands())
|
||||
NewRC = TII->getRegClass(MI->getDesc(), i, TRI);
|
||||
NewRC = TII->getRegClass(MI->getDesc(), i, TRI, MF);
|
||||
|
||||
// For now, only allow the register to be changed if its register
|
||||
// class is consistent across all uses.
|
||||
|
||||
Reference in New Issue
Block a user