On Mon, 20 Jun 2022 23:56:51 GMT, David Holmes <dhol...@openjdk.org> wrote:

> Hi Coleen,
> 
> The changes in themselves seem fine to me - I only skimmed things, mainly 
> looking at the new files. It is a very large refactoring so there will be an 
> impact on backports naturally.
> 
> I'm not sure this will save much in terms of build time inclusions (how many 
> files only include thread.hpp now?) but the code structure/management 
> benefits of this are more important anyway. (Though I must confess in a 
> remote terminal using vi I appreciate everything being in one file. :) ).
> 
> Thanks.

Currently, as counted by 
https://urldefense.com/v3/__https://github.com/iklam/tools/blob/main/headers/whoincludes.tcl__;!!ACWV5N9M2RV99hQ!LFYYC1U1YK-eB0GKVLJ8WGVx9WsiPp2mqAV6JIra3xd9dLnINJ19B7iTEH1IxFu1-BW5xwZfgiy6xcDLo-iX962twg$
 , there isn't much improvement in terms of build time:

Before this PR:
- thread.hpp was included 847 times

After this PR
- thread.hpp is included 848 times
- javaThread.hpp is included 843 times

One reason is in handles.hpp, which has implicit conversion from `JavaThread*` 
to `Thread*`. E.g., when you have:


void blah(TRAPS) {
    Handle h(THREAD, someOop);
   . ..
}


Anyway, I think this PR is a very important step towards faster build time. We 
can do further refactoring. E.g., avoid including handles.hpp unnecessarily in 
other .hpp files (and move offenders from .hpp to .inline.hpp, etc).

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

PR: https://git.openjdk.org/jdk/pull/9218

Reply via email to