test/jtreg-ext/requires/VMProps.java
changeset 58428 9b644c06226f
parent 55757 07e998f8f816
child 58511 eb68d459ba6a
equal deleted inserted replaced
58427:d9b2b4085f9a 58428:9b644c06226f
   233     /**
   233     /**
   234      * @return true if VM supports JVMCI and false otherwise
   234      * @return true if VM supports JVMCI and false otherwise
   235      */
   235      */
   236     protected String vmJvmci() {
   236     protected String vmJvmci() {
   237         // builds with jvmci have this flag
   237         // builds with jvmci have this flag
   238         return "" + (WB.getBooleanVMFlag("EnableJVMCI") != null);
   238         if (WB.getBooleanVMFlag("EnableJVMCI") == null) {
       
   239             return "false";
       
   240         }
       
   241 
       
   242         switch (GC.selected()) {
       
   243             case Serial:
       
   244             case Parallel:
       
   245             case G1:
       
   246                 // These GCs are supported with JVMCI
       
   247                 return "true";
       
   248             default:
       
   249                 break;
       
   250         }
       
   251 
       
   252         // Every other GC is not supported
       
   253         return "false";
   239     }
   254     }
   240 
   255 
   241     /**
   256     /**
   242      * @return true if VM runs in emulated-client mode and false otherwise.
   257      * @return true if VM runs in emulated-client mode and false otherwise.
   243      */
   258      */
   354         if (Platform.isWindows()) {
   369         if (Platform.isWindows()) {
   355             jaotc = bin.resolve("jaotc.exe");
   370             jaotc = bin.resolve("jaotc.exe");
   356         } else {
   371         } else {
   357             jaotc = bin.resolve("jaotc");
   372             jaotc = bin.resolve("jaotc");
   358         }
   373         }
   359         return "" + Files.exists(jaotc);
   374 
       
   375         if (!Files.exists(jaotc)) {
       
   376             // No jaotc => no AOT
       
   377             return "false";
       
   378         }
       
   379 
       
   380         switch (GC.selected()) {
       
   381             case Serial:
       
   382             case Parallel:
       
   383             case G1:
       
   384                 // These GCs are supported with AOT
       
   385                 return "true";
       
   386             default:
       
   387                 break;
       
   388         }
       
   389 
       
   390         // Every other GC is not supported
       
   391         return "false";
   360     }
   392     }
   361 
   393 
   362     /*
   394     /*
   363      * @return true if there is at least one loaded AOT'ed library.
   395      * @return true if there is at least one loaded AOT'ed library.
   364      */
   396      */