RFR: 8359227: Code cache/heap size options should be size_t [v2]
Kim Barrett
kbarrett at openjdk.org
Fri Jun 13 21:14:35 UTC 2025
On Fri, 13 Jun 2025 12:29:59 GMT, Manuel Hässig <mhaessig at openjdk.org> wrote:
>> Kim Barrett has updated the pull request incrementally with two additional commits since the last revision:
>>
>> - update copyrights
>> - remove leftover <type_traits> include
>
> src/hotspot/share/jvmci/jvmciCompilerToVMInit.cpp line 61:
>
>> 59:
>> 60: #include <type_traits>
>> 61:
>
> Is this related to this change? I cannot find any usages from this header in the diff.
Oops. Leftover from an abandoned idea. Removed now.
> src/hotspot/share/runtime/arguments.cpp line 2451:
>
>> 2449: return JNI_EINVAL;
>> 2450: }
>> 2451: if (FLAG_SET_CMDLINE(ReservedCodeCacheSize, (size_t)long_ReservedCodeCacheSize) != JVMFlag::SUCCESS) {
>
> Is this cast correct on a 32-bit platform, where `size_t` is not the same as `uint64_t`?
This isn't any different from the previous code, as uintx is also a 32/64 bit
type on 32/64 bit platforms. And it's fine, as the default for the maximum
value for parse_memory_size is max_uintx.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/25791#discussion_r2146097179
PR Review Comment: https://git.openjdk.org/jdk/pull/25791#discussion_r2146097889
More information about the graal-dev
mailing list