RFR: 8354727: CompilationPolicy creates too many compiler threads when code cache space is scarce [v2]
    Manuel Hässig 
    mhaessig at openjdk.org
       
    Thu Jun 12 09:35:19 UTC 2025
    
    
  
On Thu, 12 Jun 2025 09:03:19 GMT, Damon Fenacci <dfenacci at openjdk.org> wrote:
>> Manuel Hässig has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix inadvertantly removed header
>>   
>>   Co-developed-by: Damon Fenacci <dfenacci at openjdk.org>
>
> Thanks for fixing this @mhaessig.
> I guess the issue cannot happen if `NonNMethodCodeHeapSize` is not given as a flag as it will be dynamically adapted to the number of compiler threads created, right?
Thank you for having a look @dafedafe!
> I guess the issue cannot happen if NonNMethodCodeHeapSize is not given as a flag as it will be dynamically adapted to the number of compiler threads created, right?
That is right. In this case, the heuristics in `CodeCache::initialize_heaps()` take over.
> src/hotspot/share/compiler/compilationPolicy.cpp line 40:
> 
>> 38: #include "runtime/deoptimization.hpp"
>> 39: #include "runtime/flags/debug_globals.hpp"
>> 40: #include "runtime/frame.hpp"
> 
> Was this removed on purpose? It isn't used directly but doesn't seem to be related to your change...
Thank you for pointing this out. No, this is a blunder on my part.  I fixed it in b62ef8a.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/25770#issuecomment-2965861219
PR Review Comment: https://git.openjdk.org/jdk/pull/25770#discussion_r2142185964
    
    
More information about the hotspot-compiler-dev
mailing list