Mercurial > hg > truffle
comparison test/testlibrary/whitebox/sun/hotspot/WhiteBox.java @ 20608:4cb90023bf2b
8061651: Interface to the Lookup Index Cache to improve URLClassPath search time
Summary: Implemented the interface in sun.misc.URLClassPath and corresponding JVM_XXX APIs
Reviewed-by: mchung, acorn, jiangli, dholmes
author | iklam |
---|---|
date | Mon, 13 Oct 2014 16:09:57 -0700 |
parents | 417e3b8d04c5 |
children | 80260967f994 |
comparison
equal
deleted
inserted
replaced
20607:f5f752e74840 | 20608:4cb90023bf2b |
---|---|
28 import java.util.Arrays; | 28 import java.util.Arrays; |
29 import java.util.List; | 29 import java.util.List; |
30 import java.util.function.Function; | 30 import java.util.function.Function; |
31 import java.util.stream.Stream; | 31 import java.util.stream.Stream; |
32 import java.security.BasicPermission; | 32 import java.security.BasicPermission; |
33 import java.net.URL; | |
33 | 34 |
34 import sun.hotspot.parser.DiagnosticCommand; | 35 import sun.hotspot.parser.DiagnosticCommand; |
35 | 36 |
36 public class WhiteBox { | 37 public class WhiteBox { |
37 | 38 |
81 // Make sure class name is in the correct format | 82 // Make sure class name is in the correct format |
82 public boolean isClassAlive(String name) { | 83 public boolean isClassAlive(String name) { |
83 return isClassAlive0(name.replace('.', '/')); | 84 return isClassAlive0(name.replace('.', '/')); |
84 } | 85 } |
85 private native boolean isClassAlive0(String name); | 86 private native boolean isClassAlive0(String name); |
87 | |
88 // Resource/Class Lookup Cache | |
89 public native boolean classKnownToNotExist(ClassLoader loader, String name); | |
90 public native URL[] getLookupCacheURLs(ClassLoader loader); | |
91 public native int[] getLookupCacheMatches(ClassLoader loader, String name); | |
86 | 92 |
87 // G1 | 93 // G1 |
88 public native boolean g1InConcurrentMark(); | 94 public native boolean g1InConcurrentMark(); |
89 public native boolean g1IsHumongous(Object o); | 95 public native boolean g1IsHumongous(Object o); |
90 public native long g1NumFreeRegions(); | 96 public native long g1NumFreeRegions(); |