diff options
author | Cameron Zwarich <zwarich@apple.com> | 2011-03-16 22:20:07 +0000 |
---|---|---|
committer | Cameron Zwarich <zwarich@apple.com> | 2011-03-16 22:20:07 +0000 |
commit | 8df6bf5f5c8a55b089ef8b706bc0cc77ff16906c (patch) | |
tree | de589713cc324a2d5505f3f8f3c8c30413d43485 /lib | |
parent | 83320a023c26aa8150761fc0694e7999941febb2 (diff) |
Don't recompute something that we already have in a local variable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127764 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp index c6b1a2d612..aa7009ac39 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp @@ -1151,9 +1151,9 @@ void SelectionDAGBuilder::visitRet(const ReturnInst &I) { Flags.setInReg(); // Propagate extension type if any - if (F->paramHasAttr(0, Attribute::SExt)) + if (ExtendKind == ISD::SIGN_EXTEND) Flags.setSExt(); - else if (F->paramHasAttr(0, Attribute::ZExt)) + else if (ExtendKind == ISD::ZERO_EXTEND) Flags.setZExt(); for (unsigned i = 0; i < NumParts; ++i) { |