Merge
This commit is contained in:
commit
9c966207ef
1
.hgtags
1
.hgtags
@ -206,3 +206,4 @@ e41d716405b209d3eddef8bd4240cec2bd34dcca jdk8-b81
|
||||
5e8c55025644730385a6f8fa029ecdb2d2c98a07 jdk8-b82
|
||||
bcebd3fdefc91abb9d7fa0c5af6211b3f8720da6 jdk8-b83
|
||||
d7ad0dfaa41151bd3a9ae46725b0aec3730a9cd0 jdk8-b84
|
||||
1872c12529090e1c1dbf567f02ad7ae6231b8f0c jdk8-b85
|
||||
|
@ -206,3 +206,4 @@ fd1a5574cf68af24bfd52decc37ac6361afb278a jdk8-b78
|
||||
29153d0df68f84162ffe8c2cf4f402a3f2245e85 jdk8-b82
|
||||
466685ba01bfb7bc1e1ac61490fd8c0f3cc18763 jdk8-b83
|
||||
01f631f89fa392b4e484d0812c40ea8f9d2353aa jdk8-b84
|
||||
7fc358f5943676b82f1dccd3152b1ac07d92e38b jdk8-b85
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copyright (c) 2012, 2013 Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copyright (c) 2012, 2013 Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
|
@ -30,7 +30,7 @@ pull_extra_base="$2"
|
||||
# Python always buffers stdout significantly, thus we will not see any output from hg clone jdk,
|
||||
# until a lot of time has passed! By passing -u to python, we get incremental updates
|
||||
# on stdout. Much nicer.
|
||||
whichhg="`which hg`"
|
||||
whichhg="`which hg 2> /dev/null | grep -v '^no hg in'`"
|
||||
|
||||
if [ "${whichhg}" = "" ] ; then
|
||||
echo Cannot find hg!
|
||||
@ -51,7 +51,7 @@ if [ "#!" = "$has_hash_bang" ] ; then
|
||||
bpython="`basename "$python"`"
|
||||
fi
|
||||
|
||||
if [ "python" = "$bpython" -a -x "$python" ] ; then
|
||||
if [ -x "$python" -a ! -d "$python" -a "`${python} -V 2>&1 | cut -f 1 -d ' '`" = "Python" ] ; then
|
||||
hg="${python} -u ${whichhg}"
|
||||
else
|
||||
echo Cannot find python from hg launcher. Running plain hg, which probably has buffered stdout.
|
||||
|
@ -196,7 +196,7 @@ $(OUTPUT_ROOT)/source_tips: FRC
|
||||
|
||||
|
||||
# Remove everything, except the output from configure.
|
||||
clean: clean-langtools clean-corba clean-jaxp clean-jaxws clean-hotspot clean-jdk clean-nashorn clean-images clean-overlay-images clean-bootcycle-build clean-docs
|
||||
clean: clean-langtools clean-corba clean-jaxp clean-jaxws clean-hotspot clean-jdk clean-nashorn clean-images clean-overlay-images clean-bootcycle-build clean-docs clean-test
|
||||
@($(CD) $(OUTPUT_ROOT) && $(RM) -r tmp source_tips build.log* build-trace*.log*)
|
||||
@$(ECHO) Cleaned all build artifacts.
|
||||
|
||||
@ -237,6 +237,8 @@ clean-bootcycle-build:
|
||||
clean-docs:
|
||||
$(call CleanComponent,docs)
|
||||
$(call CleanComponent,docstemp)
|
||||
clean-test:
|
||||
$(call CleanComponent,testoutput)
|
||||
|
||||
.PHONY: langtools corba jaxp jaxws hotspot jdk nashorn images overlay-images install
|
||||
.PHONY: langtools-only corba-only jaxp-only jaxws-only hotspot-only jdk-only nashorn-only images-only overlay-images-only install-only
|
||||
|
@ -206,3 +206,4 @@ e41fb1aa0329767b2737303c994e38bede1baa07 jdk8-b79
|
||||
48e1bc77004d9af575b733c04637b98fd17603c2 jdk8-b82
|
||||
a45bb25a67c7517b45f00c9682e317f46fecbba9 jdk8-b83
|
||||
928f8b888deb785cbd7bbd5f951cd6880f11f14e jdk8-b84
|
||||
9583a6431596bac1959d2d8828f5ea217843dd12 jdk8-b85
|
||||
|
@ -330,3 +330,8 @@ e3a41fc0234895eba4f272b984f7dacff495f8eb hs25-b24
|
||||
8d0f263a370c5f3e61791bb06054560804117288 hs25-b25
|
||||
af788b85010ebabbc1e8f52c6766e08c7a95cf99 jdk8-b84
|
||||
a947f40fb536e5b9e0aa210cf26abb430f80887a hs25-b26
|
||||
42fe530cd478744a4d12a0cbf803f0fc804bab1a jdk8-b85
|
||||
09b0d3e9ba6cdf7da07d4010d2d1df14596f6864 hs25-b27
|
||||
6d88a566d369f6a1f86912cad7d0912686b2fda1 hs25-b28
|
||||
86db4847f195c0ecceea646431f1ff22d56282e8 jdk8-b86
|
||||
01d5f04e64dc2d64625b2db2056f5ed4de918a45 hs25-b29
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Top level gnumake file for hotspot builds
|
||||
@ -85,15 +85,15 @@ else
|
||||
endif
|
||||
|
||||
# Typical C1/C2 targets made available with this Makefile
|
||||
C1_VM_TARGETS=product1 fastdebug1 optimized1 jvmg1
|
||||
C2_VM_TARGETS=product fastdebug optimized jvmg
|
||||
ZERO_VM_TARGETS=productzero fastdebugzero optimizedzero jvmgzero
|
||||
SHARK_VM_TARGETS=productshark fastdebugshark optimizedshark jvmgshark
|
||||
MINIMAL1_VM_TARGETS=productminimal1 fastdebugminimal1 jvmgminimal1
|
||||
C1_VM_TARGETS=product1 fastdebug1 optimized1 debug1
|
||||
C2_VM_TARGETS=product fastdebug optimized debug
|
||||
ZERO_VM_TARGETS=productzero fastdebugzero optimizedzero debugzero
|
||||
SHARK_VM_TARGETS=productshark fastdebugshark optimizedshark debugshark
|
||||
MINIMAL1_VM_TARGETS=productminimal1 fastdebugminimal1 debugminimal1
|
||||
|
||||
COMMON_VM_PRODUCT_TARGETS=product product1 docs export_product
|
||||
COMMON_VM_FASTDEBUG_TARGETS=fastdebug fastdebug1 docs export_fastdebug
|
||||
COMMON_VM_DEBUG_TARGETS=jvmg jvmg1 docs export_debug
|
||||
COMMON_VM_DEBUG_TARGETS=debug debug1 docs export_debug
|
||||
|
||||
# JDK directory list
|
||||
JDK_DIRS=bin include jre lib demo
|
||||
@ -103,13 +103,13 @@ all: all_product all_fastdebug
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
all_product: productminimal1
|
||||
all_fastdebug: fastdebugminimal1
|
||||
all_debug: jvmgminimal1
|
||||
all_debug: debugminimal1
|
||||
endif
|
||||
|
||||
ifdef BUILD_CLIENT_ONLY
|
||||
all_product: product1 docs export_product
|
||||
all_fastdebug: fastdebug1 docs export_fastdebug
|
||||
all_debug: jvmg1 docs export_debug
|
||||
all_debug: debug1 docs export_debug
|
||||
else
|
||||
ifeq ($(MACOSX_UNIVERSAL),true)
|
||||
all_product: universal_product
|
||||
@ -127,13 +127,13 @@ all_optimized: optimized optimized1 docs export_optimized
|
||||
allzero: all_productzero all_fastdebugzero
|
||||
all_productzero: productzero docs export_product
|
||||
all_fastdebugzero: fastdebugzero docs export_fastdebug
|
||||
all_debugzero: jvmgzero docs export_debug
|
||||
all_debugzero: debugzero docs export_debug
|
||||
all_optimizedzero: optimizedzero docs export_optimized
|
||||
|
||||
allshark: all_productshark all_fastdebugshark
|
||||
all_productshark: productshark docs export_product
|
||||
all_fastdebugshark: fastdebugshark docs export_fastdebug
|
||||
all_debugshark: jvmgshark docs export_debug
|
||||
all_debugshark: debugshark docs export_debug
|
||||
all_optimizedshark: optimizedshark docs export_optimized
|
||||
|
||||
# Do everything
|
||||
@ -227,7 +227,7 @@ generic_buildshark:
|
||||
$(MKDIR) -p $(OUTPUTDIR)
|
||||
$(CD) $(OUTPUTDIR); \
|
||||
$(MAKE) -f $(ABS_OS_MAKEFILE) \
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
$(MAKE_ARGS) $(VM_TARGET)
|
||||
|
||||
generic_buildminimal1:
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
@ -260,7 +260,7 @@ export_fastdebug:
|
||||
EXPORT_SUBDIR=/$(@:export_%=%) \
|
||||
generic_export
|
||||
export_debug:
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%=%) VM_SUBDIR=${VM_DEBUG} \
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%=%) VM_SUBDIR=$(@:export_%=%) \
|
||||
EXPORT_SUBDIR=/$(@:export_%=%) \
|
||||
generic_export
|
||||
export_optimized:
|
||||
@ -281,192 +281,197 @@ export_fastdebug_jdk::
|
||||
ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/$(@:export_%_jdk=%) \
|
||||
generic_export
|
||||
export_debug_jdk::
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%_jdk=%) VM_SUBDIR=${VM_DEBUG} \
|
||||
$(MAKE) BUILD_FLAVOR=$(@:export_%_jdk=%) VM_SUBDIR=$(@:export_%_jdk=%) \
|
||||
ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/$(@:export_%_jdk=%) \
|
||||
generic_export
|
||||
|
||||
# Export file copy rules
|
||||
XUSAGE=$(HS_SRC_DIR)/share/vm/Xusage.txt
|
||||
DOCS_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_docs
|
||||
C1_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_compiler1
|
||||
C2_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_compiler2
|
||||
ZERO_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_zero
|
||||
SHARK_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_shark
|
||||
C1_DIR=$(C1_BASE_DIR)/$(VM_SUBDIR)
|
||||
C2_DIR=$(C2_BASE_DIR)/$(VM_SUBDIR)
|
||||
ZERO_DIR=$(ZERO_BASE_DIR)/$(VM_SUBDIR)
|
||||
SHARK_DIR=$(SHARK_BASE_DIR)/$(VM_SUBDIR)
|
||||
MINIMAL1_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_minimal1
|
||||
MINIMAL1_DIR=$(MINIMAL1_BASE_DIR)/$(VM_SUBDIR)
|
||||
DOCS_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_docs
|
||||
C1_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_compiler1/$(VM_SUBDIR)
|
||||
C2_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_compiler2/$(VM_SUBDIR)
|
||||
MINIMAL1_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_minimal1/$(VM_SUBDIR)
|
||||
ZERO_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_zero/$(VM_SUBDIR)
|
||||
SHARK_DIR =$(OUTPUTDIR)/$(VM_PLATFORM)_shark/$(VM_SUBDIR)
|
||||
|
||||
# Server (C2)
|
||||
ifeq ($(JVM_VARIANT_SERVER), true)
|
||||
MISC_DIR=$(C2_DIR)
|
||||
GEN_DIR=$(C2_BASE_DIR)/generated
|
||||
# Common
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(C2_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(C2_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Windows
|
||||
$(EXPORT_SERVER_DIR)/%.dll: $(C2_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.pdb: $(C2_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.map: $(C2_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(C2_DIR)/%.lib
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.dll: $(C2_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.pdb: $(C2_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.map: $(C2_DIR)/%.map
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(C2_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(C2_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.$(LIBRARY_SUFFIX): $(C2_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(C2_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(C2_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.debuginfo: $(C2_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
|
||||
# Client (C1)
|
||||
ifeq ($(JVM_VARIANT_CLIENT), true)
|
||||
MISC_DIR=$(C1_DIR)
|
||||
GEN_DIR=$(C1_BASE_DIR)/generated
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
MISC_DIR=$(SHARK_DIR)
|
||||
GEN_DIR=$(SHARK_BASE_DIR)/generated
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZERO), true)
|
||||
MISC_DIR=$(ZERO_DIR)
|
||||
GEN_DIR=$(ZERO_BASE_DIR)/generated
|
||||
# Common
|
||||
$(EXPORT_CLIENT_DIR)/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(C1_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(C1_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Windows
|
||||
$(EXPORT_CLIENT_DIR)/%.dll: $(C1_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.pdb: $(C1_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.map: $(C1_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(C1_DIR)/%.lib
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.dll: $(C1_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.pdb: $(C1_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.map: $(C1_DIR)/%.map
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(C1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.$(LIBRARY_SUFFIX): $(C1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.$(LIBRARY_SUFFIX): $(C1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(C1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.debuginfo: $(C1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.debuginfo: $(C1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
|
||||
# Minimal1
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1), true)
|
||||
MISC_DIR=$(MINIMAL1_DIR)
|
||||
GEN_DIR=$(MINIMAL1_BASE_DIR)/generated
|
||||
endif
|
||||
|
||||
# Bin files (windows)
|
||||
ifeq ($(OSNAME),windows)
|
||||
|
||||
# Get jvm.lib
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(MISC_DIR)/%.lib
|
||||
# Common
|
||||
$(EXPORT_MINIMAL_DIR)/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
|
||||
# Other libraries (like SA)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.diz: $(MISC_DIR)/%.diz
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(MINIMAL1_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.dll: $(MISC_DIR)/%.dll
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(MINIMAL1_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.pdb: $(MISC_DIR)/%.pdb
|
||||
# Windows
|
||||
$(EXPORT_MINIMAL_DIR)/%.dll: $(MINIMAL1_DIR)/%.dll
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_BIN_DIR)/%.map: $(MISC_DIR)/%.map
|
||||
$(EXPORT_MINIMAL_DIR)/%.pdb: $(MINIMAL1_DIR)/%.pdb
|
||||
$(install-file)
|
||||
|
||||
# Client files always come from C1 area
|
||||
$(EXPORT_CLIENT_DIR)/%.diz: $(C1_DIR)/%.diz
|
||||
$(EXPORT_MINIMAL_DIR)/%.map: $(MINIMAL1_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.dll: $(C1_DIR)/%.dll
|
||||
$(EXPORT_LIB_DIR)/%.lib: $(MINIMAL1_DIR)/%.lib
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.pdb: $(C1_DIR)/%.pdb
|
||||
$(EXPORT_JRE_BIN_DIR)/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.map: $(C1_DIR)/%.map
|
||||
$(EXPORT_JRE_BIN_DIR)/%.dll: $(MINIMAL1_DIR)/%.dll
|
||||
$(install-file)
|
||||
|
||||
# Server files always come from C2 area
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(C2_DIR)/%.diz
|
||||
$(EXPORT_JRE_BIN_DIR)/%.pdb: $(MINIMAL1_DIR)/%.pdb
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.dll: $(C2_DIR)/%.dll
|
||||
$(EXPORT_JRE_BIN_DIR)/%.map: $(MINIMAL1_DIR)/%.map
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.pdb: $(C2_DIR)/%.pdb
|
||||
# Unix
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(MINIMAL1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.map: $(C2_DIR)/%.map
|
||||
$(EXPORT_MINIMAL_DIR)/%.$(LIBRARY_SUFFIX): $(MINIMAL1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.$(LIBRARY_SUFFIX): $(MINIMAL1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(MINIMAL1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.debuginfo: $(MINIMAL1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.debuginfo: $(MINIMAL1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
|
||||
# Minimal JVM files always come from minimal area
|
||||
$(EXPORT_MINIMAL_DIR)/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
# Zero
|
||||
ifeq ($(JVM_VARIANT_ZERO), true)
|
||||
# Common
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(ZERO_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.dll: $(MINIMAL1_DIR)/%.dll
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(ZERO_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.pdb: $(MINIMAL1_DIR)/%.pdb
|
||||
# Unix
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(ZERO_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.map: $(MINIMAL1_DIR)/%.map
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(ZERO_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(ZERO_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(ZERO_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(ZERO_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(ZERO_DIR)/%.diz
|
||||
$(install-file)
|
||||
|
||||
# Shared Library
|
||||
ifneq ($(OSNAME),windows)
|
||||
ifeq ($(JVM_VARIANT_SERVER), true)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(C2_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(C2_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.$(LIBRARY_SUFFIX): $(C2_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(C2_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(C2_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.debuginfo: $(C2_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/64/%.diz: $(C2_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_CLIENT), true)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(C1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.$(LIBRARY_SUFFIX): $(C1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.$(LIBRARY_SUFFIX): $(C1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(C1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.debuginfo: $(C1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.debuginfo: $(C1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_CLIENT_DIR)/64/%.diz: $(C1_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(SHARK_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo): $(SHARK_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(SHARK_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(SHARK_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(SHARK_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(SHARK_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_ZERO), true)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(ZERO_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(ZERO_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(ZERO_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(ZERO_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(ZERO_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(ZERO_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1), true)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(MINIMAL1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.$(LIBRARY_SUFFIX): $(MINIMAL1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.$(LIBRARY_SUFFIX): $(MINIMAL1_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo: $(MINIMAL1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.debuginfo: $(MINIMAL1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.debuginfo: $(MINIMAL1_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_MINIMAL_DIR)/64/%.diz: $(MINIMAL1_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
endif
|
||||
|
||||
# Jar file (sa-jdi.jar)
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(GEN_DIR)/%.jar
|
||||
# Shark
|
||||
ifeq ($(JVM_VARIANT_ZEROSHARK), true)
|
||||
# Common
|
||||
$(EXPORT_LIB_DIR)/%.jar: $(SHARK_DIR)/../generated/%.jar
|
||||
$(install-file)
|
||||
|
||||
# Include files (jvmti.h, jvmticmlr.h, jni.h, $(JDK_INCLUDE_SUBDIR)/jni_md.h, jmm.h, jfr.h)
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(GEN_DIR)/jvmtifiles/%
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(SHARK_DIR)/../generated/jvmtifiles/%
|
||||
$(install-file)
|
||||
# Unix
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.$(LIBRARY_SUFFIX): $(SHARK_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.debuginfo): $(SHARK_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_JRE_LIB_ARCH_DIR)/%.diz: $(SHARK_DIR)/%.diz
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.$(LIBRARY_SUFFIX): $(SHARK_DIR)/%.$(LIBRARY_SUFFIX)
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.debuginfo: $(SHARK_DIR)/%.debuginfo
|
||||
$(install-file)
|
||||
$(EXPORT_SERVER_DIR)/%.diz: $(SHARK_DIR)/%.diz
|
||||
$(install-file)
|
||||
endif
|
||||
|
||||
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/code/%
|
||||
$(install-file)
|
||||
@ -541,11 +546,11 @@ generic_test:
|
||||
@$(RUN_JVM) -XXaltjvm=$(ALTJVM_DIR) -showversion -help
|
||||
|
||||
# C2 test targets
|
||||
test_product test_optimized test_fastdebug test_jvmg:
|
||||
test_product test_optimized test_fastdebug test_debug:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(C2_DIR)/$(@:test_%=%)"
|
||||
|
||||
# C1 test targets
|
||||
test_product1 test_optimized1 test_fastdebug1 test_jvmg1:
|
||||
test_product1 test_optimized1 test_fastdebug1 test_debug1:
|
||||
ifeq ($(ARCH_DATA_MODEL), 32)
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(C1_DIR)/$(@:test_%1=%)"
|
||||
else
|
||||
@ -553,15 +558,15 @@ test_product1 test_optimized1 test_fastdebug1 test_jvmg1:
|
||||
endif
|
||||
|
||||
# Zero test targets
|
||||
test_productzero test_optimizedzero test_fastdebugzero test_jvmgzero:
|
||||
test_productzero test_optimizedzero test_fastdebugzero test_debugzero:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(ZERO_DIR)/$(@:test_%zero=%)"
|
||||
|
||||
# Shark test targets
|
||||
test_productshark test_optimizedshark test_fastdebugshark test_jvmgshark:
|
||||
test_productshark test_optimizedshark test_fastdebugshark test_debugshark:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(SHARK_DIR)/$(@:test_%shark=%)"
|
||||
|
||||
# Minimal1 test targets
|
||||
test_productminimal1 test_optimizedminimal1 test_fastdebugminimal1 test_jvmgminimal1:
|
||||
test_productminimal1 test_optimizedminimal1 test_fastdebugminimal1 test_debugminimal1:
|
||||
@$(MAKE) generic_test ALTJVM_DIR="$(MINIMAL1_DIR)/$(@:test_%minimal1=%)"
|
||||
|
||||
|
||||
@ -626,7 +631,7 @@ help: intro_help target_help variable_help notes_help examples_help
|
||||
# Intro help message
|
||||
intro_help:
|
||||
@$(ECHO) \
|
||||
"Makefile for the Hotspot workspace."
|
||||
"Makefile for the Hotspot workspace."
|
||||
@$(ECHO) \
|
||||
"Default behavior is to build and create an export area for the j2se builds."
|
||||
|
||||
@ -637,7 +642,7 @@ target_help:
|
||||
@$(ECHO) "world: Same as: all create_jdk"
|
||||
@$(ECHO) "all_product: Same as: product product1 export_product"
|
||||
@$(ECHO) "all_fastdebug: Same as: fastdebug fastdebug1 export_fastdebug"
|
||||
@$(ECHO) "all_debug: Same as: jvmg jvmg1 export_debug"
|
||||
@$(ECHO) "all_debug: Same as: debug debug1 export_debug"
|
||||
@$(ECHO) "all_optimized: Same as: optimized optimized1 export_optimized"
|
||||
@$(ECHO) "clean: Clean all areas"
|
||||
@$(ECHO) "export_product: Export product files to EXPORT_PATH"
|
||||
@ -730,7 +735,7 @@ examples_help:
|
||||
@$(ECHO) \
|
||||
" $(MAKE) world"
|
||||
@$(ECHO) \
|
||||
" $(MAKE) ALT_BOOTDIR=/opt/java/jdk$(PREVIOUS_JDK_VERSION)"
|
||||
" $(MAKE) ALT_BOOTDIR=/opt/java/jdk$(PREVIOUS_JDK_VERSION)"
|
||||
@$(ECHO) \
|
||||
" $(MAKE) ALT_JDK_IMPORT_PATH=/opt/java/jdk$(JDK_VERSION)"
|
||||
|
||||
@ -741,6 +746,23 @@ include $(GAMMADIR)/make/$(OSNAME)/makefiles/universal.gmk
|
||||
endif
|
||||
endif
|
||||
|
||||
# Compatibility for transition to new naming
|
||||
warn_jvmg_deprecated:
|
||||
echo "Warning: The jvmg target has been replaced with debug"
|
||||
echo "Warning: Please update your usage"
|
||||
|
||||
jvmg: warn_jvmg_deprecated debug
|
||||
|
||||
jvmg1: warn_jvmg_deprecated debug1
|
||||
|
||||
jvmgminimal1: warn_jvmg_deprecated debugminimal1
|
||||
|
||||
jvmgcore: warn_jvmg_deprecated debugcore
|
||||
|
||||
jvmgzero: warn_jvmg_deprecated debugzero
|
||||
|
||||
jvmgshark: warn_jvmg_deprecated debugshark
|
||||
|
||||
# JPRT rule to build this workspace
|
||||
include $(GAMMADIR)/make/jprt.gmk
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -142,55 +142,43 @@ VARIANTARCH = $(subst i386,i486,$(ZERO_LIBARCH))
|
||||
#
|
||||
# debug compiler2 <os>_<arch>_compiler2/debug
|
||||
# fastdebug compiler2 <os>_<arch>_compiler2/fastdebug
|
||||
# jvmg compiler2 <os>_<arch>_compiler2/jvmg
|
||||
# optimized compiler2 <os>_<arch>_compiler2/optimized
|
||||
# profiled compiler2 <os>_<arch>_compiler2/profiled
|
||||
# product compiler2 <os>_<arch>_compiler2/product
|
||||
#
|
||||
# debug1 compiler1 <os>_<arch>_compiler1/debug
|
||||
# fastdebug1 compiler1 <os>_<arch>_compiler1/fastdebug
|
||||
# jvmg1 compiler1 <os>_<arch>_compiler1/jvmg
|
||||
# optimized1 compiler1 <os>_<arch>_compiler1/optimized
|
||||
# profiled1 compiler1 <os>_<arch>_compiler1/profiled
|
||||
# product1 compiler1 <os>_<arch>_compiler1/product
|
||||
#
|
||||
# debugcore core <os>_<arch>_core/debug
|
||||
# fastdebugcore core <os>_<arch>_core/fastdebug
|
||||
# jvmgcore core <os>_<arch>_core/jvmg
|
||||
# optimizedcore core <os>_<arch>_core/optimized
|
||||
# profiledcore core <os>_<arch>_core/profiled
|
||||
# productcore core <os>_<arch>_core/product
|
||||
#
|
||||
# debugzero zero <os>_<arch>_zero/debug
|
||||
# fastdebugzero zero <os>_<arch>_zero/fastdebug
|
||||
# jvmgzero zero <os>_<arch>_zero/jvmg
|
||||
# optimizedzero zero <os>_<arch>_zero/optimized
|
||||
# profiledzero zero <os>_<arch>_zero/profiled
|
||||
# productzero zero <os>_<arch>_zero/product
|
||||
#
|
||||
# debugshark shark <os>_<arch>_shark/debug
|
||||
# fastdebugshark shark <os>_<arch>_shark/fastdebug
|
||||
# jvmgshark shark <os>_<arch>_shark/jvmg
|
||||
# optimizedshark shark <os>_<arch>_shark/optimized
|
||||
# profiledshark shark <os>_<arch>_shark/profiled
|
||||
# productshark shark <os>_<arch>_shark/product
|
||||
#
|
||||
# fastdebugminimal1 minimal1 <os>_<arch>_minimal1/fastdebug
|
||||
# jvmgminimal1 minimal1 <os>_<arch>_minimal1/jvmg
|
||||
# debugminimal1 minimal1 <os>_<arch>_minimal1/debug
|
||||
# productminimal1 minimal1 <os>_<arch>_minimal1/product
|
||||
#
|
||||
# What you get with each target:
|
||||
#
|
||||
# debug* - "thin" libjvm - debug info linked into the gamma launcher
|
||||
# debug* - debug compile with asserts enabled
|
||||
# fastdebug* - optimized compile, but with asserts enabled
|
||||
# jvmg* - "fat" libjvm - debug info linked into libjvm.so
|
||||
# optimized* - optimized compile, no asserts
|
||||
# profiled* - gprof
|
||||
# product* - the shippable thing: optimized compile, no asserts, -DPRODUCT
|
||||
|
||||
# This target list needs to be coordinated with the usage message
|
||||
# in the build.sh script:
|
||||
TARGETS = debug jvmg fastdebug optimized profiled product
|
||||
TARGETS = debug fastdebug optimized product
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
SUBDIR_DOCS = $(OSNAME)_$(VARIANTARCH)_docs
|
||||
@ -354,15 +342,29 @@ docs: checks
|
||||
$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) jvmtidocs
|
||||
|
||||
# Synonyms for win32-like targets.
|
||||
compiler2: jvmg product
|
||||
compiler2: debug product
|
||||
|
||||
compiler1: jvmg1 product1
|
||||
compiler1: debug1 product1
|
||||
|
||||
core: jvmgcore productcore
|
||||
core: debugcore productcore
|
||||
|
||||
zero: jvmgzero productzero
|
||||
zero: debugzero productzero
|
||||
|
||||
shark: jvmgshark productshark
|
||||
shark: debugshark productshark
|
||||
|
||||
warn_jvmg_deprecated:
|
||||
echo "Warning: The jvmg target has been replaced with debug"
|
||||
echo "Warning: Please update your usage"
|
||||
|
||||
jvmg: warn_jvmg_deprecated debug
|
||||
|
||||
jvmg1: warn_jvmg_deprecated debug1
|
||||
|
||||
jvmgcore: warn_jvmg_deprecated debugcore
|
||||
|
||||
jvmgzero: warn_jvmg_deprecated debugzero
|
||||
|
||||
jvmgshark: warn_jvmg_deprecated debugshark
|
||||
|
||||
clean_docs:
|
||||
rm -rf $(SUBDIR_DOCS)
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Usage:
|
||||
@ -46,11 +46,11 @@
|
||||
# Makefile - for "make foo"
|
||||
# flags.make - with macro settings
|
||||
# vm.make - to support making "$(MAKE) -v vm.make" in makefiles
|
||||
# adlc.make -
|
||||
# adlc.make -
|
||||
# jvmti.make - generate JVMTI bindings from the spec (JSR-163)
|
||||
# sa.make - generate SA jar file and natives
|
||||
# env.[ck]sh - environment settings
|
||||
#
|
||||
#
|
||||
# The makefiles are split this way so that "make foo" will run faster by not
|
||||
# having to read the dependency files for the vm.
|
||||
|
||||
@ -122,7 +122,7 @@ SIMPLE_DIRS = \
|
||||
$(PLATFORM_DIR)/generated/jvmtifiles \
|
||||
$(PLATFORM_DIR)/generated/dtracefiles
|
||||
|
||||
TARGETS = debug fastdebug jvmg optimized product profiled
|
||||
TARGETS = debug fastdebug optimized product
|
||||
SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
|
||||
|
||||
# For dependencies and recursive makes.
|
||||
@ -186,8 +186,8 @@ $(SIMPLE_DIRS):
|
||||
$(QUIETLY) mkdir -p $@
|
||||
|
||||
# Convenience macro which takes a source relative path, applies $(1) to the
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
gamma-path=$(subst $(GAMMADIR),\$$(GAMMADIR),$(call $(1),$(HS_COMMON_SRC)/$(2)))
|
||||
|
||||
# This bit is needed to enable local rebuilds.
|
||||
@ -279,8 +279,6 @@ flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
[ "$(TARGET)" = profiled ] && \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/optimized.make"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
|
||||
) > $@
|
||||
|
||||
@ -381,7 +379,7 @@ jdkpath.sh: $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo "JDK=${JAVA_HOME}"; \
|
||||
) > $@
|
||||
) > $@
|
||||
|
||||
FORCE:
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
@ -27,17 +27,16 @@
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
DEBUG_CFLAGS/DEFAULT= $(DEBUG_CFLAGS)
|
||||
DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@))
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE)
|
||||
|
||||
# _NMT_NOINLINE_ informs NMT that no inlining by Compiler
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE) -D_NMT_NOINLINE_
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
||||
|
||||
_JUNK_ := $(shell echo -e >&2 ""\
|
||||
"----------------------------------------------------------------------\n" \
|
||||
"WARNING: 'make debug' is deprecated. It will be removed in the future.\n" \
|
||||
"Please use 'make jvmg' to build debug JVM. \n" \
|
||||
"----------------------------------------------------------------------\n")
|
||||
|
||||
VERSION = debug
|
||||
SYSDEFS += -DASSERT -DDEBUG
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# The common definitions for hotspot bsd builds.
|
||||
@ -86,7 +86,7 @@ ifneq (,$(findstring $(ARCH), amd64 x86_64))
|
||||
VM_PLATFORM = bsd_i486
|
||||
HS_ARCH = x86
|
||||
# We have to reset ARCH to i386 since SRCARCH relies on it
|
||||
ARCH = i386
|
||||
ARCH = i386
|
||||
endif
|
||||
endif
|
||||
|
||||
@ -146,9 +146,6 @@ else
|
||||
LIBRARY_SUFFIX=so
|
||||
endif
|
||||
|
||||
# FIXUP: The subdirectory for a debug build is NOT the same on all platforms
|
||||
VM_DEBUG=jvmg
|
||||
|
||||
EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
|
||||
|
||||
# client and server subdirectories have symbolic links to ../libjsig.so
|
||||
@ -177,7 +174,7 @@ ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
else
|
||||
EXPORT_LIST += $(EXPORT_MINIMAL_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
# Serviceability Binaries
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012 Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
@ -59,5 +59,5 @@ CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
MAPFILE = $(GAMMADIR)/make/bsd/makefiles/mapfile-vers-debug
|
||||
|
||||
VERSION = optimized
|
||||
SYSDEFS += -DASSERT -DFASTDEBUG
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
||||
|
@ -187,7 +187,7 @@ Src_Dirs/ZERO := $(CORE_PATHS)
|
||||
Src_Dirs/SHARK := $(CORE_PATHS) $(SHARK_PATHS)
|
||||
Src_Dirs := $(Src_Dirs/$(TYPE))
|
||||
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp chaitin\* c2_\* runtime_\*
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp c2_\* runtime_\*
|
||||
COMPILER1_SPECIFIC_FILES := c1_\*
|
||||
SHARK_SPECIFIC_FILES := shark
|
||||
ZERO_SPECIFIC_FILES := zero
|
||||
|
@ -35,7 +35,7 @@ HOTSPOT_VM_COPYRIGHT=Copyright 2013
|
||||
|
||||
HS_MAJOR_VER=25
|
||||
HS_MINOR_VER=0
|
||||
HS_BUILD_NUMBER=27
|
||||
HS_BUILD_NUMBER=30
|
||||
|
||||
JDK_MAJOR_VER=1
|
||||
JDK_MINOR_VER=8
|
||||
|
@ -133,15 +133,15 @@ jprt.my.windows.x64=${jprt.my.windows.x64.${jprt.tools.default.release}}
|
||||
# Standard list of jprt build targets for this source tree
|
||||
|
||||
jprt.build.targets.standard= \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug|debug}, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug|debug}, \
|
||||
${jprt.my.solaris.i586}-{product|fastdebug|debug}, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug|debug}, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug|debug}, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}, \
|
||||
${jprt.my.solaris.i586}-{product|fastdebug}, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug|debug}, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug|debug}, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug|debug}, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}, \
|
||||
${jprt.my.linux.armvh}-{product|fastdebug}
|
||||
|
||||
jprt.build.targets.open= \
|
||||
@ -150,7 +150,7 @@ jprt.build.targets.open= \
|
||||
${jprt.my.linux.x64}-{productOpen}
|
||||
|
||||
jprt.build.targets.embedded= \
|
||||
${jprt.my.linux.i586}-{productEmb|fastdebugEmb|debugEmb}, \
|
||||
${jprt.my.linux.i586}-{productEmb|fastdebugEmb}, \
|
||||
${jprt.my.linux.ppc}-{productEmb|fastdebugEmb}, \
|
||||
${jprt.my.linux.ppcv2}-{productEmb|fastdebugEmb}, \
|
||||
${jprt.my.linux.ppcsflt}-{productEmb|fastdebugEmb}, \
|
||||
@ -174,21 +174,18 @@ jprt.my.solaris.sparc.test.targets= \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-scimark, \
|
||||
${jprt.my.solaris.sparc}-product-{c1|c2}-runThese, \
|
||||
${jprt.my.solaris.sparc}-fastdebug-c1-runThese_Xshare, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_default, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_SerialGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_ParallelGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_ParNewGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_CMS, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_G1, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCBasher_ParOldGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_default, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_SerialGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_ParallelGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_ParNewGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_CMS, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_G1, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-GCOld_ParOldGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-jbb_default, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-c2-jbb_default_nontiered, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-jbb_SerialGC, \
|
||||
${jprt.my.solaris.sparc}-{product|fastdebug}-{c1|c2}-jbb_ParallelGC, \
|
||||
@ -201,21 +198,18 @@ jprt.my.solaris.sparcv9.test.targets= \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-jvm98_nontiered, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-scimark, \
|
||||
${jprt.my.solaris.sparcv9}-product-c2-runThese, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_default, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_SerialGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_ParallelGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_ParNewGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_CMS, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_G1, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCBasher_ParOldGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_default, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_SerialGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_ParallelGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_ParNewGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_CMS, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_G1, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-GCOld_ParOldGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-jbb_default, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-jbb_default_nontiered, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-jbb_SerialGC, \
|
||||
${jprt.my.solaris.sparcv9}-{product|fastdebug}-c2-jbb_ParallelGC, \
|
||||
@ -229,21 +223,18 @@ jprt.my.solaris.x64.test.targets= \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-scimark, \
|
||||
${jprt.my.solaris.x64}-product-c2-runThese, \
|
||||
${jprt.my.solaris.x64}-product-c2-runThese_Xcomp, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_default, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_SerialGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_ParallelGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_ParNewGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_CMS, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_G1, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCBasher_ParOldGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_default, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_SerialGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_ParallelGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_ParNewGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_CMS, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_G1, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-GCOld_ParOldGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-jbb_default, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-jbb_default_nontiered, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-jbb_SerialGC, \
|
||||
${jprt.my.solaris.x64}-{product|fastdebug}-c2-jbb_ParallelGC, \
|
||||
@ -258,28 +249,24 @@ jprt.my.solaris.i586.test.targets= \
|
||||
${jprt.my.solaris.i586}-product-{c1|c2}-runThese_Xcomp, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c1-runThese_Xcomp, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c1-runThese_Xshare, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_default, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_SerialGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_ParallelGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_ParNewGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_CMS, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_G1, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCBasher_ParOldGC, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_default, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_SerialGC, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_ParallelGC, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_ParNewGC, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_CMS, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_G1, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-GCBasher_ParOldGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_default, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_SerialGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_ParallelGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_ParNewGC, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_CMS, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_G1, \
|
||||
${jprt.my.solaris.i586}-product-c1-GCOld_ParOldGC, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-jbb_default, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-jbb_default_nontiered, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-jbb_ParallelGC, \
|
||||
${jprt.my.solaris.i586}-fastdebug-c2-jbb_CMS, \
|
||||
@ -293,21 +280,19 @@ jprt.my.linux.i586.test.targets = \
|
||||
${jprt.my.linux.i586}-product-c1-runThese_Xcomp, \
|
||||
${jprt.my.linux.i586}-fastdebug-c1-runThese_Xshare, \
|
||||
${jprt.my.linux.i586}-fastdebug-c2-runThese_Xcomp, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_default, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_SerialGC, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_ParallelGC, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_ParNewGC, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_CMS, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_G1, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-{c1|c2}-GCBasher_ParOldGC, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_default, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_SerialGC, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_ParallelGC, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_ParNewGC, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_CMS, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_G1, \
|
||||
${jprt.my.linux.i586}-product-{c1|c2}-GCOld_ParOldGC, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-c1-jbb_default, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-c1-jbb_SerialGC, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-c2-jbb_default_nontiered, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-c1-jbb_ParallelGC, \
|
||||
${jprt.my.linux.i586}-{product|fastdebug}-c1-jbb_CMS, \
|
||||
@ -318,21 +303,18 @@ jprt.my.linux.x64.test.targets = \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-jvm98, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-jvm98_nontiered, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-scimark, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_default, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_SerialGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_ParallelGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_ParNewGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_CMS, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_G1, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCBasher_ParOldGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_default, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_SerialGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_ParallelGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_ParNewGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_CMS, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_G1, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-GCOld_ParOldGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-jbb_default, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-jbb_default_nontiered, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-jbb_ParallelGC, \
|
||||
${jprt.my.linux.x64}-{product|fastdebug}-c2-jbb_G1, \
|
||||
@ -342,21 +324,18 @@ jprt.my.macosx.x64.test.targets = \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-jvm98, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-jvm98_nontiered, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-scimark, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_default, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_SerialGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_ParallelGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_ParNewGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_CMS, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_G1, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCBasher_ParOldGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_default, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_SerialGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_ParallelGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_ParNewGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_CMS, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_G1, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-GCOld_ParOldGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-jbb_default, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-jbb_default_nontiered, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-jbb_ParallelGC, \
|
||||
${jprt.my.macosx.x64}-{product|fastdebug}-c2-jbb_G1, \
|
||||
@ -369,14 +348,12 @@ jprt.my.windows.i586.test.targets = \
|
||||
${jprt.my.windows.i586}-product-{c1|c2}-runThese, \
|
||||
${jprt.my.windows.i586}-product-{c1|c2}-runThese_Xcomp, \
|
||||
${jprt.my.windows.i586}-fastdebug-c1-runThese_Xshare, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_default, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_SerialGC, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_ParallelGC, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_ParNewGC, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_CMS, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_G1, \
|
||||
${jprt.my.windows.i586}-{product|fastdebug}-{c1|c2}-GCBasher_ParOldGC, \
|
||||
${jprt.my.windows.i586}-product-{c1|c2}-GCOld_default, \
|
||||
${jprt.my.windows.i586}-product-{c1|c2}-GCOld_SerialGC, \
|
||||
${jprt.my.windows.i586}-product-{c1|c2}-GCOld_ParallelGC, \
|
||||
${jprt.my.windows.i586}-product-{c1|c2}-GCOld_ParNewGC, \
|
||||
@ -396,14 +373,12 @@ jprt.my.windows.x64.test.targets = \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-scimark, \
|
||||
${jprt.my.windows.x64}-product-c2-runThese, \
|
||||
${jprt.my.windows.x64}-product-c2-runThese_Xcomp, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_default, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_SerialGC, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_ParallelGC, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_ParNewGC, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_CMS, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_G1, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCBasher_ParOldGC, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCOld_default, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCOld_SerialGC, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCOld_ParallelGC, \
|
||||
${jprt.my.windows.x64}-{product|fastdebug}-c2-GCOld_ParNewGC, \
|
||||
@ -419,7 +394,7 @@ jprt.my.windows.x64.test.targets = \
|
||||
|
||||
# Some basic "smoke" tests for OpenJDK builds
|
||||
jprt.test.targets.open = \
|
||||
${jprt.my.solaris.x64}-{productOpen|debugOpen|fastdebugOpen}-c2-jvm98, \
|
||||
${jprt.my.solaris.x64}-{productOpen|fastdebugOpen}-c2-jvm98, \
|
||||
${jprt.my.solaris.i586}-{productOpen|fastdebugOpen}-c2-jvm98, \
|
||||
${jprt.my.linux.x64}-{productOpen|fastdebugOpen}-c2-jvm98
|
||||
|
||||
@ -520,5 +495,5 @@ jprt.make.rule.test.targets.jdk7u8=${jprt.make.rule.test.targets.jdk7}
|
||||
jprt.make.rule.test.targets=${jprt.make.rule.test.targets.${jprt.tools.default.release}}
|
||||
|
||||
# 7155453: Work-around to prevent popups on OSX from blocking test completion
|
||||
# but the work-around is added to all platforms to be consistent
|
||||
# but the work-around is added to all platforms to be consistent
|
||||
jprt.jbb.options=-Djava.awt.headless=true
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -142,55 +142,42 @@ VARIANTARCH = $(subst i386,i486,$(ZERO_LIBARCH))
|
||||
#
|
||||
# debug compiler2 <os>_<arch>_compiler2/debug
|
||||
# fastdebug compiler2 <os>_<arch>_compiler2/fastdebug
|
||||
# jvmg compiler2 <os>_<arch>_compiler2/jvmg
|
||||
# optimized compiler2 <os>_<arch>_compiler2/optimized
|
||||
# profiled compiler2 <os>_<arch>_compiler2/profiled
|
||||
# product compiler2 <os>_<arch>_compiler2/product
|
||||
#
|
||||
# debug1 compiler1 <os>_<arch>_compiler1/debug
|
||||
# fastdebug1 compiler1 <os>_<arch>_compiler1/fastdebug
|
||||
# jvmg1 compiler1 <os>_<arch>_compiler1/jvmg
|
||||
# optimized1 compiler1 <os>_<arch>_compiler1/optimized
|
||||
# profiled1 compiler1 <os>_<arch>_compiler1/profiled
|
||||
# product1 compiler1 <os>_<arch>_compiler1/product
|
||||
#
|
||||
# debugcore core <os>_<arch>_core/debug
|
||||
# fastdebugcore core <os>_<arch>_core/fastdebug
|
||||
# jvmgcore core <os>_<arch>_core/jvmg
|
||||
# optimizedcore core <os>_<arch>_core/optimized
|
||||
# profiledcore core <os>_<arch>_core/profiled
|
||||
# productcore core <os>_<arch>_core/product
|
||||
#
|
||||
# debugzero zero <os>_<arch>_zero/debug
|
||||
# fastdebugzero zero <os>_<arch>_zero/fastdebug
|
||||
# jvmgzero zero <os>_<arch>_zero/jvmg
|
||||
# optimizedzero zero <os>_<arch>_zero/optimized
|
||||
# profiledzero zero <os>_<arch>_zero/profiled
|
||||
# productzero zero <os>_<arch>_zero/product
|
||||
#
|
||||
# debugshark shark <os>_<arch>_shark/debug
|
||||
# fastdebugshark shark <os>_<arch>_shark/fastdebug
|
||||
# jvmgshark shark <os>_<arch>_shark/jvmg
|
||||
# optimizedshark shark <os>_<arch>_shark/optimized
|
||||
# profiledshark shark <os>_<arch>_shark/profiled
|
||||
# productshark shark <os>_<arch>_shark/product
|
||||
#
|
||||
# fastdebugminimal1 minimal1 <os>_<arch>_minimal1/fastdebug
|
||||
# jvmgminimal1 minimal1 <os>_<arch>_minimal1/jvmg
|
||||
# productminimal1 minimal1 <os>_<arch>_minimal1/product
|
||||
#
|
||||
# What you get with each target:
|
||||
#
|
||||
# debug* - "thin" libjvm - debug info linked into the gamma launcher
|
||||
# debug* - debug compile with asserts enabled
|
||||
# fastdebug* - optimized compile, but with asserts enabled
|
||||
# jvmg* - "fat" libjvm - debug info linked into libjvm.so
|
||||
# optimized* - optimized compile, no asserts
|
||||
# profiled* - gprof
|
||||
# product* - the shippable thing: optimized compile, no asserts, -DPRODUCT
|
||||
|
||||
# This target list needs to be coordinated with the usage message
|
||||
# in the build.sh script:
|
||||
TARGETS = debug jvmg fastdebug optimized profiled product
|
||||
TARGETS = debug fastdebug optimized product
|
||||
|
||||
ifeq ($(findstring true, $(JVM_VARIANT_ZERO) $(JVM_VARIANT_ZEROSHARK)), true)
|
||||
SUBDIR_DOCS = $(OSNAME)_$(VARIANTARCH)_docs
|
||||
@ -357,15 +344,29 @@ docs: checks
|
||||
$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
|
||||
|
||||
# Synonyms for win32-like targets.
|
||||
compiler2: jvmg product
|
||||
compiler2: debug product
|
||||
|
||||
compiler1: jvmg1 product1
|
||||
compiler1: debug1 product1
|
||||
|
||||
core: jvmgcore productcore
|
||||
core: debugcore productcore
|
||||
|
||||
zero: jvmgzero productzero
|
||||
zero: debugzero productzero
|
||||
|
||||
shark: jvmgshark productshark
|
||||
shark: debugshark productshark
|
||||
|
||||
warn_jvmg_deprecated:
|
||||
echo "Warning: The jvmg target has been replaced with debug"
|
||||
echo "Warning: Please update your usage"
|
||||
|
||||
jvmg: warn_jvmg_deprecated debug
|
||||
|
||||
jvmg1: warn_jvmg_deprecated debug1
|
||||
|
||||
jvmgcore: warn_jvmg_deprecated debugcore
|
||||
|
||||
jvmgzero: warn_jvmg_deprecated debugzero
|
||||
|
||||
jvmgshark: warn_jvmg_deprecated debugshark
|
||||
|
||||
clean_docs:
|
||||
rm -rf $(SUBDIR_DOCS)
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Usage:
|
||||
@ -46,11 +46,11 @@
|
||||
# Makefile - for "make foo"
|
||||
# flags.make - with macro settings
|
||||
# vm.make - to support making "$(MAKE) -v vm.make" in makefiles
|
||||
# adlc.make -
|
||||
# adlc.make -
|
||||
# jvmti.make - generate JVMTI bindings from the spec (JSR-163)
|
||||
# sa.make - generate SA jar file and natives
|
||||
# env.[ck]sh - environment settings
|
||||
#
|
||||
#
|
||||
# The makefiles are split this way so that "make foo" will run faster by not
|
||||
# having to read the dependency files for the vm.
|
||||
|
||||
@ -117,7 +117,7 @@ SIMPLE_DIRS = \
|
||||
$(PLATFORM_DIR)/generated/adfiles \
|
||||
$(PLATFORM_DIR)/generated/jvmtifiles
|
||||
|
||||
TARGETS = debug fastdebug jvmg optimized product profiled
|
||||
TARGETS = debug fastdebug optimized product
|
||||
SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
|
||||
|
||||
# For dependencies and recursive makes.
|
||||
@ -179,8 +179,8 @@ $(SIMPLE_DIRS):
|
||||
$(QUIETLY) mkdir -p $@
|
||||
|
||||
# Convenience macro which takes a source relative path, applies $(1) to the
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
gamma-path=$(subst $(GAMMADIR),\$$(GAMMADIR),$(call $(1),$(HS_COMMON_SRC)/$(2)))
|
||||
|
||||
# This bit is needed to enable local rebuilds.
|
||||
@ -284,8 +284,6 @@ flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
[ "$(TARGET)" = profiled ] && \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/optimized.make"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
|
||||
) > $@
|
||||
|
||||
@ -376,7 +374,7 @@ jdkpath.sh: $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo "JDK=${JAVA_HOME}"; \
|
||||
) > $@
|
||||
) > $@
|
||||
|
||||
FORCE:
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
@ -27,17 +27,16 @@
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
DEBUG_CFLAGS/DEFAULT= $(DEBUG_CFLAGS)
|
||||
DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@))
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE)
|
||||
|
||||
# _NMT_NOINLINE_ informs NMT that no inlining by Compiler
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE) -D_NMT_NOINLINE_
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfile
|
||||
MAPFILE = $(GAMMADIR)/make/linux/makefiles/mapfile-vers-debug
|
||||
|
||||
_JUNK_ := $(shell echo -e >&2 ""\
|
||||
"----------------------------------------------------------------------\n" \
|
||||
"WARNING: 'make debug' is deprecated. It will be removed in the future.\n" \
|
||||
"Please use 'make jvmg' to build debug JVM. \n" \
|
||||
"----------------------------------------------------------------------\n")
|
||||
|
||||
VERSION = debug
|
||||
SYSDEFS += -DASSERT -DDEBUG
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# The common definitions for hotspot linux builds.
|
||||
@ -92,7 +92,7 @@ ifneq (,$(findstring $(ARCH), amd64 x86_64))
|
||||
VM_PLATFORM = linux_i486
|
||||
HS_ARCH = x86
|
||||
# We have to reset ARCH to i686 since SRCARCH relies on it
|
||||
ARCH = i686
|
||||
ARCH = i686
|
||||
endif
|
||||
endif
|
||||
|
||||
@ -240,9 +240,6 @@ JDK_INCLUDE_SUBDIR=linux
|
||||
# Library suffix
|
||||
LIBRARY_SUFFIX=so
|
||||
|
||||
# FIXUP: The subdirectory for a debug build is NOT the same on all platforms
|
||||
VM_DEBUG=jvmg
|
||||
|
||||
EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
|
||||
|
||||
# client and server subdirectories have symbolic links to ../libjsig.so
|
||||
@ -279,7 +276,7 @@ ifeq ($(JVM_VARIANT_CLIENT),true)
|
||||
else
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
@ -292,15 +289,15 @@ ifeq ($(JVM_VARIANT_MINIMAL1),true)
|
||||
else
|
||||
EXPORT_LIST += $(EXPORT_MINIMAL_DIR)/libjvm.debuginfo
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
# Serviceability Binaries
|
||||
# No SA Support for PPC, IA64, ARM or zero
|
||||
ADD_SA_BINARIES/x86 = $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.$(LIBRARY_SUFFIX) \
|
||||
$(EXPORT_LIB_DIR)/sa-jdi.jar
|
||||
$(EXPORT_LIB_DIR)/sa-jdi.jar
|
||||
ADD_SA_BINARIES/sparc = $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.$(LIBRARY_SUFFIX) \
|
||||
$(EXPORT_LIB_DIR)/sa-jdi.jar
|
||||
$(EXPORT_LIB_DIR)/sa-jdi.jar
|
||||
ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ifeq ($(ZIP_DEBUGINFO_FILES),1)
|
||||
ADD_SA_BINARIES/x86 += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.diz
|
||||
@ -310,10 +307,10 @@ ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
ADD_SA_BINARIES/sparc += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.debuginfo
|
||||
endif
|
||||
endif
|
||||
ADD_SA_BINARIES/ppc =
|
||||
ADD_SA_BINARIES/ia64 =
|
||||
ADD_SA_BINARIES/arm =
|
||||
ADD_SA_BINARIES/zero =
|
||||
ADD_SA_BINARIES/ppc =
|
||||
ADD_SA_BINARIES/ia64 =
|
||||
ADD_SA_BINARIES/arm =
|
||||
ADD_SA_BINARIES/zero =
|
||||
|
||||
-include $(HS_ALT_MAKE)/linux/makefiles/defs.make
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
@ -59,5 +59,5 @@ CFLAGS$(HOTSPARC_GENERIC) += $(OPT_CFLAGS/BYFILE)
|
||||
MAPFILE = $(GAMMADIR)/make/linux/makefiles/mapfile-vers-debug
|
||||
|
||||
VERSION = optimized
|
||||
SYSDEFS += -DASSERT -DFASTDEBUG
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
||||
|
@ -126,14 +126,12 @@ endif
|
||||
# Compiler warnings are treated as errors
|
||||
WARNINGS_ARE_ERRORS = -Werror
|
||||
|
||||
# Except for a few acceptable ones
|
||||
WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef -Wunused-function
|
||||
|
||||
# Since GCC 4.3, -Wconversion has changed its meanings to warn these implicit
|
||||
# conversions which might affect the values. To avoid that, we need to turn
|
||||
# it off explicitly.
|
||||
ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
|
||||
WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef
|
||||
else
|
||||
WARNING_FLAGS = -Wpointer-arith -Wconversion -Wsign-compare -Wundef
|
||||
# conversions which might affect the values. Only enable it in earlier versions.
|
||||
ifeq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
|
||||
WARNING_FLAGS += -Wconversion
|
||||
endif
|
||||
|
||||
CFLAGS_WARN/DEFAULT = $(WARNINGS_ARE_ERRORS) $(WARNING_FLAGS)
|
||||
|
@ -189,7 +189,7 @@ Src_Dirs/ZERO := $(CORE_PATHS)
|
||||
Src_Dirs/SHARK := $(CORE_PATHS) $(SHARK_PATHS)
|
||||
Src_Dirs := $(Src_Dirs/$(TYPE))
|
||||
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp chaitin\* c2_\* runtime_\*
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp c2_\* runtime_\*
|
||||
COMPILER1_SPECIFIC_FILES := c1_\*
|
||||
SHARK_SPECIFIC_FILES := shark
|
||||
ZERO_SPECIFIC_FILES := zero
|
||||
|
@ -120,37 +120,29 @@ endif
|
||||
#
|
||||
# debug compiler2 <os>_<arch>_compiler2/debug
|
||||
# fastdebug compiler2 <os>_<arch>_compiler2/fastdebug
|
||||
# jvmg compiler2 <os>_<arch>_compiler2/jvmg
|
||||
# optimized compiler2 <os>_<arch>_compiler2/optimized
|
||||
# profiled compiler2 <os>_<arch>_compiler2/profiled
|
||||
# product compiler2 <os>_<arch>_compiler2/product
|
||||
#
|
||||
# debug1 compiler1 <os>_<arch>_compiler1/debug
|
||||
# fastdebug1 compiler1 <os>_<arch>_compiler1/fastdebug
|
||||
# jvmg1 compiler1 <os>_<arch>_compiler1/jvmg
|
||||
# optimized1 compiler1 <os>_<arch>_compiler1/optimized
|
||||
# profiled1 compiler1 <os>_<arch>_compiler1/profiled
|
||||
# product1 compiler1 <os>_<arch>_compiler1/product
|
||||
#
|
||||
# debugcore core <os>_<arch>_core/debug
|
||||
# fastdebugcore core <os>_<arch>_core/fastdebug
|
||||
# jvmgcore core <os>_<arch>_core/jvmg
|
||||
# optimizedcore core <os>_<arch>_core/optimized
|
||||
# profiledcore core <os>_<arch>_core/profiled
|
||||
# productcore core <os>_<arch>_core/product
|
||||
#
|
||||
# What you get with each target:
|
||||
#
|
||||
# debug* - "thin" libjvm - debug info linked into the gamma launcher
|
||||
# debug* - debug compile with asserts enabled
|
||||
# fastdebug* - optimized compile, but with asserts enabled
|
||||
# jvmg* - "fat" libjvm - debug info linked into libjvm.so
|
||||
# optimized* - optimized compile, no asserts
|
||||
# profiled* - gprof
|
||||
# product* - the shippable thing: optimized compile, no asserts, -DPRODUCT
|
||||
|
||||
# This target list needs to be coordinated with the usage message
|
||||
# in the build.sh script:
|
||||
TARGETS = debug jvmg fastdebug optimized profiled product
|
||||
TARGETS = debug fastdebug optimized product
|
||||
|
||||
SUBDIR_DOCS = $(OSNAME)_$(BUILDARCH)_docs
|
||||
SUBDIRS_C1 = $(addprefix $(OSNAME)_$(BUILDARCH)_compiler1/,$(TARGETS))
|
||||
@ -267,11 +259,21 @@ docs: checks
|
||||
$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
|
||||
|
||||
# Synonyms for win32-like targets.
|
||||
compiler2: jvmg product
|
||||
compiler2: debug product
|
||||
|
||||
compiler1: jvmg1 product1
|
||||
compiler1: debug1 product1
|
||||
|
||||
core: jvmgcore productcore
|
||||
core: debugcore productcore
|
||||
|
||||
warn_jvmg_deprecated:
|
||||
echo "Warning: The jvmg target has been replaced with debug"
|
||||
echo "Warning: Please update your usage"
|
||||
|
||||
jvmg: warn_jvmg_deprecated debug
|
||||
|
||||
jvmg1: warn_jvmg_deprecated debug1
|
||||
|
||||
jvmgcore: warn_jvmg_deprecated debugcore
|
||||
|
||||
clean_docs:
|
||||
rm -rf $(SUBDIR_DOCS)
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Usage:
|
||||
@ -46,11 +46,11 @@
|
||||
# Makefile - for "make foo"
|
||||
# flags.make - with macro settings
|
||||
# vm.make - to support making "$(MAKE) -v vm.make" in makefiles
|
||||
# adlc.make -
|
||||
# adlc.make -
|
||||
# jvmti.make - generate JVMTI bindings from the spec (JSR-163)
|
||||
# sa.make - generate SA jar file and natives
|
||||
# env.[ck]sh - environment settings
|
||||
#
|
||||
#
|
||||
# The makefiles are split this way so that "make foo" will run faster by not
|
||||
# having to read the dependency files for the vm.
|
||||
|
||||
@ -69,7 +69,7 @@ PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH).gcc
|
||||
GCC_LIB = /usr/local/lib
|
||||
else
|
||||
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH)
|
||||
GCC_LIB =
|
||||
GCC_LIB =
|
||||
endif
|
||||
|
||||
ifdef FORCE_TIERED
|
||||
@ -110,7 +110,7 @@ SIMPLE_DIRS = \
|
||||
$(PLATFORM_DIR)/generated/adfiles \
|
||||
$(PLATFORM_DIR)/generated/jvmtifiles
|
||||
|
||||
TARGETS = debug fastdebug jvmg optimized product profiled
|
||||
TARGETS = debug fastdebug optimized product
|
||||
SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS))
|
||||
|
||||
# For dependencies and recursive makes.
|
||||
@ -153,7 +153,7 @@ ifndef OPENJDK
|
||||
endif
|
||||
endif
|
||||
|
||||
BUILDTREE_VARS += HOTSPOT_RELEASE_VERSION=$(HS_BUILD_VER) HOTSPOT_BUILD_VERSION= JRE_RELEASE_VERSION=$(JRE_RELEASE_VERSION)
|
||||
BUILDTREE_VARS += HOTSPOT_RELEASE_VERSION=$(HS_BUILD_VER) HOTSPOT_BUILD_VERSION= JRE_RELEASE_VERSION=$(JRE_RELEASE_VERSION)
|
||||
|
||||
BUILDTREE = \
|
||||
$(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_TARGETS) $(BUILDTREE_VARS)
|
||||
@ -172,8 +172,8 @@ $(SIMPLE_DIRS):
|
||||
$(QUIETLY) mkdir -p $@
|
||||
|
||||
# Convenience macro which takes a source relative path, applies $(1) to the
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
# absolute path, and then replaces $(GAMMADIR) in the result with a
|
||||
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile.
|
||||
gamma-path=$(subst $(GAMMADIR),\$$(GAMMADIR),$(call $(1),$(HS_COMMON_SRC)/$(2)))
|
||||
|
||||
# This bit is needed to enable local rebuilds.
|
||||
@ -274,8 +274,6 @@ flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo; \
|
||||
[ "$(TARGET)" = profiled ] && \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/optimized.make"; \
|
||||
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \
|
||||
) > $@
|
||||
|
||||
@ -366,7 +364,7 @@ jdkpath.sh: $(BUILDTREE_MAKE)
|
||||
$(QUIETLY) ( \
|
||||
$(BUILDTREE_COMMENT); \
|
||||
echo "JDK=${JAVA_HOME}"; \
|
||||
) > $@
|
||||
) > $@
|
||||
|
||||
FORCE:
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
@ -37,22 +37,20 @@ ifeq ($(COMPILER_REV_NUMERIC),508)
|
||||
endif
|
||||
endif
|
||||
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE)
|
||||
# _NMT_NOINLINE_ informs NMT that no inlining by Compiler
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE) -D_NMT_NOINLINE_
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfiles
|
||||
MAPFILE = $(GAMMADIR)/make/solaris/makefiles/mapfile-vers \
|
||||
$(GAMMADIR)/make/solaris/makefiles/mapfile-vers-debug
|
||||
|
||||
# This mapfile is only needed when compiling with dtrace support,
|
||||
# This mapfile is only needed when compiling with dtrace support,
|
||||
# and mustn't be otherwise.
|
||||
MAPFILE_DTRACE = $(GAMMADIR)/make/solaris/makefiles/mapfile-vers-$(TYPE)
|
||||
|
||||
_JUNK_ := $(shell echo >&2 ""\
|
||||
"-------------------------------------------------------------------------\n" \
|
||||
"WARNING: 'gnumake debug' is deprecated. It will be removed in the future.\n" \
|
||||
"Please use 'gnumake jvmg' to build debug JVM. \n" \
|
||||
"-------------------------------------------------------------------------\n")
|
||||
|
||||
VERSION = debug
|
||||
SYSDEFS += -DASSERT -DDEBUG
|
||||
SYSDEFS += -DASSERT
|
||||
PICFLAGS = DEFAULT
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 2006, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2006, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# The common definitions for hotspot solaris builds.
|
||||
@ -172,9 +172,6 @@ JDK_INCLUDE_SUBDIR=solaris
|
||||
# Library suffix
|
||||
LIBRARY_SUFFIX=so
|
||||
|
||||
# FIXUP: The subdirectory for a debug build is NOT the same on all platforms
|
||||
VM_DEBUG=jvmg
|
||||
|
||||
EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
|
||||
|
||||
# client and server subdirectories have symbolic links to ../libjsig.$(LIBRARY_SUFFIX)
|
||||
@ -221,8 +218,8 @@ ifeq ($(JVM_VARIANT_SERVER),true)
|
||||
endif
|
||||
ifeq ($(JVM_VARIANT_CLIENT),true)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/Xusage.txt
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm_db.$(LIBRARY_SUFFIX)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm.$(LIBRARY_SUFFIX)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm_db.$(LIBRARY_SUFFIX)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/libjvm_dtrace.$(LIBRARY_SUFFIX)
|
||||
ifeq ($(ARCH_DATA_MODEL),32)
|
||||
EXPORT_LIST += $(EXPORT_CLIENT_DIR)/64/libjvm_db.$(LIBRARY_SUFFIX)
|
||||
@ -257,4 +254,4 @@ ifeq ($(ENABLE_FULL_DEBUG_SYMBOLS),1)
|
||||
EXPORT_LIST += $(EXPORT_JRE_LIB_ARCH_DIR)/libsaproc.debuginfo
|
||||
endif
|
||||
endif
|
||||
EXPORT_LIST += $(EXPORT_LIB_DIR)/sa-jdi.jar
|
||||
EXPORT_LIST += $(EXPORT_LIB_DIR)/sa-jdi.jar
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
@ -118,10 +118,10 @@ CFLAGS += $(DEBUG_CFLAGS/BYFILE)
|
||||
MAPFILE = $(GAMMADIR)/make/solaris/makefiles/mapfile-vers \
|
||||
$(GAMMADIR)/make/solaris/makefiles/mapfile-vers-debug
|
||||
|
||||
# This mapfile is only needed when compiling with dtrace support,
|
||||
# This mapfile is only needed when compiling with dtrace support,
|
||||
# and mustn't be otherwise.
|
||||
MAPFILE_DTRACE = $(GAMMADIR)/make/solaris/makefiles/mapfile-vers-$(TYPE)
|
||||
|
||||
VERSION = optimized
|
||||
SYSDEFS += -DASSERT -DFASTDEBUG -DCHECK_UNHANDLED_OOPS
|
||||
SYSDEFS += -DASSERT -DCHECK_UNHANDLED_OOPS
|
||||
PICFLAGS = DEFAULT
|
||||
|
@ -1,56 +0,0 @@
|
||||
#
|
||||
# Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
# under the terms of the GNU General Public License version 2 only, as
|
||||
# published by the Free Software Foundation.
|
||||
#
|
||||
# This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
# version 2 for more details (a copy is included in the LICENSE file that
|
||||
# accompanied this code).
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License version
|
||||
# 2 along with this work; if not, write to the Free Software Foundation,
|
||||
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
#
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
|
||||
# Sets make macros for making debug version of VM
|
||||
|
||||
# Compiler specific DEBUG_CFLAGS are passed in from gcc.make, sparcWorks.make
|
||||
DEBUG_CFLAGS/DEFAULT= $(DEBUG_CFLAGS)
|
||||
DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@))
|
||||
|
||||
ifeq ("${Platform_compiler}", "sparcWorks")
|
||||
|
||||
ifeq ($(COMPILER_REV_NUMERIC),508)
|
||||
# SS11 SEGV when compiling with -g and -xarch=v8, using different backend
|
||||
DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0
|
||||
DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0
|
||||
endif
|
||||
endif
|
||||
|
||||
# _NMT_NOINLINE_ informs NMT that no inlining by Compiler
|
||||
CFLAGS += $(DEBUG_CFLAGS/BYFILE) -D_NMT_NOINLINE_
|
||||
|
||||
# Set the environment variable HOTSPARC_GENERIC to "true"
|
||||
# to inhibit the effect of the previous line on CFLAGS.
|
||||
|
||||
# Linker mapfiles
|
||||
MAPFILE = $(GAMMADIR)/make/solaris/makefiles/mapfile-vers \
|
||||
$(GAMMADIR)/make/solaris/makefiles/mapfile-vers-debug
|
||||
|
||||
# This mapfile is only needed when compiling with dtrace support,
|
||||
# and mustn't be otherwise.
|
||||
MAPFILE_DTRACE = $(GAMMADIR)/make/solaris/makefiles/mapfile-vers-$(TYPE)
|
||||
|
||||
VERSION = debug
|
||||
SYSDEFS += -DASSERT -DDEBUG
|
||||
PICFLAGS = DEFAULT
|
@ -202,7 +202,7 @@ Src_Dirs/ZERO := $(CORE_PATHS)
|
||||
Src_Dirs/SHARK := $(CORE_PATHS)
|
||||
Src_Dirs := $(Src_Dirs/$(TYPE))
|
||||
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp chaitin\* c2_\* runtime_\*
|
||||
COMPILER2_SPECIFIC_FILES := opto libadt bcEscapeAnalyzer.cpp c2_\* runtime_\*
|
||||
COMPILER1_SPECIFIC_FILES := c1_\*
|
||||
SHARK_SPECIFIC_FILES := shark
|
||||
ZERO_SPECIFIC_FILES := zero
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -235,18 +235,14 @@ product release optimized: checks $(variantDir) $(variantDir)\local.make sanity
|
||||
cd $(variantDir)
|
||||
nmake -nologo -f $(WorkSpace)\make\windows\makefiles\top.make BUILD_FLAVOR=product ARCH=$(ARCH)
|
||||
|
||||
# The debug or jvmg (all the same thing) is an optional build
|
||||
debug jvmg: checks $(variantDir) $(variantDir)\local.make sanity
|
||||
# The debug build is an optional build
|
||||
debug: checks $(variantDir) $(variantDir)\local.make sanity
|
||||
cd $(variantDir)
|
||||
nmake -nologo -f $(WorkSpace)\make\windows\makefiles\top.make BUILD_FLAVOR=debug ARCH=$(ARCH)
|
||||
fastdebug: checks $(variantDir) $(variantDir)\local.make sanity
|
||||
cd $(variantDir)
|
||||
nmake -nologo -f $(WorkSpace)\make\windows\makefiles\top.make BUILD_FLAVOR=fastdebug ARCH=$(ARCH)
|
||||
|
||||
develop: checks $(variantDir) $(variantDir)\local.make sanity
|
||||
cd $(variantDir)
|
||||
nmake -nologo -f $(WorkSpace)\make\windows\makefiles\top.make BUILD_FLAVOR=product DEVELOP=1 ARCH=$(ARCH)
|
||||
|
||||
# target to create just the directory structure
|
||||
tree: checks $(variantDir) $(variantDir)\local.make sanity
|
||||
mkdir $(variantDir)\product
|
||||
|
@ -114,7 +114,7 @@ case "${TYPE}" in
|
||||
"shark") Src_Dirs="${CORE_PATHS}" ;;
|
||||
esac
|
||||
|
||||
COMPILER2_SPECIFIC_FILES="opto libadt bcEscapeAnalyzer.cpp chaitin* c2_* runtime_*"
|
||||
COMPILER2_SPECIFIC_FILES="opto libadt bcEscapeAnalyzer.cpp c2_* runtime_*"
|
||||
COMPILER1_SPECIFIC_FILES="c1_*"
|
||||
SHARK_SPECIFIC_FILES="shark"
|
||||
ZERO_SPECIFIC_FILES="zero"
|
||||
|
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# The common definitions for hotspot windows builds.
|
||||
@ -209,8 +209,6 @@ endif
|
||||
ifneq (,$(findstring MINGW,$(SYSTEM_UNAME)))
|
||||
USING_MINGW=true
|
||||
endif
|
||||
# FIXUP: The subdirectory for a debug build is NOT the same on all platforms
|
||||
VM_DEBUG=debug
|
||||
|
||||
# Windows wants particular paths due to nmake (must be after macros defined)
|
||||
# It is important that gnumake invokes nmake with C:\\...\\ formated
|
||||
@ -292,7 +290,7 @@ ifeq ($(BUILD_WIN_SA), 1)
|
||||
MAKE_ARGS += BUILD_WIN_SA=1
|
||||
endif
|
||||
|
||||
# Propagate compiler and tools paths from configure to nmake.
|
||||
# Propagate compiler and tools paths from configure to nmake.
|
||||
# Need to make sure they contain \\ and not /.
|
||||
ifneq ($(SPEC),)
|
||||
ifeq ($(USING_CYGWIN), true)
|
||||
|
@ -31,11 +31,7 @@ COMMONSRC=$(WorkSpace)\src
|
||||
ALTSRC=$(WorkSpace)\src\closed
|
||||
|
||||
!ifdef RELEASE
|
||||
!ifdef DEVELOP
|
||||
CXX_FLAGS=$(CXX_FLAGS) /D "DEBUG"
|
||||
!else
|
||||
CXX_FLAGS=$(CXX_FLAGS) /D "PRODUCT"
|
||||
!endif
|
||||
!else
|
||||
CXX_FLAGS=$(CXX_FLAGS) /D "ASSERT"
|
||||
!endif
|
||||
@ -186,7 +182,7 @@ VM_PATH={$(VM_PATH)}
|
||||
|
||||
# Special case files not using precompiled header files.
|
||||
|
||||
c1_RInfo_$(Platform_arch).obj: $(WorkSpace)\src\cpu\$(Platform_arch)\vm\c1_RInfo_$(Platform_arch).cpp
|
||||
c1_RInfo_$(Platform_arch).obj: $(WorkSpace)\src\cpu\$(Platform_arch)\vm\c1_RInfo_$(Platform_arch).cpp
|
||||
$(CXX) $(CXX_FLAGS) $(CXX_DONT_USE_PCH) /c $(WorkSpace)\src\cpu\$(Platform_arch)\vm\c1_RInfo_$(Platform_arch).cpp
|
||||
|
||||
os_windows.obj: $(WorkSpace)\src\os\windows\vm\os_windows.cpp
|
||||
|
@ -67,7 +67,7 @@ LINK32=link.exe
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
|
||||
# ADD CPP /nologo /ML /W3 /WX /Gm /GX /Zi /Od /I "." /I "$(HotSpotWorkSpace)\src\share\vm\opto" /I "$(HotSpotWorkSpace)\src\share\vm\prims" /I "$(HotSpotWorkSpace)\src\share\vm\lookup" /I "$(HotSpotWorkSpace)\src\share\vm\interpreter" /I "$(HotSpotWorkSpace)\src\share\vm\asm" /I "$(HotSpotWorkSpace)\src\share\vm\compiler" /I "$(HotSpotWorkSpace)\src\share\vm\utilities" /I "$(HotSpotWorkSpace)\src\share\vm\code" /I "$(HotSpotWorkSpace)\src\share\vm\oops" /I "$(HotSpotWorkSpace)\src\share\vm\runtime" /I "$(HotSpotWorkSpace)\src\share\vm\memory" /I "$(HotSpotWorkSpace)\src\share\vm\libadt" /I "$(HotSpotWorkSpace)\src\cpu\i486\vm" /I "$(HotSpotWorkSpace)\src\os\win32\vm" /D "WIN32" /D "DEBUG" /D "_WINDOWS" /D "ASSERT" /Fr /FD /c
|
||||
# ADD CPP /nologo /ML /W3 /WX /Gm /GX /Zi /Od /I "." /I "$(HotSpotWorkSpace)\src\share\vm\opto" /I "$(HotSpotWorkSpace)\src\share\vm\prims" /I "$(HotSpotWorkSpace)\src\share\vm\lookup" /I "$(HotSpotWorkSpace)\src\share\vm\interpreter" /I "$(HotSpotWorkSpace)\src\share\vm\asm" /I "$(HotSpotWorkSpace)\src\share\vm\compiler" /I "$(HotSpotWorkSpace)\src\share\vm\utilities" /I "$(HotSpotWorkSpace)\src\share\vm\code" /I "$(HotSpotWorkSpace)\src\share\vm\oops" /I "$(HotSpotWorkSpace)\src\share\vm\runtime" /I "$(HotSpotWorkSpace)\src\share\vm\memory" /I "$(HotSpotWorkSpace)\src\share\vm\libadt" /I "$(HotSpotWorkSpace)\src\cpu\i486\vm" /I "$(HotSpotWorkSpace)\src\os\win32\vm" /D "WIN32" /D "_WINDOWS" /D "ASSERT" /Fr /FD /c
|
||||
# ADD BASE RSC /l 0x409
|
||||
# ADD RSC /l 0x409
|
||||
BSC32=bscmake.exe
|
||||
|
@ -67,7 +67,7 @@ LINK32=link.exe
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
|
||||
# ADD CPP /nologo /ML /W3 /WX /Gm /GX /Zi /Od /I "." /I "$(HotSpotWorkSpace)\src\share\vm\opto" /I "$(HotSpotWorkSpace)\src\share\vm\prims" /I "$(HotSpotWorkSpace)\src\share\vm\lookup" /I "$(HotSpotWorkSpace)\src\share\vm\interpreter" /I "$(HotSpotWorkSpace)\src\share\vm\asm" /I "$(HotSpotWorkSpace)\src\share\vm\compiler" /I "$(HotSpotWorkSpace)\src\share\vm\utilities" /I "$(HotSpotWorkSpace)\src\share\vm\code" /I "$(HotSpotWorkSpace)\src\share\vm\oops" /I "$(HotSpotWorkSpace)\src\share\vm\runtime" /I "$(HotSpotWorkSpace)\src\share\vm\memory" /I "$(HotSpotWorkSpace)\src\share\vm\libadt" /I "$(HotSpotWorkSpace)\src\cpu\i486\vm" /I "$(HotSpotWorkSpace)\src\os\win32\vm" /D "WIN32" /D "DEBUG" /D "_WINDOWS" /D "ASSERT" /Fr /FD /c
|
||||
# ADD CPP /nologo /ML /W3 /WX /Gm /GX /Zi /Od /I "." /I "$(HotSpotWorkSpace)\src\share\vm\opto" /I "$(HotSpotWorkSpace)\src\share\vm\prims" /I "$(HotSpotWorkSpace)\src\share\vm\lookup" /I "$(HotSpotWorkSpace)\src\share\vm\interpreter" /I "$(HotSpotWorkSpace)\src\share\vm\asm" /I "$(HotSpotWorkSpace)\src\share\vm\compiler" /I "$(HotSpotWorkSpace)\src\share\vm\utilities" /I "$(HotSpotWorkSpace)\src\share\vm\code" /I "$(HotSpotWorkSpace)\src\share\vm\oops" /I "$(HotSpotWorkSpace)\src\share\vm\runtime" /I "$(HotSpotWorkSpace)\src\share\vm\memory" /I "$(HotSpotWorkSpace)\src\share\vm\libadt" /I "$(HotSpotWorkSpace)\src\cpu\i486\vm" /I "$(HotSpotWorkSpace)\src\os\win32\vm" /D "WIN32" /D "_WINDOWS" /D "ASSERT" /Fr /FD /c
|
||||
# ADD BASE RSC /l 0x409
|
||||
# ADD RSC /l 0x409
|
||||
BSC32=bscmake.exe
|
||||
|
@ -1000,9 +1000,10 @@ OopMapSet* Runtime1::generate_code_for(StubID id, StubAssembler* sasm) {
|
||||
DeoptimizationBlob* deopt_blob = SharedRuntime::deopt_blob();
|
||||
assert(deopt_blob != NULL, "deoptimization blob must have been created");
|
||||
restore_live_registers(sasm);
|
||||
__ restore();
|
||||
__ br(Assembler::always, false, Assembler::pt, deopt_blob->unpack_with_reexecution(), relocInfo::runtime_call_type);
|
||||
__ delayed()->nop();
|
||||
|
||||
AddressLiteral dest(deopt_blob->unpack_with_reexecution());
|
||||
__ jump_to(dest, O0);
|
||||
__ delayed()->restore();
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -304,7 +304,7 @@ bool frame::safe_for_sender(JavaThread *thread) {
|
||||
|
||||
// The sender should positively be an nmethod or call_stub. On sparc we might in fact see something else.
|
||||
// The cause of this is because at a save instruction the O7 we get is a leftover from an earlier
|
||||
// window use. So if a runtime stub creates two frames (common in fastdebug/jvmg) then we see the
|
||||
// window use. So if a runtime stub creates two frames (common in fastdebug/debug) then we see the
|
||||
// stale pc. So if the sender blob is not something we'd expect we have little choice but to declare
|
||||
// the stack unwalkable. pd_get_top_frame_for_signal_handler tries to recover from this by unwinding
|
||||
// that initial frame and retrying.
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
// Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
// DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
//
|
||||
// This code is free software; you can redistribute it and/or modify it
|
||||
@ -8176,10 +8176,25 @@ instruct cadd_cmpLTMask( iRegI p, iRegI q, iRegI y, iRegI tmp, flagsReg ccr ) %{
|
||||
format %{ "SUBcc $p,$q,$p\t! p' = p-q\n\t"
|
||||
"ADD $p,$y,$tmp\t! g3=p-q+y\n\t"
|
||||
"MOVlt $tmp,$p\t! p' < 0 ? p'+y : p'" %}
|
||||
ins_encode( enc_cadd_cmpLTMask(p, q, y, tmp) );
|
||||
ins_pipe( cadd_cmpltmask );
|
||||
ins_encode(enc_cadd_cmpLTMask(p, q, y, tmp));
|
||||
ins_pipe(cadd_cmpltmask);
|
||||
%}
|
||||
|
||||
instruct and_cmpLTMask(iRegI p, iRegI q, iRegI y, flagsReg ccr) %{
|
||||
match(Set p (AndI (CmpLTMask p q) y));
|
||||
effect(KILL ccr);
|
||||
ins_cost(DEFAULT_COST*3);
|
||||
|
||||
format %{ "CMP $p,$q\n\t"
|
||||
"MOV $y,$p\n\t"
|
||||
"MOVge G0,$p" %}
|
||||
ins_encode %{
|
||||
__ cmp($p$$Register, $q$$Register);
|
||||
__ mov($y$$Register, $p$$Register);
|
||||
__ movcc(Assembler::greaterEqual, false, Assembler::icc, G0, $p$$Register);
|
||||
%}
|
||||
ins_pipe(ialu_reg_reg_ialu);
|
||||
%}
|
||||
|
||||
//-----------------------------------------------------------------
|
||||
// Direct raw moves between float and general registers using VIS3.
|
||||
|
@ -63,6 +63,13 @@ static void do_oop_store(InterpreterMacroAssembler* _masm,
|
||||
noreg /* pre_val */,
|
||||
tmp, true /*preserve_o_regs*/);
|
||||
|
||||
// G1 barrier needs uncompressed oop for region cross check.
|
||||
Register new_val = val;
|
||||
if (UseCompressedOops && val != G0) {
|
||||
new_val = tmp;
|
||||
__ mov(val, new_val);
|
||||
}
|
||||
|
||||
if (index == noreg ) {
|
||||
assert(Assembler::is_simm13(offset), "fix this code");
|
||||
__ store_heap_oop(val, base, offset);
|
||||
@ -79,7 +86,7 @@ static void do_oop_store(InterpreterMacroAssembler* _masm,
|
||||
__ add(base, index, base);
|
||||
}
|
||||
}
|
||||
__ g1_write_barrier_post(base, val, tmp);
|
||||
__ g1_write_barrier_post(base, new_val, tmp);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -214,14 +214,6 @@ static int encode(Register r) {
|
||||
return enc;
|
||||
}
|
||||
|
||||
static int encode(XMMRegister r) {
|
||||
int enc = r->encoding();
|
||||
if (enc >= 8) {
|
||||
enc -= 8;
|
||||
}
|
||||
return enc;
|
||||
}
|
||||
|
||||
void Assembler::emit_arith_b(int op1, int op2, Register dst, int imm8) {
|
||||
assert(dst->has_byte_register(), "must have byte register");
|
||||
assert(isByte(op1) && isByte(op2), "wrong opcode");
|
||||
|
@ -41,11 +41,6 @@
|
||||
|
||||
#define BIND(label) bind(label); BLOCK_COMMENT(#label ":")
|
||||
|
||||
// Workaround for C++ overloading nastiness on '0' for RegisterOrConstant.
|
||||
static RegisterOrConstant constant(int value) {
|
||||
return RegisterOrConstant(value);
|
||||
}
|
||||
|
||||
void MethodHandles::load_klass_from_Class(MacroAssembler* _masm, Register klass_reg) {
|
||||
if (VerifyMethodHandles)
|
||||
verify_klass(_masm, klass_reg, SystemDictionary::WK_KLASS_ENUM_NAME(java_lang_Class),
|
||||
|
@ -158,14 +158,19 @@ static void do_oop_store(InterpreterMacroAssembler* _masm,
|
||||
if (val == noreg) {
|
||||
__ store_heap_oop_null(Address(rdx, 0));
|
||||
} else {
|
||||
// G1 barrier needs uncompressed oop for region cross check.
|
||||
Register new_val = val;
|
||||
if (UseCompressedOops) {
|
||||
new_val = rbx;
|
||||
__ movptr(new_val, val);
|
||||
}
|
||||
__ store_heap_oop(Address(rdx, 0), val);
|
||||
__ g1_write_barrier_post(rdx /* store_adr */,
|
||||
val /* new_val */,
|
||||
new_val /* new_val */,
|
||||
r15_thread /* thread */,
|
||||
r8 /* tmp */,
|
||||
rbx /* tmp2 */);
|
||||
}
|
||||
|
||||
}
|
||||
break;
|
||||
#endif // INCLUDE_ALL_GCS
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
// Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
// DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
//
|
||||
// This code is free software; you can redistribute it and/or modify it
|
||||
@ -2280,30 +2280,6 @@ encode %{
|
||||
emit_rm(cbuf, 0x3, $p$$reg, tmpReg);
|
||||
%}
|
||||
|
||||
enc_class enc_cmpLTP_mem(rRegI p, rRegI q, memory mem, eCXRegI tmp) %{ // cadd_cmpLT
|
||||
int tmpReg = $tmp$$reg;
|
||||
|
||||
// SUB $p,$q
|
||||
emit_opcode(cbuf,0x2B);
|
||||
emit_rm(cbuf, 0x3, $p$$reg, $q$$reg);
|
||||
// SBB $tmp,$tmp
|
||||
emit_opcode(cbuf,0x1B);
|
||||
emit_rm(cbuf, 0x3, tmpReg, tmpReg);
|
||||
// AND $tmp,$y
|
||||
cbuf.set_insts_mark(); // Mark start of opcode for reloc info in mem operand
|
||||
emit_opcode(cbuf,0x23);
|
||||
int reg_encoding = tmpReg;
|
||||
int base = $mem$$base;
|
||||
int index = $mem$$index;
|
||||
int scale = $mem$$scale;
|
||||
int displace = $mem$$disp;
|
||||
relocInfo::relocType disp_reloc = $mem->disp_reloc();
|
||||
encode_RegMem(cbuf, reg_encoding, base, index, scale, displace, disp_reloc);
|
||||
// ADD $p,$tmp
|
||||
emit_opcode(cbuf,0x03);
|
||||
emit_rm(cbuf, 0x3, $p$$reg, tmpReg);
|
||||
%}
|
||||
|
||||
enc_class shift_left_long( eRegL dst, eCXRegI shift ) %{
|
||||
// TEST shift,32
|
||||
emit_opcode(cbuf,0xF7);
|
||||
@ -8885,9 +8861,9 @@ instruct convP2B( rRegI dst, eRegP src, eFlagsReg cr ) %{
|
||||
%}
|
||||
%}
|
||||
|
||||
instruct cmpLTMask( eCXRegI dst, ncxRegI p, ncxRegI q, eFlagsReg cr ) %{
|
||||
instruct cmpLTMask(eCXRegI dst, ncxRegI p, ncxRegI q, eFlagsReg cr) %{
|
||||
match(Set dst (CmpLTMask p q));
|
||||
effect( KILL cr );
|
||||
effect(KILL cr);
|
||||
ins_cost(400);
|
||||
|
||||
// SETlt can only use low byte of EAX,EBX, ECX, or EDX as destination
|
||||
@ -8895,50 +8871,83 @@ instruct cmpLTMask( eCXRegI dst, ncxRegI p, ncxRegI q, eFlagsReg cr ) %{
|
||||
"CMP $p,$q\n\t"
|
||||
"SETlt $dst\n\t"
|
||||
"NEG $dst" %}
|
||||
ins_encode( OpcRegReg(0x33,dst,dst),
|
||||
OpcRegReg(0x3B,p,q),
|
||||
setLT_reg(dst), neg_reg(dst) );
|
||||
ins_pipe( pipe_slow );
|
||||
ins_encode %{
|
||||
Register Rp = $p$$Register;
|
||||
Register Rq = $q$$Register;
|
||||
Register Rd = $dst$$Register;
|
||||
Label done;
|
||||
__ xorl(Rd, Rd);
|
||||
__ cmpl(Rp, Rq);
|
||||
__ setb(Assembler::less, Rd);
|
||||
__ negl(Rd);
|
||||
%}
|
||||
|
||||
ins_pipe(pipe_slow);
|
||||
%}
|
||||
|
||||
instruct cmpLTMask0( rRegI dst, immI0 zero, eFlagsReg cr ) %{
|
||||
instruct cmpLTMask0(rRegI dst, immI0 zero, eFlagsReg cr) %{
|
||||
match(Set dst (CmpLTMask dst zero));
|
||||
effect( DEF dst, KILL cr );
|
||||
effect(DEF dst, KILL cr);
|
||||
ins_cost(100);
|
||||
|
||||
format %{ "SAR $dst,31" %}
|
||||
opcode(0xC1, 0x7); /* C1 /7 ib */
|
||||
ins_encode( RegOpcImm( dst, 0x1F ) );
|
||||
ins_pipe( ialu_reg );
|
||||
format %{ "SAR $dst,31\t# cmpLTMask0" %}
|
||||
ins_encode %{
|
||||
__ sarl($dst$$Register, 31);
|
||||
%}
|
||||
ins_pipe(ialu_reg);
|
||||
%}
|
||||
|
||||
|
||||
instruct cadd_cmpLTMask( ncxRegI p, ncxRegI q, ncxRegI y, eCXRegI tmp, eFlagsReg cr ) %{
|
||||
/* better to save a register than avoid a branch */
|
||||
instruct cadd_cmpLTMask(rRegI p, rRegI q, rRegI y, eFlagsReg cr) %{
|
||||
match(Set p (AddI (AndI (CmpLTMask p q) y) (SubI p q)));
|
||||
effect( KILL tmp, KILL cr );
|
||||
effect(KILL cr);
|
||||
ins_cost(400);
|
||||
// annoyingly, $tmp has no edges so you cant ask for it in
|
||||
// any format or encoding
|
||||
format %{ "SUB $p,$q\n\t"
|
||||
"SBB ECX,ECX\n\t"
|
||||
"AND ECX,$y\n\t"
|
||||
"ADD $p,ECX" %}
|
||||
ins_encode( enc_cmpLTP(p,q,y,tmp) );
|
||||
ins_pipe( pipe_cmplt );
|
||||
format %{ "SUB $p,$q\t# cadd_cmpLTMask\n\t"
|
||||
"JGE done\n\t"
|
||||
"ADD $p,$y\n"
|
||||
"done: " %}
|
||||
ins_encode %{
|
||||
Register Rp = $p$$Register;
|
||||
Register Rq = $q$$Register;
|
||||
Register Ry = $y$$Register;
|
||||
Label done;
|
||||
__ subl(Rp, Rq);
|
||||
__ jccb(Assembler::greaterEqual, done);
|
||||
__ addl(Rp, Ry);
|
||||
__ bind(done);
|
||||
%}
|
||||
|
||||
ins_pipe(pipe_cmplt);
|
||||
%}
|
||||
|
||||
/* better to save a register than avoid a branch */
|
||||
instruct and_cmpLTMask(rRegI p, rRegI q, rRegI y, eFlagsReg cr) %{
|
||||
match(Set y (AndI (CmpLTMask p q) y));
|
||||
effect(KILL cr);
|
||||
|
||||
ins_cost(300);
|
||||
|
||||
format %{ "CMPL $p, $q\t# and_cmpLTMask\n\t"
|
||||
"JLT done\n\t"
|
||||
"XORL $y, $y\n"
|
||||
"done: " %}
|
||||
ins_encode %{
|
||||
Register Rp = $p$$Register;
|
||||
Register Rq = $q$$Register;
|
||||
Register Ry = $y$$Register;
|
||||
Label done;
|
||||
__ cmpl(Rp, Rq);
|
||||
__ jccb(Assembler::less, done);
|
||||
__ xorl(Ry, Ry);
|
||||
__ bind(done);
|
||||
%}
|
||||
|
||||
ins_pipe(pipe_cmplt);
|
||||
%}
|
||||
|
||||
/* If I enable this, I encourage spilling in the inner loop of compress.
|
||||
instruct cadd_cmpLTMask_mem( ncxRegI p, ncxRegI q, memory y, eCXRegI tmp, eFlagsReg cr ) %{
|
||||
instruct cadd_cmpLTMask_mem(ncxRegI p, ncxRegI q, memory y, eCXRegI tmp, eFlagsReg cr) %{
|
||||
match(Set p (AddI (AndI (CmpLTMask p q) (LoadI y)) (SubI p q)));
|
||||
effect( USE_KILL tmp, KILL cr );
|
||||
ins_cost(400);
|
||||
|
||||
format %{ "SUB $p,$q\n\t"
|
||||
"SBB ECX,ECX\n\t"
|
||||
"AND ECX,$y\n\t"
|
||||
"ADD $p,ECX" %}
|
||||
ins_encode( enc_cmpLTP_mem(p,q,y,tmp) );
|
||||
%}
|
||||
*/
|
||||
|
||||
//----------Long Instructions------------------------------------------------
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
// Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
// DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
//
|
||||
// This code is free software; you can redistribute it and/or modify it
|
||||
@ -1651,17 +1651,6 @@ const RegMask Matcher::method_handle_invoke_SP_save_mask() {
|
||||
return PTR_RBP_REG_mask();
|
||||
}
|
||||
|
||||
static Address build_address(int b, int i, int s, int d) {
|
||||
Register index = as_Register(i);
|
||||
Address::ScaleFactor scale = (Address::ScaleFactor)s;
|
||||
if (index == rsp) {
|
||||
index = noreg;
|
||||
scale = Address::no_scale;
|
||||
}
|
||||
Address addr(as_Register(b), index, scale, d);
|
||||
return addr;
|
||||
}
|
||||
|
||||
%}
|
||||
|
||||
//----------ENCODING BLOCK-----------------------------------------------------
|
||||
@ -9403,7 +9392,7 @@ instruct cmpLTMask(rRegI dst, rRegI p, rRegI q, rFlagsReg cr)
|
||||
match(Set dst (CmpLTMask p q));
|
||||
effect(KILL cr);
|
||||
|
||||
ins_cost(400); // XXX
|
||||
ins_cost(400);
|
||||
format %{ "cmpl $p, $q\t# cmpLTMask\n\t"
|
||||
"setlt $dst\n\t"
|
||||
"movzbl $dst, $dst\n\t"
|
||||
@ -9421,37 +9410,63 @@ instruct cmpLTMask0(rRegI dst, immI0 zero, rFlagsReg cr)
|
||||
match(Set dst (CmpLTMask dst zero));
|
||||
effect(KILL cr);
|
||||
|
||||
ins_cost(100); // XXX
|
||||
ins_cost(100);
|
||||
format %{ "sarl $dst, #31\t# cmpLTMask0" %}
|
||||
opcode(0xC1, 0x7); /* C1 /7 ib */
|
||||
ins_encode(reg_opc_imm(dst, 0x1F));
|
||||
ins_encode %{
|
||||
__ sarl($dst$$Register, 31);
|
||||
%}
|
||||
ins_pipe(ialu_reg);
|
||||
%}
|
||||
|
||||
|
||||
instruct cadd_cmpLTMask(rRegI p, rRegI q, rRegI y, rRegI tmp, rFlagsReg cr)
|
||||
/* Better to save a register than avoid a branch */
|
||||
instruct cadd_cmpLTMask(rRegI p, rRegI q, rRegI y, rFlagsReg cr)
|
||||
%{
|
||||
match(Set p (AddI (AndI (CmpLTMask p q) y) (SubI p q)));
|
||||
effect(TEMP tmp, KILL cr);
|
||||
|
||||
ins_cost(400); // XXX
|
||||
format %{ "subl $p, $q\t# cadd_cmpLTMask1\n\t"
|
||||
"sbbl $tmp, $tmp\n\t"
|
||||
"andl $tmp, $y\n\t"
|
||||
"addl $p, $tmp" %}
|
||||
effect(KILL cr);
|
||||
ins_cost(300);
|
||||
format %{ "subl $p,$q\t# cadd_cmpLTMask\n\t"
|
||||
"jge done\n\t"
|
||||
"addl $p,$y\n"
|
||||
"done: " %}
|
||||
ins_encode %{
|
||||
Register Rp = $p$$Register;
|
||||
Register Rq = $q$$Register;
|
||||
Register Ry = $y$$Register;
|
||||
Register Rt = $tmp$$Register;
|
||||
Label done;
|
||||
__ subl(Rp, Rq);
|
||||
__ sbbl(Rt, Rt);
|
||||
__ andl(Rt, Ry);
|
||||
__ addl(Rp, Rt);
|
||||
__ jccb(Assembler::greaterEqual, done);
|
||||
__ addl(Rp, Ry);
|
||||
__ bind(done);
|
||||
%}
|
||||
ins_pipe(pipe_cmplt);
|
||||
%}
|
||||
|
||||
/* Better to save a register than avoid a branch */
|
||||
instruct and_cmpLTMask(rRegI p, rRegI q, rRegI y, rFlagsReg cr)
|
||||
%{
|
||||
match(Set y (AndI (CmpLTMask p q) y));
|
||||
effect(KILL cr);
|
||||
|
||||
ins_cost(300);
|
||||
|
||||
format %{ "cmpl $p, $q\t# and_cmpLTMask\n\t"
|
||||
"jlt done\n\t"
|
||||
"xorl $y, $y\n"
|
||||
"done: " %}
|
||||
ins_encode %{
|
||||
Register Rp = $p$$Register;
|
||||
Register Rq = $q$$Register;
|
||||
Register Ry = $y$$Register;
|
||||
Label done;
|
||||
__ cmpl(Rp, Rq);
|
||||
__ jccb(Assembler::less, done);
|
||||
__ xorl(Ry, Ry);
|
||||
__ bind(done);
|
||||
%}
|
||||
ins_pipe(pipe_cmplt);
|
||||
%}
|
||||
|
||||
|
||||
//---------- FP Instructions------------------------------------------------
|
||||
|
||||
instruct cmpF_cc_reg(rFlagsRegU cr, regF src1, regF src2)
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -60,7 +60,7 @@
|
||||
#define PR_MODEL_LP64 2
|
||||
|
||||
#ifdef COMPILER1
|
||||
#if defined(DEBUG) || defined(FASTDEBUG)
|
||||
#ifdef ASSERT
|
||||
|
||||
/*
|
||||
* To avoid the most part of potential link errors
|
||||
@ -84,7 +84,7 @@ address StubRoutines::_call_stub_return_address = NULL;
|
||||
|
||||
StubQueue* AbstractInterpreter::_code = NULL;
|
||||
|
||||
#endif /* defined(DEBUG) || defined(FASTDEBUG) */
|
||||
#endif /* ASSERT */
|
||||
#endif /* COMPILER1 */
|
||||
|
||||
#define GEN_OFFS(Type,Name) \
|
||||
|
@ -152,7 +152,6 @@ sigset_t SR_sigset;
|
||||
// utility functions
|
||||
|
||||
static int SR_initialize();
|
||||
static int SR_finalize();
|
||||
|
||||
julong os::available_memory() {
|
||||
return Bsd::available_memory();
|
||||
@ -1200,6 +1199,9 @@ bool os::dll_build_name(char* buffer, size_t buflen,
|
||||
} else if (strchr(pname, *os::path_separator()) != NULL) {
|
||||
int n;
|
||||
char** pelements = split_path(pname, &n);
|
||||
if (pelements == NULL) {
|
||||
return false;
|
||||
}
|
||||
for (int i = 0 ; i < n ; i++) {
|
||||
// Really shouldn't be NULL, but check can't hurt
|
||||
if (pelements[i] == NULL || strlen(pelements[i]) == 0) {
|
||||
@ -2766,10 +2768,6 @@ static int SR_initialize() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int SR_finalize() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
// returns true on success and false on error - really an error is fatal
|
||||
// but this seems the normal response to library errors
|
||||
@ -3578,16 +3576,6 @@ int os::Bsd::safe_cond_timedwait(pthread_cond_t *_cond, pthread_mutex_t *_mutex,
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// debug support
|
||||
|
||||
static address same_page(address x, address y) {
|
||||
int page_bits = -os::vm_page_size();
|
||||
if ((intptr_t(x) & page_bits) == (intptr_t(y) & page_bits))
|
||||
return x;
|
||||
else if (x > y)
|
||||
return (address)(intptr_t(y) | ~page_bits) + 1;
|
||||
else
|
||||
return (address)(intptr_t(y) & page_bits);
|
||||
}
|
||||
|
||||
bool os::find(address addr, outputStream* st) {
|
||||
Dl_info dlinfo;
|
||||
memset(&dlinfo, 0, sizeof(dlinfo));
|
||||
@ -3611,8 +3599,8 @@ bool os::find(address addr, outputStream* st) {
|
||||
|
||||
if (Verbose) {
|
||||
// decode some bytes around the PC
|
||||
address begin = same_page(addr-40, addr);
|
||||
address end = same_page(addr+40, addr);
|
||||
address begin = clamp_address_in_page(addr-40, addr, os::vm_page_size());
|
||||
address end = clamp_address_in_page(addr+40, addr, os::vm_page_size());
|
||||
address lowest = (address) dlinfo.dli_sname;
|
||||
if (!lowest) lowest = (address) dlinfo.dli_fbase;
|
||||
if (begin < lowest) begin = lowest;
|
||||
|
@ -672,15 +672,15 @@ static int open_sharedmem_file(const char* filename, int oflags, TRAPS) {
|
||||
RESTARTABLE(::open(filename, oflags), result);
|
||||
if (result == OS_ERR) {
|
||||
if (errno == ENOENT) {
|
||||
THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Process not found");
|
||||
THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Process not found", OS_ERR);
|
||||
}
|
||||
else if (errno == EACCES) {
|
||||
THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Permission denied");
|
||||
THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Permission denied", OS_ERR);
|
||||
}
|
||||
else {
|
||||
THROW_MSG_0(vmSymbols::java_io_IOException(), strerror(errno));
|
||||
THROW_MSG_(vmSymbols::java_io_IOException(), strerror(errno), OS_ERR);
|
||||
}
|
||||
}
|
||||
|
||||
@ -828,7 +828,7 @@ static void mmap_attach_shared(const char* user, int vmid, PerfMemory::PerfMemor
|
||||
char* mapAddress;
|
||||
int result;
|
||||
int fd;
|
||||
size_t size;
|
||||
size_t size = 0;
|
||||
const char* luser = NULL;
|
||||
|
||||
int mmap_prot;
|
||||
@ -899,9 +899,12 @@ static void mmap_attach_shared(const char* user, int vmid, PerfMemory::PerfMemor
|
||||
|
||||
if (*sizep == 0) {
|
||||
size = sharedmem_filesize(fd, CHECK);
|
||||
assert(size != 0, "unexpected size");
|
||||
} else {
|
||||
size = *sizep;
|
||||
}
|
||||
|
||||
assert(size > 0, "unexpected size <= 0");
|
||||
|
||||
mapAddress = (char*)::mmap((char*)0, size, mmap_prot, MAP_SHARED, fd, 0);
|
||||
|
||||
// attempt to close the file - restart if it gets interrupted,
|
||||
|
@ -176,7 +176,6 @@ class MemNotifyThread: public Thread {
|
||||
// utility functions
|
||||
|
||||
static int SR_initialize();
|
||||
static int SR_finalize();
|
||||
|
||||
julong os::available_memory() {
|
||||
return Linux::available_memory();
|
||||
@ -1633,6 +1632,9 @@ bool os::dll_build_name(char* buffer, size_t buflen,
|
||||
} else if (strchr(pname, *os::path_separator()) != NULL) {
|
||||
int n;
|
||||
char** pelements = split_path(pname, &n);
|
||||
if (pelements == NULL) {
|
||||
return false;
|
||||
}
|
||||
for (int i = 0 ; i < n ; i++) {
|
||||
// Really shouldn't be NULL, but check can't hurt
|
||||
if (pelements[i] == NULL || strlen(pelements[i]) == 0) {
|
||||
@ -3655,10 +3657,6 @@ static int SR_initialize() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int SR_finalize() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
// returns true on success and false on error - really an error is fatal
|
||||
// but this seems the normal response to library errors
|
||||
@ -4500,16 +4498,6 @@ int os::Linux::safe_cond_timedwait(pthread_cond_t *_cond, pthread_mutex_t *_mute
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// debug support
|
||||
|
||||
static address same_page(address x, address y) {
|
||||
int page_bits = -os::vm_page_size();
|
||||
if ((intptr_t(x) & page_bits) == (intptr_t(y) & page_bits))
|
||||
return x;
|
||||
else if (x > y)
|
||||
return (address)(intptr_t(y) | ~page_bits) + 1;
|
||||
else
|
||||
return (address)(intptr_t(y) & page_bits);
|
||||
}
|
||||
|
||||
bool os::find(address addr, outputStream* st) {
|
||||
Dl_info dlinfo;
|
||||
memset(&dlinfo, 0, sizeof(dlinfo));
|
||||
@ -4533,8 +4521,8 @@ bool os::find(address addr, outputStream* st) {
|
||||
|
||||
if (Verbose) {
|
||||
// decode some bytes around the PC
|
||||
address begin = same_page(addr-40, addr);
|
||||
address end = same_page(addr+40, addr);
|
||||
address begin = clamp_address_in_page(addr-40, addr, os::vm_page_size());
|
||||
address end = clamp_address_in_page(addr+40, addr, os::vm_page_size());
|
||||
address lowest = (address) dlinfo.dli_sname;
|
||||
if (!lowest) lowest = (address) dlinfo.dli_fbase;
|
||||
if (begin < lowest) begin = lowest;
|
||||
|
@ -672,15 +672,15 @@ static int open_sharedmem_file(const char* filename, int oflags, TRAPS) {
|
||||
RESTARTABLE(::open(filename, oflags), result);
|
||||
if (result == OS_ERR) {
|
||||
if (errno == ENOENT) {
|
||||
THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Process not found");
|
||||
THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Process not found", OS_ERR);
|
||||
}
|
||||
else if (errno == EACCES) {
|
||||
THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Permission denied");
|
||||
THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Permission denied", OS_ERR);
|
||||
}
|
||||
else {
|
||||
THROW_MSG_0(vmSymbols::java_io_IOException(), strerror(errno));
|
||||
THROW_MSG_(vmSymbols::java_io_IOException(), strerror(errno), OS_ERR);
|
||||
}
|
||||
}
|
||||
|
||||
@ -828,7 +828,7 @@ static void mmap_attach_shared(const char* user, int vmid, PerfMemory::PerfMemor
|
||||
char* mapAddress;
|
||||
int result;
|
||||
int fd;
|
||||
size_t size;
|
||||
size_t size = 0;
|
||||
const char* luser = NULL;
|
||||
|
||||
int mmap_prot;
|
||||
@ -899,9 +899,12 @@ static void mmap_attach_shared(const char* user, int vmid, PerfMemory::PerfMemor
|
||||
|
||||
if (*sizep == 0) {
|
||||
size = sharedmem_filesize(fd, CHECK);
|
||||
assert(size != 0, "unexpected size");
|
||||
} else {
|
||||
size = *sizep;
|
||||
}
|
||||
|
||||
assert(size > 0, "unexpected size <= 0");
|
||||
|
||||
mapAddress = (char*)::mmap((char*)0, size, mmap_prot, MAP_SHARED, fd, 0);
|
||||
|
||||
// attempt to close the file - restart if it gets interrupted,
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -55,14 +55,14 @@
|
||||
#include "utilities/accessFlags.hpp"
|
||||
#include "utilities/globalDefinitions.hpp"
|
||||
#ifdef COMPILER1
|
||||
#if defined(DEBUG) || defined(FASTDEBUG)
|
||||
#ifdef ASSERT
|
||||
|
||||
/*
|
||||
* To avoid the most part of potential link errors
|
||||
* we link this program with -z nodefs .
|
||||
*
|
||||
* But for 'debug1' and 'fastdebug1' we still have to provide
|
||||
* a particular workaround for the following symbols bellow.
|
||||
* a particular workaround for the following symbols below.
|
||||
* It will be good to find out a generic way in the future.
|
||||
*/
|
||||
|
||||
@ -79,7 +79,7 @@ address StubRoutines::_call_stub_return_address = NULL;
|
||||
|
||||
StubQueue* AbstractInterpreter::_code = NULL;
|
||||
|
||||
#endif /* defined(DEBUG) || defined(FASTDEBUG) */
|
||||
#endif /* ASSERT */
|
||||
#endif /* COMPILER1 */
|
||||
|
||||
#define GEN_OFFS(Type,Name) \
|
||||
|
@ -1885,6 +1885,9 @@ bool os::dll_build_name(char* buffer, size_t buflen,
|
||||
} else if (strchr(pname, *os::path_separator()) != NULL) {
|
||||
int n;
|
||||
char** pelements = split_path(pname, &n);
|
||||
if (pelements == NULL) {
|
||||
return false;
|
||||
}
|
||||
for (int i = 0 ; i < n ; i++) {
|
||||
// really shouldn't be NULL but what the heck, check can't hurt
|
||||
if (pelements[i] == NULL || strlen(pelements[i]) == 0) {
|
||||
@ -5787,16 +5790,6 @@ int os::loadavg(double loadavg[], int nelem) {
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
|
||||
static address same_page(address x, address y) {
|
||||
intptr_t page_bits = -os::vm_page_size();
|
||||
if ((intptr_t(x) & page_bits) == (intptr_t(y) & page_bits))
|
||||
return x;
|
||||
else if (x > y)
|
||||
return (address)(intptr_t(y) | ~page_bits) + 1;
|
||||
else
|
||||
return (address)(intptr_t(y) & page_bits);
|
||||
}
|
||||
|
||||
bool os::find(address addr, outputStream* st) {
|
||||
Dl_info dlinfo;
|
||||
memset(&dlinfo, 0, sizeof(dlinfo));
|
||||
@ -5822,8 +5815,8 @@ bool os::find(address addr, outputStream* st) {
|
||||
|
||||
if (Verbose) {
|
||||
// decode some bytes around the PC
|
||||
address begin = same_page(addr-40, addr);
|
||||
address end = same_page(addr+40, addr);
|
||||
address begin = clamp_address_in_page(addr-40, addr, os::vm_page_size());
|
||||
address end = clamp_address_in_page(addr+40, addr, os::vm_page_size());
|
||||
address lowest = (address) dlinfo.dli_sname;
|
||||
if (!lowest) lowest = (address) dlinfo.dli_fbase;
|
||||
if (begin < lowest) begin = lowest;
|
||||
|
@ -687,15 +687,15 @@ static int open_sharedmem_file(const char* filename, int oflags, TRAPS) {
|
||||
RESTARTABLE(::open(filename, oflags), result);
|
||||
if (result == OS_ERR) {
|
||||
if (errno == ENOENT) {
|
||||
THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Process not found");
|
||||
THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Process not found", OS_ERR);
|
||||
}
|
||||
else if (errno == EACCES) {
|
||||
THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Permission denied");
|
||||
THROW_MSG_(vmSymbols::java_lang_IllegalArgumentException(),
|
||||
"Permission denied", OS_ERR);
|
||||
}
|
||||
else {
|
||||
THROW_MSG_0(vmSymbols::java_io_IOException(), strerror(errno));
|
||||
THROW_MSG_(vmSymbols::java_io_IOException(), strerror(errno), OS_ERR);
|
||||
}
|
||||
}
|
||||
|
||||
@ -843,7 +843,7 @@ static void mmap_attach_shared(const char* user, int vmid, PerfMemory::PerfMemor
|
||||
char* mapAddress;
|
||||
int result;
|
||||
int fd;
|
||||
size_t size;
|
||||
size_t size = 0;
|
||||
const char* luser = NULL;
|
||||
|
||||
int mmap_prot;
|
||||
@ -914,9 +914,12 @@ static void mmap_attach_shared(const char* user, int vmid, PerfMemory::PerfMemor
|
||||
|
||||
if (*sizep == 0) {
|
||||
size = sharedmem_filesize(fd, CHECK);
|
||||
assert(size != 0, "unexpected size");
|
||||
} else {
|
||||
size = *sizep;
|
||||
}
|
||||
|
||||
assert(size > 0, "unexpected size <= 0");
|
||||
|
||||
mapAddress = (char*)::mmap((char*)0, size, mmap_prot, MAP_SHARED, fd, 0);
|
||||
|
||||
// attempt to close the file - restart if it gets interrupted,
|
||||
|
@ -1,78 +0,0 @@
|
||||
/*
|
||||
* Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
* under the terms of the GNU General Public License version 2 only, as
|
||||
* published by the Free Software Foundation.
|
||||
*
|
||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
||||
* version 2 for more details (a copy is included in the LICENSE file that
|
||||
* accompanied this code).
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License version
|
||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
||||
*
|
||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
* or visit www.oracle.com if you need additional information or have any
|
||||
* questions.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "precompiled.hpp"
|
||||
#include "opto/chaitin.hpp"
|
||||
#include "opto/machnode.hpp"
|
||||
|
||||
// Disallow the use of the frame pointer (EBP) for implicit null exceptions
|
||||
// on win95/98. If we do not do this, the OS gets confused and gives a stack
|
||||
// error.
|
||||
void PhaseRegAlloc::pd_preallocate_hook() {
|
||||
#ifndef _WIN64
|
||||
if (ImplicitNullChecks && !os::win32::is_nt()) {
|
||||
for (uint block_num=1; block_num<_cfg._num_blocks; block_num++) {
|
||||
Block *block = _cfg._blocks[block_num];
|
||||
|
||||
Node *block_end = block->end();
|
||||
if (block_end->is_MachNullCheck() &&
|
||||
block_end->as_Mach()->ideal_Opcode() != Op_Con) {
|
||||
// The last instruction in the block is an implicit null check.
|
||||
// Fix its input so that it does not load into the frame pointer.
|
||||
_matcher.pd_implicit_null_fixup(block_end->in(1)->as_Mach(),
|
||||
block_end->as_MachNullCheck()->_vidx);
|
||||
}
|
||||
}
|
||||
}
|
||||
#else
|
||||
// WIN64==itanium on XP
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef ASSERT
|
||||
// Verify that no implicit null check uses the frame pointer (EBP) as
|
||||
// its register on win95/98. Use of the frame pointer in an implicit
|
||||
// null check confuses the OS, yielding a stack error.
|
||||
void PhaseRegAlloc::pd_postallocate_verify_hook() {
|
||||
#ifndef _WIN64
|
||||
if (ImplicitNullChecks && !os::win32::is_nt()) {
|
||||
for (uint block_num=1; block_num<_cfg._num_blocks; block_num++) {
|
||||
Block *block = _cfg._blocks[block_num];
|
||||
|
||||
Node *block_end = block->_nodes[block->_nodes.size()-1];
|
||||
if (block_end->is_MachNullCheck() && block_end->as_Mach()->ideal_Opcode() != Op_Con) {
|
||||
// The last instruction in the block is an implicit
|
||||
// null check. Verify that this instruction does not
|
||||
// use the frame pointer.
|
||||
int reg = get_reg_first(block_end->in(1)->in(block_end->as_MachNullCheck()->_vidx));
|
||||
assert(reg != EBP_num,
|
||||
"implicit null check using frame pointer on win95/98");
|
||||
}
|
||||
}
|
||||
}
|
||||
#else
|
||||
// WIN64==itanium on XP
|
||||
#endif
|
||||
}
|
||||
#endif
|
@ -1182,6 +1182,9 @@ bool os::dll_build_name(char *buffer, size_t buflen,
|
||||
} else if (strchr(pname, *os::path_separator()) != NULL) {
|
||||
int n;
|
||||
char** pelements = split_path(pname, &n);
|
||||
if (pelements == NULL) {
|
||||
return false;
|
||||
}
|
||||
for (int i = 0 ; i < n ; i++) {
|
||||
char* path = pelements[i];
|
||||
// Really shouldn't be NULL, but check can't hurt
|
||||
@ -4235,9 +4238,6 @@ char * os::native_path(char *path) {
|
||||
path[3] = '\0';
|
||||
}
|
||||
|
||||
#ifdef DEBUG
|
||||
jio_fprintf(stderr, "sysNativePath: %s\n", path);
|
||||
#endif DEBUG
|
||||
return path;
|
||||
}
|
||||
|
||||
|
@ -1581,7 +1581,7 @@ static void open_file_mapping(const char* user, int vmid,
|
||||
ResourceMark rm;
|
||||
|
||||
void *mapAddress = 0;
|
||||
size_t size;
|
||||
size_t size = 0;
|
||||
HANDLE fmh;
|
||||
DWORD ofm_access;
|
||||
DWORD mv_access;
|
||||
@ -1652,9 +1652,12 @@ static void open_file_mapping(const char* user, int vmid,
|
||||
|
||||
if (*sizep == 0) {
|
||||
size = sharedmem_filesize(rfilename, CHECK);
|
||||
assert(size != 0, "unexpected size");
|
||||
} else {
|
||||
size = *sizep;
|
||||
}
|
||||
|
||||
assert(size > 0, "unexpected size <= 0");
|
||||
|
||||
// Open the file mapping object with the given name
|
||||
fmh = open_sharedmem_object(robjectname, ofm_access, CHECK);
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 2008, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2008, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -19,7 +19,7 @@
|
||||
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
||||
# or visit www.oracle.com if you need additional information or have any
|
||||
# questions.
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
# Single gnu makefile for solaris, linux and windows (windows requires cygwin and mingw)
|
||||
@ -66,7 +66,7 @@ ARCH=i386
|
||||
endif
|
||||
CC = $(MINGW)-gcc
|
||||
CONFIGURE_ARGS= --host=$(MINGW) --target=$(MINGW)
|
||||
else #linux
|
||||
else #linux
|
||||
CPU = $(shell uname -m)
|
||||
ARCH1=$(CPU:x86_64=amd64)
|
||||
ARCH=$(ARCH1:i686=i386)
|
||||
@ -116,7 +116,6 @@ OUTFLAGS += -o $@
|
||||
else #Windows
|
||||
OS = windows
|
||||
CC = gcc
|
||||
#CPPFLAGS += /D"WIN32" /D"_WINDOWS" /D"DEBUG" /D"NDEBUG"
|
||||
CFLAGS += /nologo /MD /W3 /WX /O2 /Fo$(@:.dll=.obj) /Gi-
|
||||
CFLAGS += LIBARCH=\"$(LIBARCH)\"
|
||||
DLDFLAGS += /dll /subsystem:windows /incremental:no \
|
||||
|
@ -368,8 +368,10 @@ wildcardFileList(const char *wildcard)
|
||||
const char *basename;
|
||||
FileList fl = FileList_new(16);
|
||||
WildcardIterator it = WildcardIterator_for(wildcard);
|
||||
if (it == NULL)
|
||||
if (it == NULL) {
|
||||
FileList_free(fl);
|
||||
return NULL;
|
||||
}
|
||||
while ((basename = WildcardIterator_next(it)) != NULL)
|
||||
if (isJarFileName(basename))
|
||||
FileList_add(fl, wildcardConcat(wildcard, basename));
|
||||
|
@ -63,11 +63,10 @@ static void defineRegNames(FILE *fp, RegisterForm *registers) {
|
||||
RegDef *reg_def = NULL;
|
||||
RegDef *next = NULL;
|
||||
registers->reset_RegDefs();
|
||||
for( reg_def = registers->iter_RegDefs(); reg_def != NULL; reg_def = next ) {
|
||||
for (reg_def = registers->iter_RegDefs(); reg_def != NULL; reg_def = next) {
|
||||
next = registers->iter_RegDefs();
|
||||
const char *comma = (next != NULL) ? "," : " // no trailing comma";
|
||||
fprintf(fp," \"%s\"%s\n",
|
||||
reg_def->_regname, comma );
|
||||
fprintf(fp," \"%s\"%s\n", reg_def->_regname, comma);
|
||||
}
|
||||
|
||||
// Finish defining enumeration
|
||||
@ -79,10 +78,10 @@ static void defineRegNames(FILE *fp, RegisterForm *registers) {
|
||||
reg_def = NULL;
|
||||
next = NULL;
|
||||
registers->reset_RegDefs();
|
||||
for( reg_def = registers->iter_RegDefs(); reg_def != NULL; reg_def = next ) {
|
||||
for (reg_def = registers->iter_RegDefs(); reg_def != NULL; reg_def = next) {
|
||||
next = registers->iter_RegDefs();
|
||||
const char *comma = (next != NULL) ? "," : " // no trailing comma";
|
||||
fprintf(fp,"\t%s%s\n", reg_def->_concrete, comma );
|
||||
fprintf(fp,"\t%s%s\n", reg_def->_concrete, comma);
|
||||
}
|
||||
// Finish defining array
|
||||
fprintf(fp,"\t};\n");
|
||||
@ -104,19 +103,17 @@ static void defineRegEncodes(FILE *fp, RegisterForm *registers) {
|
||||
RegDef *reg_def = NULL;
|
||||
RegDef *next = NULL;
|
||||
registers->reset_RegDefs();
|
||||
for( reg_def = registers->iter_RegDefs(); reg_def != NULL; reg_def = next ) {
|
||||
for (reg_def = registers->iter_RegDefs(); reg_def != NULL; reg_def = next) {
|
||||
next = registers->iter_RegDefs();
|
||||
const char* register_encode = reg_def->register_encode();
|
||||
const char *comma = (next != NULL) ? "," : " // no trailing comma";
|
||||
int encval;
|
||||
if (!ADLParser::is_int_token(register_encode, encval)) {
|
||||
fprintf(fp," %s%s // %s\n",
|
||||
register_encode, comma, reg_def->_regname );
|
||||
fprintf(fp," %s%s // %s\n", register_encode, comma, reg_def->_regname);
|
||||
} else {
|
||||
// Output known constants in hex char format (backward compatibility).
|
||||
assert(encval < 256, "Exceeded supported width for register encoding");
|
||||
fprintf(fp," (unsigned char)'\\x%X'%s // %s\n",
|
||||
encval, comma, reg_def->_regname );
|
||||
fprintf(fp," (unsigned char)'\\x%X'%s // %s\n", encval, comma, reg_def->_regname);
|
||||
}
|
||||
}
|
||||
// Finish defining enumeration
|
||||
@ -133,9 +130,10 @@ static void defineRegClassEnum(FILE *fp, RegisterForm *registers) {
|
||||
fprintf(fp,"// Enumeration of register class names\n");
|
||||
fprintf(fp, "enum machRegisterClass {\n");
|
||||
registers->_rclasses.reset();
|
||||
for( const char *class_name = NULL;
|
||||
(class_name = registers->_rclasses.iter()) != NULL; ) {
|
||||
fprintf(fp," %s,\n", toUpper( class_name ));
|
||||
for (const char *class_name = NULL; (class_name = registers->_rclasses.iter()) != NULL;) {
|
||||
const char * class_name_to_upper = toUpper(class_name);
|
||||
fprintf(fp," %s,\n", class_name_to_upper);
|
||||
delete[] class_name_to_upper;
|
||||
}
|
||||
// Finish defining enumeration
|
||||
fprintf(fp, " _last_Mach_Reg_Class\n");
|
||||
@ -148,7 +146,7 @@ static void defineRegClassEnum(FILE *fp, RegisterForm *registers) {
|
||||
void ArchDesc::declare_register_masks(FILE *fp_hpp) {
|
||||
const char *rc_name;
|
||||
|
||||
if( _register ) {
|
||||
if (_register) {
|
||||
// Build enumeration of user-defined register classes.
|
||||
defineRegClassEnum(fp_hpp, _register);
|
||||
|
||||
@ -156,24 +154,27 @@ void ArchDesc::declare_register_masks(FILE *fp_hpp) {
|
||||
fprintf(fp_hpp,"\n");
|
||||
fprintf(fp_hpp,"// Register masks, one for each register class.\n");
|
||||
_register->_rclasses.reset();
|
||||
for( rc_name = NULL;
|
||||
(rc_name = _register->_rclasses.iter()) != NULL; ) {
|
||||
const char *prefix = "";
|
||||
RegClass *reg_class = _register->getRegClass(rc_name);
|
||||
assert( reg_class, "Using an undefined register class");
|
||||
for (rc_name = NULL; (rc_name = _register->_rclasses.iter()) != NULL;) {
|
||||
const char *prefix = "";
|
||||
RegClass *reg_class = _register->getRegClass(rc_name);
|
||||
assert(reg_class, "Using an undefined register class");
|
||||
|
||||
const char* rc_name_to_upper = toUpper(rc_name);
|
||||
|
||||
if (reg_class->_user_defined == NULL) {
|
||||
fprintf(fp_hpp, "extern const RegMask _%s%s_mask;\n", prefix, toUpper( rc_name ) );
|
||||
fprintf(fp_hpp, "inline const RegMask &%s%s_mask() { return _%s%s_mask; }\n", prefix, toUpper( rc_name ), prefix, toUpper( rc_name ));
|
||||
fprintf(fp_hpp, "extern const RegMask _%s%s_mask;\n", prefix, rc_name_to_upper);
|
||||
fprintf(fp_hpp, "inline const RegMask &%s%s_mask() { return _%s%s_mask; }\n", prefix, rc_name_to_upper, prefix, rc_name_to_upper);
|
||||
} else {
|
||||
fprintf(fp_hpp, "inline const RegMask &%s%s_mask() { %s }\n", prefix, toUpper( rc_name ), reg_class->_user_defined);
|
||||
fprintf(fp_hpp, "inline const RegMask &%s%s_mask() { %s }\n", prefix, rc_name_to_upper, reg_class->_user_defined);
|
||||
}
|
||||
|
||||
if( reg_class->_stack_or_reg ) {
|
||||
if (reg_class->_stack_or_reg) {
|
||||
assert(reg_class->_user_defined == NULL, "no user defined reg class here");
|
||||
fprintf(fp_hpp, "extern const RegMask _%sSTACK_OR_%s_mask;\n", prefix, toUpper( rc_name ) );
|
||||
fprintf(fp_hpp, "inline const RegMask &%sSTACK_OR_%s_mask() { return _%sSTACK_OR_%s_mask; }\n", prefix, toUpper( rc_name ), prefix, toUpper( rc_name ) );
|
||||
fprintf(fp_hpp, "extern const RegMask _%sSTACK_OR_%s_mask;\n", prefix, rc_name_to_upper);
|
||||
fprintf(fp_hpp, "inline const RegMask &%sSTACK_OR_%s_mask() { return _%sSTACK_OR_%s_mask; }\n", prefix, rc_name_to_upper, prefix, rc_name_to_upper);
|
||||
}
|
||||
delete[] rc_name_to_upper;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -183,34 +184,41 @@ void ArchDesc::declare_register_masks(FILE *fp_hpp) {
|
||||
void ArchDesc::build_register_masks(FILE *fp_cpp) {
|
||||
const char *rc_name;
|
||||
|
||||
if( _register ) {
|
||||
if (_register) {
|
||||
// Generate a list of register masks, one for each class.
|
||||
fprintf(fp_cpp,"\n");
|
||||
fprintf(fp_cpp,"// Register masks, one for each register class.\n");
|
||||
_register->_rclasses.reset();
|
||||
for( rc_name = NULL;
|
||||
(rc_name = _register->_rclasses.iter()) != NULL; ) {
|
||||
const char *prefix = "";
|
||||
RegClass *reg_class = _register->getRegClass(rc_name);
|
||||
assert( reg_class, "Using an undefined register class");
|
||||
for (rc_name = NULL; (rc_name = _register->_rclasses.iter()) != NULL;) {
|
||||
const char *prefix = "";
|
||||
RegClass *reg_class = _register->getRegClass(rc_name);
|
||||
assert(reg_class, "Using an undefined register class");
|
||||
|
||||
if (reg_class->_user_defined != NULL) continue;
|
||||
if (reg_class->_user_defined != NULL) {
|
||||
continue;
|
||||
}
|
||||
|
||||
int len = RegisterForm::RegMask_Size();
|
||||
fprintf(fp_cpp, "const RegMask _%s%s_mask(", prefix, toUpper( rc_name ) );
|
||||
{ int i;
|
||||
for( i = 0; i < len-1; i++ )
|
||||
fprintf(fp_cpp," 0x%x,",reg_class->regs_in_word(i,false));
|
||||
fprintf(fp_cpp," 0x%x );\n",reg_class->regs_in_word(i,false));
|
||||
const char* rc_name_to_upper = toUpper(rc_name);
|
||||
fprintf(fp_cpp, "const RegMask _%s%s_mask(", prefix, rc_name_to_upper);
|
||||
|
||||
{
|
||||
int i;
|
||||
for(i = 0; i < len - 1; i++) {
|
||||
fprintf(fp_cpp," 0x%x,", reg_class->regs_in_word(i, false));
|
||||
}
|
||||
fprintf(fp_cpp," 0x%x );\n", reg_class->regs_in_word(i, false));
|
||||
}
|
||||
|
||||
if( reg_class->_stack_or_reg ) {
|
||||
if (reg_class->_stack_or_reg) {
|
||||
int i;
|
||||
fprintf(fp_cpp, "const RegMask _%sSTACK_OR_%s_mask(", prefix, toUpper( rc_name ) );
|
||||
for( i = 0; i < len-1; i++ )
|
||||
fprintf(fp_cpp," 0x%x,",reg_class->regs_in_word(i,true));
|
||||
fprintf(fp_cpp," 0x%x );\n",reg_class->regs_in_word(i,true));
|
||||
fprintf(fp_cpp, "const RegMask _%sSTACK_OR_%s_mask(", prefix, rc_name_to_upper);
|
||||
for(i = 0; i < len - 1; i++) {
|
||||
fprintf(fp_cpp," 0x%x,",reg_class->regs_in_word(i, true));
|
||||
}
|
||||
fprintf(fp_cpp," 0x%x );\n",reg_class->regs_in_word(i, true));
|
||||
}
|
||||
delete[] rc_name_to_upper;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -2676,7 +2684,9 @@ static void defineIn_RegMask(FILE *fp, FormDict &globals, OperandForm &oper) {
|
||||
if (strcmp(first_reg_class, "stack_slots") == 0) {
|
||||
fprintf(fp," return &(Compile::current()->FIRST_STACK_mask());\n");
|
||||
} else {
|
||||
fprintf(fp," return &%s_mask();\n", toUpper(first_reg_class));
|
||||
const char* first_reg_class_to_upper = toUpper(first_reg_class);
|
||||
fprintf(fp," return &%s_mask();\n", first_reg_class_to_upper);
|
||||
delete[] first_reg_class_to_upper;
|
||||
}
|
||||
} else {
|
||||
// Build a switch statement to return the desired mask.
|
||||
@ -2688,7 +2698,9 @@ static void defineIn_RegMask(FILE *fp, FormDict &globals, OperandForm &oper) {
|
||||
if( !strcmp(reg_class, "stack_slots") ) {
|
||||
fprintf(fp, " case %d: return &(Compile::current()->FIRST_STACK_mask());\n", index);
|
||||
} else {
|
||||
fprintf(fp, " case %d: return &%s_mask();\n", index, toUpper(reg_class));
|
||||
const char* reg_class_to_upper = toUpper(reg_class);
|
||||
fprintf(fp, " case %d: return &%s_mask();\n", index, reg_class_to_upper);
|
||||
delete[] reg_class_to_upper;
|
||||
}
|
||||
}
|
||||
fprintf(fp," }\n");
|
||||
|
@ -2069,9 +2069,21 @@ public:
|
||||
void closing() { fprintf(_cpp, " _LAST_MACH_OPER\n");
|
||||
OutputMap::closing();
|
||||
}
|
||||
void map(OpClassForm &opc) { fprintf(_cpp, " %s", _AD.machOperEnum(opc._ident) ); }
|
||||
void map(OperandForm &oper) { fprintf(_cpp, " %s", _AD.machOperEnum(oper._ident) ); }
|
||||
void map(char *name) { fprintf(_cpp, " %s", _AD.machOperEnum(name)); }
|
||||
void map(OpClassForm &opc) {
|
||||
const char* opc_ident_to_upper = _AD.machOperEnum(opc._ident);
|
||||
fprintf(_cpp, " %s", opc_ident_to_upper);
|
||||
delete[] opc_ident_to_upper;
|
||||
}
|
||||
void map(OperandForm &oper) {
|
||||
const char* oper_ident_to_upper = _AD.machOperEnum(oper._ident);
|
||||
fprintf(_cpp, " %s", oper_ident_to_upper);
|
||||
delete[] oper_ident_to_upper;
|
||||
}
|
||||
void map(char *name) {
|
||||
const char* name_to_upper = _AD.machOperEnum(name);
|
||||
fprintf(_cpp, " %s", name_to_upper);
|
||||
delete[] name_to_upper;
|
||||
}
|
||||
|
||||
bool do_instructions() { return false; }
|
||||
void map(InstructForm &inst){ assert( false, "ShouldNotCallThis()"); }
|
||||
|
@ -938,5 +938,7 @@ void Canonicalizer::do_ProfileCall(ProfileCall* x) {}
|
||||
void Canonicalizer::do_ProfileInvoke(ProfileInvoke* x) {}
|
||||
void Canonicalizer::do_RuntimeCall(RuntimeCall* x) {}
|
||||
void Canonicalizer::do_RangeCheckPredicate(RangeCheckPredicate* x) {}
|
||||
#ifdef ASSERT
|
||||
void Canonicalizer::do_Assert(Assert* x) {}
|
||||
#endif
|
||||
void Canonicalizer::do_MemBar(MemBar* x) {}
|
||||
|
@ -108,7 +108,9 @@ class Canonicalizer: InstructionVisitor {
|
||||
virtual void do_RuntimeCall (RuntimeCall* x);
|
||||
virtual void do_MemBar (MemBar* x);
|
||||
virtual void do_RangeCheckPredicate(RangeCheckPredicate* x);
|
||||
#ifdef ASSERT
|
||||
virtual void do_Assert (Assert* x);
|
||||
#endif
|
||||
};
|
||||
|
||||
#endif // SHARE_VM_C1_C1_CANONICALIZER_HPP
|
||||
|
@ -111,7 +111,9 @@ class ProfileInvoke;
|
||||
class RuntimeCall;
|
||||
class MemBar;
|
||||
class RangeCheckPredicate;
|
||||
#ifdef ASSERT
|
||||
class Assert;
|
||||
#endif
|
||||
|
||||
// A Value is a reference to the instruction creating the value
|
||||
typedef Instruction* Value;
|
||||
|
@ -871,12 +871,14 @@ void InstructionPrinter::do_RangeCheckPredicate(RangeCheckPredicate* x) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef ASSERT
|
||||
void InstructionPrinter::do_Assert(Assert* x) {
|
||||
output()->print("assert ");
|
||||
print_value(x->x());
|
||||
output()->print(" %s ", cond_name(x->cond()));
|
||||
print_value(x->y());
|
||||
}
|
||||
#endif
|
||||
|
||||
void InstructionPrinter::do_UnsafePrefetchWrite(UnsafePrefetchWrite* x) {
|
||||
print_unsafe_object_op(x, "UnsafePrefetchWrite");
|
||||
|
@ -136,7 +136,9 @@ class InstructionPrinter: public InstructionVisitor {
|
||||
virtual void do_RuntimeCall (RuntimeCall* x);
|
||||
virtual void do_MemBar (MemBar* x);
|
||||
virtual void do_RangeCheckPredicate(RangeCheckPredicate* x);
|
||||
#ifdef ASSERT
|
||||
virtual void do_Assert (Assert* x);
|
||||
#endif
|
||||
};
|
||||
#endif // PRODUCT
|
||||
|
||||
|
@ -1778,7 +1778,9 @@ const char * LIR_Op::name() const {
|
||||
// LIR_OpProfileCall
|
||||
case lir_profile_call: s = "profile_call"; break;
|
||||
// LIR_OpAssert
|
||||
#ifdef ASSERT
|
||||
case lir_assert: s = "assert"; break;
|
||||
#endif
|
||||
case lir_none: ShouldNotReachHere();break;
|
||||
default: s = "illegal_op"; break;
|
||||
}
|
||||
@ -2025,12 +2027,14 @@ void LIR_OpLock::print_instr(outputStream* out) const {
|
||||
out->print("[lbl:0x%x]", stub()->entry());
|
||||
}
|
||||
|
||||
#ifdef ASSERT
|
||||
void LIR_OpAssert::print_instr(outputStream* out) const {
|
||||
print_condition(out, condition()); out->print(" ");
|
||||
in_opr1()->print(out); out->print(" ");
|
||||
in_opr2()->print(out); out->print(", \"");
|
||||
out->print(msg()); out->print("\"");
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
void LIR_OpDelay::print_instr(outputStream* out) const {
|
||||
|
@ -881,8 +881,9 @@ class LIR_OpLock;
|
||||
class LIR_OpTypeCheck;
|
||||
class LIR_OpCompareAndSwap;
|
||||
class LIR_OpProfileCall;
|
||||
#ifdef ASSERT
|
||||
class LIR_OpAssert;
|
||||
|
||||
#endif
|
||||
|
||||
// LIR operation codes
|
||||
enum LIR_Code {
|
||||
@ -1139,7 +1140,9 @@ class LIR_Op: public CompilationResourceObj {
|
||||
virtual LIR_OpTypeCheck* as_OpTypeCheck() { return NULL; }
|
||||
virtual LIR_OpCompareAndSwap* as_OpCompareAndSwap() { return NULL; }
|
||||
virtual LIR_OpProfileCall* as_OpProfileCall() { return NULL; }
|
||||
#ifdef ASSERT
|
||||
virtual LIR_OpAssert* as_OpAssert() { return NULL; }
|
||||
#endif
|
||||
|
||||
virtual void verify() const {}
|
||||
};
|
||||
|
@ -711,25 +711,6 @@ static ciArrayKlass* as_array_klass(ciType* type) {
|
||||
}
|
||||
}
|
||||
|
||||
static Value maxvalue(IfOp* ifop) {
|
||||
switch (ifop->cond()) {
|
||||
case If::eql: return NULL;
|
||||
case If::neq: return NULL;
|
||||
case If::lss: // x < y ? x : y
|
||||
case If::leq: // x <= y ? x : y
|
||||
if (ifop->x() == ifop->tval() &&
|
||||
ifop->y() == ifop->fval()) return ifop->y();
|
||||
return NULL;
|
||||
|
||||
case If::gtr: // x > y ? y : x
|
||||
case If::geq: // x >= y ? y : x
|
||||
if (ifop->x() == ifop->tval() &&
|
||||
ifop->y() == ifop->fval()) return ifop->y();
|
||||
return NULL;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
static ciType* phi_declared_type(Phi* phi) {
|
||||
ciType* t = phi->operand_at(0)->declared_type();
|
||||
if (t == NULL) {
|
||||
@ -3123,8 +3104,8 @@ void LIRGenerator::do_RuntimeCall(RuntimeCall* x) {
|
||||
}
|
||||
}
|
||||
|
||||
void LIRGenerator::do_Assert(Assert *x) {
|
||||
#ifdef ASSERT
|
||||
void LIRGenerator::do_Assert(Assert *x) {
|
||||
ValueTag tag = x->x()->type()->tag();
|
||||
If::Condition cond = x->cond();
|
||||
|
||||
@ -3144,9 +3125,8 @@ void LIRGenerator::do_Assert(Assert *x) {
|
||||
LIR_Opr right = yin->result();
|
||||
|
||||
__ lir_assert(lir_cond(x->cond()), left, right, x->message(), true);
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
void LIRGenerator::do_RangeCheckPredicate(RangeCheckPredicate *x) {
|
||||
|
||||
|
@ -537,7 +537,9 @@ class LIRGenerator: public InstructionVisitor, public BlockClosure {
|
||||
virtual void do_RuntimeCall (RuntimeCall* x);
|
||||
virtual void do_MemBar (MemBar* x);
|
||||
virtual void do_RangeCheckPredicate(RangeCheckPredicate* x);
|
||||
#ifdef ASSERT
|
||||
virtual void do_Assert (Assert* x);
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
|
@ -535,7 +535,9 @@ public:
|
||||
void do_RuntimeCall (RuntimeCall* x);
|
||||
void do_MemBar (MemBar* x);
|
||||
void do_RangeCheckPredicate(RangeCheckPredicate* x);
|
||||
#ifdef ASSERT
|
||||
void do_Assert (Assert* x);
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
@ -718,8 +720,9 @@ void NullCheckVisitor::do_ProfileInvoke (ProfileInvoke* x) {}
|
||||
void NullCheckVisitor::do_RuntimeCall (RuntimeCall* x) {}
|
||||
void NullCheckVisitor::do_MemBar (MemBar* x) {}
|
||||
void NullCheckVisitor::do_RangeCheckPredicate(RangeCheckPredicate* x) {}
|
||||
#ifdef ASSERT
|
||||
void NullCheckVisitor::do_Assert (Assert* x) {}
|
||||
|
||||
#endif
|
||||
|
||||
void NullCheckEliminator::visit(Value* p) {
|
||||
assert(*p != NULL, "should not find NULL instructions");
|
||||
|
@ -166,7 +166,9 @@ public:
|
||||
void do_RuntimeCall (RuntimeCall* x) { /* nothing to do */ };
|
||||
void do_MemBar (MemBar* x) { /* nothing to do */ };
|
||||
void do_RangeCheckPredicate(RangeCheckPredicate* x) { /* nothing to do */ };
|
||||
#ifdef ASSERT
|
||||
void do_Assert (Assert* x) { /* nothing to do */ };
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifdef ASSERT
|
||||
|
@ -316,6 +316,7 @@ class LoopInvariantCodeMotion : public StackObj {
|
||||
ShortLoopOptimizer* _short_loop_optimizer;
|
||||
Instruction* _insertion_point;
|
||||
ValueStack * _state;
|
||||
bool _insert_is_pred;
|
||||
|
||||
void set_invariant(Value v) const { _gvn->set_processed(v); }
|
||||
bool is_invariant(Value v) const { return _gvn->is_processed(v); }
|
||||
@ -339,6 +340,7 @@ LoopInvariantCodeMotion::LoopInvariantCodeMotion(ShortLoopOptimizer *slo, Global
|
||||
|
||||
assert(insertion_block->end()->as_Base() == NULL, "cannot insert into entry block");
|
||||
_insertion_point = insertion_block->end()->prev();
|
||||
_insert_is_pred = loop_header->is_predecessor(insertion_block);
|
||||
|
||||
BlockEnd *block_end = insertion_block->end();
|
||||
_state = block_end->state_before();
|
||||
@ -379,13 +381,13 @@ void LoopInvariantCodeMotion::process_block(BlockBegin* block) {
|
||||
} else if (cur->as_LoadField() != NULL) {
|
||||
LoadField* lf = (LoadField*)cur;
|
||||
// deoptimizes on NullPointerException
|
||||
cur_invariant = !lf->needs_patching() && !lf->field()->is_volatile() && !_short_loop_optimizer->has_field_store(lf->field()->type()->basic_type()) && is_invariant(lf->obj());
|
||||
cur_invariant = !lf->needs_patching() && !lf->field()->is_volatile() && !_short_loop_optimizer->has_field_store(lf->field()->type()->basic_type()) && is_invariant(lf->obj()) && _insert_is_pred;
|
||||
} else if (cur->as_ArrayLength() != NULL) {
|
||||
ArrayLength *length = cur->as_ArrayLength();
|
||||
cur_invariant = is_invariant(length->array());
|
||||
} else if (cur->as_LoadIndexed() != NULL) {
|
||||
LoadIndexed *li = (LoadIndexed *)cur->as_LoadIndexed();
|
||||
cur_invariant = !_short_loop_optimizer->has_indexed_store(as_BasicType(cur->type())) && is_invariant(li->array()) && is_invariant(li->index());
|
||||
cur_invariant = !_short_loop_optimizer->has_indexed_store(as_BasicType(cur->type())) && is_invariant(li->array()) && is_invariant(li->index()) && _insert_is_pred;
|
||||
}
|
||||
|
||||
if (cur_invariant) {
|
||||
|
@ -207,7 +207,9 @@ class ValueNumberingVisitor: public InstructionVisitor {
|
||||
void do_RuntimeCall (RuntimeCall* x) { /* nothing to do */ };
|
||||
void do_MemBar (MemBar* x) { /* nothing to do */ };
|
||||
void do_RangeCheckPredicate(RangeCheckPredicate* x) { /* nothing to do */ };
|
||||
#ifdef ASSERT
|
||||
void do_Assert (Assert* x) { /* nothing to do */ };
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
|
@ -1723,9 +1723,6 @@ void ClassFileParser::parse_annotations(u1* buffer, int limit,
|
||||
} else {
|
||||
coll->set_contended_group(0); // default contended group
|
||||
}
|
||||
coll->set_contended(true);
|
||||
} else {
|
||||
coll->set_contended(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -150,7 +150,6 @@ class ClassFileParser VALUE_OBJ_CLASS_SPEC {
|
||||
void set_contended_group(u2 group) { _contended_group = group; }
|
||||
u2 contended_group() { return _contended_group; }
|
||||
|
||||
void set_contended(bool contended) { set_annotation(_sun_misc_Contended); }
|
||||
bool is_contended() { return has_annotation(_sun_misc_Contended); }
|
||||
};
|
||||
|
||||
|
@ -1274,13 +1274,16 @@ void ClassLoader::compile_the_world() {
|
||||
Handle system_class_loader (THREAD, SystemDictionary::java_system_loader());
|
||||
// Iterate over all bootstrap class path entries
|
||||
ClassPathEntry* e = _first_entry;
|
||||
jlong start = os::javaTimeMillis();
|
||||
while (e != NULL) {
|
||||
// We stop at rt.jar, unless it is the first bootstrap path entry
|
||||
if (e->is_rt_jar() && e != _first_entry) break;
|
||||
e->compile_the_world(system_class_loader, CATCH);
|
||||
e = e->next();
|
||||
}
|
||||
tty->print_cr("CompileTheWorld : Done");
|
||||
jlong end = os::javaTimeMillis();
|
||||
tty->print_cr("CompileTheWorld : Done (%d classes, %d methods, %d ms)",
|
||||
_compile_the_world_class_counter, _compile_the_world_method_counter, (end - start));
|
||||
{
|
||||
// Print statistics as if before normal exit:
|
||||
extern void print_statistics();
|
||||
@ -1289,7 +1292,8 @@ void ClassLoader::compile_the_world() {
|
||||
vm_exit(0);
|
||||
}
|
||||
|
||||
int ClassLoader::_compile_the_world_counter = 0;
|
||||
int ClassLoader::_compile_the_world_class_counter = 0;
|
||||
int ClassLoader::_compile_the_world_method_counter = 0;
|
||||
static int _codecache_sweep_counter = 0;
|
||||
|
||||
// Filter out all exceptions except OOMs
|
||||
@ -1311,8 +1315,8 @@ void ClassLoader::compile_the_world_in(char* name, Handle loader, TRAPS) {
|
||||
// If the file has a period after removing .class, it's not really a
|
||||
// valid class file. The class loader will check everything else.
|
||||
if (strchr(buffer, '.') == NULL) {
|
||||
_compile_the_world_counter++;
|
||||
if (_compile_the_world_counter > CompileTheWorldStopAt) return;
|
||||
_compile_the_world_class_counter++;
|
||||
if (_compile_the_world_class_counter > CompileTheWorldStopAt) return;
|
||||
|
||||
// Construct name without extension
|
||||
TempNewSymbol sym = SymbolTable::new_symbol(buffer, CHECK);
|
||||
@ -1329,16 +1333,16 @@ void ClassLoader::compile_the_world_in(char* name, Handle loader, TRAPS) {
|
||||
if (HAS_PENDING_EXCEPTION) {
|
||||
// If something went wrong in preloading we just ignore it
|
||||
clear_pending_exception_if_not_oom(CHECK);
|
||||
tty->print_cr("Preloading failed for (%d) %s", _compile_the_world_counter, buffer);
|
||||
tty->print_cr("Preloading failed for (%d) %s", _compile_the_world_class_counter, buffer);
|
||||
}
|
||||
}
|
||||
|
||||
if (_compile_the_world_counter >= CompileTheWorldStartAt) {
|
||||
if (_compile_the_world_class_counter >= CompileTheWorldStartAt) {
|
||||
if (k.is_null() || exception_occurred) {
|
||||
// If something went wrong (e.g. ExceptionInInitializerError) we skip this class
|
||||
tty->print_cr("CompileTheWorld (%d) : Skipping %s", _compile_the_world_counter, buffer);
|
||||
tty->print_cr("CompileTheWorld (%d) : Skipping %s", _compile_the_world_class_counter, buffer);
|
||||
} else {
|
||||
tty->print_cr("CompileTheWorld (%d) : %s", _compile_the_world_counter, buffer);
|
||||
tty->print_cr("CompileTheWorld (%d) : %s", _compile_the_world_class_counter, buffer);
|
||||
// Preload all classes to get around uncommon traps
|
||||
// Iterate over all methods in class
|
||||
for (int n = 0; n < k->methods()->length(); n++) {
|
||||
@ -1356,7 +1360,9 @@ void ClassLoader::compile_the_world_in(char* name, Handle loader, TRAPS) {
|
||||
methodHandle(), 0, "CTW", THREAD);
|
||||
if (HAS_PENDING_EXCEPTION) {
|
||||
clear_pending_exception_if_not_oom(CHECK);
|
||||
tty->print_cr("CompileTheWorld (%d) : Skipping method: %s", _compile_the_world_counter, m->name()->as_C_string());
|
||||
tty->print_cr("CompileTheWorld (%d) : Skipping method: %s", _compile_the_world_class_counter, m->name()->as_C_string());
|
||||
} else {
|
||||
_compile_the_world_method_counter++;
|
||||
}
|
||||
if (TieredCompilation && TieredStopAtLevel >= CompLevel_full_optimization) {
|
||||
// Clobber the first compile and force second tier compilation
|
||||
@ -1370,7 +1376,9 @@ void ClassLoader::compile_the_world_in(char* name, Handle loader, TRAPS) {
|
||||
methodHandle(), 0, "CTW", THREAD);
|
||||
if (HAS_PENDING_EXCEPTION) {
|
||||
clear_pending_exception_if_not_oom(CHECK);
|
||||
tty->print_cr("CompileTheWorld (%d) : Skipping method: %s", _compile_the_world_counter, m->name()->as_C_string());
|
||||
tty->print_cr("CompileTheWorld (%d) : Skipping method: %s", _compile_the_world_class_counter, m->name()->as_C_string());
|
||||
} else {
|
||||
_compile_the_world_method_counter++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -340,11 +340,12 @@ class ClassLoader: AllStatic {
|
||||
// Force compilation of all methods in all classes in bootstrap class path (stress test)
|
||||
#ifndef PRODUCT
|
||||
private:
|
||||
static int _compile_the_world_counter;
|
||||
static int _compile_the_world_class_counter;
|
||||
static int _compile_the_world_method_counter;
|
||||
public:
|
||||
static void compile_the_world();
|
||||
static void compile_the_world_in(char* name, Handle loader, TRAPS);
|
||||
static int compile_the_world_counter() { return _compile_the_world_counter; }
|
||||
static int compile_the_world_counter() { return _compile_the_world_class_counter; }
|
||||
#endif //PRODUCT
|
||||
};
|
||||
|
||||
|
@ -70,15 +70,19 @@ ClassLoaderData::ClassLoaderData(Handle h_class_loader, bool is_anonymous) :
|
||||
_is_anonymous(is_anonymous), _keep_alive(is_anonymous), // initially
|
||||
_metaspace(NULL), _unloading(false), _klasses(NULL),
|
||||
_claimed(0), _jmethod_ids(NULL), _handles(NULL), _deallocate_list(NULL),
|
||||
_next(NULL), _dependencies(NULL),
|
||||
_next(NULL), _dependencies(),
|
||||
_metaspace_lock(new Mutex(Monitor::leaf+1, "Metaspace allocation lock", true)) {
|
||||
// empty
|
||||
}
|
||||
|
||||
void ClassLoaderData::init_dependencies(TRAPS) {
|
||||
_dependencies.init(CHECK);
|
||||
}
|
||||
|
||||
void ClassLoaderData::Dependencies::init(TRAPS) {
|
||||
// Create empty dependencies array to add to. CMS requires this to be
|
||||
// an oop so that it can track additions via card marks. We think.
|
||||
_dependencies = (oop)oopFactory::new_objectArray(2, CHECK);
|
||||
_list_head = oopFactory::new_objectArray(2, CHECK);
|
||||
}
|
||||
|
||||
bool ClassLoaderData::claim() {
|
||||
@ -95,13 +99,17 @@ void ClassLoaderData::oops_do(OopClosure* f, KlassClosure* klass_closure, bool m
|
||||
}
|
||||
|
||||
f->do_oop(&_class_loader);
|
||||
f->do_oop(&_dependencies);
|
||||
_dependencies.oops_do(f);
|
||||
_handles->oops_do(f);
|
||||
if (klass_closure != NULL) {
|
||||
classes_do(klass_closure);
|
||||
}
|
||||
}
|
||||
|
||||
void ClassLoaderData::Dependencies::oops_do(OopClosure* f) {
|
||||
f->do_oop((oop*)&_list_head);
|
||||
}
|
||||
|
||||
void ClassLoaderData::classes_do(KlassClosure* klass_closure) {
|
||||
for (Klass* k = _klasses; k != NULL; k = k->next_link()) {
|
||||
klass_closure->do_klass(k);
|
||||
@ -154,14 +162,14 @@ void ClassLoaderData::record_dependency(Klass* k, TRAPS) {
|
||||
// It's a dependency we won't find through GC, add it. This is relatively rare
|
||||
// Must handle over GC point.
|
||||
Handle dependency(THREAD, to);
|
||||
from_cld->add_dependency(dependency, CHECK);
|
||||
from_cld->_dependencies.add(dependency, CHECK);
|
||||
}
|
||||
|
||||
|
||||
void ClassLoaderData::add_dependency(Handle dependency, TRAPS) {
|
||||
void ClassLoaderData::Dependencies::add(Handle dependency, TRAPS) {
|
||||
// Check first if this dependency is already in the list.
|
||||
// Save a pointer to the last to add to under the lock.
|
||||
objArrayOop ok = (objArrayOop)_dependencies;
|
||||
objArrayOop ok = _list_head;
|
||||
objArrayOop last = NULL;
|
||||
while (ok != NULL) {
|
||||
last = ok;
|
||||
@ -184,16 +192,17 @@ void ClassLoaderData::add_dependency(Handle dependency, TRAPS) {
|
||||
objArrayHandle new_dependency(THREAD, deps);
|
||||
|
||||
// Add the dependency under lock
|
||||
locked_add_dependency(last_handle, new_dependency);
|
||||
locked_add(last_handle, new_dependency, THREAD);
|
||||
}
|
||||
|
||||
void ClassLoaderData::locked_add_dependency(objArrayHandle last_handle,
|
||||
objArrayHandle new_dependency) {
|
||||
void ClassLoaderData::Dependencies::locked_add(objArrayHandle last_handle,
|
||||
objArrayHandle new_dependency,
|
||||
Thread* THREAD) {
|
||||
|
||||
// Have to lock and put the new dependency on the end of the dependency
|
||||
// array so the card mark for CMS sees that this dependency is new.
|
||||
// Can probably do this lock free with some effort.
|
||||
MutexLockerEx ml(metaspace_lock(), Mutex::_no_safepoint_check_flag);
|
||||
ObjectLocker ol(Handle(THREAD, _list_head), THREAD);
|
||||
|
||||
oop loader_or_mirror = new_dependency->obj_at(0);
|
||||
|
||||
|
@ -93,6 +93,18 @@ class ClassLoaderDataGraph : public AllStatic {
|
||||
class ClassLoaderData : public CHeapObj<mtClass> {
|
||||
friend class VMStructs;
|
||||
private:
|
||||
class Dependencies VALUE_OBJ_CLASS_SPEC {
|
||||
objArrayOop _list_head;
|
||||
void locked_add(objArrayHandle last,
|
||||
objArrayHandle new_dependency,
|
||||
Thread* THREAD);
|
||||
public:
|
||||
Dependencies() : _list_head(NULL) {}
|
||||
void add(Handle dependency, TRAPS);
|
||||
void init(TRAPS);
|
||||
void oops_do(OopClosure* f);
|
||||
};
|
||||
|
||||
friend class ClassLoaderDataGraph;
|
||||
friend class ClassLoaderDataGraphMetaspaceIterator;
|
||||
friend class MetaDataFactory;
|
||||
@ -100,10 +112,11 @@ class ClassLoaderData : public CHeapObj<mtClass> {
|
||||
|
||||
static ClassLoaderData * _the_null_class_loader_data;
|
||||
|
||||
oop _class_loader; // oop used to uniquely identify a class loader
|
||||
// class loader or a canonical class path
|
||||
oop _dependencies; // oop to hold dependencies from this class loader
|
||||
// data to others.
|
||||
oop _class_loader; // oop used to uniquely identify a class loader
|
||||
// class loader or a canonical class path
|
||||
Dependencies _dependencies; // holds dependencies from this class loader
|
||||
// data to others.
|
||||
|
||||
Metaspace * _metaspace; // Meta-space where meta-data defined by the
|
||||
// classes in the class loader are allocated.
|
||||
Mutex* _metaspace_lock; // Locks the metaspace for allocations and setup.
|
||||
@ -134,9 +147,6 @@ class ClassLoaderData : public CHeapObj<mtClass> {
|
||||
static Metaspace* _ro_metaspace;
|
||||
static Metaspace* _rw_metaspace;
|
||||
|
||||
void add_dependency(Handle dependency, TRAPS);
|
||||
void locked_add_dependency(objArrayHandle last, objArrayHandle new_dependency);
|
||||
|
||||
void set_next(ClassLoaderData* next) { _next = next; }
|
||||
ClassLoaderData* next() const { return _next; }
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -175,14 +175,14 @@ class StackMapFrame : public ResourceObj {
|
||||
ErrorContext* ctx, TRAPS) const;
|
||||
|
||||
inline void set_mark() {
|
||||
#ifdef DEBUG
|
||||
#ifdef ASSERT
|
||||
// Put bogus type to indicate it's no longer valid.
|
||||
if (_stack_mark != -1) {
|
||||
for (int i = _stack_mark - 1; i >= _stack_size; --i) {
|
||||
_stack[i] = VerificationType::bogus_type();
|
||||
}
|
||||
}
|
||||
#endif // def DEBUG
|
||||
#endif // def ASSERT
|
||||
_stack_mark = _stack_size;
|
||||
}
|
||||
|
||||
|
@ -1592,9 +1592,10 @@ Symbol* SystemDictionary::find_placeholder(Symbol* class_name,
|
||||
// Used for assertions and verification only
|
||||
Klass* SystemDictionary::find_class(Symbol* class_name, ClassLoaderData* loader_data) {
|
||||
#ifndef ASSERT
|
||||
guarantee(VerifyBeforeGC ||
|
||||
VerifyDuringGC ||
|
||||
VerifyBeforeExit ||
|
||||
guarantee(VerifyBeforeGC ||
|
||||
VerifyDuringGC ||
|
||||
VerifyBeforeExit ||
|
||||
VerifyDuringStartup ||
|
||||
VerifyAfterGC, "too expensive");
|
||||
#endif
|
||||
assert_locked_or_safepoint(SystemDictionary_lock);
|
||||
|
@ -63,6 +63,7 @@
|
||||
|
||||
#define NOFAILOVER_MAJOR_VERSION 51
|
||||
#define NONZERO_PADDING_BYTES_IN_SWITCH_MAJOR_VERSION 51
|
||||
#define STATIC_METHOD_IN_INTERFACE_MAJOR_VERSION 52
|
||||
|
||||
// Access to external entry for VerifyClassCodes - old byte code verifier
|
||||
|
||||
@ -2320,6 +2321,11 @@ void ClassVerifier::verify_invoke_instructions(
|
||||
types = (1 << JVM_CONSTANT_InterfaceMethodref) |
|
||||
(1 << JVM_CONSTANT_Methodref);
|
||||
break;
|
||||
case Bytecodes::_invokestatic:
|
||||
types = (_klass->major_version() < STATIC_METHOD_IN_INTERFACE_MAJOR_VERSION) ?
|
||||
(1 << JVM_CONSTANT_Methodref) :
|
||||
((1 << JVM_CONSTANT_InterfaceMethodref) | (1 << JVM_CONSTANT_Methodref));
|
||||
break;
|
||||
default:
|
||||
types = 1 << JVM_CONSTANT_Methodref;
|
||||
}
|
||||
|
@ -348,14 +348,14 @@ RuntimeStub* RuntimeStub::new_runtime_stub(const char* stub_name,
|
||||
|
||||
|
||||
void* RuntimeStub::operator new(size_t s, unsigned size) {
|
||||
void* p = CodeCache::allocate(size);
|
||||
void* p = CodeCache::allocate(size, true);
|
||||
if (!p) fatal("Initial size of CodeCache is too small");
|
||||
return p;
|
||||
}
|
||||
|
||||
// operator new shared by all singletons:
|
||||
void* SingletonBlob::operator new(size_t s, unsigned size) {
|
||||
void* p = CodeCache::allocate(size);
|
||||
void* p = CodeCache::allocate(size, true);
|
||||
if (!p) fatal("Initial size of CodeCache is too small");
|
||||
return p;
|
||||
}
|
||||
|
@ -172,7 +172,7 @@ nmethod* CodeCache::next_nmethod (CodeBlob* cb) {
|
||||
|
||||
static size_t maxCodeCacheUsed = 0;
|
||||
|
||||
CodeBlob* CodeCache::allocate(int size) {
|
||||
CodeBlob* CodeCache::allocate(int size, bool is_critical) {
|
||||
// Do not seize the CodeCache lock here--if the caller has not
|
||||
// already done so, we are going to lose bigtime, since the code
|
||||
// cache will contain a garbage CodeBlob until the caller can
|
||||
@ -183,7 +183,7 @@ CodeBlob* CodeCache::allocate(int size) {
|
||||
CodeBlob* cb = NULL;
|
||||
_number_of_blobs++;
|
||||
while (true) {
|
||||
cb = (CodeBlob*)_heap->allocate(size);
|
||||
cb = (CodeBlob*)_heap->allocate(size, is_critical);
|
||||
if (cb != NULL) break;
|
||||
if (!_heap->expand_by(CodeCacheExpansionSize)) {
|
||||
// Expansion failed
|
||||
@ -192,8 +192,8 @@ CodeBlob* CodeCache::allocate(int size) {
|
||||
if (PrintCodeCacheExtension) {
|
||||
ResourceMark rm;
|
||||
tty->print_cr("code cache extended to [" INTPTR_FORMAT ", " INTPTR_FORMAT "] (%d bytes)",
|
||||
(intptr_t)_heap->begin(), (intptr_t)_heap->end(),
|
||||
(address)_heap->end() - (address)_heap->begin());
|
||||
(intptr_t)_heap->low_boundary(), (intptr_t)_heap->high(),
|
||||
(address)_heap->high() - (address)_heap->low_boundary());
|
||||
}
|
||||
}
|
||||
maxCodeCacheUsed = MAX2(maxCodeCacheUsed, ((address)_heap->high_boundary() -
|
||||
@ -608,13 +608,13 @@ void CodeCache::verify_oops() {
|
||||
|
||||
address CodeCache::first_address() {
|
||||
assert_locked_or_safepoint(CodeCache_lock);
|
||||
return (address)_heap->begin();
|
||||
return (address)_heap->low_boundary();
|
||||
}
|
||||
|
||||
|
||||
address CodeCache::last_address() {
|
||||
assert_locked_or_safepoint(CodeCache_lock);
|
||||
return (address)_heap->end();
|
||||
return (address)_heap->high();
|
||||
}
|
||||
|
||||
|
||||
@ -996,10 +996,9 @@ void CodeCache::print() {
|
||||
void CodeCache::print_summary(outputStream* st, bool detailed) {
|
||||
size_t total = (_heap->high_boundary() - _heap->low_boundary());
|
||||
st->print_cr("CodeCache: size=" SIZE_FORMAT "Kb used=" SIZE_FORMAT
|
||||
"Kb max_used=" SIZE_FORMAT "Kb free=" SIZE_FORMAT
|
||||
"Kb max_free_chunk=" SIZE_FORMAT "Kb",
|
||||
"Kb max_used=" SIZE_FORMAT "Kb free=" SIZE_FORMAT "Kb",
|
||||
total/K, (total - unallocated_capacity())/K,
|
||||
maxCodeCacheUsed/K, unallocated_capacity()/K, largest_free_block()/K);
|
||||
maxCodeCacheUsed/K, unallocated_capacity()/K);
|
||||
|
||||
if (detailed) {
|
||||
st->print_cr(" bounds [" INTPTR_FORMAT ", " INTPTR_FORMAT ", " INTPTR_FORMAT "]",
|
||||
@ -1018,19 +1017,8 @@ void CodeCache::print_summary(outputStream* st, bool detailed) {
|
||||
|
||||
void CodeCache::log_state(outputStream* st) {
|
||||
st->print(" total_blobs='" UINT32_FORMAT "' nmethods='" UINT32_FORMAT "'"
|
||||
" adapters='" UINT32_FORMAT "' free_code_cache='" SIZE_FORMAT "'"
|
||||
" largest_free_block='" SIZE_FORMAT "'",
|
||||
" adapters='" UINT32_FORMAT "' free_code_cache='" SIZE_FORMAT "'",
|
||||
nof_blobs(), nof_nmethods(), nof_adapters(),
|
||||
unallocated_capacity(), largest_free_block());
|
||||
unallocated_capacity());
|
||||
}
|
||||
|
||||
size_t CodeCache::largest_free_block() {
|
||||
// This is called both with and without CodeCache_lock held so
|
||||
// handle both cases.
|
||||
if (CodeCache_lock->owned_by_self()) {
|
||||
return _heap->largest_free_block();
|
||||
} else {
|
||||
MutexLockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag);
|
||||
return _heap->largest_free_block();
|
||||
}
|
||||
}
|
||||
|
@ -70,7 +70,7 @@ class CodeCache : AllStatic {
|
||||
static void initialize();
|
||||
|
||||
// Allocation/administration
|
||||
static CodeBlob* allocate(int size); // allocates a new CodeBlob
|
||||
static CodeBlob* allocate(int size, bool is_critical = false); // allocates a new CodeBlob
|
||||
static void commit(CodeBlob* cb); // called when the allocated CodeBlob has been filled
|
||||
static int alignment_unit(); // guaranteed alignment of all CodeBlobs
|
||||
static int alignment_offset(); // guaranteed offset of first CodeBlob byte within alignment unit (i.e., allocation header)
|
||||
@ -156,19 +156,13 @@ class CodeCache : AllStatic {
|
||||
static address low_bound() { return (address) _heap->low_boundary(); }
|
||||
static address high_bound() { return (address) _heap->high_boundary(); }
|
||||
|
||||
static bool has_space(int size) {
|
||||
// Always leave some room in the CodeCache for I2C/C2I adapters
|
||||
return largest_free_block() > (CodeCacheMinimumFreeSpace + size);
|
||||
}
|
||||
|
||||
// Profiling
|
||||
static address first_address(); // first address used for CodeBlobs
|
||||
static address last_address(); // last address used for CodeBlobs
|
||||
static size_t capacity() { return _heap->capacity(); }
|
||||
static size_t max_capacity() { return _heap->max_capacity(); }
|
||||
static size_t unallocated_capacity() { return _heap->unallocated_capacity(); }
|
||||
static size_t largest_free_block();
|
||||
static bool needs_flushing() { return largest_free_block() < CodeCacheFlushingMinimumFreeSpace; }
|
||||
static bool needs_flushing() { return unallocated_capacity() < CodeCacheFlushingMinimumFreeSpace; }
|
||||
|
||||
static bool needs_cache_clean() { return _needs_cache_clean; }
|
||||
static void set_needs_cache_clean(bool v) { _needs_cache_clean = v; }
|
||||
|
@ -501,18 +501,17 @@ nmethod* nmethod::new_native_nmethod(methodHandle method,
|
||||
{
|
||||
MutexLockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag);
|
||||
int native_nmethod_size = allocation_size(code_buffer, sizeof(nmethod));
|
||||
if (CodeCache::has_space(native_nmethod_size)) {
|
||||
CodeOffsets offsets;
|
||||
offsets.set_value(CodeOffsets::Verified_Entry, vep_offset);
|
||||
offsets.set_value(CodeOffsets::Frame_Complete, frame_complete);
|
||||
nm = new (native_nmethod_size) nmethod(method(), native_nmethod_size,
|
||||
compile_id, &offsets,
|
||||
code_buffer, frame_size,
|
||||
basic_lock_owner_sp_offset,
|
||||
basic_lock_sp_offset, oop_maps);
|
||||
NOT_PRODUCT(if (nm != NULL) nmethod_stats.note_native_nmethod(nm));
|
||||
if (PrintAssembly && nm != NULL)
|
||||
Disassembler::decode(nm);
|
||||
CodeOffsets offsets;
|
||||
offsets.set_value(CodeOffsets::Verified_Entry, vep_offset);
|
||||
offsets.set_value(CodeOffsets::Frame_Complete, frame_complete);
|
||||
nm = new (native_nmethod_size) nmethod(method(), native_nmethod_size,
|
||||
compile_id, &offsets,
|
||||
code_buffer, frame_size,
|
||||
basic_lock_owner_sp_offset,
|
||||
basic_lock_sp_offset, oop_maps);
|
||||
NOT_PRODUCT(if (nm != NULL) nmethod_stats.note_native_nmethod(nm));
|
||||
if (PrintAssembly && nm != NULL) {
|
||||
Disassembler::decode(nm);
|
||||
}
|
||||
}
|
||||
// verify nmethod
|
||||
@ -538,18 +537,17 @@ nmethod* nmethod::new_dtrace_nmethod(methodHandle method,
|
||||
{
|
||||
MutexLockerEx mu(CodeCache_lock, Mutex::_no_safepoint_check_flag);
|
||||
int nmethod_size = allocation_size(code_buffer, sizeof(nmethod));
|
||||
if (CodeCache::has_space(nmethod_size)) {
|
||||
CodeOffsets offsets;
|
||||
offsets.set_value(CodeOffsets::Verified_Entry, vep_offset);
|
||||
offsets.set_value(CodeOffsets::Dtrace_trap, trap_offset);
|
||||
offsets.set_value(CodeOffsets::Frame_Complete, frame_complete);
|
||||
CodeOffsets offsets;
|
||||
offsets.set_value(CodeOffsets::Verified_Entry, vep_offset);
|
||||
offsets.set_value(CodeOffsets::Dtrace_trap, trap_offset);
|
||||
offsets.set_value(CodeOffsets::Frame_Complete, frame_complete);
|
||||
|
||||
nm = new (nmethod_size) nmethod(method(), nmethod_size,
|
||||
&offsets, code_buffer, frame_size);
|
||||
nm = new (nmethod_size) nmethod(method(), nmethod_size,
|
||||
&offsets, code_buffer, frame_size);
|
||||
|
||||
NOT_PRODUCT(if (nm != NULL) nmethod_stats.note_nmethod(nm));
|
||||
if (PrintAssembly && nm != NULL)
|
||||
Disassembler::decode(nm);
|
||||
NOT_PRODUCT(if (nm != NULL) nmethod_stats.note_nmethod(nm));
|
||||
if (PrintAssembly && nm != NULL) {
|
||||
Disassembler::decode(nm);
|
||||
}
|
||||
}
|
||||
// verify nmethod
|
||||
@ -591,16 +589,16 @@ nmethod* nmethod::new_nmethod(methodHandle method,
|
||||
+ round_to(handler_table->size_in_bytes(), oopSize)
|
||||
+ round_to(nul_chk_table->size_in_bytes(), oopSize)
|
||||
+ round_to(debug_info->data_size() , oopSize);
|
||||
if (CodeCache::has_space(nmethod_size)) {
|
||||
nm = new (nmethod_size)
|
||||
nmethod(method(), nmethod_size, compile_id, entry_bci, offsets,
|
||||
orig_pc_offset, debug_info, dependencies, code_buffer, frame_size,
|
||||
oop_maps,
|
||||
handler_table,
|
||||
nul_chk_table,
|
||||
compiler,
|
||||
comp_level);
|
||||
}
|
||||
|
||||
nm = new (nmethod_size)
|
||||
nmethod(method(), nmethod_size, compile_id, entry_bci, offsets,
|
||||
orig_pc_offset, debug_info, dependencies, code_buffer, frame_size,
|
||||
oop_maps,
|
||||
handler_table,
|
||||
nul_chk_table,
|
||||
compiler,
|
||||
comp_level);
|
||||
|
||||
if (nm != NULL) {
|
||||
// To make dependency checking during class loading fast, record
|
||||
// the nmethod dependencies in the classes it is dependent on.
|
||||
@ -612,15 +610,18 @@ nmethod* nmethod::new_nmethod(methodHandle method,
|
||||
// classes the slow way is too slow.
|
||||
for (Dependencies::DepStream deps(nm); deps.next(); ) {
|
||||
Klass* klass = deps.context_type();
|
||||
if (klass == NULL) continue; // ignore things like evol_method
|
||||
if (klass == NULL) {
|
||||
continue; // ignore things like evol_method
|
||||
}
|
||||
|
||||
// record this nmethod as dependent on this klass
|
||||
InstanceKlass::cast(klass)->add_dependent_nmethod(nm);
|
||||
}
|
||||
}
|
||||
NOT_PRODUCT(if (nm != NULL) nmethod_stats.note_nmethod(nm));
|
||||
if (PrintAssembly && nm != NULL)
|
||||
if (PrintAssembly && nm != NULL) {
|
||||
Disassembler::decode(nm);
|
||||
}
|
||||
}
|
||||
|
||||
// verify nmethod
|
||||
@ -798,13 +799,11 @@ nmethod::nmethod(
|
||||
}
|
||||
#endif // def HAVE_DTRACE_H
|
||||
|
||||
void* nmethod::operator new(size_t size, int nmethod_size) {
|
||||
void* alloc = CodeCache::allocate(nmethod_size);
|
||||
guarantee(alloc != NULL, "CodeCache should have enough space");
|
||||
return alloc;
|
||||
void* nmethod::operator new(size_t size, int nmethod_size) throw () {
|
||||
// Not critical, may return null if there is too little continuous memory
|
||||
return CodeCache::allocate(nmethod_size);
|
||||
}
|
||||
|
||||
|
||||
nmethod::nmethod(
|
||||
Method* method,
|
||||
int nmethod_size,
|
||||
|
@ -1206,11 +1206,8 @@ nmethod* CompileBroker::compile_method(methodHandle method, int osr_bci,
|
||||
assert(osr_bci == InvocationEntryBci || (0 <= osr_bci && osr_bci < method->code_size()), "bci out of range");
|
||||
assert(!method->is_abstract() && (osr_bci == InvocationEntryBci || !method->is_native()), "cannot compile abstract/native methods");
|
||||
assert(!method->method_holder()->is_not_initialized(), "method holder must be initialized");
|
||||
|
||||
if (!TieredCompilation) {
|
||||
comp_level = CompLevel_highest_tier;
|
||||
}
|
||||
|
||||
// allow any levels for WhiteBox
|
||||
assert(WhiteBoxAPI || TieredCompilation || comp_level == CompLevel_highest_tier, "only CompLevel_highest_tier must be used in non-tiered");
|
||||
// return quickly if possible
|
||||
|
||||
// lock, make sure that the compilation
|
||||
@ -1584,7 +1581,7 @@ void CompileBroker::compiler_thread_loop() {
|
||||
// We need this HandleMark to avoid leaking VM handles.
|
||||
HandleMark hm(thread);
|
||||
|
||||
if (CodeCache::largest_free_block() < CodeCacheMinimumFreeSpace) {
|
||||
if (CodeCache::unallocated_capacity() < CodeCacheMinimumFreeSpace) {
|
||||
// the code cache is really full
|
||||
handle_full_code_cache();
|
||||
} else if (UseCodeCacheFlushing && CodeCache::needs_flushing()) {
|
||||
|
@ -60,28 +60,6 @@ CompileLog::~CompileLog() {
|
||||
}
|
||||
|
||||
|
||||
// Advance kind up to a null or space, return this tail.
|
||||
// Make sure kind is null-terminated, not space-terminated.
|
||||
// Use the buffer if necessary.
|
||||
static const char* split_attrs(const char* &kind, char* buffer) {
|
||||
const char* attrs = strchr(kind, ' ');
|
||||
// Tease apart the first word from the rest:
|
||||
if (attrs == NULL) {
|
||||
return ""; // no attrs, no split
|
||||
} else if (kind == buffer) {
|
||||
((char*) attrs)[-1] = 0;
|
||||
return attrs;
|
||||
} else {
|
||||
// park it in the buffer, so we can put a null on the end
|
||||
assert(!(kind >= buffer && kind < buffer+100), "not obviously in buffer");
|
||||
int klen = attrs - kind;
|
||||
strncpy(buffer, kind, klen);
|
||||
buffer[klen] = 0;
|
||||
kind = buffer; // return by reference
|
||||
return attrs;
|
||||
}
|
||||
}
|
||||
|
||||
// see_tag, pop_tag: Override the default do-nothing methods on xmlStream.
|
||||
// These methods provide a hook for managing the the extra context markup.
|
||||
void CompileLog::see_tag(const char* tag, bool push) {
|
||||
|
@ -237,13 +237,6 @@ static const char * command_names[] = {
|
||||
"help"
|
||||
};
|
||||
|
||||
static const char * command_name(OracleCommand command) {
|
||||
if (command < OracleFirstCommand || command >= OracleCommandCount) {
|
||||
return "unknown command";
|
||||
}
|
||||
return command_names[command];
|
||||
}
|
||||
|
||||
class MethodMatcher;
|
||||
static MethodMatcher* lists[OracleCommandCount] = { 0, };
|
||||
|
||||
|
@ -48,6 +48,7 @@
|
||||
#include "memory/iterator.hpp"
|
||||
#include "memory/referencePolicy.hpp"
|
||||
#include "memory/resourceArea.hpp"
|
||||
#include "memory/tenuredGeneration.hpp"
|
||||
#include "oops/oop.inline.hpp"
|
||||
#include "prims/jvmtiExport.hpp"
|
||||
#include "runtime/globals_extension.hpp"
|
||||
@ -916,7 +917,31 @@ void ConcurrentMarkSweepGeneration::compute_new_size() {
|
||||
return;
|
||||
}
|
||||
|
||||
size_t expand_bytes = 0;
|
||||
// Compute some numbers about the state of the heap.
|
||||
const size_t used_after_gc = used();
|
||||
const size_t capacity_after_gc = capacity();
|
||||
|
||||
CardGeneration::compute_new_size();
|
||||
|
||||
// Reset again after a possible resizing
|
||||
cmsSpace()->reset_after_compaction();
|
||||
|
||||
assert(used() == used_after_gc && used_after_gc <= capacity(),
|
||||
err_msg("used: " SIZE_FORMAT " used_after_gc: " SIZE_FORMAT
|
||||
" capacity: " SIZE_FORMAT, used(), used_after_gc, capacity()));
|
||||
}
|
||||
|
||||
void ConcurrentMarkSweepGeneration::compute_new_size_free_list() {
|
||||
assert_locked_or_safepoint(Heap_lock);
|
||||
|
||||
// If incremental collection failed, we just want to expand
|
||||
// to the limit.
|
||||
if (incremental_collection_failed()) {
|
||||
clear_incremental_collection_failed();
|
||||
grow_to_reserved();
|
||||
return;
|
||||
}
|
||||
|
||||
double free_percentage = ((double) free()) / capacity();
|
||||
double desired_free_percentage = (double) MinHeapFreeRatio / 100;
|
||||
double maximum_free_percentage = (double) MaxHeapFreeRatio / 100;
|
||||
@ -925,9 +950,7 @@ void ConcurrentMarkSweepGeneration::compute_new_size() {
|
||||
if (free_percentage < desired_free_percentage) {
|
||||
size_t desired_capacity = (size_t)(used() / ((double) 1 - desired_free_percentage));
|
||||
assert(desired_capacity >= capacity(), "invalid expansion size");
|
||||
expand_bytes = MAX2(desired_capacity - capacity(), MinHeapDeltaBytes);
|
||||
}
|
||||
if (expand_bytes > 0) {
|
||||
size_t expand_bytes = MAX2(desired_capacity - capacity(), MinHeapDeltaBytes);
|
||||
if (PrintGCDetails && Verbose) {
|
||||
size_t desired_capacity = (size_t)(used() / ((double) 1 - desired_free_percentage));
|
||||
gclog_or_tty->print_cr("\nFrom compute_new_size: ");
|
||||
@ -961,6 +984,14 @@ void ConcurrentMarkSweepGeneration::compute_new_size() {
|
||||
gclog_or_tty->print_cr(" Expanded free fraction %f",
|
||||
((double) free()) / capacity());
|
||||
}
|
||||
} else {
|
||||
size_t desired_capacity = (size_t)(used() / ((double) 1 - desired_free_percentage));
|
||||
assert(desired_capacity <= capacity(), "invalid expansion size");
|
||||
size_t shrink_bytes = capacity() - desired_capacity;
|
||||
// Don't shrink unless the delta is greater than the minimum shrink we want
|
||||
if (shrink_bytes >= MinHeapDeltaBytes) {
|
||||
shrink_free_list_by(shrink_bytes);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -1872,7 +1903,7 @@ void CMSCollector::compute_new_size() {
|
||||
assert_locked_or_safepoint(Heap_lock);
|
||||
FreelistLocker z(this);
|
||||
MetaspaceGC::compute_new_size();
|
||||
_cmsGen->compute_new_size();
|
||||
_cmsGen->compute_new_size_free_list();
|
||||
}
|
||||
|
||||
// A work method used by foreground collection to determine
|
||||
@ -2601,6 +2632,10 @@ void CMSCollector::gc_prologue(bool full) {
|
||||
}
|
||||
|
||||
void ConcurrentMarkSweepGeneration::gc_prologue(bool full) {
|
||||
|
||||
_capacity_at_prologue = capacity();
|
||||
_used_at_prologue = used();
|
||||
|
||||
// Delegate to CMScollector which knows how to coordinate between
|
||||
// this and any other CMS generations that it is responsible for
|
||||
// collecting.
|
||||
@ -2774,6 +2809,23 @@ bool CMSCollector::is_cms_reachable(HeapWord* addr) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
CMSCollector::print_on_error(outputStream* st) {
|
||||
CMSCollector* collector = ConcurrentMarkSweepGeneration::_collector;
|
||||
if (collector != NULL) {
|
||||
CMSBitMap* bitmap = &collector->_markBitMap;
|
||||
st->print_cr("Marking Bits: (CMSBitMap*) " PTR_FORMAT, bitmap);
|
||||
bitmap->print_on_error(st, " Bits: ");
|
||||
|
||||
st->cr();
|
||||
|
||||
CMSBitMap* mut_bitmap = &collector->_modUnionTable;
|
||||
st->print_cr("Mod Union Table: (CMSBitMap*) " PTR_FORMAT, mut_bitmap);
|
||||
mut_bitmap->print_on_error(st, " Bits: ");
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////
|
||||
// CMS Verification Support
|
||||
////////////////////////////////////////////////////////
|
||||
@ -3300,6 +3352,26 @@ bool ConcurrentMarkSweepGeneration::expand_and_ensure_spooling_space(
|
||||
}
|
||||
|
||||
|
||||
void ConcurrentMarkSweepGeneration::shrink_by(size_t bytes) {
|
||||
assert_locked_or_safepoint(ExpandHeap_lock);
|
||||
// Shrink committed space
|
||||
_virtual_space.shrink_by(bytes);
|
||||
// Shrink space; this also shrinks the space's BOT
|
||||
_cmsSpace->set_end((HeapWord*) _virtual_space.high());
|
||||
size_t new_word_size = heap_word_size(_cmsSpace->capacity());
|
||||
// Shrink the shared block offset array
|
||||
_bts->resize(new_word_size);
|
||||
MemRegion mr(_cmsSpace->bottom(), new_word_size);
|
||||
// Shrink the card table
|
||||
Universe::heap()->barrier_set()->resize_covered_region(mr);
|
||||
|
||||
if (Verbose && PrintGC) {
|
||||
size_t new_mem_size = _virtual_space.committed_size();
|
||||
size_t old_mem_size = new_mem_size + bytes;
|
||||
gclog_or_tty->print_cr("Shrinking %s from " SIZE_FORMAT "K to " SIZE_FORMAT "K",
|
||||
name(), old_mem_size/K, new_mem_size/K);
|
||||
}
|
||||
}
|
||||
|
||||
void ConcurrentMarkSweepGeneration::shrink(size_t bytes) {
|
||||
assert_locked_or_safepoint(Heap_lock);
|
||||
@ -3351,7 +3423,7 @@ bool ConcurrentMarkSweepGeneration::grow_to_reserved() {
|
||||
return success;
|
||||
}
|
||||
|
||||
void ConcurrentMarkSweepGeneration::shrink_by(size_t bytes) {
|
||||
void ConcurrentMarkSweepGeneration::shrink_free_list_by(size_t bytes) {
|
||||
assert_locked_or_safepoint(Heap_lock);
|
||||
assert_lock_strong(freelistLock());
|
||||
// XXX Fix when compaction is implemented.
|
||||
@ -6476,6 +6548,10 @@ void CMSBitMap::dirty_range_iterate_clear(MemRegion mr, MemRegionClosure* cl) {
|
||||
}
|
||||
}
|
||||
|
||||
void CMSBitMap::print_on_error(outputStream* st, const char* prefix) const {
|
||||
_bm.print_on_error(st, prefix);
|
||||
}
|
||||
|
||||
#ifndef PRODUCT
|
||||
void CMSBitMap::assert_locked() const {
|
||||
CMSLockVerifier::assert_locked(lock());
|
||||
@ -6845,7 +6921,7 @@ size_t ScanMarkedObjectsAgainCarefullyClosure::do_object_careful_m(
|
||||
size = CompactibleFreeListSpace::adjustObjectSize(
|
||||
p->oop_iterate(_scanningClosure));
|
||||
}
|
||||
#ifdef DEBUG
|
||||
#ifdef ASSERT
|
||||
size_t direct_size =
|
||||
CompactibleFreeListSpace::adjustObjectSize(p->size());
|
||||
assert(size == direct_size, "Inconsistency in size");
|
||||
@ -6857,7 +6933,7 @@ size_t ScanMarkedObjectsAgainCarefullyClosure::do_object_careful_m(
|
||||
assert(_bitMap->isMarked(addr+size-1),
|
||||
"inconsistent Printezis mark");
|
||||
}
|
||||
#endif // DEBUG
|
||||
#endif // ASSERT
|
||||
} else {
|
||||
// an unitialized object
|
||||
assert(_bitMap->isMarked(addr+1), "missing Printezis mark?");
|
||||
@ -6999,14 +7075,14 @@ bool ScanMarkedObjectsAgainClosure::do_object_bm(oop p, MemRegion mr) {
|
||||
HeapWord* addr = (HeapWord*)p;
|
||||
assert(_span.contains(addr), "we are scanning the CMS generation");
|
||||
bool is_obj_array = false;
|
||||
#ifdef DEBUG
|
||||
#ifdef ASSERT
|
||||
if (!_parallel) {
|
||||
assert(_mark_stack->isEmpty(), "pre-condition (eager drainage)");
|
||||
assert(_collector->overflow_list_is_empty(),
|
||||
"overflow list should be empty");
|
||||
|
||||
}
|
||||
#endif // DEBUG
|
||||
#endif // ASSERT
|
||||
if (_bit_map->isMarked(addr)) {
|
||||
// Obj arrays are precisely marked, non-arrays are not;
|
||||
// so we scan objArrays precisely and non-arrays in their
|
||||
@ -7026,14 +7102,14 @@ bool ScanMarkedObjectsAgainClosure::do_object_bm(oop p, MemRegion mr) {
|
||||
}
|
||||
}
|
||||
}
|
||||
#ifdef DEBUG
|
||||
#ifdef ASSERT
|
||||
if (!_parallel) {
|
||||
assert(_mark_stack->isEmpty(), "post-condition (eager drainage)");
|
||||
assert(_collector->overflow_list_is_empty(),
|
||||
"overflow list should be empty");
|
||||
|
||||
}
|
||||
#endif // DEBUG
|
||||
#endif // ASSERT
|
||||
return is_obj_array;
|
||||
}
|
||||
|
||||
@ -8244,7 +8320,7 @@ size_t SweepClosure::do_live_chunk(FreeChunk* fc) {
|
||||
assert(size == CompactibleFreeListSpace::adjustObjectSize(size),
|
||||
"alignment problem");
|
||||
|
||||
#ifdef DEBUG
|
||||
#ifdef ASSERT
|
||||
if (oop(addr)->klass_or_null() != NULL) {
|
||||
// Ignore mark word because we are running concurrent with mutators
|
||||
assert(oop(addr)->is_oop(true), "live block should be an oop");
|
||||
@ -9074,51 +9150,6 @@ void ASConcurrentMarkSweepGeneration::update_counters(size_t used) {
|
||||
}
|
||||
}
|
||||
|
||||
// The desired expansion delta is computed so that:
|
||||
// . desired free percentage or greater is used
|
||||
void ASConcurrentMarkSweepGeneration::compute_new_size() {
|
||||
assert_locked_or_safepoint(Heap_lock);
|
||||
|
||||
GenCollectedHeap* gch = (GenCollectedHeap*) GenCollectedHeap::heap();
|
||||
|
||||
// If incremental collection failed, we just want to expand
|
||||
// to the limit.
|
||||
if (incremental_collection_failed()) {
|
||||
clear_incremental_collection_failed();
|
||||
grow_to_reserved();
|
||||
return;
|
||||
}
|
||||
|
||||
assert(UseAdaptiveSizePolicy, "Should be using adaptive sizing");
|
||||
|
||||
assert(gch->kind() == CollectedHeap::GenCollectedHeap,
|
||||
"Wrong type of heap");
|
||||
int prev_level = level() - 1;
|
||||
assert(prev_level >= 0, "The cms generation is the lowest generation");
|
||||
Generation* prev_gen = gch->get_gen(prev_level);
|
||||
assert(prev_gen->kind() == Generation::ASParNew,
|
||||
"Wrong type of young generation");
|
||||
ParNewGeneration* younger_gen = (ParNewGeneration*) prev_gen;
|
||||
size_t cur_eden = younger_gen->eden()->capacity();
|
||||
CMSAdaptiveSizePolicy* size_policy = cms_size_policy();
|
||||
size_t cur_promo = free();
|
||||
size_policy->compute_tenured_generation_free_space(cur_promo,
|
||||
max_available(),
|
||||
cur_eden);
|
||||
resize(cur_promo, size_policy->promo_size());
|
||||
|
||||
// Record the new size of the space in the cms generation
|
||||
// that is available for promotions. This is temporary.
|
||||
// It should be the desired promo size.
|
||||
size_policy->avg_cms_promo()->sample(free());
|
||||
size_policy->avg_old_live()->sample(used());
|
||||
|
||||
if (UsePerfData) {
|
||||
CMSGCAdaptivePolicyCounters* counters = gc_adaptive_policy_counters();
|
||||
counters->update_cms_capacity_counter(capacity());
|
||||
}
|
||||
}
|
||||
|
||||
void ASConcurrentMarkSweepGeneration::shrink_by(size_t desired_bytes) {
|
||||
assert_locked_or_safepoint(Heap_lock);
|
||||
assert_lock_strong(freelistLock());
|
||||
|
@ -60,6 +60,7 @@ class CompactibleFreeListSpace;
|
||||
class FreeChunk;
|
||||
class PromotionInfo;
|
||||
class ScanMarkedObjectsAgainCarefullyClosure;
|
||||
class TenuredGeneration;
|
||||
|
||||
// A generic CMS bit map. It's the basis for both the CMS marking bit map
|
||||
// as well as for the mod union table (in each case only a subset of the
|
||||
@ -150,6 +151,8 @@ class CMSBitMap VALUE_OBJ_CLASS_SPEC {
|
||||
size_t heapWordToOffset(HeapWord* addr) const;
|
||||
size_t heapWordDiffToOffsetDiff(size_t diff) const;
|
||||
|
||||
void print_on_error(outputStream* st, const char* prefix) const;
|
||||
|
||||
// debugging
|
||||
// is this address range covered by the bit-map?
|
||||
NOT_PRODUCT(
|
||||
@ -810,9 +813,6 @@ class CMSCollector: public CHeapObj<mtGC> {
|
||||
// used regions of each generation to limit the extent of sweep
|
||||
void save_sweep_limits();
|
||||
|
||||
// Resize the generations included in the collector.
|
||||
void compute_new_size();
|
||||
|
||||
// A work method used by foreground collection to determine
|
||||
// what type of collection (compacting or not, continuing or fresh)
|
||||
// it should do.
|
||||
@ -909,6 +909,9 @@ class CMSCollector: public CHeapObj<mtGC> {
|
||||
void releaseFreelistLocks() const;
|
||||
bool haveFreelistLocks() const;
|
||||
|
||||
// Adjust size of underlying generation
|
||||
void compute_new_size();
|
||||
|
||||
// GC prologue and epilogue
|
||||
void gc_prologue(bool full);
|
||||
void gc_epilogue(bool full);
|
||||
@ -983,6 +986,8 @@ class CMSCollector: public CHeapObj<mtGC> {
|
||||
CMSAdaptiveSizePolicy* size_policy();
|
||||
CMSGCAdaptivePolicyCounters* gc_adaptive_policy_counters();
|
||||
|
||||
static void print_on_error(outputStream* st);
|
||||
|
||||
// debugging
|
||||
void verify();
|
||||
bool verify_after_remark();
|
||||
@ -1082,7 +1087,7 @@ class ConcurrentMarkSweepGeneration: public CardGeneration {
|
||||
|
||||
protected:
|
||||
// Shrink generation by specified size (returns false if unable to shrink)
|
||||
virtual void shrink_by(size_t bytes);
|
||||
void shrink_free_list_by(size_t bytes);
|
||||
|
||||
// Update statistics for GC
|
||||
virtual void update_gc_stats(int level, bool full);
|
||||
@ -1233,6 +1238,7 @@ class ConcurrentMarkSweepGeneration: public CardGeneration {
|
||||
CMSExpansionCause::Cause cause);
|
||||
virtual bool expand(size_t bytes, size_t expand_bytes);
|
||||
void shrink(size_t bytes);
|
||||
void shrink_by(size_t bytes);
|
||||
HeapWord* expand_and_par_lab_allocate(CMSParGCThreadState* ps, size_t word_sz);
|
||||
bool expand_and_ensure_spooling_space(PromotionInfo* promo);
|
||||
|
||||
@ -1293,7 +1299,13 @@ class ConcurrentMarkSweepGeneration: public CardGeneration {
|
||||
bool must_be_youngest() const { return false; }
|
||||
bool must_be_oldest() const { return true; }
|
||||
|
||||
void compute_new_size();
|
||||
// Resize the generation after a compacting GC. The
|
||||
// generation can be treated as a contiguous space
|
||||
// after the compaction.
|
||||
virtual void compute_new_size();
|
||||
// Resize the generation after a non-compacting
|
||||
// collection.
|
||||
void compute_new_size_free_list();
|
||||
|
||||
CollectionTypes debug_collection_type() { return _debug_collection_type; }
|
||||
void rotate_debug_collection_type();
|
||||
@ -1315,7 +1327,6 @@ class ASConcurrentMarkSweepGeneration : public ConcurrentMarkSweepGeneration {
|
||||
virtual void shrink_by(size_t bytes);
|
||||
|
||||
public:
|
||||
virtual void compute_new_size();
|
||||
ASConcurrentMarkSweepGeneration(ReservedSpace rs, size_t initial_byte_size,
|
||||
int level, CardTableRS* ct,
|
||||
bool use_adaptive_freelists,
|
||||
|
@ -101,6 +101,10 @@ bool CMBitMapRO::covers(ReservedSpace heap_rs) const {
|
||||
}
|
||||
#endif
|
||||
|
||||
void CMBitMapRO::print_on_error(outputStream* st, const char* prefix) const {
|
||||
_bm.print_on_error(st, prefix);
|
||||
}
|
||||
|
||||
bool CMBitMap::allocate(ReservedSpace heap_rs) {
|
||||
_bmStartWord = (HeapWord*)(heap_rs.base());
|
||||
_bmWordSize = heap_rs.size()/HeapWordSize; // heap_rs.size() is in bytes
|
||||
@ -3277,6 +3281,13 @@ void ConcurrentMark::print_worker_threads_on(outputStream* st) const {
|
||||
}
|
||||
}
|
||||
|
||||
void ConcurrentMark::print_on_error(outputStream* st) const {
|
||||
st->print_cr("Marking Bits (Prev, Next): (CMBitMap*) " PTR_FORMAT ", (CMBitMap*) " PTR_FORMAT,
|
||||
_prevMarkBitMap, _nextMarkBitMap);
|
||||
_prevMarkBitMap->print_on_error(st, " Prev Bits: ");
|
||||
_nextMarkBitMap->print_on_error(st, " Next Bits: ");
|
||||
}
|
||||
|
||||
// We take a break if someone is trying to stop the world.
|
||||
bool ConcurrentMark::do_yield_check(uint worker_id) {
|
||||
if (should_yield()) {
|
||||
|
@ -113,6 +113,8 @@ class CMBitMapRO VALUE_OBJ_CLASS_SPEC {
|
||||
return res;
|
||||
}
|
||||
|
||||
void print_on_error(outputStream* st, const char* prefix) const;
|
||||
|
||||
// debugging
|
||||
NOT_PRODUCT(bool covers(ReservedSpace rs) const;)
|
||||
};
|
||||
@ -829,6 +831,8 @@ public:
|
||||
|
||||
void print_worker_threads_on(outputStream* st) const;
|
||||
|
||||
void print_on_error(outputStream* st) const;
|
||||
|
||||
// The following indicate whether a given verbose level has been
|
||||
// set. Notice that anything above stats is conditional to
|
||||
// _MARKING_VERBOSE_ having been set to 1
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -1322,234 +1322,240 @@ bool G1CollectedHeap::do_collection(bool explicit_gc,
|
||||
gclog_or_tty->date_stamp(G1Log::fine() && PrintGCDateStamps);
|
||||
TraceCPUTime tcpu(G1Log::finer(), true, gclog_or_tty);
|
||||
|
||||
TraceTime t(GCCauseString("Full GC", gc_cause()), G1Log::fine(), true, gclog_or_tty);
|
||||
TraceCollectorStats tcs(g1mm()->full_collection_counters());
|
||||
TraceMemoryManagerStats tms(true /* fullGC */, gc_cause());
|
||||
|
||||
double start = os::elapsedTime();
|
||||
g1_policy()->record_full_collection_start();
|
||||
|
||||
// Note: When we have a more flexible GC logging framework that
|
||||
// allows us to add optional attributes to a GC log record we
|
||||
// could consider timing and reporting how long we wait in the
|
||||
// following two methods.
|
||||
wait_while_free_regions_coming();
|
||||
// If we start the compaction before the CM threads finish
|
||||
// scanning the root regions we might trip them over as we'll
|
||||
// be moving objects / updating references. So let's wait until
|
||||
// they are done. By telling them to abort, they should complete
|
||||
// early.
|
||||
_cm->root_regions()->abort();
|
||||
_cm->root_regions()->wait_until_scan_finished();
|
||||
append_secondary_free_list_if_not_empty_with_lock();
|
||||
|
||||
gc_prologue(true);
|
||||
increment_total_collections(true /* full gc */);
|
||||
increment_old_marking_cycles_started();
|
||||
|
||||
size_t g1h_prev_used = used();
|
||||
assert(used() == recalculate_used(), "Should be equal");
|
||||
|
||||
verify_before_gc();
|
||||
|
||||
pre_full_gc_dump();
|
||||
|
||||
COMPILER2_PRESENT(DerivedPointerTable::clear());
|
||||
|
||||
// Disable discovery and empty the discovered lists
|
||||
// for the CM ref processor.
|
||||
ref_processor_cm()->disable_discovery();
|
||||
ref_processor_cm()->abandon_partial_discovery();
|
||||
ref_processor_cm()->verify_no_references_recorded();
|
||||
|
||||
// Abandon current iterations of concurrent marking and concurrent
|
||||
// refinement, if any are in progress. We have to do this before
|
||||
// wait_until_scan_finished() below.
|
||||
concurrent_mark()->abort();
|
||||
|
||||
// Make sure we'll choose a new allocation region afterwards.
|
||||
release_mutator_alloc_region();
|
||||
abandon_gc_alloc_regions();
|
||||
g1_rem_set()->cleanupHRRS();
|
||||
|
||||
// We should call this after we retire any currently active alloc
|
||||
// regions so that all the ALLOC / RETIRE events are generated
|
||||
// before the start GC event.
|
||||
_hr_printer.start_gc(true /* full */, (size_t) total_collections());
|
||||
|
||||
// We may have added regions to the current incremental collection
|
||||
// set between the last GC or pause and now. We need to clear the
|
||||
// incremental collection set and then start rebuilding it afresh
|
||||
// after this full GC.
|
||||
abandon_collection_set(g1_policy()->inc_cset_head());
|
||||
g1_policy()->clear_incremental_cset();
|
||||
g1_policy()->stop_incremental_cset_building();
|
||||
|
||||
tear_down_region_sets(false /* free_list_only */);
|
||||
g1_policy()->set_gcs_are_young(true);
|
||||
|
||||
// See the comments in g1CollectedHeap.hpp and
|
||||
// G1CollectedHeap::ref_processing_init() about
|
||||
// how reference processing currently works in G1.
|
||||
|
||||
// Temporarily make discovery by the STW ref processor single threaded (non-MT).
|
||||
ReferenceProcessorMTDiscoveryMutator stw_rp_disc_ser(ref_processor_stw(), false);
|
||||
|
||||
// Temporarily clear the STW ref processor's _is_alive_non_header field.
|
||||
ReferenceProcessorIsAliveMutator stw_rp_is_alive_null(ref_processor_stw(), NULL);
|
||||
|
||||
ref_processor_stw()->enable_discovery(true /*verify_disabled*/, true /*verify_no_refs*/);
|
||||
ref_processor_stw()->setup_policy(do_clear_all_soft_refs);
|
||||
|
||||
// Do collection work
|
||||
{
|
||||
HandleMark hm; // Discard invalid handles created during gc
|
||||
G1MarkSweep::invoke_at_safepoint(ref_processor_stw(), do_clear_all_soft_refs);
|
||||
}
|
||||
TraceTime t(GCCauseString("Full GC", gc_cause()), G1Log::fine(), true, gclog_or_tty);
|
||||
TraceCollectorStats tcs(g1mm()->full_collection_counters());
|
||||
TraceMemoryManagerStats tms(true /* fullGC */, gc_cause());
|
||||
|
||||
assert(free_regions() == 0, "we should not have added any free regions");
|
||||
rebuild_region_sets(false /* free_list_only */);
|
||||
double start = os::elapsedTime();
|
||||
g1_policy()->record_full_collection_start();
|
||||
|
||||
// Enqueue any discovered reference objects that have
|
||||
// not been removed from the discovered lists.
|
||||
ref_processor_stw()->enqueue_discovered_references();
|
||||
// Note: When we have a more flexible GC logging framework that
|
||||
// allows us to add optional attributes to a GC log record we
|
||||
// could consider timing and reporting how long we wait in the
|
||||
// following two methods.
|
||||
wait_while_free_regions_coming();
|
||||
// If we start the compaction before the CM threads finish
|
||||
// scanning the root regions we might trip them over as we'll
|
||||
// be moving objects / updating references. So let's wait until
|
||||
// they are done. By telling them to abort, they should complete
|
||||
// early.
|
||||
_cm->root_regions()->abort();
|
||||
_cm->root_regions()->wait_until_scan_finished();
|
||||
append_secondary_free_list_if_not_empty_with_lock();
|
||||
|
||||
COMPILER2_PRESENT(DerivedPointerTable::update_pointers());
|
||||
gc_prologue(true);
|
||||
increment_total_collections(true /* full gc */);
|
||||
increment_old_marking_cycles_started();
|
||||
|
||||
MemoryService::track_memory_usage();
|
||||
assert(used() == recalculate_used(), "Should be equal");
|
||||
|
||||
verify_after_gc();
|
||||
verify_before_gc();
|
||||
|
||||
assert(!ref_processor_stw()->discovery_enabled(), "Postcondition");
|
||||
ref_processor_stw()->verify_no_references_recorded();
|
||||
pre_full_gc_dump();
|
||||
|
||||
// Delete metaspaces for unloaded class loaders and clean up loader_data graph
|
||||
ClassLoaderDataGraph::purge();
|
||||
COMPILER2_PRESENT(DerivedPointerTable::clear());
|
||||
|
||||
// Note: since we've just done a full GC, concurrent
|
||||
// marking is no longer active. Therefore we need not
|
||||
// re-enable reference discovery for the CM ref processor.
|
||||
// That will be done at the start of the next marking cycle.
|
||||
assert(!ref_processor_cm()->discovery_enabled(), "Postcondition");
|
||||
ref_processor_cm()->verify_no_references_recorded();
|
||||
// Disable discovery and empty the discovered lists
|
||||
// for the CM ref processor.
|
||||
ref_processor_cm()->disable_discovery();
|
||||
ref_processor_cm()->abandon_partial_discovery();
|
||||
ref_processor_cm()->verify_no_references_recorded();
|
||||
|
||||
reset_gc_time_stamp();
|
||||
// Since everything potentially moved, we will clear all remembered
|
||||
// sets, and clear all cards. Later we will rebuild remebered
|
||||
// sets. We will also reset the GC time stamps of the regions.
|
||||
clear_rsets_post_compaction();
|
||||
check_gc_time_stamps();
|
||||
// Abandon current iterations of concurrent marking and concurrent
|
||||
// refinement, if any are in progress. We have to do this before
|
||||
// wait_until_scan_finished() below.
|
||||
concurrent_mark()->abort();
|
||||
|
||||
// Resize the heap if necessary.
|
||||
resize_if_necessary_after_full_collection(explicit_gc ? 0 : word_size);
|
||||
// Make sure we'll choose a new allocation region afterwards.
|
||||
release_mutator_alloc_region();
|
||||
abandon_gc_alloc_regions();
|
||||
g1_rem_set()->cleanupHRRS();
|
||||
|
||||
if (_hr_printer.is_active()) {
|
||||
// We should do this after we potentially resize the heap so
|
||||
// that all the COMMIT / UNCOMMIT events are generated before
|
||||
// the end GC event.
|
||||
// We should call this after we retire any currently active alloc
|
||||
// regions so that all the ALLOC / RETIRE events are generated
|
||||
// before the start GC event.
|
||||
_hr_printer.start_gc(true /* full */, (size_t) total_collections());
|
||||
|
||||
print_hrs_post_compaction();
|
||||
_hr_printer.end_gc(true /* full */, (size_t) total_collections());
|
||||
}
|
||||
// We may have added regions to the current incremental collection
|
||||
// set between the last GC or pause and now. We need to clear the
|
||||
// incremental collection set and then start rebuilding it afresh
|
||||
// after this full GC.
|
||||
abandon_collection_set(g1_policy()->inc_cset_head());
|
||||
g1_policy()->clear_incremental_cset();
|
||||
g1_policy()->stop_incremental_cset_building();
|
||||
|
||||
if (_cg1r->use_cache()) {
|
||||
_cg1r->clear_and_record_card_counts();
|
||||
_cg1r->clear_hot_cache();
|
||||
}
|
||||
tear_down_region_sets(false /* free_list_only */);
|
||||
g1_policy()->set_gcs_are_young(true);
|
||||
|
||||
// Rebuild remembered sets of all regions.
|
||||
if (G1CollectedHeap::use_parallel_gc_threads()) {
|
||||
uint n_workers =
|
||||
AdaptiveSizePolicy::calc_active_workers(workers()->total_workers(),
|
||||
workers()->active_workers(),
|
||||
Threads::number_of_non_daemon_threads());
|
||||
assert(UseDynamicNumberOfGCThreads ||
|
||||
n_workers == workers()->total_workers(),
|
||||
"If not dynamic should be using all the workers");
|
||||
workers()->set_active_workers(n_workers);
|
||||
// Set parallel threads in the heap (_n_par_threads) only
|
||||
// before a parallel phase and always reset it to 0 after
|
||||
// the phase so that the number of parallel threads does
|
||||
// no get carried forward to a serial phase where there
|
||||
// may be code that is "possibly_parallel".
|
||||
set_par_threads(n_workers);
|
||||
// See the comments in g1CollectedHeap.hpp and
|
||||
// G1CollectedHeap::ref_processing_init() about
|
||||
// how reference processing currently works in G1.
|
||||
|
||||
ParRebuildRSTask rebuild_rs_task(this);
|
||||
assert(check_heap_region_claim_values(
|
||||
HeapRegion::InitialClaimValue), "sanity check");
|
||||
assert(UseDynamicNumberOfGCThreads ||
|
||||
workers()->active_workers() == workers()->total_workers(),
|
||||
"Unless dynamic should use total workers");
|
||||
// Use the most recent number of active workers
|
||||
assert(workers()->active_workers() > 0,
|
||||
"Active workers not properly set");
|
||||
set_par_threads(workers()->active_workers());
|
||||
workers()->run_task(&rebuild_rs_task);
|
||||
set_par_threads(0);
|
||||
assert(check_heap_region_claim_values(
|
||||
HeapRegion::RebuildRSClaimValue), "sanity check");
|
||||
reset_heap_region_claim_values();
|
||||
} else {
|
||||
RebuildRSOutOfRegionClosure rebuild_rs(this);
|
||||
heap_region_iterate(&rebuild_rs);
|
||||
}
|
||||
// Temporarily make discovery by the STW ref processor single threaded (non-MT).
|
||||
ReferenceProcessorMTDiscoveryMutator stw_rp_disc_ser(ref_processor_stw(), false);
|
||||
|
||||
if (G1Log::fine()) {
|
||||
print_size_transition(gclog_or_tty, g1h_prev_used, used(), capacity());
|
||||
}
|
||||
// Temporarily clear the STW ref processor's _is_alive_non_header field.
|
||||
ReferenceProcessorIsAliveMutator stw_rp_is_alive_null(ref_processor_stw(), NULL);
|
||||
|
||||
if (true) { // FIXME
|
||||
MetaspaceGC::compute_new_size();
|
||||
}
|
||||
ref_processor_stw()->enable_discovery(true /*verify_disabled*/, true /*verify_no_refs*/);
|
||||
ref_processor_stw()->setup_policy(do_clear_all_soft_refs);
|
||||
|
||||
// Start a new incremental collection set for the next pause
|
||||
assert(g1_policy()->collection_set() == NULL, "must be");
|
||||
g1_policy()->start_incremental_cset_building();
|
||||
// Do collection work
|
||||
{
|
||||
HandleMark hm; // Discard invalid handles created during gc
|
||||
G1MarkSweep::invoke_at_safepoint(ref_processor_stw(), do_clear_all_soft_refs);
|
||||
}
|
||||
|
||||
// Clear the _cset_fast_test bitmap in anticipation of adding
|
||||
// regions to the incremental collection set for the next
|
||||
// evacuation pause.
|
||||
clear_cset_fast_test();
|
||||
assert(free_regions() == 0, "we should not have added any free regions");
|
||||
rebuild_region_sets(false /* free_list_only */);
|
||||
|
||||
init_mutator_alloc_region();
|
||||
// Enqueue any discovered reference objects that have
|
||||
// not been removed from the discovered lists.
|
||||
ref_processor_stw()->enqueue_discovered_references();
|
||||
|
||||
double end = os::elapsedTime();
|
||||
g1_policy()->record_full_collection_end();
|
||||
COMPILER2_PRESENT(DerivedPointerTable::update_pointers());
|
||||
|
||||
MemoryService::track_memory_usage();
|
||||
|
||||
verify_after_gc();
|
||||
|
||||
assert(!ref_processor_stw()->discovery_enabled(), "Postcondition");
|
||||
ref_processor_stw()->verify_no_references_recorded();
|
||||
|
||||
// Delete metaspaces for unloaded class loaders and clean up loader_data graph
|
||||
ClassLoaderDataGraph::purge();
|
||||
|
||||
// Note: since we've just done a full GC, concurrent
|
||||
// marking is no longer active. Therefore we need not
|
||||
// re-enable reference discovery for the CM ref processor.
|
||||
// That will be done at the start of the next marking cycle.
|
||||
assert(!ref_processor_cm()->discovery_enabled(), "Postcondition");
|
||||
ref_processor_cm()->verify_no_references_recorded();
|
||||
|
||||
reset_gc_time_stamp();
|
||||
// Since everything potentially moved, we will clear all remembered
|
||||
// sets, and clear all cards. Later we will rebuild remebered
|
||||
// sets. We will also reset the GC time stamps of the regions.
|
||||
clear_rsets_post_compaction();
|
||||
check_gc_time_stamps();
|
||||
|
||||
// Resize the heap if necessary.
|
||||
resize_if_necessary_after_full_collection(explicit_gc ? 0 : word_size);
|
||||
|
||||
if (_hr_printer.is_active()) {
|
||||
// We should do this after we potentially resize the heap so
|
||||
// that all the COMMIT / UNCOMMIT events are generated before
|
||||
// the end GC event.
|
||||
|
||||
print_hrs_post_compaction();
|
||||
_hr_printer.end_gc(true /* full */, (size_t) total_collections());
|
||||
}
|
||||
|
||||
if (_cg1r->use_cache()) {
|
||||
_cg1r->clear_and_record_card_counts();
|
||||
_cg1r->clear_hot_cache();
|
||||
}
|
||||
|
||||
// Rebuild remembered sets of all regions.
|
||||
if (G1CollectedHeap::use_parallel_gc_threads()) {
|
||||
uint n_workers =
|
||||
AdaptiveSizePolicy::calc_active_workers(workers()->total_workers(),
|
||||
workers()->active_workers(),
|
||||
Threads::number_of_non_daemon_threads());
|
||||
assert(UseDynamicNumberOfGCThreads ||
|
||||
n_workers == workers()->total_workers(),
|
||||
"If not dynamic should be using all the workers");
|
||||
workers()->set_active_workers(n_workers);
|
||||
// Set parallel threads in the heap (_n_par_threads) only
|
||||
// before a parallel phase and always reset it to 0 after
|
||||
// the phase so that the number of parallel threads does
|
||||
// no get carried forward to a serial phase where there
|
||||
// may be code that is "possibly_parallel".
|
||||
set_par_threads(n_workers);
|
||||
|
||||
ParRebuildRSTask rebuild_rs_task(this);
|
||||
assert(check_heap_region_claim_values(
|
||||
HeapRegion::InitialClaimValue), "sanity check");
|
||||
assert(UseDynamicNumberOfGCThreads ||
|
||||
workers()->active_workers() == workers()->total_workers(),
|
||||
"Unless dynamic should use total workers");
|
||||
// Use the most recent number of active workers
|
||||
assert(workers()->active_workers() > 0,
|
||||
"Active workers not properly set");
|
||||
set_par_threads(workers()->active_workers());
|
||||
workers()->run_task(&rebuild_rs_task);
|
||||
set_par_threads(0);
|
||||
assert(check_heap_region_claim_values(
|
||||
HeapRegion::RebuildRSClaimValue), "sanity check");
|
||||
reset_heap_region_claim_values();
|
||||
} else {
|
||||
RebuildRSOutOfRegionClosure rebuild_rs(this);
|
||||
heap_region_iterate(&rebuild_rs);
|
||||
}
|
||||
|
||||
if (true) { // FIXME
|
||||
MetaspaceGC::compute_new_size();
|
||||
}
|
||||
|
||||
#ifdef TRACESPINNING
|
||||
ParallelTaskTerminator::print_termination_counts();
|
||||
ParallelTaskTerminator::print_termination_counts();
|
||||
#endif
|
||||
|
||||
gc_epilogue(true);
|
||||
// Discard all rset updates
|
||||
JavaThread::dirty_card_queue_set().abandon_logs();
|
||||
assert(!G1DeferredRSUpdate
|
||||
|| (G1DeferredRSUpdate &&
|
||||
(dirty_card_queue_set().completed_buffers_num() == 0)), "Should not be any");
|
||||
|
||||
// Discard all rset updates
|
||||
JavaThread::dirty_card_queue_set().abandon_logs();
|
||||
assert(!G1DeferredRSUpdate
|
||||
|| (G1DeferredRSUpdate && (dirty_card_queue_set().completed_buffers_num() == 0)), "Should not be any");
|
||||
_young_list->reset_sampled_info();
|
||||
// At this point there should be no regions in the
|
||||
// entire heap tagged as young.
|
||||
assert(check_young_list_empty(true /* check_heap */),
|
||||
"young list should be empty at this point");
|
||||
|
||||
_young_list->reset_sampled_info();
|
||||
// At this point there should be no regions in the
|
||||
// entire heap tagged as young.
|
||||
assert( check_young_list_empty(true /* check_heap */),
|
||||
"young list should be empty at this point");
|
||||
// Update the number of full collections that have been completed.
|
||||
increment_old_marking_cycles_completed(false /* concurrent */);
|
||||
|
||||
// Update the number of full collections that have been completed.
|
||||
increment_old_marking_cycles_completed(false /* concurrent */);
|
||||
_hrs.verify_optional();
|
||||
verify_region_sets_optional();
|
||||
|
||||
_hrs.verify_optional();
|
||||
verify_region_sets_optional();
|
||||
// Start a new incremental collection set for the next pause
|
||||
assert(g1_policy()->collection_set() == NULL, "must be");
|
||||
g1_policy()->start_incremental_cset_building();
|
||||
|
||||
// Clear the _cset_fast_test bitmap in anticipation of adding
|
||||
// regions to the incremental collection set for the next
|
||||
// evacuation pause.
|
||||
clear_cset_fast_test();
|
||||
|
||||
init_mutator_alloc_region();
|
||||
|
||||
double end = os::elapsedTime();
|
||||
g1_policy()->record_full_collection_end();
|
||||
|
||||
if (G1Log::fine()) {
|
||||
g1_policy()->print_heap_transition();
|
||||
}
|
||||
|
||||
// We must call G1MonitoringSupport::update_sizes() in the same scoping level
|
||||
// as an active TraceMemoryManagerStats object (i.e. before the destructor for the
|
||||
// TraceMemoryManagerStats is called) so that the G1 memory pools are updated
|
||||
// before any GC notifications are raised.
|
||||
g1mm()->update_sizes();
|
||||
|
||||
gc_epilogue(true);
|
||||
}
|
||||
|
||||
if (G1Log::finer()) {
|
||||
g1_policy()->print_detailed_heap_transition();
|
||||
}
|
||||
|
||||
print_heap_after_gc();
|
||||
|
||||
// We must call G1MonitoringSupport::update_sizes() in the same scoping level
|
||||
// as an active TraceMemoryManagerStats object (i.e. before the destructor for the
|
||||
// TraceMemoryManagerStats is called) so that the G1 memory pools are updated
|
||||
// before any GC notifications are raised.
|
||||
g1mm()->update_sizes();
|
||||
post_full_gc_dump();
|
||||
}
|
||||
|
||||
post_full_gc_dump();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -3427,6 +3433,15 @@ void G1CollectedHeap::print_extended_on(outputStream* st) const {
|
||||
heap_region_iterate(&blk);
|
||||
}
|
||||
|
||||
void G1CollectedHeap::print_on_error(outputStream* st) const {
|
||||
this->CollectedHeap::print_on_error(st);
|
||||
|
||||
if (_cm != NULL) {
|
||||
st->cr();
|
||||
_cm->print_on_error(st);
|
||||
}
|
||||
}
|
||||
|
||||
void G1CollectedHeap::print_gc_threads_on(outputStream* st) const {
|
||||
if (G1CollectedHeap::use_parallel_gc_threads()) {
|
||||
workers()->print_worker_threads_on(st);
|
||||
@ -3829,7 +3844,6 @@ G1CollectedHeap::do_collection_pause_at_safepoint(double target_pause_time_ms) {
|
||||
// The elapsed time induced by the start time below deliberately elides
|
||||
// the possible verification above.
|
||||
double sample_start_time_sec = os::elapsedTime();
|
||||
size_t start_used_bytes = used();
|
||||
|
||||
#if YOUNG_LIST_VERBOSE
|
||||
gclog_or_tty->print_cr("\nBefore recording pause start.\nYoung_list:");
|
||||
@ -3837,8 +3851,7 @@ G1CollectedHeap::do_collection_pause_at_safepoint(double target_pause_time_ms) {
|
||||
g1_policy()->print_collection_set(g1_policy()->inc_cset_head(), gclog_or_tty);
|
||||
#endif // YOUNG_LIST_VERBOSE
|
||||
|
||||
g1_policy()->record_collection_pause_start(sample_start_time_sec,
|
||||
start_used_bytes);
|
||||
g1_policy()->record_collection_pause_start(sample_start_time_sec);
|
||||
|
||||
double scan_wait_start = os::elapsedTime();
|
||||
// We have to wait until the CM threads finish scanning the
|
||||
|
@ -1575,6 +1575,7 @@ public:
|
||||
virtual void verify(bool silent);
|
||||
virtual void print_on(outputStream* st) const;
|
||||
virtual void print_extended_on(outputStream* st) const;
|
||||
virtual void print_on_error(outputStream* st) const;
|
||||
|
||||
virtual void print_gc_threads_on(outputStream* st) const;
|
||||
virtual void gc_threads_do(ThreadClosure* tc) const;
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -406,7 +406,6 @@ void G1CollectorPolicy::init() {
|
||||
}
|
||||
_free_regions_at_end_of_collection = _g1->free_regions();
|
||||
update_young_list_target_length();
|
||||
_prev_eden_capacity = _young_list_target_length * HeapRegion::GrainBytes;
|
||||
|
||||
// We may immediately start allocating regions and placing them on the
|
||||
// collection set list. Initialize the per-collection set info
|
||||
@ -746,6 +745,7 @@ G1CollectorPolicy::verify_young_ages(HeapRegion* head,
|
||||
|
||||
void G1CollectorPolicy::record_full_collection_start() {
|
||||
_full_collection_start_sec = os::elapsedTime();
|
||||
record_heap_size_info_at_start();
|
||||
// Release the future to-space so that it is available for compaction into.
|
||||
_g1->set_full_collection();
|
||||
}
|
||||
@ -788,8 +788,7 @@ void G1CollectorPolicy::record_stop_world_start() {
|
||||
_stop_world_start = os::elapsedTime();
|
||||
}
|
||||
|
||||
void G1CollectorPolicy::record_collection_pause_start(double start_time_sec,
|
||||
size_t start_used) {
|
||||
void G1CollectorPolicy::record_collection_pause_start(double start_time_sec) {
|
||||
// We only need to do this here as the policy will only be applied
|
||||
// to the GC we're about to start. so, no point is calculating this
|
||||
// every time we calculate / recalculate the target young length.
|
||||
@ -803,19 +802,14 @@ void G1CollectorPolicy::record_collection_pause_start(double start_time_sec,
|
||||
_trace_gen0_time_data.record_start_collection(s_w_t_ms);
|
||||
_stop_world_start = 0.0;
|
||||
|
||||
record_heap_size_info_at_start();
|
||||
|
||||
phase_times()->record_cur_collection_start_sec(start_time_sec);
|
||||
_cur_collection_pause_used_at_start_bytes = start_used;
|
||||
_cur_collection_pause_used_regions_at_start = _g1->used_regions();
|
||||
_pending_cards = _g1->pending_card_num();
|
||||
|
||||
_collection_set_bytes_used_before = 0;
|
||||
_bytes_copied_during_gc = 0;
|
||||
|
||||
YoungList* young_list = _g1->young_list();
|
||||
_eden_bytes_before_gc = young_list->eden_used_bytes();
|
||||
_survivor_bytes_before_gc = young_list->survivor_used_bytes();
|
||||
_capacity_before_gc = _g1->capacity();
|
||||
|
||||
_last_gc_was_young = false;
|
||||
|
||||
// do that for any other surv rate groups
|
||||
@ -1153,6 +1147,21 @@ void G1CollectorPolicy::record_collection_pause_end(double pause_time_ms) {
|
||||
byte_size_in_proper_unit((double)(bytes)), \
|
||||
proper_unit_for_byte_size((bytes))
|
||||
|
||||
void G1CollectorPolicy::record_heap_size_info_at_start() {
|
||||
YoungList* young_list = _g1->young_list();
|
||||
_eden_bytes_before_gc = young_list->eden_used_bytes();
|
||||
_survivor_bytes_before_gc = young_list->survivor_used_bytes();
|
||||
_capacity_before_gc = _g1->capacity();
|
||||
|
||||
_cur_collection_pause_used_at_start_bytes = _g1->used();
|
||||
_cur_collection_pause_used_regions_at_start = _g1->used_regions();
|
||||
|
||||
size_t eden_capacity_before_gc =
|
||||
(_young_list_target_length * HeapRegion::GrainBytes) - _survivor_bytes_before_gc;
|
||||
|
||||
_prev_eden_capacity = eden_capacity_before_gc;
|
||||
}
|
||||
|
||||
void G1CollectorPolicy::print_heap_transition() {
|
||||
_g1->print_size_transition(gclog_or_tty,
|
||||
_cur_collection_pause_used_at_start_bytes, _g1->used(), _g1->capacity());
|
||||
@ -1183,8 +1192,6 @@ void G1CollectorPolicy::print_detailed_heap_transition() {
|
||||
EXT_SIZE_PARAMS(_capacity_before_gc),
|
||||
EXT_SIZE_PARAMS(used),
|
||||
EXT_SIZE_PARAMS(capacity));
|
||||
|
||||
_prev_eden_capacity = eden_capacity;
|
||||
}
|
||||
|
||||
void G1CollectorPolicy::adjust_concurrent_refinement(double update_rs_time,
|
||||
@ -1359,18 +1366,6 @@ void G1CollectorPolicy::print_yg_surv_rate_info() const {
|
||||
#endif // PRODUCT
|
||||
}
|
||||
|
||||
#ifndef PRODUCT
|
||||
// for debugging, bit of a hack...
|
||||
static char*
|
||||
region_num_to_mbs(int length) {
|
||||
static char buffer[64];
|
||||
double bytes = (double) (length * HeapRegion::GrainBytes);
|
||||
double mbs = bytes / (double) (1024 * 1024);
|
||||
sprintf(buffer, "%7.2lfMB", mbs);
|
||||
return buffer;
|
||||
}
|
||||
#endif // PRODUCT
|
||||
|
||||
uint G1CollectorPolicy::max_regions(int purpose) {
|
||||
switch (purpose) {
|
||||
case GCAllocForSurvived:
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2001, 2012, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2001, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -671,34 +671,36 @@ public:
|
||||
|
||||
bool need_to_start_conc_mark(const char* source, size_t alloc_word_size = 0);
|
||||
|
||||
// Update the heuristic info to record a collection pause of the given
|
||||
// start time, where the given number of bytes were used at the start.
|
||||
// This may involve changing the desired size of a collection set.
|
||||
// Record the start and end of an evacuation pause.
|
||||
void record_collection_pause_start(double start_time_sec);
|
||||
void record_collection_pause_end(double pause_time_ms);
|
||||
|
||||
void record_stop_world_start();
|
||||
|
||||
void record_collection_pause_start(double start_time_sec, size_t start_used);
|
||||
// Record the start and end of a full collection.
|
||||
void record_full_collection_start();
|
||||
void record_full_collection_end();
|
||||
|
||||
// Must currently be called while the world is stopped.
|
||||
void record_concurrent_mark_init_end(double
|
||||
mark_init_elapsed_time_ms);
|
||||
void record_concurrent_mark_init_end(double mark_init_elapsed_time_ms);
|
||||
|
||||
// Record start and end of remark.
|
||||
void record_concurrent_mark_remark_start();
|
||||
void record_concurrent_mark_remark_end();
|
||||
|
||||
// Record start, end, and completion of cleanup.
|
||||
void record_concurrent_mark_cleanup_start();
|
||||
void record_concurrent_mark_cleanup_end(int no_of_gc_threads);
|
||||
void record_concurrent_mark_cleanup_completed();
|
||||
|
||||
void record_concurrent_pause();
|
||||
// Records the information about the heap size for reporting in
|
||||
// print_detailed_heap_transition
|
||||
void record_heap_size_info_at_start();
|
||||
|
||||
void record_collection_pause_end(double pause_time);
|
||||
// Print heap sizing transition (with less and more detail).
|
||||
void print_heap_transition();
|
||||
void print_detailed_heap_transition();
|
||||
|
||||
// Record the fact that a full collection occurred.
|
||||
void record_full_collection_start();
|
||||
void record_full_collection_end();
|
||||
void record_stop_world_start();
|
||||
void record_concurrent_pause();
|
||||
|
||||
// Record how much space we copied during a GC. This is typically
|
||||
// called when a GC alloc region is being retired.
|
||||
|
@ -53,15 +53,6 @@ void PtrQueue::flush() {
|
||||
}
|
||||
|
||||
|
||||
static int byte_index_to_index(int ind) {
|
||||
assert((ind % oopSize) == 0, "Invariant.");
|
||||
return ind / oopSize;
|
||||
}
|
||||
|
||||
static int index_to_byte_index(int byte_ind) {
|
||||
return byte_ind * oopSize;
|
||||
}
|
||||
|
||||
void PtrQueue::enqueue_known_active(void* ptr) {
|
||||
assert(0 <= _index && _index <= _sz, "Invariant.");
|
||||
assert(_index == 0 || _buf != NULL, "invariant");
|
||||
|
@ -173,6 +173,12 @@ public:
|
||||
void reset_counters();
|
||||
#endif // #ifndef PRODUCT
|
||||
|
||||
void print_on_error(outputStream* st) const {
|
||||
st->print_cr("Marking Bits: (ParMarkBitMap*) " PTR_FORMAT, this);
|
||||
_beg_bits.print_on_error(st, " Begin Bits: ");
|
||||
_end_bits.print_on_error(st, " End Bits: ");
|
||||
}
|
||||
|
||||
#ifdef ASSERT
|
||||
void verify_clear() const;
|
||||
inline void verify_bit(idx_t bit) const;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user