How to get reference processing logging?

Mikael Gerdin mikael.gerdin at
Wed Dec 7 12:50:50 UTC 2016

Hi Andrew,

On 2016-12-07 12:08, Andrew Haley wrote:
> I've tried "-Xlog:gc::ref" and "-Xlog:gc=ref" but neither works.
> I want to see this output:
>   log_debug(gc, ref)("Ref Counts: Soft: " SIZE_FORMAT " Weak: " SIZE_FORMAT " Final: " SIZE_FORMAT " Phantom: " SIZE_FORMAT,
>                      stats.soft_count(), stats.weak_count(), stats.final_count(), stats.phantom_count());
>   log_develop_trace(gc, ref)("JNI Weak Reference count: " SIZE_FORMAT, count_jni_refs());
> I tried -Xlog:help and searc hed on the web for information about the
> -Xlog syntax, but no luck.

The -Xlog:help output probably needs an example to cover this case.
The command line you want is

The tag syntax also allows wildcards, so if you want to see all the 
reference processing logging you could use

Hope this clarifies it a bit

> Thanks,
> Andrew.

More information about the hotspot-dev mailing list