Skip to content
This repository has been archived by the owner on Feb 2, 2023. It is now read-only.

Commit

Permalink
8258471: "search codecache" clhsdb command does not work
Browse files Browse the repository at this point in the history
Backport-of: 1e03ca1
  • Loading branch information
Yuri Nesterenko committed May 26, 2022
1 parent 6abf215 commit 73ac61f
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/hotspot/share/runtime/vmStructs.cpp
Expand Up @@ -1425,6 +1425,7 @@ typedef PaddedEnd<ObjectMonitor> PaddedObjectMonitor;
declare_type(BufferBlob, RuntimeBlob) \
declare_type(AdapterBlob, BufferBlob) \
declare_type(MethodHandlesAdapterBlob, BufferBlob) \
declare_type(VtableBlob, BufferBlob) \
declare_type(CompiledMethod, CodeBlob) \
declare_type(nmethod, CompiledMethod) \
declare_type(RuntimeStub, RuntimeBlob) \
Expand Down
Expand Up @@ -62,6 +62,7 @@ private static synchronized void initialize(TypeDataBase db) {
virtualConstructor.addMapping("RuntimeStub", RuntimeStub.class);
virtualConstructor.addMapping("AdapterBlob", AdapterBlob.class);
virtualConstructor.addMapping("MethodHandlesAdapterBlob", MethodHandlesAdapterBlob.class);
virtualConstructor.addMapping("VtableBlob", VtableBlob.class);
virtualConstructor.addMapping("SafepointBlob", SafepointBlob.class);
virtualConstructor.addMapping("DeoptimizationBlob", DeoptimizationBlob.class);
if (VM.getVM().isServerCompiler()) {
Expand Down Expand Up @@ -163,7 +164,7 @@ public CodeBlob createCodeBlobWrapper(Address codeBlobAddr) {
}
catch (Exception e) {
String message = "Unable to deduce type of CodeBlob from address " + codeBlobAddr +
" (expected type nmethod, RuntimeStub, ";
" (expected type nmethod, RuntimeStub, VtableBlob, ";
if (VM.getVM().isClientCompiler()) {
message = message + " or ";
}
Expand Down
@@ -0,0 +1,44 @@
/*
* Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2020, NTT DATA.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*
*/

package sun.jvm.hotspot.code;

import sun.jvm.hotspot.debugger.Address;

public class VtableBlob extends BufferBlob {

public VtableBlob(Address addr) {
super(addr);
}

public boolean isVtableBlob() {
return true;
}

public String getName() {
return "VtableBlob: " + super.getName();
}

}

1 comment on commit 73ac61f

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.