diff options
| author | Evan Cheng <evan.cheng@apple.com> | 2011-03-11 00:48:56 +0000 |
|---|---|---|
| committer | Evan Cheng <evan.cheng@apple.com> | 2011-03-11 00:48:56 +0000 |
| commit | adb9c03e413788d4d67d28e7837b1fa3a3f9fdfb (patch) | |
| tree | b40befec3df6c89bfcfc40d1fcdde36b66c76799 /llvm/lib/CodeGen | |
| parent | 24e99aa8337b0fd71f1220d664c529c3651e09e2 (diff) | |
| download | bcm5719-llvm-adb9c03e413788d4d67d28e7837b1fa3a3f9fdfb.tar.gz bcm5719-llvm-adb9c03e413788d4d67d28e7837b1fa3a3f9fdfb.zip | |
Avoid replacing the value of a directly stored load with the stored value if the load is indexed. rdar://9117613.
llvm-svn: 127440
Diffstat (limited to 'llvm/lib/CodeGen')
| -rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp index 4c70bc3e88b..f9f89858c97 100644 --- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp @@ -5862,8 +5862,7 @@ SDValue DAGCombiner::visitLOAD(SDNode *N) { // value. // TODO: Handle store large -> read small portion. // TODO: Handle TRUNCSTORE/LOADEXT - if (LD->getExtensionType() == ISD::NON_EXTLOAD && - !LD->isVolatile()) { + if (ISD::isNormalLoad(N) && !LD->isVolatile()) { if (ISD::isNON_TRUNCStore(Chain.getNode())) { StoreSDNode *PrevST = cast<StoreSDNode>(Chain); if (PrevST->getBasePtr() == Ptr && |

