8213346: Re-implement shared dictionary using CompactHashtable

Reviewed-by: jiangli
This commit is contained in:
Ioi Lam 2018-11-07 19:40:27 -08:00
parent 14b8e187e2
commit 147fc3ed13
31 changed files with 832 additions and 1049 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2018, 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
@ -26,6 +26,7 @@ package sun.jvm.hotspot.oops;
import java.io.*;
import java.util.*;
import sun.jvm.hotspot.memory.*;
import sun.jvm.hotspot.utilities.*;
import sun.jvm.hotspot.debugger.*;
import sun.jvm.hotspot.runtime.*;
@ -87,4 +88,12 @@ abstract public class Metadata extends VMObject {
public void dumpReplayData(PrintStream out) {
out.println("# Unknown Metadata");
}
public boolean isShared() {
VM vm = VM.getVM();
if (vm.isSharingEnabled()) {
return MetaspaceObj.isShared(getAddress());
}
return false;
}
}