RFR(XS): 8132980: Improve stability of whitebox methods getCodeBlob and freeCodeBlob (original) (raw)

Kirill Zhaldybin kirill.zhaldybin at oracle.com
Wed Sep 9 17:25:17 UTC 2015


Stanislav,

"addr == 0" in freeCodeBlob is just ignored since it's traditional for C/C++ to allow free(0) but when we are trying to read something from addr == 0 in getCodeBlob it looks like error (and crash JVM actually).

Thank you.

Regards. Kirill

On 09.09.2015 19:42, Stas Smirnov wrote:

Hi,

changes looks good, one small remark, in one case when "addr == 0" you just make a return and in another case you THROWMSGNULL is there any specific reason for a different way of handling the same condition? On 08.09.2015 19:37, Kirill Zhaldybin wrote: Hi!

Could you please review the following patch for WB methods? I added checks for negative size and null address values (where applicable) for getCodeBlob, allocateCodeBlob and freeCodeBlob, added regression test. CR: https://bugs.openjdk.java.net/browse/JDK-8132980 Webrev: hotspot: http://cr.openjdk.java.net/~kzhaldyb/webrevs/JDK-8132980/webrev.00/ Thanks, Kirill



More information about the hotspot-dev mailing list