< prev index next >

src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/code/CodeCache.java

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
  * 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.

@@ -31,11 +31,10 @@
 import sun.jvm.hotspot.types.*;
 import sun.jvm.hotspot.utilities.*;
 
 public class CodeCache {
   private static GrowableArray<CodeHeap> heapArray;
-  private static AddressField scavengeRootNMethodsField;
   private static VirtualConstructor virtualConstructor;
 
   static {
     VM.registerVMInitializedObserver(new Observer() {
         public void update(Observable o, Object data) {

@@ -54,12 +53,10 @@
         new VirtualBaseConstructor(db, codeHeapType, "sun.jvm.hotspot.memory", CodeHeap.class);
 
     AddressField heapsField = type.getAddressField("_heaps");
     heapArray = GrowableArray.create(heapsField.getValue(), heapConstructor);
 
-    scavengeRootNMethodsField = type.getAddressField("_scavenge_root_nmethods");
-
     virtualConstructor = new VirtualConstructor(db);
     // Add mappings for all possible CodeBlob subclasses
     virtualConstructor.addMapping("BufferBlob", BufferBlob.class);
     virtualConstructor.addMapping("nmethod", NMethod.class);
     virtualConstructor.addMapping("RuntimeStub", RuntimeStub.class);

@@ -71,14 +68,10 @@
       virtualConstructor.addMapping("ExceptionBlob", ExceptionBlob.class);
       virtualConstructor.addMapping("UncommonTrapBlob", UncommonTrapBlob.class);
     }
   }
 
-  public NMethod scavengeRootMethods() {
-    return (NMethod) VMObjectFactory.newObject(NMethod.class, scavengeRootNMethodsField.getValue());
-  }
-
   public boolean contains(Address p) {
     for (int i = 0; i < heapArray.length(); ++i) {
       if (heapArray.at(i).contains(p)) {
         return true;
       }
< prev index next >