src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.hotspot.test/src/org/graalvm/compiler/hotspot/test/ReplaceConstantNodesPhaseTest.java
equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2017, 2019, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
24 |
24 |
25 package org.graalvm.compiler.hotspot.test; |
25 package org.graalvm.compiler.hotspot.test; |
26 |
26 |
27 import org.graalvm.compiler.core.common.GraalOptions; |
27 import org.graalvm.compiler.core.common.GraalOptions; |
28 import org.graalvm.compiler.hotspot.GraalHotSpotVMConfig; |
28 import org.graalvm.compiler.hotspot.GraalHotSpotVMConfig; |
29 import org.graalvm.compiler.hotspot.meta.HotSpotClassInitializationPlugin; |
29 import org.graalvm.compiler.hotspot.meta.HotSpotAOTClassInitializationPlugin; |
30 import org.graalvm.compiler.hotspot.nodes.aot.InitializeKlassNode; |
30 import org.graalvm.compiler.hotspot.nodes.aot.InitializeKlassNode; |
31 import org.graalvm.compiler.hotspot.nodes.aot.LoadConstantIndirectlyNode; |
31 import org.graalvm.compiler.hotspot.nodes.aot.LoadConstantIndirectlyNode; |
32 import org.graalvm.compiler.hotspot.nodes.aot.ResolveConstantNode; |
32 import org.graalvm.compiler.hotspot.nodes.aot.ResolveConstantNode; |
33 import org.graalvm.compiler.hotspot.phases.LoadJavaMirrorWithKlassPhase; |
33 import org.graalvm.compiler.hotspot.phases.LoadJavaMirrorWithKlassPhase; |
34 import org.graalvm.compiler.hotspot.phases.aot.EliminateRedundantInitializationPhase; |
34 import org.graalvm.compiler.hotspot.phases.aot.EliminateRedundantInitializationPhase; |
48 private final GraalHotSpotVMConfig config = runtime().getVMConfig(); |
48 private final GraalHotSpotVMConfig config = runtime().getVMConfig(); |
49 |
49 |
50 @Override |
50 @Override |
51 protected Plugins getDefaultGraphBuilderPlugins() { |
51 protected Plugins getDefaultGraphBuilderPlugins() { |
52 Plugins plugins = super.getDefaultGraphBuilderPlugins(); |
52 Plugins plugins = super.getDefaultGraphBuilderPlugins(); |
53 plugins.setClassInitializationPlugin(new HotSpotClassInitializationPlugin()); |
53 plugins.setClassInitializationPlugin(new HotSpotAOTClassInitializationPlugin()); |
54 return plugins; |
54 return plugins; |
55 } |
55 } |
56 |
56 |
57 public static class X { |
57 public static class X { |
58 public static int x; |
58 public static int x; |