mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-20 03:23:01 +02:00
Move the AddLiveIn function definition closer to its uses.
llvm-svn: 69382
This commit is contained in:
parent
b2ccd16655
commit
312344e025
@ -478,17 +478,6 @@ static bool RetCC_ARM_AAPCS_Custom_f64(unsigned &ValNo, MVT &ValVT, MVT &LocVT,
|
||||
State);
|
||||
}
|
||||
|
||||
/// AddLiveIn - This helper function adds the specified physical register to the
|
||||
/// MachineFunction as a live in value. It also creates a corresponding virtual
|
||||
/// register for it.
|
||||
static unsigned AddLiveIn(MachineFunction &MF, unsigned PReg,
|
||||
const TargetRegisterClass *RC) {
|
||||
assert(RC->contains(PReg) && "Not the correct regclass!");
|
||||
unsigned VReg = MF.getRegInfo().createVirtualRegister(RC);
|
||||
MF.getRegInfo().addLiveIn(PReg, VReg);
|
||||
return VReg;
|
||||
}
|
||||
|
||||
/// LowerCallResult - Lower the result values of an ISD::CALL into the
|
||||
/// appropriate copies out of appropriate physical registers. This assumes that
|
||||
/// Chain/InFlag are the input chain/flag to use, and that TheCall is the call
|
||||
@ -1064,6 +1053,17 @@ static SDValue LowerVASTART(SDValue Op, SelectionDAG &DAG,
|
||||
return DAG.getStore(Op.getOperand(0), dl, FR, Op.getOperand(1), SV, 0);
|
||||
}
|
||||
|
||||
/// AddLiveIn - This helper function adds the specified physical register to the
|
||||
/// MachineFunction as a live-in value. It also creates a corresponding virtual
|
||||
/// register for it.
|
||||
static unsigned AddLiveIn(MachineFunction &MF, unsigned PReg,
|
||||
const TargetRegisterClass *RC) {
|
||||
assert(RC->contains(PReg) && "Not the correct regclass!");
|
||||
unsigned VReg = MF.getRegInfo().createVirtualRegister(RC);
|
||||
MF.getRegInfo().addLiveIn(PReg, VReg);
|
||||
return VReg;
|
||||
}
|
||||
|
||||
SDValue
|
||||
ARMTargetLowering::LowerFORMAL_ARGUMENTS(SDValue Op, SelectionDAG &DAG) {
|
||||
MachineFunction &MF = DAG.getMachineFunction();
|
||||
|
Loading…
Reference in New Issue
Block a user