Skip to content

Commit

Permalink
compilation failure handling should not be different with assertions …
Browse files Browse the repository at this point in the history
…enabled
  • Loading branch information
dougxc committed Apr 11, 2019
1 parent 8bfec26 commit 5d399e6
Showing 1 changed file with 4 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
import org.graalvm.compiler.core.CompilationPrinter;
import org.graalvm.compiler.core.CompilationWrapper;
import org.graalvm.compiler.core.common.CompilationIdentifier;
import org.graalvm.compiler.debug.Assertions;
import org.graalvm.compiler.debug.CounterKey;
import org.graalvm.compiler.debug.DebugCloseable;
import org.graalvm.compiler.debug.DebugContext;
Expand Down Expand Up @@ -150,9 +149,8 @@ protected ExceptionAction lookupAction(OptionValues values, Throwable cause) {
if (bailout.isPermanent()) {
// Respect current action if it has been explicitly set.
if (!CompilationBailoutAsFailure.hasBeenSet(values)) {
// Get more info for permanent bailouts during bootstrap
// or when assertions are enabled.
if (Assertions.assertionsEnabled() || compiler.getGraalRuntime().isBootstrapping()) {
// Get more info for permanent bailouts during bootstrap.
if (compiler.getGraalRuntime().isBootstrapping()) {
return Diagnose;
}

Expand All @@ -165,9 +163,8 @@ protected ExceptionAction lookupAction(OptionValues values, Throwable cause) {

// Respect current action if it has been explicitly set.
if (!CompilationFailureAction.hasBeenSet(values)) {
// Automatically exit on failure during bootstrap
// or when assertions are enabled.
if (Assertions.assertionsEnabled() || compiler.getGraalRuntime().isBootstrapping()) {
// Automatically exit on failure during bootstrap.
if (compiler.getGraalRuntime().isBootstrapping()) {
return ExitVM;
}
}
Expand Down

0 comments on commit 5d399e6

Please sign in to comment.