8250627: Use -XX:+/-UseContainerSupport for enabling/disabling Java container metrics

Fri, 24 Jul 2020 14:32:33 +0200

author
sgehwolf
date
Fri, 24 Jul 2020 14:32:33 +0200
changeset 9987
a025f6d9e6e8
parent 9986
85e682d8ab91
child 9988
1b2d99958c29

8250627: Use -XX:+/-UseContainerSupport for enabling/disabling Java container metrics
Reviewed-by: aph, dholmes, bobv, shade

make/linux/makefiles/mapfile-vers-debug file | annotate | diff | comparison | revisions
make/linux/makefiles/mapfile-vers-product file | annotate | diff | comparison | revisions
src/share/vm/prims/jvm.cpp file | annotate | diff | comparison | revisions
src/share/vm/prims/jvm.h file | annotate | diff | comparison | revisions
     1.1 --- a/make/linux/makefiles/mapfile-vers-debug	Fri Jul 17 11:54:17 2020 +0200
     1.2 +++ b/make/linux/makefiles/mapfile-vers-debug	Fri Jul 24 14:32:33 2020 +0200
     1.3 @@ -190,6 +190,7 @@
     1.4                  JVM_IsSilentCompiler;
     1.5                  JVM_IsSupportedJNIVersion;
     1.6                  JVM_IsThreadAlive;
     1.7 +                JVM_IsUseContainerSupport;
     1.8                  JVM_IsVMGeneratedMethodIx;
     1.9                  JVM_LatestUserDefinedLoader;
    1.10                  JVM_Listen;
     2.1 --- a/make/linux/makefiles/mapfile-vers-product	Fri Jul 17 11:54:17 2020 +0200
     2.2 +++ b/make/linux/makefiles/mapfile-vers-product	Fri Jul 24 14:32:33 2020 +0200
     2.3 @@ -185,6 +185,7 @@
     2.4                  JVM_IsInterface;
     2.5                  JVM_IsInterrupted;
     2.6                  JVM_IsNaN;
     2.7 +                JVM_IsUseContainerSupport;
     2.8                  JVM_IsPrimitiveClass;
     2.9                  JVM_IsSameClassPackage;
    2.10                  JVM_IsSilentCompiler;
     3.1 --- a/src/share/vm/prims/jvm.cpp	Fri Jul 17 11:54:17 2020 +0200
     3.2 +++ b/src/share/vm/prims/jvm.cpp	Fri Jul 24 14:32:33 2020 +0200
     3.3 @@ -525,6 +525,17 @@
     3.4  JVM_END
     3.5  
     3.6  
     3.7 +JVM_ENTRY_NO_ENV(jboolean, JVM_IsUseContainerSupport(void))
     3.8 +  JVMWrapper("JVM_IsUseContainerSupport");
     3.9 +#ifdef TARGET_OS_FAMILY_linux
    3.10 +  if (UseContainerSupport) {
    3.11 +      return JNI_TRUE;
    3.12 +  }
    3.13 +#endif
    3.14 +  return JNI_FALSE;
    3.15 +JVM_END
    3.16 +
    3.17 +
    3.18  
    3.19  // java.lang.Throwable //////////////////////////////////////////////////////
    3.20  
     4.1 --- a/src/share/vm/prims/jvm.h	Fri Jul 17 11:54:17 2020 +0200
     4.2 +++ b/src/share/vm/prims/jvm.h	Fri Jul 24 14:32:33 2020 +0200
     4.3 @@ -202,6 +202,9 @@
     4.4  JNIEXPORT jint JNICALL
     4.5  JVM_ActiveProcessorCount(void);
     4.6  
     4.7 +JNIEXPORT jboolean JNICALL
     4.8 +JVM_IsUseContainerSupport(void);
     4.9 +
    4.10  JNIEXPORT void * JNICALL
    4.11  JVM_LoadLibrary(const char *name);
    4.12  

mercurial