RFR: 8355364: [REDO] Missing REX2 prefix accounting in ZGC barriers leads to incorrect encoding
Jatin Bhateja
jbhateja at openjdk.org
Wed Apr 30 01:46:49 UTC 2025
On Tue, 29 Apr 2025 19:31:46 GMT, Quan Anh Mai <qamai at openjdk.org> wrote:
> I think it is more future-proof to enhance the relocation information with the offset of the exact relocation patch from the instruction start instead. I also don't agree with adding `nop` to the fast path, especially `uncolor` is used in the load fast path IIUC.
Thanks for supporting this idea, specializing barrier relocation is an alternative we already discussed, but it may not be able shield against false mapping with subsequent relocatable instruction which is what is causing crash currently.
https://mail.openjdk.org/pipermail/hotspot-compiler-dev/2025-April/088895.html
@dean-long's suggestion to map a relocation to exact patch site was a fullproof solution overcome any such limitation, but it may pose problems while querying/iterating over relocation set against starting address of instruction and is a bigger change which we plan to address with after evaluation and considering alternative scheme https://bugs.openjdk.org/browse/JDK-8355341
Current scheme of adding relocation from end of instruction is not robust either to prevent incorrect mapping with subsequent relocatable instruction, NOP is not dispatched to execution unit by add additional byte to code cache.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/24919#issuecomment-2840602447
More information about the hotspot-dev
mailing list