RFR: 8308850: Change JVM options with small ranges from 64 to 32 bits, for globals.hpp
    Dean Long 
    dlong at openjdk.org
       
    Fri Aug  4 22:50:33 UTC 2023
    
    
  
On Fri, 4 Aug 2023 17:41:50 GMT, Afshin Zafari <azafari at openjdk.org> wrote:
> The JVM options that are in range of `int` type are converted in `globals.hpp` and other files where affected.
> 
> ### Tests
> tiers 1-4 passed for linux-x64, linux-x64-debug, windows-x64, windows-x64-debug
> tier1 all passed.
src/hotspot/share/opto/macro.cpp line 1841:
> 1839:       // Generate several prefetch instructions.
> 1840:       int step_size = AllocatePrefetchStepSize;
> 1841:       int distance = AllocatePrefetchDistance;
I think this is a step in the wrong direction.  Shouldn't these remain uint?
src/hotspot/share/runtime/globals.hpp line 1258:
> 1256:           range(1, 64)                                                      \
> 1257:                                                                             \
> 1258:   product(int,  AllocatePrefetchStepSize, 16,                               \
I feel like uint is more correct for most of these.
src/hotspot/share/runtime/globals.hpp line 1590:
> 1588:           "switch")                                                         \
> 1589:                                                                             \
> 1590:   develop(int, StopInterpreterAt, 0,                                        \
Some cpu ports access this from assembly, so changing the size is gong to require cpu-specific changes.  I'd rather see this and BytecodeCounter::_counter_value both changed to uint64_t.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15164#discussion_r1284893943
PR Review Comment: https://git.openjdk.org/jdk/pull/15164#discussion_r1284894485
PR Review Comment: https://git.openjdk.org/jdk/pull/15164#discussion_r1284893634
    
    
More information about the hotspot-dev
mailing list