We don't need jdk.internal.ref.Cleaner any more

Mandy Chung mandy.chung at oracle.com
Tue Feb 16 23:52:20 UTC 2016

> On Feb 15, 2016, at 9:24 PM, David Holmes <david.holmes at oracle.com> wrote:
>> This patch looks correct to me.  The innocuous thread created for common cleaner is of Thread.MAX_PRIORITY - 2 priority whereas the reference handler thread is of MAX_PRIORITY priority.   I don’t know if this would impact any real-world application or whether worth having a dedicated thread with MAX_PRIORTY (David Holmes may have recommendation to this).
> How did you know I would read this? :)

Magic ball :)

> Thread priority has no meaning on Solaris, Linux or BSD/OSX by default.
> Only Windows actually applies thread priorities under normal conditions. The difference between MAX_PRIORITY and MAX_PRIORITY-2 is the former uses THREAD_PRIORITY_HIGHEST and the latter THREAD_PRIORITY_ABOVE_NORMAL. Without any real/reasonable workloads for benchmarking it is all somewhat arbitrary. Arguably the Reference handler thread has more work to do in general so might be better given the higher priority.

Thanks that’s useful. I never spent the time to look at the implementation.


More information about the core-libs-dev mailing list