Merge
authorprr
Wed, 11 Mar 2015 08:30:21 -0700
changeset 29448 419b99acf96d
parent 29447 999033f74e6b (current diff)
parent 29311 bc685175f836 (diff)
child 29449 0b30ab954416
child 29669 d3148063d225
Merge
common/autoconf/configure.ac
common/autoconf/generated-configure.sh
--- a/common/autoconf/configure.ac	Mon Mar 09 09:49:22 2015 -0700
+++ b/common/autoconf/configure.ac	Wed Mar 11 08:30:21 2015 -0700
@@ -196,6 +196,7 @@
 
 # Setup debug symbols (need objcopy from the toolchain for that)
 JDKOPT_SETUP_DEBUG_SYMBOLS
+JDKOPT_SETUP_CODE_COVERAGE
 
 ###############################################################################
 #
--- a/common/autoconf/flags.m4	Mon Mar 09 09:49:22 2015 -0700
+++ b/common/autoconf/flags.m4	Wed Mar 11 08:30:21 2015 -0700
@@ -677,7 +677,7 @@
 
   # The shared libraries are compiled using the picflag.
   CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
-  CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
+  CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA"
 
   # Executable flags
   CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK"
@@ -688,6 +688,19 @@
   AC_SUBST(CXXFLAGS_JDKLIB)
   AC_SUBST(CXXFLAGS_JDKEXE)
 
+  # Flags for compiling test libraries
+  CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
+  CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA"
+
+  # Flags for compiling test executables
+  CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK"
+  CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK"
+
+  AC_SUBST(CFLAGS_TESTLIB)
+  AC_SUBST(CFLAGS_TESTEXE)
+  AC_SUBST(CXXFLAGS_TESTLIB)
+  AC_SUBST(CXXFLAGS_TESTEXE)
+
   # Setup LDFLAGS et al.
   #
 
@@ -801,6 +814,16 @@
   AC_SUBST(LDFLAGS_JDKLIB_SUFFIX)
   AC_SUBST(LDFLAGS_JDKEXE_SUFFIX)
   AC_SUBST(LDFLAGS_CXX_JDK)
+
+  LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB"
+  LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE"
+  LDFLAGS_TESTLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX"
+  LDFLAGS_TESTEXE_SUFFIX="$LDFLAGS_JDKEXE_SUFFIX"
+
+  AC_SUBST(LDFLAGS_TESTLIB)
+  AC_SUBST(LDFLAGS_TESTEXE)
+  AC_SUBST(LDFLAGS_TESTLIB_SUFFIX)
+  AC_SUBST(LDFLAGS_TESTEXE_SUFFIX)
 ])
 
 # FLAGS_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE],
--- a/common/autoconf/generated-configure.sh	Mon Mar 09 09:49:22 2015 -0700
+++ b/common/autoconf/generated-configure.sh	Wed Mar 11 08:30:21 2015 -0700
@@ -680,17 +680,26 @@
 X_CFLAGS
 XMKMF
 FIXPATH
+GCOV_ENABLED
 ZIP_DEBUGINFO_FILES
 ENABLE_DEBUG_SYMBOLS
 CFLAGS_WARNINGS_ARE_ERRORS
 DISABLE_WARNING_PREFIX
 COMPILER_SUPPORTS_TARGET_BITS_FLAG
 ZERO_ARCHFLAG
+LDFLAGS_TESTEXE_SUFFIX
+LDFLAGS_TESTLIB_SUFFIX
+LDFLAGS_TESTEXE
+LDFLAGS_TESTLIB
 LDFLAGS_CXX_JDK
 LDFLAGS_JDKEXE_SUFFIX
 LDFLAGS_JDKLIB_SUFFIX
 LDFLAGS_JDKEXE
 LDFLAGS_JDKLIB
