RFR: 8293873: Centralize the initialization of UL

Johan Sjölen jsjolen at openjdk.org
Tue Sep 20 12:48:40 UTC 2022


On Fri, 16 Sep 2022 16:20:12 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

> > but it might change how UL works before VM start up
> 
> This is a bit vague :)
> 
> How exactly does UL initialization change? Does it move? If yes, what happens if we log now before initialization?

That's fair enough :-).

There are 3 times for UL:
- (a) logging does nothing
- (b) severe enough logging is redirected to stdout
- (c) UL is initialized according to user supplied options (including being disabled).

And this is a timeline showing how initialization has changed between before and after this change:


Time -->
    static init                main     LC::init            Args::parse                             VM init done
|---------------------|------------------|-----------------|--------------------------------------|
         (a)                         (b)                                    (c)
|-------------------- |------------------------------------|--------------------------------------| Old way
                    (a)                         (b)                         (c)
|----------------------------------------|-----------------|---------------------------------------| New way


So the time where (a) holds has lengthened, and the time that (b) holds has been shortened.

I'd like to entirely remove (b) in a future PR, because certain applications depend on them controlling stdout/stderr completely. Furthermore, I haven't been able to show that the JVM even depends on (b) being available.

Does this illustration make sense?

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

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


More information about the hotspot-runtime-dev mailing list