提交 fd99afc3 编写于 作者: D duke

Merge

......@@ -9,3 +9,4 @@ cbc8ad9dd0e085a607427ea35411990982f19a36 jdk7-b25
64da805be725721bf2004e7409a0d7a16fc8ddbc jdk7-b32
bb1ef4ee3d2c8cbf43a37d372325a7952be590b9 jdk7-b33
46a989ab932992b2084b946eeb322fa99b9fee6c jdk7-b34
143c1abedb7d3095eff0f9ee5fec9bf48e3490fc jdk7-b35
......@@ -5,7 +5,7 @@
</head>
<body style="background-color:lightcyan">
<!-- ====================================================== -->
+ <table width="100%">
<table width="100%">
<tr>
<td align="center">
<img alt="OpenJDK"
......@@ -39,6 +39,11 @@
<li><a href="#introduction">Introduction</a></li>
<li><a href="#MBE">Minimum Build Environments</a></li>
<li><a href="#SDBE">Specific Developer Build Environments</a></li>
<ul>
<li><a href="#fedora">Fedora Linux</a> </li>
<li><a href="#centos">CentOS Linux</a> </li>
<li><a href="#ubuntu">Ubuntu Linux</a> </li>
</ul>
<li><a href="#directories">Source Directory Structure</a> </li>
<li><a href="#building">Build Information</a>
<ul>
......@@ -182,14 +187,64 @@
we will try to provide what information we have available to us.
</blockquote>
<!-- ------------------------------------------------------ -->
<h3><a name="fedora">Fedora</a></h3>
<h3><a name="fedora">Fedora 9</a></h3>
<blockquote>
TBD
After installing
<a href="http://www.fedoraproject.org/">Fedora 9</a>
you need to make sure you have
the "Software Development" bundle installed, plus the
following packages:
<blockquote>
<ul>
<li>cups devel: Cups Development Package</li>
<li>freetype 2.3+ devel: Freetype 2.3 Development Package</li>
<li>hg: Mercurial, if you need to clone or manage source repositories</li>
<li>ksh: May be needed when using <tt>webrev</tt></li>
</ul>
</blockquote>
<p>
Always a good idea to do a complete Software Update/Refresh
after you get all the packages installed.
</blockquote>
<!-- ------------------------------------------------------ -->
<h3><a name="debian">Debian</a></h3>
<h3><a name="centos">CentOS 5.2</a></h3>
<blockquote>
TBD
After installing
<a href="http://www.centos.org/">CentOS 5.2</a>
you need to make sure you have
the following Development bundles installed:
<blockquote>
<ul>
<li>Development Libraries</li>
<li>Development Tools</li>
<li>Java Development</li>
<li>X Software Development</li>
</ul>
</blockquote>
<p>
Plus the following packages:
<blockquote>
<ul>
<li>cups devel: Cups Development Package</li>
<li>alsa devel: Alsa Development Package</li>
<li>ant: Ant Package</li>
<li>Xi devel: libXi.so Development Package</li>
</ul>
</blockquote>
<p>
The freetype 2.3 packages don't seem to be available,
but the freetype 2.3 sources can be downloaded, built,
and installed easily enough from
<a href="http://downloads.sourceforge.net/freetype">
the freetype site</a>.
Build and install with something like:
<blockquote>
<tt>./configure && make && sudo -u root make install</tt>
</blockquote>
<p>
Mercurial packages could not be found easily, but a Google
search should find ones, and they usually include Python if
it's needed.
</blockquote>
<!-- ------------------------------------------------------ -->
<h3><a name="ubuntu">Ubuntu</a></h3>
......@@ -664,8 +719,8 @@
</li>
<li>
Install the
<a href="#msvc">Microsoft Visual Studio .NET 2003 Professional</a> or the
<a href="#mssdk">Microsoft Platform SDK</a>.
<a href="#msvc">Microsoft Visual Studio .NET 2003 Professional</a> (32bit) or the
<a href="#mssdk">Microsoft Platform SDK</a> (64bit).
</li>
<li>
Setup all environment variables for compilers
......@@ -871,6 +926,11 @@
The Microsoft Visual Studio .NET 2005 (VS2005) compiler
will not work at this time due to the new runtime dll
and the manifest requirements.
<p>
<b>WARNING:</b> Make sure you check out the
<a href="#cygwin">CYGWIN link.exe WARNING</a>.
The path <tt>/usr/bin</tt> must be after the path to the
Visual Studio product.
</blockquote>
<strong><a name="mssdk">Windows X64: Microsoft Platform SDK April 2005</a></strong>
<blockquote>
......@@ -1079,6 +1139,7 @@
<thead>
<tr>
<td>Binary Name</td>
<td>Category</td>
<td>Package</td>
<td>Description</td>
</tr>
......@@ -1087,50 +1148,59 @@
<tr>
<td>ar.exe</td>
<td>Devel</td>
<td>binutils: The GNU assembler, linker and binary
<td>binutils</td>
<td>The GNU assembler, linker and binary
utilities</td>
</tr>
<tr>
<td>make.exe</td>
<td>Devel</td>
<td>make: The GNU version of the 'make' utility<br>
<td>make</td>
<td>The GNU version of the 'make' utility built for CYGWIN.<br>
<b>NOTE</b>: See <a href="#gmake">the GNU make section</a></td>
</tr>
<tr>
<td>m4.exe</td>
<td>Interpreters</td>
<td>m4: GNU implementation of the traditional Unix macro
<td>m4</td>
<td>GNU implementation of the traditional Unix macro
processor</td>
</tr>
<tr>
<td>cpio.exe</td>
<td>Utils</td>
<td>cpio: A program to manage archives of files</td>
<td>cpio</td>
<td>A program to manage archives of files</td>
</tr>
<tr>
<td>gawk.exe</td>
<td>Utils</td>
<td>awk: Pattern-directed scanning and processing language</td>
<td>awk</td>
<td>Pattern-directed scanning and processing language</td>
</tr>
<tr>
<td>file.exe</td>
<td>Utils</td>
<td>file: Determines file type using 'magic' numbers</td>
<td>file</td>
<td>Determines file type using 'magic' numbers</td>
</tr>
<tr>
<td>zip.exe</td>
<td>Archive</td>
<td>zip: Package and compress (archive) files</td>
<td>zip</td>
<td>Package and compress (archive) files</td>
</tr>
<tr>
<td>unzip.exe</td>
<td>Archive</td>
<td>unzip: Extract compressed files in a ZIP archive</td>
<td>unzip</td>
<td>Extract compressed files in a ZIP archive</td>
</tr>
<tr>
<td>free.exe</td>
<td>Procps</td>
<td>free: Display amount of free and used memory in the system</td>
<td>System</td>
<td>procps</td>
<td>Display amount of free and used memory in the system</td>
</tr>
</tbody>
</table>
......@@ -1144,6 +1214,13 @@
section on
<a href="http://cygwin.com/faq/faq.using.html#faq.using.bloda" target="_blank">
BLODA (applications that interfere with CYGWIN)</a>.
<p>
<b>WARNING:</b>
Be very careful with <b><tt>link.exe</tt></b>, it will conflict
with the Visual Studio version. You need the Visual Studio
version of <tt>link.exe</tt>, not the CYGWIN one.
So it's important that the Visual Studio paths in PATH preceed
the CYGWIN path <tt>/usr/bin</tt>.
</blockquote>
<strong><a name="dxsdk">Microsoft DirectX 9.0 SDK header files and libraries</a></strong>
<blockquote>
......@@ -1429,7 +1506,7 @@
build output is to go.
The default output directory will be build/<i>platform</i>.
</dd>
<dt><a name="ALT_SLASHJAVA"><tt>ALT_SLASHJAVA</tt></a></dt>
<dt><a name="ALT_SLASH_JAVA"><tt>ALT_SLASH_JAVA</tt></a></dt>
<dd>
The default root location for many of the ALT path locations
of the following ALT variables.
......
......@@ -9,3 +9,4 @@ ef6af34d75a7b44e77083f1d4ee47631fa09d3b4 jdk7-b31
80a0f46a6203e727012bd579fe38a609b83decce jdk7-b32
6a5b9d2f8b20de54e3bfe33cd12bd0793caedc4e jdk7-b33
0a812b9824e5d17b073765d1505594b49ff88a10 jdk7-b34
3867c4d14a5bfdbb37c97b4874ccb0ee5343111c jdk7-b35
#
# Copyright 2005-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2005-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
......@@ -67,16 +67,6 @@ ifeq ($(PLATFORM),windows)
UTILS_DEVTOOL_PATH=$(DEVTOOLS_PATH)
endif
# Utilities ant and findbugs
ifndef ANT_HOME
ANT_HOME = $(JDK_DEVTOOLS_DIR)/share/ant/latest
endif
ANT = $(ANT_HOME)/bin/ant
ifndef FINDBUGS_HOME
FINDBUGS_HOME = $(JDK_DEVTOOLS_DIR)/share/findbugs/latest
endif
FINDBUGS = $(FINDBUGS_HOME)/bin/findbugs
# Utilities
ADB = $(UTILS_COMMAND_PATH)adb
AR = $(UTILS_CCS_BIN_PATH)ar
......
......@@ -93,23 +93,13 @@ jdk_import="${ALT_JDK_IMPORT_PATH}"
jdk_devtools="${slashjava}/devtools"
share="${jdk_devtools}/share"
# Needed for langtools, maybe other parts of the build
ANT_HOME="${share}/ant/latest"
export ANT_HOME
FINDBUGS_HOME="${share}/findbugs/latest"
export FINDBUGS_HOME
# The 3 bin directories in common to all platforms
sharebin="${share}/bin"
antbin="${ANT_HOME}/bin"
findbugsbin="${FINDBUGS_HOME}/bin"
# Check input
dirMustExist "${bootdir}" ALT_BOOTDIR
dirMustExist "${slashjava}" ALT_SLASH_JAVA
dirMustExist "${jdk_import}" ALT_JDK_IMPORT_PATH
dirMustExist "${ANT_HOME}" ANT_HOME
dirMustExist "${FINDBUGS_HOME}" FINDBUGS_HOME
# Uses 'uname -s', but only expect SunOS or Linux, assume Windows otherwise.
osname=`uname -s`
......@@ -133,7 +123,7 @@ if [ "${osname}" = SunOS ] ; then
ALT_COMPILER_PATH="${compiler_path}"
export ALT_COMPILER_PATH
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
path4sdk=${compiler_path}:${sharebin}:${antbin}:${findbugsbin}
path4sdk=${compiler_path}:${sharebin}
# Add basic solaris system paths
path4sdk=${path4sdk}:/usr/ccs/bin:/usr/ccs/lib:/usr/bin:/bin:/usr/sfw/bin
......@@ -170,7 +160,7 @@ elif [ "${osname}" = Linux ] ; then
ALT_COMPILER_PATH="${compiler_path}"
export ALT_COMPILER_PATH
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
path4sdk=${compiler_path}:${sharebin}:${antbin}:${findbugsbin}
path4sdk=${compiler_path}:${sharebin}
# Add basic paths
path4sdk=${path4sdk}:/usr/bin:/bin:/usr/sbin:/sbin
......@@ -211,7 +201,7 @@ else
dosname="${mkshome}/mksnt/dosname -s"
# Most unix utilities are in the mksnt directory of ROOTDIR
unixcommand_path="${mkshome}/mksnt"
path4sdk="${sharebin};${antbin};${findbugsbin};${unixcommand_path}"
path4sdk="${sharebin};${unixcommand_path}"
dirMustExist "${unixcommand_path}" ALT_UNIXCOMMAND_PATH
devtools_path="${jdk_devtools}/win32/bin"
path4sdk="${devtools_path};${path4sdk}"
......@@ -229,7 +219,7 @@ else
dosname="/usr/bin/cygpath -a -m -s"
# Most unix utilities are in the /usr/bin
unixcommand_path="/usr/bin"
path4sdk="${sharebin};${antbin};${findbugsbin};${unixcommand_path}"
path4sdk="${sharebin};${unixcommand_path}"
dirMustExist "${unixcommand_path}" ALT_UNIXCOMMAND_PATH
# Find GNU make
make="${unixcommand_path}/make.exe"
......
......@@ -9,3 +9,4 @@ d1605aabd0a15ecf93787c47de63073c33fba52d jdk7-b30
b727c32788a906c04839516ae7443a085185a300 jdk7-b32
585535ec8a14adafa6bfea65d6975e29094c8cec jdk7-b33
5251a9cd8eb8743eee647365bee1c8afdc131556 jdk7-b34
5fa96a5a7e76da7c8dad12486293a0456c2c116c jdk7-b35
/*
* Copyright 2000-2005 Sun Microsystems, Inc. All Rights Reserved.
* Copyright 2000-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
......@@ -39,9 +39,9 @@ import sun.jvm.hotspot.utilities.*;
<P> Encoding: </P>
<PRE>
bits:
Where: [15]
Type: [14..12]
Offset: [11..0]
Type: [3..0]
Where: [4]
Offset: [31..5]
</PRE>
*/
......@@ -69,6 +69,7 @@ public class Location {
// Location::Type constants
TYPE_NORMAL = db.lookupIntConstant("Location::normal").intValue();
TYPE_OOP = db.lookupIntConstant("Location::oop").intValue();
TYPE_NARROWOOP = db.lookupIntConstant("Location::narrowoop").intValue();
TYPE_INT_IN_LONG = db.lookupIntConstant("Location::int_in_long").intValue();
TYPE_LNG = db.lookupIntConstant("Location::lng").intValue();
TYPE_FLOAT_IN_DBL = db.lookupIntConstant("Location::float_in_dbl").intValue();
......@@ -115,6 +116,8 @@ public class Location {
public static final Type NORMAL = new Type("normal");
/** Oop (please GC me!) */
public static final Type OOP = new Type("oop");
/** NarrowOop (please GC me!) */
public static final Type NARROWOOP = new Type("narrowoop");
/** Long held in one register */
public static final Type INT_IN_LONG = new Type("int_in_long");
/** Long held in one register */
......@@ -142,6 +145,8 @@ public class Location {
return TYPE_NORMAL;
} else if (this == OOP) {
return TYPE_OOP;
} else if (this == NARROWOOP) {
return TYPE_NARROWOOP;
} else if (this == INT_IN_LONG) {
return TYPE_INT_IN_LONG;
} else if (this == LNG) {
......@@ -170,6 +175,7 @@ public class Location {
// constants in Type enum
private static int TYPE_NORMAL;
private static int TYPE_OOP;
private static int TYPE_NARROWOOP;
private static int TYPE_INT_IN_LONG;
private static int TYPE_LNG;
private static int TYPE_FLOAT_IN_DBL;
......@@ -185,7 +191,7 @@ public class Location {
Location(Where where, Type type, int offset) {
setWhere(where);
setType(type);
setOffset(offset & 0x0000FFFF);
setOffset(offset);
}
public Where getWhere() {
......@@ -205,6 +211,8 @@ public class Location {
return Type.NORMAL;
} else if (type == TYPE_OOP) {
return Type.OOP;
} else if (type == TYPE_NARROWOOP) {
return Type.NARROWOOP;
} else if (type == TYPE_INT_IN_LONG) {
return Type.INT_IN_LONG;
} else if (type == TYPE_LNG) {
......@@ -238,6 +246,10 @@ public class Location {
return getType() == Type.OOP;
}
public boolean holdsNarrowOop() {
return getType() == Type.NARROWOOP;
}
public boolean holdsInt() {
return getType() == Type.INT_IN_LONG;
}
......@@ -266,7 +278,7 @@ public class Location {
if (Assert.ASSERTS_ENABLED) {
Assert.that(getWhere() == Where.ON_STACK, "wrong Where");
}
return getOffset() << VM.getVM().getLogAddressSize();
return getOffset() * (int)VM.getVM().getIntSize();
}
public int getRegisterNumber() {
......@@ -296,6 +308,8 @@ public class Location {
if (type == Type.NORMAL) {
} else if (type == Type.OOP) {
tty.print(",oop");
} else if (type == Type.NARROWOOP) {
tty.print(",narrowoop");
} else if (type == Type.INT_IN_LONG) {
tty.print(",int");
} else if (type == Type.LNG) {
......@@ -314,26 +328,26 @@ public class Location {
/** Serialization of debugging information */
public Location(DebugInfoReadStream stream) {
value = (0x0000FFFF & stream.readInt());
value = stream.readInt();
}
// FIXME: not yet implementable
// void write_on(DebugInfoWriteStream* stream);
//--------------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// Internals only below this point
//
private void setWhere(Where where) {
value |= (where.getValue() << WHERE_SHIFT);
value |= ((where.getValue() << WHERE_SHIFT) & WHERE_MASK);
}
private void setType(Type type) {
value |= (type.getValue() << TYPE_SHIFT);
value |= ((type.getValue() << TYPE_SHIFT) & TYPE_MASK);
}
private void setOffset(int offset) {
value |= (offset << OFFSET_SHIFT);
value |= ((offset << OFFSET_SHIFT) & OFFSET_MASK);
}
}
......@@ -206,6 +206,16 @@ public class CompiledVFrame extends JavaVFrame {
Assert.that( loc.isRegister(), "ints always saved to stack in 1 word" );
}
return new StackValue(valueAddr.getJLongAt(0) & 0xFFFFFFFF);
} else if (loc.holdsNarrowOop()) { // Holds an narrow oop?
if (loc.isRegister() && VM.getVM().isBigEndian()) {
// The callee has no clue whether the register holds an narrow oop,
// long or is unused. He always saves a long. Here we know
// a long was saved, but we only want an narrow oop back. Narrow the
// saved long to the narrow oop that the JVM wants.
return new StackValue(valueAddr.getCompOopHandleAt(VM.getVM().getIntSize()));
} else {
return new StackValue(valueAddr.getCompOopHandleAt(0));
}
} else if( loc.holdsOop() ) { // Holds an oop?
return new StackValue(valueAddr.getOopHandleAt(0));
} else if( loc.holdsDouble() ) {
......
......@@ -621,6 +621,11 @@ public class VM {
return bytes;
}
/** Returns true if this is a isBigEndian, false otherwise */
public boolean isBigEndian() {
return isBigEndian;
}
/** Returns true if this is a "core" build, false if either C1 or C2
is present */
public boolean isCore() {
......
......@@ -1135,6 +1135,8 @@ public class HTMLGenerator implements /* imports */ ClassConstants {
buf.append("normal");
} else if (type == Location.Type.OOP) {
buf.append("oop");
} else if (type == Location.Type.NARROWOOP) {
buf.append("narrowoop");
} else if (type == Location.Type.INT_IN_LONG) {
buf.append("int");
} else if (type == Location.Type.LNG) {
......
......@@ -35,7 +35,7 @@ HOTSPOT_VM_COPYRIGHT=Copyright 2008
HS_MAJOR_VER=14
HS_MINOR_VER=0
HS_BUILD_NUMBER=04
HS_BUILD_NUMBER=05
JDK_MAJOR_VER=1
JDK_MINOR_VER=7
......
......@@ -295,3 +295,9 @@ jprt.test.targets = \
${jprt.my.windows.i586.test.targets}, \
${jprt.my.windows.x64.test.targets}
# The default test/Makefile targets that should be run
# Example:
# jprt.make.rule.test.targets=*-*-*-packtest
#jprt.make.rule.test.targets=*-product-*-packtest
......@@ -1129,8 +1129,8 @@ void LIR_Assembler::stack2stack(LIR_Opr src, LIR_Opr dest, BasicType type) {
#else
__ pushl(frame_map()->address_for_slot(src ->double_stack_ix(), 0));
// push and pop the part at src + wordSize, adding wordSize for the previous push
__ pushl(frame_map()->address_for_slot(src ->double_stack_ix(), wordSize));
__ popl (frame_map()->address_for_slot(dest->double_stack_ix(), wordSize));
__ pushl(frame_map()->address_for_slot(src ->double_stack_ix(), 2 * wordSize));
__ popl (frame_map()->address_for_slot(dest->double_stack_ix(), 2 * wordSize));
__ popl (frame_map()->address_for_slot(dest->double_stack_ix(), 0));
#endif // _LP64
......
/*
* Copyright 1997-2006 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.
*
* This code is free software; you can redistribute it and/or modify it
......@@ -26,7 +26,7 @@
#include "incls/_location.cpp.incl"
void Location::print_on(outputStream* st) const {
if(type() == invalid && !legal_offset_in_bytes(offset() * BytesPerInt)) {
if(type() == invalid) {
// product of Location::invalid_loc() or Location::Location().
switch (where()) {
case on_stack: st->print("empty"); break;
......@@ -42,6 +42,7 @@ void Location::print_on(outputStream* st) const {
switch (type()) {
case normal: break;
case oop: st->print(",oop"); break;
case narrowoop: st->print(",narrowoop"); break;
case int_in_long: st->print(",int"); break;
case lng: st->print(",long"); break;
case float_in_dbl: st->print(",float"); break;
......@@ -53,17 +54,17 @@ void Location::print_on(outputStream* st) const {
Location::Location(DebugInfoReadStream* stream) {
_value = (uint16_t) stream->read_int();
_value = (juint) stream->read_int();
}
void Location::write_on(DebugInfoWriteStream* stream) {
stream->write_int(_value & 0x0000FFFF);
stream->write_int(_value);
}
// Valid argument to Location::new_stk_loc()?
bool Location::legal_offset_in_bytes(int offset_in_bytes) {
if ((offset_in_bytes % BytesPerInt) != 0) return false;
return (offset_in_bytes / BytesPerInt) < (OFFSET_MASK >> OFFSET_SHIFT);
return (juint)(offset_in_bytes / BytesPerInt) < (OFFSET_MASK >> OFFSET_SHIFT);
}
/*
* Copyright 1997-2006 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.
*
* This code is free software; you can redistribute it and/or modify it
......@@ -28,10 +28,10 @@
//
// Encoding:
//
// bits:
// Where: [15]
// Type: [14..12]
// Offset: [11..0]
// bits (use low bits for best compression):
// Type: [3..0]
// Where: [4]
// Offset: [31..5]
class Location VALUE_OBJ_CLASS_SPEC {
friend class VMStructs;
......@@ -42,6 +42,7 @@ class Location VALUE_OBJ_CLASS_SPEC {
};
enum Type {
invalid, // Invalid location
normal, // Ints, floats, double halves
oop, // Oop (please GC me!)
int_in_long, // Integer held in long register
......@@ -49,21 +50,21 @@ class Location VALUE_OBJ_CLASS_SPEC {
float_in_dbl, // Float held in double register
dbl, // Double held in one register
addr, // JSR return address
invalid // Invalid location
narrowoop // Narrow Oop (please GC me!)
};
private:
enum {
OFFSET_MASK = (jchar) 0x0FFF,
OFFSET_SHIFT = 0,
TYPE_MASK = (jchar) 0x7000,
TYPE_SHIFT = 12,
WHERE_MASK = (jchar) 0x8000,
WHERE_SHIFT = 15
TYPE_MASK = (juint) 0x0F,
TYPE_SHIFT = 0,
WHERE_MASK = (juint) 0x10,
WHERE_SHIFT = 4,
OFFSET_MASK = (juint) 0xFFFFFFE0,
OFFSET_SHIFT = 5
};
uint16_t _value;
juint _value;
// Create a bit-packed Location
Location(Where where_, Type type_, unsigned offset_) {
......@@ -74,9 +75,9 @@ class Location VALUE_OBJ_CLASS_SPEC {
}
inline void set(Where where_, Type type_, unsigned offset_) {
_value = (uint16_t) ((where_ << WHERE_SHIFT) |
(type_ << TYPE_SHIFT) |
((offset_ << OFFSET_SHIFT) & OFFSET_MASK));
_value = (juint) ((where_ << WHERE_SHIFT) |
(type_ << TYPE_SHIFT) |
((offset_ << OFFSET_SHIFT) & OFFSET_MASK));
}
public:
......@@ -86,7 +87,7 @@ class Location VALUE_OBJ_CLASS_SPEC {
// Register location Factory
static Location new_reg_loc( Type t, VMReg reg ) { return Location(in_register, t, reg->value()); }
// Default constructor
Location() { set(on_stack,invalid,(unsigned) -1); }
Location() { set(on_stack,invalid,0); }
// Bit field accessors
Where where() const { return (Where) ((_value & WHERE_MASK) >> WHERE_SHIFT);}
......
......@@ -157,6 +157,7 @@ Node *AddNode::Ideal(PhaseGVN *phase, bool can_reshape) {
Node *a12 = add1->in(2);
const Type *t12 = phase->type( a12 );
if( t12->singleton() && t12 != Type::TOP && (add1 != add1->in(1)) ) {
assert(add1->in(1) != this, "dead loop in AddNode::Ideal");
add2 = add1->clone();
add2->set_req(2, in(2));
add2 = phase->transform(add2);
......@@ -173,6 +174,7 @@ Node *AddNode::Ideal(PhaseGVN *phase, bool can_reshape) {
Node *a22 = add2->in(2);
const Type *t22 = phase->type( a22 );
if( t22->singleton() && t22 != Type::TOP && (add2 != add2->in(1)) ) {
assert(add2->in(1) != this, "dead loop in AddNode::Ideal");
Node *addx = add2->clone();
addx->set_req(1, in(1));
addx->set_req(2, add2->in(1));
......
......@@ -334,6 +334,9 @@ static void format_helper( PhaseRegAlloc *regalloc, outputStream* st, Node *n, c
case Type::InstPtr:
st->print(" %s%d]=#Ptr" INTPTR_FORMAT,msg,i,t->isa_oopptr()->const_oop());
break;
case Type::NarrowOop:
st->print(" %s%d]=#Ptr" INTPTR_FORMAT,msg,i,t->make_ptr()->isa_oopptr()->const_oop());
break;
case Type::RawPtr:
st->print(" %s%d]=#Raw" INTPTR_FORMAT,msg,i,t->is_rawptr());
break;
......
......@@ -1967,6 +1967,7 @@ static void final_graph_reshaping_impl( Node *n, Final_Reshape_Counts &fpu ) {
!n->is_Proj() &&
nop != Op_CreateEx &&
nop != Op_CheckCastPP &&
nop != Op_DecodeN &&
!n->is_Mem() ) {
Node *x = n->clone();
call->set_req( TypeFunc::Parms, x );
......@@ -2075,20 +2076,27 @@ static void final_graph_reshaping_impl( Node *n, Final_Reshape_Counts &fpu ) {
case Op_CmpP:
// Do this transformation here to preserve CmpPNode::sub() and
// other TypePtr related Ideal optimizations (for example, ptr nullness).
if( n->in(1)->is_DecodeN() ) {
if (n->in(1)->is_DecodeN() || n->in(2)->is_DecodeN()) {
Node* in1 = n->in(1);
Node* in2 = n->in(2);
if (!in1->is_DecodeN()) {
in2 = in1;
in1 = n->in(2);
}
assert(in1->is_DecodeN(), "sanity");
Compile* C = Compile::current();
Node* in2 = NULL;
if( n->in(2)->is_DecodeN() ) {
in2 = n->in(2)->in(1);
} else if ( n->in(2)->Opcode() == Op_ConP ) {
const Type* t = n->in(2)->bottom_type();
if (t == TypePtr::NULL_PTR) {
Node *in1 = n->in(1);
Node* new_in2 = NULL;
if (in2->is_DecodeN()) {
new_in2 = in2->in(1);
} else if (in2->Opcode() == Op_ConP) {
const Type* t = in2->bottom_type();
if (t == TypePtr::NULL_PTR && UseImplicitNullCheckForNarrowOop) {
if (Matcher::clone_shift_expressions) {
// x86, ARM and friends can handle 2 adds in addressing mode.
// Decode a narrow oop and do implicit NULL check in address
// [R12 + narrow_oop_reg<<3 + offset]
in2 = ConNode::make(C, TypeNarrowOop::NULL_PTR);
new_in2 = ConNode::make(C, TypeNarrowOop::NULL_PTR);
} else {
// Don't replace CmpP(o ,null) if 'o' is used in AddP
// to generate implicit NULL check on Sparc where
......@@ -2099,16 +2107,22 @@ static void final_graph_reshaping_impl( Node *n, Final_Reshape_Counts &fpu ) {
break;
}
if (i >= in1->outcnt()) {
in2 = ConNode::make(C, TypeNarrowOop::NULL_PTR);
new_in2 = ConNode::make(C, TypeNarrowOop::NULL_PTR);
}
}
} else if (t->isa_oopptr()) {
in2 = ConNode::make(C, t->make_narrowoop());
new_in2 = ConNode::make(C, t->make_narrowoop());
}
}
if( in2 != NULL ) {
Node* cmpN = new (C, 3) CmpNNode(n->in(1)->in(1), in2);
if (new_in2 != NULL) {
Node* cmpN = new (C, 3) CmpNNode(in1->in(1), new_in2);
n->subsume_by( cmpN );
if (in1->outcnt() == 0) {
in1->disconnect_inputs(NULL);
}
if (in2->outcnt() == 0) {
in2->disconnect_inputs(NULL);
}
}
}
break;
......@@ -2214,6 +2228,9 @@ static void final_graph_reshaping_impl( Node *n, Final_Reshape_Counts &fpu ) {
// Replacing Opaque nodes with their input in final_graph_reshaping_impl(),
// requires that the walk visits a node's inputs before visiting the node.
static void final_graph_reshaping_walk( Node_Stack &nstack, Node *root, Final_Reshape_Counts &fpu ) {
ResourceArea *area = Thread::current()->resource_area();
Unique_Node_List sfpt(area);
fpu._visited.set(root->_idx); // first, mark node as visited
uint cnt = root->req();
Node *n = root;
......@@ -2224,6 +2241,8 @@ static void final_graph_reshaping_walk( Node_Stack &nstack, Node *root, Final_Re
Node* m = n->in(i);
++i;
if (m != NULL && !fpu._visited.test_set(m->_idx)) {
if (m->is_SafePoint() && m->as_SafePoint()->jvms() != NULL)
sfpt.push(m);
cnt = m->req();
nstack.push(n, i); // put on stack parent and next input's index
n = m;
......@@ -2240,6 +2259,41 @@ static void final_graph_reshaping_walk( Node_Stack &nstack, Node *root, Final_Re
nstack.pop(); // Shift to the next node on stack
}
}
// Go over safepoints nodes to skip DecodeN nodes for debug edges.
// It could be done for an uncommon traps or any safepoints/calls
// if the DecodeN node is referenced only in a debug info.
while (sfpt.size() > 0) {
n = sfpt.pop();
JVMState *jvms = n->as_SafePoint()->jvms();
assert(jvms != NULL, "sanity");
int start = jvms->debug_start();
int end = n->req();
bool is_uncommon = (n->is_CallStaticJava() &&
n->as_CallStaticJava()->uncommon_trap_request() != 0);
for (int j = start; j < end; j++) {
Node* in = n->in(j);
if (in->is_DecodeN()) {
bool safe_to_skip = true;
if (!is_uncommon ) {
// Is it safe to skip?
for (uint i = 0; i < in->outcnt(); i++) {
Node* u = in->raw_out(i);
if (!u->is_SafePoint() ||
u->is_Call() && u->as_Call()->has_non_debug_use(n)) {
safe_to_skip = false;
}
}
}
if (safe_to_skip) {
n->set_req(j, in->in(1));
}
if (in->outcnt() == 0) {
in->disconnect_inputs(NULL);
}
}
}
}
}
//------------------------------final_graph_reshaping--------------------------
......
......@@ -1212,6 +1212,7 @@ Node* GraphKit::null_check_common(Node* value, BasicType type,
Deoptimization::Action_make_not_entrant,
NULL, "assert_null");
} else {
replace_in_map(value, zerocon(type));
builtin_throw(reason);
}
}
......@@ -1960,6 +1961,7 @@ Node* GraphKit::null_check_oop(Node* value, Node* *null_control,
// method will be compiled to handle NULLs.
PreserveJVMState pjvms(this);
set_control(*null_control);
replace_in_map(value, null());
uncommon_trap(Deoptimization::Reason_null_check,
Deoptimization::Action_make_not_entrant);
(*null_control) = top(); // NULL path is dead
......
......@@ -58,6 +58,9 @@ void Block::implicit_null_check(PhaseCFG *cfg, Node *proj, Node *val, int allowe
not_null_block = _succs[0];
null_block = _succs[1];
}
while (null_block->is_Empty() == Block::empty_with_goto) {
null_block = null_block->_succs[0];
}
// Search the exception block for an uncommon trap.
// (See Parse::do_if and Parse::do_ifnull for the reason
......@@ -149,6 +152,10 @@ void Block::implicit_null_check(PhaseCFG *cfg, Node *proj, Node *val, int allowe
const TypePtr *adr_type = NULL; // Do not need this return value here
const Node* base = mach->get_base_and_disp(offset, adr_type);
if (base == NULL || base == NodeSentinel) {
// Narrow oop address doesn't have base, only index
if( val->bottom_type()->isa_narrowoop() &&
MacroAssembler::needs_explicit_null_check(offset) )
continue; // Give up if offset is beyond page size
// cannot reason about it; is probably not implicit null exception
} else {
const TypePtr* tptr = base->bottom_type()->is_ptr();
......
......@@ -932,7 +932,7 @@ void PhaseIdealLoop::split_if_with_blocks_post( Node *n ) {
// to fold a StoreP and an AddP together (as part of an
// address expression) and the AddP and StoreP have
// different controls.
if( !x->is_Load() ) _igvn._worklist.yank(x);
if( !x->is_Load() && !x->is_DecodeN() ) _igvn._worklist.yank(x);
}
_igvn.remove_dead_node(n);
}
......
......@@ -685,6 +685,8 @@ void Compile::FillLocArray( int idx, MachSafePointNode* sfpt, Node *local,
} else if( t->base() == Type::Int && OptoReg::is_reg(regnum) ) {
array->append(new_loc_value( _regalloc, regnum, Matcher::int_in_long
? Location::int_in_long : Location::normal ));
} else if( t->base() == Type::NarrowOop ) {
array->append(new_loc_value( _regalloc, regnum, Location::narrowoop ));
} else {
array->append(new_loc_value( _regalloc, regnum, _regalloc->is_oop(local) ? Location::oop : Location::normal ));
}
......@@ -704,6 +706,13 @@ void Compile::FillLocArray( int idx, MachSafePointNode* sfpt, Node *local,
case Type::KlassPtr: // fall through
array->append(new ConstantOopWriteValue(t->isa_oopptr()->const_oop()->encoding()));
break;
case Type::NarrowOop:
if (t == TypeNarrowOop::NULL_PTR) {
array->append(new ConstantOopWriteValue(NULL));
} else {
array->append(new ConstantOopWriteValue(t->make_ptr()->isa_oopptr()->const_oop()->encoding()));
}
break;
case Type::Int:
array->append(new ConstantIntValue(t->is_int()->get_con()));
break;
......@@ -878,9 +887,14 @@ void Compile::Process_OopMap_Node(MachNode *mach, int current_offset) {
}
} else if( !obj_node->is_Con() ) {
OptoReg::Name obj_reg = _regalloc->get_reg_first(obj_node);
scval = new_loc_value( _regalloc, obj_reg, Location::oop );
if( obj_node->bottom_type()->base() == Type::NarrowOop ) {
scval = new_loc_value( _regalloc, obj_reg, Location::narrowoop );
} else {
scval = new_loc_value( _regalloc, obj_reg, Location::oop );
}
} else {
scval = new ConstantOopWriteValue(obj_node->bottom_type()->is_instptr()->const_oop()->encoding());
const TypePtr *tp = obj_node->bottom_type()->make_ptr();
scval = new ConstantOopWriteValue(tp->is_instptr()->const_oop()->encoding());
}
OptoReg::Name box_reg = BoxLockNode::stack_slot(box_node);
......
......@@ -527,6 +527,7 @@ uint PhaseChaitin::Split( uint maxlrg ) {
// Initialize needs_phi and needs_split
bool needs_phi = false;
bool needs_split = false;
bool has_phi = false;
// Walk the predecessor blocks to check inputs for that live range
// Grab predecessor block header
n1 = b->pred(1);
......@@ -570,28 +571,30 @@ uint PhaseChaitin::Split( uint maxlrg ) {
}
} // End for all potential Phi inputs
// If a phi is needed, check for it
if( needs_phi ) {
// check block for appropriate phinode & update edges
for( insidx = 1; insidx <= b->end_idx(); insidx++ ) {
n1 = b->_nodes[insidx];
// bail if this is not a phi
phi = n1->is_Phi() ? n1->as_Phi() : NULL;
if( phi == NULL ) {
// Keep track of index of first non-PhiNode instruction in block
non_phi = insidx;
// break out of the for loop as we have handled all phi nodes
break;
}
// must be looking at a phi
if( Find_id(n1) == lidxs.at(slidx) ) {
// found the necessary phi
needs_phi = false;
// initialize the Reaches entry for this LRG
Reachblock[slidx] = phi;
break;
} // end if found correct phi
} // end for all phi's
// check block for appropriate phinode & update edges
for( insidx = 1; insidx <= b->end_idx(); insidx++ ) {
n1 = b->_nodes[insidx];
// bail if this is not a phi
phi = n1->is_Phi() ? n1->as_Phi() : NULL;
if( phi == NULL ) {
// Keep track of index of first non-PhiNode instruction in block
non_phi = insidx;
// break out of the for loop as we have handled all phi nodes
break;
}
// must be looking at a phi
if( Find_id(n1) == lidxs.at(slidx) ) {
// found the necessary phi
needs_phi = false;
has_phi = true;
// initialize the Reaches entry for this LRG
Reachblock[slidx] = phi;
break;
} // end if found correct phi
} // end for all phi's
// If a phi is needed or exist, check for it
if( needs_phi || has_phi ) {
// add new phinode if one not already found
if( needs_phi ) {
// create a new phi node and insert it into the block
......@@ -695,7 +698,8 @@ uint PhaseChaitin::Split( uint maxlrg ) {
}
}
assert( u, "at least 1 valid input expected" );
if( i >= cnt ) { // Didn't find 2+ unique inputs?
if( i >= cnt ) { // Found one unique input
assert(Find_id(n) == Find_id(u), "should be the same lrg");
n->replace_by(u); // Then replace with unique input
n->disconnect_inputs(NULL);
b->_nodes.remove(insidx);
......
......@@ -1204,15 +1204,17 @@ void Arguments::set_ergonomics_flags() {
// Turn off until bug is fixed.
// FLAG_SET_ERGO(bool, UseCompressedOops, true);
}
#ifdef _WIN64
if (UseLargePages && UseCompressedOops) {
// Cannot allocate guard pages for implicit checks in indexed addressing
// mode, when large pages are specified on windows.
FLAG_SET_DEFAULT(UseImplicitNullCheckForNarrowOop, false);
}
#endif // _WIN64
} else {
if (UseCompressedOops && !FLAG_IS_DEFAULT(UseCompressedOops)) {
// If specified, give a warning
if (UseConcMarkSweepGC){
warning("Compressed Oops does not work with CMS");
} else {
warning(
"Max heap size too large for Compressed Oops");
}
warning( "Max heap size too large for Compressed Oops");
FLAG_SET_DEFAULT(UseCompressedOops, false);
}
}
......
......@@ -294,6 +294,9 @@ class CommandLineFlags {
lp64_product(bool, CheckCompressedOops, trueInDebug, \
"generate checks in encoding/decoding code") \
\
product(bool, UseImplicitNullCheckForNarrowOop, true, \
"generate implicit null check in indexed addressing mode.") \
\
/* UseMembar is theoretically a temp flag used for memory barrier \
* removal testing. It was supposed to be removed before FCS but has \
* been re-added (see 6401008) */ \
......
/*
* Copyright 1997-2006 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.
*
* This code is free software; you can redistribute it and/or modify it
......@@ -86,6 +86,22 @@ StackValue* StackValue::create_stack_value(const frame* fr, const RegisterMap* r
case Location::lng:
// Long value in an aligned adjacent pair
return new StackValue(*(intptr_t*)value_addr);
case Location::narrowoop: {
union { intptr_t p; narrowOop noop;} value;
value.p = (intptr_t) CONST64(0xDEADDEAFDEADDEAF);
if (loc.is_register()) {
// The callee has no clue whether the register holds an int,
// long or is unused. He always saves a long. Here we know
// a long was saved, but we only want an int back. Narrow the
// saved long to the int that the JVM wants.
value.noop = (narrowOop) *(julong*) value_addr;
} else {
value.noop = *(narrowOop*) value_addr;
}
// Decode narrowoop and wrap a handle around the oop
Handle h(oopDesc::decode_heap_oop(value.noop));
return new StackValue(h);
}
#endif
case Location::oop: {
Handle h(*(oop *)value_addr); // Wrap a handle around the oop
......
......@@ -2756,13 +2756,17 @@ void Threads::threads_do(ThreadClosure* tc) {
// For now, just manually iterate through them.
tc->do_thread(VMThread::vm_thread());
Universe::heap()->gc_threads_do(tc);
{
// Grab the Terminator_lock to prevent watcher_thread from being terminated.
MutexLockerEx mu(Terminator_lock, Mutex::_no_safepoint_check_flag);
WatcherThread *wt = WatcherThread::watcher_thread();
if (wt != NULL)
tc->do_thread(wt);
}
WatcherThread *wt = WatcherThread::watcher_thread();
// Strictly speaking, the following NULL check isn't sufficient to make sure
// the data for WatcherThread is still valid upon being examined. However,
// considering that WatchThread terminates when the VM is on the way to
// exit at safepoint, the chance of the above is extremely small. The right
// way to prevent termination of WatcherThread would be to acquire
// Terminator_lock, but we can't do that without violating the lock rank
// checking in some cases.
if (wt != NULL)
tc->do_thread(wt);
// If CompilerThreads ever become non-JavaThreads, add them here
}
......
......@@ -380,7 +380,8 @@ ReservedHeapSpace::ReservedHeapSpace(size_t size, size_t alignment,
bool large, char* requested_address) :
ReservedSpace(size, alignment, large,
requested_address,
UseCompressedOops ? lcm(os::vm_page_size(), alignment) : 0) {
UseCompressedOops && UseImplicitNullCheckForNarrowOop ?
lcm(os::vm_page_size(), alignment) : 0) {
// Only reserved space for the java heap should have a noaccess_prefix
// if using compressed oops.
protect_noaccess_prefix(size);
......@@ -391,7 +392,8 @@ ReservedHeapSpace::ReservedHeapSpace(const size_t prefix_size,
const size_t suffix_size,
const size_t suffix_align) :
ReservedSpace(prefix_size, prefix_align, suffix_size, suffix_align,
UseCompressedOops ? lcm(os::vm_page_size(), prefix_align) : 0) {
UseCompressedOops && UseImplicitNullCheckForNarrowOop ?
lcm(os::vm_page_size(), prefix_align) : 0) {
protect_noaccess_prefix(prefix_size+suffix_size);
}
......
......@@ -1577,6 +1577,7 @@ static inline uint64_t cast_uint64_t(size_t x)
\
declare_constant(Location::normal) \
declare_constant(Location::oop) \
declare_constant(Location::narrowoop) \
declare_constant(Location::int_in_long) \
declare_constant(Location::lng) \
declare_constant(Location::float_in_dbl) \
......
#
# Copyright 2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 1995-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
......@@ -19,17 +19,18 @@
# 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.
#
#
#
#
# Makefile to run jtreg
# Makefile to run various jdk tests
#
# Get OS/ARCH specifics
OSNAME = $(shell uname -s)
SLASH_JAVA = /java
ifeq ($(OSNAME), SunOS)
PLATFORM = solaris
JCT_PLATFORM = solaris
ARCH = $(shell uname -p)
ifeq ($(ARCH), i386)
ARCH=i586
......@@ -37,203 +38,165 @@ ifeq ($(OSNAME), SunOS)
endif
ifeq ($(OSNAME), Linux)
PLATFORM = linux
JCT_PLATFORM = linux
ARCH = $(shell uname -m)
ifeq ($(ARCH), i386)
ARCH=i586
ARCH = i586
endif
endif
ifeq ($(OSNAME), Windows_NT)
PLATFORM = windows
JCT_PLATFORM = win32
SLASH_JAVA = J:
ifeq ($(word 1, $(PROCESSOR_IDENTIFIER)),ia64)
ARCH=ia64
ARCH = ia64
else
ifeq ($(word 1, $(PROCESSOR_IDENTIFIER)),AMD64)
ARCH=x64
ARCH = x64
else
ifeq ($(word 1, $(PROCESSOR_IDENTIFIER)),EM64T)
ARCH=x64
ARCH = x64
else
ARCH=i586
ARCH = i586
endif
endif
endif
EXESUFFIX = .exe
endif
# Default bundle of all test results (passed or not)
JPRT_ARCHIVE_BUNDLE=$(TEST_ROOT)/JPRT_ARCHIVE_BUNDLE.zip
# Utilities used
CD = cd
CP = cp
ECHO = echo
MKDIR = mkdir
ZIP = zip
# Default home for JTREG
ifeq ($(PLATFORM), windows)
JT_HOME = J:/svc/jct-tools3.2.2_01
else
JT_HOME = /java/svc/jct-tools3.2.2_01
# Root of this test area (important to use full paths in some places)
TEST_ROOT := $(shell pwd)
# Root of all test results
ABS_BUILD_ROOT = $(TEST_ROOT)/../build/$(PLATFORM)-$(ARCH)
ABS_TEST_OUTPUT_DIR = $(ABS_BUILD_ROOT)/testoutput
# Expect JPRT to set PRODUCT_HOME (the product or jdk in this case to test)
ifndef PRODUCT_HOME
# Try to use j2sdk-image if it exists
ABS_JDK_IMAGE = $(ABS_BUILD_ROOT)/j2sdk-image
PRODUCT_HOME := \
$(shell \
if [ -d $(ABS_JDK_IMAGE) ] ; then \
$(ECHO) "$(ABS_JDK_IMAGE)"; \
else \
$(ECHO) "$(ABS_BUILD_ROOT)" ; \
fi)
endif
# Default JTREG to run
JTREG = $(JT_HOME)/$(JCT_PLATFORM)/bin/jtreg
# Expect JPRT to set JAVA_ARGS (e.g. -server etc.)
JAVA_OPTIONS =
ifdef JAVA_ARGS
JAVA_OPTIONS = $(JAVA_ARGS)
endif
# Root of this test area
TEST_ROOT := $(shell pwd)
# Expect JPRT to set JPRT_ARCHIVE_BUNDLE (path to zip bundle for results)
ARCHIVE_BUNDLE = $(ABS_TEST_OUTPUT_DIR)/ARCHIVE_BUNDLE.zip
ifdef JPRT_ARCHIVE_BUNDLE
ARCHIVE_BUNDLE = $(JPRT_ARCHIVE_BUNDLE)
endif
# Default JDK to test
JAVA_HOME = $(TEST_ROOT)/../build/$(PLATFORM)-$(ARCH)
# How to create the test bundle (pass or fail, we want to create this)
BUNDLE_UP = ( $(MKDIR) -p `dirname $(ARCHIVE_BUNDLE)` \
&& $(CD) $(ABS_TEST_OUTPUT_DIR) \
&& $(ZIP) -q -r $(ARCHIVE_BUNDLE) . )
BUNDLE_UP_FAILED = ( exitCode=$$? && $(BUNDLE_UP) && exit $${exitCode} )
# The test directories to run
DEFAULT_TESTDIRS = serviceability
TESTDIRS = $(DEFAULT_TESTDIRS)
################################################################
# Files that hold total passed and failed counts (passed==0 is bad)
JTREG_TOTALS_DIR = $(TEST_ROOT)/JTREG_TOTALS_$(PLATFORM)_$(ARCH)
JTREG_FAILED = $(JTREG_TOTALS_DIR)/failed_count
JTREG_PASSED = $(JTREG_TOTALS_DIR)/passed_count
# Default make rule (runs jtreg_tests)
all: jtreg_tests
@$(ECHO) "Testing completed successfully"
# Root of all test results
JTREG_ALL_OUTPUT_DIRNAME = JTREG_OUTPUT_$(PLATFORM)_$(ARCH)
JTREG_ALL_OUTPUT_DIR = $(TEST_ROOT)/$(JTREG_ALL_OUTPUT_DIRNAME)
# Test results for one test directory
JTREG_TEST_OUTPUT_DIR = $(JTREG_ALL_OUTPUT_DIR)/$@
JTREG_TEST_REPORT_DIR = $(JTREG_TEST_OUTPUT_DIR)/JTreport
JTREG_TEST_WORK_DIR = $(JTREG_TEST_OUTPUT_DIR)/JTwork
JTREG_TEST_SUMMARY = $(JTREG_TEST_REPORT_DIR)/summary.txt
# Temp files used by this Makefile
JTREG_TEST_TEMP_DIR = $(JTREG_ALL_OUTPUT_DIR)/$@/temp
JTREG_TEMP_PASSED = $(JTREG_TEST_TEMP_DIR)/passed
JTREG_TEMP_FAILED = $(JTREG_TEST_TEMP_DIR)/failed
JTREG_TEMP_OUTPUT = $(JTREG_TEST_TEMP_DIR)/output
JTREG_TEMP_RESULTS = $(JTREG_TEST_TEMP_DIR)/results
# JTREG options (different for 2.1.6 and 3.2.2_01)
JTREG_COMMON_OPTIONS = -r:$(JTREG_TEST_REPORT_DIR) \
-w:$(JTREG_TEST_WORK_DIR) \
-testjdk:$(JAVA_HOME) \
-automatic \
-verbose:all
JTREG_216_OPTIONS = $(JTREG_COMMON_OPTIONS) $@ $(JAVA_ARGS)
JTREG_322_OPTIONS = $(JTREG_COMMON_OPTIONS) $(JAVA_ARGS:%=-vmoption:%) $@
# Default make rule
all: clean check tests
# Chaeck to make sure these directories exist
check: $(JT_HOME) $(JAVA_HOME) $(JTREG)
# Prime the test run
primecounts: FRC
@rm -f -r $(JTREG_TOTALS_DIR)
@mkdir -p $(JTREG_TOTALS_DIR)
@echo "0" > $(JTREG_FAILED)
@echo "0" > $(JTREG_PASSED)
# Run the tests and determine the 'make' command exit status
# Ultimately we determine the make exit code based on the passed/failed count
tests: primecounts $(TESTDIRS)
@echo "JTREG TOTAL: passed=`cat $(JTREG_PASSED)` failed=`cat $(JTREG_FAILED)`"
zip -q -r $(JPRT_ARCHIVE_BUNDLE) $(JTREG_ALL_OUTPUT_DIRNAME)
@if [ `cat $(JTREG_FAILED)` -ne 0 -o \
`cat $(JTREG_PASSED)` -le 0 ] ; then \
echo "JTREG FAILED"; \
exit 1; \
else \
echo "JTREG PASSED"; \
exit 0; \
fi
# Just make sure these directires exist
$(JT_HOME) $(JAVA_HOME): FRC
@if [ ! -d $@ ] ; then \
echo "ERROR: Directory $@ does not exist"; \
exit 1; \
fi
# Make sure this file exists
$(JTREG): FRC
@if [ ! -f $@ ] ; then \
echo "ERROR: File $@ does not exist"; \
exit 1; \
fi
# Process each test directory one by one, this rule always completes.
# Note that the use of 'tee' tosses the jtreg process exit status, this
# is as expected because even if jtreg fails, we need to save the
# output. So we update the JTREG_PASSED and JTREG_FAILED count files.
# Note that missing the 'results:' line in the last few lines of output
# will indicate a failure (or a bump by one of the JTREG_FAILED file.
# Note that passed: 0 or no passed: indication means a failure.
# Note that any indication of the word 'failed' indicates failure.
# Ultimately if the contents of JTREG_FAILED is not 0, we have failed
# tests, and if the contents of JTREG_PASSED is 0, we consider that a
# failure.
$(TESTDIRS): FRC
@if [ ! -d $@ ] ; then \
echo "ERROR: Directory $@ does not exist"; \
exit 1; \
fi
@echo "---------------------------------------------------"
@rm -f -r $(JTREG_TEST_OUTPUT_DIR)
@mkdir -p $(JTREG_TEST_OUTPUT_DIR)
@mkdir -p $(JTREG_TEST_WORK_DIR)
@mkdir -p $(JTREG_TEST_WORK_DIR)/scratch
@mkdir -p $(JTREG_TEST_REPORT_DIR)
@mkdir -p $(JTREG_TEST_TEMP_DIR)
@echo "Testing $@"
@echo "Using JAVA_HOME=$(JAVA_HOME)"
@echo "Using JAVA_ARGS=$(JAVA_ARGS)"
@if [ "`$(JTREG) -help 2>&1 | fgrep -- -vmoption`" != "" ] ; then \
echo "Assume we are using jtreg 3.2.2_01 or newer"; \
echo "$(JTREG) $(JTREG_322_OPTIONS)"; \
$(JTREG) $(JTREG_322_OPTIONS) 2>&1 | tee $(JTREG_TEMP_OUTPUT) ; \
else \
echo "Assume we are using jtreg 2.1.6"; \
echo "$(JTREG) $(JTREG_216_OPTIONS)"; \
$(JTREG) $(JTREG_216_OPTIONS) 2>&1 | tee $(JTREG_TEMP_OUTPUT) ; \
fi
@echo "---------------------------------------------------"
@echo "Extracting passed and failed counts from jtreg output"
@tail -10 $(JTREG_TEMP_OUTPUT) | fgrep -i 'results:' | \
tail -1 | tee $(JTREG_TEMP_RESULTS)
@sed -e 's@.*\ passed:\ \([1-9][0-9]*\).*@\1@' $(JTREG_TEMP_RESULTS) \
> $(JTREG_TEMP_PASSED)
@if [ "`cat $(JTREG_TEMP_PASSED)`" = "" ] ; then \
echo "ERROR: No passed indication in results"; \
expr `cat $(JTREG_FAILED)` '+' 1 > $(JTREG_FAILED); \
elif [ `cat $(JTREG_TEMP_PASSED)` -le 0 ] ; then \
echo "ERROR: Passed count appears to be 0"; \
expr `cat $(JTREG_FAILED)` '+' 1 > $(JTREG_FAILED); \
elif [ "`fgrep -i failed $(JTREG_TEMP_RESULTS)`" = "" ] ; then \
echo "No indication anything failed"; \
expr `cat $(JTREG_PASSED)` '+' `cat $(JTREG_TEMP_PASSED)` \
> $(JTREG_PASSED); \
else \
sed -e 's@.*\ failed:\ \([1-9][0-9]*\).*@\1@' $(JTREG_TEMP_FAILED) \
> $(JTREG_TEMP_FAILED); \
if [ "`cat $(JTREG_TEMP_FAILED)`" = "" ] ; then \
echo "ERROR: Failed pattern but no failed count in results"; \
expr `cat $(JTREG_FAILED)` '+' 1 > $(JTREG_FAILED); \
elif [ `cat $(JTREG_TEMP_FAILED)` -le 0 ] ; then \
echo "ERROR: Failed count is 0, did something failed or not?"; \
expr `cat $(JTREG_FAILED)` '+' 1 > $(JTREG_FAILED); \
else \
expr `cat $(JTREG_FAILED)` '+' `cat $(JTREG_TEMP_FAILED)` \
> $(JTREG_FAILED); \
fi; \
fi
@echo "---------------------------------------------------"
@echo "Summary: "
@if [ -f $(JTREG_TEST_SUMMARY) ] ; then \
cat $(JTREG_TEST_SUMMARY) ; \
else \
echo "ERROR: Missing $(JTREG_TEST_SUMMARY)"; \
fi
@echo "---------------------------------------------------"
# Prep for output
prep: clean
@$(MKDIR) -p $(ABS_TEST_OUTPUT_DIR)
@$(MKDIR) -p `dirname $(ARCHIVE_BUNDLE)`
# Cleanup
clean:
rm -f -r $(JTREG_ALL_OUTPUT_DIR)
rm -f $(JPRT_ARCHIVE_BUNDLE)
$(RM) -r $(ABS_TEST_OUTPUT_DIR)
$(RM) $(ARCHIVE_BUNDLE)
################################################################
# jtreg tests
# Expect JT_HOME to be set for jtreg tests. (home for jtreg)
JT_HOME = $(SLASH_JAVA)/re/jtreg/4.0/promoted/latest/binaries/jtreg
ifdef JPRT_JTREG_HOME
JT_HOME = $(JPRT_JTREG_HOME)
endif
# Expect JPRT to set TESTDIRS to the jtreg test dirs
JTREG_TESTDIRS = demo/jvmti/gctest demo/jvmti/hprof
ifdef TESTDIRS
JTREG_TESTDIRS = $(TESTDIRS)
endif
# Default JTREG to run (win32 script works for everybody)
JTREG = $(JT_HOME)/win32/bin/jtreg
# Option to tell jtreg to not run tests marked with "ignore"
ifeq ($(PLATFORM), windows)
JTREG_KEY_OPTION = -k:!ignore
else
JTREG_KEY_OPTION = -k:\!ignore
endif
#EXTRA_JTREG_OPTIONS =
jtreg_tests: prep $(JT_HOME) $(PRODUCT_HOME) $(JTREG)
$(JTREG) -a -v:fail,error \
$(JTREG_KEY_OPTION) \
$(EXTRA_JTREG_OPTIONS) \
-r:$(ABS_TEST_OUTPUT_DIR)/JTreport \
-w:$(ABS_TEST_OUTPUT_DIR)/JTwork \
-jdk:$(PRODUCT_HOME) \
$(JAVA_OPTIONS:%=-vmoption:%) \
$(JTREG_TESTDIRS) \
|| $(BUNDLE_UP_FAILED)
$(BUNDLE_UP)
PHONY_LIST += jtreg_tests
################################################################
# packtest
# Expect JPRT to set JPRT_PACKTEST_HOME.
PACKTEST_HOME = /net/jprt-web.sfbay.sun.com/jprt/allproducts/packtest
ifdef JPRT_PACKTEST_HOME
PACKTEST_HOME = $(JPRT_PACKTEST_HOME)
endif
#EXTRA_PACKTEST_OPTIONS =
packtest: prep $(PACKTEST_HOME)/ptest $(PRODUCT_HOME)
( $(CD) $(PACKTEST_HOME) && \
$(PACKTEST_HOME)/ptest \
-t "$(PRODUCT_HOME)" \
$(PACKTEST_STRESS_OPTION) \
$(EXTRA_PACKTEST_OPTIONS) \
-W $(ABS_TEST_OUTPUT_DIR) \
$(JAVA_OPTIONS:%=-J %) \
) || $(BUNDLE_UP_FAILED)
$(BUNDLE_UP)
packtest_stress: PACKTEST_STRESS_OPTION=-s
packtest_stress: packtest
PHONY_LIST += packtest packtest_stress
################################################################
# Phony targets (e.g. these are not filenames)
.PHONY: all clean prep $(PHONY_LIST)
FRC:
################################################################
......@@ -9,3 +9,4 @@ b7474b739d13bacd9972f88ac91f6350b7b0be12 jdk7-b31
c51121419e30eac5f0fbbce45ff1711c4ce0de28 jdk7-b32
fa4c0a6cdd25d97d4e6f5d7aa180bcbb0e0d56af jdk7-b33
434055a0716ee44bca712ebca02fc04b20e6e288 jdk7-b34
cf4894b78ceb966326e93bf221db0c2d14d59218 jdk7-b35
......@@ -704,7 +704,20 @@ endif
# Install of imported file (JDK_IMPORT_PATH, or some other external location)
define install-import-file
@$(ECHO) "ASSEMBLY_IMPORT: $@"
$(install-file)
$(prep-target)
$(CP) $< $@
@if [ "$(PLATFORM)" = "linux" -a "$(@F)" = "libjvm.so" ] ; then \
if [ -x /usr/sbin/selinuxenabled ] ; then \
/usr/sbin/selinuxenabled; \
if [ $$? = 0 ] ; then \
$(ECHO) "/usr/bin/chcon -t textrel_shlib_t $@"; \
/usr/bin/chcon -t textrel_shlib_t $@; \
if [ $$? != 0 ]; then \
echo "ERROR: Cannot chcon $@"; \
fi; \
fi; \
fi; \
fi
endef
.PHONY: all build clean clobber
#
# Copyright 2001-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2001-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
......@@ -70,7 +70,6 @@ sanity-base: pre-sanity \
sane-compiler \
sane-cacerts \
sane-ant_version \
sane-findbugs_version \
sane-zip_version \
sane-msvcrt_path
......
......@@ -352,30 +352,6 @@ else
HOTSPOT_DOCS_IMPORT_PATH :=$(call DirExists,$(HOTSPOT_IMPORT_PATH)/docs,$(PROMOTED_BUILD_BASEDIR)/docs,/NO_DOCS_DIR)
endif
# PREVIOUS_JDK_FILE: filename of install bundle for previous JDK
ifdef ALT_PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE =$(ALT_PREVIOUS_JDK_FILE)
else
PREVIOUS_JDK_FILE = jdk-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE:=$(call AltCheckSpaces,PREVIOUS_JDK_FILE)
PREVIOUS_JDK_FILE:=$(call AltCheckValue,PREVIOUS_JDK_FILE)
# PREVIOUS_JRE_FILE: filename of install bundle for previous JRE
ifdef ALT_PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE =$(ALT_PREVIOUS_JRE_FILE)
else
PREVIOUS_JRE_FILE = jre-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE:=$(call AltCheckSpaces,PREVIOUS_JRE_FILE)
PREVIOUS_JRE_FILE:=$(call AltCheckValue,PREVIOUS_JRE_FILE)
# Set here as shared variables
PREVIOUS_JRE_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JRE_FILE)
PREVIOUS_JDK_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JDK_FILE)
# These are the same on all platforms but require the above platform include 1st
# BOOTDIR: Bootstrap JDK, previous released JDK.
......@@ -389,19 +365,70 @@ export BOOTDIR
BOOTDIR:=$(call AltCheckSpaces,BOOTDIR)
BOOTDIR:=$(call AltCheckValue,BOOTDIR)
# PREVIOUS_RELEASE_PATH: path to where previous release bundles are
ifdef ALT_PREVIOUS_RELEASE_PATH
PREVIOUS_RELEASE_PATH :=$(call OptFullPath,$(ALT_PREVIOUS_RELEASE_PATH))
else
PREVIOUS_RELEASE_PATH =$(SLASH_JAVA)/re/jdk/$(PREVIOUS_JDK_VERSION)/archive/fcs/bundles/$(PLATFORM)-$(ARCH)
endif
export PREVIOUS_RELEASE_PATH
PREVIOUS_RELEASE_PATH:=$(call AltCheckSpaces,PREVIOUS_RELEASE_PATH)
PREVIOUS_RELEASE_PATH:=$(call AltCheckValue,PREVIOUS_RELEASE_PATH)
# PREVIOUS_FCS_RE_AREA: re path to where previous release binaries/bundles are
PREVIOUS_FCS_RE_AREA = $(SLASH_JAVA)/re/jdk/$(PREVIOUS_JDK_VERSION)/archive/fcs
# PREVIOUS_RELEASE_IMAGE: Previous install image to compare against
ifdef ALT_PREVIOUS_RELEASE_IMAGE
# Explicit image provided, no bundle access needed
PREVIOUS_RELEASE_IMAGE :=$(call FullPath,$(ALT_PREVIOUS_RELEASE_IMAGE))
else
# PREVIOUS_RELEASE_PATH: path to where previous release bundles are
ifdef ALT_PREVIOUS_RELEASE_PATH
PREVIOUS_RELEASE_PATH :=$(call OptFullPath,$(ALT_PREVIOUS_RELEASE_PATH))
else
PREVIOUS_RELEASE_PATH := \
$(call DirExists,$(PREVIOUS_FCS_RE_AREA)/bundles/$(PLATFORM)-$(ARCH),,)
endif
# Depending on if we have access to these bundles
ifeq ($(PREVIOUS_RELEASE_PATH),)
# Use images in re area or BOOTDIR (which is normally the previous release)
PREVIOUS_RELEASE_IMAGE := \
$(call DirExists,$(PREVIOUS_FCS_RE_AREA)/binaries/$(PLATFORM)-$(ARCH),$(BOOTDIR),)
else
# Get names of and paths to bundles
PREVIOUS_RELEASE_PATH:=$(call AltCheckSpaces,PREVIOUS_RELEASE_PATH)
PREVIOUS_RELEASE_PATH:=$(call AltCheckValue,PREVIOUS_RELEASE_PATH)
export PREVIOUS_RELEASE_PATH
# PREVIOUS_JDK_FILE: filename of install bundle for previous JDK
ifdef ALT_PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE =$(ALT_PREVIOUS_JDK_FILE)
else
PREVIOUS_JDK_FILE = \
jdk-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JDK_FILE
PREVIOUS_JDK_FILE:=$(call AltCheckSpaces,PREVIOUS_JDK_FILE)
PREVIOUS_JDK_FILE:=$(call AltCheckValue,PREVIOUS_JDK_FILE)
# PREVIOUS_JRE_FILE: filename of install bundle for previous JRE
ifdef ALT_PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE =$(ALT_PREVIOUS_JRE_FILE)
else
PREVIOUS_JRE_FILE = \
jre-$(PREVIOUS_JDK_UNDERSCORE_VERSION)-$(PLATFORM)-$(ARCH)$(BUNDLE_FILE_SUFFIX)
endif
export PREVIOUS_JRE_FILE
PREVIOUS_JRE_FILE:=$(call AltCheckSpaces,PREVIOUS_JRE_FILE)
PREVIOUS_JRE_FILE:=$(call AltCheckValue,PREVIOUS_JRE_FILE)
# Paths to these bundles
PREVIOUS_JRE_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JRE_FILE)
PREVIOUS_JDK_BUNDLE = $(PREVIOUS_RELEASE_PATH)/$(PREVIOUS_JDK_FILE)
endif
endif
# Indicate we are using an image comparison
ifneq ($(PREVIOUS_RELEASE_IMAGE),)
PREVIOUS_RELEASE_PATH = USING-PREVIOUS_RELEASE_IMAGE
PREVIOUS_JRE_BUNDLE = USING-PREVIOUS_RELEASE_IMAGE
PREVIOUS_JDK_BUNDLE = USING-PREVIOUS_RELEASE_IMAGE
endif
# CACERTS_FILE: if OPENJDK is false and the internal version of the file
......@@ -513,23 +540,17 @@ JDK_CUPS_HEADERS_PATH=$(JDK_DEVTOOLS_DIR)/share/cups/include
endif
endif
# Utilities ant and findbugs
ifeq ($(ANT_HOME),)
ANT_HOME := $(call DirExists,/usr/share/ant,$(JDK_DEVTOOLS_DIR)/share/ant/latest,)
# Utilities ant
ifeq ($(PLATFORM), windows)
ifeq ($(ANT_HOME),)
ANT_HOME := $(call DirExists,$(JDK_DEVTOOLS_DIR)/share/ant/latest,,)
endif
endif
ifeq ($(ANT_HOME),)
ANT = ant
else
ANT = $(ANT_HOME)/bin/ant
endif
ifeq ($(FINDBUGS_HOME),)
FINDBUGS_HOME := $(call DirExists,/usr/share/findbugs,$(JDK_DEVTOOLS_DIR)/share/findbugs/latest,)
endif
ifeq ($(FINDBUGS_HOME),)
FINDBUGS = findbugs
else
FINDBUGS = $(FINDBUGS_HOME)/bin/findbugs
endif
ifdef ALT_COPYRIGHT_YEAR
COPYRIGHT_YEAR = $(ALT_COPYRIGHT_YEAR)
......
#
# Copyright 2005-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2005-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
......@@ -79,7 +79,6 @@ ALL_SETTINGS+=$(call addAltSetting,SLASH_JAVA)
ALL_SETTINGS+=$(call addRequiredSetting,VARIANT)
ALL_SETTINGS+=$(call addAltSetting,JDK_DEVTOOLS_DIR)
ALL_SETTINGS+=$(call addOptionalSetting,ANT_HOME)
ALL_SETTINGS+=$(call addOptionalSetting,FINDBUGS_HOME)
ALL_SETTINGS+=$(call addAltSetting,UNIXCOMMAND_PATH)
ALL_SETTINGS+=$(call addAltSetting,COMPILER_PATH)
ALL_SETTINGS+=$(call addAltSetting,DEVTOOLS_PATH)
......@@ -119,7 +118,6 @@ ifeq ($(PLATFORM),windows)
ALL_SETTINGS+=$(call addRequiredVersionSetting,LINK_VER)
endif
ALL_SETTINGS+=$(call addRequiredVersionSetting,ANT_VER)
ALL_SETTINGS+=$(call addRequiredVersionSetting,FINDBUGS_VER)
ALL_SETTINGS+=$(call addRequiredSetting,TEMPDIR)
......
......@@ -107,21 +107,9 @@ UNZIP_VER :=$(call GetVersion,"$(_UNZIP_VER)")
BOOT_VER :=$(call GetVersion,"$(_BOOT_VER)")
REQUIRED_ANT_VER := 1.6.3
ifeq ($(ANT_HOME),)
_ANT_VER:=$(shell JAVACMD="$(BOOTDIR)/bin/java" $(ANT) -version 2>&1 )
else
_ANT_VER:=$(shell JAVACMD="$(BOOTDIR)/bin/java" ANT_HOME="$(ANT_HOME)" $(ANT) -version 2>&1 )
endif
_ANT_VER:=$(shell $(ANT) -version 2>&1 )
ANT_VER:=$(call GetVersion,"$(_ANT_VER)")
REQUIRED_FINDBUGS_VER := 1.2
ifeq ($(FINDBUGS_HOME),)
_FINDBUGS_VER:=$(shell $(FINDBUGS) -javahome "$(BOOTDIR)" -textui -version 2>&1 )
else
_FINDBUGS_VER:=$(shell FINDBUGS_HOME="$(FINDBUGS_HOME)" $(FINDBUGS) -javahome "$(BOOTDIR)" -textui -version 2>&1 )
endif
FINDBUGS_VER:=$(call GetVersion,"$(_FINDBUGS_VER)")
ifdef ALT_BINDIR
ALT_BINDIR_VERSION := $(shell $(ALT_BINDIR)/java$(EXE_SUFFIX) -version 2>&1 | $(NAWK) -F'"' '{ print $$2 }')
ALT_BINDIR_OK := $(shell $(ECHO) $(ALT_BINDIR_VERSION) | $(EGREP) -c '^$(JDK_MAJOR_VERSION).$(JDK_MINOR_VERSION)')
......@@ -182,7 +170,6 @@ include $(JDK_MAKE_SHARED_DIR)/Sanity-Settings.gmk
sane-alsa-versioncheck \
sane-alsa-headers \
sane-ant_version \
sane-findbugs_version \
sane-zip_version \
sane-unzip_version \
sane-msvcrt_path \
......@@ -1216,19 +1203,6 @@ sane-ant_version:
"" >> $(WARNING_FILE) ; \
fi
######################################################
# Check the findbugs version
######################################################
FINDBUGS_CHECK :=$(call CheckVersions,$(FINDBUGS_VER),$(REQUIRED_FINDBUGS_VER))
sane-findbugs_version:
@if [ "$(FINDBUGS_CHECK)" != "same" \
-a "$(FINDBUGS_CHECK)" != "newer" ]; then \
$(ECHO) "WARNING: The version of findbugs being used is older than \n" \
" the required version of '$(REQUIRED_FINDBUGS_VER)'. \n" \
" The version of findbugs found was '$(FINDBUGS_VER)'. \n" \
"" >> $(WARNING_FILE) ; \
fi
######################################################
# Check the zip file version
######################################################
......
......@@ -158,6 +158,7 @@ CORE_PKGS = \
javax.management.event \
javax.management.loading \
javax.management.monitor \
javax.management.namespace \
javax.management.relation \
javax.management.openmbean \
javax.management.timer \
......
......@@ -449,6 +449,7 @@ JAVA_JAVA_java = \
sun/misc/JavaLangAccess.java \
sun/misc/JavaIOAccess.java \
sun/misc/JavaIODeleteOnExitAccess.java \
sun/misc/JavaIOFileDescriptorAccess.java
sun/misc/JavaIOFileDescriptorAccess.java \
sun/misc/JavaNioAccess.java
FILES_java = $(JAVA_JAVA_java)
......@@ -222,8 +222,6 @@ SUNWprivate_1.1 {
Java_java_lang_UNIXProcess_waitForProcessExit;
Java_java_lang_UNIXProcess_forkAndExec;
Java_java_lang_UNIXProcess_destroyProcess;
Java_java_nio_Bits_copyFromByteArray;
Java_java_nio_Bits_copyToByteArray;
Java_java_nio_Bits_copyFromShortArray;
Java_java_nio_Bits_copyToShortArray;
Java_java_nio_Bits_copyFromIntArray;
......
......@@ -113,7 +113,11 @@ ifeq ($(PLATFORM), windows)
JAVALIB =
OTHER_LCF = -export:JLI_Launch \
-export:JLI_ManifestIterate \
-export:JLI_SetTraceLauncher
-export:JLI_SetTraceLauncher \
-export:JLI_ReportErrorMessage \
-export:JLI_ReportErrorMessageSys \
-export:JLI_ReportMessage \
-export:JLI_ReportExceptionDescription
endif
......
#
# Copyright 2005-2006 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2005-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
......@@ -30,6 +30,10 @@ SUNWprivate_1.1 {
JLI_Launch;
JLI_ManifestIterate;
JLI_SetTraceLauncher;
JLI_ReportErrorMessage;
JLI_ReportErrorMessageSys;
JLI_ReportMessage;
JLI_ReportExceptionDescription;
local:
*;
};
......@@ -26,6 +26,7 @@
FILES_src = \
java/nio/Bits.java \
java/nio/Buffer.java \
java/nio/BufferPoolMXBean.java \
java/nio/ByteOrder.java \
java/nio/MappedByteBuffer.java \
java/nio/StringCharBuffer.java \
......@@ -38,6 +39,9 @@ FILES_src = \
java/nio/channels/FileLock.java \
java/nio/channels/GatheringByteChannel.java \
java/nio/channels/InterruptibleChannel.java \
java/nio/channels/MembershipKey.java \
java/nio/channels/MulticastChannel.java \
java/nio/channels/NetworkChannel.java \
java/nio/channels/ReadableByteChannel.java \
java/nio/channels/ScatteringByteChannel.java \
java/nio/channels/SelectableChannel.java \
......@@ -72,6 +76,7 @@ FILES_src = \
sun/nio/ch/DatagramSocketAdaptor.java \
sun/nio/ch/DefaultSelectorProvider.java \
sun/nio/ch/DirectBuffer.java \
sun/nio/ch/ExtendedSocketOption.java \
sun/nio/ch/FileChannelImpl.java \
sun/nio/ch/FileDispatcher.java \
sun/nio/ch/FileKey.java \
......@@ -79,12 +84,14 @@ FILES_src = \
sun/nio/ch/IOUtil.java \
sun/nio/ch/IOStatus.java \
sun/nio/ch/IOVecWrapper.java \
sun/nio/ch/MembershipKeyImpl.java \
sun/nio/ch/MembershipRegistry.java \
sun/nio/ch/NativeDispatcher.java \
sun/nio/ch/NativeObject.java \
sun/nio/ch/NativeThread.java \
sun/nio/ch/NativeThreadSet.java \
sun/nio/ch/Net.java \
sun/nio/ch/OptionAdaptor.java \
sun/nio/ch/OptionKey.java \
sun/nio/ch/PipeImpl.java \
sun/nio/ch/PollArrayWrapper.java \
sun/nio/ch/Reflect.java \
......@@ -98,8 +105,7 @@ FILES_src = \
sun/nio/ch/SocketAdaptor.java \
sun/nio/ch/SocketChannelImpl.java \
sun/nio/ch/SocketDispatcher.java \
sun/nio/ch/SocketOpts.java \
sun/nio/ch/SocketOptsImpl.java \
sun/nio/ch/SocketOptionRegistry.java \
sun/nio/ch/SourceChannelImpl.java \
sun/nio/ch/Util.java \
\
......@@ -239,6 +245,7 @@ FILES_gen_ex = \
java/nio/InvalidMarkException.java \
java/nio/ReadOnlyBufferException.java \
\
java/nio/channels/AlreadyBoundException.java \
java/nio/channels/AlreadyConnectedException.java \
java/nio/channels/AsynchronousCloseException.java \
java/nio/channels/ClosedByInterruptException.java \
......@@ -257,14 +264,15 @@ FILES_gen_ex = \
java/nio/channels/UnresolvedAddressException.java \
java/nio/channels/UnsupportedAddressTypeException.java \
\
sun/nio/ch/AlreadyBoundException.java \
\
java/nio/charset/CharacterCodingException.java \
java/nio/charset/IllegalCharsetNameException.java \
java/nio/charset/UnsupportedCharsetException.java
FILES_gen_csp = sun/nio/cs/StandardCharsets.java
FILES_gen = $(FILES_gen_coder) $(FILES_gen_buffer) $(FILES_gen_ex) $(FILES_gen_csp)
FILES_gen_sor = sun/nio/ch/SocketOptionRegistry.java
FILES_gen = $(FILES_gen_coder) $(FILES_gen_buffer) $(FILES_gen_ex) \
$(FILES_gen_csp) $(FILES_gen_sor)
FILES_java = $(FILES_src) $(FILES_gen)
......@@ -56,18 +56,18 @@ FILES_java += \
sun/nio/ch/DevPollSelectorProvider.java \
sun/nio/ch/InheritedChannel.java \
sun/nio/ch/PollSelectorProvider.java \
sun/nio/ch/PollSelectorImpl.java
sun/nio/ch/PollSelectorImpl.java
FILES_c += \
DevPollArrayWrapper.c \
InheritedChannel.c \
PollArrayWrapper.c \
NativeThread.c
NativeThread.c \
PollArrayWrapper.c
FILES_export += \
sun/nio/ch/DevPollArrayWrapper.java \
sun/nio/ch/InheritedChannel.java \
sun/nio/ch/NativeThread.java
sun/nio/ch/NativeThread.java
endif # PLATFORM = solaris
ifeq ($(PLATFORM), windows)
......@@ -94,14 +94,14 @@ FILES_java += \
FILES_c += \
EPollArrayWrapper.c \
PollArrayWrapper.c \
InheritedChannel.c \
NativeThread.c
NativeThread.c \
PollArrayWrapper.c
FILES_export += \
sun/nio/ch/EPollArrayWrapper.java \
sun/nio/ch/InheritedChannel.java \
sun/nio/ch/NativeThread.java
sun/nio/ch/NativeThread.java
endif # PLATFORM = linux
# Find platform-specific C source files
......@@ -618,12 +618,6 @@ $(BUF_GEN)/%Exception.java: genExceptions.sh $(BUF_SRC)/exceptions
@$(RM) $@.temp
$(GEN_EX_CMD) $(BUF_SRC)/exceptions $(BUF_GEN)
$(SCH_GEN)/%Exception.java: genExceptions.sh $(SCH_SRC)/exceptions
$(prep-target)
@$(RM) $@.temp
$(GEN_EX_CMD) $(SCH_SRC)/exceptions $(SCH_GEN)
#
# Generated charset-provider classes
#
......@@ -638,4 +632,29 @@ $(SCS_GEN)/StandardCharsets.java: genCharsetProvider.sh \
HASHER="$(BOOT_JAVA_CMD) -jar $(HASHER_JARFILE)" \
$(SH) -e genCharsetProvider.sh $(SCS_SRC)/standard-charsets $(SCS_GEN)
#
# Generated channel implementation classes.
# C source is compiled in TEMPDIR to avoid turds left by Windows compilers.
#
GENSOR_SRC = $(SHARE_SRC)/native/sun/nio/ch/genSocketOptionRegistry.c
GENSOR_EXE = $(TEMPDIR)/genSocketOptionRegistry$(EXE_SUFFIX)
SOR_COPYRIGHT_YEARS = $(shell $(CAT) $(GENSOR_SRC) | \
$(NAWK) '/^.*Copyright.*Sun/ { print $$3 }')
$(TEMPDIR)/$(GENSOR_SRC) : $(GENSOR_SRC)
$(install-file)
$(GENSOR_EXE) : $(TEMPDIR)/$(GENSOR_SRC)
$(prep-target)
($(CD) $(TEMPDIR); $(CC) $(CPPFLAGS) $(LDDFLAGS) \
-o genSocketOptionRegistry$(EXE_SUFFIX) $(GENSOR_SRC))
$(SCH_GEN)/SocketOptionRegistry.java: $(GENSOR_EXE)
$(prep-target)
NAWK="$(NAWK)" SH="$(SH)" $(SH) -e addNotices.sh $(SOR_COPYRIGHT_YEARS) > $@
$(GENSOR_EXE) >> $@
.PHONY: sources
#
# Copyright 2001-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.
#
SUNWprivate_1.1 {
global:
......@@ -18,6 +42,8 @@ SUNWprivate_1.1 {
Java_sun_nio_ch_EPollArrayWrapper_fdLimit;
Java_sun_nio_ch_EPollArrayWrapper_init;
Java_sun_nio_ch_EPollArrayWrapper_interrupt;
Java_sun_nio_ch_EPollArrayWrapper_offsetofData;
Java_sun_nio_ch_EPollArrayWrapper_sizeofEPollEvent;
Java_sun_nio_ch_FileChannelImpl_close0;
Java_sun_nio_ch_FileChannelImpl_force0;
Java_sun_nio_ch_FileChannelImpl_initIDs;
......@@ -59,20 +85,29 @@ SUNWprivate_1.1 {
Java_sun_nio_ch_NativeThread_init;
Java_sun_nio_ch_NativeThread_signal;
Java_sun_nio_ch_Net_socket0;
Java_sun_nio_ch_Net_bind;
Java_sun_nio_ch_Net_connect;
Java_sun_nio_ch_Net_bind0;
Java_sun_nio_ch_Net_connect0;
Java_sun_nio_ch_Net_listen;
Java_sun_nio_ch_Net_localPort;
Java_sun_nio_ch_Net_localInetAddress;
Java_sun_nio_ch_Net_getIntOption0;
Java_sun_nio_ch_Net_setIntOption0;
Java_sun_nio_ch_Net_initIDs;
Java_sun_nio_ch_Net_isIPv6Available0;
Java_sun_nio_ch_Net_joinOrDrop4;
Java_sun_nio_ch_Net_blockOrUnblock4;
Java_sun_nio_ch_Net_joinOrDrop6;
Java_sun_nio_ch_Net_blockOrUnblock6;
Java_sun_nio_ch_Net_setInterface4;
Java_sun_nio_ch_Net_getInterface4;
Java_sun_nio_ch_Net_setInterface6;
Java_sun_nio_ch_Net_getInterface6;
Java_sun_nio_ch_Net_shutdown;
Java_sun_nio_ch_PollArrayWrapper_interrupt;
Java_sun_nio_ch_PollArrayWrapper_poll0;
Java_sun_nio_ch_ServerSocketChannelImpl_accept0;
Java_sun_nio_ch_ServerSocketChannelImpl_initIDs;
Java_sun_nio_ch_ServerSocketChannelImpl_listen;
Java_sun_nio_ch_SocketChannelImpl_checkConnect;
Java_sun_nio_ch_SocketChannelImpl_shutdown;
local:
*;
......
#
# Copyright 2001-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.
#
SUNWprivate_1.1 {
global:
......@@ -59,20 +83,29 @@ SUNWprivate_1.1 {
Java_sun_nio_ch_NativeThread_init;
Java_sun_nio_ch_NativeThread_signal;
Java_sun_nio_ch_Net_socket0;
Java_sun_nio_ch_Net_bind;
Java_sun_nio_ch_Net_connect;
Java_sun_nio_ch_Net_bind0;
Java_sun_nio_ch_Net_connect0;
Java_sun_nio_ch_Net_listen;
Java_sun_nio_ch_Net_localPort;
Java_sun_nio_ch_Net_localInetAddress;
Java_sun_nio_ch_Net_getIntOption0;
Java_sun_nio_ch_Net_setIntOption0;
Java_sun_nio_ch_Net_initIDs;
Java_sun_nio_ch_Net_isIPv6Available0;
Java_sun_nio_ch_Net_joinOrDrop4;
Java_sun_nio_ch_Net_blockOrUnblock4;
Java_sun_nio_ch_Net_joinOrDrop6;
Java_sun_nio_ch_Net_blockOrUnblock6;
Java_sun_nio_ch_Net_setInterface4;
Java_sun_nio_ch_Net_getInterface4;
Java_sun_nio_ch_Net_setInterface6;
Java_sun_nio_ch_Net_getInterface6;
Java_sun_nio_ch_Net_shutdown;
Java_sun_nio_ch_PollArrayWrapper_interrupt;
Java_sun_nio_ch_PollArrayWrapper_poll0;
Java_sun_nio_ch_ServerSocketChannelImpl_accept0;
Java_sun_nio_ch_ServerSocketChannelImpl_initIDs;
Java_sun_nio_ch_ServerSocketChannelImpl_listen;
Java_sun_nio_ch_SocketChannelImpl_checkConnect;
Java_sun_nio_ch_SocketChannelImpl_shutdown;
local:
*;
......
......@@ -100,20 +100,16 @@ share="${jdk_devtools}/share"
# Needed for langtools, maybe other parts of the build
ANT_HOME="${share}/ant/latest"
export ANT_HOME
FINDBUGS_HOME="${share}/findbugs/latest"
export FINDBUGS_HOME
# The 3 bin directories in common to all platforms
sharebin="${share}/bin"
antbin="${ANT_HOME}/bin"
findbugsbin="${FINDBUGS_HOME}/bin"
# Check input
dirMustExist "${bootdir}" ALT_BOOTDIR
dirMustExist "${slashjava}" ALT_SLASH_JAVA
dirMustExist "${jdk_import}" ALT_JDK_IMPORT_PATH
dirMustExist "${ANT_HOME}" ANT_HOME
dirMustExist "${FINDBUGS_HOME}" FINDBUGS_HOME
# Use the JDK import for now (FIXME: use the binary plugs?)
if [ "${OPENJDK}" = true ] ; then
......@@ -143,7 +139,7 @@ if [ "${osname}" = SunOS ] ; then
ALT_COMPILER_PATH="${compiler_path}"
export ALT_COMPILER_PATH
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
path4sdk=${compiler_path}:${sharebin}:${antbin}:${findbugsbin}
path4sdk=${compiler_path}:${sharebin}:${antbin}
# Add basic solaris system paths
path4sdk=${path4sdk}:/usr/ccs/bin:/usr/ccs/lib:/usr/bin:/bin:/usr/sfw/bin
......@@ -180,7 +176,7 @@ elif [ "${osname}" = Linux ] ; then
ALT_COMPILER_PATH="${compiler_path}"
export ALT_COMPILER_PATH
dirMustExist "${compiler_path}" ALT_COMPILER_PATH
path4sdk=${compiler_path}:${sharebin}:${antbin}:${findbugsbin}
path4sdk=${compiler_path}:${sharebin}:${antbin}
# Add basic paths
path4sdk=${path4sdk}:/usr/bin:/bin:/usr/sbin:/sbin
......@@ -228,7 +224,7 @@ else
dosname="${mkshome}/mksnt/dosname -s"
# Most unix utilities are in the mksnt directory of ROOTDIR
unixcommand_path="${mkshome}/mksnt"
path4sdk="${sharebin};${antbin};${findbugsbin};${unixcommand_path}"
path4sdk="${sharebin};${antbin};${unixcommand_path}"
dirMustExist "${unixcommand_path}" ALT_UNIXCOMMAND_PATH
devtools_path="${jdk_devtools}/win32/bin"
path4sdk="${devtools_path};${path4sdk}"
......@@ -246,7 +242,7 @@ else
dosname="/usr/bin/cygpath -a -m -s"
# Most unix utilities are in the /usr/bin
unixcommand_path="/usr/bin"
path4sdk="${sharebin};${antbin};${findbugsbin};${unixcommand_path}"
path4sdk="${sharebin};${antbin};${unixcommand_path}"
dirMustExist "${unixcommand_path}" ALT_UNIXCOMMAND_PATH
# Find GNU make
make="${unixcommand_path}/make.exe"
......
......@@ -31,7 +31,7 @@ BUILDDIR = ../..
PRODUCT = java
include $(BUILDDIR)/common/Defs.gmk
SUBDIRS = server
SUBDIRS = multicast server
all build clean clobber::
$(SUBDIRS-loop)
......
#
# Copyright 2000-2007 Sun Microsystems, Inc. All Rights Reserved.
# Copyright 2007 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
......@@ -23,17 +23,30 @@
# have any questions.
#
# Generated exception classes for sun.nio.ch
#
# Makefile for the nio/multicast sample code
#
BUILDDIR = ../../..
PRODUCT = java
include $(BUILDDIR)/common/Defs.gmk
SAMPLE_SRC_DIR = $(SHARE_SRC)/sample/nio/multicast
SAMPLE_DST_DIR = $(SAMPLEDIR)/nio/multicast
SAMPLE_FILES = \
$(SAMPLE_DST_DIR)/Reader.java \
$(SAMPLE_DST_DIR)/Sender.java \
$(SAMPLE_DST_DIR)/MulticastAddress.java
SINCE=1.4
PACKAGE=sun.nio.ch
# This year should only change if the generated source is modified.
COPYRIGHT_YEARS=2000-2007
all build: $(SAMPLE_FILES)
$(SAMPLE_DST_DIR)/%: $(SAMPLE_SRC_DIR)/%
$(install-file)
SUPER=IllegalStateException
clean clobber:
$(RM) -r $(SAMPLE_DST_DIR)
gen AlreadyBoundException "
* Unchecked exception thrown when an attempt is made to bind a {@link
* SocketChannel} that is already bound." \
9002280723481772026L
.PHONY: all build clean clobber
......@@ -142,59 +142,59 @@ FILES_2D_c = \
# These files rely on motif to be built, and should not be included
# in a headless build.
FILES_MOTIF_c = \
awt_AWTEvent.c \
awt_Button.c \
awt_Canvas.c \
awt_Checkbox.c \
awt_Component.c \
awt_Cursor.c \
awt_DataTransferer.c \
awt_DrawingSurface.c \
awt_Event.c \
awt_FileDialog.c \
awt_GlobalCursorManager.c \
awt_GraphicsEnv.c \
awt_InputMethod.c \
awt_Insets.c \
awt_KeyboardFocusManager.c \
awt_Label.c \
awt_List.c \
awt_Menu.c \
awt_MenuBar.c \
awt_MenuComponent.c \
awt_MenuItem.c \
awt_motif.c \
awt_Plugin.c \
awt_PopupMenu.c \
awt_Robot.c \
awt_Scrollbar.c \
awt_ScrollPane.c \
awt_Selection.c \
awt_UNIXToolkit.c \
awt_TextArea.c \
awt_TextField.c \
awt_TopLevel.c \
awt_mgrsel.c \
awt_util.c \
awt_wm.c \
awt_XmDnD.c \
awt_dnd.c \
awt_dnd_ds.c \
awt_dnd_dt.c \
canvas.c \
cursor.c \
multi_font.c \
robot_common.c \
list.c \
multiVis.c \
XDrawingArea.c \
MouseInfo.c \
awt_xembed.c \
awt_xembed_server.c \
gtk2_interface.c \
swing_GTKEngine.c \
swing_GTKStyle.c
#FILES_MOTIF_c = \
#keep awt_AWTEvent.c \
# awt_Button.c \
# awt_Canvas.c \
# awt_Checkbox.c \
#keep .h awt_Component.c \
#keep .h awt_Cursor.c \
# awt_DataTransferer.c \
# awt_DrawingSurface.c \
# awt_Event.c \
# awt_FileDialog.c \
# awt_GlobalCursorManager.c \
# awt_GraphicsEnv.c \
# awt_InputMethod.c \
#keep awt_Insets.c \
# awt_KeyboardFocusManager.c \
# awt_Label.c \
# awt_List.c \
# awt_Menu.c \
# awt_MenuBar.c \
# awt_MenuComponent.c \
# awt_MenuItem.c \
# awt_motif.c \
# awt_Plugin.c \
# awt_PopupMenu.c \
# awt_Robot.c \
# awt_Scrollbar.c \
# awt_ScrollPane.c \
# awt_Selection.c \
# awt_UNIXToolkit.c \
# awt_TextArea.c \
# awt_TextField.c \
# awt_TopLevel.c \
# awt_mgrsel.c \
# awt_util.c \
# awt_wm.c \
# awt_XmDnD.c \
# awt_dnd.c \
# awt_dnd_ds.c \
# awt_dnd_dt.c \
# canvas.c \
# cursor.c \
# multi_font.c \
# robot_common.c \
# list.c \
# multiVis.c \
# XDrawingArea.c \
# MouseInfo.c \
# awt_xembed.c \
# awt_xembed_server.c \
# gtk2_interface.c \
# swing_GTKEngine.c \
# swing_GTKStyle.c
# These files are required to be built, with or without motif. Some of
......
......@@ -60,48 +60,15 @@ FILES_export = \
sun/awt/image/DataBufferNative.java \
\
sun/awt/motif/X11FontMetrics.java \
sun/awt/motif/X11Clipboard.java \
sun/awt/motif/X11Selection.java \
sun/awt/motif/X11SelectionHolder.java \
sun/awt/X11InputMethod.java \
sun/awt/motif/MInputMethod.java \
sun/awt/motif/MInputMethodControl.java \
sun/awt/motif/MCustomCursor.java \
sun/awt/motif/MFontConfiguration.java \
sun/awt/motif/MFontPeer.java \
sun/awt/motif/MToolkit.java \
sun/awt/motif/MComponentPeer.java \
sun/awt/motif/MButtonPeer.java \
sun/awt/motif/MCanvasPeer.java \
sun/awt/motif/MCheckboxPeer.java \
sun/awt/motif/MFileDialogPeer.java \
sun/awt/motif/MGlobalCursorManager.java \
sun/awt/motif/MTextFieldPeer.java \
sun/awt/motif/MLabelPeer.java \
sun/awt/motif/MListPeer.java \
sun/awt/motif/MWindowPeer.java \
sun/awt/motif/MMenuBarPeer.java \
sun/awt/motif/MMenuPeer.java \
sun/awt/motif/MPopupMenuPeer.java \
sun/awt/motif/MDialogPeer.java \
sun/awt/motif/MMenuItemPeer.java \
sun/awt/motif/MCheckboxMenuItemPeer.java \
sun/awt/motif/MChoicePeer.java \
sun/awt/motif/MTextAreaPeer.java \
sun/awt/motif/MScrollbarPeer.java \
sun/awt/motif/MScrollPanePeer.java \
sun/awt/motif/MFramePeer.java \
sun/awt/DebugSettings.java \
sun/awt/EmbeddedFrame.java \
sun/awt/motif/MEmbeddedFramePeer.java \
sun/awt/PlatformFont.java \
sun/awt/FontDescriptor.java \
sun/awt/NativeLibLoader.java \
sun/awt/motif/MDropTargetContextPeer.java \
sun/awt/motif/MDragSourceContextPeer.java \
sun/awt/motif/MRobotPeer.java \
sun/awt/motif/X11DragSourceContextPeer.java \
sun/awt/motif/X11DropTargetContextPeer.java \
sun/awt/X11GraphicsEnvironment.java \
sun/awt/X11GraphicsDevice.java \
sun/awt/X11GraphicsConfig.java \
......@@ -124,7 +91,6 @@ FILES_export = \
sun/java2d/cmm/ColorTransform.java \
sun/awt/datatransfer/DataTransferer.java \
sun/awt/dnd/SunDragSourceContextPeer.java \
sun/awt/motif/MDataTransferer.java \
sun/awt/motif/MToolkitThreadBlockedHandler.java \
sun/java2d/opengl/OGLBlitLoops.java \
sun/java2d/opengl/OGLContext.java \
......@@ -220,6 +186,5 @@ FILES_export2 = \
java/awt/event/NativeLibLoader.java \
java/awt/peer/ComponentPeer.java \
java/awt/dnd/DnDConstants.java \
sun/awt/CausedFocusEvent.java \
sun/awt/motif/MEmbedCanvasPeer.java
sun/awt/CausedFocusEvent.java
此差异已折叠。
此差异已折叠。
......@@ -28,14 +28,6 @@
#
INIT += $(LIB_LOCATION)
ifndef HEADLESS
ifeq ($(PLATFORM), linux)
ifeq ($(STATIC_MOTIF),false)
INIT += $(LIB_LOCATION)/libXm.so
endif
endif
endif
#
# Files
#
......@@ -52,13 +44,9 @@ include $(BUILDDIR)/sun/awt/FILES_export_unix.gmk
ifdef HEADLESS
FILES_c = $(FILES_NO_MOTIF_c)
else
FILES_c = $(FILES_MOTIF_c) $(FILES_NO_MOTIF_c)
ifeq ($(MOTIF_VERSION), 2)
FILES_c += awt_motif21.c
FILES_c += awt_Choice21.c
endif
# FILES_c = $(FILES_MOTIF_c) $(FILES_NO_MOTIF_c)
# XXX if in FILES_MOTIF_c there are unrelated to motif stuff, create a separate list!
FILES_c = $(FILES_NO_MOTIF_c)
endif
ifeq ($(PLATFORM), solaris)
......@@ -93,15 +81,6 @@ include $(BUILDDIR)/common/Library.gmk
$(LIB_LOCATION):
$(MKDIR) -p $@
ifeq ($(PLATFORM), linux)
ifeq ($(STATIC_MOTIF),false)
$(LIB_LOCATION)/libXm.so:
$(CP) $(MOTIF_LIB)/libXm.so $(LIB_LOCATION)/libXm.so
# Automounter problem makes the link fail on Redhat 6.1.
# $(LN) -s $(MOTIF_LIB)/libXm.so $(LIB_LOCATION)/libXm.so
endif
endif
clean::
#
......@@ -135,33 +114,49 @@ CFLAGS += -DHEADLESS=$(HEADLESS)
CPPFLAGS += -DHEADLESS=$(HEADLESS)
OTHER_LDLIBS =
else
CFLAGS += -DMOTIF_VERSION=$(MOTIF_VERSION)
ifeq ($(STATIC_MOTIF),true)
LIBXM = $(MOTIF_LIB)/libXm.a -lXp -lXmu
ifeq ($(PLATFORM), linux)
ifeq ($(ARCH_DATA_MODEL), 64)
LIBXT = -lXt
else
# Allows for builds on Debian GNU Linux, X11 is in a different place
LIBXT = $(firstword $(wildcard /usr/X11R6/lib/libXt.a) \
$(wildcard /usr/lib/libXt.a))
LIBSM = $(firstword $(wildcard /usr/X11R6/lib/libSM.a) \
$(wildcard /usr/lib/libSM.a))
LIBICE = $(firstword $(wildcard /usr/X11R6/lib/libICE.a) \
$(wildcard /usr/lib/libICE.a))
endif
endif
else
LIBXM = -L$(MOTIF_LIB) -lXm -lXp
ifeq ($(PLATFORM), linux)
LIBXT = -lXt
LIBSM =
LIBICE =
endif
endif
#CFLAGS += -DMOTIF_VERSION=$(MOTIF_VERSION)
#ifeq ($(STATIC_MOTIF),true)
# LIBXM = $(MOTIF_LIB)/libXm.a -lXp -lXmu
# ifeq ($(PLATFORM), linux)
# ifeq ($(ARCH_DATA_MODEL), 64)
# LIBXT = -lXt
# else
# # Allows for builds on Debian GNU Linux, X11 is in a different place
# LIBXT = $(firstword $(wildcard /usr/X11R6/lib/libXt.a) \
# $(wildcard /usr/lib/libXt.a))
# LIBSM = $(firstword $(wildcard /usr/X11R6/lib/libSM.a) \
# $(wildcard /usr/lib/libSM.a))
# LIBICE = $(firstword $(wildcard /usr/X11R6/lib/libICE.a) \
# $(wildcard /usr/lib/libICE.a))
# endif
# endif
#else
# LIBXM = -L$(MOTIF_LIB) -lXm -lXp
# ifeq ($(PLATFORM), linux)
# LIBXT = -lXt
# LIBSM =
# LIBICE =
# endif
#endif
LIBXTST = -lXtst
ifeq ($(PLATFORM), linux)
ifeq ($(ARCH_DATA_MODEL), 64)
# XXX what about the rest of them?
LIBXT = -lXt
else
# Allows for builds on Debian GNU Linux, X11 is in a different place
LIBXT = $(firstword $(wildcard /usr/X11R6/lib/libXt.a) \
$(wildcard /usr/lib/libXt.a))
LIBSM = $(firstword $(wildcard /usr/X11R6/lib/libSM.a) \
$(wildcard /usr/lib/libSM.a))
LIBICE = $(firstword $(wildcard /usr/X11R6/lib/libICE.a) \
$(wildcard /usr/lib/libICE.a))
LIBXTST = $(firstword $(wildcard /usr/X11R6/lib/libXtst.a) \
$(wildcard /usr/lib/libXtst.a))
endif
endif
# Use -lXmu for EditRes support
LIBXMU_DBG = -lXmu
......@@ -169,14 +164,14 @@ LIBXMU_OPT =
LIBXMU = $(LIBXMU_$(VARIANT))
ifeq ($(PLATFORM), solaris)
OTHER_LDLIBS = $(LIBXM) -lXt -lXext $(LIBXTST) $(LIBXMU) -lX11 -lXi
OTHER_LDLIBS = -lXt -lXext $(LIBXTST) $(LIBXMU) -lX11 -lXi
endif
ifeq ($(PLATFORM), linux)
OTHER_CFLAGS += -DMLIB_NO_LIBSUNMATH
OTHER_CFLAGS += -DMOTIF_VERSION=2
# XXX what is this define below? Isn't it motif-related?
OTHER_CFLAGS += -DXMSTRINGDEFINES=1
OTHER_LDLIBS = $(LIBXM) $(LIBXMU) $(LIBXTST) -lXext $(LIBXT) $(LIBSM) $(LIBICE) -lX11 -lXi
OTHER_LDLIBS = $(LIBXMU) $(LIBXTST) -lXext $(LIBXT) $(LIBSM) $(LIBICE) -lX11 -lXi
endif
endif
......@@ -199,9 +194,8 @@ endif
CPPFLAGS += -I$(CUPS_HEADERS_PATH)
ifndef HEADLESS
CPPFLAGS += -I$(MOTIF_DIR)/include \
-I$(OPENWIN_HOME)/include
LDFLAGS += -L$(MOTIF_LIB) -L$(OPENWIN_LIB)
CPPFLAGS += -I$(OPENWIN_HOME)/include
LDFLAGS += -L$(OPENWIN_LIB)
endif # !HEADLESS
......
......@@ -25,8 +25,8 @@
/*
* This file primarily consists of all the error and warning messages, that
* are used in ReportErrorMessage. All message must be defined here, in order
* to help in I18N/L10N the messages.
* are used in JLI_ReportErrorMessage. All message must be defined here, in
* order to help with localizing the messages.
*/
#ifndef _EMESSAGES_H
......
......@@ -148,7 +148,7 @@ static void ShowSplashScreen();
static jboolean IsWildCardEnabled();
#define ARG_CHECK(n, f, a) if (n < 1) { \
ReportErrorMessage(f, a); \
JLI_ReportErrorMessage(f, a); \
printUsage = JNI_TRUE; \
*pret = 1; \
return JNI_TRUE; \
......@@ -326,15 +326,15 @@ JavaMain(void * _args)
start = CounterGet();
if (!InitializeJVM(&vm, &env, &ifn)) {
ReportErrorMessage(JVM_ERROR1);
JLI_ReportErrorMessage(JVM_ERROR1);
exit(1);
}
if (printVersion || showVersion) {
PrintJavaVersion(env, showVersion);
if ((*env)->ExceptionOccurred(env)) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
if (printVersion) {
......@@ -347,8 +347,8 @@ JavaMain(void * _args)
if (printXUsage || printUsage || (jarfile == 0 && classname == 0)) {
PrintUsage(env, printXUsage);
if ((*env)->ExceptionOccurred(env)) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
ret=1;
}
goto leave;
......@@ -397,43 +397,43 @@ JavaMain(void * _args)
if (jarfile != 0) {
mainClassName = GetMainClassName(env, jarfile);
if ((*env)->ExceptionOccurred(env)) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
if (mainClassName == NULL) {
ReportErrorMessage(JAR_ERROR1,jarfile, GEN_ERROR);
JLI_ReportErrorMessage(JAR_ERROR1,jarfile, GEN_ERROR);
goto leave;
}
classname = (char *)(*env)->GetStringUTFChars(env, mainClassName, 0);
if (classname == NULL) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
mainClass = LoadClass(env, classname);
if(mainClass == NULL) { /* exception occured */
ReportExceptionDescription(env);
ReportErrorMessage(CLS_ERROR1, classname);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(CLS_ERROR1, classname);
goto leave;
}
(*env)->ReleaseStringUTFChars(env, mainClassName, classname);
} else {
mainClassName = NewPlatformString(env, classname);
if (mainClassName == NULL) {
ReportErrorMessage(CLS_ERROR2, classname, GEN_ERROR);
JLI_ReportErrorMessage(CLS_ERROR2, classname, GEN_ERROR);
goto leave;
}
classname = (char *)(*env)->GetStringUTFChars(env, mainClassName, 0);
if (classname == NULL) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
mainClass = LoadClass(env, classname);
if(mainClass == NULL) { /* exception occured */
ReportExceptionDescription(env);
ReportErrorMessage(CLS_ERROR1, classname);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(CLS_ERROR1, classname);
goto leave;
}
(*env)->ReleaseStringUTFChars(env, mainClassName, classname);
......@@ -444,10 +444,10 @@ JavaMain(void * _args)
"([Ljava/lang/String;)V");
if (mainID == NULL) {
if ((*env)->ExceptionOccurred(env)) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
} else {
ReportErrorMessage(CLS_ERROR3);
JLI_ReportErrorMessage(CLS_ERROR3);
}
goto leave;
}
......@@ -459,8 +459,8 @@ JavaMain(void * _args)
mainID, JNI_TRUE);
if( obj == NULL) { /* exception occurred */
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
......@@ -469,14 +469,14 @@ JavaMain(void * _args)
(*env)->GetObjectClass(env, obj),
"getModifiers", "()I");
if ((*env)->ExceptionOccurred(env)) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
mods = (*env)->CallIntMethod(env, obj, mid);
if ((mods & 1) == 0) { /* if (!Modifier.isPublic(mods)) ... */
ReportErrorMessage(CLS_ERROR4);
JLI_ReportErrorMessage(CLS_ERROR4);
goto leave;
}
}
......@@ -484,8 +484,8 @@ JavaMain(void * _args)
/* Build argument array */
mainArgs = NewPlatformStringArray(env, argv, argc);
if (mainArgs == NULL) {
ReportExceptionDescription(env);
ReportErrorMessage(JNI_ERROR);
JLI_ReportExceptionDescription(env);
JLI_ReportErrorMessage(JNI_ERROR);
goto leave;
}
......@@ -506,7 +506,7 @@ JavaMain(void * _args)
* launcher's return code except by calling System.exit.
*/
if ((*vm)->DetachCurrentThread(vm) != 0) {
ReportErrorMessage(JVM_ERROR2);
JLI_ReportErrorMessage(JVM_ERROR2);
ret = 1;
goto leave;
}
......@@ -635,7 +635,7 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) {
if (loopCount > knownVMsCount) {
if (!speculative) {
ReportErrorMessage(CFG_ERROR1);
JLI_ReportErrorMessage(CFG_ERROR1);
exit(1);
} else {
return "ERROR";
......@@ -645,7 +645,7 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) {
if (nextIdx < 0) {
if (!speculative) {
ReportErrorMessage(CFG_ERROR2, knownVMs[jvmidx].alias);
JLI_ReportErrorMessage(CFG_ERROR2, knownVMs[jvmidx].alias);
exit(1);
} else {
return "ERROR";
......@@ -660,7 +660,7 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) {
switch (knownVMs[jvmidx].flag) {
case VM_WARN:
if (!speculative) {
ReportErrorMessage(CFG_WARN1, jvmtype, knownVMs[0].name + 1);
JLI_ReportErrorMessage(CFG_WARN1, jvmtype, knownVMs[0].name + 1);
}
/* fall through */
case VM_IGNORE:
......@@ -670,7 +670,7 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) {
break;
case VM_ERROR:
if (!speculative) {
ReportErrorMessage(CFG_ERROR3, jvmtype);
JLI_ReportErrorMessage(CFG_ERROR3, jvmtype);
exit(1);
} else {
return "ERROR";
......@@ -879,9 +879,9 @@ SelectVersion(int argc, char **argv, char **main_class)
if (jarflag && operand) {
if ((res = JLI_ParseManifest(operand, &info)) != 0) {
if (res == -1)
ReportErrorMessage(JAR_ERROR2, operand);
JLI_ReportErrorMessage(JAR_ERROR2, operand);
else
ReportErrorMessage(JAR_ERROR3, operand);
JLI_ReportErrorMessage(JAR_ERROR3, operand);
exit(1);
}
......@@ -948,7 +948,7 @@ SelectVersion(int argc, char **argv, char **main_class)
* Check for correct syntax of the version specification (JSR 56).
*/
if (!JLI_ValidVersionString(info.jre_version)) {
ReportErrorMessage(SPC_ERROR1, info.jre_version);
JLI_ReportErrorMessage(SPC_ERROR1, info.jre_version);
exit(1);
}
......@@ -970,7 +970,7 @@ SelectVersion(int argc, char **argv, char **main_class)
JLI_MemFree(new_argv);
return;
} else {
ReportErrorMessage(CFG_ERROR4, info.jre_version);
JLI_ReportErrorMessage(CFG_ERROR4, info.jre_version);
exit(1);
}
}
......@@ -1040,7 +1040,7 @@ ParseArguments(int *pargc, char ***pargv, char **pjarfile,
* command line options.
*/
} else if (JLI_StrCmp(arg, "-fullversion") == 0) {
ReportMessage("%s full version \"%s\"", _launcher_name, GetFullVersion());
JLI_ReportMessage("%s full version \"%s\"", _launcher_name, GetFullVersion());
return JNI_FALSE;
} else if (JLI_StrCmp(arg, "-verbosegc") == 0) {
AddOption("-verbose:gc", NULL);
......@@ -1080,7 +1080,7 @@ ParseArguments(int *pargc, char ***pargv, char **pjarfile,
JLI_StrCmp(arg, "-cs") == 0 ||
JLI_StrCmp(arg, "-noasyncgc") == 0) {
/* No longer supported */
ReportErrorMessage(ARG_WARN, arg);
JLI_ReportErrorMessage(ARG_WARN, arg);
} else if (JLI_StrCCmp(arg, "-version:") == 0 ||
JLI_StrCmp(arg, "-no-jre-restrict-search") == 0 ||
JLI_StrCmp(arg, "-jre-restrict-search") == 0 ||
......@@ -1143,12 +1143,12 @@ InitializeJVM(JavaVM **pvm, JNIEnv **penv, InvocationFunctions *ifn)
#define NULL_CHECK0(e) if ((e) == 0) { \
ReportErrorMessage(JNI_ERROR); \
JLI_ReportErrorMessage(JNI_ERROR); \
return 0; \
}
#define NULL_CHECK(e) if ((e) == 0) { \
ReportErrorMessage(JNI_ERROR); \
JLI_ReportErrorMessage(JNI_ERROR); \
return; \
}
......@@ -1351,7 +1351,7 @@ TranslateApplicationArgs(int jargc, const char **jargv, int *pargc, char ***parg
char *arg = argv[i];
if (arg[0] == '-' && arg[1] == 'J') {
if (arg[2] == '\0') {
ReportErrorMessage(ARG_ERROR3);
JLI_ReportErrorMessage(ARG_ERROR3);
exit(1);
}
*nargv++ = arg + 2;
......@@ -1418,7 +1418,7 @@ AddApplicationOptions(int cpathc, const char **cpathv)
}
if (!GetApplicationHome(home, sizeof(home))) {
ReportErrorMessage(CFG_ERROR5);
JLI_ReportErrorMessage(CFG_ERROR5);
return JNI_FALSE;
}
......@@ -1691,7 +1691,7 @@ ReadKnownVMs(const char *jrepath, const char * arch, jboolean speculative)
jvmCfg = fopen(jvmCfgName, "r");
if (jvmCfg == NULL) {
if (!speculative) {
ReportErrorMessage(CFG_ERROR6, jvmCfgName);
JLI_ReportErrorMessage(CFG_ERROR6, jvmCfgName);
exit(1);
} else {
return -1;
......@@ -1703,7 +1703,7 @@ ReadKnownVMs(const char *jrepath, const char * arch, jboolean speculative)
if (line[0] == '#')
continue;
if (line[0] != '-') {
ReportErrorMessage(CFG_WARN2, lineno, jvmCfgName);
JLI_ReportErrorMessage(CFG_WARN2, lineno, jvmCfgName);
}
if (cnt >= knownVMsLimit) {
GrowKnownVMs(cnt);
......@@ -1711,13 +1711,13 @@ ReadKnownVMs(const char *jrepath, const char * arch, jboolean speculative)
line[JLI_StrLen(line)-1] = '\0'; /* remove trailing newline */
tmpPtr = line + JLI_StrCSpn(line, whiteSpace);
if (*tmpPtr == 0) {
ReportErrorMessage(CFG_WARN3, lineno, jvmCfgName);
JLI_ReportErrorMessage(CFG_WARN3, lineno, jvmCfgName);
} else {
/* Null-terminate this string for JLI_StringDup below */
*tmpPtr++ = 0;
tmpPtr += JLI_StrSpn(tmpPtr, whiteSpace);
if (*tmpPtr == 0) {
ReportErrorMessage(CFG_WARN3, lineno, jvmCfgName);
JLI_ReportErrorMessage(CFG_WARN3, lineno, jvmCfgName);
} else {
if (!JLI_StrCCmp(tmpPtr, "KNOWN")) {
vmType = VM_KNOWN;
......@@ -1727,7 +1727,7 @@ ReadKnownVMs(const char *jrepath, const char * arch, jboolean speculative)
tmpPtr += JLI_StrSpn(tmpPtr, whiteSpace);
}
if (*tmpPtr == 0) {
ReportErrorMessage(CFG_WARN3, lineno, jvmCfgName);
JLI_ReportErrorMessage(CFG_WARN3, lineno, jvmCfgName);
} else {
/* Null terminate altVMName */
altVMName = tmpPtr;
......@@ -1747,7 +1747,7 @@ ReadKnownVMs(const char *jrepath, const char * arch, jboolean speculative)
tmpPtr += JLI_StrSpn(tmpPtr, whiteSpace);
}
if (*tmpPtr == 0) {
ReportErrorMessage(CFG_WARN4, lineno, jvmCfgName);
JLI_ReportErrorMessage(CFG_WARN4, lineno, jvmCfgName);
} else {
/* Null terminate server class VM name */
serverClassVMName = tmpPtr;
......@@ -1756,7 +1756,7 @@ ReadKnownVMs(const char *jrepath, const char * arch, jboolean speculative)
vmType = VM_IF_SERVER_CLASS;
}
} else {
ReportErrorMessage(CFG_WARN5, lineno, &jvmCfgName[0]);
JLI_ReportErrorMessage(CFG_WARN5, lineno, &jvmCfgName[0]);
vmType = VM_KNOWN;
}
}
......@@ -2019,7 +2019,7 @@ RemovableOption(char * option)
* A utility procedure to always print to stderr
*/
void
ReportMessage(const char* fmt, ...)
JLI_ReportMessage(const char* fmt, ...)
{
va_list vl;
va_start(vl, fmt);
......
......@@ -121,24 +121,20 @@ void CreateExecutionEnvironment(int *_argc,
char jvmpath[],
jint so_jvmpath,
char **original_argv);
/* Reports an error message to stderr or a window as appropriate. */
void JLI_ReportErrorMessage(const char * message, ...);
/*
* Report an error message to stderr or a window as appropriate.
*/
void ReportErrorMessage(const char * message, ...);
void ReportErrorMessageSys(const char * format, ...);
/* Reports a system error message to stderr or a window */
void JLI_ReportErrorMessageSys(const char * message, ...);
/*
* Report an error message only to stderr.
*/
void ReportMessage(const char * message, ...);
/* Reports an error message only to stderr. */
void JLI_ReportMessage(const char * message, ...);
/*
* Report an exception which terminates the vm to stderr or a window
* Reports an exception which terminates the vm to stderr or a window
* as appropriate.
*/
void ReportExceptionDescription(JNIEnv * env);
void JLI_ReportExceptionDescription(JNIEnv * env);
void PrintMachineDependentOptions();
const char *jlong_format_specifier();
......
......@@ -176,6 +176,18 @@ public class JmxProperties {
public static final String RELATION_LOGGER_NAME =
"javax.management.relation";
/**
* Logger name for Namespaces.
*/
public static final String NAMESPACE_LOGGER_NAME =
"javax.management.namespace";
/**
* Logger name for Namespaces.
*/
public static final Logger NAMESPACE_LOGGER =
Logger.getLogger(NAMESPACE_LOGGER_NAME);
/**
* Logger for Relation Service.
*/
......
......@@ -213,8 +213,8 @@ public class Button extends Component implements Accessible {
}
// This could change the preferred size of the Component.
if (testvalid && valid) {
invalidate();
if (testvalid) {
invalidateIfValid();
}
}
......
......@@ -556,8 +556,7 @@ public class ContainerOrderFocusTraversalPolicy extends FocusTraversalPolicy
* enabled, and focusable; <code>false</code> otherwise
*/
protected boolean accept(Component aComponent) {
if (!(aComponent.isVisible() && aComponent.isDisplayable() &&
aComponent.isFocusable() && aComponent.isEnabled())) {
if (!aComponent.canBeFocusOwner()) {
return false;
}
......
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册