+CXXFLAGS_TESTEXE
+CXXFLAGS_TESTLIB
+CFLAGS_TESTEXE
+CFLAGS_TESTLIB
 CXXFLAGS_JDKEXE
 CXXFLAGS_JDKLIB
 CFLAGS_JDKEXE
@@ -1085,6 +1094,7 @@
 with_extra_ldflags
 enable_debug_symbols
 enable_zip_debug_info
+enable_native_coverage
 with_x
 with_cups
 with_cups_include
@@ -1853,6 +1863,9 @@
   --disable-debug-symbols disable generation of debug symbols [enabled]
   --disable-zip-debug-info
                           disable zipping of debug-info files [enabled]
+  --enable-native-coverage
+                          enable native compilation with code coverage
+                          data[disabled]
   --disable-freetype-bundling
                           disable bundling of the freetype library with the
                           build result [enabled on Windows or when using
@@ -3994,6 +4007,12 @@
 
 
 
+################################################################################
+#
+# Gcov coverage data for hotspot
+#
+
+
 #
 # Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -4350,7 +4369,7 @@
 #CUSTOM_AUTOCONF_INCLUDE
 
 # Do not change or remove the following line, it is needed for consistency checks:
-DATE_WHEN_GENERATED=1425893864
+DATE_WHEN_GENERATED=1425994551
 
 ###############################################################################
 #
@@ -42565,7 +42584,7 @@
 
   # The shared libraries are compiled using the picflag.
   CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
-  CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA "
+  CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA"
 
   # Executable flags
   CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK"
@@ -42576,6 +42595,19 @@
 
 
 
+  # Flags for compiling test libraries
+  CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA"
+  CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA"
+
+  # Flags for compiling test executables
+  CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK"
+  CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK"
+
+
+
+
+
+
   # Setup LDFLAGS et al.
   #
 
@@ -42690,6 +42722,16 @@
 
 
 
+  LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB"
+  LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE"
+  LDFLAGS_TESTLIB_SUFFIX="$LDFLAGS_JDKLIB_SUFFIX"
+  LDFLAGS_TESTEXE_SUFFIX="$LDFLAGS_JDKEXE_SUFFIX"
+
+
+
+
+
+
 
   # Some Zero and Shark settings.
   # ZERO_ARCHFLAG tells the compiler which mode to build for
@@ -42994,6 +43036,45 @@
 
 
 
+  # Check whether --enable-native-coverage was given.
+if test "${enable_native_coverage+set}" = set; then :
+  enableval=$enable_native_coverage;
+fi
+
+  GCOV_ENABLED="false"
+  if test "x$enable_native_coverage" = "xyes"; then
+    if test "x$TOOLCHAIN_TYPE" = "xgcc"; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5
+$as_echo_n "checking if native coverage is enabled... " >&6; }
+      { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+      GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline"
+      GCOV_LDFLAGS="-fprofile-arcs"
+      LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS"
+      LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS"
+      LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS"
+      CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS"
+      CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS"
+      CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS"
+      CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS"
+      LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS"
+      LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS"
+      GCOV_ENABLED="true"
+    else
+      as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5
+    fi
+  elif test "x$enable_native_coverage" = "xno"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5
+$as_echo_n "checking if native coverage is enabled... " >&6; }
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+  elif test "x$enable_native_coverage" != "x"; then
+    as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5
+  fi
+
+
+
+
 ###############################################################################
 #
 # Check dependencies for external and internal libraries.
--- a/common/autoconf/jdk-options.m4	Mon Mar 09 09:49:22 2015 -0700
+++ b/common/autoconf/jdk-options.m4	Wed Mar 11 08:30:21 2015 -0700
@@ -640,3 +640,41 @@
   AC_SUBST(ENABLE_DEBUG_SYMBOLS)
   AC_SUBST(ZIP_DEBUGINFO_FILES)
 ])
