RFR(xs): 8150619: Improve thread based logging introduced with 8149036

Thomas Stüfe thomas.stuefe at gmail.com
Thu Feb 25 13:19:52 UTC 2016

Hi all,

please review and sponsor this tiny addition to 8149036. These are some
tiny cleanups which could not be added to the original change anymore
because it was already pushed.

bug: https://bugs.openjdk.java.net/browse/JDK-8150619

Original mail thread for 8149036:

The change unifies the logging messages for all platforms and all log sites
as much as possible.

Please note: "tid" always refers to whatever os::current_thread_id()
returns. This may be a pthread_t (AIX, BSD), a kernel thread id or similar
(Mac, Linux, Solaris), or a windows thread id. Beside printing the "tid", I
print out additional thread ids where it may be interesting, especially at
thread start and attach. On AIX, I print the kernel thread id, on
Linux/Mac, the pthread id.

There are some instances where I have only one and not the other:
- after a call to pthread_create(), I only have the pthread id of the
newborn thread, not the kernel thread id, so this is all I can print.
- in shared code, all I have or all I can print without making the code to
complicated is the "tid"

Finally, the change adds a jtreg test to logging, to test the new logging

Thanks & Kind Regards, Thomas

More information about the hotspot-runtime-dev mailing list