mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-15 07:34:33 +00:00
Eliminate an extra copy from R1 that Nate noticed on function calls that
have to write arguments to the stack git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22536 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
4015ea8711
commit
988b1dd608
@ -1293,7 +1293,8 @@ unsigned ISel::SelectExpr(SDOperand N, bool Recording) {
|
||||
MVT::ValueType DestType = N.getValueType();
|
||||
|
||||
if (Node->getOpcode() == ISD::CopyFromReg &&
|
||||
MRegisterInfo::isVirtualRegister(cast<RegSDNode>(Node)->getReg()))
|
||||
(MRegisterInfo::isVirtualRegister(cast<RegSDNode>(Node)->getReg()) ||
|
||||
cast<RegSDNode>(Node)->getReg() == PPC::R1))
|
||||
// Just use the specified register as our input.
|
||||
return cast<RegSDNode>(Node)->getReg();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user