aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2012-03-22 19:29:09 +0000
committerEvan Cheng <evan.cheng@apple.com>2012-03-22 19:29:09 +0000
commit5aef7957ddf43d30c33137386fdd9cbfcc5944e4 (patch)
tree4d0ad06e519933514b1f6034569c8681bd01fcc0 /lib
parentc7f5c6e0e3a25aa5f6320766dd1bb29371e6948d (diff)
downloadexternal_llvm-5aef7957ddf43d30c33137386fdd9cbfcc5944e4.zip
external_llvm-5aef7957ddf43d30c33137386fdd9cbfcc5944e4.tar.gz
external_llvm-5aef7957ddf43d30c33137386fdd9cbfcc5944e4.tar.bz2
Assign node orders to target intrinsics which do not produce results. rdar://11096639
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153269 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
index 2ac9655..6ec38c5 100644
--- a/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
+++ b/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
@@ -3586,6 +3586,12 @@ void SelectionDAGBuilder::visitTargetIntrinsic(const CallInst &I,
}
setValue(&I, Result);
+ } else {
+ // Assign order to result here. If the intrinsic does not produce a result,
+ // it won't be mapped to a SDNode and visit() will not assign it an order
+ // number.
+ ++SDNodeOrder;
+ AssignOrderingToNode(Result.getNode());
}
}