Merge
This commit is contained in:
commit
289ca864cd
1
.hgtags
1
.hgtags
@ -2,3 +2,4 @@
|
|||||||
bf2517e15f0c0f950e5b3143c4ca11e2df73dcc1 jdk7-b25
|
bf2517e15f0c0f950e5b3143c4ca11e2df73dcc1 jdk7-b25
|
||||||
5ae7db536e3fcf6be78e45b240a9058095e0ed38 jdk7-b26
|
5ae7db536e3fcf6be78e45b240a9058095e0ed38 jdk7-b26
|
||||||
67052ac87fc927d048e62ec54ff42adb230d3f7c jdk7-b27
|
67052ac87fc927d048e62ec54ff42adb230d3f7c jdk7-b27
|
||||||
|
18dc4ba4739a537fd146f77da51db16efce28da2 jdk7-b28
|
||||||
|
@ -2,3 +2,4 @@ cfeea66a3fa8ca3686a7cfa2d0ce8ab0169f168d jdk7-b24
|
|||||||
cbc8ad9dd0e085a607427ea35411990982f19a36 jdk7-b25
|
cbc8ad9dd0e085a607427ea35411990982f19a36 jdk7-b25
|
||||||
9410f77cc30c604d1caf7c9fe3a57fa19e1acbe8 jdk7-b26
|
9410f77cc30c604d1caf7c9fe3a57fa19e1acbe8 jdk7-b26
|
||||||
11b4dc9f2be3523ef989a0db8459eb56b3045c3a jdk7-b27
|
11b4dc9f2be3523ef989a0db8459eb56b3045c3a jdk7-b27
|
||||||
|
56652b46f328937f6b9b5130f1e4cd80f48868ef jdk7-b28
|
||||||
|
@ -2,3 +2,4 @@
|
|||||||
5e61d5df62586474414d1058e9186441aa908f51 jdk7-b25
|
5e61d5df62586474414d1058e9186441aa908f51 jdk7-b25
|
||||||
0043eb3d4e628f049ff80a8c223b5657136085e7 jdk7-b26
|
0043eb3d4e628f049ff80a8c223b5657136085e7 jdk7-b26
|
||||||
e84e9018bebbf3e5bafc5706e7882a15cb1c7d99 jdk7-b27
|
e84e9018bebbf3e5bafc5706e7882a15cb1c7d99 jdk7-b27
|
||||||
|
27509b7d21ed783b3f6eb7b7612781c675a30c2f jdk7-b28
|
||||||
|
@ -31,6 +31,9 @@ COMPILER_NAME=Sun Studio
|
|||||||
|
|
||||||
# Sun Studio Compiler settings specific to Solaris
|
# Sun Studio Compiler settings specific to Solaris
|
||||||
ifeq ($(PLATFORM), solaris)
|
ifeq ($(PLATFORM), solaris)
|
||||||
|
# FIXUP: Change to SS12 when validated
|
||||||
|
#COMPILER_VERSION=SS12
|
||||||
|
#REQUIRED_CC_VER=5.9
|
||||||
COMPILER_VERSION=SS11
|
COMPILER_VERSION=SS11
|
||||||
REQUIRED_CC_VER=5.8
|
REQUIRED_CC_VER=5.8
|
||||||
CC = $(COMPILER_PATH)cc
|
CC = $(COMPILER_PATH)cc
|
||||||
@ -51,8 +54,8 @@ endif
|
|||||||
# Sun Studio Compiler settings specific to Linux
|
# Sun Studio Compiler settings specific to Linux
|
||||||
ifeq ($(PLATFORM), linux)
|
ifeq ($(PLATFORM), linux)
|
||||||
# This has not been tested
|
# This has not been tested
|
||||||
COMPILER_VERSION=SS11
|
COMPILER_VERSION=SS12
|
||||||
REQUIRED_CC_VER=5.8
|
REQUIRED_CC_VER=5.9
|
||||||
CC = $(COMPILER_PATH)cc
|
CC = $(COMPILER_PATH)cc
|
||||||
CPP = $(COMPILER_PATH)cc -E
|
CPP = $(COMPILER_PATH)cc -E
|
||||||
CXX = $(COMPILER_PATH)CC
|
CXX = $(COMPILER_PATH)CC
|
||||||
|
@ -123,9 +123,15 @@ if [ "${osname}" = SunOS ] ; then
|
|||||||
solaris_arch=i386
|
solaris_arch=i386
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Get the SS11 compilers into path (make sure it matches ALT setting)
|
# Get the compilers into path (make sure it matches ALT setting)
|
||||||
compiler_path=${jdk_devtools}/${solaris_arch}/SUNWspro/SS11/bin
|
if [ "${JPRT_SOLARIS_COMPILER_NAME}" != "" ] ; then
|
||||||
|
compiler_name=${JPRT_SOLARIS_COMPILER_NAME}
|
||||||
|
else
|
||||||
|
# FIXUP: Change to SS12 when validated
|
||||||
|
#compiler_name=SS12
|
||||||
compiler_name=SS11
|
compiler_name=SS11
|
||||||
|
fi
|
||||||
|
compiler_path=${jdk_devtools}/${solaris_arch}/SUNWspro/${compiler_name}/bin
|
||||||
ALT_COMPILER_PATH="${compiler_path}"
|
ALT_COMPILER_PATH="${compiler_path}"
|
||||||
export ALT_COMPILER_PATH
|
export ALT_COMPILER_PATH
|
||||||
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
|
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
|
||||||
|
@ -2,3 +2,4 @@ a61af66fc99eb5ec9d50c05b0c599757b1289ceb jdk7-b24
|
|||||||
7836be3e92d0a4f9ee7566f602c91f5609534e66 jdk7-b25
|
7836be3e92d0a4f9ee7566f602c91f5609534e66 jdk7-b25
|
||||||
ad0b851458ff9d1d490ed2d79bb84f75a9fdb753 jdk7-b26
|
ad0b851458ff9d1d490ed2d79bb84f75a9fdb753 jdk7-b26
|
||||||
e3d2692f8442e2d951166dc9bd9a330684754438 jdk7-b27
|
e3d2692f8442e2d951166dc9bd9a330684754438 jdk7-b27
|
||||||
|
c14dab40ed9bf45ad21150bd70c9c80cdf655415 jdk7-b28
|
||||||
|
@ -189,7 +189,7 @@ public class CompactibleFreeListSpace extends CompactibleSpace {
|
|||||||
cur = cur.addOffsetTo(adjustObjectSizeInBytes(size));
|
cur = cur.addOffsetTo(adjustObjectSizeInBytes(size));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FreeChunk.secondWordIndicatesFreeChunk(dbg.getAddressValue(klassOop))) {
|
if (FreeChunk.indicatesFreeChunk(cur)) {
|
||||||
if (! cur.equals(regionStart)) {
|
if (! cur.equals(regionStart)) {
|
||||||
res.add(new MemRegion(regionStart, cur));
|
res.add(new MemRegion(regionStart, cur));
|
||||||
}
|
}
|
||||||
|
@ -28,6 +28,7 @@ import java.util.*;
|
|||||||
import sun.jvm.hotspot.debugger.*;
|
import sun.jvm.hotspot.debugger.*;
|
||||||
import sun.jvm.hotspot.types.*;
|
import sun.jvm.hotspot.types.*;
|
||||||
import sun.jvm.hotspot.runtime.*;
|
import sun.jvm.hotspot.runtime.*;
|
||||||
|
import sun.jvm.hotspot.oops.*;
|
||||||
|
|
||||||
public class FreeChunk extends VMObject {
|
public class FreeChunk extends VMObject {
|
||||||
static {
|
static {
|
||||||
@ -42,13 +43,13 @@ public class FreeChunk extends VMObject {
|
|||||||
Type type = db.lookupType("FreeChunk");
|
Type type = db.lookupType("FreeChunk");
|
||||||
nextField = type.getAddressField("_next");
|
nextField = type.getAddressField("_next");
|
||||||
prevField = type.getAddressField("_prev");
|
prevField = type.getAddressField("_prev");
|
||||||
sizeField = type.getCIntegerField("_size");
|
sizeField = type.getAddressField("_size");
|
||||||
}
|
}
|
||||||
|
|
||||||
// Fields
|
// Fields
|
||||||
private static AddressField nextField;
|
private static AddressField nextField;
|
||||||
private static AddressField prevField;
|
private static AddressField prevField;
|
||||||
private static CIntegerField sizeField;
|
private static AddressField sizeField;
|
||||||
|
|
||||||
// Accessors
|
// Accessors
|
||||||
public FreeChunk next() {
|
public FreeChunk next() {
|
||||||
@ -61,20 +62,34 @@ public class FreeChunk extends VMObject {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public long size() {
|
public long size() {
|
||||||
return sizeField.getValue(addr);
|
if (VM.getVM().isCompressedOopsEnabled()) {
|
||||||
|
Mark mark = new Mark(sizeField.getValue(addr));
|
||||||
|
return mark.getSize();
|
||||||
|
} else {
|
||||||
|
Address size = sizeField.getValue(addr);
|
||||||
|
Debugger dbg = VM.getVM().getDebugger();
|
||||||
|
return dbg.getAddressValue(size);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public FreeChunk(Address addr) {
|
public FreeChunk(Address addr) {
|
||||||
super(addr);
|
super(addr);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean secondWordIndicatesFreeChunk(long word) {
|
public static boolean indicatesFreeChunk(Address cur) {
|
||||||
return (word & 0x1L) == 0x1L;
|
FreeChunk f = new FreeChunk(cur);
|
||||||
|
return f.isFree();
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isFree() {
|
public boolean isFree() {
|
||||||
Debugger dbg = VM.getVM().getDebugger();
|
if (VM.getVM().isCompressedOopsEnabled()) {
|
||||||
|
Mark mark = new Mark(sizeField.getValue(addr));
|
||||||
|
return mark.isCmsFreeChunk();
|
||||||
|
} else {
|
||||||
Address prev = prevField.getValue(addr);
|
Address prev = prevField.getValue(addr);
|
||||||
return secondWordIndicatesFreeChunk(dbg.getAddressValue(prev));
|
Debugger dbg = VM.getVM().getDebugger();
|
||||||
|
long word = dbg.getAddressValue(prev);
|
||||||
|
return (word & 0x1L) == 0x1L;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -79,6 +79,11 @@ public class Mark extends VMObject {
|
|||||||
noHashInPlace = db.lookupLongConstant("markOopDesc::no_hash_in_place").longValue();
|
noHashInPlace = db.lookupLongConstant("markOopDesc::no_hash_in_place").longValue();
|
||||||
noLockInPlace = db.lookupLongConstant("markOopDesc::no_lock_in_place").longValue();
|
noLockInPlace = db.lookupLongConstant("markOopDesc::no_lock_in_place").longValue();
|
||||||
maxAge = db.lookupLongConstant("markOopDesc::max_age").longValue();
|
maxAge = db.lookupLongConstant("markOopDesc::max_age").longValue();
|
||||||
|
|
||||||
|
/* Constants in markOop used by CMS. */
|
||||||
|
cmsShift = db.lookupLongConstant("markOopDesc::cms_shift").longValue();
|
||||||
|
cmsMask = db.lookupLongConstant("markOopDesc::cms_mask").longValue();
|
||||||
|
sizeShift = db.lookupLongConstant("markOopDesc::size_shift").longValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Field accessors
|
// Field accessors
|
||||||
@ -120,6 +125,11 @@ public class Mark extends VMObject {
|
|||||||
|
|
||||||
private static long maxAge;
|
private static long maxAge;
|
||||||
|
|
||||||
|
/* Constants in markOop used by CMS. */
|
||||||
|
private static long cmsShift;
|
||||||
|
private static long cmsMask;
|
||||||
|
private static long sizeShift;
|
||||||
|
|
||||||
public Mark(Address addr) {
|
public Mark(Address addr) {
|
||||||
super(addr);
|
super(addr);
|
||||||
}
|
}
|
||||||
@ -290,4 +300,11 @@ public class Mark extends VMObject {
|
|||||||
//
|
//
|
||||||
// // Recover address of oop from encoded form used in mark
|
// // Recover address of oop from encoded form used in mark
|
||||||
// inline void* decode_pointer() { return clear_lock_bits(); }
|
// inline void* decode_pointer() { return clear_lock_bits(); }
|
||||||
|
|
||||||
|
// Copy markOop methods for CMS here.
|
||||||
|
public boolean isCmsFreeChunk() {
|
||||||
|
return isUnlocked() &&
|
||||||
|
(Bits.maskBitsLong(value() >> cmsShift, cmsMask) & 0x1L) == 0x1L;
|
||||||
|
}
|
||||||
|
public long getSize() { return (long)(value() >> sizeShift); }
|
||||||
}
|
}
|
||||||
|
@ -316,6 +316,14 @@ public class ObjectHeap {
|
|||||||
iterateLiveRegions(liveRegions, visitor, null);
|
iterateLiveRegions(liveRegions, visitor, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isValidMethod(OopHandle handle) {
|
||||||
|
OopHandle klass = Oop.getKlassForOopHandle(handle);
|
||||||
|
if (klass != null && klass.equals(methodKlassHandle)) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
// Creates an instance from the Oop hierarchy based based on the handle
|
// Creates an instance from the Oop hierarchy based based on the handle
|
||||||
public Oop newOop(OopHandle handle) {
|
public Oop newOop(OopHandle handle) {
|
||||||
// The only known way to detect the right type of an oop is
|
// The only known way to detect the right type of an oop is
|
||||||
@ -375,8 +383,10 @@ public class ObjectHeap {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (DEBUG) {
|
||||||
System.err.println("Unknown oop at " + handle);
|
System.err.println("Unknown oop at " + handle);
|
||||||
System.err.println("Oop's klass is " + klass);
|
System.err.println("Oop's klass is " + klass);
|
||||||
|
}
|
||||||
|
|
||||||
throw new UnknownOopException();
|
throw new UnknownOopException();
|
||||||
}
|
}
|
||||||
|
@ -228,10 +228,7 @@ public class JavaThread extends Thread {
|
|||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
if (vf.isJavaFrame()) {
|
return vf.isJavaFrame() ? (JavaVFrame)vf : vf.javaSender();
|
||||||
return (JavaVFrame) vf;
|
|
||||||
}
|
|
||||||
return (JavaVFrame) vf.javaSender();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** In this system, a JavaThread is the top-level factory for a
|
/** In this system, a JavaThread is the top-level factory for a
|
||||||
|
@ -121,6 +121,13 @@ public class SolarisSPARCJavaThreadPDAccess implements JavaThreadPDAccess {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public Frame getCurrentFrameGuess(JavaThread thread, Address addr) {
|
public Frame getCurrentFrameGuess(JavaThread thread, Address addr) {
|
||||||
|
|
||||||
|
// If java stack is walkable then both last_Java_sp and last_Java_pc are
|
||||||
|
// non null and we can start stack walk from this frame.
|
||||||
|
if (thread.getLastJavaSP() != null && thread.getLastJavaPC() != null) {
|
||||||
|
return new SPARCFrame(SPARCFrame.biasSP(thread.getLastJavaSP()), thread.getLastJavaPC());
|
||||||
|
}
|
||||||
|
|
||||||
ThreadProxy t = getThreadProxy(addr);
|
ThreadProxy t = getThreadProxy(addr);
|
||||||
SPARCThreadContext context = (SPARCThreadContext) t.getContext();
|
SPARCThreadContext context = (SPARCThreadContext) t.getContext();
|
||||||
// For now, let's see what happens if we do a similar thing to
|
// For now, let's see what happens if we do a similar thing to
|
||||||
|
@ -422,6 +422,13 @@ public class SPARCFrame extends Frame {
|
|||||||
if (getFP().addOffsetTo(INTERPRETER_FRAME_VM_LOCAL_WORDS * VM.getVM().getAddressSize()).lessThan(getSP())) {
|
if (getFP().addOffsetTo(INTERPRETER_FRAME_VM_LOCAL_WORDS * VM.getVM().getAddressSize()).lessThan(getSP())) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
OopHandle methodHandle = addressOfInterpreterFrameMethod().getOopHandleAt(0);
|
||||||
|
|
||||||
|
if (VM.getVM().getObjectHeap().isValidMethod(methodHandle) == false) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
// These are hacks to keep us out of trouble.
|
// These are hacks to keep us out of trouble.
|
||||||
// The problem with these is that they mask other problems
|
// The problem with these is that they mask other problems
|
||||||
if (getFP().lessThanOrEqual(getSP())) { // this attempts to deal with unsigned comparison above
|
if (getFP().lessThanOrEqual(getSP())) { // this attempts to deal with unsigned comparison above
|
||||||
@ -433,9 +440,18 @@ public class SPARCFrame extends Frame {
|
|||||||
// FIXME: this is not atomic with respect to GC and is unsuitable
|
// FIXME: this is not atomic with respect to GC and is unsuitable
|
||||||
// for use in a non-debugging, or reflective, system. Need to
|
// for use in a non-debugging, or reflective, system. Need to
|
||||||
// figure out how to express this.
|
// figure out how to express this.
|
||||||
if (addressOfInterpreterFrameBCX().getAddressAt(0) == null) {
|
Address bcx = addressOfInterpreterFrameBCX().getAddressAt(0);
|
||||||
return false; // BCP not yet set up
|
|
||||||
|
Method method;
|
||||||
|
try {
|
||||||
|
method = (Method) VM.getVM().getObjectHeap().newOop(methodHandle);
|
||||||
|
} catch (UnknownOopException ex) {
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
int bci = bcpToBci(bcx, method);
|
||||||
|
//validate bci
|
||||||
|
if (bci < 0) return false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -471,7 +487,7 @@ public class SPARCFrame extends Frame {
|
|||||||
// will update it accordingly
|
// will update it accordingly
|
||||||
map.setIncludeArgumentOops(false);
|
map.setIncludeArgumentOops(false);
|
||||||
|
|
||||||
if (cb == null && isEntryFrame()) {
|
if (isEntryFrame()) {
|
||||||
return senderForEntryFrame(map);
|
return senderForEntryFrame(map);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -539,7 +555,6 @@ public class SPARCFrame extends Frame {
|
|||||||
int SP_OFFSET_IN_GREGSET = 17;
|
int SP_OFFSET_IN_GREGSET = 17;
|
||||||
raw_sp = fp.getAddressAt(VM.getVM().getAddressSize() * SP_OFFSET_IN_GREGSET);
|
raw_sp = fp.getAddressAt(VM.getVM().getAddressSize() * SP_OFFSET_IN_GREGSET);
|
||||||
Address pc = fp.getAddressAt(VM.getVM().getAddressSize() * PC_OFFSET_IN_GREGSET);
|
Address pc = fp.getAddressAt(VM.getVM().getAddressSize() * PC_OFFSET_IN_GREGSET);
|
||||||
// System.out.println(" next frame's SP: " + sp + " PC: " + pc);
|
|
||||||
return new SPARCFrame(raw_sp, pc);
|
return new SPARCFrame(raw_sp, pc);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -562,10 +577,8 @@ public class SPARCFrame extends Frame {
|
|||||||
// sender's _interpreter_sp_adjustment field.
|
// sender's _interpreter_sp_adjustment field.
|
||||||
if (VM.getVM().getInterpreter().contains(pc)) {
|
if (VM.getVM().getInterpreter().contains(pc)) {
|
||||||
isInterpreted = true;
|
isInterpreted = true;
|
||||||
if (VM.getVM().isClientCompiler()) {
|
|
||||||
map.makeIntegerRegsUnsaved();
|
map.makeIntegerRegsUnsaved();
|
||||||
map.shiftWindow(sp, youngerSP);
|
map.shiftWindow(sp, youngerSP);
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// Find a CodeBlob containing this frame's pc or elide the lookup and use the
|
// Find a CodeBlob containing this frame's pc or elide the lookup and use the
|
||||||
// supplied blob which is already known to be associated with this frame.
|
// supplied blob which is already known to be associated with this frame.
|
||||||
|
@ -87,12 +87,13 @@ public class PStack extends Tool {
|
|||||||
while (f != null) {
|
while (f != null) {
|
||||||
ClosestSymbol sym = f.closestSymbolToPC();
|
ClosestSymbol sym = f.closestSymbolToPC();
|
||||||
Address pc = f.pc();
|
Address pc = f.pc();
|
||||||
|
out.print(pc + "\t");
|
||||||
if (sym != null) {
|
if (sym != null) {
|
||||||
String name = sym.getName();
|
String name = sym.getName();
|
||||||
if (cdbgCanDemangle) {
|
if (cdbgCanDemangle) {
|
||||||
name = cdbg.demangle(name);
|
name = cdbg.demangle(name);
|
||||||
}
|
}
|
||||||
out.print(pc + "\t" + name);
|
out.print(name);
|
||||||
long diff = sym.getOffset();
|
long diff = sym.getOffset();
|
||||||
if (diff != 0L) {
|
if (diff != 0L) {
|
||||||
out.print(" + 0x" + Long.toHexString(diff));
|
out.print(" + 0x" + Long.toHexString(diff));
|
||||||
@ -120,7 +121,6 @@ public class PStack extends Tool {
|
|||||||
// look for known code blobs
|
// look for known code blobs
|
||||||
CodeCache c = VM.getVM().getCodeCache();
|
CodeCache c = VM.getVM().getCodeCache();
|
||||||
if (c.contains(pc)) {
|
if (c.contains(pc)) {
|
||||||
out.print(pc + "\t");
|
|
||||||
CodeBlob cb = c.findBlobUnsafe(pc);
|
CodeBlob cb = c.findBlobUnsafe(pc);
|
||||||
if (cb.isNMethod()) {
|
if (cb.isNMethod()) {
|
||||||
names = getJavaNames(th, f.localVariableBase());
|
names = getJavaNames(th, f.localVariableBase());
|
||||||
@ -144,18 +144,18 @@ public class PStack extends Tool {
|
|||||||
out.println("<Unknown code blob>");
|
out.println("<Unknown code blob>");
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
printUnknown(out,pc);
|
printUnknown(out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// print java frames, if any
|
// print java frames, if any
|
||||||
if (names != null && names.length != 0) {
|
if (names != null && names.length != 0) {
|
||||||
// print java frame(s)
|
// print java frame(s)
|
||||||
for (int i = 0; i < names.length; i++) {
|
for (int i = 0; i < names.length; i++) {
|
||||||
out.println(pc + "\t" + names[i]);
|
out.println(names[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
printUnknown(out,pc);
|
printUnknown(out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
f = f.sender();
|
f = f.sender();
|
||||||
@ -220,8 +220,8 @@ public class PStack extends Tool {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void printUnknown(PrintStream out, Address pc) {
|
private void printUnknown(PrintStream out) {
|
||||||
out.println(pc + "\t????????");
|
out.println("\t????????");
|
||||||
}
|
}
|
||||||
|
|
||||||
private String[] getJavaNames(ThreadProxy th, Address fp) {
|
private String[] getJavaNames(ThreadProxy th, Address fp) {
|
||||||
|
@ -33,9 +33,9 @@
|
|||||||
# Don't put quotes (fail windows build).
|
# Don't put quotes (fail windows build).
|
||||||
HOTSPOT_VM_COPYRIGHT=Copyright 2008
|
HOTSPOT_VM_COPYRIGHT=Copyright 2008
|
||||||
|
|
||||||
HS_MAJOR_VER=13
|
HS_MAJOR_VER=14
|
||||||
HS_MINOR_VER=0
|
HS_MINOR_VER=0
|
||||||
HS_BUILD_NUMBER=02
|
HS_BUILD_NUMBER=01
|
||||||
|
|
||||||
JDK_MAJOR_VER=1
|
JDK_MAJOR_VER=1
|
||||||
JDK_MINOR_VER=7
|
JDK_MINOR_VER=7
|
||||||
|
@ -30,7 +30,7 @@ DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@)
|
|||||||
|
|
||||||
ifeq ("${Platform_compiler}", "sparcWorks")
|
ifeq ("${Platform_compiler}", "sparcWorks")
|
||||||
|
|
||||||
ifeq ($(COMPILER_REV),5.8))
|
ifeq ($(COMPILER_REV),5.8)
|
||||||
# SS11 SEGV when compiling with -g and -xarch=v8, using different backend
|
# SS11 SEGV when compiling with -g and -xarch=v8, using different backend
|
||||||
DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0
|
DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0
|
||||||
DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0
|
DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0
|
||||||
|
@ -36,6 +36,7 @@ public class Database {
|
|||||||
private FileList outerFiles;
|
private FileList outerFiles;
|
||||||
private FileList indivIncludes;
|
private FileList indivIncludes;
|
||||||
private FileList grandInclude; // the results for the grand include file
|
private FileList grandInclude; // the results for the grand include file
|
||||||
|
private HashMap<String,String> platformDepFiles;
|
||||||
private long threshold;
|
private long threshold;
|
||||||
private int nOuterFiles;
|
private int nOuterFiles;
|
||||||
private int nPrecompiledFiles;
|
private int nPrecompiledFiles;
|
||||||
@ -57,6 +58,7 @@ public class Database {
|
|||||||
outerFiles = new FileList("outerFiles", plat);
|
outerFiles = new FileList("outerFiles", plat);
|
||||||
indivIncludes = new FileList("IndivIncludes", plat);
|
indivIncludes = new FileList("IndivIncludes", plat);
|
||||||
grandInclude = new FileList(plat.getGIFileTemplate().nameOfList(), plat);
|
grandInclude = new FileList(plat.getGIFileTemplate().nameOfList(), plat);
|
||||||
|
platformDepFiles = new HashMap<String,String>();
|
||||||
|
|
||||||
threshold = t;
|
threshold = t;
|
||||||
nOuterFiles = 0;
|
nOuterFiles = 0;
|
||||||
@ -209,6 +211,10 @@ public class Database {
|
|||||||
FileList p = allFiles.listForFile(includer);
|
FileList p = allFiles.listForFile(includer);
|
||||||
p.setPlatformDependentInclude(pdName.dirPreStemSuff());
|
p.setPlatformDependentInclude(pdName.dirPreStemSuff());
|
||||||
|
|
||||||
|
// Record the implicit include of this file so that the
|
||||||
|
// dependencies for precompiled headers can mention it.
|
||||||
|
platformDepFiles.put(newIncluder, includer);
|
||||||
|
|
||||||
// Add an implicit dependency on platform
|
// Add an implicit dependency on platform
|
||||||
// specific file for the generic file
|
// specific file for the generic file
|
||||||
|
|
||||||
@ -408,6 +414,12 @@ public class Database {
|
|||||||
for (Iterator iter = grandInclude.iterator(); iter.hasNext(); ) {
|
for (Iterator iter = grandInclude.iterator(); iter.hasNext(); ) {
|
||||||
FileList list = (FileList) iter.next();
|
FileList list = (FileList) iter.next();
|
||||||
gd.println(list.getName() + " \\");
|
gd.println(list.getName() + " \\");
|
||||||
|
String platformDep = platformDepFiles.get(list.getName());
|
||||||
|
if (platformDep != null) {
|
||||||
|
// make sure changes to the platform dependent file will
|
||||||
|
// cause regeneration of the pch file.
|
||||||
|
gd.println(platformDep + " \\");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
gd.println();
|
gd.println();
|
||||||
gd.println();
|
gd.println();
|
||||||
|
@ -729,6 +729,7 @@ bool InstructForm::captures_bottom_type() const {
|
|||||||
!strcmp(_matrule->_rChild->_opType,"DecodeN") ||
|
!strcmp(_matrule->_rChild->_opType,"DecodeN") ||
|
||||||
!strcmp(_matrule->_rChild->_opType,"EncodeP") ||
|
!strcmp(_matrule->_rChild->_opType,"EncodeP") ||
|
||||||
!strcmp(_matrule->_rChild->_opType,"LoadN") ||
|
!strcmp(_matrule->_rChild->_opType,"LoadN") ||
|
||||||
|
!strcmp(_matrule->_rChild->_opType,"LoadNKlass") ||
|
||||||
!strcmp(_matrule->_rChild->_opType,"CreateEx") || // type of exception
|
!strcmp(_matrule->_rChild->_opType,"CreateEx") || // type of exception
|
||||||
!strcmp(_matrule->_rChild->_opType,"CheckCastPP")) ) return true;
|
!strcmp(_matrule->_rChild->_opType,"CheckCastPP")) ) return true;
|
||||||
else if ( is_ideal_load() == Form::idealP ) return true;
|
else if ( is_ideal_load() == Form::idealP ) return true;
|
||||||
|
@ -283,6 +283,7 @@
|
|||||||
template(cache_field_name, "cache") \
|
template(cache_field_name, "cache") \
|
||||||
template(value_name, "value") \
|
template(value_name, "value") \
|
||||||
template(frontCacheEnabled_name, "frontCacheEnabled") \
|
template(frontCacheEnabled_name, "frontCacheEnabled") \
|
||||||
|
template(stringCacheEnabled_name, "stringCacheEnabled") \
|
||||||
\
|
\
|
||||||
/* non-intrinsic name/signature pairs: */ \
|
/* non-intrinsic name/signature pairs: */ \
|
||||||
template(register_method_name, "register") \
|
template(register_method_name, "register") \
|
||||||
|
@ -805,22 +805,23 @@ size_t CompactibleFreeListSpace::block_size(const HeapWord* p) const {
|
|||||||
// This must be volatile, or else there is a danger that the compiler
|
// This must be volatile, or else there is a danger that the compiler
|
||||||
// will compile the code below into a sometimes-infinite loop, by keeping
|
// will compile the code below into a sometimes-infinite loop, by keeping
|
||||||
// the value read the first time in a register.
|
// the value read the first time in a register.
|
||||||
oop o = (oop)p;
|
|
||||||
volatile oop* second_word_addr = o->klass_addr();
|
|
||||||
while (true) {
|
while (true) {
|
||||||
klassOop k = (klassOop)(*second_word_addr);
|
|
||||||
// We must do this until we get a consistent view of the object.
|
// We must do this until we get a consistent view of the object.
|
||||||
if (FreeChunk::secondWordIndicatesFreeChunk((intptr_t)k)) {
|
if (FreeChunk::indicatesFreeChunk(p)) {
|
||||||
FreeChunk* fc = (FreeChunk*)p;
|
volatile FreeChunk* fc = (volatile FreeChunk*)p;
|
||||||
volatile size_t* sz_addr = (volatile size_t*)(fc->size_addr());
|
size_t res = fc->size();
|
||||||
size_t res = (*sz_addr);
|
// If the object is still a free chunk, return the size, else it
|
||||||
klassOop k2 = (klassOop)(*second_word_addr); // Read to confirm.
|
// has been allocated so try again.
|
||||||
if (k == k2) {
|
if (FreeChunk::indicatesFreeChunk(p)) {
|
||||||
assert(res != 0, "Block size should not be 0");
|
assert(res != 0, "Block size should not be 0");
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
} else if (k != NULL) {
|
} else {
|
||||||
|
// must read from what 'p' points to in each loop.
|
||||||
|
klassOop k = ((volatile oopDesc*)p)->klass_or_null();
|
||||||
|
if (k != NULL) {
|
||||||
assert(k->is_oop(true /* ignore mark word */), "Should really be klass oop.");
|
assert(k->is_oop(true /* ignore mark word */), "Should really be klass oop.");
|
||||||
|
oop o = (oop)p;
|
||||||
assert(o->is_parsable(), "Should be parsable");
|
assert(o->is_parsable(), "Should be parsable");
|
||||||
assert(o->is_oop(true /* ignore mark word */), "Should be an oop.");
|
assert(o->is_oop(true /* ignore mark word */), "Should be an oop.");
|
||||||
size_t res = o->size_given_klass(k->klass_part());
|
size_t res = o->size_given_klass(k->klass_part());
|
||||||
@ -830,6 +831,7 @@ size_t CompactibleFreeListSpace::block_size(const HeapWord* p) const {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// A variant of the above that uses the Printezis bits for
|
// A variant of the above that uses the Printezis bits for
|
||||||
// unparsable but allocated objects. This avoids any possible
|
// unparsable but allocated objects. This avoids any possible
|
||||||
@ -845,24 +847,23 @@ const {
|
|||||||
// This must be volatile, or else there is a danger that the compiler
|
// This must be volatile, or else there is a danger that the compiler
|
||||||
// will compile the code below into a sometimes-infinite loop, by keeping
|
// will compile the code below into a sometimes-infinite loop, by keeping
|
||||||
// the value read the first time in a register.
|
// the value read the first time in a register.
|
||||||
oop o = (oop)p;
|
|
||||||
volatile oop* second_word_addr = o->klass_addr();
|
|
||||||
DEBUG_ONLY(uint loops = 0;)
|
DEBUG_ONLY(uint loops = 0;)
|
||||||
while (true) {
|
while (true) {
|
||||||
klassOop k = (klassOop)(*second_word_addr);
|
|
||||||
// We must do this until we get a consistent view of the object.
|
// We must do this until we get a consistent view of the object.
|
||||||
if (FreeChunk::secondWordIndicatesFreeChunk((intptr_t)k)) {
|
if (FreeChunk::indicatesFreeChunk(p)) {
|
||||||
FreeChunk* fc = (FreeChunk*)p;
|
volatile FreeChunk* fc = (volatile FreeChunk*)p;
|
||||||
volatile size_t* sz_addr = (volatile size_t*)(fc->size_addr());
|
size_t res = fc->size();
|
||||||
size_t res = (*sz_addr);
|
if (FreeChunk::indicatesFreeChunk(p)) {
|
||||||
klassOop k2 = (klassOop)(*second_word_addr); // Read to confirm.
|
|
||||||
if (k == k2) {
|
|
||||||
assert(res != 0, "Block size should not be 0");
|
assert(res != 0, "Block size should not be 0");
|
||||||
assert(loops == 0, "Should be 0");
|
assert(loops == 0, "Should be 0");
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
} else if (k != NULL && o->is_parsable()) {
|
} else {
|
||||||
|
// must read from what 'p' points to in each loop.
|
||||||
|
klassOop k = ((volatile oopDesc*)p)->klass_or_null();
|
||||||
|
if (k != NULL && ((oopDesc*)p)->is_parsable()) {
|
||||||
assert(k->is_oop(), "Should really be klass oop.");
|
assert(k->is_oop(), "Should really be klass oop.");
|
||||||
|
oop o = (oop)p;
|
||||||
assert(o->is_oop(), "Should be an oop");
|
assert(o->is_oop(), "Should be an oop");
|
||||||
size_t res = o->size_given_klass(k->klass_part());
|
size_t res = o->size_given_klass(k->klass_part());
|
||||||
res = adjustObjectSize(res);
|
res = adjustObjectSize(res);
|
||||||
@ -871,6 +872,7 @@ const {
|
|||||||
} else {
|
} else {
|
||||||
return c->block_size_if_printezis_bits(p);
|
return c->block_size_if_printezis_bits(p);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
assert(loops == 0, "Can loop at most once");
|
assert(loops == 0, "Can loop at most once");
|
||||||
DEBUG_ONLY(loops++;)
|
DEBUG_ONLY(loops++;)
|
||||||
}
|
}
|
||||||
@ -907,9 +909,8 @@ bool CompactibleFreeListSpace::block_is_obj(const HeapWord* p) const {
|
|||||||
// and those objects (if garbage) may have been modified to hold
|
// and those objects (if garbage) may have been modified to hold
|
||||||
// live range information.
|
// live range information.
|
||||||
// assert(ParallelGCThreads > 0 || _bt.block_start(p) == p, "Should be a block boundary");
|
// assert(ParallelGCThreads > 0 || _bt.block_start(p) == p, "Should be a block boundary");
|
||||||
klassOop k = oop(p)->klass();
|
if (FreeChunk::indicatesFreeChunk(p)) return false;
|
||||||
intptr_t ki = (intptr_t)k;
|
klassOop k = oop(p)->klass_or_null();
|
||||||
if (FreeChunk::secondWordIndicatesFreeChunk(ki)) return false;
|
|
||||||
if (k != NULL) {
|
if (k != NULL) {
|
||||||
// Ignore mark word because it may have been used to
|
// Ignore mark word because it may have been used to
|
||||||
// chain together promoted objects (the last one
|
// chain together promoted objects (the last one
|
||||||
@ -1027,7 +1028,7 @@ HeapWord* CompactibleFreeListSpace::allocate(size_t size) {
|
|||||||
FreeChunk* fc = (FreeChunk*)res;
|
FreeChunk* fc = (FreeChunk*)res;
|
||||||
fc->markNotFree();
|
fc->markNotFree();
|
||||||
assert(!fc->isFree(), "shouldn't be marked free");
|
assert(!fc->isFree(), "shouldn't be marked free");
|
||||||
assert(oop(fc)->klass() == NULL, "should look uninitialized");
|
assert(oop(fc)->klass_or_null() == NULL, "should look uninitialized");
|
||||||
// Verify that the block offset table shows this to
|
// Verify that the block offset table shows this to
|
||||||
// be a single block, but not one which is unallocated.
|
// be a single block, but not one which is unallocated.
|
||||||
_bt.verify_single_block(res, size);
|
_bt.verify_single_block(res, size);
|
||||||
@ -2593,7 +2594,7 @@ HeapWord* CFLS_LAB::alloc(size_t word_sz) {
|
|||||||
}
|
}
|
||||||
res->markNotFree();
|
res->markNotFree();
|
||||||
assert(!res->isFree(), "shouldn't be marked free");
|
assert(!res->isFree(), "shouldn't be marked free");
|
||||||
assert(oop(res)->klass() == NULL, "should look uninitialized");
|
assert(oop(res)->klass_or_null() == NULL, "should look uninitialized");
|
||||||
// mangle a just allocated object with a distinct pattern.
|
// mangle a just allocated object with a distinct pattern.
|
||||||
debug_only(res->mangleAllocated(word_sz));
|
debug_only(res->mangleAllocated(word_sz));
|
||||||
return (HeapWord*)res;
|
return (HeapWord*)res;
|
||||||
|
@ -190,7 +190,8 @@ ConcurrentMarkSweepGeneration::ConcurrentMarkSweepGeneration(
|
|||||||
// depends on this property.
|
// depends on this property.
|
||||||
debug_only(
|
debug_only(
|
||||||
FreeChunk* junk = NULL;
|
FreeChunk* junk = NULL;
|
||||||
assert(junk->prev_addr() == (void*)(oop(junk)->klass_addr()),
|
assert(UseCompressedOops ||
|
||||||
|
junk->prev_addr() == (void*)(oop(junk)->klass_addr()),
|
||||||
"Offset of FreeChunk::_prev within FreeChunk must match"
|
"Offset of FreeChunk::_prev within FreeChunk must match"
|
||||||
" that of OopDesc::_klass within OopDesc");
|
" that of OopDesc::_klass within OopDesc");
|
||||||
)
|
)
|
||||||
@ -1039,7 +1040,7 @@ void CMSCollector::direct_allocated(HeapWord* start, size_t size) {
|
|||||||
// mark end of object
|
// mark end of object
|
||||||
}
|
}
|
||||||
// check that oop looks uninitialized
|
// check that oop looks uninitialized
|
||||||
assert(oop(start)->klass() == NULL, "_klass should be NULL");
|
assert(oop(start)->klass_or_null() == NULL, "_klass should be NULL");
|
||||||
}
|
}
|
||||||
|
|
||||||
void CMSCollector::promoted(bool par, HeapWord* start,
|
void CMSCollector::promoted(bool par, HeapWord* start,
|
||||||
@ -1309,17 +1310,25 @@ ConcurrentMarkSweepGeneration::par_promote(int thread_num,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
oop obj = oop(obj_ptr);
|
oop obj = oop(obj_ptr);
|
||||||
assert(obj->klass() == NULL, "Object should be uninitialized here.");
|
assert(obj->klass_or_null() == NULL, "Object should be uninitialized here.");
|
||||||
// Otherwise, copy the object. Here we must be careful to insert the
|
// Otherwise, copy the object. Here we must be careful to insert the
|
||||||
// klass pointer last, since this marks the block as an allocated object.
|
// klass pointer last, since this marks the block as an allocated object.
|
||||||
|
// Except with compressed oops it's the mark word.
|
||||||
HeapWord* old_ptr = (HeapWord*)old;
|
HeapWord* old_ptr = (HeapWord*)old;
|
||||||
if (word_sz > (size_t)oopDesc::header_size()) {
|
if (word_sz > (size_t)oopDesc::header_size()) {
|
||||||
Copy::aligned_disjoint_words(old_ptr + oopDesc::header_size(),
|
Copy::aligned_disjoint_words(old_ptr + oopDesc::header_size(),
|
||||||
obj_ptr + oopDesc::header_size(),
|
obj_ptr + oopDesc::header_size(),
|
||||||
word_sz - oopDesc::header_size());
|
word_sz - oopDesc::header_size());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (UseCompressedOops) {
|
||||||
|
// Copy gap missed by (aligned) header size calculation above
|
||||||
|
obj->set_klass_gap(old->klass_gap());
|
||||||
|
}
|
||||||
|
|
||||||
// Restore the mark word copied above.
|
// Restore the mark word copied above.
|
||||||
obj->set_mark(m);
|
obj->set_mark(m);
|
||||||
|
|
||||||
// Now we can track the promoted object, if necessary. We take care
|
// Now we can track the promoted object, if necessary. We take care
|
||||||
// To delay the transition from uninitialized to full object
|
// To delay the transition from uninitialized to full object
|
||||||
// (i.e., insertion of klass pointer) until after, so that it
|
// (i.e., insertion of klass pointer) until after, so that it
|
||||||
@ -1327,7 +1336,8 @@ ConcurrentMarkSweepGeneration::par_promote(int thread_num,
|
|||||||
if (promoInfo->tracking()) {
|
if (promoInfo->tracking()) {
|
||||||
promoInfo->track((PromotedObject*)obj, old->klass());
|
promoInfo->track((PromotedObject*)obj, old->klass());
|
||||||
}
|
}
|
||||||
// Finally, install the klass pointer.
|
|
||||||
|
// Finally, install the klass pointer (this should be volatile).
|
||||||
obj->set_klass(old->klass());
|
obj->set_klass(old->klass());
|
||||||
|
|
||||||
assert(old->is_oop(), "Will dereference klass ptr below");
|
assert(old->is_oop(), "Will dereference klass ptr below");
|
||||||
@ -6165,7 +6175,7 @@ size_t CMSCollector::block_size_if_printezis_bits(HeapWord* addr) const {
|
|||||||
HeapWord* CMSCollector::next_card_start_after_block(HeapWord* addr) const {
|
HeapWord* CMSCollector::next_card_start_after_block(HeapWord* addr) const {
|
||||||
size_t sz = 0;
|
size_t sz = 0;
|
||||||
oop p = (oop)addr;
|
oop p = (oop)addr;
|
||||||
if (p->klass() != NULL && p->is_parsable()) {
|
if (p->klass_or_null() != NULL && p->is_parsable()) {
|
||||||
sz = CompactibleFreeListSpace::adjustObjectSize(p->size());
|
sz = CompactibleFreeListSpace::adjustObjectSize(p->size());
|
||||||
} else {
|
} else {
|
||||||
sz = block_size_using_printezis_bits(addr);
|
sz = block_size_using_printezis_bits(addr);
|
||||||
@ -6602,7 +6612,7 @@ size_t ScanMarkedObjectsAgainCarefullyClosure::do_object_careful_m(
|
|||||||
}
|
}
|
||||||
if (_bitMap->isMarked(addr)) {
|
if (_bitMap->isMarked(addr)) {
|
||||||
// it's marked; is it potentially uninitialized?
|
// it's marked; is it potentially uninitialized?
|
||||||
if (p->klass() != NULL) {
|
if (p->klass_or_null() != NULL) {
|
||||||
if (CMSPermGenPrecleaningEnabled && !p->is_parsable()) {
|
if (CMSPermGenPrecleaningEnabled && !p->is_parsable()) {
|
||||||
// Signal precleaning to redirty the card since
|
// Signal precleaning to redirty the card since
|
||||||
// the klass pointer is already installed.
|
// the klass pointer is already installed.
|
||||||
@ -6615,11 +6625,8 @@ size_t ScanMarkedObjectsAgainCarefullyClosure::do_object_careful_m(
|
|||||||
if (p->is_objArray()) {
|
if (p->is_objArray()) {
|
||||||
// objArrays are precisely marked; restrict scanning
|
// objArrays are precisely marked; restrict scanning
|
||||||
// to dirty cards only.
|
// to dirty cards only.
|
||||||
size = p->oop_iterate(_scanningClosure, mr);
|
size = CompactibleFreeListSpace::adjustObjectSize(
|
||||||
assert(size == CompactibleFreeListSpace::adjustObjectSize(size),
|
p->oop_iterate(_scanningClosure, mr));
|
||||||
"adjustObjectSize should be the identity for array sizes, "
|
|
||||||
"which are necessarily larger than minimum object size of "
|
|
||||||
"two heap words");
|
|
||||||
} else {
|
} else {
|
||||||
// A non-array may have been imprecisely marked; we need
|
// A non-array may have been imprecisely marked; we need
|
||||||
// to scan object in its entirety.
|
// to scan object in its entirety.
|
||||||
@ -6653,7 +6660,7 @@ size_t ScanMarkedObjectsAgainCarefullyClosure::do_object_careful_m(
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Either a not yet marked object or an uninitialized object
|
// Either a not yet marked object or an uninitialized object
|
||||||
if (p->klass() == NULL || !p->is_parsable()) {
|
if (p->klass_or_null() == NULL || !p->is_parsable()) {
|
||||||
// An uninitialized object, skip to the next card, since
|
// An uninitialized object, skip to the next card, since
|
||||||
// we may not be able to read its P-bits yet.
|
// we may not be able to read its P-bits yet.
|
||||||
assert(size == 0, "Initial value");
|
assert(size == 0, "Initial value");
|
||||||
@ -6710,7 +6717,7 @@ size_t SurvivorSpacePrecleanClosure::do_object_careful(oop p) {
|
|||||||
HeapWord* addr = (HeapWord*)p;
|
HeapWord* addr = (HeapWord*)p;
|
||||||
DEBUG_ONLY(_collector->verify_work_stacks_empty();)
|
DEBUG_ONLY(_collector->verify_work_stacks_empty();)
|
||||||
assert(!_span.contains(addr), "we are scanning the survivor spaces");
|
assert(!_span.contains(addr), "we are scanning the survivor spaces");
|
||||||
assert(p->klass() != NULL, "object should be initializd");
|
assert(p->klass_or_null() != NULL, "object should be initializd");
|
||||||
assert(p->is_parsable(), "must be parsable.");
|
assert(p->is_parsable(), "must be parsable.");
|
||||||
// an initialized object; ignore mark word in verification below
|
// an initialized object; ignore mark word in verification below
|
||||||
// since we are running concurrent with mutators
|
// since we are running concurrent with mutators
|
||||||
@ -6868,7 +6875,7 @@ void MarkFromRootsClosure::do_bit(size_t offset) {
|
|||||||
assert(_skipBits == 0, "tautology");
|
assert(_skipBits == 0, "tautology");
|
||||||
_skipBits = 2; // skip next two marked bits ("Printezis-marks")
|
_skipBits = 2; // skip next two marked bits ("Printezis-marks")
|
||||||
oop p = oop(addr);
|
oop p = oop(addr);
|
||||||
if (p->klass() == NULL || !p->is_parsable()) {
|
if (p->klass_or_null() == NULL || !p->is_parsable()) {
|
||||||
DEBUG_ONLY(if (!_verifying) {)
|
DEBUG_ONLY(if (!_verifying) {)
|
||||||
// We re-dirty the cards on which this object lies and increase
|
// We re-dirty the cards on which this object lies and increase
|
||||||
// the _threshold so that we'll come back to scan this object
|
// the _threshold so that we'll come back to scan this object
|
||||||
@ -6890,7 +6897,7 @@ void MarkFromRootsClosure::do_bit(size_t offset) {
|
|||||||
if (_threshold < end_card_addr) {
|
if (_threshold < end_card_addr) {
|
||||||
_threshold = end_card_addr;
|
_threshold = end_card_addr;
|
||||||
}
|
}
|
||||||
if (p->klass() != NULL) {
|
if (p->klass_or_null() != NULL) {
|
||||||
// Redirty the range of cards...
|
// Redirty the range of cards...
|
||||||
_mut->mark_range(redirty_range);
|
_mut->mark_range(redirty_range);
|
||||||
} // ...else the setting of klass will dirty the card anyway.
|
} // ...else the setting of klass will dirty the card anyway.
|
||||||
@ -7048,7 +7055,7 @@ void Par_MarkFromRootsClosure::do_bit(size_t offset) {
|
|||||||
assert(_skip_bits == 0, "tautology");
|
assert(_skip_bits == 0, "tautology");
|
||||||
_skip_bits = 2; // skip next two marked bits ("Printezis-marks")
|
_skip_bits = 2; // skip next two marked bits ("Printezis-marks")
|
||||||
oop p = oop(addr);
|
oop p = oop(addr);
|
||||||
if (p->klass() == NULL || !p->is_parsable()) {
|
if (p->klass_or_null() == NULL || !p->is_parsable()) {
|
||||||
// in the case of Clean-on-Enter optimization, redirty card
|
// in the case of Clean-on-Enter optimization, redirty card
|
||||||
// and avoid clearing card by increasing the threshold.
|
// and avoid clearing card by increasing the threshold.
|
||||||
return;
|
return;
|
||||||
@ -8023,7 +8030,7 @@ size_t SweepClosure::doLiveChunk(FreeChunk* fc) {
|
|||||||
"alignment problem");
|
"alignment problem");
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
if (oop(addr)->klass() != NULL &&
|
if (oop(addr)->klass_or_null() != NULL &&
|
||||||
( !_collector->should_unload_classes()
|
( !_collector->should_unload_classes()
|
||||||
|| oop(addr)->is_parsable())) {
|
|| oop(addr)->is_parsable())) {
|
||||||
// Ignore mark word because we are running concurrent with mutators
|
// Ignore mark word because we are running concurrent with mutators
|
||||||
@ -8036,7 +8043,7 @@ size_t SweepClosure::doLiveChunk(FreeChunk* fc) {
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
// This should be an initialized object that's alive.
|
// This should be an initialized object that's alive.
|
||||||
assert(oop(addr)->klass() != NULL &&
|
assert(oop(addr)->klass_or_null() != NULL &&
|
||||||
(!_collector->should_unload_classes()
|
(!_collector->should_unload_classes()
|
||||||
|| oop(addr)->is_parsable()),
|
|| oop(addr)->is_parsable()),
|
||||||
"Should be an initialized object");
|
"Should be an initialized object");
|
||||||
|
@ -22,88 +22,6 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
//
|
|
||||||
// Free block maintenance for Concurrent Mark Sweep Generation
|
|
||||||
//
|
|
||||||
// The main data structure for free blocks are
|
|
||||||
// . an indexed array of small free blocks, and
|
|
||||||
// . a dictionary of large free blocks
|
|
||||||
//
|
|
||||||
|
|
||||||
// No virtuals in FreeChunk (don't want any vtables).
|
|
||||||
|
|
||||||
// A FreeChunk is merely a chunk that can be in a doubly linked list
|
|
||||||
// and has a size field. NOTE: FreeChunks are distinguished from allocated
|
|
||||||
// objects in two ways (by the sweeper). The second word (prev) has the
|
|
||||||
// LSB set to indicate a free chunk; allocated objects' klass() pointers
|
|
||||||
// don't have their LSB set. The corresponding bit in the CMSBitMap is
|
|
||||||
// set when the chunk is allocated. There are also blocks that "look free"
|
|
||||||
// but are not part of the free list and should not be coalesced into larger
|
|
||||||
// free blocks. These free blocks have their two LSB's set.
|
|
||||||
|
|
||||||
class FreeChunk VALUE_OBJ_CLASS_SPEC {
|
|
||||||
friend class VMStructs;
|
|
||||||
FreeChunk* _next;
|
|
||||||
FreeChunk* _prev;
|
|
||||||
size_t _size;
|
|
||||||
|
|
||||||
public:
|
|
||||||
NOT_PRODUCT(static const size_t header_size();)
|
|
||||||
// Returns "true" if the "wrd", which is required to be the second word
|
|
||||||
// of a block, indicates that the block represents a free chunk.
|
|
||||||
static bool secondWordIndicatesFreeChunk(intptr_t wrd) {
|
|
||||||
return (wrd & 0x1) == 0x1;
|
|
||||||
}
|
|
||||||
bool isFree() const {
|
|
||||||
return secondWordIndicatesFreeChunk((intptr_t)_prev);
|
|
||||||
}
|
|
||||||
bool cantCoalesce() const { return (((intptr_t)_prev) & 0x3) == 0x3; }
|
|
||||||
FreeChunk* next() const { return _next; }
|
|
||||||
FreeChunk* prev() const { return (FreeChunk*)(((intptr_t)_prev) & ~(0x3)); }
|
|
||||||
debug_only(void* prev_addr() const { return (void*)&_prev; })
|
|
||||||
|
|
||||||
void linkAfter(FreeChunk* ptr) {
|
|
||||||
linkNext(ptr);
|
|
||||||
if (ptr != NULL) ptr->linkPrev(this);
|
|
||||||
}
|
|
||||||
void linkAfterNonNull(FreeChunk* ptr) {
|
|
||||||
assert(ptr != NULL, "precondition violation");
|
|
||||||
linkNext(ptr);
|
|
||||||
ptr->linkPrev(this);
|
|
||||||
}
|
|
||||||
void linkNext(FreeChunk* ptr) { _next = ptr; }
|
|
||||||
void linkPrev(FreeChunk* ptr) { _prev = (FreeChunk*)((intptr_t)ptr | 0x1); }
|
|
||||||
void clearPrev() { _prev = NULL; }
|
|
||||||
void clearNext() { _next = NULL; }
|
|
||||||
void dontCoalesce() {
|
|
||||||
// the block should be free
|
|
||||||
assert(isFree(), "Should look like a free block");
|
|
||||||
_prev = (FreeChunk*)(((intptr_t)_prev) | 0x2);
|
|
||||||
}
|
|
||||||
void markFree() { _prev = (FreeChunk*)((intptr_t)_prev | 0x1); }
|
|
||||||
void markNotFree() { _prev = NULL; }
|
|
||||||
|
|
||||||
size_t size() const { return _size; }
|
|
||||||
void setSize(size_t size) { _size = size; }
|
|
||||||
|
|
||||||
// For volatile reads:
|
|
||||||
size_t* size_addr() { return &_size; }
|
|
||||||
|
|
||||||
// Return the address past the end of this chunk
|
|
||||||
HeapWord* end() const { return ((HeapWord*) this) + _size; }
|
|
||||||
|
|
||||||
// debugging
|
|
||||||
void verify() const PRODUCT_RETURN;
|
|
||||||
void verifyList() const PRODUCT_RETURN;
|
|
||||||
void mangleAllocated(size_t size) PRODUCT_RETURN;
|
|
||||||
void mangleFreed(size_t size) PRODUCT_RETURN;
|
|
||||||
};
|
|
||||||
|
|
||||||
// Alignment helpers etc.
|
|
||||||
#define numQuanta(x,y) ((x+y-1)/y)
|
|
||||||
enum AlignmentConstants {
|
|
||||||
MinChunkSize = numQuanta(sizeof(FreeChunk), MinObjAlignmentInBytes) * MinObjAlignment
|
|
||||||
};
|
|
||||||
|
|
||||||
// A FreeBlockDictionary is an abstract superclass that will allow
|
// A FreeBlockDictionary is an abstract superclass that will allow
|
||||||
// a number of alternative implementations in the future.
|
// a number of alternative implementations in the future.
|
||||||
|
@ -47,15 +47,15 @@ void FreeChunk::mangleAllocated(size_t size) {
|
|||||||
Copy::fill_to_words(addr + hdr, size - hdr, baadbabeHeapWord);
|
Copy::fill_to_words(addr + hdr, size - hdr, baadbabeHeapWord);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FreeChunk::mangleFreed(size_t size) {
|
void FreeChunk::mangleFreed(size_t sz) {
|
||||||
assert(baadbabeHeapWord != deadbeefHeapWord, "Need distinct patterns");
|
assert(baadbabeHeapWord != deadbeefHeapWord, "Need distinct patterns");
|
||||||
// mangle all but the header of a just-freed block of storage
|
// mangle all but the header of a just-freed block of storage
|
||||||
// just prior to passing it to the storage dictionary
|
// just prior to passing it to the storage dictionary
|
||||||
assert(size >= MinChunkSize, "smallest size of object");
|
assert(sz >= MinChunkSize, "smallest size of object");
|
||||||
assert(size == _size, "just checking");
|
assert(sz == size(), "just checking");
|
||||||
HeapWord* addr = (HeapWord*)this;
|
HeapWord* addr = (HeapWord*)this;
|
||||||
size_t hdr = header_size();
|
size_t hdr = header_size();
|
||||||
Copy::fill_to_words(addr + hdr, size - hdr, deadbeefHeapWord);
|
Copy::fill_to_words(addr + hdr, sz - hdr, deadbeefHeapWord);
|
||||||
}
|
}
|
||||||
|
|
||||||
void FreeChunk::verifyList() const {
|
void FreeChunk::verifyList() const {
|
||||||
|
@ -0,0 +1,137 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2001-2005 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
//
|
||||||
|
// Free block maintenance for Concurrent Mark Sweep Generation
|
||||||
|
//
|
||||||
|
// The main data structure for free blocks are
|
||||||
|
// . an indexed array of small free blocks, and
|
||||||
|
// . a dictionary of large free blocks
|
||||||
|
//
|
||||||
|
|
||||||
|
// No virtuals in FreeChunk (don't want any vtables).
|
||||||
|
|
||||||
|
// A FreeChunk is merely a chunk that can be in a doubly linked list
|
||||||
|
// and has a size field. NOTE: FreeChunks are distinguished from allocated
|
||||||
|
// objects in two ways (by the sweeper), depending on whether the VM is 32 or
|
||||||
|
// 64 bits.
|
||||||
|
// In 32 bits or 64 bits without CompressedOops, the second word (prev) has the
|
||||||
|
// LSB set to indicate a free chunk; allocated objects' klass() pointers
|
||||||
|
// don't have their LSB set. The corresponding bit in the CMSBitMap is
|
||||||
|
// set when the chunk is allocated. There are also blocks that "look free"
|
||||||
|
// but are not part of the free list and should not be coalesced into larger
|
||||||
|
// free blocks. These free blocks have their two LSB's set.
|
||||||
|
|
||||||
|
class FreeChunk VALUE_OBJ_CLASS_SPEC {
|
||||||
|
friend class VMStructs;
|
||||||
|
// For 64 bit compressed oops, the markOop encodes both the size and the
|
||||||
|
// indication that this is a FreeChunk and not an object.
|
||||||
|
volatile size_t _size;
|
||||||
|
FreeChunk* _prev;
|
||||||
|
FreeChunk* _next;
|
||||||
|
|
||||||
|
markOop mark() const volatile { return (markOop)_size; }
|
||||||
|
void set_mark(markOop m) { _size = (size_t)m; }
|
||||||
|
|
||||||
|
public:
|
||||||
|
NOT_PRODUCT(static const size_t header_size();)
|
||||||
|
|
||||||
|
// Returns "true" if the address indicates that the block represents
|
||||||
|
// a free chunk.
|
||||||
|
static bool indicatesFreeChunk(const HeapWord* addr) {
|
||||||
|
// Force volatile read from addr because value might change between
|
||||||
|
// calls. We really want the read of _mark and _prev from this pointer
|
||||||
|
// to be volatile but making the fields volatile causes all sorts of
|
||||||
|
// compilation errors.
|
||||||
|
return ((volatile FreeChunk*)addr)->isFree();
|
||||||
|
}
|
||||||
|
|
||||||
|
bool isFree() const volatile {
|
||||||
|
LP64_ONLY(if (UseCompressedOops) return mark()->is_cms_free_chunk(); else)
|
||||||
|
return (((intptr_t)_prev) & 0x1) == 0x1;
|
||||||
|
}
|
||||||
|
bool cantCoalesce() const {
|
||||||
|
assert(isFree(), "can't get coalesce bit on not free");
|
||||||
|
return (((intptr_t)_prev) & 0x2) == 0x2;
|
||||||
|
}
|
||||||
|
void dontCoalesce() {
|
||||||
|
// the block should be free
|
||||||
|
assert(isFree(), "Should look like a free block");
|
||||||
|
_prev = (FreeChunk*)(((intptr_t)_prev) | 0x2);
|
||||||
|
}
|
||||||
|
FreeChunk* prev() const {
|
||||||
|
return (FreeChunk*)(((intptr_t)_prev) & ~(0x3));
|
||||||
|
}
|
||||||
|
|
||||||
|
debug_only(void* prev_addr() const { return (void*)&_prev; })
|
||||||
|
|
||||||
|
size_t size() const volatile {
|
||||||
|
LP64_ONLY(if (UseCompressedOops) return mark()->get_size(); else )
|
||||||
|
return _size;
|
||||||
|
}
|
||||||
|
void setSize(size_t sz) {
|
||||||
|
LP64_ONLY(if (UseCompressedOops) set_mark(markOopDesc::set_size_and_free(sz)); else )
|
||||||
|
_size = sz;
|
||||||
|
}
|
||||||
|
|
||||||
|
FreeChunk* next() const { return _next; }
|
||||||
|
|
||||||
|
void linkAfter(FreeChunk* ptr) {
|
||||||
|
linkNext(ptr);
|
||||||
|
if (ptr != NULL) ptr->linkPrev(this);
|
||||||
|
}
|
||||||
|
void linkAfterNonNull(FreeChunk* ptr) {
|
||||||
|
assert(ptr != NULL, "precondition violation");
|
||||||
|
linkNext(ptr);
|
||||||
|
ptr->linkPrev(this);
|
||||||
|
}
|
||||||
|
void linkNext(FreeChunk* ptr) { _next = ptr; }
|
||||||
|
void linkPrev(FreeChunk* ptr) {
|
||||||
|
LP64_ONLY(if (UseCompressedOops) _prev = ptr; else)
|
||||||
|
_prev = (FreeChunk*)((intptr_t)ptr | 0x1);
|
||||||
|
}
|
||||||
|
void clearPrev() { _prev = NULL; }
|
||||||
|
void clearNext() { _next = NULL; }
|
||||||
|
void markNotFree() {
|
||||||
|
LP64_ONLY(if (UseCompressedOops) set_mark(markOopDesc::prototype());)
|
||||||
|
// Also set _prev to null
|
||||||
|
_prev = NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Return the address past the end of this chunk
|
||||||
|
HeapWord* end() const { return ((HeapWord*) this) + size(); }
|
||||||
|
|
||||||
|
// debugging
|
||||||
|
void verify() const PRODUCT_RETURN;
|
||||||
|
void verifyList() const PRODUCT_RETURN;
|
||||||
|
void mangleAllocated(size_t size) PRODUCT_RETURN;
|
||||||
|
void mangleFreed(size_t size) PRODUCT_RETURN;
|
||||||
|
};
|
||||||
|
|
||||||
|
// Alignment helpers etc.
|
||||||
|
#define numQuanta(x,y) ((x+y-1)/y)
|
||||||
|
enum AlignmentConstants {
|
||||||
|
MinChunkSize = numQuanta(sizeof(FreeChunk), MinObjAlignmentInBytes) * MinObjAlignment
|
||||||
|
};
|
||||||
|
|
@ -23,6 +23,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#define VM_STRUCTS_CMS(nonstatic_field, \
|
#define VM_STRUCTS_CMS(nonstatic_field, \
|
||||||
|
volatile_nonstatic_field, \
|
||||||
static_field) \
|
static_field) \
|
||||||
nonstatic_field(CompactibleFreeListSpace, _collector, CMSCollector*) \
|
nonstatic_field(CompactibleFreeListSpace, _collector, CMSCollector*) \
|
||||||
nonstatic_field(CompactibleFreeListSpace, _bt, BlockOffsetArrayNonContigSpace) \
|
nonstatic_field(CompactibleFreeListSpace, _bt, BlockOffsetArrayNonContigSpace) \
|
||||||
@ -36,9 +37,9 @@
|
|||||||
nonstatic_field(CMSCollector, _markBitMap, CMSBitMap) \
|
nonstatic_field(CMSCollector, _markBitMap, CMSBitMap) \
|
||||||
nonstatic_field(ConcurrentMarkSweepGeneration, _cmsSpace, CompactibleFreeListSpace*) \
|
nonstatic_field(ConcurrentMarkSweepGeneration, _cmsSpace, CompactibleFreeListSpace*) \
|
||||||
static_field(ConcurrentMarkSweepThread, _collector, CMSCollector*) \
|
static_field(ConcurrentMarkSweepThread, _collector, CMSCollector*) \
|
||||||
|
volatile_nonstatic_field(FreeChunk, _size, size_t) \
|
||||||
nonstatic_field(FreeChunk, _next, FreeChunk*) \
|
nonstatic_field(FreeChunk, _next, FreeChunk*) \
|
||||||
nonstatic_field(FreeChunk, _prev, FreeChunk*) \
|
nonstatic_field(FreeChunk, _prev, FreeChunk*) \
|
||||||
nonstatic_field(FreeChunk, _size, size_t) \
|
|
||||||
nonstatic_field(LinearAllocBlock, _word_size, size_t) \
|
nonstatic_field(LinearAllocBlock, _word_size, size_t) \
|
||||||
nonstatic_field(FreeList, _size, size_t) \
|
nonstatic_field(FreeList, _size, size_t) \
|
||||||
nonstatic_field(FreeList, _count, ssize_t) \
|
nonstatic_field(FreeList, _count, ssize_t) \
|
||||||
|
@ -206,6 +206,7 @@ freeBlockDictionary.cpp thread_<os_family>.inline.hpp
|
|||||||
|
|
||||||
freeBlockDictionary.hpp allocation.hpp
|
freeBlockDictionary.hpp allocation.hpp
|
||||||
freeBlockDictionary.hpp debug.hpp
|
freeBlockDictionary.hpp debug.hpp
|
||||||
|
freeBlockDictionary.hpp freeChunk.hpp
|
||||||
freeBlockDictionary.hpp globalDefinitions.hpp
|
freeBlockDictionary.hpp globalDefinitions.hpp
|
||||||
freeBlockDictionary.hpp memRegion.hpp
|
freeBlockDictionary.hpp memRegion.hpp
|
||||||
freeBlockDictionary.hpp mutex.hpp
|
freeBlockDictionary.hpp mutex.hpp
|
||||||
@ -214,6 +215,14 @@ freeBlockDictionary.hpp ostream.hpp
|
|||||||
freeChunk.cpp copy.hpp
|
freeChunk.cpp copy.hpp
|
||||||
freeChunk.cpp freeBlockDictionary.hpp
|
freeChunk.cpp freeBlockDictionary.hpp
|
||||||
|
|
||||||
|
freeChunk.hpp allocation.hpp
|
||||||
|
freeChunk.hpp debug.hpp
|
||||||
|
freeChunk.hpp globalDefinitions.hpp
|
||||||
|
freeChunk.hpp markOop.hpp
|
||||||
|
freeChunk.hpp memRegion.hpp
|
||||||
|
freeChunk.hpp mutex.hpp
|
||||||
|
freeChunk.hpp ostream.hpp
|
||||||
|
|
||||||
freeList.cpp freeBlockDictionary.hpp
|
freeList.cpp freeBlockDictionary.hpp
|
||||||
freeList.cpp freeList.hpp
|
freeList.cpp freeList.hpp
|
||||||
freeList.cpp globals.hpp
|
freeList.cpp globals.hpp
|
||||||
|
@ -1004,6 +1004,9 @@ void PSParallelCompact::pre_compact(PreGCValues* pre_gc_values)
|
|||||||
|
|
||||||
DEBUG_ONLY(mark_bitmap()->verify_clear();)
|
DEBUG_ONLY(mark_bitmap()->verify_clear();)
|
||||||
DEBUG_ONLY(summary_data().verify_clear();)
|
DEBUG_ONLY(summary_data().verify_clear();)
|
||||||
|
|
||||||
|
// Have worker threads release resources the next time they run a task.
|
||||||
|
gc_task_manager()->release_all_resources();
|
||||||
}
|
}
|
||||||
|
|
||||||
void PSParallelCompact::post_compact()
|
void PSParallelCompact::post_compact()
|
||||||
@ -1949,12 +1952,6 @@ void PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
|||||||
TimeStamp compaction_start;
|
TimeStamp compaction_start;
|
||||||
TimeStamp collection_exit;
|
TimeStamp collection_exit;
|
||||||
|
|
||||||
// "serial_CM" is needed until the parallel implementation
|
|
||||||
// of the move and update is done.
|
|
||||||
ParCompactionManager* serial_CM = new ParCompactionManager();
|
|
||||||
// Don't initialize more than once.
|
|
||||||
// serial_CM->initialize(&summary_data(), mark_bitmap());
|
|
||||||
|
|
||||||
ParallelScavengeHeap* heap = gc_heap();
|
ParallelScavengeHeap* heap = gc_heap();
|
||||||
GCCause::Cause gc_cause = heap->gc_cause();
|
GCCause::Cause gc_cause = heap->gc_cause();
|
||||||
PSYoungGen* young_gen = heap->young_gen();
|
PSYoungGen* young_gen = heap->young_gen();
|
||||||
@ -1969,6 +1966,10 @@ void PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
|||||||
PreGCValues pre_gc_values;
|
PreGCValues pre_gc_values;
|
||||||
pre_compact(&pre_gc_values);
|
pre_compact(&pre_gc_values);
|
||||||
|
|
||||||
|
// Get the compaction manager reserved for the VM thread.
|
||||||
|
ParCompactionManager* const vmthread_cm =
|
||||||
|
ParCompactionManager::manager_array(gc_task_manager()->workers());
|
||||||
|
|
||||||
// Place after pre_compact() where the number of invocations is incremented.
|
// Place after pre_compact() where the number of invocations is incremented.
|
||||||
AdaptiveSizePolicyOutput(size_policy, heap->total_collections());
|
AdaptiveSizePolicyOutput(size_policy, heap->total_collections());
|
||||||
|
|
||||||
@ -2008,7 +2009,7 @@ void PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
|||||||
bool marked_for_unloading = false;
|
bool marked_for_unloading = false;
|
||||||
|
|
||||||
marking_start.update();
|
marking_start.update();
|
||||||
marking_phase(serial_CM, maximum_heap_compaction);
|
marking_phase(vmthread_cm, maximum_heap_compaction);
|
||||||
|
|
||||||
#ifndef PRODUCT
|
#ifndef PRODUCT
|
||||||
if (TraceParallelOldGCMarkingPhase) {
|
if (TraceParallelOldGCMarkingPhase) {
|
||||||
@ -2039,7 +2040,7 @@ void PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
bool max_on_system_gc = UseMaximumCompactionOnSystemGC && is_system_gc;
|
bool max_on_system_gc = UseMaximumCompactionOnSystemGC && is_system_gc;
|
||||||
summary_phase(serial_CM, maximum_heap_compaction || max_on_system_gc);
|
summary_phase(vmthread_cm, maximum_heap_compaction || max_on_system_gc);
|
||||||
|
|
||||||
#ifdef ASSERT
|
#ifdef ASSERT
|
||||||
if (VerifyParallelOldWithMarkSweep &&
|
if (VerifyParallelOldWithMarkSweep &&
|
||||||
@ -2067,13 +2068,13 @@ void PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
|||||||
// code can use the the forwarding pointers to
|
// code can use the the forwarding pointers to
|
||||||
// check the new pointer calculation. The restore_marks()
|
// check the new pointer calculation. The restore_marks()
|
||||||
// has to be done before the real compact.
|
// has to be done before the real compact.
|
||||||
serial_CM->set_action(ParCompactionManager::VerifyUpdate);
|
vmthread_cm->set_action(ParCompactionManager::VerifyUpdate);
|
||||||
compact_perm(serial_CM);
|
compact_perm(vmthread_cm);
|
||||||
compact_serial(serial_CM);
|
compact_serial(vmthread_cm);
|
||||||
serial_CM->set_action(ParCompactionManager::ResetObjects);
|
vmthread_cm->set_action(ParCompactionManager::ResetObjects);
|
||||||
compact_perm(serial_CM);
|
compact_perm(vmthread_cm);
|
||||||
compact_serial(serial_CM);
|
compact_serial(vmthread_cm);
|
||||||
serial_CM->set_action(ParCompactionManager::UpdateAndCopy);
|
vmthread_cm->set_action(ParCompactionManager::UpdateAndCopy);
|
||||||
|
|
||||||
// For debugging only
|
// For debugging only
|
||||||
PSMarkSweep::restore_marks();
|
PSMarkSweep::restore_marks();
|
||||||
@ -2084,16 +2085,14 @@ void PSParallelCompact::invoke_no_policy(bool maximum_heap_compaction) {
|
|||||||
compaction_start.update();
|
compaction_start.update();
|
||||||
// Does the perm gen always have to be done serially because
|
// Does the perm gen always have to be done serially because
|
||||||
// klasses are used in the update of an object?
|
// klasses are used in the update of an object?
|
||||||
compact_perm(serial_CM);
|
compact_perm(vmthread_cm);
|
||||||
|
|
||||||
if (UseParallelOldGCCompacting) {
|
if (UseParallelOldGCCompacting) {
|
||||||
compact();
|
compact();
|
||||||
} else {
|
} else {
|
||||||
compact_serial(serial_CM);
|
compact_serial(vmthread_cm);
|
||||||
}
|
}
|
||||||
|
|
||||||
delete serial_CM;
|
|
||||||
|
|
||||||
// Reset the mark bitmap, summary data, and do other bookkeeping. Must be
|
// Reset the mark bitmap, summary data, and do other bookkeeping. Must be
|
||||||
// done before resizing.
|
// done before resizing.
|
||||||
post_compact();
|
post_compact();
|
||||||
|
@ -66,7 +66,7 @@ void ImmutableSpace::print() const {
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void ImmutableSpace::verify(bool allow_dirty) const {
|
void ImmutableSpace::verify(bool allow_dirty) {
|
||||||
HeapWord* p = bottom();
|
HeapWord* p = bottom();
|
||||||
HeapWord* t = end();
|
HeapWord* t = end();
|
||||||
HeapWord* prev_p = NULL;
|
HeapWord* prev_p = NULL;
|
||||||
|
@ -59,5 +59,5 @@ class ImmutableSpace: public CHeapObj {
|
|||||||
// Debugging
|
// Debugging
|
||||||
virtual void print() const PRODUCT_RETURN;
|
virtual void print() const PRODUCT_RETURN;
|
||||||
virtual void print_short() const PRODUCT_RETURN;
|
virtual void print_short() const PRODUCT_RETURN;
|
||||||
virtual void verify(bool allow_dirty) const;
|
virtual void verify(bool allow_dirty);
|
||||||
};
|
};
|
||||||
|
@ -599,12 +599,28 @@ void MutableNUMASpace::initialize(MemRegion mr, bool clear_space) {
|
|||||||
// Mark the the holes in chunks below the top() as invalid.
|
// Mark the the holes in chunks below the top() as invalid.
|
||||||
void MutableNUMASpace::set_top(HeapWord* value) {
|
void MutableNUMASpace::set_top(HeapWord* value) {
|
||||||
bool found_top = false;
|
bool found_top = false;
|
||||||
for (int i = 0; i < lgrp_spaces()->length(); i++) {
|
for (int i = 0; i < lgrp_spaces()->length();) {
|
||||||
LGRPSpace *ls = lgrp_spaces()->at(i);
|
LGRPSpace *ls = lgrp_spaces()->at(i);
|
||||||
MutableSpace *s = ls->space();
|
MutableSpace *s = ls->space();
|
||||||
HeapWord *top = MAX2((HeapWord*)round_down((intptr_t)s->top(), page_size()), s->bottom());
|
HeapWord *top = MAX2((HeapWord*)round_down((intptr_t)s->top(), page_size()), s->bottom());
|
||||||
|
|
||||||
if (s->contains(value)) {
|
if (s->contains(value)) {
|
||||||
|
// Check if setting the chunk's top to a given value would create a hole less than
|
||||||
|
// a minimal object; assuming that's not the last chunk in which case we don't care.
|
||||||
|
if (i < lgrp_spaces()->length() - 1) {
|
||||||
|
size_t remainder = pointer_delta(s->end(), value);
|
||||||
|
const size_t minimal_object_size = oopDesc::header_size();
|
||||||
|
if (remainder < minimal_object_size && remainder > 0) {
|
||||||
|
// Add a filler object of a minimal size, it will cross the chunk boundary.
|
||||||
|
SharedHeap::fill_region_with_object(MemRegion(value, minimal_object_size));
|
||||||
|
value += minimal_object_size;
|
||||||
|
assert(!s->contains(value), "Should be in the next chunk");
|
||||||
|
// Restart the loop from the same chunk, since the value has moved
|
||||||
|
// to the next one.
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!os::numa_has_static_binding() && top < value && top < s->end()) {
|
if (!os::numa_has_static_binding() && top < value && top < s->end()) {
|
||||||
ls->add_invalid_region(MemRegion(top, value));
|
ls->add_invalid_region(MemRegion(top, value));
|
||||||
}
|
}
|
||||||
@ -620,6 +636,7 @@ void MutableNUMASpace::set_top(HeapWord* value) {
|
|||||||
s->set_top(s->end());
|
s->set_top(s->end());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
i++;
|
||||||
}
|
}
|
||||||
MutableSpace::set_top(value);
|
MutableSpace::set_top(value);
|
||||||
}
|
}
|
||||||
@ -700,12 +717,14 @@ HeapWord* MutableNUMASpace::cas_allocate(size_t size) {
|
|||||||
MutableSpace *s = lgrp_spaces()->at(i)->space();
|
MutableSpace *s = lgrp_spaces()->at(i)->space();
|
||||||
HeapWord *p = s->cas_allocate(size);
|
HeapWord *p = s->cas_allocate(size);
|
||||||
if (p != NULL) {
|
if (p != NULL) {
|
||||||
size_t remainder = pointer_delta(s->end(), p);
|
size_t remainder = pointer_delta(s->end(), p + size);
|
||||||
if (remainder < (size_t)oopDesc::header_size() && remainder > 0) {
|
if (remainder < (size_t)oopDesc::header_size() && remainder > 0) {
|
||||||
if (s->cas_deallocate(p, size)) {
|
if (s->cas_deallocate(p, size)) {
|
||||||
// We were the last to allocate and created a fragment less than
|
// We were the last to allocate and created a fragment less than
|
||||||
// a minimal object.
|
// a minimal object.
|
||||||
p = NULL;
|
p = NULL;
|
||||||
|
} else {
|
||||||
|
guarantee(false, "Deallocation should always succeed");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -761,10 +780,12 @@ void MutableNUMASpace::print_on(outputStream* st) const {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void MutableNUMASpace::verify(bool allow_dirty) const {
|
void MutableNUMASpace::verify(bool allow_dirty) {
|
||||||
for (int i = 0; i < lgrp_spaces()->length(); i++) {
|
// This can be called after setting an arbitary value to the space's top,
|
||||||
lgrp_spaces()->at(i)->space()->verify(allow_dirty);
|
// so an object can cross the chunk boundary. We ensure the parsablity
|
||||||
}
|
// of the space and just walk the objects in linear fashion.
|
||||||
|
ensure_parsability();
|
||||||
|
MutableSpace::verify(allow_dirty);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Scan pages and gather stats about page placement and size.
|
// Scan pages and gather stats about page placement and size.
|
||||||
|
@ -192,7 +192,7 @@ class MutableNUMASpace : public MutableSpace {
|
|||||||
// Debugging
|
// Debugging
|
||||||
virtual void print_on(outputStream* st) const;
|
virtual void print_on(outputStream* st) const;
|
||||||
virtual void print_short_on(outputStream* st) const;
|
virtual void print_short_on(outputStream* st) const;
|
||||||
virtual void verify(bool allow_dirty) const;
|
virtual void verify(bool allow_dirty);
|
||||||
|
|
||||||
virtual void set_top(HeapWord* value);
|
virtual void set_top(HeapWord* value);
|
||||||
};
|
};
|
||||||
|
@ -118,7 +118,7 @@ void MutableSpace::print_on(outputStream* st) const {
|
|||||||
bottom(), top(), end());
|
bottom(), top(), end());
|
||||||
}
|
}
|
||||||
|
|
||||||
void MutableSpace::verify(bool allow_dirty) const {
|
void MutableSpace::verify(bool allow_dirty) {
|
||||||
HeapWord* p = bottom();
|
HeapWord* p = bottom();
|
||||||
HeapWord* t = top();
|
HeapWord* t = top();
|
||||||
HeapWord* prev_p = NULL;
|
HeapWord* prev_p = NULL;
|
||||||
|
@ -98,5 +98,5 @@ class MutableSpace: public ImmutableSpace {
|
|||||||
virtual void print_on(outputStream* st) const;
|
virtual void print_on(outputStream* st) const;
|
||||||
virtual void print_short() const;
|
virtual void print_short() const;
|
||||||
virtual void print_short_on(outputStream* st) const;
|
virtual void print_short_on(outputStream* st) const;
|
||||||
virtual void verify(bool allow_dirty) const;
|
virtual void verify(bool allow_dirty);
|
||||||
};
|
};
|
||||||
|
@ -196,6 +196,8 @@ void CardTableModRefBS::resize_covered_region(MemRegion new_region) {
|
|||||||
assert(_whole_heap.contains(new_region),
|
assert(_whole_heap.contains(new_region),
|
||||||
"attempt to cover area not in reserved area");
|
"attempt to cover area not in reserved area");
|
||||||
debug_only(verify_guard();)
|
debug_only(verify_guard();)
|
||||||
|
// collided is true if the expansion would push into another committed region
|
||||||
|
debug_only(bool collided = false;)
|
||||||
int const ind = find_covering_region_by_base(new_region.start());
|
int const ind = find_covering_region_by_base(new_region.start());
|
||||||
MemRegion const old_region = _covered[ind];
|
MemRegion const old_region = _covered[ind];
|
||||||
assert(old_region.start() == new_region.start(), "just checking");
|
assert(old_region.start() == new_region.start(), "just checking");
|
||||||
@ -211,12 +213,36 @@ void CardTableModRefBS::resize_covered_region(MemRegion new_region) {
|
|||||||
}
|
}
|
||||||
// Align the end up to a page size (starts are already aligned).
|
// Align the end up to a page size (starts are already aligned).
|
||||||
jbyte* const new_end = byte_after(new_region.last());
|
jbyte* const new_end = byte_after(new_region.last());
|
||||||
HeapWord* const new_end_aligned =
|
HeapWord* new_end_aligned =
|
||||||
(HeapWord*) align_size_up((uintptr_t)new_end, _page_size);
|
(HeapWord*) align_size_up((uintptr_t)new_end, _page_size);
|
||||||
assert(new_end_aligned >= (HeapWord*) new_end,
|
assert(new_end_aligned >= (HeapWord*) new_end,
|
||||||
"align up, but less");
|
"align up, but less");
|
||||||
|
int ri = 0;
|
||||||
|
for (ri = 0; ri < _cur_covered_regions; ri++) {
|
||||||
|
if (ri != ind) {
|
||||||
|
if (_committed[ri].contains(new_end_aligned)) {
|
||||||
|
assert((new_end_aligned >= _committed[ri].start()) &&
|
||||||
|
(_committed[ri].start() > _committed[ind].start()),
|
||||||
|
"New end of committed region is inconsistent");
|
||||||
|
new_end_aligned = _committed[ri].start();
|
||||||
|
assert(new_end_aligned > _committed[ind].start(),
|
||||||
|
"New end of committed region is before start");
|
||||||
|
debug_only(collided = true;)
|
||||||
|
// Should only collide with 1 region
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#ifdef ASSERT
|
||||||
|
for (++ri; ri < _cur_covered_regions; ri++) {
|
||||||
|
assert(!_committed[ri].contains(new_end_aligned),
|
||||||
|
"New end of committed region is in a second committed region");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
// The guard page is always committed and should not be committed over.
|
// The guard page is always committed and should not be committed over.
|
||||||
HeapWord* const new_end_for_commit = MIN2(new_end_aligned, _guard_region.start());
|
HeapWord* const new_end_for_commit = MIN2(new_end_aligned,
|
||||||
|
_guard_region.start());
|
||||||
|
|
||||||
if (new_end_for_commit > cur_committed.end()) {
|
if (new_end_for_commit > cur_committed.end()) {
|
||||||
// Must commit new pages.
|
// Must commit new pages.
|
||||||
MemRegion const new_committed =
|
MemRegion const new_committed =
|
||||||
@ -239,9 +265,11 @@ void CardTableModRefBS::resize_covered_region(MemRegion new_region) {
|
|||||||
if (!uncommit_region.is_empty()) {
|
if (!uncommit_region.is_empty()) {
|
||||||
if (!os::uncommit_memory((char*)uncommit_region.start(),
|
if (!os::uncommit_memory((char*)uncommit_region.start(),
|
||||||
uncommit_region.byte_size())) {
|
uncommit_region.byte_size())) {
|
||||||
// Do better than this for Merlin
|
assert(false, "Card table contraction failed");
|
||||||
vm_exit_out_of_memory(uncommit_region.byte_size(),
|
// The call failed so don't change the end of the
|
||||||
"card table contraction");
|
// committed region. This is better than taking the
|
||||||
|
// VM down.
|
||||||
|
new_end_aligned = _committed[ind].end();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -257,8 +285,25 @@ void CardTableModRefBS::resize_covered_region(MemRegion new_region) {
|
|||||||
}
|
}
|
||||||
assert(index_for(new_region.last()) < (int) _guard_index,
|
assert(index_for(new_region.last()) < (int) _guard_index,
|
||||||
"The guard card will be overwritten");
|
"The guard card will be overwritten");
|
||||||
jbyte* const end = byte_after(new_region.last());
|
// This line commented out cleans the newly expanded region and
|
||||||
|
// not the aligned up expanded region.
|
||||||
|
// jbyte* const end = byte_after(new_region.last());
|
||||||
|
jbyte* const end = (jbyte*) new_end_for_commit;
|
||||||
|
assert((end >= byte_after(new_region.last())) || collided,
|
||||||
|
"Expect to be beyond new region unless impacting another region");
|
||||||
// do nothing if we resized downward.
|
// do nothing if we resized downward.
|
||||||
|
#ifdef ASSERT
|
||||||
|
for (int ri = 0; ri < _cur_covered_regions; ri++) {
|
||||||
|
if (ri != ind) {
|
||||||
|
// The end of the new committed region should not
|
||||||
|
// be in any existing region unless it matches
|
||||||
|
// the start of the next region.
|
||||||
|
assert(!_committed[ri].contains(end) ||
|
||||||
|
(_committed[ri].start() == (HeapWord*) end),
|
||||||
|
"Overlapping committed regions");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
#endif
|
||||||
if (entry < end) {
|
if (entry < end) {
|
||||||
memset(entry, clean_card, pointer_delta(end, entry, sizeof(jbyte)));
|
memset(entry, clean_card, pointer_delta(end, entry, sizeof(jbyte)));
|
||||||
}
|
}
|
||||||
|
@ -29,8 +29,10 @@
|
|||||||
//
|
//
|
||||||
// Bit-format of an object header (most significant first):
|
// Bit-format of an object header (most significant first):
|
||||||
//
|
//
|
||||||
//
|
// 32 bits: unused:0 hash:25 age:4 biased_lock:1 lock:2
|
||||||
// unused:0/25 hash:25/31 age:4 biased_lock:1 lock:2 = 32/64 bits
|
// 64 bits: unused:24 hash:31 cms:2 age:4 biased_lock:1 lock:2
|
||||||
|
// unused:20 size:35 cms:2 age:4 biased_lock:1 lock:2 (if cms
|
||||||
|
// free chunk)
|
||||||
//
|
//
|
||||||
// - hash contains the identity hash value: largest value is
|
// - hash contains the identity hash value: largest value is
|
||||||
// 31 bits, see os::random(). Also, 64-bit vm's require
|
// 31 bits, see os::random(). Also, 64-bit vm's require
|
||||||
@ -91,6 +93,7 @@ class markOopDesc: public oopDesc {
|
|||||||
biased_lock_bits = 1,
|
biased_lock_bits = 1,
|
||||||
max_hash_bits = BitsPerWord - age_bits - lock_bits - biased_lock_bits,
|
max_hash_bits = BitsPerWord - age_bits - lock_bits - biased_lock_bits,
|
||||||
hash_bits = max_hash_bits > 31 ? 31 : max_hash_bits,
|
hash_bits = max_hash_bits > 31 ? 31 : max_hash_bits,
|
||||||
|
cms_bits = LP64_ONLY(1) NOT_LP64(0),
|
||||||
epoch_bits = 2
|
epoch_bits = 2
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -106,7 +109,8 @@ class markOopDesc: public oopDesc {
|
|||||||
enum { lock_shift = 0,
|
enum { lock_shift = 0,
|
||||||
biased_lock_shift = lock_bits,
|
biased_lock_shift = lock_bits,
|
||||||
age_shift = lock_bits + biased_lock_bits,
|
age_shift = lock_bits + biased_lock_bits,
|
||||||
hash_shift = lock_bits + biased_lock_bits + age_bits,
|
cms_shift = age_shift + age_bits,
|
||||||
|
hash_shift = cms_shift + cms_bits,
|
||||||
epoch_shift = hash_shift
|
epoch_shift = hash_shift
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -118,7 +122,9 @@ class markOopDesc: public oopDesc {
|
|||||||
age_mask = right_n_bits(age_bits),
|
age_mask = right_n_bits(age_bits),
|
||||||
age_mask_in_place = age_mask << age_shift,
|
age_mask_in_place = age_mask << age_shift,
|
||||||
epoch_mask = right_n_bits(epoch_bits),
|
epoch_mask = right_n_bits(epoch_bits),
|
||||||
epoch_mask_in_place = epoch_mask << epoch_shift
|
epoch_mask_in_place = epoch_mask << epoch_shift,
|
||||||
|
cms_mask = right_n_bits(cms_bits),
|
||||||
|
cms_mask_in_place = cms_mask << cms_shift
|
||||||
#ifndef _WIN64
|
#ifndef _WIN64
|
||||||
,hash_mask = right_n_bits(hash_bits),
|
,hash_mask = right_n_bits(hash_bits),
|
||||||
hash_mask_in_place = (address_word)hash_mask << hash_shift
|
hash_mask_in_place = (address_word)hash_mask << hash_shift
|
||||||
@ -360,4 +366,40 @@ class markOopDesc: public oopDesc {
|
|||||||
|
|
||||||
// see the definition in markOop.cpp for the gory details
|
// see the definition in markOop.cpp for the gory details
|
||||||
bool should_not_be_cached() const;
|
bool should_not_be_cached() const;
|
||||||
|
|
||||||
|
// These markOops indicate cms free chunk blocks and not objects.
|
||||||
|
// In 64 bit, the markOop is set to distinguish them from oops.
|
||||||
|
// These are defined in 32 bit mode for vmStructs.
|
||||||
|
const static uintptr_t cms_free_chunk_pattern = 0x1;
|
||||||
|
|
||||||
|
// Constants for the size field.
|
||||||
|
enum { size_shift = cms_shift + cms_bits,
|
||||||
|
size_bits = 35 // need for compressed oops 32G
|
||||||
|
};
|
||||||
|
// These values are too big for Win64
|
||||||
|
const static uintptr_t size_mask = LP64_ONLY(right_n_bits(size_bits))
|
||||||
|
NOT_LP64(0);
|
||||||
|
const static uintptr_t size_mask_in_place =
|
||||||
|
(address_word)size_mask << size_shift;
|
||||||
|
|
||||||
|
#ifdef _LP64
|
||||||
|
static markOop cms_free_prototype() {
|
||||||
|
return markOop(((intptr_t)prototype() & ~cms_mask_in_place) |
|
||||||
|
((cms_free_chunk_pattern & cms_mask) << cms_shift));
|
||||||
|
}
|
||||||
|
uintptr_t cms_encoding() const {
|
||||||
|
return mask_bits(value() >> cms_shift, cms_mask);
|
||||||
|
}
|
||||||
|
bool is_cms_free_chunk() const {
|
||||||
|
return is_neutral() &&
|
||||||
|
(cms_encoding() & cms_free_chunk_pattern) == cms_free_chunk_pattern;
|
||||||
|
}
|
||||||
|
|
||||||
|
size_t get_size() const { return (size_t)(value() >> size_shift); }
|
||||||
|
static markOop set_size_and_free(size_t size) {
|
||||||
|
assert((size & ~size_mask) == 0, "shouldn't overflow size field");
|
||||||
|
return markOop(((intptr_t)cms_free_prototype() & ~size_mask_in_place) |
|
||||||
|
(((intptr_t)size & size_mask) << size_shift));
|
||||||
|
}
|
||||||
|
#endif // _LP64
|
||||||
};
|
};
|
||||||
|
@ -158,7 +158,6 @@ public:
|
|||||||
assert(ProfileTraps, "used only under +ProfileTraps");
|
assert(ProfileTraps, "used only under +ProfileTraps");
|
||||||
uint old_flags = (_header._struct._flags & flag_mask);
|
uint old_flags = (_header._struct._flags & flag_mask);
|
||||||
_header._struct._flags = (new_state << trap_shift) | old_flags;
|
_header._struct._flags = (new_state << trap_shift) | old_flags;
|
||||||
assert(trap_state() == new_state, "sanity");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
u1 flags() {
|
u1 flags() {
|
||||||
|
@ -565,10 +565,12 @@ Node* DecodeNNode::Identity(PhaseTransform* phase) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const Type *DecodeNNode::Value( PhaseTransform *phase ) const {
|
const Type *DecodeNNode::Value( PhaseTransform *phase ) const {
|
||||||
if (phase->type( in(1) ) == TypeNarrowOop::NULL_PTR) {
|
const Type *t = phase->type( in(1) );
|
||||||
return TypePtr::NULL_PTR;
|
if (t == Type::TOP) return Type::TOP;
|
||||||
}
|
if (t == TypeNarrowOop::NULL_PTR) return TypePtr::NULL_PTR;
|
||||||
return bottom_type();
|
|
||||||
|
assert(t->isa_narrowoop(), "only narrowoop here");
|
||||||
|
return t->is_narrowoop()->make_oopptr();
|
||||||
}
|
}
|
||||||
|
|
||||||
Node* DecodeNNode::decode(PhaseTransform* phase, Node* value) {
|
Node* DecodeNNode::decode(PhaseTransform* phase, Node* value) {
|
||||||
@ -599,10 +601,12 @@ Node* EncodePNode::Identity(PhaseTransform* phase) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const Type *EncodePNode::Value( PhaseTransform *phase ) const {
|
const Type *EncodePNode::Value( PhaseTransform *phase ) const {
|
||||||
if (phase->type( in(1) ) == TypePtr::NULL_PTR) {
|
const Type *t = phase->type( in(1) );
|
||||||
return TypeNarrowOop::NULL_PTR;
|
if (t == Type::TOP) return Type::TOP;
|
||||||
}
|
if (t == TypePtr::NULL_PTR) return TypeNarrowOop::NULL_PTR;
|
||||||
return bottom_type();
|
|
||||||
|
assert(t->isa_oopptr(), "only oopptr here");
|
||||||
|
return t->is_oopptr()->make_narrowoop();
|
||||||
}
|
}
|
||||||
|
|
||||||
Node* EncodePNode::encode(PhaseTransform* phase, Node* value) {
|
Node* EncodePNode::encode(PhaseTransform* phase, Node* value) {
|
||||||
|
@ -549,10 +549,18 @@ class Opaque1Node : public Node {
|
|||||||
virtual uint hash() const ; // { return NO_HASH; }
|
virtual uint hash() const ; // { return NO_HASH; }
|
||||||
virtual uint cmp( const Node &n ) const;
|
virtual uint cmp( const Node &n ) const;
|
||||||
public:
|
public:
|
||||||
Opaque1Node( Node *n ) : Node(0,n) {}
|
Opaque1Node( Compile* C, Node *n ) : Node(0,n) {
|
||||||
|
// Put it on the Macro nodes list to removed during macro nodes expansion.
|
||||||
|
init_flags(Flag_is_macro);
|
||||||
|
C->add_macro_node(this);
|
||||||
|
}
|
||||||
// Special version for the pre-loop to hold the original loop limit
|
// Special version for the pre-loop to hold the original loop limit
|
||||||
// which is consumed by range check elimination.
|
// which is consumed by range check elimination.
|
||||||
Opaque1Node( Node *n, Node* orig_limit ) : Node(0,n,orig_limit) {}
|
Opaque1Node( Compile* C, Node *n, Node* orig_limit ) : Node(0,n,orig_limit) {
|
||||||
|
// Put it on the Macro nodes list to removed during macro nodes expansion.
|
||||||
|
init_flags(Flag_is_macro);
|
||||||
|
C->add_macro_node(this);
|
||||||
|
}
|
||||||
Node* original_loop_limit() { return req()==3 ? in(2) : NULL; }
|
Node* original_loop_limit() { return req()==3 ? in(2) : NULL; }
|
||||||
virtual int Opcode() const;
|
virtual int Opcode() const;
|
||||||
virtual const Type *bottom_type() const { return TypeInt::INT; }
|
virtual const Type *bottom_type() const { return TypeInt::INT; }
|
||||||
@ -572,7 +580,11 @@ class Opaque2Node : public Node {
|
|||||||
virtual uint hash() const ; // { return NO_HASH; }
|
virtual uint hash() const ; // { return NO_HASH; }
|
||||||
virtual uint cmp( const Node &n ) const;
|
virtual uint cmp( const Node &n ) const;
|
||||||
public:
|
public:
|
||||||
Opaque2Node( Node *n ) : Node(0,n) {}
|
Opaque2Node( Compile* C, Node *n ) : Node(0,n) {
|
||||||
|
// Put it on the Macro nodes list to removed during macro nodes expansion.
|
||||||
|
init_flags(Flag_is_macro);
|
||||||
|
C->add_macro_node(this);
|
||||||
|
}
|
||||||
virtual int Opcode() const;
|
virtual int Opcode() const;
|
||||||
virtual const Type *bottom_type() const { return TypeInt::INT; }
|
virtual const Type *bottom_type() const { return TypeInt::INT; }
|
||||||
};
|
};
|
||||||
|
@ -307,7 +307,6 @@ static Block* raise_LCA_above_marks(Block* LCA, node_idx_t mark,
|
|||||||
|
|
||||||
// Test and set the visited bit.
|
// Test and set the visited bit.
|
||||||
if (mid->raise_LCA_visited() == mark) continue; // already visited
|
if (mid->raise_LCA_visited() == mark) continue; // already visited
|
||||||
mid->set_raise_LCA_visited(mark);
|
|
||||||
|
|
||||||
// Don't process the current LCA, otherwise the search may terminate early
|
// Don't process the current LCA, otherwise the search may terminate early
|
||||||
if (mid != LCA && mid->raise_LCA_mark() == mark) {
|
if (mid != LCA && mid->raise_LCA_mark() == mark) {
|
||||||
@ -317,6 +316,8 @@ static Block* raise_LCA_above_marks(Block* LCA, node_idx_t mark,
|
|||||||
assert(early->dominates(LCA), "early is high enough");
|
assert(early->dominates(LCA), "early is high enough");
|
||||||
// Resume searching at that point, skipping intermediate levels.
|
// Resume searching at that point, skipping intermediate levels.
|
||||||
worklist.push(LCA);
|
worklist.push(LCA);
|
||||||
|
if (LCA == mid)
|
||||||
|
continue; // Don't mark as visited to avoid early termination.
|
||||||
} else {
|
} else {
|
||||||
// Keep searching through this block's predecessors.
|
// Keep searching through this block's predecessors.
|
||||||
for (uint j = 1, jmax = mid->num_preds(); j < jmax; j++) {
|
for (uint j = 1, jmax = mid->num_preds(); j < jmax; j++) {
|
||||||
@ -324,6 +325,7 @@ static Block* raise_LCA_above_marks(Block* LCA, node_idx_t mark,
|
|||||||
worklist.push(mid_parent);
|
worklist.push(mid_parent);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
mid->set_raise_LCA_visited(mark);
|
||||||
}
|
}
|
||||||
return LCA;
|
return LCA;
|
||||||
}
|
}
|
||||||
|
@ -690,7 +690,7 @@ void PhaseIdealLoop::insert_pre_post_loops( IdealLoopTree *loop, Node_List &old_
|
|||||||
// (the main-loop trip-counter exit value) because we will be changing
|
// (the main-loop trip-counter exit value) because we will be changing
|
||||||
// the exit value (via unrolling) so we cannot constant-fold away the zero
|
// the exit value (via unrolling) so we cannot constant-fold away the zero
|
||||||
// trip guard until all unrolling is done.
|
// trip guard until all unrolling is done.
|
||||||
Node *zer_opaq = new (C, 2) Opaque1Node(incr);
|
Node *zer_opaq = new (C, 2) Opaque1Node(C, incr);
|
||||||
Node *zer_cmp = new (C, 3) CmpINode( zer_opaq, limit );
|
Node *zer_cmp = new (C, 3) CmpINode( zer_opaq, limit );
|
||||||
Node *zer_bol = new (C, 2) BoolNode( zer_cmp, b_test );
|
Node *zer_bol = new (C, 2) BoolNode( zer_cmp, b_test );
|
||||||
register_new_node( zer_opaq, new_main_exit );
|
register_new_node( zer_opaq, new_main_exit );
|
||||||
@ -760,7 +760,7 @@ void PhaseIdealLoop::insert_pre_post_loops( IdealLoopTree *loop, Node_List &old_
|
|||||||
// pre-loop, the main-loop may not execute at all. Later in life this
|
// pre-loop, the main-loop may not execute at all. Later in life this
|
||||||
// zero-trip guard will become the minimum-trip guard when we unroll
|
// zero-trip guard will become the minimum-trip guard when we unroll
|
||||||
// the main-loop.
|
// the main-loop.
|
||||||
Node *min_opaq = new (C, 2) Opaque1Node(limit);
|
Node *min_opaq = new (C, 2) Opaque1Node(C, limit);
|
||||||
Node *min_cmp = new (C, 3) CmpINode( pre_incr, min_opaq );
|
Node *min_cmp = new (C, 3) CmpINode( pre_incr, min_opaq );
|
||||||
Node *min_bol = new (C, 2) BoolNode( min_cmp, b_test );
|
Node *min_bol = new (C, 2) BoolNode( min_cmp, b_test );
|
||||||
register_new_node( min_opaq, new_pre_exit );
|
register_new_node( min_opaq, new_pre_exit );
|
||||||
@ -810,7 +810,7 @@ void PhaseIdealLoop::insert_pre_post_loops( IdealLoopTree *loop, Node_List &old_
|
|||||||
|
|
||||||
// Save the original loop limit in this Opaque1 node for
|
// Save the original loop limit in this Opaque1 node for
|
||||||
// use by range check elimination.
|
// use by range check elimination.
|
||||||
Node *pre_opaq = new (C, 3) Opaque1Node(pre_limit, limit);
|
Node *pre_opaq = new (C, 3) Opaque1Node(C, pre_limit, limit);
|
||||||
|
|
||||||
register_new_node( pre_limit, pre_head->in(0) );
|
register_new_node( pre_limit, pre_head->in(0) );
|
||||||
register_new_node( pre_opaq , pre_head->in(0) );
|
register_new_node( pre_opaq , pre_head->in(0) );
|
||||||
|
@ -205,7 +205,7 @@ ProjNode* PhaseIdealLoop::create_slow_version_of_loop(IdealLoopTree *loop,
|
|||||||
|
|
||||||
Node *cont = _igvn.intcon(1);
|
Node *cont = _igvn.intcon(1);
|
||||||
set_ctrl(cont, C->root());
|
set_ctrl(cont, C->root());
|
||||||
Node* opq = new (C, 2) Opaque1Node(cont);
|
Node* opq = new (C, 2) Opaque1Node(C, cont);
|
||||||
register_node(opq, outer_loop, entry, dom_depth(entry));
|
register_node(opq, outer_loop, entry, dom_depth(entry));
|
||||||
Node *bol = new (C, 2) Conv2BNode(opq);
|
Node *bol = new (C, 2) Conv2BNode(opq);
|
||||||
register_node(bol, outer_loop, entry, dom_depth(entry));
|
register_node(bol, outer_loop, entry, dom_depth(entry));
|
||||||
|
@ -2685,7 +2685,7 @@ void PhaseIdealLoop::reorg_offsets( IdealLoopTree *loop ) {
|
|||||||
if( !cle->stride_is_con() ) continue;
|
if( !cle->stride_is_con() ) continue;
|
||||||
// Hit! Refactor use to use the post-incremented tripcounter.
|
// Hit! Refactor use to use the post-incremented tripcounter.
|
||||||
// Compute a post-increment tripcounter.
|
// Compute a post-increment tripcounter.
|
||||||
Node *opaq = new (C, 2) Opaque2Node( cle->incr() );
|
Node *opaq = new (C, 2) Opaque2Node( C, cle->incr() );
|
||||||
register_new_node( opaq, u_ctrl );
|
register_new_node( opaq, u_ctrl );
|
||||||
Node *neg_stride = _igvn.intcon(-cle->stride_con());
|
Node *neg_stride = _igvn.intcon(-cle->stride_con());
|
||||||
set_ctrl(neg_stride, C->root());
|
set_ctrl(neg_stride, C->root());
|
||||||
|
@ -262,14 +262,16 @@ const Node* MachNode::get_base_and_disp(intptr_t &offset, const TypePtr* &adr_ty
|
|||||||
// Now we have collected every part of the ADLC MEMORY_INTER.
|
// Now we have collected every part of the ADLC MEMORY_INTER.
|
||||||
// See if it adds up to a base + offset.
|
// See if it adds up to a base + offset.
|
||||||
if (index != NULL) {
|
if (index != NULL) {
|
||||||
if (!index->is_Con()) {
|
|
||||||
const TypeNarrowOop* narrowoop = index->bottom_type()->isa_narrowoop();
|
const TypeNarrowOop* narrowoop = index->bottom_type()->isa_narrowoop();
|
||||||
if (narrowoop != NULL) {
|
if (narrowoop != NULL) { // EncodeN, LoadN, LoadConN, LoadNKlass.
|
||||||
// Memory references through narrow oops have a
|
// Memory references through narrow oops have a
|
||||||
// funny base so grab the type from the index.
|
// funny base so grab the type from the index:
|
||||||
adr_type = narrowoop->make_oopptr();
|
// [R12 + narrow_oop_reg<<3 + offset]
|
||||||
|
assert(base == NULL, "Memory references through narrow oops have no base");
|
||||||
|
offset = disp;
|
||||||
|
adr_type = narrowoop->make_oopptr()->add_offset(offset);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
} else if (!index->is_Con()) {
|
||||||
disp = Type::OffsetBot;
|
disp = Type::OffsetBot;
|
||||||
} else if (disp != Type::OffsetBot) {
|
} else if (disp != Type::OffsetBot) {
|
||||||
const TypeX* ti = index->bottom_type()->isa_intptr_t();
|
const TypeX* ti = index->bottom_type()->isa_intptr_t();
|
||||||
|
@ -1674,8 +1674,15 @@ bool PhaseMacroExpand::expand_macro_nodes() {
|
|||||||
success = eliminate_locking_node(n->as_AbstractLock());
|
success = eliminate_locking_node(n->as_AbstractLock());
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
if (n->Opcode() == Op_Opaque1 || n->Opcode() == Op_Opaque2) {
|
||||||
|
_igvn.add_users_to_worklist(n);
|
||||||
|
_igvn.hash_delete(n);
|
||||||
|
_igvn.subsume_node(n, n->in(1));
|
||||||
|
success = true;
|
||||||
|
} else {
|
||||||
assert(false, "unknown node type in macro list");
|
assert(false, "unknown node type in macro list");
|
||||||
}
|
}
|
||||||
|
}
|
||||||
assert(success == (C->macro_count() < old_macro_count), "elimination reduces macro count");
|
assert(success == (C->macro_count() < old_macro_count), "elimination reduces macro count");
|
||||||
progress = progress || success;
|
progress = progress || success;
|
||||||
}
|
}
|
||||||
|
@ -82,6 +82,7 @@ Matcher::Matcher( Node_List &proj_list ) :
|
|||||||
idealreg2debugmask[Op_RegF] = NULL;
|
idealreg2debugmask[Op_RegF] = NULL;
|
||||||
idealreg2debugmask[Op_RegD] = NULL;
|
idealreg2debugmask[Op_RegD] = NULL;
|
||||||
idealreg2debugmask[Op_RegP] = NULL;
|
idealreg2debugmask[Op_RegP] = NULL;
|
||||||
|
debug_only(_mem_node = NULL;) // Ideal memory node consumed by mach node
|
||||||
}
|
}
|
||||||
|
|
||||||
//------------------------------warp_incoming_stk_arg------------------------
|
//------------------------------warp_incoming_stk_arg------------------------
|
||||||
@ -1153,7 +1154,10 @@ MachNode *Matcher::match_tree( const Node *n ) {
|
|||||||
|
|
||||||
// StoreNodes require their Memory input to match any LoadNodes
|
// StoreNodes require their Memory input to match any LoadNodes
|
||||||
Node *mem = n->is_Store() ? n->in(MemNode::Memory) : (Node*)1 ;
|
Node *mem = n->is_Store() ? n->in(MemNode::Memory) : (Node*)1 ;
|
||||||
|
#ifdef ASSERT
|
||||||
|
Node* save_mem_node = _mem_node;
|
||||||
|
_mem_node = n->is_Store() ? (Node*)n : NULL;
|
||||||
|
#endif
|
||||||
// State object for root node of match tree
|
// State object for root node of match tree
|
||||||
// Allocate it on _states_arena - stack allocation can cause stack overflow.
|
// Allocate it on _states_arena - stack allocation can cause stack overflow.
|
||||||
State *s = new (&_states_arena) State;
|
State *s = new (&_states_arena) State;
|
||||||
@ -1205,6 +1209,7 @@ MachNode *Matcher::match_tree( const Node *n ) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
debug_only( _mem_node = save_mem_node; )
|
||||||
return m;
|
return m;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1445,8 +1450,30 @@ MachNode *Matcher::ReduceInst( State *s, int rule, Node *&mem ) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// If a Memory was used, insert a Memory edge
|
// If a Memory was used, insert a Memory edge
|
||||||
if( mem != (Node*)1 )
|
if( mem != (Node*)1 ) {
|
||||||
mach->ins_req(MemNode::Memory,mem);
|
mach->ins_req(MemNode::Memory,mem);
|
||||||
|
#ifdef ASSERT
|
||||||
|
// Verify adr type after matching memory operation
|
||||||
|
const MachOper* oper = mach->memory_operand();
|
||||||
|
if (oper != NULL && oper != (MachOper*)-1 &&
|
||||||
|
mach->adr_type() != TypeRawPtr::BOTTOM) { // non-direct addressing mode
|
||||||
|
// It has a unique memory operand. Find corresponding ideal mem node.
|
||||||
|
Node* m = NULL;
|
||||||
|
if (leaf->is_Mem()) {
|
||||||
|
m = leaf;
|
||||||
|
} else {
|
||||||
|
m = _mem_node;
|
||||||
|
assert(m != NULL && m->is_Mem(), "expecting memory node");
|
||||||
|
}
|
||||||
|
if (m->adr_type() != mach->adr_type()) {
|
||||||
|
m->dump();
|
||||||
|
tty->print_cr("mach:");
|
||||||
|
mach->dump(1);
|
||||||
|
}
|
||||||
|
assert(m->adr_type() == mach->adr_type(), "matcher should not change adr type");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
// If the _leaf is an AddP, insert the base edge
|
// If the _leaf is an AddP, insert the base edge
|
||||||
if( leaf->is_AddP() )
|
if( leaf->is_AddP() )
|
||||||
@ -1510,7 +1537,9 @@ void Matcher::ReduceInst_Chain_Rule( State *s, int rule, Node *&mem, MachNode *m
|
|||||||
assert( newrule >= _LAST_MACH_OPER, "Do NOT chain from internal operand");
|
assert( newrule >= _LAST_MACH_OPER, "Do NOT chain from internal operand");
|
||||||
mach->_opnds[1] = s->MachOperGenerator( _reduceOp[catch_op], C );
|
mach->_opnds[1] = s->MachOperGenerator( _reduceOp[catch_op], C );
|
||||||
Node *mem1 = (Node*)1;
|
Node *mem1 = (Node*)1;
|
||||||
|
debug_only(Node *save_mem_node = _mem_node;)
|
||||||
mach->add_req( ReduceInst(s, newrule, mem1) );
|
mach->add_req( ReduceInst(s, newrule, mem1) );
|
||||||
|
debug_only(_mem_node = save_mem_node;)
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -1520,6 +1549,7 @@ uint Matcher::ReduceInst_Interior( State *s, int rule, Node *&mem, MachNode *mac
|
|||||||
if( s->_leaf->is_Load() ) {
|
if( s->_leaf->is_Load() ) {
|
||||||
Node *mem2 = s->_leaf->in(MemNode::Memory);
|
Node *mem2 = s->_leaf->in(MemNode::Memory);
|
||||||
assert( mem == (Node*)1 || mem == mem2, "multiple Memories being matched at once?" );
|
assert( mem == (Node*)1 || mem == mem2, "multiple Memories being matched at once?" );
|
||||||
|
debug_only( if( mem == (Node*)1 ) _mem_node = s->_leaf;)
|
||||||
mem = mem2;
|
mem = mem2;
|
||||||
}
|
}
|
||||||
if( s->_leaf->in(0) != NULL && s->_leaf->req() > 1) {
|
if( s->_leaf->in(0) != NULL && s->_leaf->req() > 1) {
|
||||||
@ -1563,7 +1593,9 @@ uint Matcher::ReduceInst_Interior( State *s, int rule, Node *&mem, MachNode *mac
|
|||||||
// --> ReduceInst( newrule )
|
// --> ReduceInst( newrule )
|
||||||
mach->_opnds[num_opnds++] = s->MachOperGenerator( _reduceOp[catch_op], C );
|
mach->_opnds[num_opnds++] = s->MachOperGenerator( _reduceOp[catch_op], C );
|
||||||
Node *mem1 = (Node*)1;
|
Node *mem1 = (Node*)1;
|
||||||
|
debug_only(Node *save_mem_node = _mem_node;)
|
||||||
mach->add_req( ReduceInst( newstate, newrule, mem1 ) );
|
mach->add_req( ReduceInst( newstate, newrule, mem1 ) );
|
||||||
|
debug_only(_mem_node = save_mem_node;)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
assert( mach->_opnds[num_opnds-1], "" );
|
assert( mach->_opnds[num_opnds-1], "" );
|
||||||
@ -1594,6 +1626,7 @@ void Matcher::ReduceOper( State *s, int rule, Node *&mem, MachNode *mach ) {
|
|||||||
if( s->_leaf->is_Load() ) {
|
if( s->_leaf->is_Load() ) {
|
||||||
assert( mem == (Node*)1, "multiple Memories being matched at once?" );
|
assert( mem == (Node*)1, "multiple Memories being matched at once?" );
|
||||||
mem = s->_leaf->in(MemNode::Memory);
|
mem = s->_leaf->in(MemNode::Memory);
|
||||||
|
debug_only(_mem_node = s->_leaf;)
|
||||||
}
|
}
|
||||||
if( s->_leaf->in(0) && s->_leaf->req() > 1) {
|
if( s->_leaf->in(0) && s->_leaf->req() > 1) {
|
||||||
if( !mach->in(0) )
|
if( !mach->in(0) )
|
||||||
@ -1618,7 +1651,9 @@ void Matcher::ReduceOper( State *s, int rule, Node *&mem, MachNode *mach ) {
|
|||||||
// Reduce the instruction, and add a direct pointer from this
|
// Reduce the instruction, and add a direct pointer from this
|
||||||
// machine instruction to the newly reduced one.
|
// machine instruction to the newly reduced one.
|
||||||
Node *mem1 = (Node*)1;
|
Node *mem1 = (Node*)1;
|
||||||
|
debug_only(Node *save_mem_node = _mem_node;)
|
||||||
mach->add_req( ReduceInst( kid, newrule, mem1 ) );
|
mach->add_req( ReduceInst( kid, newrule, mem1 ) );
|
||||||
|
debug_only(_mem_node = save_mem_node;)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -104,6 +104,8 @@ class Matcher : public PhaseTransform {
|
|||||||
#ifdef ASSERT
|
#ifdef ASSERT
|
||||||
// Make sure only new nodes are reachable from this node
|
// Make sure only new nodes are reachable from this node
|
||||||
void verify_new_nodes_only(Node* root);
|
void verify_new_nodes_only(Node* root);
|
||||||
|
|
||||||
|
Node* _mem_node; // Ideal memory node consumed by mach node
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@ -253,11 +253,17 @@ bool MemNode::all_controls_dominate(Node* dom, Node* sub) {
|
|||||||
if (dom == NULL || dom->is_top() || sub == NULL || sub->is_top())
|
if (dom == NULL || dom->is_top() || sub == NULL || sub->is_top())
|
||||||
return false; // Conservative answer for dead code
|
return false; // Conservative answer for dead code
|
||||||
|
|
||||||
// Check 'dom'.
|
// Check 'dom'. Skip Proj and CatchProj nodes.
|
||||||
dom = dom->find_exact_control(dom);
|
dom = dom->find_exact_control(dom);
|
||||||
if (dom == NULL || dom->is_top())
|
if (dom == NULL || dom->is_top())
|
||||||
return false; // Conservative answer for dead code
|
return false; // Conservative answer for dead code
|
||||||
|
|
||||||
|
if (dom == sub) {
|
||||||
|
// For the case when, for example, 'sub' is Initialize and the original
|
||||||
|
// 'dom' is Proj node of the 'sub'.
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (dom->is_Con() || dom->is_Start() || dom->is_Root() || dom == sub)
|
if (dom->is_Con() || dom->is_Start() || dom->is_Root() || dom == sub)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
@ -271,6 +277,7 @@ bool MemNode::all_controls_dominate(Node* dom, Node* sub) {
|
|||||||
sub->is_Region(), "expecting only these nodes");
|
sub->is_Region(), "expecting only these nodes");
|
||||||
|
|
||||||
// Get control edge of 'sub'.
|
// Get control edge of 'sub'.
|
||||||
|
Node* orig_sub = sub;
|
||||||
sub = sub->find_exact_control(sub->in(0));
|
sub = sub->find_exact_control(sub->in(0));
|
||||||
if (sub == NULL || sub->is_top())
|
if (sub == NULL || sub->is_top())
|
||||||
return false; // Conservative answer for dead code
|
return false; // Conservative answer for dead code
|
||||||
@ -296,14 +303,16 @@ bool MemNode::all_controls_dominate(Node* dom, Node* sub) {
|
|||||||
|
|
||||||
for (uint next = 0; next < dom_list.size(); next++) {
|
for (uint next = 0; next < dom_list.size(); next++) {
|
||||||
Node* n = dom_list.at(next);
|
Node* n = dom_list.at(next);
|
||||||
|
if (n == orig_sub)
|
||||||
|
return false; // One of dom's inputs dominated by sub.
|
||||||
if (!n->is_CFG() && n->pinned()) {
|
if (!n->is_CFG() && n->pinned()) {
|
||||||
// Check only own control edge for pinned non-control nodes.
|
// Check only own control edge for pinned non-control nodes.
|
||||||
n = n->find_exact_control(n->in(0));
|
n = n->find_exact_control(n->in(0));
|
||||||
if (n == NULL || n->is_top())
|
if (n == NULL || n->is_top())
|
||||||
return false; // Conservative answer for dead code
|
return false; // Conservative answer for dead code
|
||||||
assert(n->is_CFG(), "expecting control");
|
assert(n->is_CFG(), "expecting control");
|
||||||
}
|
dom_list.push(n);
|
||||||
if (n->is_Con() || n->is_Start() || n->is_Root()) {
|
} else if (n->is_Con() || n->is_Start() || n->is_Root()) {
|
||||||
only_dominating_controls = true;
|
only_dominating_controls = true;
|
||||||
} else if (n->is_CFG()) {
|
} else if (n->is_CFG()) {
|
||||||
if (n->dominates(sub, nlist))
|
if (n->dominates(sub, nlist))
|
||||||
|
@ -1039,6 +1039,9 @@ Node* Node::find_exact_control(Node* ctrl) {
|
|||||||
//--------------------------dominates------------------------------------------
|
//--------------------------dominates------------------------------------------
|
||||||
// Helper function for MemNode::all_controls_dominate().
|
// Helper function for MemNode::all_controls_dominate().
|
||||||
// Check if 'this' control node dominates or equal to 'sub' control node.
|
// Check if 'this' control node dominates or equal to 'sub' control node.
|
||||||
|
// We already know that if any path back to Root or Start reaches 'this',
|
||||||
|
// then all paths so, so this is a simple search for one example,
|
||||||
|
// not an exhaustive search for a counterexample.
|
||||||
bool Node::dominates(Node* sub, Node_List &nlist) {
|
bool Node::dominates(Node* sub, Node_List &nlist) {
|
||||||
assert(this->is_CFG(), "expecting control");
|
assert(this->is_CFG(), "expecting control");
|
||||||
assert(sub != NULL && sub->is_CFG(), "expecting control");
|
assert(sub != NULL && sub->is_CFG(), "expecting control");
|
||||||
@ -1047,110 +1050,115 @@ bool Node::dominates(Node* sub, Node_List &nlist) {
|
|||||||
int iterations_without_region_limit = DominatorSearchLimit;
|
int iterations_without_region_limit = DominatorSearchLimit;
|
||||||
|
|
||||||
Node* orig_sub = sub;
|
Node* orig_sub = sub;
|
||||||
|
Node* dom = this;
|
||||||
|
bool met_dom = false;
|
||||||
nlist.clear();
|
nlist.clear();
|
||||||
bool this_dominates = false;
|
|
||||||
bool result = false; // Conservative answer
|
|
||||||
|
|
||||||
while (sub != NULL) { // walk 'sub' up the chain to 'this'
|
// Walk 'sub' backward up the chain to 'dom', watching for regions.
|
||||||
if (sub == this) {
|
// After seeing 'dom', continue up to Root or Start.
|
||||||
|
// If we hit a region (backward split point), it may be a loop head.
|
||||||
|
// Keep going through one of the region's inputs. If we reach the
|
||||||
|
// same region again, go through a different input. Eventually we
|
||||||
|
// will either exit through the loop head, or give up.
|
||||||
|
// (If we get confused, break out and return a conservative 'false'.)
|
||||||
|
while (sub != NULL) {
|
||||||
|
if (sub->is_top()) break; // Conservative answer for dead code.
|
||||||
|
if (sub == dom) {
|
||||||
if (nlist.size() == 0) {
|
if (nlist.size() == 0) {
|
||||||
// No Region nodes except loops were visited before and the EntryControl
|
// No Region nodes except loops were visited before and the EntryControl
|
||||||
// path was taken for loops: it did not walk in a cycle.
|
// path was taken for loops: it did not walk in a cycle.
|
||||||
result = true;
|
return true;
|
||||||
break;
|
} else if (met_dom) {
|
||||||
} else if (this_dominates) {
|
break; // already met before: walk in a cycle
|
||||||
result = false; // already met before: walk in a cycle
|
|
||||||
break;
|
|
||||||
} else {
|
} else {
|
||||||
// Region nodes were visited. Continue walk up to Start or Root
|
// Region nodes were visited. Continue walk up to Start or Root
|
||||||
// to make sure that it did not walk in a cycle.
|
// to make sure that it did not walk in a cycle.
|
||||||
this_dominates = true; // first time meet
|
met_dom = true; // first time meet
|
||||||
iterations_without_region_limit = DominatorSearchLimit; // Reset
|
iterations_without_region_limit = DominatorSearchLimit; // Reset
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (sub->is_Start() || sub->is_Root()) {
|
if (sub->is_Start() || sub->is_Root()) {
|
||||||
result = this_dominates;
|
// Success if we met 'dom' along a path to Start or Root.
|
||||||
break;
|
// We assume there are no alternative paths that avoid 'dom'.
|
||||||
|
// (This assumption is up to the caller to ensure!)
|
||||||
|
return met_dom;
|
||||||
}
|
}
|
||||||
Node* up = sub->find_exact_control(sub->in(0));
|
Node* up = sub->in(0);
|
||||||
if (up == NULL || up->is_top()) {
|
// Normalize simple pass-through regions and projections:
|
||||||
result = false; // Conservative answer for dead code
|
up = sub->find_exact_control(up);
|
||||||
break;
|
// If sub == up, we found a self-loop. Try to push past it.
|
||||||
}
|
if (sub == up && sub->is_Loop()) {
|
||||||
if (sub == up && (sub->is_Loop() || sub->is_Region() && sub->req() != 3)) {
|
// Take loop entry path on the way up to 'dom'.
|
||||||
// Take first valid path on the way up to 'this'.
|
|
||||||
up = sub->in(1); // in(LoopNode::EntryControl);
|
up = sub->in(1); // in(LoopNode::EntryControl);
|
||||||
|
} else if (sub == up && sub->is_Region() && sub->req() != 3) {
|
||||||
|
// Always take in(1) path on the way up to 'dom' for clone regions
|
||||||
|
// (with only one input) or regions which merge > 2 paths
|
||||||
|
// (usually used to merge fast/slow paths).
|
||||||
|
up = sub->in(1);
|
||||||
} else if (sub == up && sub->is_Region()) {
|
} else if (sub == up && sub->is_Region()) {
|
||||||
assert(sub->req() == 3, "sanity");
|
// Try both paths for Regions with 2 input paths (it may be a loop head).
|
||||||
|
// It could give conservative 'false' answer without information
|
||||||
|
// which region's input is the entry path.
|
||||||
iterations_without_region_limit = DominatorSearchLimit; // Reset
|
iterations_without_region_limit = DominatorSearchLimit; // Reset
|
||||||
|
|
||||||
// Try both paths for such Regions.
|
|
||||||
// It is not accurate without regions dominating information.
|
|
||||||
// With such information the other path should be checked for
|
|
||||||
// the most dominating Region which was visited before.
|
|
||||||
bool region_was_visited_before = false;
|
bool region_was_visited_before = false;
|
||||||
uint i = 1;
|
|
||||||
uint size = nlist.size();
|
|
||||||
if (size == 0) {
|
|
||||||
// No such Region nodes were visited before.
|
|
||||||
// Take first valid path on the way up to 'this'.
|
|
||||||
} else {
|
|
||||||
// Was this Region node visited before?
|
// Was this Region node visited before?
|
||||||
intptr_t ni;
|
// If so, we have reached it because we accidentally took a
|
||||||
int j = size - 1;
|
// loop-back edge from 'sub' back into the body of the loop,
|
||||||
for (; j >= 0; j--) {
|
// and worked our way up again to the loop header 'sub'.
|
||||||
ni = (intptr_t)nlist.at(j);
|
// So, take the first unexplored path on the way up to 'dom'.
|
||||||
if ((Node*)(ni & ~1) == sub) {
|
for (int j = nlist.size() - 1; j >= 0; j--) {
|
||||||
if ((ni & 1) != 0) {
|
intptr_t ni = (intptr_t)nlist.at(j);
|
||||||
break; // Visited 2 paths. Give up.
|
Node* visited = (Node*)(ni & ~1);
|
||||||
} else {
|
bool visited_twice_already = ((ni & 1) != 0);
|
||||||
|
if (visited == sub) {
|
||||||
|
if (visited_twice_already) {
|
||||||
|
// Visited 2 paths, but still stuck in loop body. Give up.
|
||||||
|
return false;
|
||||||
|
}
|
||||||
// The Region node was visited before only once.
|
// The Region node was visited before only once.
|
||||||
|
// (We will repush with the low bit set, below.)
|
||||||
nlist.remove(j);
|
nlist.remove(j);
|
||||||
|
// We will find a new edge and re-insert.
|
||||||
region_was_visited_before = true;
|
region_was_visited_before = true;
|
||||||
for (; i < sub->req(); i++) {
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Find an incoming edge which has not been seen yet; walk through it.
|
||||||
|
assert(up == sub, "");
|
||||||
|
uint skip = region_was_visited_before ? 1 : 0;
|
||||||
|
for (uint i = 1; i < sub->req(); i++) {
|
||||||
Node* in = sub->in(i);
|
Node* in = sub->in(i);
|
||||||
if (in != NULL && !in->is_top() && in != sub) {
|
if (in != NULL && !in->is_top() && in != sub) {
|
||||||
|
if (skip == 0) {
|
||||||
|
up = in;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
--skip; // skip this nontrivial input
|
||||||
i++; // Take other path.
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if (j >= 0 && (ni & 1) != 0) {
|
|
||||||
result = false; // Visited 2 paths. Give up.
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
// The Region node was not visited before.
|
|
||||||
}
|
|
||||||
for (; i < sub->req(); i++) {
|
|
||||||
Node* in = sub->in(i);
|
|
||||||
if (in != NULL && !in->is_top() && in != sub) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (i < sub->req()) {
|
|
||||||
up = sub->in(i);
|
|
||||||
if (region_was_visited_before && sub != up) {
|
|
||||||
// Set 0 bit to indicate that both paths were taken.
|
// Set 0 bit to indicate that both paths were taken.
|
||||||
nlist.push((Node*)((intptr_t)sub + 1));
|
nlist.push((Node*)((intptr_t)sub + (region_was_visited_before ? 1 : 0)));
|
||||||
} else {
|
|
||||||
nlist.push(sub);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (up == sub) {
|
||||||
|
break; // some kind of tight cycle
|
||||||
}
|
}
|
||||||
}
|
if (up == orig_sub && met_dom) {
|
||||||
if (sub == up) {
|
// returned back after visiting 'dom'
|
||||||
result = false; // some kind of tight cycle
|
break; // some kind of cycle
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
if (--iterations_without_region_limit < 0) {
|
if (--iterations_without_region_limit < 0) {
|
||||||
result = false; // dead cycle
|
break; // dead cycle
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
sub = up;
|
sub = up;
|
||||||
}
|
}
|
||||||
return result;
|
|
||||||
|
// Did not meet Root or Start node in pred. chain.
|
||||||
|
// Conservative answer for dead code.
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
//------------------------------remove_dead_region-----------------------------
|
//------------------------------remove_dead_region-----------------------------
|
||||||
|
@ -45,10 +45,13 @@ Node *SubNode::Identity( PhaseTransform *phase ) {
|
|||||||
return in(2)->in(2);
|
return in(2)->in(2);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Convert "(X+Y) - Y" into X
|
// Convert "(X+Y) - Y" into X and "(X+Y) - X" into Y
|
||||||
if( in(1)->Opcode() == Op_AddI ) {
|
if( in(1)->Opcode() == Op_AddI ) {
|
||||||
if( phase->eqv(in(1)->in(2),in(2)) )
|
if( phase->eqv(in(1)->in(2),in(2)) )
|
||||||
return in(1)->in(1);
|
return in(1)->in(1);
|
||||||
|
if (phase->eqv(in(1)->in(1),in(2)))
|
||||||
|
return in(1)->in(2);
|
||||||
|
|
||||||
// Also catch: "(X + Opaque2(Y)) - Y". In this case, 'Y' is a loop-varying
|
// Also catch: "(X + Opaque2(Y)) - Y". In this case, 'Y' is a loop-varying
|
||||||
// trip counter and X is likely to be loop-invariant (that's how O2 Nodes
|
// trip counter and X is likely to be loop-invariant (that's how O2 Nodes
|
||||||
// are originally used, although the optimizer sometimes jiggers things).
|
// are originally used, although the optimizer sometimes jiggers things).
|
||||||
|
@ -1174,7 +1174,7 @@ void Arguments::set_ergonomics_flags() {
|
|||||||
// field offset to determine free list chunk markers.
|
// field offset to determine free list chunk markers.
|
||||||
// Check that UseCompressedOops can be set with the max heap size allocated
|
// Check that UseCompressedOops can be set with the max heap size allocated
|
||||||
// by ergonomics.
|
// by ergonomics.
|
||||||
if (!UseConcMarkSweepGC && MaxHeapSize <= max_heap_for_compressed_oops()) {
|
if (MaxHeapSize <= max_heap_for_compressed_oops()) {
|
||||||
if (FLAG_IS_DEFAULT(UseCompressedOops)) {
|
if (FLAG_IS_DEFAULT(UseCompressedOops)) {
|
||||||
// Leave compressed oops off by default. Uncomment
|
// Leave compressed oops off by default. Uncomment
|
||||||
// the following line to return it to default status.
|
// the following line to return it to default status.
|
||||||
|
@ -2246,6 +2246,9 @@ class CommandLineFlags {
|
|||||||
product(bool, AggressiveOpts, false, \
|
product(bool, AggressiveOpts, false, \
|
||||||
"Enable aggressive optimizations - see arguments.cpp") \
|
"Enable aggressive optimizations - see arguments.cpp") \
|
||||||
\
|
\
|
||||||
|
product(bool, UseStringCache, false, \
|
||||||
|
"Enable String cache capabilities on String.java") \
|
||||||
|
\
|
||||||
/* statistics */ \
|
/* statistics */ \
|
||||||
develop(bool, UseVTune, false, \
|
develop(bool, UseVTune, false, \
|
||||||
"enable support for Intel's VTune profiler") \
|
"enable support for Intel's VTune profiler") \
|
||||||
|
@ -2926,6 +2926,7 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (AggressiveOpts) {
|
if (AggressiveOpts) {
|
||||||
|
{
|
||||||
// Forcibly initialize java/util/HashMap and mutate the private
|
// Forcibly initialize java/util/HashMap and mutate the private
|
||||||
// static final "frontCacheEnabled" field before we start creating instances
|
// static final "frontCacheEnabled" field before we start creating instances
|
||||||
#ifdef ASSERT
|
#ifdef ASSERT
|
||||||
@ -2944,6 +2945,26 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (UseStringCache) {
|
||||||
|
// Forcibly initialize java/lang/String and mutate the private
|
||||||
|
// static final "stringCacheEnabled" field before we start creating instances
|
||||||
|
#ifdef ASSERT
|
||||||
|
klassOop tmp_k = SystemDictionary::find(vmSymbolHandles::java_lang_String(), Handle(), Handle(), CHECK_0);
|
||||||
|
assert(tmp_k == NULL, "java/lang/String should not be loaded yet");
|
||||||
|
#endif
|
||||||
|
klassOop k_o = SystemDictionary::resolve_or_null(vmSymbolHandles::java_lang_String(), Handle(), Handle(), CHECK_0);
|
||||||
|
KlassHandle k = KlassHandle(THREAD, k_o);
|
||||||
|
guarantee(k.not_null(), "Must find java/lang/String");
|
||||||
|
instanceKlassHandle ik = instanceKlassHandle(THREAD, k());
|
||||||
|
ik->initialize(CHECK_0);
|
||||||
|
fieldDescriptor fd;
|
||||||
|
// Possible we might not find this field; if so, don't break
|
||||||
|
if (ik->find_local_field(vmSymbols::stringCacheEnabled_name(), vmSymbols::bool_signature(), &fd)) {
|
||||||
|
k()->bool_field_put(fd.offset(), true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Initialize java_lang.System (needed before creating the thread)
|
// Initialize java_lang.System (needed before creating the thread)
|
||||||
if (InitializeJavaLangSystem) {
|
if (InitializeJavaLangSystem) {
|
||||||
initialize_class(vmSymbolHandles::java_lang_System(), CHECK_0);
|
initialize_class(vmSymbolHandles::java_lang_System(), CHECK_0);
|
||||||
|
@ -1695,7 +1695,12 @@ static inline uint64_t cast_uint64_t(size_t x)
|
|||||||
declare_constant(markOopDesc::no_hash) \
|
declare_constant(markOopDesc::no_hash) \
|
||||||
declare_constant(markOopDesc::no_hash_in_place) \
|
declare_constant(markOopDesc::no_hash_in_place) \
|
||||||
declare_constant(markOopDesc::no_lock_in_place) \
|
declare_constant(markOopDesc::no_lock_in_place) \
|
||||||
declare_constant(markOopDesc::max_age)
|
declare_constant(markOopDesc::max_age) \
|
||||||
|
\
|
||||||
|
/* Constants in markOop used by CMS. */ \
|
||||||
|
declare_constant(markOopDesc::cms_shift) \
|
||||||
|
declare_constant(markOopDesc::cms_mask) \
|
||||||
|
declare_constant(markOopDesc::size_shift) \
|
||||||
|
|
||||||
/* NOTE that we do not use the last_entry() macro here; it is used */
|
/* NOTE that we do not use the last_entry() macro here; it is used */
|
||||||
/* in vmStructs_<os>_<cpu>.hpp's VM_LONG_CONSTANTS_OS_CPU macro (and */
|
/* in vmStructs_<os>_<cpu>.hpp's VM_LONG_CONSTANTS_OS_CPU macro (and */
|
||||||
@ -1959,6 +1964,7 @@ VMStructEntry VMStructs::localHotSpotVMStructs[] = {
|
|||||||
GENERATE_STATIC_VM_STRUCT_ENTRY)
|
GENERATE_STATIC_VM_STRUCT_ENTRY)
|
||||||
|
|
||||||
VM_STRUCTS_CMS(GENERATE_NONSTATIC_VM_STRUCT_ENTRY, \
|
VM_STRUCTS_CMS(GENERATE_NONSTATIC_VM_STRUCT_ENTRY, \
|
||||||
|
GENERATE_NONSTATIC_VM_STRUCT_ENTRY, \
|
||||||
GENERATE_STATIC_VM_STRUCT_ENTRY)
|
GENERATE_STATIC_VM_STRUCT_ENTRY)
|
||||||
#endif // SERIALGC
|
#endif // SERIALGC
|
||||||
|
|
||||||
@ -2100,6 +2106,7 @@ VMStructs::init() {
|
|||||||
CHECK_STATIC_VM_STRUCT_ENTRY);
|
CHECK_STATIC_VM_STRUCT_ENTRY);
|
||||||
|
|
||||||
VM_STRUCTS_CMS(CHECK_NONSTATIC_VM_STRUCT_ENTRY,
|
VM_STRUCTS_CMS(CHECK_NONSTATIC_VM_STRUCT_ENTRY,
|
||||||
|
CHECK_VOLATILE_NONSTATIC_VM_STRUCT_ENTRY,
|
||||||
CHECK_STATIC_VM_STRUCT_ENTRY);
|
CHECK_STATIC_VM_STRUCT_ENTRY);
|
||||||
#endif // SERIALGC
|
#endif // SERIALGC
|
||||||
|
|
||||||
@ -2204,6 +2211,7 @@ VMStructs::init() {
|
|||||||
debug_only(VM_STRUCTS_PARALLELGC(ENSURE_FIELD_TYPE_PRESENT, \
|
debug_only(VM_STRUCTS_PARALLELGC(ENSURE_FIELD_TYPE_PRESENT, \
|
||||||
ENSURE_FIELD_TYPE_PRESENT));
|
ENSURE_FIELD_TYPE_PRESENT));
|
||||||
debug_only(VM_STRUCTS_CMS(ENSURE_FIELD_TYPE_PRESENT, \
|
debug_only(VM_STRUCTS_CMS(ENSURE_FIELD_TYPE_PRESENT, \
|
||||||
|
ENSURE_FIELD_TYPE_PRESENT, \
|
||||||
ENSURE_FIELD_TYPE_PRESENT));
|
ENSURE_FIELD_TYPE_PRESENT));
|
||||||
#endif // SERIALGC
|
#endif // SERIALGC
|
||||||
debug_only(VM_STRUCTS_CPU(ENSURE_FIELD_TYPE_PRESENT, \
|
debug_only(VM_STRUCTS_CPU(ENSURE_FIELD_TYPE_PRESENT, \
|
||||||
|
820
hotspot/test/compiler/6714694/Tester.java
Normal file
820
hotspot/test/compiler/6714694/Tester.java
Normal file
@ -0,0 +1,820 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @test
|
||||||
|
* @bug 6714694
|
||||||
|
* @summary assertion in 64bit server vm (store->find_edge(load) != -1,"missing precedence edge") with COOPs
|
||||||
|
* @run main/othervm -Xcomp Tester
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* Complexity upper bound: 38602 ops */
|
||||||
|
|
||||||
|
interface Tester_Interface_0 {
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
abstract class Tester_Class_1 implements Tester_Interface_0 {
|
||||||
|
static int var_1 = (false ? (short)'b' : (short)-2.4256387E38F) | (byte)('g' * -7.660532860983624E307);
|
||||||
|
float var_2;
|
||||||
|
byte var_3;
|
||||||
|
static boolean var_4 = true;
|
||||||
|
double var_5 = 8.818325751338691E307;
|
||||||
|
Object var_6;
|
||||||
|
static short var_7;
|
||||||
|
final static char var_8 = 'x';
|
||||||
|
final static float var_9 = 2.2030989E38F;
|
||||||
|
|
||||||
|
|
||||||
|
public Tester_Class_1()
|
||||||
|
{
|
||||||
|
var_6 = (var_6 = (var_6 = "xkx"));
|
||||||
|
switch (var_7 = (var_3 = (byte)var_5))
|
||||||
|
{
|
||||||
|
case 113:
|
||||||
|
|
||||||
|
case 114:
|
||||||
|
Object var_12;
|
||||||
|
var_4 = 4.9121917E37F < 1957795258;
|
||||||
|
var_4 |= (var_4 ^= !var_4) ^ (var_4 |= var_4);
|
||||||
|
var_3 = (var_3 = (var_3 = (byte)+6010964363045275648L));
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 102:
|
||||||
|
|
||||||
|
}
|
||||||
|
final float var_13 = 1.2443151E38F;
|
||||||
|
var_3 = (byte)(var_1 |= (var_7 = (var_3 = (byte)var_5)));
|
||||||
|
var_2 = (long)(var_7 = (var_3 = (byte)var_8)) - (var_7 = (byte)386742565);
|
||||||
|
var_4 &= var_4;
|
||||||
|
var_2 = (long)((var_3 = (var_3 = (byte)var_8)) / ((var_4 ^= (var_5 /= var_9) <= (var_1 &= var_1)) ? (var_7 = (short)6872886933545336832L) : (byte)var_8));
|
||||||
|
var_6 = "uqflj";
|
||||||
|
{
|
||||||
|
switch (((new String[var_3 = (byte)var_5])[var_3 = (byte)8097442298927900672L]).charAt(1540148550))
|
||||||
|
{
|
||||||
|
case 'l':
|
||||||
|
|
||||||
|
}
|
||||||
|
var_2 = (var_7 = (byte)2.9859440663042714E307);
|
||||||
|
{
|
||||||
|
Object var_14;
|
||||||
|
}
|
||||||
|
var_3 = (var_3 = (var_3 = (byte)3.3634427195550136E307));
|
||||||
|
var_5 += '_';
|
||||||
|
}
|
||||||
|
var_6 = "tempfdjen";
|
||||||
|
var_3 = (((var_4 ^= new String("jmwiwmk").endsWith("rtlstmnuo")) ? !true : !false) ? true : (var_4 = false)) ? (var_3 = (byte)var_5) : (var_3 = (var_3 = (byte)var_5));
|
||||||
|
var_4 ^= false;
|
||||||
|
if (1.6435436003809043E307 != var_9)
|
||||||
|
{
|
||||||
|
boolean var_15 = true;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var_4 = false;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
Object var_16 = ((new Tester_Class_1[(byte)71832757][(byte)1.0694914E38F])[(byte)1315653071][(byte)(var_7 = (var_7 = (byte)var_8))]).var_6 = new int[(byte)var_8][var_3 = (byte)1933656747];
|
||||||
|
}
|
||||||
|
var_7 = (var_4 = var_4) ? (short)2.756967E37F : (short)'K';
|
||||||
|
byte var_17;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
abstract public Tester_Interface_0 func_0(double[][] arg_0, final Object arg_1);
|
||||||
|
|
||||||
|
|
||||||
|
final double func_0(final float arg_0, final short arg_1, final boolean arg_2)
|
||||||
|
{
|
||||||
|
var_6 = (var_6 = "lmshbl");
|
||||||
|
var_3 = (var_3 = (new byte[(new byte[(byte)arg_1])[var_3 = (byte)arg_0]])[var_3 = (var_3 = (byte)(var_1 >>>= var_1))]);
|
||||||
|
var_5 %= (var_3 = (byte)1909375874);
|
||||||
|
var_1 /= (char)(short)'i';
|
||||||
|
{
|
||||||
|
"vgar".length();
|
||||||
|
}
|
||||||
|
int var_10;
|
||||||
|
{
|
||||||
|
var_3 = (var_4 &= true) ? (byte)(var_5 *= 6375499657746206720L) : (byte)+ (var_5 /= var_9);
|
||||||
|
var_7 = (var_4 = true) ? (byte)(false ? (short)749593632 : (byte)8.692758043260743E307) : (byte)var_1;
|
||||||
|
((new Tester_Class_1[(byte)1.2890904018345944E308])[(byte)var_1]).var_3 = (var_3 = (byte)arg_0);
|
||||||
|
var_4 = true ^ var_4;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
var_1 ^= (var_3 = (var_3 = (var_3 = (byte)'U')));
|
||||||
|
}
|
||||||
|
var_3 = (var_3 = (var_3 = (var_3 = (byte)arg_1)));
|
||||||
|
char var_11;
|
||||||
|
var_1 += (var_2 = (var_7 = arg_1));
|
||||||
|
{
|
||||||
|
var_7 = (var_7 = arg_1);
|
||||||
|
}
|
||||||
|
var_7 = arg_1;
|
||||||
|
var_6 = (new char[(byte)1985094111797788672L][var_3 = (byte)3112604683090268160L])[var_3 = (byte)~ (var_3 = (byte)(var_5 += var_1))];
|
||||||
|
var_3 = (var_3 = (var_3 = (var_3 = (byte)3694858000202921984L)));
|
||||||
|
var_1 /= ~ ((byte)1311538336);
|
||||||
|
(((var_4 |= arg_2 ? !true && arg_2 : false) ? arg_2 : arg_2) ? "iih".substring(~ (var_3 = (byte)3.5401308E37F), 'g' * arg_1) : "gynskmvoj").trim();
|
||||||
|
var_3 = (var_3 = arg_2 ? (byte)+ ~5247392660383928320L : (byte)8392160279007184896L);
|
||||||
|
var_3 = (var_3 = (var_3 = (byte)var_8));
|
||||||
|
return (var_5 += 7.157559E37F) + (var_11 = 'V');
|
||||||
|
}
|
||||||
|
|
||||||
|
public String toString()
|
||||||
|
{
|
||||||
|
String result = "[\n";
|
||||||
|
result += "Tester_Class_1.var_7 = "; result += Tester.Printer.print(var_7);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_3 = "; result += Tester.Printer.print(var_3);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_8 = "; result += Tester.Printer.print(var_8);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_1 = "; result += Tester.Printer.print(var_1);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_4 = "; result += Tester.Printer.print(var_4);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_5 = "; result += Tester.Printer.print(var_5);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_2 = "; result += Tester.Printer.print(var_2);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_9 = "; result += Tester.Printer.print(var_9);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_1.var_6 = "; result += Tester.Printer.print(var_6);
|
||||||
|
result += "";
|
||||||
|
result += "\n]";
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
class Tester_Class_2 extends Tester_Class_1 implements Tester_Interface_0 {
|
||||||
|
final static String var_18 = false | Tester_Class_1.var_4 | (Tester_Class_1.var_4 &= (Tester_Class_1.var_4 |= (Tester_Class_1.var_4 = var_4))) ? "tbobyhqne" : "";
|
||||||
|
static String var_19 = "acxfj";
|
||||||
|
|
||||||
|
|
||||||
|
public Tester_Class_2()
|
||||||
|
{
|
||||||
|
Tester_Class_1.var_4 = !Tester_Class_1.var_4;
|
||||||
|
var_1++;
|
||||||
|
var_2 = (byte)2.4009747E38F;
|
||||||
|
new String();
|
||||||
|
var_6 = (var_19 = "hsshyw");
|
||||||
|
var_19 = var_19;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public Tester_Interface_0 func_0(double[][] arg_0, final Object arg_1)
|
||||||
|
{
|
||||||
|
var_5 = 4.0352057E37F;
|
||||||
|
(((false && ! ((Tester_Class_1.var_4 |= !true) ^ (Tester_Class_1.var_4 ^ false))) ^ (var_4 &= true) ? var_4 : (var_4 ^= true)) ? "spskwj" : "xcqianm").length();
|
||||||
|
((var_4 |= (Tester_Class_1.var_4 ^= Tester_Class_1.var_4) ? (Tester_Class_1.var_4 &= false) : (Tester_Class_1.var_4 |= Tester_Class_1.var_4)) ? (Tester_Class_1)(var_6 = new double[(byte)6.628342687109622E307]) : (Tester_Class_1)arg_1).var_6 = arg_0;
|
||||||
|
var_7 = (short)(byte)(short)8775325134193811456L;
|
||||||
|
var_4 ^= (var_4 &= !false);
|
||||||
|
((Tester_Class_1)arg_1).var_3 = (var_3 = (byte)(var_5 %= 8.933448E37F));
|
||||||
|
Tester_Class_1 var_20 = Tester_Class_1.var_4 ? (Tester_Class_1)arg_1 : (Tester_Class_1)arg_1;
|
||||||
|
{
|
||||||
|
var_19.endsWith(var_19);
|
||||||
|
var_6 = var_20;
|
||||||
|
(var_20 = (var_20 = var_20)).var_2 = (short)('p' <= 1986176769 % (int)2242661265280256000L % 2664882044098145280L ? ~ (var_3 = (byte)1.1892553447967157E308) & ~1806805036550279168L : (var_7 = (byte)var_8));
|
||||||
|
}
|
||||||
|
final boolean var_21 = Tester_Class_1.var_4;
|
||||||
|
var_20.var_3 = (var_3 = (var_20.var_3 = (byte)'t'));
|
||||||
|
boolean var_22 = true;
|
||||||
|
Tester_Class_1.var_4 |= (var_4 = var_21);
|
||||||
|
var_19 = "ocn";
|
||||||
|
var_19 = var_19;
|
||||||
|
var_1 *= Tester_Class_1.var_8;
|
||||||
|
var_20 = var_22 ? var_20 : var_20;
|
||||||
|
var_7 = var_21 ? (byte)+ ((byte)var_1) : ((var_20 = (var_20 = var_20)).var_3 = (var_3 = (var_3 = (byte)'L')));
|
||||||
|
return true ? (var_20 = var_20) : (new Tester_Interface_0[(byte)5618282952859970560L])[var_3 = (byte)Tester_Class_1.var_8];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public boolean equals(Object obj)
|
||||||
|
{
|
||||||
|
Tester_Class_1.var_7 = (var_7 = (((Tester_Class_1)obj).var_3 = (byte)var_9));
|
||||||
|
{
|
||||||
|
final Tester_Class_1 var_23 = (Tester_Class_1)obj;
|
||||||
|
}
|
||||||
|
++Tester_Class_1.var_1;
|
||||||
|
var_5 = (Tester_Class_1.var_7 = var_4 ? (Tester_Class_1.var_7 = (((Tester_Class_1)obj).var_3 = (byte)Tester_Class_1.var_8)) : (var_7 = (byte)var_9));
|
||||||
|
((Tester_Class_1)obj).var_6 = var_18.replace(Tester_Class_1.var_8, Tester_Class_1.var_8);
|
||||||
|
((new Tester_Class_1[((Tester_Class_1)(obj = new char[var_3 = (byte)Tester_Class_1.var_8])).var_3 = (((Tester_Class_1)obj).var_3 = (byte)(var_1 %= 787509251458841600L))])[(new byte[var_3 = (byte)Tester_Class_1.var_1])[((Tester_Class_1)obj).var_3 = (byte)1.2382548E38F]]).var_3 = (((Tester_Class_1)obj).var_3 = var_4 ? (byte)Tester_Class_1.var_8 : (byte)4.1085164E36F);
|
||||||
|
var_1 &= var_8;
|
||||||
|
var_7 = var_4 ? (var_3 = (byte)var_8) : (byte)var_5;
|
||||||
|
var_19 = var_18;
|
||||||
|
("o".compareTo("kwlfk") > (var_2 = 5289241662482067456L) ? (Tester_Class_1)obj : (Tester_Class_1)obj).var_5 -= (((Tester_Class_1)obj).var_3 = (((Tester_Class_1)obj).var_3 = (((Tester_Class_1)obj).var_3 = (byte)var_9)));
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public String toString()
|
||||||
|
{
|
||||||
|
String result = "[\n";
|
||||||
|
result += "Tester_Class_2.var_7 = "; result += Tester.Printer.print(var_7);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_8 = "; result += Tester.Printer.print(var_8);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_3 = "; result += Tester.Printer.print(var_3);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_18 = "; result += Tester.Printer.print(var_18);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_19 = "; result += Tester.Printer.print(var_19);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_1 = "; result += Tester.Printer.print(var_1);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_4 = "; result += Tester.Printer.print(var_4);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_5 = "; result += Tester.Printer.print(var_5);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_2 = "; result += Tester.Printer.print(var_2);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_9 = "; result += Tester.Printer.print(var_9);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_2.var_6 = "; result += Tester.Printer.print(var_6);
|
||||||
|
result += "";
|
||||||
|
result += "\n]";
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
class Tester_Class_3 extends Tester_Class_2 implements Tester_Interface_0 {
|
||||||
|
long var_24 = 9026266006808413184L;
|
||||||
|
char var_25;
|
||||||
|
String var_26 = ((var_4 ^= Tester_Class_1.var_4) ? (!true ? false : (var_4 |= true)) : (Tester_Class_2.var_4 ^= var_4)) ? "dkmhvhl" : (var_19 = (Tester_Class_2.var_19 = (Tester_Class_2.var_19 = var_18)));
|
||||||
|
static Tester_Class_2 var_27;
|
||||||
|
short var_28 = Tester_Class_2.var_7 = (short)(Tester_Class_2.var_1 &= (var_3 = (var_3 = (var_3 = (byte)Tester_Class_2.var_9))));
|
||||||
|
static boolean var_29 = false;
|
||||||
|
static Object[][] var_30;
|
||||||
|
int var_31 = 750583762;
|
||||||
|
Tester_Class_2 var_32;
|
||||||
|
final static long var_33 = 3050784555932008448L;
|
||||||
|
|
||||||
|
|
||||||
|
public Tester_Class_3()
|
||||||
|
{
|
||||||
|
byte[] var_34;
|
||||||
|
var_4 &= (Tester_Class_1.var_4 = true);
|
||||||
|
Tester_Class_1.var_1--;
|
||||||
|
switch (var_28 >>= ~ ((byte)var_28))
|
||||||
|
{
|
||||||
|
case 9:
|
||||||
|
|
||||||
|
case 26:
|
||||||
|
Tester_Class_1.var_4 ^= Tester_Class_1.var_4;
|
||||||
|
(Tester_Class_2.var_19 = "pwtic").indexOf(Tester_Class_2.var_18);
|
||||||
|
var_26.indexOf(var_19);
|
||||||
|
((Tester_Class_1)(new Tester_Interface_0[(byte)var_5])[var_24 <= var_31 ? (byte)'^' : (byte)var_24]).var_2 = 5611775846881101824L;
|
||||||
|
var_29 |= (Tester_Class_2.var_4 ^= var_29);
|
||||||
|
Tester_Class_2 var_35;
|
||||||
|
var_24 <<= (var_31 >>= (var_25 = var_8));
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 28:
|
||||||
|
|
||||||
|
}
|
||||||
|
new String();
|
||||||
|
var_5 %= (var_25 = 'n');
|
||||||
|
((Tester_Class_2)(Tester_Class_1)(((Tester_Class_1)(var_6 = Tester_Class_2.var_18)).var_6 = (var_26 = ""))).var_2 = var_31;
|
||||||
|
--var_1;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public String toString()
|
||||||
|
{
|
||||||
|
String result = "[\n";
|
||||||
|
result += "Tester_Class_3.var_8 = "; result += Tester.Printer.print(var_8);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_25 = "; result += Tester.Printer.print(var_25);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_1 = "; result += Tester.Printer.print(var_1);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_31 = "; result += Tester.Printer.print(var_31);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_30 = "; result += Tester.Printer.print(var_30);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_24 = "; result += Tester.Printer.print(var_24);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_33 = "; result += Tester.Printer.print(var_33);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_5 = "; result += Tester.Printer.print(var_5);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_2 = "; result += Tester.Printer.print(var_2);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_9 = "; result += Tester.Printer.print(var_9);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_7 = "; result += Tester.Printer.print(var_7);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_28 = "; result += Tester.Printer.print(var_28);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_3 = "; result += Tester.Printer.print(var_3);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_18 = "; result += Tester.Printer.print(var_18);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_19 = "; result += Tester.Printer.print(var_19);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_26 = "; result += Tester.Printer.print(var_26);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_4 = "; result += Tester.Printer.print(var_4);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_29 = "; result += Tester.Printer.print(var_29);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_27 = "; result += Tester.Printer.print(var_27);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_32 = "; result += Tester.Printer.print(var_32);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester_Class_3.var_6 = "; result += Tester.Printer.print(var_6);
|
||||||
|
result += "";
|
||||||
|
result += "\n]";
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class Tester {
|
||||||
|
static double var_36 = 2.679028326789642E307;
|
||||||
|
float var_37;
|
||||||
|
String var_38 = Tester_Class_2.var_18;
|
||||||
|
static Tester_Interface_0 var_39;
|
||||||
|
static char var_40 = 'D';
|
||||||
|
Tester_Class_1 var_41;
|
||||||
|
static int var_42;
|
||||||
|
final static boolean var_43 = false;
|
||||||
|
|
||||||
|
|
||||||
|
final static Tester_Class_2 func_0(Tester_Class_1 arg_0, final Tester_Class_2 arg_1)
|
||||||
|
{
|
||||||
|
"ooots".replaceFirst("rdxor", ((new Tester_Class_3[arg_1.var_3 = (byte)2.7836305E38F])[arg_0.var_3 = (byte)+ + +1.4958218616334936E307]).var_26);
|
||||||
|
if (true)
|
||||||
|
{
|
||||||
|
arg_0 = (Tester_Class_3)arg_0;
|
||||||
|
((Tester_Class_3)arg_0).var_25 = var_40;
|
||||||
|
final Tester_Class_2 var_44 = (Tester_Class_2)((Tester_Class_3.var_29 |= var_43) ? arg_0 : (arg_0.var_6 = Tester_Class_3.var_18));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var_39 = (Tester_Class_3.var_27 = (Tester_Class_3)arg_1);
|
||||||
|
}
|
||||||
|
Tester_Class_3.var_19 = "onndgsil";
|
||||||
|
var_39 = arg_0;
|
||||||
|
return (Tester_Class_2.var_4 &= Tester_Class_2.var_4 ^ true) ? (((Tester_Class_3)arg_0).var_32 = (Tester_Class_3)arg_1) : (((Tester_Class_3)arg_0).var_32 = (Tester_Class_3)arg_1);
|
||||||
|
}
|
||||||
|
|
||||||
|
private final static float func_1(final short arg_0, int[][] arg_1, final long arg_2)
|
||||||
|
{
|
||||||
|
Tester_Class_2.var_1 *= arg_0;
|
||||||
|
double var_45 = 6.841391103184752E307;
|
||||||
|
long var_46;
|
||||||
|
Tester_Class_2.var_1--;
|
||||||
|
--var_40;
|
||||||
|
++var_40;
|
||||||
|
++Tester_Class_3.var_1;
|
||||||
|
Tester_Class_1.var_4 = false;
|
||||||
|
var_36 %= 'X';
|
||||||
|
++Tester_Class_2.var_1;
|
||||||
|
Tester_Class_1.var_1++;
|
||||||
|
return 3.2422038E38F;
|
||||||
|
}
|
||||||
|
|
||||||
|
private final static char func_2(double arg_0, final byte arg_1, int arg_2)
|
||||||
|
{
|
||||||
|
--Tester_Class_3.var_1;
|
||||||
|
if (Tester_Class_1.var_4)
|
||||||
|
{
|
||||||
|
if (var_43)
|
||||||
|
{
|
||||||
|
Tester_Class_3.var_1++;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var_40 <<= 1329560515532651520L;
|
||||||
|
}
|
||||||
|
(false & Tester_Class_2.var_4 ? (new Tester_Class_1[arg_1])[arg_1] : (new Tester_Class_1[arg_1][arg_1])[arg_1][arg_1]).var_3 = arg_1;
|
||||||
|
Tester_Class_2.var_19 = Tester_Class_3.var_19;
|
||||||
|
--var_40;
|
||||||
|
final long var_47 = ~Tester_Class_3.var_33 << var_40--;
|
||||||
|
((Tester_Class_3)(new Tester_Class_2[arg_1][arg_1])[arg_1][arg_1]).var_24 *= (var_36 *= (long)arg_1 * ~arg_1);
|
||||||
|
Tester_Class_2.var_19 = Tester_Class_2.var_19;
|
||||||
|
++((new Tester_Class_3[arg_1])[arg_1]).var_24;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var_40++;
|
||||||
|
}
|
||||||
|
var_40 <<= var_40;
|
||||||
|
if (true)
|
||||||
|
{
|
||||||
|
++arg_2;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Tester_Class_2.var_7 = arg_1;
|
||||||
|
}
|
||||||
|
boolean var_48 = true;
|
||||||
|
var_36 /= arg_1;
|
||||||
|
final short var_49 = 15276;
|
||||||
|
Tester_Interface_0 var_50;
|
||||||
|
((Tester_Class_2.var_19 = (Tester_Class_2.var_19 = Tester_Class_2.var_19)) + "xhi").toString();
|
||||||
|
arg_2++;
|
||||||
|
return var_40;
|
||||||
|
}
|
||||||
|
|
||||||
|
public final static char func_4(final boolean arg_0)
|
||||||
|
{
|
||||||
|
float var_52 = 2.8063675E38F;
|
||||||
|
var_40--;
|
||||||
|
Object var_53;
|
||||||
|
Tester_Class_3.var_29 |= (Tester_Class_3.var_29 &= true);
|
||||||
|
if (!Tester_Class_1.var_4)
|
||||||
|
{
|
||||||
|
--var_40;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var_52 %= 2027756834;
|
||||||
|
}
|
||||||
|
int var_54 = Tester_Class_1.var_1++;
|
||||||
|
var_40--;
|
||||||
|
long var_55;
|
||||||
|
byte var_56 = 97;
|
||||||
|
var_36 *= 9.75628909363086E307 % + -1.9812653793936264E306;
|
||||||
|
int var_57;
|
||||||
|
boolean var_58 = Tester_Class_1.var_4 ^= var_43;
|
||||||
|
return 'J';
|
||||||
|
}
|
||||||
|
|
||||||
|
static float func_5(final Object arg_0, float arg_1, final Tester_Class_2 arg_2)
|
||||||
|
{
|
||||||
|
var_39 = arg_2;
|
||||||
|
Tester_Class_3.var_27 = arg_2;
|
||||||
|
arg_1 %= 1.7777554E38F;
|
||||||
|
var_39 = (Tester_Class_3.var_27 = arg_2);
|
||||||
|
Tester_Class_3 var_59;
|
||||||
|
{
|
||||||
|
var_40 -= arg_1 - ~ (((Tester_Class_3)arg_2).var_3 = (byte)1455854212);
|
||||||
|
}
|
||||||
|
Object var_60 = Tester_Class_1.var_4 ? arg_0 : new String[arg_2.var_3 = (byte)arg_1][(byte)((Tester_Class_3)arg_0).var_28];
|
||||||
|
Tester_Class_3.var_27 = (Tester_Class_2)(var_39 = arg_2);
|
||||||
|
((Tester_Class_3.var_4 |= var_43) ? (var_59 = (var_59 = (var_59 = (Tester_Class_3)var_60))) : (var_59 = (Tester_Class_3)arg_2)).var_24 ^= Tester_Class_3.var_1;
|
||||||
|
return Tester_Class_1.var_9;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void func_6(char arg_0, final Tester_Class_3 arg_1, String arg_2, final double arg_3)
|
||||||
|
{
|
||||||
|
((new Tester_Class_1[(byte)arg_1.var_28])[(arg_1.var_32 = arg_1).var_3 = (byte)var_40]).var_2 = Tester_Class_3.var_9;
|
||||||
|
double var_61;
|
||||||
|
(true ? (arg_1.var_32 = arg_1) : (arg_1.var_32 = (Tester_Class_3.var_27 = (arg_1.var_32 = arg_1)))).var_6 = var_43 | (Tester_Class_2.var_4 = !Tester_Class_3.var_4) ? (arg_1.var_26 = arg_2) : (Tester_Class_2.var_19 = Tester_Class_2.var_18);
|
||||||
|
}
|
||||||
|
|
||||||
|
private final char func_7(int arg_0)
|
||||||
|
{
|
||||||
|
Tester_Class_2.var_4 &= var_43;
|
||||||
|
float var_62 = Tester_Class_3.var_9;
|
||||||
|
--var_40;
|
||||||
|
int var_63 = Tester_Class_1.var_1++;
|
||||||
|
{
|
||||||
|
"nncjfoit".indexOf((new int[(byte)'\\'])[(byte)var_36]);
|
||||||
|
if (var_43)
|
||||||
|
{
|
||||||
|
((new Tester_Class_3[(byte)var_40][(byte)Tester_Class_2.var_1])[(byte)5046997225818337280L][(byte)var_63]).var_24 >>>= var_40;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
--var_40;
|
||||||
|
}
|
||||||
|
--Tester_Class_2.var_1;
|
||||||
|
--var_63;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
final byte var_64 = Tester_Class_1.var_4 ? (byte)'M' : (byte)(var_62 -= + ((byte)Tester_Class_1.var_8));
|
||||||
|
float var_65;
|
||||||
|
var_62 *= ((Tester_Class_3)(new Tester_Interface_0[var_64])[var_64]).var_24++;
|
||||||
|
var_36 /= var_64;
|
||||||
|
{
|
||||||
|
double var_66;
|
||||||
|
}
|
||||||
|
var_40 += 3500240160155094016L;
|
||||||
|
((new Tester_Class_1[var_64][var_64])[var_64][var_64]).var_3 = (byte)(Tester_Class_2.var_7 = (Tester_Class_1.var_7 = (Tester_Class_1.var_7 = (Tester_Class_1.var_7 = var_64))));
|
||||||
|
++Tester_Class_3.var_1;
|
||||||
|
}
|
||||||
|
--arg_0;
|
||||||
|
{
|
||||||
|
arg_0++;
|
||||||
|
}
|
||||||
|
Tester_Class_2.var_1++;
|
||||||
|
var_40 &= (short)((byte)Tester_Class_2.var_8 >> (((new Tester_Class_3[(byte)var_36])[(byte)(var_40 = Tester_Class_3.var_8)]).var_3 = (byte)((byte)3.3531374E38F * var_40)));
|
||||||
|
var_36 %= (var_62 = (byte)900943133);
|
||||||
|
var_36 = Tester_Class_3.var_33;
|
||||||
|
var_62 += (var_40 /= (byte)6766658341842315264L % (byte)'p') * (short)2019461672;
|
||||||
|
--var_40;
|
||||||
|
if (true)
|
||||||
|
{
|
||||||
|
var_62 *= 365879806965555200L;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
var_36 -= ~9163555887358003200L;
|
||||||
|
}
|
||||||
|
Tester_Class_1.var_4 = Tester_Class_1.var_4;
|
||||||
|
{
|
||||||
|
var_40 <<= var_63;
|
||||||
|
}
|
||||||
|
var_40++;
|
||||||
|
String var_67;
|
||||||
|
return Tester_Class_1.var_8;
|
||||||
|
}
|
||||||
|
|
||||||
|
private final static Tester_Interface_0 func_8(char arg_0, final Tester_Class_2 arg_1, final String arg_2)
|
||||||
|
{
|
||||||
|
((new Tester[(byte)((Tester_Class_3)arg_1).var_28])[((Tester_Class_1)(var_39 = arg_1)).var_3 = ((Tester_Class_3.var_27 = (Tester_Class_3)arg_1).var_3 = (byte)+ -9.9100855E36F)]).var_38 = (var_43 ? "k" : Tester_Class_2.var_19).substring(350785312);
|
||||||
|
return (new Tester_Interface_0[(byte)'l'])[((Tester_Class_1)(var_39 = (Tester_Class_3.var_27 = (Tester_Class_3)arg_1))).var_3 = ((Tester_Class_3.var_27 = arg_1).var_3 = (((Tester_Class_3)arg_1).var_3 = (arg_1.var_3 = (arg_1.var_3 = (byte)'['))))];
|
||||||
|
}
|
||||||
|
|
||||||
|
private final int func_9(Tester_Class_3 arg_0, char arg_1)
|
||||||
|
{
|
||||||
|
final float var_68 = Tester_Class_3.var_9;
|
||||||
|
Tester_Class_2.var_18.toLowerCase();
|
||||||
|
double var_69;
|
||||||
|
{
|
||||||
|
Tester_Class_3.var_29 ^= !false || Tester_Class_2.var_4;
|
||||||
|
}
|
||||||
|
Tester_Class_1 var_70;
|
||||||
|
(Tester_Class_3.var_27 = (Tester_Class_2)(var_70 = arg_0)).var_6 = (Tester_Class_2)((var_41 = arg_0).var_6 = (arg_0.var_6 = arg_0));
|
||||||
|
"hv".codePointBefore(--Tester_Class_2.var_1);
|
||||||
|
var_41 = arg_0;
|
||||||
|
return ~ (((arg_0 = arg_0).var_24 &= arg_1) == 3.0764282E38F ? (byte)457565863 : ((arg_0 = arg_0).var_3 = (byte)arg_0.var_28));
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void func_10(double arg_0, final Tester_Class_3 arg_1, double arg_2)
|
||||||
|
{
|
||||||
|
arg_1.var_32 = 'g' != 1.520646515461986E307 ? (arg_1.var_32 = arg_1) : arg_1;
|
||||||
|
Tester_Class_2.var_19.startsWith(Tester_Class_2.var_19 = Tester_Class_3.var_18);
|
||||||
|
Tester_Class_1.var_4 ^= true & (arg_1.var_3 = (arg_1.var_3 = (byte)- ((byte)1.4509185661781193E308))) > (arg_1.var_2 = var_40);
|
||||||
|
var_36 += Tester_Class_3.var_9;
|
||||||
|
}
|
||||||
|
|
||||||
|
Tester_Interface_0 func_12(final Object arg_0, float arg_1)
|
||||||
|
{
|
||||||
|
switch (((Tester_Class_3)arg_0).var_3 = (byte)arg_1)
|
||||||
|
{
|
||||||
|
case 4:
|
||||||
|
var_41 = (Tester_Class_3)(var_39 = (Tester_Class_3.var_27 = (Tester_Class_3.var_27 = (Tester_Class_3)arg_0)));
|
||||||
|
double var_72 = (double)3858573493713776640L;
|
||||||
|
byte var_73 = (var_41 = (Tester_Class_2)arg_0).var_3 = (((Tester_Class_3)arg_0).var_3 = (byte)var_72);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 13:
|
||||||
|
(Tester_Class_3.var_27 = (((Tester_Class_3)arg_0).var_32 = (Tester_Class_3)(Tester_Class_2)arg_0)).var_3 = (Tester_Class_2.var_1 *= ((Tester_Class_3)arg_0).var_24) == (byte)Tester_Class_3.var_33 ? (byte)188693954866039808L : (byte)Tester_Class_2.var_8;
|
||||||
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
var_40 <<= (byte)157510337;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 26:
|
||||||
|
|
||||||
|
case 122:
|
||||||
|
|
||||||
|
}
|
||||||
|
Tester_Interface_0 var_74;
|
||||||
|
long var_75;
|
||||||
|
var_41 = (var_41 = (var_41 = (Tester_Class_2)arg_0));
|
||||||
|
arg_1 *= 1601420762;
|
||||||
|
var_74 = (var_41 = Tester_Class_1.var_4 ? (Tester_Class_3)arg_0 : (Tester_Class_2)arg_0);
|
||||||
|
(Tester_Class_1.var_4 ? (Tester_Class_3)(var_39 = (Tester_Class_3)arg_0) : (true ? (Tester_Class_3)arg_0 : (Tester_Class_3)arg_0)).var_28 *= 1066935145;
|
||||||
|
var_40 >>>= (byte)6.643183E36F / - ((byte)1.277596E37F);
|
||||||
|
{
|
||||||
|
((Tester_Class_3)(((Tester_Class_3)((Tester_Class_3.var_29 ^= (Tester_Class_3.var_29 &= var_43)) ? (Tester_Class_2)arg_0 : (Tester_Class_2)arg_0)).var_32 = (Tester_Class_3.var_27 = (Tester_Class_2)arg_0))).var_28--;
|
||||||
|
}
|
||||||
|
var_38 = "qad";
|
||||||
|
byte var_76 = ((Tester_Class_2)(var_39 = (Tester_Class_3)arg_0)).var_3 = true ? ((var_41 = (var_41 = (Tester_Class_3)arg_0)).var_3 = (byte)1.7128118638075888E308) : (byte)1.6562746603631249E308;
|
||||||
|
return var_39 = (Tester_Class_3)((var_41 = (Tester_Class_3)arg_0).var_6 = Tester_Class_2.var_18);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected final String func_13()
|
||||||
|
{
|
||||||
|
float var_77;
|
||||||
|
var_38 = (Tester_Class_2.var_19 = var_38);
|
||||||
|
Tester_Class_2.var_4 ^= !var_43 | (Tester_Class_3.var_29 ^= Tester_Class_1.var_4);
|
||||||
|
Tester_Class_3.var_1--;
|
||||||
|
Tester_Class_2.var_1++;
|
||||||
|
return Tester_Class_2.var_18;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String execute()
|
||||||
|
{
|
||||||
|
try {
|
||||||
|
Tester t = new Tester();
|
||||||
|
try { t.test(); }
|
||||||
|
catch(Throwable e) { }
|
||||||
|
try { return t.toString(); }
|
||||||
|
catch (Throwable e) { return "Error during result conversion to String"; }
|
||||||
|
} catch (Throwable e) { return "Error during test execution"; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void main(String[] args)
|
||||||
|
{
|
||||||
|
try {
|
||||||
|
Tester t = new Tester();
|
||||||
|
try { t.test(); }
|
||||||
|
catch(Throwable e) { }
|
||||||
|
try { System.out.println(t); }
|
||||||
|
catch(Throwable e) { }
|
||||||
|
} catch (Throwable e) { }
|
||||||
|
}
|
||||||
|
|
||||||
|
private void test()
|
||||||
|
{
|
||||||
|
int var_78 = 0;
|
||||||
|
var_39 = (new Tester_Class_1[(byte)var_40])[(byte)Tester_Class_3.var_33];
|
||||||
|
while (var_43 && (var_78 < 70 && true))
|
||||||
|
{
|
||||||
|
var_40 *= ~ ~Tester_Class_3.var_33 % Tester_Class_3.var_9;
|
||||||
|
var_78++;
|
||||||
|
var_39 = new Tester_Class_3();
|
||||||
|
var_39 = (var_41 = (Tester_Class_3.var_27 = new Tester_Class_2()));
|
||||||
|
}
|
||||||
|
final Tester_Class_3 var_79 = (Tester_Class_1.var_4 ? ~Tester_Class_3.var_33 : var_36) == 1433764895112462336L ? new Tester_Class_3() : new Tester_Class_3();
|
||||||
|
Tester_Class_2 var_80;
|
||||||
|
}
|
||||||
|
public String toString()
|
||||||
|
{
|
||||||
|
String result = "[\n";
|
||||||
|
result += "Tester.var_40 = "; result += Printer.print(var_40);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_42 = "; result += Printer.print(var_42);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_36 = "; result += Printer.print(var_36);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_37 = "; result += Printer.print(var_37);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_39 = "; result += Printer.print(var_39);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_38 = "; result += Printer.print(var_38);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_43 = "; result += Printer.print(var_43);
|
||||||
|
result += "\n";
|
||||||
|
result += "Tester.var_41 = "; result += Printer.print(var_41);
|
||||||
|
result += "";
|
||||||
|
result += "\n]";
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
static class Printer
|
||||||
|
{
|
||||||
|
public static String print(boolean arg) { return String.valueOf(arg); }
|
||||||
|
public static String print(byte arg) { return String.valueOf(arg); }
|
||||||
|
public static String print(short arg) { return String.valueOf(arg); }
|
||||||
|
public static String print(char arg) { return String.valueOf((int)arg); }
|
||||||
|
public static String print(int arg) { return String.valueOf(arg); }
|
||||||
|
public static String print(long arg) { return String.valueOf(arg); }
|
||||||
|
public static String print(float arg) { return String.valueOf(arg); }
|
||||||
|
public static String print(double arg) { return String.valueOf(arg); }
|
||||||
|
|
||||||
|
|
||||||
|
public static String print(Object arg)
|
||||||
|
{
|
||||||
|
return print_r(new java.util.Stack(), arg);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String print_r(java.util.Stack visitedObjects, Object arg)
|
||||||
|
{
|
||||||
|
String result = "";
|
||||||
|
if (arg == null)
|
||||||
|
result += "null";
|
||||||
|
else
|
||||||
|
if (arg.getClass().isArray())
|
||||||
|
{
|
||||||
|
for (int i = 0; i < visitedObjects.size(); i++)
|
||||||
|
if (visitedObjects.elementAt(i) == arg) return "<recursive>";
|
||||||
|
|
||||||
|
visitedObjects.push(arg);
|
||||||
|
|
||||||
|
final String delimiter = ", ";
|
||||||
|
result += "[";
|
||||||
|
|
||||||
|
if (arg instanceof Object[])
|
||||||
|
{
|
||||||
|
Object[] array = (Object[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print_r(visitedObjects, array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof boolean[])
|
||||||
|
{
|
||||||
|
boolean[] array = (boolean[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof byte[])
|
||||||
|
{
|
||||||
|
byte[] array = (byte[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof short[])
|
||||||
|
{
|
||||||
|
short[] array = (short[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof char[])
|
||||||
|
{
|
||||||
|
char[] array = (char[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof int[])
|
||||||
|
{
|
||||||
|
int[] array = (int[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof long[])
|
||||||
|
{
|
||||||
|
long[] array = (long[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof float[])
|
||||||
|
{
|
||||||
|
float[] array = (float[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
if (arg instanceof double[])
|
||||||
|
{
|
||||||
|
double[] array = (double[]) arg;
|
||||||
|
for (int i = 0; i < array.length; i++)
|
||||||
|
{
|
||||||
|
result += print(array[i]);
|
||||||
|
if (i < array.length - 1) result += delimiter;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
result += "]";
|
||||||
|
visitedObjects.pop();
|
||||||
|
|
||||||
|
} else
|
||||||
|
{
|
||||||
|
result += arg.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
@ -2,3 +2,4 @@
|
|||||||
a3b3ba7d6034dc754b51ddc3d281399ac1cae5f1 jdk7-b25
|
a3b3ba7d6034dc754b51ddc3d281399ac1cae5f1 jdk7-b25
|
||||||
da43cb85fac1646d6f97e4a35e510bbfdff97bdb jdk7-b26
|
da43cb85fac1646d6f97e4a35e510bbfdff97bdb jdk7-b26
|
||||||
bafed478d67c3acf7744aaad88b9404261ea6739 jdk7-b27
|
bafed478d67c3acf7744aaad88b9404261ea6739 jdk7-b27
|
||||||
|
b996318955c0ad8e9fa0ffb56c74f626786e863f jdk7-b28
|
||||||
|
@ -2,3 +2,4 @@
|
|||||||
59fd8224ba2da5c2d8d4c68e33cf33ab41ce8de0 jdk7-b25
|
59fd8224ba2da5c2d8d4c68e33cf33ab41ce8de0 jdk7-b25
|
||||||
debd37e1a422e580edb086c95d6e89199133a39c jdk7-b26
|
debd37e1a422e580edb086c95d6e89199133a39c jdk7-b26
|
||||||
27d8f42862c11b4ddc4af2dd2d2a3cd86cda04c2 jdk7-b27
|
27d8f42862c11b4ddc4af2dd2d2a3cd86cda04c2 jdk7-b27
|
||||||
|
eefcd5204500a11d6aa802dca9f961cf10ab64c2 jdk7-b28
|
||||||
|
@ -2,3 +2,4 @@
|
|||||||
75fca0b0ab83ab1392e615910cea020f66535390 jdk7-b25
|
75fca0b0ab83ab1392e615910cea020f66535390 jdk7-b25
|
||||||
fb57027902e04ecafceae31a605e69b436c23d57 jdk7-b26
|
fb57027902e04ecafceae31a605e69b436c23d57 jdk7-b26
|
||||||
3e599d98875ddf919c8ea11cff9b3a99ba631a9b jdk7-b27
|
3e599d98875ddf919c8ea11cff9b3a99ba631a9b jdk7-b27
|
||||||
|
02e4c5348592a8d7fc2cba28bc5f8e35c0e17277 jdk7-b28
|
||||||
|
@ -197,7 +197,6 @@ endif
|
|||||||
|
|
||||||
# Lint Flags:
|
# Lint Flags:
|
||||||
# -Xa ANSI C plus K&R, favor ANSI rules
|
# -Xa ANSI C plus K&R, favor ANSI rules
|
||||||
# -Xarch=XXX Same as 'cc -xarch=XXX'
|
|
||||||
# -fd report on old style func defs
|
# -fd report on old style func defs
|
||||||
# -errchk=structarg report on 64bit struct args by value
|
# -errchk=structarg report on 64bit struct args by value
|
||||||
# -errchk=longptr64 report on 64bit to 32bit issues (ignores casts)
|
# -errchk=longptr64 report on 64bit to 32bit issues (ignores casts)
|
||||||
@ -206,6 +205,7 @@ endif
|
|||||||
# -x suppress unused externs
|
# -x suppress unused externs
|
||||||
# -u suppress extern func/vars used/defined
|
# -u suppress extern func/vars used/defined
|
||||||
# -errfmt=simple use one line errors with position info
|
# -errfmt=simple use one line errors with position info
|
||||||
|
# $(LINT_XARCH_OPTION) See Compiler-sun.gwk
|
||||||
|
|
||||||
LINTFLAGS_COMMON = -Xa
|
LINTFLAGS_COMMON = -Xa
|
||||||
LINTFLAGS_COMMON += -fd
|
LINTFLAGS_COMMON += -fd
|
||||||
@ -224,42 +224,12 @@ LINTFLAGS_DBG =
|
|||||||
# Tell the compilers to never generate globalized names, all the time.
|
# Tell the compilers to never generate globalized names, all the time.
|
||||||
CFLAGS_COMMON += -W0,-noglobal
|
CFLAGS_COMMON += -W0,-noglobal
|
||||||
|
|
||||||
# Arch specific settings (determines type of .o files and instruction set)
|
# If we have a specific arch value to use, add it
|
||||||
ifeq ($(ARCH_FAMILY), sparc)
|
|
||||||
ifdef VIS_NEEDED
|
|
||||||
XARCH_VALUE/32=v8plusa
|
|
||||||
XARCH_VALUE/64=v9a
|
|
||||||
else
|
|
||||||
# Someday this should change to improve optimization on UltraSPARC
|
|
||||||
# and abandon the old v8-only machines like the SPARCstation 10.
|
|
||||||
# Indications with Mustang is that alacrity runs do not show a
|
|
||||||
# big improvement using v8plus over v8, but other benchmarks might.
|
|
||||||
XARCH_VALUE/32=v8
|
|
||||||
XARCH_VALUE/64=v9
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
ifeq ($(ARCH_FAMILY), i586)
|
|
||||||
XARCH_VALUE/64=amd64
|
|
||||||
XARCH_VALUE/32=
|
|
||||||
endif
|
|
||||||
|
|
||||||
# Arch value based on current data model being built
|
|
||||||
XARCH_VALUE=$(XARCH_VALUE/$(ARCH_DATA_MODEL))
|
|
||||||
ifneq ($(XARCH_VALUE), )
|
|
||||||
# The actual compiler -xarch options to use
|
|
||||||
XARCH_OPTION/32 = -xarch=$(XARCH_VALUE/32)
|
|
||||||
XARCH_OPTION/64 = -xarch=$(XARCH_VALUE/64)
|
|
||||||
XARCH_OPTION = $(XARCH_OPTION/$(ARCH_DATA_MODEL))
|
|
||||||
endif
|
|
||||||
|
|
||||||
# If we have a specific -xarch value to use, add it
|
|
||||||
ifdef XARCH_OPTION
|
|
||||||
CFLAGS_COMMON += $(XARCH_OPTION)
|
CFLAGS_COMMON += $(XARCH_OPTION)
|
||||||
CXXFLAGS_COMMON += $(XARCH_OPTION)
|
CXXFLAGS_COMMON += $(XARCH_OPTION)
|
||||||
ASFLAGS_COMMON += $(XARCH_OPTION)
|
ASFLAGS_COMMON += $(AS_XARCH_OPTION)
|
||||||
EXTRA_LIBS += $(XARCH_OPTION)
|
EXTRA_LIBS += $(XARCH_OPTION)
|
||||||
LINTFLAGS_COMMON += -Xarch=$(XARCH_VALUE)
|
LINTFLAGS_COMMON += $(LINT_XARCH_OPTION)
|
||||||
endif
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# uncomment the following to build with PERTURBALOT set
|
# uncomment the following to build with PERTURBALOT set
|
||||||
|
@ -1236,7 +1236,6 @@ ifeq ($(PLATFORM), windows)
|
|||||||
$(RM) $(TEMPDIR)/rebase.input
|
$(RM) $(TEMPDIR)/rebase.input
|
||||||
endif
|
endif
|
||||||
$(RM) -r $(JDK_IMAGE_DIR)
|
$(RM) -r $(JDK_IMAGE_DIR)
|
||||||
$(RM) -r $(JDK_DEBUG_IMAGE_DIR)
|
|
||||||
$(RM) -r $(JRE_IMAGE_DIR)
|
$(RM) -r $(JRE_IMAGE_DIR)
|
||||||
|
|
||||||
images images-clobber::
|
images images-clobber::
|
||||||
|
@ -31,6 +31,9 @@ COMPILER_NAME=Sun Studio
|
|||||||
|
|
||||||
# Sun Studio Compiler settings specific to Solaris
|
# Sun Studio Compiler settings specific to Solaris
|
||||||
ifeq ($(PLATFORM), solaris)
|
ifeq ($(PLATFORM), solaris)
|
||||||
|
# FIXUP: Change to SS12 when validated
|
||||||
|
#COMPILER_VERSION=SS12
|
||||||
|
#REQUIRED_CC_VER=5.9
|
||||||
COMPILER_VERSION=SS11
|
COMPILER_VERSION=SS11
|
||||||
REQUIRED_CC_VER=5.8
|
REQUIRED_CC_VER=5.8
|
||||||
CC = $(COMPILER_PATH)cc
|
CC = $(COMPILER_PATH)cc
|
||||||
@ -51,8 +54,8 @@ endif
|
|||||||
# Sun Studio Compiler settings specific to Linux
|
# Sun Studio Compiler settings specific to Linux
|
||||||
ifeq ($(PLATFORM), linux)
|
ifeq ($(PLATFORM), linux)
|
||||||
# This has not been tested
|
# This has not been tested
|
||||||
COMPILER_VERSION=SS11
|
COMPILER_VERSION=SS12
|
||||||
REQUIRED_CC_VER=5.8
|
REQUIRED_CC_VER=5.9
|
||||||
CC = $(COMPILER_PATH)cc
|
CC = $(COMPILER_PATH)cc
|
||||||
CPP = $(COMPILER_PATH)cc -E
|
CPP = $(COMPILER_PATH)cc -E
|
||||||
CXX = $(COMPILER_PATH)CC
|
CXX = $(COMPILER_PATH)CC
|
||||||
@ -74,3 +77,58 @@ endif
|
|||||||
_CC_VER :=$(shell $(CC) -V 2>&1 | $(HEAD) -n 1)
|
_CC_VER :=$(shell $(CC) -V 2>&1 | $(HEAD) -n 1)
|
||||||
CC_VER :=$(call GetVersion,"$(_CC_VER)")
|
CC_VER :=$(call GetVersion,"$(_CC_VER)")
|
||||||
|
|
||||||
|
# Arch specific settings (determines type of .o files and instruction set)
|
||||||
|
# Starting in SS12 (5.9), the arch options changed.
|
||||||
|
# The assembler /usr/ccs/bin/as wants older SS11 (5.8) style options.
|
||||||
|
# Note: We need to have both 32 and 64 values at all times for awt Makefiles.
|
||||||
|
#
|
||||||
|
XARCH_OPTION_OLD/32 =
|
||||||
|
XARCH_OPTION_OLD/64 =
|
||||||
|
XARCH_OPTION_NEW/32 = -m32
|
||||||
|
XARCH_OPTION_NEW/64 = -m64
|
||||||
|
# Lint options are slightly different
|
||||||
|
LINT_XARCH_OPTION_OLD/32 =
|
||||||
|
LINT_XARCH_OPTION_OLD/64 =
|
||||||
|
LINT_XARCH_OPTION_NEW/32 = -m32
|
||||||
|
LINT_XARCH_OPTION_NEW/64 = -m64
|
||||||
|
ifeq ($(ARCH_FAMILY), sparc)
|
||||||
|
ifdef VIS_NEEDED
|
||||||
|
XARCH_OPTION_OLD/32 += -xarch=v8plusa
|
||||||
|
XARCH_OPTION_OLD/64 += -xarch=v9a
|
||||||
|
XARCH_OPTION_NEW/32 += -xarch=sparcvis
|
||||||
|
XARCH_OPTION_NEW/64 += -xarch=sparcvis
|
||||||
|
else
|
||||||
|
# Someday this should change to improve optimization on UltraSPARC
|
||||||
|
# and abandon v8, even change to sparcvis or sparcvis2, this
|
||||||
|
# abandons machines like the SPARCstation 10.
|
||||||
|
# Indications with jdk6 is that alacrity runs do not show a
|
||||||
|
# big improvement using v8plus over v8, but other benchmarks might.
|
||||||
|
XARCH_OPTION_OLD/32 += -xarch=v8
|
||||||
|
XARCH_OPTION_OLD/64 += -xarch=v9
|
||||||
|
# Note that this new option (SS12+) effectively means v8plus
|
||||||
|
XARCH_OPTION_NEW/32 += -xarch=sparc
|
||||||
|
XARCH_OPTION_NEW/64 += -xarch=sparc
|
||||||
|
endif
|
||||||
|
LINT_XARCH_OPTION_OLD/64 += -Xarch=v9
|
||||||
|
endif
|
||||||
|
ifeq ($(ARCH_FAMILY), i586)
|
||||||
|
XARCH_OPTION_OLD/64 += -xarch=amd64
|
||||||
|
LINT_XARCH_OPTION_OLD/64 += -Xarch=amd64
|
||||||
|
endif
|
||||||
|
# Pick the options we want based on the compiler being used.
|
||||||
|
ifeq ($(shell expr $(CC_VER) \>= 5.9), 1)
|
||||||
|
XARCH_OPTION/32 = $(XARCH_OPTION_NEW/32)
|
||||||
|
XARCH_OPTION/64 = $(XARCH_OPTION_NEW/64)
|
||||||
|
LINT_XARCH_OPTION/32 = $(LINT_XARCH_OPTION_NEW/32)
|
||||||
|
LINT_XARCH_OPTION/64 = $(LINT_XARCH_OPTION_NEW/64)
|
||||||
|
else
|
||||||
|
XARCH_OPTION/32 = $(XARCH_OPTION_OLD/32)
|
||||||
|
XARCH_OPTION/64 = $(XARCH_OPTION_OLD/64)
|
||||||
|
LINT_XARCH_OPTION/32 = $(LINT_XARCH_OPTION_OLD/32)
|
||||||
|
LINT_XARCH_OPTION/64 = $(LINT_XARCH_OPTION_OLD/64)
|
||||||
|
endif
|
||||||
|
XARCH_OPTION = $(XARCH_OPTION/$(ARCH_DATA_MODEL))
|
||||||
|
LINT_XARCH_OPTION = $(LINT_XARCH_OPTION/$(ARCH_DATA_MODEL))
|
||||||
|
# The /usr/ccs/bin/as assembler always wants the older SS11 (5.8) options.
|
||||||
|
AS_XARCH_OPTION = $(XARCH_OPTION_OLD/$(ARCH_DATA_MODEL))
|
||||||
|
|
||||||
|
@ -119,7 +119,7 @@ if [ "${osname}" = SunOS ] ; then
|
|||||||
# System place where JDK installed images are stored?
|
# System place where JDK installed images are stored?
|
||||||
jdk_instances=/usr/jdk/instances
|
jdk_instances=/usr/jdk/instances
|
||||||
|
|
||||||
# Get the SS11 compilers (and latest patches for them too)
|
# Get the Sun Studio compilers (and latest patches for them too)
|
||||||
if [ "${ALT_COMPILER_PATH}" = "" ] ; then
|
if [ "${ALT_COMPILER_PATH}" = "" ] ; then
|
||||||
ALT_COMPILER_PATH=/opt/SUNWspro/bin
|
ALT_COMPILER_PATH=/opt/SUNWspro/bin
|
||||||
export ALT_COMPILER_PATH
|
export ALT_COMPILER_PATH
|
||||||
|
@ -133,9 +133,15 @@ if [ "${osname}" = SunOS ] ; then
|
|||||||
solaris_arch=i386
|
solaris_arch=i386
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Get the SS11 compilers into path (make sure it matches ALT setting)
|
# Get the compilers into path (make sure it matches ALT setting)
|
||||||
compiler_path=${jdk_devtools}/${solaris_arch}/SUNWspro/SS11/bin
|
if [ "${JPRT_SOLARIS_COMPILER_NAME}" != "" ] ; then
|
||||||
|
compiler_name=${JPRT_SOLARIS_COMPILER_NAME}
|
||||||
|
else
|
||||||
|
# FIXUP: Change to SS12 when validated
|
||||||
|
#compiler_name=SS12
|
||||||
compiler_name=SS11
|
compiler_name=SS11
|
||||||
|
fi
|
||||||
|
compiler_path=${jdk_devtools}/${solaris_arch}/SUNWspro/${compiler_name}/bin
|
||||||
ALT_COMPILER_PATH="${compiler_path}"
|
ALT_COMPILER_PATH="${compiler_path}"
|
||||||
export ALT_COMPILER_PATH
|
export ALT_COMPILER_PATH
|
||||||
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
|
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
|
||||||
|
@ -93,7 +93,6 @@ else # PLATFORM
|
|||||||
# Other extra flags needed for compiling.
|
# Other extra flags needed for compiling.
|
||||||
#
|
#
|
||||||
CPPFLAGS += -I$(OPENWIN_HOME)/include \
|
CPPFLAGS += -I$(OPENWIN_HOME)/include \
|
||||||
-I$(MOTIF_DIR)/include \
|
|
||||||
-I$(SHARE_SRC)/native/$(PKGDIR)/debug \
|
-I$(SHARE_SRC)/native/$(PKGDIR)/debug \
|
||||||
-I$(SHARE_SRC)/native/$(PKGDIR)/image \
|
-I$(SHARE_SRC)/native/$(PKGDIR)/image \
|
||||||
-I$(SHARE_SRC)/native/$(PKGDIR)/image/cvutils \
|
-I$(SHARE_SRC)/native/$(PKGDIR)/image/cvutils \
|
||||||
|
@ -3057,10 +3057,24 @@ public abstract class Component implements ImageObserver, MenuContainer,
|
|||||||
// services. Additionally, the request is restricted to
|
// services. Additionally, the request is restricted to
|
||||||
// the bounds of the component.
|
// the bounds of the component.
|
||||||
if (parent != null) {
|
if (parent != null) {
|
||||||
int px = this.x + ((x < 0) ? 0 : x);
|
if (x < 0) {
|
||||||
int py = this.y + ((y < 0) ? 0 : y);
|
width += x;
|
||||||
|
x = 0;
|
||||||
|
}
|
||||||
|
if (y < 0) {
|
||||||
|
height += y;
|
||||||
|
y = 0;
|
||||||
|
}
|
||||||
|
|
||||||
int pwidth = (width > this.width) ? this.width : width;
|
int pwidth = (width > this.width) ? this.width : width;
|
||||||
int pheight = (height > this.height) ? this.height : height;
|
int pheight = (height > this.height) ? this.height : height;
|
||||||
|
|
||||||
|
if (pwidth <= 0 || pheight <= 0) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
int px = this.x + x;
|
||||||
|
int py = this.y + y;
|
||||||
parent.repaint(tm, px, py, pwidth, pheight);
|
parent.repaint(tm, px, py, pwidth, pheight);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright 1997-2007 Sun Microsystems, Inc. All Rights Reserved.
|
* Copyright 1997-2008 Sun Microsystems, Inc. All Rights Reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
@ -485,7 +485,6 @@ public class DragSourceContext
|
|||||||
|
|
||||||
Cursor c = null;
|
Cursor c = null;
|
||||||
|
|
||||||
targetAct = DnDConstants.ACTION_NONE;
|
|
||||||
switch (status) {
|
switch (status) {
|
||||||
case ENTER:
|
case ENTER:
|
||||||
case OVER:
|
case OVER:
|
||||||
@ -507,6 +506,10 @@ public class DragSourceContext
|
|||||||
else
|
else
|
||||||
c = DragSource.DefaultCopyDrop;
|
c = DragSource.DefaultCopyDrop;
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
targetAct = DnDConstants.ACTION_NONE;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
setCursorImpl(c);
|
setCursorImpl(c);
|
||||||
|
@ -1696,8 +1696,8 @@ public class RequiredModelMBean
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
// eat exceptions because interface doesn't have an
|
// eat exceptions because interface doesn't have an
|
||||||
// exception on it
|
// exception on it
|
||||||
if (MODELMBEAN_LOGGER.isLoggable(Level.WARNING)) {
|
if (MODELMBEAN_LOGGER.isLoggable(Level.FINER)) {
|
||||||
MODELMBEAN_LOGGER.logp(Level.WARNING,
|
MODELMBEAN_LOGGER.logp(Level.FINER,
|
||||||
RequiredModelMBean.class.getName(),
|
RequiredModelMBean.class.getName(),
|
||||||
"getAttributes(String[])",
|
"getAttributes(String[])",
|
||||||
"Failed to get \"" + attrNames[i] + "\": ", e);
|
"Failed to get \"" + attrNames[i] + "\": ", e);
|
||||||
@ -1857,8 +1857,8 @@ public class RequiredModelMBean
|
|||||||
attrValue.getClass().getName() +
|
attrValue.getClass().getName() +
|
||||||
" received.");
|
" received.");
|
||||||
} catch (ClassNotFoundException x) {
|
} catch (ClassNotFoundException x) {
|
||||||
if (MODELMBEAN_LOGGER.isLoggable(Level.WARNING)) {
|
if (MODELMBEAN_LOGGER.isLoggable(Level.FINER)) {
|
||||||
MODELMBEAN_LOGGER.logp(Level.WARNING,
|
MODELMBEAN_LOGGER.logp(Level.FINER,
|
||||||
RequiredModelMBean.class.getName(),
|
RequiredModelMBean.class.getName(),
|
||||||
"setAttribute(Attribute)","Class " +
|
"setAttribute(Attribute)","Class " +
|
||||||
attrType + " for attribute "
|
attrType + " for attribute "
|
||||||
@ -2224,8 +2224,8 @@ public class RequiredModelMBean
|
|||||||
ntfyObj.getMessage() + " Severity = " +
|
ntfyObj.getMessage() + " Severity = " +
|
||||||
(String)ntfyDesc.getFieldValue("severity"));
|
(String)ntfyDesc.getFieldValue("severity"));
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
if (MODELMBEAN_LOGGER.isLoggable(Level.WARNING)) {
|
if (MODELMBEAN_LOGGER.isLoggable(Level.FINE)) {
|
||||||
MODELMBEAN_LOGGER.logp(Level.WARNING,
|
MODELMBEAN_LOGGER.logp(Level.FINE,
|
||||||
RequiredModelMBean.class.getName(),
|
RequiredModelMBean.class.getName(),
|
||||||
"sendNotification(Notification)",
|
"sendNotification(Notification)",
|
||||||
"Failed to log " +
|
"Failed to log " +
|
||||||
@ -2618,8 +2618,8 @@ public class RequiredModelMBean
|
|||||||
" Old value = " + oldv +
|
" Old value = " + oldv +
|
||||||
" New value = " + newv);
|
" New value = " + newv);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
if (MODELMBEAN_LOGGER.isLoggable(Level.WARNING)) {
|
if (MODELMBEAN_LOGGER.isLoggable(Level.FINE)) {
|
||||||
MODELMBEAN_LOGGER.logp(Level.WARNING,
|
MODELMBEAN_LOGGER.logp(Level.FINE,
|
||||||
RequiredModelMBean.class.getName(),mth,
|
RequiredModelMBean.class.getName(),mth,
|
||||||
"Failed to log " + ntfyObj.getType() +
|
"Failed to log " + ntfyObj.getType() +
|
||||||
" notification: ", e);
|
" notification: ", e);
|
||||||
@ -2644,8 +2644,8 @@ public class RequiredModelMBean
|
|||||||
" Old value = " + oldv +
|
" Old value = " + oldv +
|
||||||
" New value = " + newv);
|
" New value = " + newv);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
if (MODELMBEAN_LOGGER.isLoggable(Level.WARNING)) {
|
if (MODELMBEAN_LOGGER.isLoggable(Level.FINE)) {
|
||||||
MODELMBEAN_LOGGER.logp(Level.WARNING,
|
MODELMBEAN_LOGGER.logp(Level.FINE,
|
||||||
RequiredModelMBean.class.getName(),mth,
|
RequiredModelMBean.class.getName(),mth,
|
||||||
"Failed to log " + ntfyObj.getType() +
|
"Failed to log " + ntfyObj.getType() +
|
||||||
" notification: ", e);
|
" notification: ", e);
|
||||||
|
@ -102,7 +102,7 @@ class OCSPChecker extends PKIXCertPathChecker {
|
|||||||
*/
|
*/
|
||||||
public void init(boolean forward) throws CertPathValidatorException {
|
public void init(boolean forward) throws CertPathValidatorException {
|
||||||
if (!forward) {
|
if (!forward) {
|
||||||
remainingCerts = certs.length;
|
remainingCerts = certs.length + 1;
|
||||||
} else {
|
} else {
|
||||||
throw new CertPathValidatorException(
|
throw new CertPathValidatorException(
|
||||||
"Forward checking not supported");
|
"Forward checking not supported");
|
||||||
@ -131,14 +131,22 @@ class OCSPChecker extends PKIXCertPathChecker {
|
|||||||
|
|
||||||
InputStream in = null;
|
InputStream in = null;
|
||||||
OutputStream out = null;
|
OutputStream out = null;
|
||||||
|
|
||||||
|
// Decrement the certificate counter
|
||||||
|
remainingCerts--;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
// Examine OCSP properties
|
|
||||||
X509Certificate responderCert = null;
|
X509Certificate responderCert = null;
|
||||||
boolean seekResponderCert = false;
|
boolean seekResponderCert = false;
|
||||||
X500Principal responderSubjectName = null;
|
X500Principal responderSubjectName = null;
|
||||||
X500Principal responderIssuerName = null;
|
X500Principal responderIssuerName = null;
|
||||||
BigInteger responderSerialNumber = null;
|
BigInteger responderSerialNumber = null;
|
||||||
|
|
||||||
|
boolean seekIssuerCert = true;
|
||||||
|
X509CertImpl issuerCertImpl = null;
|
||||||
|
X509CertImpl currCertImpl =
|
||||||
|
X509CertImpl.toImpl((X509Certificate)cert);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* OCSP security property values, in the following order:
|
* OCSP security property values, in the following order:
|
||||||
* 1. ocsp.responderURL
|
* 1. ocsp.responderURL
|
||||||
@ -148,6 +156,9 @@ class OCSPChecker extends PKIXCertPathChecker {
|
|||||||
*/
|
*/
|
||||||
String[] properties = getOCSPProperties();
|
String[] properties = getOCSPProperties();
|
||||||
|
|
||||||
|
// Check whether OCSP is feasible before seeking cert information
|
||||||
|
URL url = getOCSPServerURL(currCertImpl, properties);
|
||||||
|
|
||||||
// When responder's subject name is set then the issuer/serial
|
// When responder's subject name is set then the issuer/serial
|
||||||
// properties are ignored
|
// properties are ignored
|
||||||
if (properties[1] != null) {
|
if (properties[1] != null) {
|
||||||
@ -172,14 +183,9 @@ class OCSPChecker extends PKIXCertPathChecker {
|
|||||||
seekResponderCert = true;
|
seekResponderCert = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
boolean seekIssuerCert = true;
|
// Set the issuer certificate to the next cert in the chain
|
||||||
X509CertImpl issuerCertImpl = null;
|
// (unless we're processing the final cert).
|
||||||
X509CertImpl currCertImpl =
|
if (remainingCerts < certs.length) {
|
||||||
X509CertImpl.toImpl((X509Certificate)cert);
|
|
||||||
remainingCerts--;
|
|
||||||
|
|
||||||
// Set the issuer certificate
|
|
||||||
if (remainingCerts != 0) {
|
|
||||||
issuerCertImpl = X509CertImpl.toImpl(certs[remainingCerts]);
|
issuerCertImpl = X509CertImpl.toImpl(certs[remainingCerts]);
|
||||||
seekIssuerCert = false; // done
|
seekIssuerCert = false; // done
|
||||||
|
|
||||||
@ -312,7 +318,8 @@ class OCSPChecker extends PKIXCertPathChecker {
|
|||||||
// Construct an OCSP Request
|
// Construct an OCSP Request
|
||||||
OCSPRequest ocspRequest =
|
OCSPRequest ocspRequest =
|
||||||
new OCSPRequest(currCertImpl, issuerCertImpl);
|
new OCSPRequest(currCertImpl, issuerCertImpl);
|
||||||
URL url = getOCSPServerURL(currCertImpl, properties);
|
|
||||||
|
// Use the URL to the OCSP service that was created earlier
|
||||||
HttpURLConnection con = (HttpURLConnection)url.openConnection();
|
HttpURLConnection con = (HttpURLConnection)url.openConnection();
|
||||||
if (DEBUG != null) {
|
if (DEBUG != null) {
|
||||||
DEBUG.println("connecting to OCSP service at: " + url);
|
DEBUG.println("connecting to OCSP service at: " + url);
|
||||||
|
@ -358,6 +358,17 @@ Java_java_net_PlainSocketImpl_socketConnect(JNIEnv *env, jobject this,
|
|||||||
* See 6343810.
|
* See 6343810.
|
||||||
*/
|
*/
|
||||||
while (1) {
|
while (1) {
|
||||||
|
#ifndef USE_SELECT
|
||||||
|
{
|
||||||
|
fprintf(stdout,"\nNATIVE: fd = %d] ", fd);
|
||||||
|
struct pollfd pfd;
|
||||||
|
pfd.fd = fd;
|
||||||
|
pfd.events = POLLOUT;
|
||||||
|
|
||||||
|
connect_rv = NET_Poll(&pfd, 1, -1);
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
{
|
||||||
fd_set wr, ex;
|
fd_set wr, ex;
|
||||||
|
|
||||||
FD_ZERO(&wr);
|
FD_ZERO(&wr);
|
||||||
@ -365,8 +376,10 @@ Java_java_net_PlainSocketImpl_socketConnect(JNIEnv *env, jobject this,
|
|||||||
FD_ZERO(&ex);
|
FD_ZERO(&ex);
|
||||||
FD_SET(fd, &ex);
|
FD_SET(fd, &ex);
|
||||||
|
|
||||||
errno = 0;
|
|
||||||
connect_rv = NET_Select(fd+1, 0, &wr, &ex, 0);
|
connect_rv = NET_Select(fd+1, 0, &wr, &ex, 0);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if (connect_rv == JVM_IO_ERR) {
|
if (connect_rv == JVM_IO_ERR) {
|
||||||
if (errno == EINTR) {
|
if (errno == EINTR) {
|
||||||
continue;
|
continue;
|
||||||
|
@ -3464,6 +3464,21 @@ UINT AwtComponent::WindowsKeyToJavaKey(UINT windowsKey, UINT modifiers)
|
|||||||
return java_awt_event_KeyEvent_VK_UNDEFINED;
|
return java_awt_event_KeyEvent_VK_UNDEFINED;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BOOL AwtComponent::IsNavigationKey(UINT wkey) {
|
||||||
|
switch (wkey) {
|
||||||
|
case VK_END:
|
||||||
|
case VK_PRIOR: // PageUp
|
||||||
|
case VK_NEXT: // PageDown
|
||||||
|
case VK_HOME:
|
||||||
|
case VK_LEFT:
|
||||||
|
case VK_UP:
|
||||||
|
case VK_RIGHT:
|
||||||
|
case VK_DOWN:
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
// determine if a key is a numpad key (distinguishes the numpad
|
// determine if a key is a numpad key (distinguishes the numpad
|
||||||
// arrow keys from the non-numpad arrow keys, for example).
|
// arrow keys from the non-numpad arrow keys, for example).
|
||||||
BOOL AwtComponent::IsNumPadKey(UINT vkey, BOOL extended)
|
BOOL AwtComponent::IsNumPadKey(UINT vkey, BOOL extended)
|
||||||
@ -3563,7 +3578,10 @@ UINT AwtComponent::WindowsKeyToJavaChar(UINT wkey, UINT modifiers, TransOps ops)
|
|||||||
// fix for 4623376,4737679,4501485,4740906,4708221 (4173679/4122715)
|
// fix for 4623376,4737679,4501485,4740906,4708221 (4173679/4122715)
|
||||||
// Here we try to resolve a conflict with ::ToAsciiEx's translating
|
// Here we try to resolve a conflict with ::ToAsciiEx's translating
|
||||||
// ALT+number key combinations. kdm@sarc.spb.su
|
// ALT+number key combinations. kdm@sarc.spb.su
|
||||||
|
// yan: Do it for navigation keys only, otherwise some AltGr deadkeys fail.
|
||||||
|
if( IsNavigationKey(wkey) ) {
|
||||||
keyboardState[VK_MENU] &= ~KEY_STATE_DOWN;
|
keyboardState[VK_MENU] &= ~KEY_STATE_DOWN;
|
||||||
|
}
|
||||||
|
|
||||||
if (ctrlIsDown)
|
if (ctrlIsDown)
|
||||||
{
|
{
|
||||||
|
@ -823,6 +823,7 @@ public:
|
|||||||
private:
|
private:
|
||||||
AwtComponent* SearchChild(UINT id);
|
AwtComponent* SearchChild(UINT id);
|
||||||
void RemoveChild(UINT id) ;
|
void RemoveChild(UINT id) ;
|
||||||
|
static BOOL IsNavigationKey(UINT wkey);
|
||||||
|
|
||||||
ChildListItem* m_childList;
|
ChildListItem* m_childList;
|
||||||
|
|
||||||
|
@ -1,75 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright 2005 Sun Microsystems, Inc. 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.
|
|
||||||
*
|
|
||||||
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
|
||||||
* CA 95054 USA or visit www.sun.com if you need additional information or
|
|
||||||
* have any questions.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* @test
|
|
||||||
* @bug 6316460
|
|
||||||
* @summary Test that the legacy com.sun.management.jmx.Introspector
|
|
||||||
* methods work.
|
|
||||||
* @author Eamonn McManus
|
|
||||||
* @run clean LegacyIntrospectorTest
|
|
||||||
* @run build LegacyIntrospectorTest
|
|
||||||
* @run main LegacyIntrospectorTest
|
|
||||||
*/
|
|
||||||
|
|
||||||
import javax.management.*;
|
|
||||||
import com.sun.management.jmx.*;
|
|
||||||
|
|
||||||
public class LegacyIntrospectorTest {
|
|
||||||
public static interface TestMBean {
|
|
||||||
public int getWhatever();
|
|
||||||
}
|
|
||||||
public static class Test implements TestMBean {
|
|
||||||
public int getWhatever() {return 0;}
|
|
||||||
}
|
|
||||||
|
|
||||||
@SuppressWarnings("deprecation")
|
|
||||||
public static void main(String[] args) throws Exception {
|
|
||||||
MBeanInfo mbi = Introspector.testCompliance(Test.class);
|
|
||||||
MBeanAttributeInfo mbai = mbi.getAttributes()[0];
|
|
||||||
if (!mbai.getName().equals("Whatever"))
|
|
||||||
throw new Exception("Wrong attribute name: " + mbai.getName());
|
|
||||||
Class c = Introspector.getMBeanInterface(Test.class);
|
|
||||||
if (c != TestMBean.class)
|
|
||||||
throw new Exception("Wrong interface: " + c);
|
|
||||||
|
|
||||||
MBeanServer mbs1 = new MBeanServerImpl();
|
|
||||||
if (!mbs1.getDefaultDomain().equals("DefaultDomain"))
|
|
||||||
throw new Exception("Wrong default domain: " + mbs1.getDefaultDomain());
|
|
||||||
|
|
||||||
MBeanServer mbs2 = new MBeanServerImpl("Foo");
|
|
||||||
if (!mbs2.getDefaultDomain().equals("Foo"))
|
|
||||||
throw new Exception("Wrong default domain: " + mbs2.getDefaultDomain());
|
|
||||||
|
|
||||||
ObjectName delegateName =
|
|
||||||
new ObjectName("JMImplementation:type=MBeanServerDelegate");
|
|
||||||
MBeanInfo delegateInfo = mbs2.getMBeanInfo(delegateName);
|
|
||||||
MBeanInfo refDelegateInfo =
|
|
||||||
MBeanServerFactory.newMBeanServer().getMBeanInfo(delegateName);
|
|
||||||
if (!delegateInfo.equals(refDelegateInfo))
|
|
||||||
throw new Exception("Wrong delegate info from MBeanServerImpl: " +
|
|
||||||
delegateInfo);
|
|
||||||
|
|
||||||
System.out.println("TEST PASSED");
|
|
||||||
}
|
|
||||||
}
|
|
@ -2,32 +2,22 @@
|
|||||||
* Copyright 2008 Sun Microsystems, Inc. All Rights Reserved.
|
* Copyright 2008 Sun Microsystems, Inc. All Rights Reserved.
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
*
|
*
|
||||||
* This code is free software; you can redistribute it and/or modi
|
* This code is free software; you can redistribute it and/or modify it
|
||||||
fy it
|
* under the terms of the GNU General Public License version 2 only, as
|
||||||
* under the terms of the GNU General Public License version 2 onl
|
|
||||||
y, as
|
|
||||||
* published by the Free Software Foundation.
|
* published by the Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This code is distributed in the hope that it will be useful, bu
|
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||||
t WITHOUT
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABIL
|
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||||
ITY or
|
* version 2 for more details (a copy is included in the LICENSE file that
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public L
|
|
||||||
icense
|
|
||||||
* version 2 for more details (a copy is included in the LICENSE f
|
|
||||||
ile that
|
|
||||||
* accompanied this code).
|
* accompanied this code).
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public Licen
|
* You should have received a copy of the GNU General Public License version
|
||||||
se version
|
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||||
* 2 along with this work; if not, write to the Free Software Foun
|
|
||||||
dation,
|
|
||||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||||
*
|
*
|
||||||
* Please contact Sun Microsystems, Inc., 4150 Network Circle, San
|
* Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
ta Clara,
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
* CA 95054 USA or visit www.sun.com if you need additional inform
|
|
||||||
ation or
|
|
||||||
* have any questions.
|
* have any questions.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
#
|
#
|
||||||
# Copyright 2006 Sun Microsystems, Inc. All Rights Reserved.
|
# Copyright 2006-2008 Sun Microsystems, Inc. All Rights Reserved.
|
||||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||||
#
|
#
|
||||||
# This code is free software; you can redistribute it and/or modify it
|
# This code is free software; you can redistribute it and/or modify it
|
||||||
@ -90,7 +90,8 @@ chmod u+w cert8.db
|
|||||||
|
|
||||||
echo | ${TESTJAVA}${FS}bin${FS}java -Dfile -Dnss \
|
echo | ${TESTJAVA}${FS}bin${FS}java -Dfile -Dnss \
|
||||||
-Dnss.lib=${NSS}${FS}lib${FS}${PF}${FS}${LIBNAME} \
|
-Dnss.lib=${NSS}${FS}lib${FS}${PF}${FS}${LIBNAME} \
|
||||||
KeyToolTest || exit 12
|
KeyToolTest
|
||||||
|
status=$?
|
||||||
|
|
||||||
rm -f p11-nss.txt
|
rm -f p11-nss.txt
|
||||||
rm -f cert8.db
|
rm -f cert8.db
|
||||||
@ -101,4 +102,5 @@ rm HumanInputStream*.class
|
|||||||
rm KeyToolTest.class
|
rm KeyToolTest.class
|
||||||
rm TestException.class
|
rm TestException.class
|
||||||
|
|
||||||
exit $?
|
exit $status
|
||||||
|
|
||||||
|
@ -2,3 +2,4 @@
|
|||||||
58039502942e52f4144a33f36290a2bd2f3581e6 jdk7-b25
|
58039502942e52f4144a33f36290a2bd2f3581e6 jdk7-b25
|
||||||
c46d25a2350ac147d0121d9c9725af6fcb1b4dbe jdk7-b26
|
c46d25a2350ac147d0121d9c9725af6fcb1b4dbe jdk7-b26
|
||||||
a17265993253d61becd04fe7d96d1fe8b4bd6dff jdk7-b27
|
a17265993253d61becd04fe7d96d1fe8b4bd6dff jdk7-b27
|
||||||
|
4ef4bd31856949554967fbf22783babb21a62a0e jdk7-b28
|
||||||
|
@ -301,7 +301,11 @@ public class Types {
|
|||||||
: isSubtypeUnchecked(elemtype(t), elemtype(s), warn);
|
: isSubtypeUnchecked(elemtype(t), elemtype(s), warn);
|
||||||
} else if (isSubtype(t, s)) {
|
} else if (isSubtype(t, s)) {
|
||||||
return true;
|
return true;
|
||||||
} else if (!s.isRaw()) {
|
}
|
||||||
|
else if (t.tag == TYPEVAR) {
|
||||||
|
return isSubtypeUnchecked(t.getUpperBound(), s, warn);
|
||||||
|
}
|
||||||
|
else if (!s.isRaw()) {
|
||||||
Type t2 = asSuper(t, s.tsym);
|
Type t2 = asSuper(t, s.tsym);
|
||||||
if (t2 != null && t2.isRaw()) {
|
if (t2 != null && t2.isRaw()) {
|
||||||
if (isReifiable(s))
|
if (isReifiable(s))
|
||||||
|
@ -454,6 +454,8 @@ public class Attr extends JCTree.Visitor {
|
|||||||
void attribTypeVariables(List<JCTypeParameter> typarams, Env<AttrContext> env) {
|
void attribTypeVariables(List<JCTypeParameter> typarams, Env<AttrContext> env) {
|
||||||
for (JCTypeParameter tvar : typarams) {
|
for (JCTypeParameter tvar : typarams) {
|
||||||
TypeVar a = (TypeVar)tvar.type;
|
TypeVar a = (TypeVar)tvar.type;
|
||||||
|
a.tsym.flags_field |= UNATTRIBUTED;
|
||||||
|
a.bound = Type.noType;
|
||||||
if (!tvar.bounds.isEmpty()) {
|
if (!tvar.bounds.isEmpty()) {
|
||||||
List<Type> bounds = List.of(attribType(tvar.bounds.head, env));
|
List<Type> bounds = List.of(attribType(tvar.bounds.head, env));
|
||||||
for (JCExpression bound : tvar.bounds.tail)
|
for (JCExpression bound : tvar.bounds.tail)
|
||||||
@ -464,13 +466,14 @@ public class Attr extends JCTree.Visitor {
|
|||||||
// java.lang.Object.
|
// java.lang.Object.
|
||||||
types.setBounds(a, List.of(syms.objectType));
|
types.setBounds(a, List.of(syms.objectType));
|
||||||
}
|
}
|
||||||
|
a.tsym.flags_field &= ~UNATTRIBUTED;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
void attribBounds(List<JCTypeParameter> typarams, Env<AttrContext> env) {
|
|
||||||
for (JCTypeParameter tvar : typarams)
|
for (JCTypeParameter tvar : typarams)
|
||||||
chk.checkNonCyclic(tvar.pos(), (TypeVar)tvar.type);
|
chk.checkNonCyclic(tvar.pos(), (TypeVar)tvar.type);
|
||||||
attribStats(typarams, env);
|
attribStats(typarams, env);
|
||||||
|
}
|
||||||
|
|
||||||
|
void attribBounds(List<JCTypeParameter> typarams) {
|
||||||
for (JCTypeParameter typaram : typarams) {
|
for (JCTypeParameter typaram : typarams) {
|
||||||
Type bound = typaram.type.getUpperBound();
|
Type bound = typaram.type.getUpperBound();
|
||||||
if (bound != null && bound.tsym instanceof ClassSymbol) {
|
if (bound != null && bound.tsym instanceof ClassSymbol) {
|
||||||
@ -581,7 +584,7 @@ public class Attr extends JCTree.Visitor {
|
|||||||
try {
|
try {
|
||||||
chk.checkDeprecatedAnnotation(tree.pos(), m);
|
chk.checkDeprecatedAnnotation(tree.pos(), m);
|
||||||
|
|
||||||
attribBounds(tree.typarams, env);
|
attribBounds(tree.typarams);
|
||||||
|
|
||||||
// If we override any other methods, check that we do so properly.
|
// If we override any other methods, check that we do so properly.
|
||||||
// JLS ???
|
// JLS ???
|
||||||
@ -2689,7 +2692,7 @@ public class Attr extends JCTree.Visitor {
|
|||||||
chk.validateAnnotations(tree.mods.annotations, c);
|
chk.validateAnnotations(tree.mods.annotations, c);
|
||||||
|
|
||||||
// Validate type parameters, supertype and interfaces.
|
// Validate type parameters, supertype and interfaces.
|
||||||
attribBounds(tree.typarams, env);
|
attribBounds(tree.typarams);
|
||||||
chk.validateTypeParams(tree.typarams);
|
chk.validateTypeParams(tree.typarams);
|
||||||
chk.validate(tree.extending);
|
chk.validate(tree.extending);
|
||||||
chk.validate(tree.implementing);
|
chk.validate(tree.implementing);
|
||||||
|
@ -1486,6 +1486,8 @@ public class Check {
|
|||||||
|
|
||||||
private void checkNonCyclic1(DiagnosticPosition pos, Type t, Set<TypeVar> seen) {
|
private void checkNonCyclic1(DiagnosticPosition pos, Type t, Set<TypeVar> seen) {
|
||||||
final TypeVar tv;
|
final TypeVar tv;
|
||||||
|
if (t.tag == TYPEVAR && (t.tsym.flags() & UNATTRIBUTED) != 0)
|
||||||
|
return;
|
||||||
if (seen.contains(t)) {
|
if (seen.contains(t)) {
|
||||||
tv = (TypeVar)t;
|
tv = (TypeVar)t;
|
||||||
tv.bound = new ErrorType();
|
tv.bound = new ErrorType();
|
||||||
|
@ -228,7 +228,7 @@ public class Resolve {
|
|||||||
// another symbol which is a member of `site'
|
// another symbol which is a member of `site'
|
||||||
// (because, if it is overridden, `sym' is not strictly
|
// (because, if it is overridden, `sym' is not strictly
|
||||||
// speaking a member of `site'.)
|
// speaking a member of `site'.)
|
||||||
(sym.kind != MTH || sym.isConstructor() ||
|
(sym.kind != MTH || sym.isConstructor() || sym.isStatic() ||
|
||||||
((MethodSymbol)sym).implementation(site.tsym, types, true) == sym);
|
((MethodSymbol)sym).implementation(site.tsym, types, true) == sym);
|
||||||
default: // this case includes erroneous combinations as well
|
default: // this case includes erroneous combinations as well
|
||||||
return isAccessible(env, site);
|
return isAccessible(env, site);
|
||||||
|
@ -1606,7 +1606,7 @@ public class JavacFileManager implements StandardJavaFileManager {
|
|||||||
/** @deprecated see bug 6410637 */
|
/** @deprecated see bug 6410637 */
|
||||||
@Deprecated
|
@Deprecated
|
||||||
public String getPath() {
|
public String getPath() {
|
||||||
return entry.getName() + "(" + entry + ")";
|
return zipName + "(" + entry.getName() + ")";
|
||||||
}
|
}
|
||||||
|
|
||||||
public long getLastModified() {
|
public long getLastModified() {
|
||||||
|
@ -1,3 +1,28 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2007-2008 Sun Microsystems, Inc. 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. Sun designates this
|
||||||
|
* particular file as subject to the "Classpath" exception as provided
|
||||||
|
* by Sun in the LICENSE file that accompanied this code.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
package com.sun.tools.javac.zip;
|
package com.sun.tools.javac.zip;
|
||||||
|
|
||||||
import java.io.*;
|
import java.io.*;
|
||||||
|
@ -1,3 +1,28 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2007-2008 Sun Microsystems, Inc. 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. Sun designates this
|
||||||
|
* particular file as subject to the "Classpath" exception as provided
|
||||||
|
* by Sun in the LICENSE file that accompanied this code.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
package com.sun.tools.javac.zip;
|
package com.sun.tools.javac.zip;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
@ -58,7 +58,7 @@ public class ClassData implements RuntimeConstants {
|
|||||||
private String superclassname;
|
private String superclassname;
|
||||||
private int source_cpx=0;
|
private int source_cpx=0;
|
||||||
private byte tags[];
|
private byte tags[];
|
||||||
private Hashtable indexHashAscii = new Hashtable();
|
private Hashtable<Object,Integer> indexHashAscii = new Hashtable<Object,Integer>();
|
||||||
private String pkgPrefix="";
|
private String pkgPrefix="";
|
||||||
private int pkgPrefixLen=0;
|
private int pkgPrefixLen=0;
|
||||||
|
|
||||||
@ -167,19 +167,19 @@ public class ClassData implements RuntimeConstants {
|
|||||||
switch(tags[i] = tag) {
|
switch(tags[i] = tag) {
|
||||||
case CONSTANT_UTF8:
|
case CONSTANT_UTF8:
|
||||||
String str=in.readUTF();
|
String str=in.readUTF();
|
||||||
indexHashAscii.put(cpool[i] = str, new Integer(i));
|
indexHashAscii.put(cpool[i] = str, i);
|
||||||
break;
|
break;
|
||||||
case CONSTANT_INTEGER:
|
case CONSTANT_INTEGER:
|
||||||
cpool[i] = new Integer(in.readInt());
|
cpool[i] = Integer.valueOf(in.readInt());
|
||||||
break;
|
break;
|
||||||
case CONSTANT_FLOAT:
|
case CONSTANT_FLOAT:
|
||||||
cpool[i] = new Float(in.readFloat());
|
cpool[i] = Float.valueOf(in.readFloat());
|
||||||
break;
|
break;
|
||||||
case CONSTANT_LONG:
|
case CONSTANT_LONG:
|
||||||
cpool[i++] = new Long(in.readLong());
|
cpool[i++] = Long.valueOf(in.readLong());
|
||||||
break;
|
break;
|
||||||
case CONSTANT_DOUBLE:
|
case CONSTANT_DOUBLE:
|
||||||
cpool[i++] = new Double(in.readDouble());
|
cpool[i++] = Double.valueOf(in.readDouble());
|
||||||
break;
|
break;
|
||||||
case CONSTANT_CLASS:
|
case CONSTANT_CLASS:
|
||||||
case CONSTANT_STRING:
|
case CONSTANT_STRING:
|
||||||
@ -365,7 +365,7 @@ public class ClassData implements RuntimeConstants {
|
|||||||
* Returns the access of this class or interface.
|
* Returns the access of this class or interface.
|
||||||
*/
|
*/
|
||||||
public String[] getAccess(){
|
public String[] getAccess(){
|
||||||
Vector v = new Vector();
|
Vector<String> v = new Vector<String>();
|
||||||
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
||||||
if ((access & ACC_FINAL) !=0) v.addElement("final");
|
if ((access & ACC_FINAL) !=0) v.addElement("final");
|
||||||
if ((access & ACC_ABSTRACT) !=0) v.addElement("abstract");
|
if ((access & ACC_ABSTRACT) !=0) v.addElement("abstract");
|
||||||
|
@ -45,7 +45,7 @@ public class FieldData implements RuntimeConstants {
|
|||||||
int value_cpx=0;
|
int value_cpx=0;
|
||||||
boolean isSynthetic=false;
|
boolean isSynthetic=false;
|
||||||
boolean isDeprecated=false;
|
boolean isDeprecated=false;
|
||||||
Vector attrs;
|
Vector<AttrData> attrs;
|
||||||
|
|
||||||
public FieldData(ClassData cls){
|
public FieldData(ClassData cls){
|
||||||
this.cls=cls;
|
this.cls=cls;
|
||||||
@ -60,7 +60,7 @@ public class FieldData implements RuntimeConstants {
|
|||||||
descriptor_index = in.readUnsignedShort();
|
descriptor_index = in.readUnsignedShort();
|
||||||
// Read the attributes
|
// Read the attributes
|
||||||
int attributes_count = in.readUnsignedShort();
|
int attributes_count = in.readUnsignedShort();
|
||||||
attrs=new Vector(attributes_count);
|
attrs=new Vector<AttrData>(attributes_count);
|
||||||
for (int i = 0; i < attributes_count; i++) {
|
for (int i = 0; i < attributes_count; i++) {
|
||||||
int attr_name_index=in.readUnsignedShort();
|
int attr_name_index=in.readUnsignedShort();
|
||||||
if (cls.getTag(attr_name_index)!=CONSTANT_UTF8) continue;
|
if (cls.getTag(attr_name_index)!=CONSTANT_UTF8) continue;
|
||||||
@ -99,7 +99,7 @@ public class FieldData implements RuntimeConstants {
|
|||||||
* Returns access of a field.
|
* Returns access of a field.
|
||||||
*/
|
*/
|
||||||
public String[] getAccess(){
|
public String[] getAccess(){
|
||||||
Vector v = new Vector();
|
Vector<String> v = new Vector<String>();
|
||||||
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
||||||
if ((access & ACC_PRIVATE) !=0) v.addElement("private");
|
if ((access & ACC_PRIVATE) !=0) v.addElement("private");
|
||||||
if ((access & ACC_PROTECTED) !=0) v.addElement("protected");
|
if ((access & ACC_PROTECTED) !=0) v.addElement("protected");
|
||||||
|
@ -63,7 +63,7 @@ class InnerClassData implements RuntimeConstants {
|
|||||||
* Returns the access of this class or interface.
|
* Returns the access of this class or interface.
|
||||||
*/
|
*/
|
||||||
public String[] getAccess(){
|
public String[] getAccess(){
|
||||||
Vector v = new Vector();
|
Vector<String> v = new Vector<String>();
|
||||||
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
||||||
if ((access & ACC_FINAL) !=0) v.addElement("final");
|
if ((access & ACC_FINAL) !=0) v.addElement("final");
|
||||||
if ((access & ACC_ABSTRACT) !=0) v.addElement("abstract");
|
if ((access & ACC_ABSTRACT) !=0) v.addElement("abstract");
|
||||||
|
@ -653,7 +653,7 @@ public class JavapPrinter {
|
|||||||
case CONSTANT_METHOD:
|
case CONSTANT_METHOD:
|
||||||
case CONSTANT_INTERFACEMETHOD:
|
case CONSTANT_INTERFACEMETHOD:
|
||||||
case CONSTANT_FIELD: {
|
case CONSTANT_FIELD: {
|
||||||
CPX2 x = (CPX2)(cls.getCpoolEntry(cpx));
|
CPX2 x = cls.getCpoolEntry(cpx);
|
||||||
if (x.cpx1 == cls.getthis_cpx()) {
|
if (x.cpx1 == cls.getthis_cpx()) {
|
||||||
// don't print class part for local references
|
// don't print class part for local references
|
||||||
cpx=x.cpx2;
|
cpx=x.cpx2;
|
||||||
@ -851,7 +851,7 @@ public class JavapPrinter {
|
|||||||
case CONSTANT_INTERFACEMETHOD:
|
case CONSTANT_INTERFACEMETHOD:
|
||||||
case CONSTANT_FIELD: {
|
case CONSTANT_FIELD: {
|
||||||
// CPX2 x=(CPX2)(cpool[cpx]);
|
// CPX2 x=(CPX2)(cpool[cpx]);
|
||||||
CPX2 x = (CPX2)(cls.getCpoolEntry(cpx));
|
CPX2 x = cls.getCpoolEntry(cpx);
|
||||||
if (x.cpx1 == cls.getthis_cpx()) {
|
if (x.cpx1 == cls.getthis_cpx()) {
|
||||||
// don't print class part for local references
|
// don't print class part for local references
|
||||||
cpx=x.cpx2;
|
cpx=x.cpx2;
|
||||||
|
@ -37,7 +37,7 @@ import java.io.*;
|
|||||||
*/
|
*/
|
||||||
public class Main {
|
public class Main {
|
||||||
|
|
||||||
private Vector classList = new Vector();
|
private Vector<String> classList = new Vector<String>();
|
||||||
private PrintWriter out;
|
private PrintWriter out;
|
||||||
JavapEnvironment env = new JavapEnvironment();
|
JavapEnvironment env = new JavapEnvironment();
|
||||||
private static boolean errorOccurred = false;
|
private static boolean errorOccurred = false;
|
||||||
@ -201,7 +201,7 @@ public class Main{
|
|||||||
*/
|
*/
|
||||||
private void displayResults() {
|
private void displayResults() {
|
||||||
for (int i = 0; i < classList.size() ; i++ ) {
|
for (int i = 0; i < classList.size() ; i++ ) {
|
||||||
String Name = (String)classList.elementAt(i);
|
String Name = classList.elementAt(i);
|
||||||
InputStream classin = env.getFileInputStream(Name);
|
InputStream classin = env.getFileInputStream(Name);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -43,14 +43,14 @@ public class MethodData {
|
|||||||
int descriptor_index;
|
int descriptor_index;
|
||||||
int attributes_count;
|
int attributes_count;
|
||||||
byte[] code;
|
byte[] code;
|
||||||
Vector exception_table = new Vector(0);
|
Vector<TrapData> exception_table = new Vector<TrapData>(0);
|
||||||
Vector lin_num_tb = new Vector(0);
|
Vector<LineNumData> lin_num_tb = new Vector<LineNumData>(0);
|
||||||
Vector loc_var_tb = new Vector(0);
|
Vector<LocVarData> loc_var_tb = new Vector<LocVarData>(0);
|
||||||
StackMapTableData[] stackMapTable;
|
StackMapTableData[] stackMapTable;
|
||||||
StackMapData[] stackMap;
|
StackMapData[] stackMap;
|
||||||
int[] exc_index_table=null;
|
int[] exc_index_table=null;
|
||||||
Vector attrs=new Vector(0);
|
Vector<AttrData> attrs=new Vector<AttrData>(0);
|
||||||
Vector code_attrs=new Vector(0);
|
Vector<AttrData> code_attrs=new Vector<AttrData>(0);
|
||||||
int max_stack, max_locals;
|
int max_stack, max_locals;
|
||||||
boolean isSynthetic=false;
|
boolean isSynthetic=false;
|
||||||
boolean isDeprecated=false;
|
boolean isDeprecated=false;
|
||||||
@ -165,7 +165,7 @@ public class MethodData {
|
|||||||
*/
|
*/
|
||||||
void readExceptionTable (DataInputStream in) throws IOException {
|
void readExceptionTable (DataInputStream in) throws IOException {
|
||||||
int exception_table_len=in.readUnsignedShort();
|
int exception_table_len=in.readUnsignedShort();
|
||||||
exception_table=new Vector(exception_table_len);
|
exception_table=new Vector<TrapData>(exception_table_len);
|
||||||
for (int l = 0; l < exception_table_len; l++) {
|
for (int l = 0; l < exception_table_len; l++) {
|
||||||
exception_table.addElement(new TrapData(in, l));
|
exception_table.addElement(new TrapData(in, l));
|
||||||
}
|
}
|
||||||
@ -177,7 +177,7 @@ public class MethodData {
|
|||||||
void readLineNumTable (DataInputStream in) throws IOException {
|
void readLineNumTable (DataInputStream in) throws IOException {
|
||||||
int attr_len = in.readInt(); // attr_length
|
int attr_len = in.readInt(); // attr_length
|
||||||
int lin_num_tb_len = in.readUnsignedShort();
|
int lin_num_tb_len = in.readUnsignedShort();
|
||||||
lin_num_tb=new Vector(lin_num_tb_len);
|
lin_num_tb=new Vector<LineNumData>(lin_num_tb_len);
|
||||||
for (int l = 0; l < lin_num_tb_len; l++) {
|
for (int l = 0; l < lin_num_tb_len; l++) {
|
||||||
lin_num_tb.addElement(new LineNumData(in));
|
lin_num_tb.addElement(new LineNumData(in));
|
||||||
}
|
}
|
||||||
@ -189,7 +189,7 @@ public class MethodData {
|
|||||||
void readLocVarTable (DataInputStream in) throws IOException {
|
void readLocVarTable (DataInputStream in) throws IOException {
|
||||||
int attr_len=in.readInt(); // attr_length
|
int attr_len=in.readInt(); // attr_length
|
||||||
int loc_var_tb_len = in.readUnsignedShort();
|
int loc_var_tb_len = in.readUnsignedShort();
|
||||||
loc_var_tb = new Vector(loc_var_tb_len);
|
loc_var_tb = new Vector<LocVarData>(loc_var_tb_len);
|
||||||
for (int l = 0; l < loc_var_tb_len; l++) {
|
for (int l = 0; l < loc_var_tb_len; l++) {
|
||||||
loc_var_tb.addElement(new LocVarData(in));
|
loc_var_tb.addElement(new LocVarData(in));
|
||||||
}
|
}
|
||||||
@ -237,7 +237,7 @@ public class MethodData {
|
|||||||
*/
|
*/
|
||||||
public String[] getAccess(){
|
public String[] getAccess(){
|
||||||
|
|
||||||
Vector v = new Vector();
|
Vector<String> v = new Vector<String>();
|
||||||
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
if ((access & ACC_PUBLIC) !=0) v.addElement("public");
|
||||||
if ((access & ACC_PRIVATE) !=0) v.addElement("private");
|
if ((access & ACC_PRIVATE) !=0) v.addElement("private");
|
||||||
if ((access & ACC_PROTECTED) !=0) v.addElement("protected");
|
if ((access & ACC_PROTECTED) !=0) v.addElement("protected");
|
||||||
|
@ -26,8 +26,6 @@
|
|||||||
|
|
||||||
package sun.tools.javap;
|
package sun.tools.javap;
|
||||||
|
|
||||||
import java.io.IOException;
|
|
||||||
import java.io.InputStream;
|
|
||||||
import java.util.Hashtable;
|
import java.util.Hashtable;
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
|
|
||||||
@ -36,14 +34,14 @@ public class Tables implements Constants {
|
|||||||
/**
|
/**
|
||||||
* Define mnemocodes table.
|
* Define mnemocodes table.
|
||||||
*/
|
*/
|
||||||
static Hashtable mnemocodes = new Hashtable(301, 0.5f);
|
static Hashtable<String,Integer> mnemocodes = new Hashtable<String,Integer>(301, 0.5f);
|
||||||
static String opcExtNamesTab[]=new String[128];
|
static String opcExtNamesTab[]=new String[128];
|
||||||
static String opcPrivExtNamesTab[]=new String[128];
|
static String opcPrivExtNamesTab[]=new String[128];
|
||||||
static void defineNonPriv(int opc, String mnem) {
|
static void defineNonPriv(int opc, String mnem) {
|
||||||
mnemocodes.put(opcExtNamesTab[opc]=mnem, new Integer(opc_nonpriv*256+opc));
|
mnemocodes.put(opcExtNamesTab[opc]=mnem, opc_nonpriv*256+opc);
|
||||||
}
|
}
|
||||||
static void definePriv(int opc, String mnem) {
|
static void definePriv(int opc, String mnem) {
|
||||||
mnemocodes.put(opcPrivExtNamesTab[opc]="priv_"+mnem, new Integer(opc_priv*256+opc));
|
mnemocodes.put(opcPrivExtNamesTab[opc]="priv_"+mnem, opc_priv*256+opc);
|
||||||
}
|
}
|
||||||
static void defineExt(int opc, String mnem) {
|
static void defineExt(int opc, String mnem) {
|
||||||
defineNonPriv(opc, mnem);
|
defineNonPriv(opc, mnem);
|
||||||
@ -51,28 +49,28 @@ public class Tables implements Constants {
|
|||||||
}
|
}
|
||||||
static { int k;
|
static { int k;
|
||||||
for (k=0; k<opc_wide; k++) {
|
for (k=0; k<opc_wide; k++) {
|
||||||
mnemocodes.put(opcNamesTab[k], new Integer(k));
|
mnemocodes.put(opcNamesTab[k], k);
|
||||||
}
|
}
|
||||||
for (k=opc_wide+1; k<opcNamesTab.length; k++) {
|
for (k=opc_wide+1; k<opcNamesTab.length; k++) {
|
||||||
mnemocodes.put(opcNamesTab[k], new Integer(k));
|
mnemocodes.put(opcNamesTab[k], k);
|
||||||
}
|
}
|
||||||
mnemocodes.put("invokenonvirtual", new Integer(opc_invokespecial));
|
mnemocodes.put("invokenonvirtual", opc_invokespecial);
|
||||||
|
|
||||||
mnemocodes.put("iload_w", new Integer(opc_iload_w));
|
mnemocodes.put("iload_w", opc_iload_w);
|
||||||
mnemocodes.put("lload_w", new Integer(opc_lload_w));
|
mnemocodes.put("lload_w", opc_lload_w);
|
||||||
mnemocodes.put("fload_w", new Integer(opc_fload_w));
|
mnemocodes.put("fload_w", opc_fload_w);
|
||||||
mnemocodes.put("dload_w", new Integer(opc_dload_w));
|
mnemocodes.put("dload_w", opc_dload_w);
|
||||||
mnemocodes.put("aload_w", new Integer(opc_aload_w));
|
mnemocodes.put("aload_w", opc_aload_w);
|
||||||
mnemocodes.put("istore_w", new Integer(opc_istore_w));
|
mnemocodes.put("istore_w", opc_istore_w);
|
||||||
mnemocodes.put("lstore_w", new Integer(opc_lstore_w));
|
mnemocodes.put("lstore_w", opc_lstore_w);
|
||||||
mnemocodes.put("fstore_w", new Integer(opc_fstore_w));
|
mnemocodes.put("fstore_w", opc_fstore_w);
|
||||||
mnemocodes.put("dstore_w", new Integer(opc_dstore_w));
|
mnemocodes.put("dstore_w", opc_dstore_w);
|
||||||
mnemocodes.put("astore_w", new Integer(opc_astore_w));
|
mnemocodes.put("astore_w", opc_astore_w);
|
||||||
mnemocodes.put("ret_w", new Integer(opc_ret_w));
|
mnemocodes.put("ret_w", opc_ret_w);
|
||||||
mnemocodes.put("iinc_w", new Integer(opc_iinc_w));
|
mnemocodes.put("iinc_w", opc_iinc_w);
|
||||||
|
|
||||||
mnemocodes.put("nonpriv", new Integer(opc_nonpriv));
|
mnemocodes.put("nonpriv", opc_nonpriv);
|
||||||
mnemocodes.put("priv", new Integer(opc_priv));
|
mnemocodes.put("priv", opc_priv);
|
||||||
|
|
||||||
defineExt(0, "load_ubyte");
|
defineExt(0, "load_ubyte");
|
||||||
defineExt(1, "load_byte");
|
defineExt(1, "load_byte");
|
||||||
@ -183,7 +181,7 @@ public class Tables implements Constants {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static int opcode(String mnem) {
|
public static int opcode(String mnem) {
|
||||||
Integer Val=(Integer)(mnemocodes.get(mnem));
|
Integer Val=mnemocodes.get(mnem);
|
||||||
if (Val == null) return -1;
|
if (Val == null) return -1;
|
||||||
return Val.intValue();
|
return Val.intValue();
|
||||||
}
|
}
|
||||||
@ -191,7 +189,7 @@ public class Tables implements Constants {
|
|||||||
/**
|
/**
|
||||||
* Initialized keyword and token Hashtables
|
* Initialized keyword and token Hashtables
|
||||||
*/
|
*/
|
||||||
static Vector keywordNames = new Vector(40);
|
static Vector<String> keywordNames = new Vector<String>(40);
|
||||||
private static void defineKeywordName(String id, int token) {
|
private static void defineKeywordName(String id, int token) {
|
||||||
|
|
||||||
if (token>=keywordNames.size()) {
|
if (token>=keywordNames.size()) {
|
||||||
@ -202,7 +200,7 @@ public class Tables implements Constants {
|
|||||||
public static String keywordName(int token) {
|
public static String keywordName(int token) {
|
||||||
if (token==-1) return "EOF";
|
if (token==-1) return "EOF";
|
||||||
if (token>=keywordNames.size()) return null;
|
if (token>=keywordNames.size()) return null;
|
||||||
return (String)keywordNames.elementAt(token);
|
return keywordNames.elementAt(token);
|
||||||
}
|
}
|
||||||
static {
|
static {
|
||||||
defineKeywordName("ident", IDENT);
|
defineKeywordName("ident", IDENT);
|
||||||
@ -217,15 +215,15 @@ public class Tables implements Constants {
|
|||||||
defineKeywordName("RBRACE", RBRACE);
|
defineKeywordName("RBRACE", RBRACE);
|
||||||
}
|
}
|
||||||
|
|
||||||
static Hashtable keywords = new Hashtable(40);
|
static Hashtable<String,Integer> keywords = new Hashtable<String,Integer>(40);
|
||||||
public static int keyword(String idValue) {
|
public static int keyword(String idValue) {
|
||||||
Integer Val=(Integer)(keywords.get(idValue));
|
Integer val=keywords.get(idValue);
|
||||||
if (Val == null) return IDENT;
|
if (val == null) return IDENT;
|
||||||
return Val.intValue();
|
return val.intValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void defineKeyword(String id, int token) {
|
private static void defineKeyword(String id, int token) {
|
||||||
keywords.put(id, new Integer(token));
|
keywords.put(id, token);
|
||||||
defineKeywordName(id, token);
|
defineKeywordName(id, token);
|
||||||
}
|
}
|
||||||
static {
|
static {
|
||||||
@ -275,8 +273,8 @@ public class Tables implements Constants {
|
|||||||
/**
|
/**
|
||||||
* Define tag table.
|
* Define tag table.
|
||||||
*/
|
*/
|
||||||
private static Vector tagNames = new Vector(10);
|
private static Vector<String> tagNames = new Vector<String>(10);
|
||||||
private static Hashtable Tags = new Hashtable(10);
|
private static Hashtable<String,Integer> Tags = new Hashtable<String,Integer>(10);
|
||||||
static {
|
static {
|
||||||
defineTag("Asciz",CONSTANT_UTF8);
|
defineTag("Asciz",CONSTANT_UTF8);
|
||||||
defineTag("int",CONSTANT_INTEGER);
|
defineTag("int",CONSTANT_INTEGER);
|
||||||
@ -291,7 +289,7 @@ public class Tables implements Constants {
|
|||||||
defineTag("NameAndType",CONSTANT_NAMEANDTYPE);
|
defineTag("NameAndType",CONSTANT_NAMEANDTYPE);
|
||||||
}
|
}
|
||||||
private static void defineTag(String id, int val) {
|
private static void defineTag(String id, int val) {
|
||||||
Tags.put(id, new Integer(val));
|
Tags.put(id, val);
|
||||||
if (val>=tagNames.size()) {
|
if (val>=tagNames.size()) {
|
||||||
tagNames.setSize(val+1);
|
tagNames.setSize(val+1);
|
||||||
}
|
}
|
||||||
@ -299,10 +297,10 @@ public class Tables implements Constants {
|
|||||||
}
|
}
|
||||||
public static String tagName(int tag) {
|
public static String tagName(int tag) {
|
||||||
if (tag>=tagNames.size()) return null;
|
if (tag>=tagNames.size()) return null;
|
||||||
return (String)tagNames.elementAt(tag);
|
return tagNames.elementAt(tag);
|
||||||
}
|
}
|
||||||
public static int tagValue(String idValue) {
|
public static int tagValue(String idValue) {
|
||||||
Integer Val=(Integer)(Tags.get(idValue));
|
Integer Val=Tags.get(idValue);
|
||||||
if (Val == null) return 0;
|
if (Val == null) return 0;
|
||||||
return Val.intValue();
|
return Val.intValue();
|
||||||
}
|
}
|
||||||
@ -310,8 +308,8 @@ public class Tables implements Constants {
|
|||||||
/**
|
/**
|
||||||
* Define type table. These types used in "newarray" instruction only.
|
* Define type table. These types used in "newarray" instruction only.
|
||||||
*/
|
*/
|
||||||
private static Vector typeNames = new Vector(10);
|
private static Vector<String> typeNames = new Vector<String>(10);
|
||||||
private static Hashtable Types = new Hashtable(10);
|
private static Hashtable<String,Integer> Types = new Hashtable<String,Integer>(10);
|
||||||
static {
|
static {
|
||||||
defineType("int",T_INT);
|
defineType("int",T_INT);
|
||||||
defineType("long",T_LONG);
|
defineType("long",T_LONG);
|
||||||
@ -324,28 +322,28 @@ public class Tables implements Constants {
|
|||||||
defineType("short",T_SHORT);
|
defineType("short",T_SHORT);
|
||||||
}
|
}
|
||||||
private static void defineType(String id, int val) {
|
private static void defineType(String id, int val) {
|
||||||
Types.put(id, new Integer(val));
|
Types.put(id, val);
|
||||||
if (val>=typeNames.size()) {
|
if (val>=typeNames.size()) {
|
||||||
typeNames.setSize(val+1);
|
typeNames.setSize(val+1);
|
||||||
}
|
}
|
||||||
typeNames.setElementAt(id, val);
|
typeNames.setElementAt(id, val);
|
||||||
}
|
}
|
||||||
public static int typeValue(String idValue) {
|
public static int typeValue(String idValue) {
|
||||||
Integer Val=(Integer)(Types.get(idValue));
|
Integer Val=Types.get(idValue);
|
||||||
if (Val == null) return -1;
|
if (Val == null) return -1;
|
||||||
return Val.intValue();
|
return Val.intValue();
|
||||||
}
|
}
|
||||||
public static String typeName(int type) {
|
public static String typeName(int type) {
|
||||||
if (type>=typeNames.size()) return null;
|
if (type>=typeNames.size()) return null;
|
||||||
return (String)typeNames.elementAt(type);
|
return typeNames.elementAt(type);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Define MapTypes table.
|
* Define MapTypes table.
|
||||||
* These constants used in stackmap tables only.
|
* These constants used in stackmap tables only.
|
||||||
*/
|
*/
|
||||||
private static Vector mapTypeNames = new Vector(10);
|
private static Vector<String> mapTypeNames = new Vector<String>(10);
|
||||||
private static Hashtable MapTypes = new Hashtable(10);
|
private static Hashtable<String,Integer> MapTypes = new Hashtable<String,Integer>(10);
|
||||||
static {
|
static {
|
||||||
defineMapType("bogus", ITEM_Bogus);
|
defineMapType("bogus", ITEM_Bogus);
|
||||||
defineMapType("int", ITEM_Integer);
|
defineMapType("int", ITEM_Integer);
|
||||||
@ -358,20 +356,20 @@ public class Tables implements Constants {
|
|||||||
defineMapType("uninitialized", ITEM_NewObject);
|
defineMapType("uninitialized", ITEM_NewObject);
|
||||||
}
|
}
|
||||||
private static void defineMapType(String id, int val) {
|
private static void defineMapType(String id, int val) {
|
||||||
MapTypes.put(id, new Integer(val));
|
MapTypes.put(id, val);
|
||||||
if (val>=mapTypeNames.size()) {
|
if (val>=mapTypeNames.size()) {
|
||||||
mapTypeNames.setSize(val+1);
|
mapTypeNames.setSize(val+1);
|
||||||
}
|
}
|
||||||
mapTypeNames.setElementAt(id, val);
|
mapTypeNames.setElementAt(id, val);
|
||||||
}
|
}
|
||||||
public static int mapTypeValue(String idValue) {
|
public static int mapTypeValue(String idValue) {
|
||||||
Integer Val=(Integer)(MapTypes.get(idValue));
|
Integer Val=MapTypes.get(idValue);
|
||||||
if (Val == null) return -1;
|
if (Val == null) return -1;
|
||||||
return Val.intValue();
|
return Val.intValue();
|
||||||
}
|
}
|
||||||
public static String mapTypeName(int type) {
|
public static String mapTypeName(int type) {
|
||||||
if (type>=mapTypeNames.size()) return null;
|
if (type>=mapTypeNames.size()) return null;
|
||||||
return (String)mapTypeNames.elementAt(type);
|
return mapTypeNames.elementAt(type);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -79,7 +79,7 @@ public class TypeSignature {
|
|||||||
* Returns java type signature of a parameter.
|
* Returns java type signature of a parameter.
|
||||||
*/
|
*/
|
||||||
public String getParametersHelper(String parameterdes){
|
public String getParametersHelper(String parameterdes){
|
||||||
Vector parameters = new Vector();
|
Vector<String> parameters = new Vector<String>();
|
||||||
int startindex = -1;
|
int startindex = -1;
|
||||||
int endindex = -1;
|
int endindex = -1;
|
||||||
String param = "";
|
String param = "";
|
||||||
@ -187,7 +187,7 @@ public class TypeSignature {
|
|||||||
int i;
|
int i;
|
||||||
|
|
||||||
for(i = 0; i < parameters.size(); i++){
|
for(i = 0; i < parameters.size(); i++){
|
||||||
parametersignature += (String)parameters.elementAt(i);
|
parametersignature += parameters.elementAt(i);
|
||||||
if(i != parameters.size()-1){
|
if(i != parameters.size()-1){
|
||||||
parametersignature += ", ";
|
parametersignature += ", ";
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,7 @@ public class T6589361 {
|
|||||||
Iterable<JavaFileObject> files = fm.list(StandardLocation.PLATFORM_CLASS_PATH, "java.lang", set, false);
|
Iterable<JavaFileObject> files = fm.list(StandardLocation.PLATFORM_CLASS_PATH, "java.lang", set, false);
|
||||||
for (JavaFileObject file : files) {
|
for (JavaFileObject file : files) {
|
||||||
|
|
||||||
if (file.toString().startsWith("java" + File.separator + "lang" + File.separator + "Object.class")) {
|
if (file.toString().contains("java" + File.separator + "lang" + File.separator + "Object.class")) {
|
||||||
String str = fm.inferBinaryName(StandardLocation.CLASS_PATH, file);
|
String str = fm.inferBinaryName(StandardLocation.CLASS_PATH, file);
|
||||||
if (!str.equals("java.lang.Object")) {
|
if (!str.equals("java.lang.Object")) {
|
||||||
throw new AssertionError("Error in JavacFileManager.inferBinaryName method!");
|
throw new AssertionError("Error in JavacFileManager.inferBinaryName method!");
|
||||||
|
65
langtools/test/tools/javac/T6705935.java
Normal file
65
langtools/test/tools/javac/T6705935.java
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @test
|
||||||
|
* @bug 6705935
|
||||||
|
* @summary javac reports path name of entry in ZipFileIndex incorectly
|
||||||
|
*/
|
||||||
|
|
||||||
|
import java.io.*;
|
||||||
|
import java.util.*;
|
||||||
|
import javax.tools.*;
|
||||||
|
import com.sun.tools.javac.util.*;
|
||||||
|
|
||||||
|
public class T6705935 {
|
||||||
|
public static void main(String... args) throws Exception {
|
||||||
|
new T6705935().run();
|
||||||
|
}
|
||||||
|
|
||||||
|
public void run() throws Exception {
|
||||||
|
File java_home = new File(System.getProperty("java.home"));
|
||||||
|
if (java_home.getName().equals("jre"))
|
||||||
|
java_home = java_home.getParentFile();
|
||||||
|
|
||||||
|
JavaCompiler c = ToolProvider.getSystemJavaCompiler();
|
||||||
|
JavaFileManager fm = c.getStandardFileManager(null, null, null);
|
||||||
|
for (JavaFileObject fo: fm.list(StandardLocation.PLATFORM_CLASS_PATH,
|
||||||
|
"java.lang",
|
||||||
|
Collections.singleton(JavaFileObject.Kind.CLASS),
|
||||||
|
false)) {
|
||||||
|
String p = ((BaseFileObject)fo).getPath();
|
||||||
|
int bra = p.indexOf("(");
|
||||||
|
int ket = p.indexOf(")");
|
||||||
|
//System.err.println(bra + "," + ket + "," + p.length());
|
||||||
|
if (bra == -1 || ket != p.length() -1)
|
||||||
|
throw new Exception("unexpected path: " + p + "[" + bra + "," + ket + "," + p.length());
|
||||||
|
String part1 = p.substring(0, bra);
|
||||||
|
String part2 = p.substring(bra + 1, ket);
|
||||||
|
//System.err.println("[" + part1 + "|" + part2 + "]" + " " + java_home);
|
||||||
|
if (part1.equals(part2) || !part1.startsWith(java_home.getPath()))
|
||||||
|
throw new Exception("bad path: " + p);
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
35
langtools/test/tools/javac/generics/6677785/T6677785.java
Normal file
35
langtools/test/tools/javac/generics/6677785/T6677785.java
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @test
|
||||||
|
* @bug 6677785
|
||||||
|
* @summary REGRESSION: StackOverFlowError with Cyclic Class level Type Parameters when used in constructors
|
||||||
|
* @author Maurizio Cimadamore
|
||||||
|
* @compile/fail/ref=T6677785.out -XDstdout -XDrawDiagnostics T6677785.java
|
||||||
|
*/
|
||||||
|
public class T6677785<E extends T, T extends E> {
|
||||||
|
T6677785() {}
|
||||||
|
T6677785(E e) {}
|
||||||
|
T6677785(E e, T t) {}
|
||||||
|
}
|
2
langtools/test/tools/javac/generics/6677785/T6677785.out
Normal file
2
langtools/test/tools/javac/generics/6677785/T6677785.out
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
T6677785.java:31:23: compiler.err.cyclic.inheritance: E
|
||||||
|
1 error
|
37
langtools/test/tools/javac/generics/T6507024.java
Normal file
37
langtools/test/tools/javac/generics/T6507024.java
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @test
|
||||||
|
* @bug 6507024
|
||||||
|
* @summary unchecked conversion between arrays fails after capture conversion
|
||||||
|
* @author Maurizio Cimadamore
|
||||||
|
*
|
||||||
|
* @compile T6507024.java
|
||||||
|
*/
|
||||||
|
|
||||||
|
public class T6507024<T> {
|
||||||
|
<Z> void m(T6507024<Z>[] results) {
|
||||||
|
T6507024<Z>[] r = results.getClass().cast(null);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,31 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* @test
|
||||||
|
* @bug 6665223
|
||||||
|
* @summary Static import of inherited protected method causes compiler exception
|
||||||
|
* @author Maurizio Cimadamore
|
||||||
|
*
|
||||||
|
* @compile pkg/A.java
|
||||||
|
*/
|
31
langtools/test/tools/javac/staticImport/6665223/pkg/A.java
Normal file
31
langtools/test/tools/javac/staticImport/6665223/pkg/A.java
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
package pkg;
|
||||||
|
|
||||||
|
import static pkg.B.b;
|
||||||
|
|
||||||
|
class A {
|
||||||
|
public static void main(String[] args) {
|
||||||
|
b();
|
||||||
|
}
|
||||||
|
}
|
29
langtools/test/tools/javac/staticImport/6665223/pkg/B.java
Normal file
29
langtools/test/tools/javac/staticImport/6665223/pkg/B.java
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
/*
|
||||||
|
* Copyright 2008 Sun Microsystems, Inc. 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.
|
||||||
|
*
|
||||||
|
* 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 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
|
||||||
|
* CA 95054 USA or visit www.sun.com if you need additional information or
|
||||||
|
* have any questions.
|
||||||
|
*/
|
||||||
|
package pkg;
|
||||||
|
|
||||||
|
class B extends B2 {}
|
||||||
|
|
||||||
|
abstract class B2 {
|
||||||
|
protected static void b() {}
|
||||||
|
}
|
@ -225,7 +225,10 @@ COMMON_BUILD_ARGUMENTS = \
|
|||||||
JDK_MKTG_VERSION=$(JDK_MKTG_VERSION) \
|
JDK_MKTG_VERSION=$(JDK_MKTG_VERSION) \
|
||||||
JDK_MAJOR_VERSION=$(JDK_MAJOR_VERSION) \
|
JDK_MAJOR_VERSION=$(JDK_MAJOR_VERSION) \
|
||||||
JDK_MINOR_VERSION=$(JDK_MINOR_VERSION) \
|
JDK_MINOR_VERSION=$(JDK_MINOR_VERSION) \
|
||||||
JDK_MICRO_VERSION=$(JDK_MICRO_VERSION)
|
JDK_MICRO_VERSION=$(JDK_MICRO_VERSION) \
|
||||||
|
PREVIOUS_MAJOR_VERSION=$(PREVIOUS_MAJOR_VERSION) \
|
||||||
|
PREVIOUS_MINOR_VERSION=$(PREVIOUS_MINOR_VERSION) \
|
||||||
|
PREVIOUS_MICRO_VERSION=$(PREVIOUS_MICRO_VERSION)
|
||||||
|
|
||||||
ifdef ARCH_DATA_MODEL
|
ifdef ARCH_DATA_MODEL
|
||||||
COMMON_BUILD_ARGUMENTS += ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)
|
COMMON_BUILD_ARGUMENTS += ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)
|
||||||
|
Loading…
Reference in New Issue
Block a user