hotspot/test/compiler/jvmci/compilerToVM/ResolveFieldInPoolTest.java
changeset 40855 3c4c913195e3
parent 40631 ed82623d7831
child 41092 c388d897472d
equal deleted inserted replaced
40854:f20df9375ac9 40855:3c4c913195e3
    51 import compiler.jvmci.compilerToVM.ConstantPoolTestCase.Validator;
    51 import compiler.jvmci.compilerToVM.ConstantPoolTestCase.Validator;
    52 import compiler.jvmci.compilerToVM.ConstantPoolTestsHelper.DummyClasses;
    52 import compiler.jvmci.compilerToVM.ConstantPoolTestsHelper.DummyClasses;
    53 import jdk.internal.misc.Unsafe;
    53 import jdk.internal.misc.Unsafe;
    54 import jdk.internal.org.objectweb.asm.Opcodes;
    54 import jdk.internal.org.objectweb.asm.Opcodes;
    55 import jdk.test.lib.Asserts;
    55 import jdk.test.lib.Asserts;
    56 import jdk.test.lib.Utils;
    56 import jdk.test.lib.unsafe.UnsafeHelper;
    57 import jdk.vm.ci.hotspot.CompilerToVMHelper;
    57 import jdk.vm.ci.hotspot.CompilerToVMHelper;
    58 import jdk.vm.ci.hotspot.HotSpotResolvedObjectType;
    58 import jdk.vm.ci.hotspot.HotSpotResolvedObjectType;
    59 import jdk.vm.ci.meta.ConstantPool;
    59 import jdk.vm.ci.meta.ConstantPool;
    60 
    60 
    61 import java.lang.reflect.Field;
    61 import java.lang.reflect.Field;
    67 /**
    67 /**
    68  * Test for {@code jdk.vm.ci.hotspot.CompilerToVM.resolveFieldInPool} method
    68  * Test for {@code jdk.vm.ci.hotspot.CompilerToVM.resolveFieldInPool} method
    69  */
    69  */
    70 public class ResolveFieldInPoolTest {
    70 public class ResolveFieldInPoolTest {
    71 
    71 
    72     private static final Unsafe UNSAFE = Utils.getUnsafe();
    72     private static final Unsafe UNSAFE = UnsafeHelper.getUnsafe();
    73 
    73 
    74     public static void main(String[] args) throws Exception {
    74     public static void main(String[] args) throws Exception {
    75         Map<ConstantTypes, Validator> typeTests = new HashMap<>();
    75         Map<ConstantTypes, Validator> typeTests = new HashMap<>();
    76         typeTests.put(CONSTANT_FIELDREF, ResolveFieldInPoolTest::validate);
    76         typeTests.put(CONSTANT_FIELDREF, ResolveFieldInPoolTest::validate);
    77         ConstantPoolTestCase testCase = new ConstantPoolTestCase(typeTests);
    77         ConstantPoolTestCase testCase = new ConstantPoolTestCase(typeTests);