summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@intel.com>2019-06-02 03:31:01 +0000
committerCraig Topper <craig.topper@intel.com>2019-06-02 03:31:01 +0000
commitf58ef87bb789bece7cba04925756814b903b3740 (patch)
treeabcda9a503645ccdb00bc813dfe00175f239b891 /llvm/lib
parent0a6bababa830e325014eb5ebde1b39050afcb2a3 (diff)
downloadbcm5719-llvm-f58ef87bb789bece7cba04925756814b903b3740.tar.gz
bcm5719-llvm-f58ef87bb789bece7cba04925756814b903b3740.zip
[DAGCombiner] Replace two unchecked dyn_casts with casts.
The results of the dyn_casts were immediately dereferenced on the next line so they had better not be null. I don't think there's any way for these dyn_casts to fail, so use a cast of adding null check. llvm-svn: 362315
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
index 773e0281b17..4ed17440abc 100644
--- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -8068,7 +8068,7 @@ SDValue DAGCombiner::visitMSTORE(SDNode *N) {
if (Level >= AfterLegalizeTypes)
return SDValue();
- MaskedStoreSDNode *MST = dyn_cast<MaskedStoreSDNode>(N);
+ MaskedStoreSDNode *MST = cast<MaskedStoreSDNode>(N);
SDValue Mask = MST->getMask();
SDValue Data = MST->getValue();
EVT VT = Data.getValueType();
@@ -8219,7 +8219,7 @@ SDValue DAGCombiner::visitMLOAD(SDNode *N) {
if (Level >= AfterLegalizeTypes)
return SDValue();
- MaskedLoadSDNode *MLD = dyn_cast<MaskedLoadSDNode>(N);
+ MaskedLoadSDNode *MLD = cast<MaskedLoadSDNode>(N);
SDValue Mask = MLD->getMask();
SDLoc DL(N);
OpenPOWER on IntegriCloud