[9] RFR(S): 8056067: NodeHash debug variables are available in product build

Tobias Hartmann tobias.hartmann at oracle.com
Thu Aug 28 12:24:41 UTC 2014


please review the following patch that fixes JDK-8056067.

Bug: https://bugs.openjdk.java.net/browse/JDK-8056067
Webrev: http://cr.openjdk.java.net/~thartmann/8056067/webrev.00/

Some members of NodeHash are only needed in debug/optimized builds but 
are also available in product. For example, '_grows' is incremented in 
'NodeHash::grow' but only accessed for debugging in NodeHash::dump(). 
Other members like '_look_probes' are only maintained in debug and 
therefore contain no information in product and optimized (see [1]).

Make variables only available in debug/optimized.

- Checked output of 'java -XX:+PrintCompilation -XX:+PrintOptoStatistics 
-XX:+Verbose' with fastdebug, optimized and product build


Output of java -XX:+PrintCompilation -XX:+PrintOptoStatistics -XX:+Verbose

fastdebug build:
GVN Hash stats: 0 grows to 512 max_size
   28/512 ( 5.5% full)
   30p/(0h+36m) ( 0.83 probes/lookup)
   0p/28i ( 0.00 probes/insert)

optimized build:
GVN Hash stats: 0 grows to 512 max_size
   28/512 ( 5.5% full)
   0p/(0h+0m) ( -nan probes/lookup)
   0p/28i ( 0.00 probes/insert)

The third line of the output shows wrong values with the optimized build.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/hotspot-compiler-dev/attachments/20140828/ad265413/attachment.html>

More information about the hotspot-compiler-dev mailing list