summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2011-09-15 21:20:49 +0000
committerEli Friedman <eli.friedman@gmail.com>2011-09-15 21:20:49 +0000
commitee8f14a79972fbed5b8b8d141e79854622c53f59 (patch)
tree53e27703a789b3e1db969cd5f54b55731883843b /llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
parent4d9924f950e8e5123e1ea9842b053e771d9aa432 (diff)
downloadbcm5719-llvm-ee8f14a79972fbed5b8b8d141e79854622c53f59.tar.gz
bcm5719-llvm-ee8f14a79972fbed5b8b8d141e79854622c53f59.zip
Some legalization fixes for atomic load and store.
llvm-svn: 139851
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
index e672512256f..1337ef2242b 100644
--- a/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
@@ -2971,7 +2971,7 @@ void SelectionDAGLegalize::ExpandNode(SDNode *Node,
}
case ISD::ATOMIC_LOAD: {
// There is no libcall for atomic load; fake it with ATOMIC_CMP_SWAP.
- SDValue Zero = DAG.getConstant(0, cast<AtomicSDNode>(Node)->getMemoryVT());
+ SDValue Zero = DAG.getConstant(0, Node->getValueType(0));
SDValue Swap = DAG.getAtomic(ISD::ATOMIC_CMP_SWAP, dl,
cast<AtomicSDNode>(Node)->getMemoryVT(),
Node->getOperand(0),
OpenPOWER on IntegriCloud