Hi Yasumasa,
On 10/08/2016 10:18 PM, Yasumasa Suenaga wrote:
Hi all,
When I chose "Monitor Cache Dump" menu in HSDB, I saw an Exception as
below:
------------
Exception in thread "AWT-EventQueue-0"
java.lang.ExceptionInInitializerError
at
sun.jvm.hotspot.ui.MonitorCacheDumpPanel.dumpOn(jdk.hotspot.agent@9-internal/MonitorCacheDumpPanel.java:92)
at
sun.jvm.hotspot.ui.MonitorCacheDumpPanel.<init>(jdk.hotspot.agent@9-internal/MonitorCacheDumpPanel.java:59)
at
sun.jvm.hotspot.HSDB.showMonitorCacheDumpPanel(jdk.hotspot.agent@9-internal/HSDB.java:1534)
:
Caused by: java.lang.ArithmeticException: / by zero
at
sun.jvm.hotspot.runtime.ObjectSynchronizer.initialize(jdk.hotspot.agent@9-internal/ObjectSynchronizer.java:55)
:
------------
ObjectSynchronizer finds DEFAULT_CACHE_LINE_SIZE value from VMStructs,
however, it is not contained.
This value is added by JDK-8049737. DEFAULT_CACHE_LINE_SIZE is macro.
When we set macro value to VMStructs, we have to use
declare_preprocessor_constant macro. However this change uses
declare_constant macro. It is the cause of this exception.
I uploaded a webrev for this issue.
Could you review it?
http://cr.openjdk.java.net/~ysuenaga/JDK-8163580/webrev.00/
I'm jdk 9 committer, but I cannot access JPRT.
So I need a sponsor.
I agree with your analysis and fix. I will sponsor this under the
'trivial change' rules.
Thanks,
David
Thanks,
Yasumasa