# HG changeset patch # User bobv # Date 1286478777 14400 # Node ID 4ef36b2a6a3ae786ddf20fc24b05975c69d818ae # Parent a32b2fc663218aff42855ec01b88f70893f1a647 6989297: Integrate additional portability improvements Reviewed-by: vladidan, dholmes diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/cpu/sparc/vm/globals_sparc.hpp --- a/hotspot/src/cpu/sparc/vm/globals_sparc.hpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/cpu/sparc/vm/globals_sparc.hpp Thu Oct 07 15:12:57 2010 -0400 @@ -62,3 +62,5 @@ define_pd_global(bool, RewriteBytecodes, true); define_pd_global(bool, RewriteFrequentPairs, true); + +define_pd_global(bool, UseMembar, false); diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/cpu/x86/vm/globals_x86.hpp --- a/hotspot/src/cpu/x86/vm/globals_x86.hpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/cpu/x86/vm/globals_x86.hpp Thu Oct 07 15:12:57 2010 -0400 @@ -63,3 +63,5 @@ define_pd_global(bool, RewriteBytecodes, true); define_pd_global(bool, RewriteFrequentPairs, true); + +define_pd_global(bool, UseMembar, false); diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/cpu/x86/vm/methodHandles_x86.cpp --- a/hotspot/src/cpu/x86/vm/methodHandles_x86.cpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/cpu/x86/vm/methodHandles_x86.cpp Thu Oct 07 15:12:57 2010 -0400 @@ -346,7 +346,7 @@ if (stack_dump_count > 64) stack_dump_count = 48; for (i = 0; i < stack_dump_count; i += 4) { printf(" dump at SP[%d] "INTPTR_FORMAT": "INTPTR_FORMAT" "INTPTR_FORMAT" "INTPTR_FORMAT" "INTPTR_FORMAT"\n", - i, &entry_sp[i+0], entry_sp[i+0], entry_sp[i+1], entry_sp[i+2], entry_sp[i+3]); + i, (intptr_t)&entry_sp[i+0], entry_sp[i+0], entry_sp[i+1], entry_sp[i+2], entry_sp[i+3]); } print_method_handle(mh); } diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/cpu/zero/vm/globals_zero.hpp --- a/hotspot/src/cpu/zero/vm/globals_zero.hpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/cpu/zero/vm/globals_zero.hpp Thu Oct 07 15:12:57 2010 -0400 @@ -45,3 +45,5 @@ define_pd_global(bool, RewriteBytecodes, true); define_pd_global(bool, RewriteFrequentPairs, true); + +define_pd_global(bool, UseMembar, false); diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/os/linux/vm/attachListener_linux.cpp --- a/hotspot/src/os/linux/vm/attachListener_linux.cpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/os/linux/vm/attachListener_linux.cpp Thu Oct 07 15:12:57 2010 -0400 @@ -176,10 +176,10 @@ int n = snprintf(path, UNIX_PATH_MAX, "%s/.java_pid%d", os::get_temp_directory(), os::current_process_id()); - if (n <= (int)UNIX_PATH_MAX) { + if (n < (int)UNIX_PATH_MAX) { n = snprintf(initial_path, UNIX_PATH_MAX, "%s.tmp", path); } - if (n > (int)UNIX_PATH_MAX) { + if (n >= (int)UNIX_PATH_MAX) { return -1; } diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/share/vm/includeDB_core --- a/hotspot/src/share/vm/includeDB_core Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/share/vm/includeDB_core Thu Oct 07 15:12:57 2010 -0400 @@ -3229,6 +3229,7 @@ orderAccess.hpp os.hpp orderAccess_.inline.hpp orderAccess.hpp +orderAccess_.inline.hpp vm_version_.hpp os.cpp allocation.inline.hpp os.cpp arguments.hpp diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/share/vm/runtime/globals.hpp --- a/hotspot/src/share/vm/runtime/globals.hpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/share/vm/runtime/globals.hpp Thu Oct 07 15:12:57 2010 -0400 @@ -323,10 +323,10 @@ /* UseMembar is theoretically a temp flag used for memory barrier \ * removal testing. It was supposed to be removed before FCS but has \ * been re-added (see 6401008) */ \ - product(bool, UseMembar, false, \ + product_pd(bool, UseMembar, \ "(Unstable) Issues membars on thread state transitions") \ \ - /* Temporary: See 6948537 */ \ + /* Temporary: See 6948537 */ \ experimental(bool, UseMemSetInBOT, true, \ "(Unstable) uses memset in BOT updates in GC code") \ \ diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/share/vm/runtime/sharedRuntime.cpp --- a/hotspot/src/share/vm/runtime/sharedRuntime.cpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/share/vm/runtime/sharedRuntime.cpp Thu Oct 07 15:12:57 2010 -0400 @@ -302,6 +302,9 @@ return (f <= (double)0.0) ? (double)0.0 - f : f; } +#endif + +#if defined(__SOFTFP__) || defined(PPC) double SharedRuntime::dsqrt(double f) { return sqrt(f); } diff -r a32b2fc66321 -r 4ef36b2a6a3a hotspot/src/share/vm/runtime/sharedRuntime.hpp --- a/hotspot/src/share/vm/runtime/sharedRuntime.hpp Thu Sep 30 12:05:08 2010 -0400 +++ b/hotspot/src/share/vm/runtime/sharedRuntime.hpp Thu Oct 07 15:12:57 2010 -0400 @@ -116,6 +116,9 @@ #if defined(__SOFTFP__) || defined(E500V2) static double dabs(double f); +#endif + +#if defined(__SOFTFP__) || defined(PPC) static double dsqrt(double f); #endif