diff options
author | Christian Konig <christian.koenig@amd.com> | 2013-05-17 09:46:48 +0000 |
---|---|---|
committer | Christian Konig <christian.koenig@amd.com> | 2013-05-17 09:46:48 +0000 |
commit | b7be72df5bb3d06be9d5315f74d5c83909f6c5ae (patch) | |
tree | d6bef5c37b563beba73a768e950db16181509ab2 | |
parent | 35de14540f1c7d4743483f90aab791cbe515b4bb (diff) | |
download | bcm5719-llvm-b7be72df5bb3d06be9d5315f74d5c83909f6c5ae.tar.gz bcm5719-llvm-b7be72df5bb3d06be9d5315f74d5c83909f6c5ae.zip |
R600/SI: return undef instead of null for skipped arguments
This is a candidate for the stable branch.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=64694
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
Tested-by: Michel Dänzer <michel.daenzer@amd.com>
llvm-svn: 182084
-rw-r--r-- | llvm/lib/Target/R600/SIISelLowering.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/R600/SIISelLowering.cpp b/llvm/lib/Target/R600/SIISelLowering.cpp index 6bd82a5d774..98ef80f2a43 100644 --- a/llvm/lib/Target/R600/SIISelLowering.cpp +++ b/llvm/lib/Target/R600/SIISelLowering.cpp @@ -156,8 +156,9 @@ SDValue SITargetLowering::LowerFormalArguments( for (unsigned i = 0, e = Ins.size(), ArgIdx = 0; i != e; ++i) { + const ISD::InputArg &Arg = Ins[i]; if (Skipped & (1 << i)) { - InVals.push_back(SDValue()); + InVals.push_back(DAG.getUNDEF(Arg.VT)); continue; } @@ -181,7 +182,6 @@ SDValue SITargetLowering::LowerFormalArguments( Reg = MF.addLiveIn(Reg, RC); SDValue Val = DAG.getCopyFromReg(Chain, DL, Reg, VT); - const ISD::InputArg &Arg = Ins[i]; if (Arg.VT.isVector()) { // Build a vector from the registers |