RFR: 8367981: Refine CompactHashtable comments
    Francesco Andreuzzi 
    fandreuzzi at openjdk.org
       
    Thu Sep 18 11:19:50 UTC 2025
    
    
  
On Thu, 18 Sep 2025 10:53:25 GMT, Hamlin Li <mli at openjdk.org> wrote:
> Hi,
> Can you help to review this patch?
> 
> The comments of CompactHashtable and related classes are out of date, and some comments are unclear, wrong or misleading.
> As the related classes are used in more and more scenarios, it's helpful to update the comments.
> 
> Thanks
src/hotspot/share/classfile/compactHashtable.cpp line 195:
> 193: size_t SimpleCompactHashtable::calculate_header_size() {
> 194:   // We have 5 fields. Each takes up sizeof(intptr_t). See WriteClosure::do_u4
> 195:   constexpr size_t bytes = sizeof(intptr_t) * 5;
The whole method could perhaps become a `constexpr`
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/27360#discussion_r2358666947
    
    
More information about the hotspot-runtime-dev
mailing list