Fix miscompilation of float vector returns. Compile code to this:

_func:
        vsldoi v2, v3, v2, 12
        vsldoi v2, v2, v2, 4
        blr

instead of:

_func:
        vsldoi v2, v3, v2, 12
        vsldoi v2, v2, v2, 4
***     vor f1, v2, v2
        blr


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29607 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2006-08-11 16:47:32 +00:00
parent 84ff46b0d9
commit 325f0a129e

View File

@ -1238,11 +1238,11 @@ static SDOperand LowerRET(SDOperand Op, SelectionDAG &DAG) {
ArgReg = PPC::R3;
} else if (ArgVT == MVT::i64) {
ArgReg = PPC::X3;
} else if (MVT::isFloatingPoint(ArgVT)) {
ArgReg = PPC::F1;
} else {
assert(MVT::isVector(ArgVT));
} else if (MVT::isVector(ArgVT)) {
ArgReg = PPC::V2;
} else {
assert(MVT::isFloatingPoint(ArgVT));
ArgReg = PPC::F1;
}
Copy = DAG.getCopyToReg(Op.getOperand(0), ArgReg, Op.getOperand(1),