+
+################################################################################
+#
+# Gcov coverage data for hotspot
+#
+AC_DEFUN_ONCE([JDKOPT_SETUP_CODE_COVERAGE],
+[
+  AC_ARG_ENABLE(native-coverage, [AS_HELP_STRING([--enable-native-coverage],
+      [enable native compilation with code coverage data@<:@disabled@:>@])])
+  GCOV_ENABLED="false"
+  if test "x$enable_native_coverage" = "xyes"; then
+    if test "x$TOOLCHAIN_TYPE" = "xgcc"; then
+      AC_MSG_CHECKING([if native coverage is enabled])
+      AC_MSG_RESULT([yes])
+      GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline"
+      GCOV_LDFLAGS="-fprofile-arcs"
+      LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS"
+      LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS"
+      LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS"
+      CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS"
+      CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS"
+      CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS"
+      CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS"
+      LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS"
+      LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS"
+      GCOV_ENABLED="true"
+    else
+      AC_MSG_ERROR([--enable-native-coverage only works with toolchain type gcc])
+    fi
+  elif test "x$enable_native_coverage" = "xno"; then
+    AC_MSG_CHECKING([if native coverage is enabled])
+    AC_MSG_RESULT([no])
+  elif test "x$enable_native_coverage" != "x"; then
+    AC_MSG_ERROR([--enable-native-coverage can only be assigned "yes" or "no"])
+  fi
+
+  AC_SUBST(GCOV_ENABLED)
+])
--- a/common/autoconf/spec.gmk.in	Mon Mar 09 09:49:22 2015 -0700
+++ b/common/autoconf/spec.gmk.in	Wed Mar 11 08:30:21 2015 -0700
@@ -292,6 +292,8 @@
 # Enable RMIConnector IIOP transport
 RMICONNECTOR_IIOP=@RMICONNECTOR_IIOP@
 
+GCOV_ENABLED=@GCOV_ENABLED@
+
 # Necessary additional compiler flags to compile X11
 X_CFLAGS:=@X_CFLAGS@
 X_LIBS:=@X_LIBS@
@@ -380,6 +382,16 @@
 # Sometimes a different linker is needed for c++ executables
 LDEXECXX:=@FIXPATH@ @LDEXECXX@
 
+# Compiler and linker flags used when building native tests
+CFLAGS_TESTLIB:=@CFLAGS_TESTLIB@
+CXXFLAGS_TESTLIB:=@CXXFLAGS_TESTLIB@
+CFLAGS_TESTEXE:=@CFLAGS_TESTEXE@
+CXXFLAGS_TESTEXE:=@CXXFLAGS_TESTEXE@
+LDFLAGS_TESTLIB:=@LDFLAGS_TESTLIB@
+LDFLAGS_TESTLIB_SUFFIX:=@LDFLAGS_TESTLIB_SUFFIX@
+LDFLAGS_TESTEXE:=@LDFLAGS_TESTEXE@
+LDFLAGS_TESTEXE_SUFFIX:=@LDFLAGS_TESTEXE_SUFFIX@
+
 # BUILD_CC/BUILD_LD is a compiler/linker that generates code that is runnable on the
 # build platform.
 BUILD_CC:=@FIXPATH@ @BUILD_CC@
@@ -702,6 +714,10 @@
 TEST_IMAGE_SUBDIR:=test
 TEST_IMAGE_DIR=$(IMAGES_OUTPUTDIR)/$(TEST_IMAGE_SUBDIR)
 
+# Symbols image
+SYMBOLS_IMAGE_SUBDIR:=symbols
+SYMBOLS_IMAGE_DIR=$(IMAGES_OUTPUTDIR)/$(SYMBOLS_IMAGE_SUBDIR)
+
 # Macosx bundles directory definitions
 JDK_BUNDLE_SUBDIR=jdk-bundle/jdk$(JDK_VERSION).jdk/Contents
 JRE_BUNDLE_SUBDIR=jre-bundle/jre$(JDK_VERSION).jre/Contents
