annotate graal/com.oracle.max.graal.tests/src/com/oracle/max/graal/compiler/tests/GraphTest.java @ 4410:646a6bfecf73

Small doc fixes.
author Doug Simon <doug.simon@oracle.com>
date Mon, 30 Jan 2012 15:16:00 +0100
parents 1bd28959b8b8
children 897b7d18bebc
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
1 /*
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
2 * Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
4 *
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
5 * This code is free software; you can redistribute it and/or modify it
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
6 * under the terms of the GNU General Public License version 2 only, as
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
7 * published by the Free Software Foundation.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
8 *
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
9 * This code is distributed in the hope that it will be useful, but WITHOUT
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
12 * version 2 for more details (a copy is included in the LICENSE file that
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
13 * accompanied this code).
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
14 *
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
15 * You should have received a copy of the GNU General Public License version
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
16 * 2 along with this work; if not, write to the Free Software Foundation,
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
18 *
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
20 * or visit www.oracle.com if you need additional information or have any
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
21 * questions.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
22 */
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
23 package com.oracle.max.graal.compiler.tests;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
24
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
25 import java.lang.reflect.*;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
26
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
27 import junit.framework.Assert;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
28
4199
aaac4894175c Renamed cri packages from sun to oracle.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 3733
diff changeset
29 import com.oracle.max.cri.ri.*;
4204
4df4499e0289 Fixed unit tests.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4203
diff changeset
30 import com.oracle.max.graal.compiler.phases.*;
4df4499e0289 Fixed unit tests.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4203
diff changeset
31 import com.oracle.max.graal.compiler.phases.PhasePlan.*;
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
32 import com.oracle.max.graal.cri.*;
4363
7462c3600c3a Draft changes to the graph plotting.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4265
diff changeset
33 import com.oracle.max.graal.debug.*;
4205
2af849af1723 moved graphbuilder into the graal.java project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4204
diff changeset
34 import com.oracle.max.graal.java.*;
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
35 import com.oracle.max.graal.nodes.*;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
36
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
37 /**
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
38 * Base class for Graal compiler unit tests. These are white box tests
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
39 * for Graal compiler transformations. The general pattern for a test is:
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
40 * <ol>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
41 * <li>Create a graph by {@linkplain #parse(String) parsing} a method.</li>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
42 * <li>Manually modify the graph (e.g. replace a paramter node with a constant).</li>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
43 * <li>Apply a transformation to the graph.</li>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
44 * <li>Assert that the transformed graph is equal to an expected graph.</li>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
45 * </ol>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
46 * <p>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
47 * See {@link InvokeTest} as an example.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
48 * <p>
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
49 * The tests can be run in Eclipse with the "Compiler Unit Test" Eclipse
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
50 * launch configuration found in the top level of this project or by
4410
646a6bfecf73 Small doc fixes.
Doug Simon <doug.simon@oracle.com>
parents: 4387
diff changeset
51 * running {@code mx unittest} on the command line.
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
52 */
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
53 public abstract class GraphTest {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
54
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
55 protected final GraalRuntime runtime;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
56
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
57 public GraphTest() {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
58 this.runtime = GraalRuntimeAccess.getGraalRuntime();
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
59 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
60
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
61 protected void assertEquals(StructuredGraph expected, StructuredGraph graph) {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
62 if (expected.getNodeCount() != graph.getNodeCount()) {
4363
7462c3600c3a Draft changes to the graph plotting.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4265
diff changeset
63 Debug.dump(expected, "Node count not matching - expected");
7462c3600c3a Draft changes to the graph plotting.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4265
diff changeset
64 Debug.dump(graph, "Node count not matching - actual");
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
65 Assert.fail("Graphs do not have the same number of nodes");
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
66 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
67 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
68
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
69 protected GraalRuntime runtime() {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
70 return runtime;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
71 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
72
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
73 /**
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
74 * Parses a Java method to produce a graph.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
75 *
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
76 * @param methodName the name of the method in {@code this.getClass()} to be parsed
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
77 */
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
78 protected StructuredGraph parse(String methodName) {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
79 Method found = null;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
80 for (Method m : this.getClass().getMethods()) {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
81 if (m.getName().equals(methodName)) {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
82 Assert.assertNull(found);
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
83 found = m;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
84 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
85 }
4340
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
86 if (found != null) {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
87 return parse(found);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
88 } else {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
89 throw new RuntimeException("method not found: " + methodName);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
90 }
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
91 }
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
92
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
93 /**
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
94 * Parses a Java method to produce a graph.
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
95 *
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
96 * @param methodName the name of the method in {@code this.getClass()} to be parsed
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
97 */
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
98 protected StructuredGraph parseProfiled(String methodName) {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
99 Method found = null;
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
100 for (Method m : this.getClass().getMethods()) {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
101 if (m.getName().equals(methodName)) {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
102 Assert.assertNull(found);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
103 found = m;
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
104 }
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
105 }
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
106 if (found != null) {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
107 return parseProfiled(found);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
108 } else {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
109 throw new RuntimeException("method not found: " + methodName);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
110 }
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
111 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
112
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
113 /**
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
114 * Parses a Java method to produce a graph.
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
115 */
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
116 protected StructuredGraph parse(Method m) {
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
117 RiResolvedMethod riMethod = runtime.getRiMethod(m);
4203
847e9dcb4980 Add graph builder to the phase plan.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4200
diff changeset
118 StructuredGraph graph = new StructuredGraph(riMethod);
4315
4c223446c28e Replace the eagerResolving option of GraphBuilderConfiguration with three resolve policies: Default, EagerForSnippets (previously eagerResolving), and Eager (resolves exceptions and types of constants as well)
Peter Hofer <peter.hofer@jku.at>
parents: 4265
diff changeset
119 new GraphBuilderPhase(runtime, GraphBuilderConfiguration.getSnippetDefault()).apply(graph);
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
120 return graph;
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
121 }
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
122
4340
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
123 /**
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
124 * Parses a Java method to produce a graph.
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
125 */
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
126 protected StructuredGraph parseProfiled(Method m) {
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
127 RiResolvedMethod riMethod = runtime.getRiMethod(m);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
128 StructuredGraph graph = new StructuredGraph(riMethod);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
129 new GraphBuilderPhase(runtime, GraphBuilderConfiguration.getDefault()).apply(graph);
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
130 return graph;
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
131 }
5caca26cb1b9 small fix (missing changes)
Lukas Stadler <lukas.stadler@jku.at>
parents: 4315
diff changeset
132
4204
4df4499e0289 Fixed unit tests.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4203
diff changeset
133 protected PhasePlan getDefaultPhasePlan() {
4df4499e0289 Fixed unit tests.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4203
diff changeset
134 PhasePlan plan = new PhasePlan();
4315
4c223446c28e Replace the eagerResolving option of GraphBuilderConfiguration with three resolve policies: Default, EagerForSnippets (previously eagerResolving), and Eager (resolves exceptions and types of constants as well)
Peter Hofer <peter.hofer@jku.at>
parents: 4265
diff changeset
135 plan.addPhase(PhasePosition.AFTER_PARSING, new GraphBuilderPhase(runtime, GraphBuilderConfiguration.getSnippetDefault()));
4204
4df4499e0289 Fixed unit tests.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4203
diff changeset
136 return plan;
4df4499e0289 Fixed unit tests.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents: 4203
diff changeset
137 }
3733
e233f5660da4 Added Java files from Maxine project.
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
diff changeset
138 }