mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-10 02:36:06 +00:00
Use the subtarget on the dag to get TargetFrameLowering rather
than off the target machine. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@219378 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
31c9cd065a
commit
05597e9fa3
@ -1627,7 +1627,7 @@ void SelectionDAGLegalize::ExpandDYNAMIC_STACKALLOC(SDNode* Node,
|
|||||||
Chain = SP.getValue(1);
|
Chain = SP.getValue(1);
|
||||||
unsigned Align = cast<ConstantSDNode>(Tmp3)->getZExtValue();
|
unsigned Align = cast<ConstantSDNode>(Tmp3)->getZExtValue();
|
||||||
unsigned StackAlign =
|
unsigned StackAlign =
|
||||||
TM.getSubtargetImpl()->getFrameLowering()->getStackAlignment();
|
DAG.getSubtarget().getFrameLowering()->getStackAlignment();
|
||||||
Tmp1 = DAG.getNode(ISD::SUB, dl, VT, SP, Size); // Value
|
Tmp1 = DAG.getNode(ISD::SUB, dl, VT, SP, Size); // Value
|
||||||
if (Align > StackAlign)
|
if (Align > StackAlign)
|
||||||
Tmp1 = DAG.getNode(ISD::AND, dl, VT, Tmp1,
|
Tmp1 = DAG.getNode(ISD::AND, dl, VT, Tmp1,
|
||||||
|
@ -3441,7 +3441,7 @@ void SelectionDAGBuilder::visitAlloca(const AllocaInst &I) {
|
|||||||
// the stack alignment, ignore it. If the size is greater than or equal to
|
// the stack alignment, ignore it. If the size is greater than or equal to
|
||||||
// the stack alignment, we note this in the DYNAMIC_STACKALLOC node.
|
// the stack alignment, we note this in the DYNAMIC_STACKALLOC node.
|
||||||
unsigned StackAlign =
|
unsigned StackAlign =
|
||||||
TM.getSubtargetImpl()->getFrameLowering()->getStackAlignment();
|
DAG.getSubtarget().getFrameLowering()->getStackAlignment();
|
||||||
if (Align <= StackAlign)
|
if (Align <= StackAlign)
|
||||||
Align = 0;
|
Align = 0;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user