Skip to content

Commit d56d975

Browse files
committed
[GR-37349] Check for null ProfilingInfo in OptimisticOptimizations
PullRequest: graal/11289
2 parents 4ae0e0d + 1924879 commit d56d975

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/src/org.graalvm.compiler.phases/src/org/graalvm/compiler/phases/OptimisticOptimizations.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ public boolean lessOptimisticThan(OptimisticOptimizations other) {
132132
}
133133

134134
private static boolean checkDeoptimizations(OptionValues options, ProfilingInfo profilingInfo, DeoptimizationReason reason) {
135-
return profilingInfo.getDeoptimizationCount(reason) < GraalOptions.DeoptsToDisableOptimisticOptimization.getValue(options);
135+
return profilingInfo == null || profilingInfo.getDeoptimizationCount(reason) < GraalOptions.DeoptsToDisableOptimisticOptimization.getValue(options);
136136
}
137137

138138
@Override

0 commit comments

Comments
 (0)