RFR: 8362504: AArch64: Replace MOVZ+MOVK+MOVK with ADRP+ADD
Vladimir Kozlov
kvn at openjdk.org
Wed Aug 20 14:58:41 UTC 2025
On Wed, 20 Aug 2025 14:31:50 GMT, Andrew Dinn <adinn at openjdk.org> wrote:
> Would it make sense to disable the reachability-based optimization when AOTCodeCache::is_on() returns true?
AOTCodeCache::_cache is set in AOTCodeCache::init2() which is called after universe_init() and some stubs are generated. There are runtime calls in stubs which we may need to adjust using temporary `cache` value created in AOTCodeCache::initialize(). So we can't rely on AOTCodeCache::is_on() in production run for this.
Yes, it is complicated "dance" to make sure AOT is working properly.
We can use AOTCodeCache::is_caching_enabled() instead which simple checks flags set during flags parsing.
But it also not reliable because flags could be adjust later when we later load AOT code cache and check its compatibility.
I agree with both Andrews that this change seems don't provide much benefits to accept it.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/26653#issuecomment-3206768915
More information about the hotspot-dev
mailing list