RFR: 8359227: Code cache/heap size options should be size_t [v2]

Larry Cable duke at openjdk.org
Mon Jun 16 19:07:30 UTC 2025


On Mon, 16 Jun 2025 18:49:37 GMT, Kim Barrett <kbarrett at openjdk.org> wrote:

>> src/hotspot/share/jvmci/jvmciCompilerToVMInit.cpp line 550:
>> 
>>> 548: #define ADD_SIZE_T_FLAG(name) ADD_FLAG(size_t, name, BOXED_LONG)
>>> 549: #define ADD_INTX_FLAG(name)   ADD_FLAG(intx, name, BOXED_LONG)
>>> 550: #define ADD_UINTX_FLAG(name)  ADD_FLAG(uintx, name, BOXED_LONG)
>> 
>> Suggestion:
>> 
>> #define ADD_BOOL_FLAG(name)   ADD_FLAG(bool,   name, BOXED_BOOLEAN)
>> #define ADD_INT_FLAG(name)    ADD_FLAG(int,    name, BOXED_LONG)
>> #define ADD_SIZE_T_FLAG(name) ADD_FLAG(size_t, name, BOXED_LONG)
>> #define ADD_INTX_FLAG(name)   ADD_FLAG(intx,   name, BOXED_LONG)
>> #define ADD_UINTX_FLAG(name)  ADD_FLAG(uintx,  name, BOXED_LONG)
>> 
>> Feel free to ignore, but since you are already touching this, we might as well align it.
>
> I'd rather not. I'm not a fan of this kind of formatting. I moved the `ADD_FLAG` calls over to
> maintain the pre-existing formatting after adding the longer than anything else `ADD_SIZE_T_FLAG`,
> but the `ADD_FLAG` arguments were not lined up and I'd just as soon leave them that way.

not sure being a fan or not is sufficient reason...

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25791#discussion_r2150671231


More information about the hotspot-dev mailing list