public class WriteBarrierAdditionTest extends GraalCompilerTest
| Modifier and Type | Class and Description |
|---|---|
static class |
WriteBarrierAdditionTest.Container |
GraalCompilerTest.ArgSupplier, GraalCompilerTest.ResultGraalTest.MultiCauseAssertionError| Modifier and Type | Field and Description |
|---|---|
(package private) static WriteBarrierAdditionTest.Container |
con |
private static HotSpotVMConfig |
config |
(package private) static Object[] |
dst |
private static long |
referentOffset |
(package private) static Object[] |
src |
(package private) static WeakReference<Object> |
wr |
lastCompiledGraph| Constructor and Description |
|---|
WriteBarrierAdditionTest() |
| Modifier and Type | Method and Description |
|---|---|
private HotSpotInstalledCode |
getInstalledCode(String name,
boolean withUnsafePrefix) |
void |
test1()
Expected 2 barriers for the Serial GC and 4 for G1 (2 pre + 2 post).
|
void |
test10()
The following test concerns the runtime checks of the unsafe loads.
|
void |
test11() |
static void |
test1Snippet() |
void |
test2()
Expected 4 barriers for the Serial GC and 8 for G1 (4 pre + 4 post).
|
private void |
test2(String snippet,
Object... args) |
static void |
test2Snippet(boolean test) |
void |
test3()
Expected 4 barriers for the Serial GC and 8 for G1 (4 pre + 4 post).
|
static void |
test3Snippet() |
void |
test4()
Expected 2 barriers for the Serial GC and 5 for G1 (3 pre + 2 post) The (2 or 4) barriers are
emitted while initializing the fields of the WeakReference instance.
|
static Object |
test4Snippet() |
void |
test5()
Expected 4 barriers for the Serial GC and 9 for G1 (1 ref + 4 pre + 4 post).
|
static Object |
test5Snippet() |
void |
test6()
The following test concerns the runtime checks of the unsafe loads.
|
void |
test7()
The following test concerns the runtime checks of the unsafe loads.
|
void |
test8()
The following test concerns the runtime checks of the unsafe loads.
|
void |
test9()
The following test concerns the runtime checks of the unsafe loads.
|
static void |
testArrayCopy(Object a,
Object b,
Object c) |
private void |
testHelper(String snippetName,
int expectedBarriers) |
static Object |
testUnsafeLoad(sun.misc.Unsafe theUnsafe,
Object a,
Object b,
Object c) |
addMethod, after, afterTest, applyArgSuppliers, argsWithReceiver, asResolvedJavaMethod, assertConstantReturn, assertEquals, assertEquals, assertEquals, before, beforeTest, branchProbability, breakpoint, breakpoint, checkArgs, checkHighTierGraph, checkLowTierGraph, checkMidTierGraph, compile, countUnusedConstants, createLIRSuites, createSuites, editGraphBuilderConfiguration, executeActual, executeActualCheckDeopt, executeExpected, getBackend, getCanonicalGraphString, getCode, getCode, getCode, getCodeCache, getConstantReflection, getCustomGraphBuilderSuite, getDefaultGraphBuilderPlugins, getDefaultGraphBuilderSuite, getDefaultHighTierContext, getLIRSuites, getLowerer, getMetaAccess, getNodeCountExcludingUnusedConstants, getProviders, getReplacements, getResolvedJavaMethod, getResolvedJavaMethod, getResolvedJavaMethod, getSnippetReflection, getSpeculationLog, getSuites, getTarget, initializeDebugging, invoke, isArchitecture, iterationCount, lookupMethod, parseDebug, parseEager, parseEager, parseForCompile, parseProfiled, parseProfiled, referenceInvoke, supply, test, test, testAgainstExpected, testAgainstExpected, testNassertDeepEquals, assertDeepEquals, assertDeepEquals, assertDeepEquals, assertFalse, assertFalse, assertFalse, assertTrue, assertTrue, assertTrue, equalFloatsOrDoublesDelta, fail, getMethod, getMethod, getMethod, ulpsDeltaprivate static final HotSpotVMConfig config
private static final long referentOffset
static WeakReference<Object> wr
static WriteBarrierAdditionTest.Container con
public WriteBarrierAdditionTest()
public void test1() throws Exception
Exceptionpublic static void test1Snippet()
public void test2() throws Exception
Exceptionpublic static void test2Snippet(boolean test)
public void test3() throws Exception
Exceptionpublic static void test3Snippet()
public void test4() throws Exception
Exceptionpublic static Object test4Snippet()
public void test5() throws Exception
Exceptionpublic static Object test5Snippet() throws Exception
Exceptionpublic void test6() throws Exception
Exceptionpublic void test7() throws Exception
Exceptionpublic void test8() throws Exception
Exceptionpublic void test10() throws Exception
Exceptionpublic void test9() throws Exception
Exceptionpublic static void testArrayCopy(Object a, Object b, Object c) throws Exception
Exceptionpublic static Object testUnsafeLoad(sun.misc.Unsafe theUnsafe, Object a, Object b, Object c) throws Exception
Exceptionprivate HotSpotInstalledCode getInstalledCode(String name, boolean withUnsafePrefix) throws Exception
Exceptionprivate void testHelper(String snippetName, int expectedBarriers) throws Exception, SecurityException
ExceptionSecurityException