Merge
authorsla
Mon, 28 Apr 2014 09:31:25 +0000
changeset 24243 ef084b317ced
parent 24241 cddb46f7b7fa (current diff)
parent 24242 73337a12595a (diff)
child 24245 9e3d7b4e7041
child 24331 c0bc7e5653fb
Merge
--- a/hotspot/make/aix/makefiles/mapfile-vers-debug	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/aix/makefiles/mapfile-vers-debug	Mon Apr 28 09:31:25 2014 +0000
@@ -122,7 +122,7 @@
                 JVM_GetClassModifiers;
                 JVM_GetClassName;
                 JVM_GetClassNameUTF;
-		JVM_GetClassSignature;
+                JVM_GetClassSignature;
                 JVM_GetClassSigners;
                 JVM_GetClassTypeAnnotations;
                 JVM_GetComponentType;
@@ -163,6 +163,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/make/aix/makefiles/mapfile-vers-product	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/aix/makefiles/mapfile-vers-product	Mon Apr 28 09:31:25 2014 +0000
@@ -161,6 +161,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/make/bsd/makefiles/mapfile-vers-darwin-debug	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/bsd/makefiles/mapfile-vers-darwin-debug	Mon Apr 28 09:31:25 2014 +0000
@@ -161,6 +161,7 @@
                 _JVM_GetStackTraceElement
                 _JVM_GetSystemPackage
                 _JVM_GetSystemPackages
+                _JVM_GetTemporaryDirectory
                 _JVM_GetThreadStateNames
                 _JVM_GetThreadStateValues
                 _JVM_GetVersionInfo
--- a/hotspot/make/bsd/makefiles/mapfile-vers-darwin-product	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/bsd/makefiles/mapfile-vers-darwin-product	Mon Apr 28 09:31:25 2014 +0000
@@ -161,6 +161,7 @@
                 _JVM_GetStackTraceElement
                 _JVM_GetSystemPackage
                 _JVM_GetSystemPackages
+                _JVM_GetTemporaryDirectory
                 _JVM_GetThreadStateNames
                 _JVM_GetThreadStateValues
                 _JVM_GetVersionInfo
--- a/hotspot/make/bsd/makefiles/mapfile-vers-debug	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/bsd/makefiles/mapfile-vers-debug	Mon Apr 28 09:31:25 2014 +0000
@@ -122,7 +122,7 @@
                 JVM_GetClassModifiers;
                 JVM_GetClassName;
                 JVM_GetClassNameUTF;
-		JVM_GetClassSignature;
+                JVM_GetClassSignature;
                 JVM_GetClassSigners;
                 JVM_GetClassTypeAnnotations;
                 JVM_GetComponentType;
@@ -163,6 +163,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/make/bsd/makefiles/mapfile-vers-product	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/bsd/makefiles/mapfile-vers-product	Mon Apr 28 09:31:25 2014 +0000
@@ -163,6 +163,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/make/linux/makefiles/mapfile-vers-debug	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/linux/makefiles/mapfile-vers-debug	Mon Apr 28 09:31:25 2014 +0000
@@ -122,7 +122,7 @@
                 JVM_GetClassModifiers;
                 JVM_GetClassName;
                 JVM_GetClassNameUTF;
-		JVM_GetClassSignature;
+                JVM_GetClassSignature;
                 JVM_GetClassSigners;
                 JVM_GetClassTypeAnnotations;
                 JVM_GetComponentType;
@@ -163,6 +163,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/make/linux/makefiles/mapfile-vers-product	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/linux/makefiles/mapfile-vers-product	Mon Apr 28 09:31:25 2014 +0000
@@ -163,6 +163,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/make/solaris/makefiles/mapfile-vers	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/make/solaris/makefiles/mapfile-vers	Mon Apr 28 09:31:25 2014 +0000
@@ -163,6 +163,7 @@
                 JVM_GetStackTraceElement;
                 JVM_GetSystemPackage;
                 JVM_GetSystemPackages;
+                JVM_GetTemporaryDirectory;
                 JVM_GetThreadStateNames;
                 JVM_GetThreadStateValues;
                 JVM_GetVersionInfo;
--- a/hotspot/src/share/vm/prims/jvm.cpp	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/src/share/vm/prims/jvm.cpp	Mon Apr 28 09:31:25 2014 +0000
@@ -386,6 +386,23 @@
 JVM_END
 
 
+/*
+ * Return the temporary directory that the VM uses for the attach
+ * and perf data files.
+ *
+ * It is important that this directory is well-known and the
+ * same for all VM instances. It cannot be affected by configuration
+ * variables such as java.io.tmpdir.
+ */
+JVM_ENTRY(jstring, JVM_GetTemporaryDirectory(JNIEnv *env))
+  JVMWrapper("JVM_GetTemporaryDirectory");
+  HandleMark hm(THREAD);
+  const char* temp_dir = os::get_temp_directory();
+  Handle h = java_lang_String::create_from_platform_dependent_str(temp_dir, CHECK_NULL);
+  return (jstring) JNIHandles::make_local(env, h());
+JVM_END
+
+
 // java.lang.Runtime /////////////////////////////////////////////////////////////////////////
 
 extern volatile jint vm_created;
--- a/hotspot/src/share/vm/prims/jvm.h	Sun Apr 27 18:57:56 2014 +0200
+++ b/hotspot/src/share/vm/prims/jvm.h	Mon Apr 28 09:31:25 2014 +0000
@@ -1485,6 +1485,9 @@
 JNIEXPORT jobject JNICALL
 JVM_InitAgentProperties(JNIEnv *env, jobject agent_props);
 
+JNIEXPORT jstring JNICALL
+JVM_GetTemporaryDirectory(JNIEnv *env);
+
 /* Generics reflection support.
  *
  * Returns information about the given class's EnclosingMethod