summaryrefslogtreecommitdiffstats
path: root/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2010-06-26 18:22:20 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2010-06-26 18:22:20 +0000
commit72d13ff755fe8484c89468252f945ba23fe98f71 (patch)
tree053e915fdae2948c982c6009a8bf4fd0413dd164 /lib/CodeGen/SelectionDAG/SelectionDAG.cpp
parentde4fe231392165c7566081fb3f86aee4f6a4e0d6 (diff)
downloadexternal_llvm-72d13ff755fe8484c89468252f945ba23fe98f71.zip
external_llvm-72d13ff755fe8484c89468252f945ba23fe98f71.tar.gz
external_llvm-72d13ff755fe8484c89468252f945ba23fe98f71.tar.bz2
When splitting a VAARG, remember its alignment.
This produces terrible but correct code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106952 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r--lib/CodeGen/SelectionDAG/SelectionDAG.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
index 5c35df7..0a504db 100644
--- a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+++ b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
@@ -4141,9 +4141,10 @@ SelectionDAG::getIndexedStore(SDValue OrigStore, DebugLoc dl, SDValue Base,
SDValue SelectionDAG::getVAArg(EVT VT, DebugLoc dl,
SDValue Chain, SDValue Ptr,
- SDValue SV) {
- SDValue Ops[] = { Chain, Ptr, SV };
- return getNode(ISD::VAARG, dl, getVTList(VT, MVT::Other), Ops, 3);
+ SDValue SV,
+ unsigned Align) {
+ SDValue Ops[] = { Chain, Ptr, SV, getTargetConstant(Align, MVT::i32) };
+ return getNode(ISD::VAARG, dl, getVTList(VT, MVT::Other), Ops, 4);
}
SDValue SelectionDAG::getNode(unsigned Opcode, DebugLoc DL, EVT VT,