test/jtreg-ext/requires/VMProps.java
changeset 51214 67736b4846a0
parent 50914 07498f5b6a96
child 51251 0a7a0a6dfa22
--- a/test/jtreg-ext/requires/VMProps.java	Fri Jul 20 09:33:49 2018 +0200
+++ b/test/jtreg-ext/requires/VMProps.java	Fri Jul 20 09:46:57 2018 +0200
@@ -79,6 +79,9 @@
         // vm.hasSAandCanAttach is "true" if the VM contains the serviceability agent
         // and jhsdb and it can attach to the VM.
         map.put("vm.hasSAandCanAttach", vmHasSAandCanAttach());
+        // vm.hasJFR is "true" if JFR is included in the build of the VM and
+        // so tests can be executed.
+        map.put("vm.hasJFR", vmHasJFR());
         map.put("vm.cpu.features", cpuFeatures());
         map.put("vm.rtm.cpu", vmRTMCPU());
         map.put("vm.rtm.os", vmRTMOS());
@@ -288,6 +291,14 @@
     }
 
     /**
+     * @return "true" if the VM is compiled with Java Flight Recorder (JFR)
+     * support.
+     */
+    protected String vmHasJFR() {
+        return "" + WB.isJFRIncludedInVmBuild();
+    }
+
+    /**
      * @return true if VM runs RTM supported OS and false otherwise.
      */
     protected String vmRTMOS() {