diff options
| author | Greg Lewis <glewis@FreeBSD.org> | 2007-09-20 03:35:30 +0000 |
|---|---|---|
| committer | Greg Lewis <glewis@FreeBSD.org> | 2007-09-20 03:35:30 +0000 |
| commit | 260ffa12c0f108eb67999015df3fe0328aec4e3d (patch) | |
| tree | 70d3a17af379c40502057ac848174b70d764b447 /java/jdk15/files/patch-vm::globals.hpp | |
| parent | There's a whole bunch of class builders out there. In fact, creating a (diff) | |
. Default UseThreadPriorities to false on BSD. This can be toggled by
passing -XX:+UseThreadPriorities.
. Remove the os_sleep hack which was used on FreeBSD to make sure lower
priority threads got time slices. Instead, just call pthread_yield().
On FreeBSD 7.x with libthr, this will still give lower priority threads
some time (with the above flag turned on), although such behaviour is
not guaranteed by POSIX. This boosts FreeBSD performance by 7-fold on
an 8 core system, putting it on a par with Solaris (benchmarks by kris@).
The Java standard and the JCK tests are somewhat contradictory on thread
priority being guaranteed to work, and in this case the performance
benefits appear to outweigh any possible side effects.
. Pick up DEFAULT_LD_LIBRARY_PATH from the build environment rather than
patching it into a file at build time. This simplifies the Makefile.
Submitted by: Kurt Miller <kurt@intricatesoftware.com>
Diffstat (limited to 'java/jdk15/files/patch-vm::globals.hpp')
| -rw-r--r-- | java/jdk15/files/patch-vm::globals.hpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/java/jdk15/files/patch-vm::globals.hpp b/java/jdk15/files/patch-vm::globals.hpp new file mode 100644 index 000000000000..04d6c38413ed --- /dev/null +++ b/java/jdk15/files/patch-vm::globals.hpp @@ -0,0 +1,26 @@ +$FreeBSD$ + +--- ../../hotspot/src/share/vm/runtime/globals.hpp.orig Wed May 2 04:01:50 2007 ++++ ../../hotspot/src/share/vm/runtime/globals.hpp Tue Sep 18 21:40:44 2007 +@@ -130,6 +130,12 @@ + #define falseInProduct true + #endif + ++#if defined(_ALLBSD_SOURCE) ++#define OSUseThreadPriorities false ++#else ++#define OSUseThreadPriorities true ++#endif ++ + // develop flags are settable / visible only during development and are constant in the PRODUCT version + // product flags are always settable / visible + +@@ -2546,7 +2552,7 @@ + "beginning to throw OutOfMemoryErrors in each compile") \ + \ + /* Priorities */ \ +- product(bool, UseThreadPriorities, true, \ ++ product(bool, UseThreadPriorities, OSUseThreadPriorities, \ + "Use native thread priorities") \ + \ + product(intx, ThreadPriorityPolicy, 0, \ |
