diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2008-02-26 18:37:49 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2008-02-26 18:37:49 +0000 |
commit | 9ec8095485c994522c9a50e16fc029de94c20476 (patch) | |
tree | 0655cdb4e01d169dc970fc839727d556bc2bce39 /lib/Transforms/Scalar/CodeGenPrepare.cpp | |
parent | 36ab30102a220a5d1e3e3ac062790fca218a38df (diff) |
Fix for pr2093: direct operands aren't necessarily addresses, so don't
try to simplify them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47610 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Scalar/CodeGenPrepare.cpp')
-rw-r--r-- | lib/Transforms/Scalar/CodeGenPrepare.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Transforms/Scalar/CodeGenPrepare.cpp b/lib/Transforms/Scalar/CodeGenPrepare.cpp index e6f7283ef4..15ccbbd420 100644 --- a/lib/Transforms/Scalar/CodeGenPrepare.cpp +++ b/lib/Transforms/Scalar/CodeGenPrepare.cpp @@ -970,7 +970,8 @@ bool CodeGenPrepare::OptimizeInlineAsmInst(Instruction *I, CallSite CS, // Compute the constraint code and ConstraintType to use. OpInfo.ComputeConstraintToUse(*TLI); - if (OpInfo.ConstraintType == TargetLowering::C_Memory) { + if (OpInfo.ConstraintType == TargetLowering::C_Memory && + OpInfo.isIndirect) { Value *OpVal = OpInfo.CallOperandVal; MadeChange |= OptimizeLoadStoreInst(I, OpVal, OpVal->getType(), SunkAddrs); |