< prev index next >

test/compiler/jvmci/compilerToVM/GetNextStackFrameTest.java

Print this page
rev 11557 : 8132919: use package in compiler tests
Reviewed-by: duke


  25  * @test
  26  * @bug 8136421
  27  * @requires (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9" | vm.simpleArch == "aarch64")
  28  * @library / /testlibrary /test/lib
  29  * @library ../common/patches
  30  * @modules java.base/jdk.internal.misc
  31  * @modules java.base/jdk.internal.org.objectweb.asm
  32  *          java.base/jdk.internal.org.objectweb.asm.tree
  33  *          jdk.vm.ci/jdk.vm.ci.hotspot
  34  *          jdk.vm.ci/jdk.vm.ci.code
  35  *          jdk.vm.ci/jdk.vm.ci.meta
  36  * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper
  37  * @build compiler.jvmci.compilerToVM.GetNextStackFrameTest
  38  * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI
  39  *                   compiler.jvmci.compilerToVM.GetNextStackFrameTest
  40  */
  41 
  42 package compiler.jvmci.compilerToVM;
  43 
  44 import compiler.jvmci.common.CTVMUtilities;
  45 import java.lang.reflect.Method;
  46 import jdk.vm.ci.hotspot.CompilerToVMHelper;
  47 import jdk.vm.ci.hotspot.HotSpotStackFrameReference;
  48 import jdk.vm.ci.meta.ResolvedJavaMethod;
  49 import jdk.test.lib.Asserts;
  50 


  51 public class GetNextStackFrameTest {
  52     private static final int RECURSION_AMOUNT = 3;
  53     private static final ResolvedJavaMethod REC_FRAME_METHOD;
  54     private static final ResolvedJavaMethod FRAME1_METHOD;
  55     private static final ResolvedJavaMethod FRAME2_METHOD;
  56     private static final ResolvedJavaMethod FRAME3_METHOD;
  57     private static final ResolvedJavaMethod FRAME4_METHOD;
  58     private static final ResolvedJavaMethod RUN_METHOD;
  59 
  60     static {
  61         Method method;
  62         try {
  63             Class<?> aClass = GetNextStackFrameTest.class;
  64             method = aClass.getDeclaredMethod("recursiveFrame", int.class);
  65             REC_FRAME_METHOD = CTVMUtilities.getResolvedMethod(method);
  66             method = aClass.getDeclaredMethod("frame1");
  67             FRAME1_METHOD = CTVMUtilities.getResolvedMethod(method);
  68             method = aClass.getDeclaredMethod("frame2");
  69             FRAME2_METHOD = CTVMUtilities.getResolvedMethod(method);
  70             method = aClass.getDeclaredMethod("frame3");




  25  * @test
  26  * @bug 8136421
  27  * @requires (vm.simpleArch == "x64" | vm.simpleArch == "sparcv9" | vm.simpleArch == "aarch64")
  28  * @library / /testlibrary /test/lib
  29  * @library ../common/patches
  30  * @modules java.base/jdk.internal.misc
  31  * @modules java.base/jdk.internal.org.objectweb.asm
  32  *          java.base/jdk.internal.org.objectweb.asm.tree
  33  *          jdk.vm.ci/jdk.vm.ci.hotspot
  34  *          jdk.vm.ci/jdk.vm.ci.code
  35  *          jdk.vm.ci/jdk.vm.ci.meta
  36  * @build jdk.vm.ci/jdk.vm.ci.hotspot.CompilerToVMHelper
  37  * @build compiler.jvmci.compilerToVM.GetNextStackFrameTest
  38  * @run main/othervm -XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI
  39  *                   compiler.jvmci.compilerToVM.GetNextStackFrameTest
  40  */
  41 
  42 package compiler.jvmci.compilerToVM;
  43 
  44 import compiler.jvmci.common.CTVMUtilities;
  45 import jdk.test.lib.Asserts;
  46 import jdk.vm.ci.hotspot.CompilerToVMHelper;
  47 import jdk.vm.ci.hotspot.HotSpotStackFrameReference;
  48 import jdk.vm.ci.meta.ResolvedJavaMethod;

  49 
  50 import java.lang.reflect.Method;
  51 
  52 public class GetNextStackFrameTest {
  53     private static final int RECURSION_AMOUNT = 3;
  54     private static final ResolvedJavaMethod REC_FRAME_METHOD;
  55     private static final ResolvedJavaMethod FRAME1_METHOD;
  56     private static final ResolvedJavaMethod FRAME2_METHOD;
  57     private static final ResolvedJavaMethod FRAME3_METHOD;
  58     private static final ResolvedJavaMethod FRAME4_METHOD;
  59     private static final ResolvedJavaMethod RUN_METHOD;
  60 
  61     static {
  62         Method method;
  63         try {
  64             Class<?> aClass = GetNextStackFrameTest.class;
  65             method = aClass.getDeclaredMethod("recursiveFrame", int.class);
  66             REC_FRAME_METHOD = CTVMUtilities.getResolvedMethod(method);
  67             method = aClass.getDeclaredMethod("frame1");
  68             FRAME1_METHOD = CTVMUtilities.getResolvedMethod(method);
  69             method = aClass.getDeclaredMethod("frame2");
  70             FRAME2_METHOD = CTVMUtilities.getResolvedMethod(method);
  71             method = aClass.getDeclaredMethod("frame3");


< prev index next >