RFR: 8352112: [ubsan] hotspot/share/code/relocInfo.cpp:130:37: runtime error: applying non-zero offset 18446744073709551614 to null pointer
Boris Ulasevich
bulasevich at openjdk.org
Tue Mar 18 23:40:06 UTC 2025
On Tue, 18 Mar 2025 21:49:53 GMT, Vladimir Kozlov <kvn at openjdk.org> wrote:
> So why not do that by setting valid address to _mutable_data and done?
Yes. We already have _immutable_data set to blob_end(). By setting _mutable_data to the same value, we align code with _immutable_data and eliminate the UBSAN error, and there's no need to modify RelocIterator.
> Actually I can do this (in both constructors):
> | - _mutable_data(nullptr),
> | + _mutable_data(header_begin() + size), // default value is blob_end()
> |
> | - _mutable_data = blob_end();
> | + assert(_mutable_data == blob_end(), "sanity");
>
> What do you think?
Good. It seems correct. Thank you!
-------------
PR Comment: https://git.openjdk.org/jdk/pull/24102#issuecomment-2734958828
More information about the hotspot-compiler-dev
mailing list