[Gentle Ping?][8u] RFR: 8260589: Crash in JfrTraceIdLoadBarrier::load(_jclass*)
Long Yang
yibo.yl at alibaba-inc.com
Fri Feb 11 08:41:45 UTC 2022
Anyone willing to review this?
Thanks,
Long Yang (杨龙/义泊)
------------------原始邮件 ------------------
发件人:杨龙(义泊) <yibo.yl at alibaba-inc.com>
发送时间:Wed Jan 12 15:28:06 2022
收件人:jdk8u-dev at openjdk.java.net <jdk8u-dev at openjdk.java.net>
主题:[8u] RFR: 8260589: Crash in JfrTraceIdLoadBarrier::load(_jclass*)
Hi,
I would appreciate it if you could review the backport of JDK-8260589 to 8u.
This crash problem is very easy to reproduce, so I feel it is necessary to backport it to 8u.
Bug: https://bugs.openjdk.java.net/browse/JDK-8260589
11u commit: https://github.com/openjdk/jdk11u-dev/commit/1d204c554ffe969567161cc05992486ff47d346d
8u webrev: https://cr.openjdk.java.net/~ddong/8260589/webrev.00
Test: jdk/test/jdk/jfr/jvm/TestPrimitiveClasses.java passed.
Due to the differences between JFR in 11u and 17, Denghui made some changes when backporting this fix to 11u.
Denghui's changes also apply to 8u, so I directly quote Denghui's list here. (4 in total)
1. use MaxJfrEventId + 101 instead of LAST_TYPE_ID + 1 as the klass id of void.class
2. jdk 11 doesn't support jfr streaming, so I removed the call `JfrTraceIdEpoch::set_changed_tag_state()` in `load_primitive`
3. the Class in jdk 11 doesn't have the field 'hidden', so I removed `writer->write<bool>(false);` in `write_primitive`
4. there are many differences in the API of JfrTraceId between 11u and tip
In addition to the above differences, I also make supplementary explanations for the modifications I made.
1. The static global variable clear_artifacts in 11u was introduced by the bugfix https://bugs.openjdk.java.net/browse/JDK-8231081, but this fix has not been backported to 8u, so I removed the code related to clear_artifacts. In 8u, the metadata of the primitive types will be written into the previous chunk on every chunk rotation.
2. In 11u, _artifacts and _class_unload are static global variables, but in 8u, they are static member variables of JfrTypeSet, so I also made necessary changes to the functions that use these two variables.
Thanks,
Long Yang
More information about the jdk8u-dev
mailing list