JDK-6604006 : globals.hpp should support non accumulating ccstr arguments
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 7
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: solaris_9
  • CPU: sparc
  • Submitted: 2007-09-12
  • Updated: 2011-03-07
  • Resolved: 2011-03-07
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 6 JDK 7 Other
6u10Fixed 7Fixed hs11Fixed
Related Reports
Relates :  
Relates :  
Description
When defining flags with ccstr arguments the default behaviour is that multiple specifications of the flag cause the definitions to accumulate into an \n separated string.  The is mainly to accomodate things like CompileCommand and CompileOnly which are commonly specified multiple times.  The makes it difficult to make string flags that have non empty default values since specifing the string on the command line will combine the default and new values.  Flags can be set using -XX:foo:=bar which disables the accumulation behaviour but this is error prone.  Some way of distinguishing the need behaviour is needed.  I'm proposing adding a new typedef ccstrlist to distinguish these cases.  Flag of type ccstrlist will have the accumulation behaviour while ccstr flags will replace the old value.

Comments
SUGGESTED FIX Webrev: http://prt-web.sfbay.sun.com/net/prt-archiver.sfbay/data/archived_workspaces/main/c2_baseline/2007/20070913205443.never.6604006.2/workspace/webrevs/webrev-2007.09.13/index.html
14-09-2007

EVALUATION yup.
13-09-2007

SUGGESTED FIX Webrev: http://prt-web.sfbay.sun.com/net/prt-archiver.sfbay/data/archived_workspaces/main/c2_baseline/2007/20070913113153.never.6604006/workspace/webrevs/webrev-2007.09.13/index.html Fixed 6604006: globals.hpp should support non accumulating ccstr arguments When defining flags with ccstr arguments the default behaviour is that multiple specifications of the flag cause the definitions to accumulate into an \n separated string. The is mainly to accomodate things like CompileCommand and CompileOnly which are commonly specified multiple times. The makes it difficult to make string flags that have non empty default values since specifing the string on the command line will combine the default and new values. Flags can be set using -XX:foo:=bar which disables the accumulation behaviour but this is error prone. Some way of requesting different behaviour is needed. I'm proposing adding a new typedef ccstrlist to distinguish these cases. Flag of type ccstrlist will have the accumulation behaviour while ccstr flags will replace the old value. I also added support for specifying the default value as NULL instead of "". I'm fixing this because it's always bugged me and I want more rational behaviour as part of the fix for 6604014. Instead of burying it in that big change I'm pulling this out so it can be seen. I've changed a few flags to make sure the behaviour works correctly since my new flags for 6604014 obviously aren't in this putback. I'm willing to change larger or smaller if that's wanted but I really want some ability to have normal string based flags. Any feedback is welcome. http://javaweb.sfbay/~never/webrev/6604006 Reviewed by: jcoomes, sbohne, kvn Fix verified (y/n): y Exercised paths where the default value changed from "" to NULL
13-09-2007