On Fri, 17 Apr 2026 09:41:34 GMT, Stefan Karlsson <[email protected]> wrote:

>> src/hotspot/share/interpreter/oopMapCache.cpp line 157:
>> 
>>> 155:   if (has_valid_mask() && mask_size() > small_mask_limit) {
>>> 156:     assert(_bit_mask[0] != 0, "should have pointer to C heap");
>>> 157:     FREE_C_HEAP_ARRAY((uintptr_t*)_bit_mask[0]);
>> 
>> ?
>
> I should have mentioned what this is. This part of the code puts a 
> (uintptr_t*) in the first element of _bit_mask if the bit mask is too large 
> to fit the static _bit_mask array. It is messing with the type system and we 
> should probably rewrite this to use a union instead.

Sorry for not being clear about this, and I should have removed this comment. I 
did look at this after writing the comment and before submitting my review, and 
have the same impression that this should be a union or something. This is 
really ugly.
Extra CR is totally fine.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/30786#discussion_r3100349161

Reply via email to