From gbenson at redhat.com Mon Jan 11 03:47:24 2010 From: gbenson at redhat.com (Gary Benson) Date: Mon, 11 Jan 2010 11:47:24 +0000 Subject: Command line options tester, now working Message-ID: <20100111114724.GD6454@redhat.com> Hi all, Back in December I committed a command line options tester that required a patch in order to run. This commit adds that patch. You can test your VM (boolean flags only for now) like this: cd icedtea6 contrib/checkopts/checkopts openjdk-ecj/build/linux-*/j2sdk-image/bin/java Cheers, Gary -- http://gbenson.net/ -------------- next part -------------- diff -r 175b5c7ee4c7 -r 4b6ab0e5a0dd ChangeLog --- a/ChangeLog Wed Jan 06 16:40:43 2010 -0500 +++ b/ChangeLog Mon Jan 11 11:43:43 2010 +0000 @@ -1,3 +1,10 @@ +2010-01-11 Gary Benson + + * patches/zero/6914622.patch: New file, imports changeset + for Sun bug 6914622 from jdk7/hotspot-comp. + * Makefile.am (ICEDTEA_PATCHES): Added the above. + * contrib/checkopts/checkopts: Updated for the above. + 2010-01-06 Deepak Bhole * plugin/icedteanp/IcedTeaNPPlugin.h: Remove debug specific line from diff -r 175b5c7ee4c7 -r 4b6ab0e5a0dd Makefile.am --- a/Makefile.am Wed Jan 06 16:40:43 2010 -0500 +++ b/Makefile.am Mon Jan 11 11:43:43 2010 +0000 @@ -201,6 +201,7 @@ patches/zero/6903453.patch \ patches/zero/6909153.patch \ patches/zero/6913869.patch \ + patches/zero/6914622.patch \ patches/icedtea-notice-safepoints.patch \ patches/icedtea-parisc-opt.patch \ patches/icedtea-lucene-crash.patch \ diff -r 175b5c7ee4c7 -r 4b6ab0e5a0dd contrib/checkopts/checkopts --- a/contrib/checkopts/checkopts Wed Jan 06 16:40:43 2010 -0500 +++ b/contrib/checkopts/checkopts Mon Jan 11 11:43:43 2010 +0000 @@ -23,6 +23,7 @@ def test_values(self): if self.type == "bool": if self.name in ( + "PrintFlagsInitial", # already done :) "ExtendedDTraceProbes", # Solaris only "RequireSharedSpaces", # Not set up "PauseAtStartup"): # Just don't... @@ -62,7 +63,9 @@ def read_flags(self): out, err = subprocess.Popen( - [self.java, "-XX:+UnlockDiagnosticVMOptions", "-Xprintflags"], + [self.java, + "-XX:+UnlockDiagnosticVMOptions", + "-XX:+PrintFlagsInitial"], stdout = subprocess.PIPE, stderr = subprocess.PIPE).communicate() if err: diff -r 175b5c7ee4c7 -r 4b6ab0e5a0dd patches/zero/6914622.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/zero/6914622.patch Mon Jan 11 11:43:43 2010 +0000 @@ -0,0 +1,98 @@ +diff -r 9b9c1ee9b3f6 -r f62a22282a47 src/share/vm/runtime/arguments.cpp +--- openjdk/hotspot/src/share/vm/runtime/arguments.cpp Wed Jan 06 22:21:39 2010 -0800 ++++ openjdk/hotspot/src/share/vm/runtime/arguments.cpp Thu Jan 07 16:24:17 2010 -0800 +@@ -2633,6 +2633,10 @@ + if (match_option(option, "-XX:-IgnoreUnrecognizedVMOptions", &tail)) { + IgnoreUnrecognizedVMOptions = false; + } ++ if (match_option(option, "-XX:+PrintFlagsInitial", &tail)) { ++ CommandLineFlags::printFlags(); ++ vm_exit(0); ++ } + } + + if (IgnoreUnrecognizedVMOptions) { +@@ -2795,11 +2799,9 @@ + CommandLineFlags::printSetFlags(); + } + +-#ifdef ASSERT + if (PrintFlagsFinal) { + CommandLineFlags::printFlags(); + } +-#endif + + return JNI_OK; + } +diff -r 9b9c1ee9b3f6 -r f62a22282a47 src/share/vm/runtime/globals.cpp +--- openjdk/hotspot/src/share/vm/runtime/globals.cpp Wed Jan 06 22:21:39 2010 -0800 ++++ openjdk/hotspot/src/share/vm/runtime/globals.cpp Thu Jan 07 16:24:17 2010 -0800 +@@ -468,6 +468,8 @@ + assert(Arguments::check_vm_args_consistency(), "Some flag settings conflict"); + } + ++#endif // PRODUCT ++ + void CommandLineFlags::printFlags() { + // Print the flags sorted by name + // note: this method is called before the thread structure is in place +@@ -493,5 +495,3 @@ + } + FREE_C_HEAP_ARRAY(Flag*, array); + } +- +-#endif +diff -r 9b9c1ee9b3f6 -r f62a22282a47 src/share/vm/runtime/globals.hpp +--- openjdk/hotspot/src/share/vm/runtime/globals.hpp Wed Jan 06 22:21:39 2010 -0800 ++++ openjdk/hotspot/src/share/vm/runtime/globals.hpp Thu Jan 07 16:24:17 2010 -0800 +@@ -211,7 +211,7 @@ + static bool wasSetOnCmdline(const char* name, bool* value); + static void printSetFlags(); + +- static void printFlags() PRODUCT_RETURN; ++ static void printFlags(); + + static void verify() PRODUCT_RETURN; + }; +@@ -327,9 +327,6 @@ + product(bool, UseMembar, false, \ + "(Unstable) Issues membars on thread state transitions") \ + \ +- product(bool, PrintCommandLineFlags, false, \ +- "Prints flags that appeared on the command line") \ +- \ + diagnostic(bool, UnlockDiagnosticVMOptions, trueInDebug, \ + "Enable normal processing of flags relating to field diagnostics")\ + \ +@@ -1967,9 +1964,6 @@ + "number of times a GC thread (minus the coordinator) " \ + "will sleep while yielding before giving up and resuming GC") \ + \ +- notproduct(bool, PrintFlagsFinal, false, \ +- "Print all command line flags after argument processing") \ +- \ + /* gc tracing */ \ + manageable(bool, PrintGC, false, \ + "Print message at garbage collect") \ +@@ -2269,11 +2263,20 @@ + "If false, restricts profiled locations to the root method only") \ + \ + product(bool, PrintVMOptions, trueInDebug, \ +- "print VM flag settings") \ ++ "Print flags that appeared on the command line") \ + \ + product(bool, IgnoreUnrecognizedVMOptions, false, \ + "Ignore unrecognized VM options") \ + \ ++ product(bool, PrintCommandLineFlags, false, \ ++ "Print flags specified on command line or set by ergonomics") \ ++ \ ++ product(bool, PrintFlagsInitial, false, \ ++ "Print all VM flags before argument processing and exit VM") \ ++ \ ++ product(bool, PrintFlagsFinal, false, \ ++ "Print all VM flags after argument and ergonomic processing") \ ++ \ + diagnostic(bool, SerializeVMOutput, true, \ + "Use a mutex to serialize output to tty and hotspot.log") \ + \ From xerxes at zafena.se Fri Jan 15 06:14:18 2010 From: xerxes at zafena.se (=?ISO-8859-1?Q?Xerxes_R=E5nby?=) Date: Fri, 15 Jan 2010 15:14:18 +0100 Subject: [patch] PR428 - remove -pedantic from LLVM_CFLAGS on Shark builds Message-ID: <4B50783A.4060509@zafena.se> The attached patch removes -pedantic from LLVM_CFLAGS to fix PR428 http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=428 ok to push to icedtea6? ok to push to icedtea? ChangeLog message: 2010-01-15 Xerxes R?nby PR icedtea/428: * configure.ac (LLVM_CFLAGS): Remove -pedantic from LLVM_CFLAGS. Cheers and have a great day! Xerxes Index: icedtea6/configure.ac =================================================================== --- icedtea6.orig/configure.ac 2010-01-15 14:55:53.000000000 +0100 +++ icedtea6/configure.ac 2010-01-15 14:58:14.000000000 +0100 @@ -607,7 +607,7 @@ llvm_components="jit engine nativecodegen" LLVM_CFLAGS=`$LLVM_CONFIG --cxxflags $llvm_components | \ sed -e 's/-O.//g' | sed -e 's/-fomit-frame-pointer//g' | \ - sed -e 's/-D_DEBUG//g'` + sed -e 's/-pedantic//g' | sed -e 's/-D_DEBUG//g'` LLVM_CFLAGS="$LLVM_CFLAGS -DSHARK_LLVM_VERSION=`$LLVM_CONFIG --version | sed 's/\.//;s/svn.*//'`" LLVM_LDFLAGS=`$LLVM_CONFIG --ldflags $llvm_components` LLVM_LIBS=`$LLVM_CONFIG --libs $llvm_components` From gbenson at redhat.com Fri Jan 15 06:31:53 2010 From: gbenson at redhat.com (Gary Benson) Date: Fri, 15 Jan 2010 14:31:53 +0000 Subject: [patch] PR428 - remove -pedantic from LLVM_CFLAGS on Shark builds In-Reply-To: <4B50783A.4060509@zafena.se> References: <4B50783A.4060509@zafena.se> Message-ID: <20100115143153.GB3485@redhat.com> Xerxes R?nby wrote: > The attached patch removes -pedantic from LLVM_CFLAGS to fix PR428 > http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=428 > > ok to push to icedtea6? Yes please. > ok to push to icedtea? I expect so. Cheers, Gary -- http://gbenson.net/