src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/ui/classbrowser/HTMLGenerator.java
--- a/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/ui/classbrowser/HTMLGenerator.java Sun Nov 26 09:05:13 2017 -0800
+++ b/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/ui/classbrowser/HTMLGenerator.java Mon Nov 27 11:20:38 2017 +0530
@@ -1910,6 +1910,7 @@
buf.append(thread.getThreadState().toString());
buf.br();
buf.beginTag("pre");
+ int count = 0;
for (JavaVFrame vf = thread.getLastJavaVFrameDbg(); vf != null; vf = vf.javaSender()) {
Method method = vf.getMethod();
buf.append(" - ");
@@ -1954,6 +1955,19 @@
}
buf.append(")");
buf.br();
+
+ ByteArrayOutputStream bytes = new ByteArrayOutputStream();
+ PrintStream printStream = new PrintStream(bytes);
+ try (printStream) {
+ vf.printLockInfo(printStream, count++);
+ for (String line : bytes.toString().split("\n")) {
+ if (genHTML) {
+ line = line.replace("<", "<").replace(">", ">");
+ }
+ buf.append(line);
+ buf.br();
+ }
+ }
}
buf.endTag("pre");