summaryrefslogtreecommitdiffstats
path: root/llvm/utils/TableGen/DAGISelEmitter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/utils/TableGen/DAGISelEmitter.cpp')
-rw-r--r--llvm/utils/TableGen/DAGISelEmitter.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/utils/TableGen/DAGISelEmitter.cpp b/llvm/utils/TableGen/DAGISelEmitter.cpp
index d2e260e2e7e..243700fdb71 100644
--- a/llvm/utils/TableGen/DAGISelEmitter.cpp
+++ b/llvm/utils/TableGen/DAGISelEmitter.cpp
@@ -586,6 +586,8 @@ void PatternCodeEmitter::EmitMatchCode(TreePatternNode *N, TreePatternNode *P,
// / [YY]
// | ^
// [XX]-------|
+
+ // We know we need the check if N's parent is not the root.
bool NeedCheck = P != Pattern;
if (!NeedCheck) {
const SDNodeInfo &PInfo = CGP.getSDNodeInfo(P->getOperator());
OpenPOWER on IntegriCloud