--- a/common/bin/hgforest.sh	Mon Mar 09 09:49:22 2015 -0700
+++ b/common/bin/hgforest.sh	Wed Mar 11 08:30:21 2015 -0700
@@ -26,6 +26,9 @@
 
 usage() {
       echo "usage: $0 [-h|--help] [-q|--quiet] [-v|--verbose] [-s|--sequential] [--] <command> [commands...]" > ${status_output}
+      echo "command format : mercurial-command [ "jdk" ] [ extra-url ]"
+      echo "command option: jdk : used only with clone command to request just the extra repos for JDK-only builds"
+      echo "command option : extra-url : server hosting the extra repositories"
       echo "Environment variables which modify behaviour:"
       echo "   HGFOREST_QUIET      : (boolean) If 'true' then standard output is redirected to /dev/null"
       echo "   HGFOREST_VERBOSE    : (boolean) If 'true' then Mercurial asked to produce verbose output"
@@ -179,7 +182,8 @@
 trap 'nice_exit' EXIT
 
 subrepos="corba jaxp jaxws langtools jdk hotspot nashorn"
-subrepos_extra="closed jdk/src/closed jdk/make/closed jdk/test/closed hotspot/make/closed hotspot/src/closed hotspot/test/closed deploy install sponsors pubs"
+jdk_subrepos_extra="closed jdk/src/closed jdk/make/closed jdk/test/closed hotspot/make/closed hotspot/src/closed hotspot/test/closed"
+subrepos_extra="$jdk_subrepos_extra deploy install sponsors pubs"
 
 # Only look in specific locations for possible forests (avoids long searches)
 pull_default=""
@@ -209,6 +213,11 @@
   pull_default_tail=`echo ${pull_default} | sed -e 's@^.*://[^/]*/\(.*\)@\1@'`
 
   if [ $# -gt 0 ] ; then
+    if [ "x${1}" = "xjdk" ] ; then
+       subrepos_extra=$jdk_subrepos_extra
+       echo "subrepos being cloned are $subrepos_extra"
+       shift
+    fi
     # if there is an "extra sources" path then reparent "extra" repos to that path
     if [ "x${pull_default}" = "x${pull_default_tail}" ] ; then
       echo "ERROR: Need initial clone from non-local source" > ${status_output}
--- a/make/Images.gmk	Mon Mar 09 09:49:22 2015 -0700
+++ b/make/Images.gmk	Wed Mar 11 08:30:21 2015 -0700
@@ -488,6 +488,42 @@
 JDK_TARGETS += $(COPY_JRTFS_JAR)
 
 ################################################################################
+# Code coverage data files
+
+ifeq ($(GCOV_ENABLED), true)
+
+  GCOV_FIND_EXPR := -type f -name "*.gcno"
+
+  ifeq ($(JVM_VARIANT_CLIENT), true)
+    $(eval $(call SetupCopyFiles,COPY_HOTSPOT_CLIENT_GCOV_GCNO, \
+        SRC := $(HOTSPOT_OUTPUTDIR), \
+        DEST := $(SYMBOLS_IMAGE_DIR)/gcov/hotspot/client, \
+        FILES := $(shell $(FIND) $(HOTSPOT_OUTPUTDIR)/*compiler1/ $(GCOV_FIND_EXPR)), \
+        FLATTEN := true))
+
+    SYMBOLS_TARGETS += $(COPY_HOTSPOT_CLIENT_GCOV_GCNO)
+  endif
+
+  ifeq ($(JVM_VARIANT_SERVER), true)
+    $(eval $(call SetupCopyFiles,COPY_HOTSPOT_SERVER_GCOV_GCNO, \
+        SRC := $(HOTSPOT_OUTPUTDIR), \
+        DEST := $(SYMBOLS_IMAGE_DIR)/gcov/hotspot/server, \
+        FILES := $(shell $(FIND) $(HOTSPOT_OUTPUTDIR)/*compiler2/ $(GCOV_FIND_EXPR)), \
+        FLATTEN := true))
+
+    SYMBOLS_TARGETS += $(COPY_HOTSPOT_SERVER_GCOV_GCNO)
+  endif
+
+  $(eval $(call SetupCopyFiles,COPY_JDK_GCOV_GCNO, \
+      SRC := $(SUPPORT_OUTPUTDIR)/native, \
+      DEST := $(SYMBOLS_IMAGE_DIR)/gcov/jdk, \
+      FILES := $(shell $(FIND) $(SUPPORT_OUTPUTDIR)/native $(GCOV_FIND_EXPR))))
+
+  SYMBOLS_TARGETS += $(COPY_JDK_GCOV_GCNO)
+
+endif
+
+################################################################################
 
 # Include custom post hook here to make it possible to augment the target lists
 # before actual target prerequisites are declared.
@@ -498,7 +534,8 @@
 $(JRE_TARGETS): $(TOOL_JRE_TARGETS)
 $(JDK_TARGETS): $(TOOL_JDK_TARGETS)
 
-jimages: $(TOOL_JRE_TARGETS) $(TOOL_JDK_TARGETS) $(JRE_TARGETS) $(JDK_TARGETS)
+jimages: $(TOOL_JRE_TARGETS) $(TOOL_JDK_TARGETS) $(JRE_TARGETS) $(JDK_TARGETS) \
+    $(SYMBOLS_TARGETS)
 
 
 $(JRE_COMPACT1_TARGETS): $(TOOL_JRE_COMPACT1_TARGETS)
--- a/make/Jprt.gmk	Mon Mar 09 09:49:22 2015 -0700
+++ b/make/Jprt.gmk	Wed Mar 11 08:30:21 2015 -0700
@@ -33,10 +33,16 @@
     override JPRT_ARCHIVE_BUNDLE := $(shell $(CYGPATH) -u $(JPRT_ARCHIVE_BUNDLE))
   endif
   ifdef JPRT_ARCHIVE_INSTALL_BUNDLE
-    override JPRT_ARCHIVE_INSTALL_BUNDLE := $(shell $(CYGPATH) -u $(JPRT_ARCHIVE_INSTALL_BUNDLE))
+    override JPRT_ARCHIVE_INSTALL_BUNDLE := \
+        $(shell $(CYGPATH) -u $(JPRT_ARCHIVE_INSTALL_BUNDLE))
   endif
   ifdef JPRT_ARCHIVE_TEST_BUNDLE
-    override JPRT_ARCHIVE_TEST_BUNDLE := $(shell $(CYGPATH) -u $(JPRT_ARCHIVE_TEST_BUNDLE))
+    override JPRT_ARCHIVE_TEST_BUNDLE := \
+        $(shell $(CYGPATH) -u $(JPRT_ARCHIVE_TEST_BUNDLE))
+  endif
+  ifdef JPRT_ARCHIVE_SYMBOLS_BUNDLE
+    override JPRT_ARCHIVE_SYMBOLS_BUNDLE := \
+        $(shell $(CYGPATH) -u $(JPRT_ARCHIVE_SYMBOLS_BUNDLE))
   endif
 endif
 
@@ -51,6 +57,9 @@
 ifndef JPRT_ARCHIVE_TEST_BUNDLE
   JPRT_ARCHIVE_TEST_BUNDLE=/tmp/jprt_bundles/test-image.zip
 endif
+ifndef JPRT_ARCHIVE_SYMBOLS_BUNDLE
+  JPRT_ARCHIVE_SYMBOLS_BUNDLE=/tmp/jprt_bundles/symbols-image.zip
+endif
 
 ifeq ($(SKIP_BOOT_CYCLE), false)
   jprt_bundle: bootcycle-images
@@ -59,6 +68,10 @@
 # This target must be called in the context of a SPEC file
 jprt_bundle: $(JPRT_ARCHIVE_BUNDLE) $(JPRT_ARCHIVE_TEST_BUNDLE)
 
+ifeq ($(GCOV_ENABLED), true)
+  jprt_bundle: $(JPRT_ARCHIVE_SYMBOLS_BUNDLE)
+endif
+
 # This target must be called in the context of a SPEC file
 $(JPRT_ARCHIVE_BUNDLE): bundles
 	$(MKDIR) -p $(@D)
@@ -70,6 +83,11 @@
 	$(RM) $@
 	$(CP) $(BUILD_OUTPUT)/bundles/$(TEST_IMAGE_SUBDIR).zip $@
 
+$(JPRT_ARCHIVE_SYMBOLS_BUNDLE): bundles
+	$(MKDIR) -p $(@D)
+	$(RM) $@
+	$(CP) $(BUILD_OUTPUT)/bundles/$(SYMBOLS_IMAGE_SUBDIR).zip $@
+
 SRC_JDK_IMAGE_DIR := $(JDK_IMAGE_DIR)
 SRC_JRE_IMAGE_DIR := $(JRE_IMAGE_DIR)
 SRC_TEST_IMAGE_DIR := $(TEST_IMAGE_DIR)
@@ -80,11 +98,19 @@
 bundles: all
 	@$(call TargetEnter)
 	$(MKDIR) -p $(BUILD_OUTPUT)/bundles
-	$(CD) $(SRC_JDK_IMAGE_DIR) && $(ZIP) -y -q -r $(BUILD_OUTPUT)/bundles/$(JDK_IMAGE_SUBDIR).zip .
-	$(CD) $(SRC_JRE_IMAGE_DIR) && $(ZIP) -y -q -r $(BUILD_OUTPUT)/bundles/$(JRE_IMAGE_SUBDIR).zip .
-	$(CD) $(SRC_TEST_IMAGE_DIR) && $(ZIP) -y -q -r $(BUILD_OUTPUT)/bundles/$(TEST_IMAGE_SUBDIR).zip .
+	$(CD) $(SRC_JDK_IMAGE_DIR) && $(ZIP) -y -q -r \
+	    $(BUILD_OUTPUT)/bundles/$(JDK_IMAGE_SUBDIR).zip .
+	$(CD) $(SRC_JRE_IMAGE_DIR) && $(ZIP) -y -q -r \
+	    $(BUILD_OUTPUT)/bundles/$(JRE_IMAGE_SUBDIR).zip .
+	$(CD) $(SRC_TEST_IMAGE_DIR) && $(ZIP) -y -q -r \
+	    $(BUILD_OUTPUT)/bundles/$(TEST_IMAGE_SUBDIR).zip .
 	if [ -d $(BUILD_OUTPUT)/install/bundles ] ; then \
-	  $(CD) $(BUILD_OUTPUT)/install/bundles && $(ZIP) -y -q -r $(JPRT_ARCHIVE_INSTALL_BUNDLE) . ; \
+	  $(CD) $(BUILD_OUTPUT)/install/bundles && $(ZIP) -y -q -r \
+	      $(JPRT_ARCHIVE_INSTALL_BUNDLE) . ; \
+	fi
+	if [ -d $(SYMBOLS_IMAGE_DIR) ] ; then \
+	  $(CD) $(SYMBOLS_IMAGE_DIR) && $(ZIP) -y -q -r \
+	      $(BUILD_OUTPUT)/bundles/$(SYMBOLS_IMAGE_SUBDIR).zip . ; \
 	fi
 	@$(call TargetExit)
 
--- a/make/Main.gmk	Mon Mar 09 09:49:22 2015 -0700
+++ b/make/Main.gmk	Wed Mar 11 08:30:21 2015 -0700
@@ -531,7 +531,7 @@
 # file.
 
 CLEAN_DIRS += hotspot jdk bootcycle-build test buildtools support \
-    images make-support test-make
+    images make-support test-make bundles
 CLEAN_DIR_TARGETS := $(addprefix clean-, $(CLEAN_DIRS))
 CLEAN_TESTS += hotspot-jtreg-native jdk-jtreg-native
 CLEAN_TEST_TARGETS += $(addprefix clean-test-, $(CLEAN_TESTS))
--- a/make/common/TestFilesCompilation.gmk	Mon Mar 09 09:49:22 2015 -0700
+++ b/make/common/TestFilesCompilation.gmk	Wed Mar 11 08:30:21 2015 -0700
@@ -68,13 +68,13 @@
   ifeq ($$($1_TYPE), LIBRARY)
     $1_PREFIX = lib
     $1_OUTPUT_SUBDIR := lib
-    $1_CFLAGS := $(CFLAGS_JDKLIB) $(CFLAGS_WARNINGS_ARE_ERRORS)
-    $1_LDFLAGS := $(LDFLAGS_JDKLIB) $(call SET_SHARED_LIBRARY_ORIGIN)
+    $1_CFLAGS := $(CFLAGS_TESTLIB) $(CFLAGS_WARNINGS_ARE_ERRORS)
+    $1_LDFLAGS := $(LDFLAGS_TESTLIB) $(call SET_SHARED_LIBRARY_ORIGIN)
   else ifeq ($$($1_TYPE), PROGRAM)
     $1_PREFIX = exe
     $1_OUTPUT_SUBDIR := bin
-    $1_CFLAGS := $(CFLAGS_JDKEXE) $(CFLAGS_WARNINGS_ARE_ERRORS)
-    $1_LDFLAGS := $(LDFLAGS_JDKEXE)
+    $1_CFLAGS := $(CFLAGS_TESTEXE) $(CFLAGS_WARNINGS_ARE_ERRORS)
+    $1_LDFLAGS := $(LDFLAGS_TESTEXE)
   else
     $$(error Unknown type: $$($1_TYPE))
   endif
--- a/test/lib/sun/hotspot/code/BlobType.java	Mon Mar 09 09:49:22 2015 -0700
+++ b/test/lib/sun/hotspot/code/BlobType.java	Wed Mar 11 08:30:21 2015 -0700
@@ -32,15 +32,28 @@
 
 public enum BlobType {
     // Execution level 1 and 4 (non-profiled) nmethods (including native nmethods)
-    MethodNonProfiled(0, "CodeHeap 'non-profiled nmethods'", "NonProfiledCodeHeapSize"),
+    MethodNonProfiled(0, "CodeHeap 'non-profiled nmethods'", "NonProfiledCodeHeapSize") {
+        @Override
+        public boolean allowTypeWhenOverflow(BlobType type) {
+            return super.allowTypeWhenOverflow(type)
+                    || type == BlobType.MethodProfiled;
+        }
+    },
     // Execution level 2 and 3 (profiled) nmethods
-    MethodProfiled(1, "CodeHeap 'profiled nmethods'", "ProfiledCodeHeapSize"),
+    MethodProfiled(1, "CodeHeap 'profiled nmethods'", "ProfiledCodeHeapSize") {
+        @Override
+        public boolean allowTypeWhenOverflow(BlobType type) {
+            return super.allowTypeWhenOverflow(type)
+                    || type == BlobType.MethodNonProfiled;
+        }
+    },
     // Non-nmethods like Buffers, Adapters and Runtime Stubs
     NonNMethod(2, "CodeHeap 'non-nmethods'", "NonNMethodCodeHeapSize") {
         @Override
         public boolean allowTypeWhenOverflow(BlobType type) {
             return super.allowTypeWhenOverflow(type)
-                    || type == BlobType.MethodNonProfiled;
+                    || type == BlobType.MethodNonProfiled
+                    || type == BlobType.MethodProfiled;
         }
     },
     // All types (No code cache segmentation)