summaryrefslogtreecommitdiff
path: root/src/jit/earlyprop.cpp
diff options
context:
space:
mode:
authorPetr Onderka <gsvick@gmail.com>2016-08-31 22:10:48 +0200
committerPetr Onderka <gsvick@gmail.com>2016-08-31 22:10:48 +0200
commit1efc57d9c1a02f591cd37167c603b646a39566b9 (patch)
tree318d0046aca7c89d56b97875bb5ae8a5c91c58cd /src/jit/earlyprop.cpp
parent60575486b9b7156b219b7e42d0e188a29be58304 (diff)
downloadcoreclr-1efc57d9c1a02f591cd37167c603b646a39566b9.tar.gz
coreclr-1efc57d9c1a02f591cd37167c603b646a39566b9.tar.bz2
coreclr-1efc57d9c1a02f591cd37167c603b646a39566b9.zip
Add missing BBF_HAS_NULLCHECK test
Diffstat (limited to 'src/jit/earlyprop.cpp')
-rw-r--r--src/jit/earlyprop.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/jit/earlyprop.cpp b/src/jit/earlyprop.cpp
index 0034b4a0ad..5b985df2bb 100644
--- a/src/jit/earlyprop.cpp
+++ b/src/jit/earlyprop.cpp
@@ -510,6 +510,11 @@ void Compiler::optFoldNullCheck(GenTreePtr tree)
// |
// x
+ if ((compCurBB->bbFlags & BBF_HAS_NULLCHECK) == 0)
+ {
+ return;
+ }
+
assert(tree->OperGet() == GT_IND);
if (tree->gtGetOp1()->OperGet() == GT_LCL_VAR)
{