src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java
--- a/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java Tue Jun 04 11:55:51 2019 -0700
+++ b/src/jdk.internal.vm.ci/share/classes/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/CompilerToVM.java Tue Jun 04 12:44:53 2019 -0700
@@ -560,6 +560,18 @@
native long[] collectCounters();
/**
+ * Get the current number of counters allocated for use by JVMCI. Should be the same value as
+ * the flag {@code JVMCICounterSize}.
+ */
+ native int getCountersSize();
+
+ /**
+ * Attempt to change the size of the counters allocated for JVMCI. This requires a safepoint to
+ * safely reallocate the storage but it's advisable to increase the size in reasonable chunks.
+ */
+ native boolean setCountersSize(int newSize);
+
+ /**
* Determines if {@code metaspaceMethodData} is mature.
*/
native boolean isMature(long metaspaceMethodData);