[10] RFR: 8182037: wrong ResourceMark in Method::print_short_name()
Rahul Raghavan
rahul.v.raghavan at oracle.com
Mon Nov 13 08:59:19 UTC 2017
Hi,
Request help reviewing proposed fix for 8182037.
jbs - https://bugs.openjdk.java.net/browse/JDK-8182037
webrev.01 - http://cr.openjdk.java.net/~rraghavan/8182037/webrev.01/
Notes / jbs extract -
-- "void Method::print_short_name(outputStream* st) {
ResourceMark rm;
breaks if st is not tty and buffer grows under the ResourceMark"
-- "All the printing functions that take an outputStream could
potentially have this problem.
The caller should have the ResourceMark."
-- "All but a couple of the calls to method->print_short_name()
are in compiler code, so reassigning to the compiler."
-- To fix the issue
- Removed ResourceMark from following printing functions -
Method::print_short_name(outputStream* st)
Method::print_name(outputStream* st)
Method::print_on(outputStream* st)
- checked usages of above functions and added ResourceMark to the callers.
(Mach5 testing in progress)
So can this be the correct fix? please tell if I missed some point here.
Thanks,
Rahul
More information about the hotspot-compiler-dev
mailing list