changeset 53190:8cc938aa8f74

Merge
author psadhukhan
date Tue, 08 Jan 2019 13:40:57 +0530
parents 7f1d89aac92a 2692d1bfe83a
children a257992e1e4d 2121afe70084
files
diffstat 44 files changed, 485 insertions(+), 233 deletions(-) [+]
line wrap: on
line diff
--- a/.hgtags	Mon Jan 07 11:02:11 2019 +0530
+++ b/.hgtags	Tue Jan 08 13:40:57 2019 +0530
@@ -531,3 +531,4 @@
 11033c4ada542f9c9a873314b6ecf60af19e8256 jdk-13+1
 7496df94b3b79f3da53925d2d137317715f11d97 jdk-12+25
 50677f43ac3df9a8684222b8893543c60f3aa0bd jdk-13+2
+de9fd809bb475401aad188eab2264226788aad81 jdk-12+26
--- a/make/RunTestsPrebuilt.gmk	Mon Jan 07 11:02:11 2019 +0530
+++ b/make/RunTestsPrebuilt.gmk	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2017, 2018, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2017, 2019, 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
@@ -237,7 +237,8 @@
 else ifeq ($(OPENJDK_TARGET_OS), windows)
   NUM_CORES := $(NUMBER_OF_PROCESSORS)
   MEMORY_SIZE := $(shell \
-      $(EXPR) `wmic computersystem get totalphysicalmemory -value | $(GREP) = \
+      $(EXPR) `wmic computersystem get totalphysicalmemory -value \
+          | $(GREP) = | $(SED) 's/\\r//g' \
           | $(CUT) -d "=" -f 2-` / 1024 / 1024 \
   )
 endif
--- a/make/autoconf/flags-cflags.m4	Mon Jan 07 11:02:11 2019 +0530
+++ b/make/autoconf/flags-cflags.m4	Tue Jan 08 13:40:57 2019 +0530
@@ -183,7 +183,8 @@
 
       # Additional warnings that are not activated by -Wall and -Wextra
       WARNINGS_ENABLE_ADDITIONAL="-Wpointer-arith -Wsign-compare \
-          -Wunused-function -Wundef -Wunused-value -Wreturn-type"
+          -Wunused-function -Wundef -Wunused-value -Wreturn-type \
+          -Wtrampolines"
       WARNINGS_ENABLE_ADDITIONAL_CXX="-Woverloaded-virtual -Wreorder"
       WARNINGS_ENABLE_ALL_CFLAGS="-Wall -Wextra -Wformat=2 $WARNINGS_ENABLE_ADDITIONAL"
       WARNINGS_ENABLE_ALL_CXXFLAGS="$WARNINGS_ENABLE_ALL_CFLAGS $WARNINGS_ENABLE_ADDITIONAL_CXX"
--- a/make/autoconf/spec.gmk.in	Mon Jan 07 11:02:11 2019 +0530
+++ b/make/autoconf/spec.gmk.in	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2011, 2019, 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
@@ -729,6 +729,7 @@
 RC:=@FIXPATH@ @RC@
 DUMPBIN:=@FIXPATH@ @DUMPBIN@
 CYGPATH:=@CYGPATH@
+WSLPATH:=@WSLPATH@
 LDD:=@LDD@
 OTOOL:=@OTOOL@
 READELF:=@READELF@
--- a/make/hotspot/ide/CreateVSProject.gmk	Mon Jan 07 11:02:11 2019 +0530
+++ b/make/hotspot/ide/CreateVSProject.gmk	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2016, 2019, 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
@@ -46,8 +46,17 @@
 
   # Helper macro to convert a unix path to a Windows path, suitable for
   # inclusion in a command line.
-  FixPath = \
-    $(strip $(subst \,\\,$(shell $(CYGPATH) -w $1)))
+  ifeq ($(OPENJDK_BUILD_OS_ENV), windows.cygwin)
+    FixPath = \
+        $(strip $(subst \,\\,$(shell $(CYGPATH) -w $1)))
+    FixLinuxExecutable = \
+        $(call FixPath, $1)
+  else ifeq ($(OPENJDK_BUILD_OS_ENV), windows.wsl)
+    FixPath = \
+        $(strip $(subst \,\\,$(shell $(WSLPATH) -w $1)))
+    FixLinuxExecutable = \
+        "%windir%\Sysnative\wsl.exe $1"
+  endif
 
   JVM_DEFINES_client := $(patsubst -D%,%, $(filter -D%, $(JVM_CFLAGS)))
   EXTRACTED_DEFINES_client := $(addprefix -define , $(JVM_DEFINES_client))
@@ -121,7 +130,7 @@
       -platformName x64 \
       -buildBase $(call FixPath, $(IDE_OUTPUTDIR)/vs-output) \
       -buildSpace $(call FixPath, $(IDE_OUTPUTDIR)) \
-      -makeBinary $(call FixPath, $(MAKE)) \
+      -makeBinary $(call FixLinuxExecutable, $(MAKE)) \
       -makeOutput $(call FixPath, $(JDK_OUTPUTDIR)/bin/server) \
       -absoluteInclude $(call FixPath, $(HOTSPOT_OUTPUTDIR)/variant-server/gensrc) \
       -absoluteSrcInclude $(call FixPath, $(HOTSPOT_OUTPUTDIR)/variant-server/gensrc) \
--- a/make/test/BuildMicrobenchmark.gmk	Mon Jan 07 11:02:11 2019 +0530
+++ b/make/test/BuildMicrobenchmark.gmk	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 #
-# Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2018, 2019, 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
@@ -78,7 +78,7 @@
 # Build microbenchmark suite for the current JDK
 $(eval $(call SetupJavaCompilation, BUILD_JDK_MICROBENCHMARK, \
     SETUP := MICROBENCHMARK_JAVA_COMPILER, \
-    ADD_JAVAC_FLAGS := -cp $(MICROBENCHMARK_CLASSPATH) -Xlint -Werror, \
+    ADD_JAVAC_FLAGS := -cp $(MICROBENCHMARK_CLASSPATH) -Xlint -Xlint:-processing -Werror, \
     SRC := $(MICROBENCHMARK_SRC), \
     BIN := $(MICROBENCHMARK_CLASSES), \
 ))
--- a/src/hotspot/cpu/x86/c1_LIRAssembler_x86.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/cpu/x86/c1_LIRAssembler_x86.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -649,7 +649,7 @@
 
     case T_FLOAT: {
       if (dest->is_single_xmm()) {
-        if (LP64_ONLY(UseAVX < 2 &&) c->is_zero_float()) {
+        if (LP64_ONLY(UseAVX <= 2 &&) c->is_zero_float()) {
           __ xorps(dest->as_xmm_float_reg(), dest->as_xmm_float_reg());
         } else {
           __ movflt(dest->as_xmm_float_reg(),
@@ -671,7 +671,7 @@
 
     case T_DOUBLE: {
       if (dest->is_double_xmm()) {
-        if (LP64_ONLY(UseAVX < 2 &&) c->is_zero_double()) {
+        if (LP64_ONLY(UseAVX <= 2 &&) c->is_zero_double()) {
           __ xorpd(dest->as_xmm_double_reg(), dest->as_xmm_double_reg());
         } else {
           __ movdbl(dest->as_xmm_double_reg(),
--- a/src/hotspot/cpu/x86/x86.ad	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/cpu/x86/x86.ad	Tue Jan 08 13:40:57 2019 +0530
@@ -2924,11 +2924,11 @@
   match(Set dst src);
   format %{ "movdqu $dst,$src\t! load vector (16 bytes)" %}
   ins_encode %{
-    if (UseAVX < 2 || VM_Version::supports_avx512vl()) {
-      __ movdqu($dst$$XMMRegister, $src$$XMMRegister);
-    } else {
+    if (UseAVX > 2 && !VM_Version::supports_avx512vl()) {
       int vector_len = 2;
       __ evmovdquq($dst$$XMMRegister, $src$$XMMRegister, vector_len);
+    } else {
+      __ movdqu($dst$$XMMRegister, $src$$XMMRegister);
     }
   %}
   ins_pipe( fpu_reg_reg );
@@ -2939,11 +2939,11 @@
   match(Set dst src);
   format %{ "movdqu $dst,$src\t! load vector (16 bytes)" %}
   ins_encode %{
-    if (UseAVX < 2 || VM_Version::supports_avx512vl()) {
-      __ movdqu($dst$$XMMRegister, $src$$XMMRegister);
-    } else {
+    if (UseAVX > 2 && !VM_Version::supports_avx512vl()) {
       int vector_len = 2;
       __ evmovdquq($dst$$XMMRegister, $src$$XMMRegister, vector_len);
+    } else {
+      __ movdqu($dst$$XMMRegister, $src$$XMMRegister);
     }
   %}
   ins_pipe( fpu_reg_reg );
@@ -2966,11 +2966,11 @@
   match(Set dst src);
   format %{ "vmovdqu $dst,$src\t! load vector (32 bytes)" %}
   ins_encode %{
-    if (UseAVX < 2 || VM_Version::supports_avx512vl()) {
-      __ vmovdqu($dst$$XMMRegister, $src$$XMMRegister);
-    } else {
+    if (UseAVX > 2 && !VM_Version::supports_avx512vl()) {
       int vector_len = 2;
       __ evmovdquq($dst$$XMMRegister, $src$$XMMRegister, vector_len);
+    } else {
+      __ vmovdqu($dst$$XMMRegister, $src$$XMMRegister);
     }
   %}
   ins_pipe( fpu_reg_reg );
@@ -2981,11 +2981,11 @@
   match(Set dst src);
   format %{ "vmovdqu $dst,$src\t! load vector (32 bytes)" %}
   ins_encode %{
-    if (UseAVX < 2 || VM_Version::supports_avx512vl()) {
-      __ vmovdqu($dst$$XMMRegister, $src$$XMMRegister);
-    } else {
+    if (UseAVX > 2 && !VM_Version::supports_avx512vl()) {
       int vector_len = 2;
       __ evmovdquq($dst$$XMMRegister, $src$$XMMRegister, vector_len);
+    } else {
+      __ vmovdqu($dst$$XMMRegister, $src$$XMMRegister);
     }
   %}
   ins_pipe( fpu_reg_reg );
--- a/src/hotspot/os/bsd/os_bsd.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/os/bsd/os_bsd.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2019, 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
@@ -2256,7 +2256,8 @@
 // not the entire user process, and user level threads are 1:1 mapped to kernel
 // threads. It has always been the case, but could change in the future. For
 // this reason, the code should not be used as default (ThreadPriorityPolicy=0).
-// It is only used when ThreadPriorityPolicy=1 and requires root privilege.
+// It is only used when ThreadPriorityPolicy=1 and may require system level permission
+// (e.g., root privilege or CAP_SYS_NICE capability).
 
 #if !defined(__APPLE__)
 int os::java_to_os_priority[CriticalPriority + 1] = {
@@ -2303,14 +2304,12 @@
 
 static int prio_init() {
   if (ThreadPriorityPolicy == 1) {
-    // Only root can raise thread priority. Don't allow ThreadPriorityPolicy=1
-    // if effective uid is not root. Perhaps, a more elegant way of doing
-    // this is to test CAP_SYS_NICE capability, but that will require libcap.so
     if (geteuid() != 0) {
       if (!FLAG_IS_DEFAULT(ThreadPriorityPolicy)) {
-        warning("-XX:ThreadPriorityPolicy requires root privilege on Bsd");
+        warning("-XX:ThreadPriorityPolicy=1 may require system level permission, " \
+                "e.g., being the root user. If the necessary permission is not " \
+                "possessed, changes to priority will be silently ignored.");
       }
-      ThreadPriorityPolicy = 0;
     }
   }
   if (UseCriticalJavaThreadPriority) {
@@ -2327,6 +2326,7 @@
   return OS_OK;
 #elif defined(__FreeBSD__)
   int ret = pthread_setprio(thread->osthread()->pthread_id(), newpri);
+  return (ret == 0) ? OS_OK : OS_ERR;
 #elif defined(__APPLE__) || defined(__NetBSD__)
   struct sched_param sp;
   int policy;
--- a/src/hotspot/os/linux/os_linux.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/os/linux/os_linux.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1999, 2019, 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
@@ -4076,7 +4076,8 @@
 // not the entire user process, and user level threads are 1:1 mapped to kernel
 // threads. It has always been the case, but could change in the future. For
 // this reason, the code should not be used as default (ThreadPriorityPolicy=0).
-// It is only used when ThreadPriorityPolicy=1 and requires root privilege.
+// It is only used when ThreadPriorityPolicy=1 and may require system level permission
+// (e.g., root privilege or CAP_SYS_NICE capability).
 
 int os::java_to_os_priority[CriticalPriority + 1] = {
   19,              // 0 Entry should never be used
@@ -4100,14 +4101,12 @@
 
 static int prio_init() {
   if (ThreadPriorityPolicy == 1) {
-    // Only root can raise thread priority. Don't allow ThreadPriorityPolicy=1
-    // if effective uid is not root. Perhaps, a more elegant way of doing
-    // this is to test CAP_SYS_NICE capability, but that will require libcap.so
     if (geteuid() != 0) {
       if (!FLAG_IS_DEFAULT(ThreadPriorityPolicy)) {
-        warning("-XX:ThreadPriorityPolicy requires root privilege on Linux");
+        warning("-XX:ThreadPriorityPolicy=1 may require system level permission, " \
+                "e.g., being the root user. If the necessary permission is not " \
+                "possessed, changes to priority will be silently ignored.");
       }
-      ThreadPriorityPolicy = 0;
     }
   }
   if (UseCriticalJavaThreadPriority) {
--- a/src/hotspot/share/code/codeHeapState.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/code/codeHeapState.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2018, 2019, Oracle and/or its affiliates. All rights reserved.
  * Copyright (c) 2018 SAP SE. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
@@ -1976,7 +1976,7 @@
     ast->print_cr("  The age of a compiled method in the CodeHeap is not available as a\n"
                   "  time stamp. Instead, a relative age is deducted from the method's compilation ID.\n"
                   "  Age information is available for tier1 and tier2 methods only. There is no\n"
-                  "  age information for stubs and blobs, because they have no compilation ID assigned.\n"
+                  "  age information for stubs and blobs, because they have no compilation ID assigned.\n"
                   "  Information for the youngest method (highest ID) in the granule is printed.\n"
                   "  Refer to the legend to learn how method age is mapped to the displayed digit.");
     print_age_legend(ast);
--- a/src/hotspot/share/compiler/methodMatcher.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/compiler/methodMatcher.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2019, 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
@@ -237,6 +237,12 @@
   }
 }
 
+#ifdef _MSC_VER
+#pragma warning(push)
+// warning C4189: The file contains a character that cannot be represented
+//                in the current code page
+#pragma warning(disable : 4819)
+#endif
 void MethodMatcher::parse_method_pattern(char*& line, const char*& error_msg, MethodMatcher* matcher) {
   MethodMatcher::Mode c_match;
   MethodMatcher::Mode m_match;
@@ -306,6 +312,9 @@
     error_msg = "Could not parse method pattern";
   }
 }
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
 
 bool MethodMatcher::matches(const methodHandle& method) const {
   Symbol* class_name  = method->method_holder()->name();
--- a/src/hotspot/share/gc/z/zReferenceProcessor.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/gc/z/zReferenceProcessor.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2019, 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
@@ -68,9 +68,9 @@
   java_lang_ref_SoftReference::set_clock(now);
 }
 
-bool ZReferenceProcessor::is_reference_inactive(oop obj) const {
-  // A non-null next field means the reference is inactive
-  return java_lang_ref_Reference::next(obj) != NULL;
+bool ZReferenceProcessor::is_inactive_final_reference(oop obj, ReferenceType type) const {
+  // A non-null next field for a FinalReference means the reference is inactive.
+  return (type == REF_FINAL) && (java_lang_ref_Reference::next(obj) != NULL);
 }
 
 ReferenceType ZReferenceProcessor::reference_type(oop obj) const {
@@ -167,11 +167,6 @@
   return type == REF_FINAL;
 }
 
-bool ZReferenceProcessor::should_clear_referent(ReferenceType type) const {
-  // Referents that were not marked must be cleared
-  return !should_mark_referent(type);
-}
-
 void ZReferenceProcessor::keep_referent_alive(oop obj, ReferenceType type) const {
   volatile oop* const p = reference_referent_addr(obj);
   if (type == REF_PHANTOM) {
@@ -192,8 +187,8 @@
   // Update statistics
   _encountered_count.get()[type]++;
 
-  if (is_reference_inactive(obj) ||
-      is_referent_strongly_alive_or_null(obj, type) ||
+  if (is_referent_strongly_alive_or_null(obj, type) ||
+      is_inactive_final_reference(obj, type) ||
       is_referent_softly_alive(obj, type)) {
     // Not discovered
     return false;
@@ -242,23 +237,19 @@
   // Update statistics
   _enqueued_count.get()[type]++;
 
-  // Clear referent
-  if (should_clear_referent(type)) {
+  if (type != REF_FINAL) {
+    // Clear referent
     java_lang_ref_Reference::set_referent(obj, NULL);
+  } else {
+    // For a FinalReference, don't clear the referent, because it is
+    // needed for the finalize call.  Instead, make the reference
+    // inactive by self-looping the 'next' field.  FinalReference
+    // doesn't allow Reference.enqueue, so there's no race to worry
+    // about when setting 'next'.
+    assert(java_lang_ref_Reference::next(obj) == NULL, "enqueued FinalReference");
+    java_lang_ref_Reference::set_next_raw(obj, obj);
   }
 
-  // Make reference inactive by self-looping the next field. We could be racing with a
-  // call to Reference.enqueue() from the application, which is why we are using a CAS
-  // to make sure we change the next field only if it is NULL. A failing CAS means the
-  // reference has already been enqueued. However, we don't check the result of the CAS,
-  // since we still have no option other than keeping the reference on the pending list.
-  // It's ok to have the reference both on the pending list and enqueued at the same
-  // time (the pending list is linked through the discovered field, while the reference
-  // queue is linked through the next field). When the ReferenceHandler thread later
-  // calls Reference.enqueue() we detect that it has already been enqueued and drop it.
-  oop* const next_addr = (oop*)java_lang_ref_Reference::next_addr_raw(obj);
-  Atomic::cmpxchg(obj, next_addr, oop(NULL));
-
   // Return next in list
   return (oop*)java_lang_ref_Reference::discovered_addr_raw(obj);
 }
--- a/src/hotspot/share/gc/z/zReferenceProcessor.hpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/gc/z/zReferenceProcessor.hpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2019, 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
@@ -52,12 +52,11 @@
   const char* reference_type_name(ReferenceType type) const;
   volatile oop* reference_referent_addr(oop obj) const;
   oop reference_referent(oop obj) const;
-  bool is_reference_inactive(oop obj) const;
+  bool is_inactive_final_reference(oop obj, ReferenceType type) const;
   bool is_referent_strongly_alive_or_null(oop obj, ReferenceType type) const;
   bool is_referent_softly_alive(oop obj, ReferenceType type) const;
   bool should_drop_reference(oop obj, ReferenceType type) const;
   bool should_mark_referent(ReferenceType type) const;
-  bool should_clear_referent(ReferenceType type) const;
   void keep_referent_alive(oop obj, ReferenceType type) const;
 
   void discover(oop obj, ReferenceType type);
--- a/src/hotspot/share/jfr/recorder/checkpoint/types/jfrTypeSetUtils.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/jfr/recorder/checkpoint/types/jfrTypeSetUtils.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -164,7 +164,7 @@
 uintptr_t JfrSymbolId::unsafe_anonymous_klass_name_hash_code(const InstanceKlass* ik) {
   assert(ik != NULL, "invariant");
   assert(ik->is_unsafe_anonymous(), "invariant");
-  const oop mirror = ik->java_mirror();
+  const oop mirror = ik->java_mirror_no_keepalive();
   assert(mirror != NULL, "invariant");
   return (uintptr_t)mirror->identity_hash();
 }
@@ -174,7 +174,7 @@
   assert(ik->is_unsafe_anonymous(), "invariant");
   assert(0 == hashcode, "invariant");
   char* anonymous_symbol = NULL;
-  const oop mirror = ik->java_mirror();
+  const oop mirror = ik->java_mirror_no_keepalive();
   assert(mirror != NULL, "invariant");
   char hash_buf[40];
   hashcode = unsafe_anonymous_klass_name_hash_code(ik);
--- a/src/hotspot/share/oops/metadata.hpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/oops/metadata.hpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2011, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2011, 2019, 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
@@ -39,9 +39,6 @@
 
   int identity_hash()                { return (int)(uintptr_t)this; }
 
-  // Rehashing support for tables containing pointers to this
-  unsigned int new_hash(juint seed)   { ShouldNotReachHere();  return 0; }
-
   virtual bool is_metadata()           const volatile { return true; }
   virtual bool is_klass()              const volatile { return false; }
   virtual bool is_method()             const volatile { return false; }
--- a/src/hotspot/share/oops/oop.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/oops/oop.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2019, 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
@@ -97,21 +97,6 @@
   return ObjectSynchronizer::identity_hash_value_for(object);
 }
 
-// When String table needs to rehash
-unsigned int oopDesc::new_hash(juint seed) {
-  EXCEPTION_MARK;
-  ResourceMark rm;
-  int length;
-  jchar* chars = java_lang_String::as_unicode_string(this, length, THREAD);
-  if (chars != NULL) {
-    // Use alternate hashing algorithm on the string
-    return AltHashing::murmur3_32(seed, chars, length);
-  } else {
-    vm_exit_out_of_memory(length, OOM_MALLOC_ERROR, "unable to create Unicode strings for String table rehash");
-    return 0;
-  }
-}
-
 // used only for asserts and guarantees
 bool oopDesc::is_oop(oop obj, bool ignore_mark_word) {
   if (!Universe::heap()->is_oop(obj)) {
--- a/src/hotspot/share/oops/oop.hpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/oops/oop.hpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2019, 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
@@ -308,9 +308,6 @@
   inline intptr_t identity_hash();
   intptr_t slow_identity_hash();
 
-  // Alternate hashing code if string table is rehashed
-  unsigned int new_hash(juint seed);
-
   // marks are forwarded to stack when object is locked
   inline bool    has_displaced_mark_raw() const;
   inline markOop displaced_mark_raw() const;
--- a/src/hotspot/share/oops/symbol.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/oops/symbol.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2019, 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
@@ -212,13 +212,6 @@
   return str;
 }
 
-// Alternate hashing for unbalanced symbol tables.
-unsigned int Symbol::new_hash(juint seed) {
-  ResourceMark rm;
-  // Use alternate hashing algorithm on this symbol.
-  return AltHashing::murmur3_32(seed, (const jbyte*)as_C_string(), utf8_length());
-}
-
 // Increment refcount while checking for zero.  If the Symbol's refcount becomes zero
 // a thread could be concurrently removing the Symbol.  This is used during SymbolTable
 // lookup to avoid reviving a dead Symbol.
--- a/src/hotspot/share/oops/symbol.hpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/oops/symbol.hpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2019, 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
@@ -164,9 +164,6 @@
            ((addr_bits ^ (length() << 8) ^ (( _body[0] << 8) | _body[1])) << 16);
   }
 
-  // For symbol table alternate hashing
-  unsigned int new_hash(juint seed);
-
   // Reference counting.  See comments above this class for when to use.
   int refcount() const { return extract_refcount(_length_and_refcount); }
   bool try_increment_refcount();
--- a/src/hotspot/share/opto/loopTransform.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/opto/loopTransform.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -354,6 +354,10 @@
   // check for vectorized loops, any peeling done was already applied
   if (_head->is_CountedLoop() && _head->as_CountedLoop()->do_unroll_only()) return false;
 
+  if (_head->is_CountedLoop() && _head->as_CountedLoop()->trip_count() == 1) {
+    return false;
+  }
+
   while( test != _head ) {      // Scan till run off top of loop
     if( test->is_If() ) {       // Test?
       Node *ctrl = phase->get_ctrl(test->in(1));
@@ -2035,13 +2039,20 @@
 
 //------------------------------adjust_limit-----------------------------------
 // Helper function for add_constraint().
-Node* PhaseIdealLoop::adjust_limit(int stride_con, Node * scale, Node *offset, Node *rc_limit, Node *loop_limit, Node *pre_ctrl) {
+Node* PhaseIdealLoop::adjust_limit(int stride_con, Node * scale, Node *offset, Node *rc_limit, Node *loop_limit, Node *pre_ctrl, bool round_up) {
   // Compute "I :: (limit-offset)/scale"
   Node *con = new SubINode(rc_limit, offset);
   register_new_node(con, pre_ctrl);
   Node *X = new DivINode(0, con, scale);
   register_new_node(X, pre_ctrl);
 
+  // When the absolute value of scale is greater than one, the integer
+  // division may round limit down so add one to the limit.
+  if (round_up) {
+    X = new AddINode(X, _igvn.intcon(1));
+    register_new_node(X, pre_ctrl);
+  }
+
   // Adjust loop limit
   loop_limit = (stride_con > 0)
                ? (Node*)(new MinINode(loop_limit, X))
@@ -2082,7 +2093,7 @@
     // (upper_limit-offset) may overflow or underflow.
     // But it is fine since main loop will either have
     // less iterations or will be skipped in such case.
-    *main_limit = adjust_limit(stride_con, scale, offset, upper_limit, *main_limit, pre_ctrl);
+    *main_limit = adjust_limit(stride_con, scale, offset, upper_limit, *main_limit, pre_ctrl, false);
 
     // The underflow limit: low_limit <= scale*I+offset.
     // For pre-loop compute
@@ -2117,7 +2128,8 @@
       // max(pre_limit, original_limit) is used in do_range_check().
     }
     // Pass (-stride) to indicate pre_loop_cond = NOT(main_loop_cond);
-    *pre_limit = adjust_limit((-stride_con), scale, offset, low_limit, *pre_limit, pre_ctrl);
+    *pre_limit = adjust_limit((-stride_con), scale, offset, low_limit, *pre_limit, pre_ctrl,
+                              scale_con > 1 && stride_con > 0);
 
   } else { // stride_con*scale_con < 0
     // For negative stride*scale pre-loop checks for overflow and
@@ -2143,7 +2155,8 @@
     Node *plus_one = new AddINode(offset, one);
     register_new_node( plus_one, pre_ctrl );
     // Pass (-stride) to indicate pre_loop_cond = NOT(main_loop_cond);
-    *pre_limit = adjust_limit((-stride_con), scale, plus_one, upper_limit, *pre_limit, pre_ctrl);
+    *pre_limit = adjust_limit((-stride_con), scale, plus_one, upper_limit, *pre_limit, pre_ctrl,
+                              scale_con < -1 && stride_con > 0);
 
     if (low_limit->get_int() == -max_jint) {
       // We need this guard when scale*main_limit+offset >= limit
@@ -2177,7 +2190,8 @@
     //       I > (low_limit-(offset+1))/scale
     //   )
 
-    *main_limit = adjust_limit(stride_con, scale, plus_one, low_limit, *main_limit, pre_ctrl);
+    *main_limit = adjust_limit(stride_con, scale, plus_one, low_limit, *main_limit, pre_ctrl,
+                               false);
   }
 }
 
--- a/src/hotspot/share/opto/loopnode.hpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/opto/loopnode.hpp	Tue Jan 08 13:40:57 2019 +0530
@@ -1190,7 +1190,7 @@
   // loop.  Scale_con, offset and limit are all loop invariant.
   void add_constraint( int stride_con, int scale_con, Node *offset, Node *low_limit, Node *upper_limit, Node *pre_ctrl, Node **pre_limit, Node **main_limit );
   // Helper function for add_constraint().
-  Node* adjust_limit( int stride_con, Node * scale, Node *offset, Node *rc_limit, Node *loop_limit, Node *pre_ctrl );
+  Node* adjust_limit(int stride_con, Node * scale, Node *offset, Node *rc_limit, Node *loop_limit, Node *pre_ctrl, bool round_up);
 
   // Partially peel loop up through last_peel node.
   bool partial_peel( IdealLoopTree *loop, Node_List &old_new );
--- a/src/hotspot/share/runtime/arguments.cpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/runtime/arguments.cpp	Tue Jan 08 13:40:57 2019 +0530
@@ -3088,6 +3088,10 @@
       BytecodeVerificationRemote = true;
       log_info(cds)("All non-system classes will be verified (-Xverify:remote) during CDS dump time.");
     }
+
+    // Compilation is already disabled if the user specifies -Xshare:dump.
+    // Disable compilation in case user specifies -XX:+DumpSharedSpaces instead of -Xshare:dump.
+    set_mode_flags(_int);
   }
   if (UseSharedSpaces && patch_mod_javabase) {
     no_shared_spaces("CDS is disabled when " JAVA_BASE_NAME " module is patched.");
--- a/src/hotspot/share/runtime/globals.hpp	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/hotspot/share/runtime/globals.hpp	Tue Jan 08 13:40:57 2019 +0530
@@ -2049,7 +2049,8 @@
           "    to higher native thread priorities. This policy should be   "\
           "    used with care, as sometimes it can cause performance       "\
           "    degradation in the application and/or the entire system. On "\
-          "    Linux this policy requires root privilege.")                 \
+          "    Linux/BSD/macOS this policy requires root privilege or an   "\
+          "    extended capability.")                                       \
           range(0, 1)                                                       \
                                                                             \
   product(bool, ThreadPriorityVerbose, false,                               \
--- a/src/java.base/share/classes/java/lang/System.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/java.base/share/classes/java/lang/System.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1994, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1994, 2019, 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
@@ -984,7 +984,7 @@
      * <p>If a security manager exists, its
      * {@link SecurityManager#checkPermission checkPermission}
      * method is called with a
-     * {@code {@link RuntimePermission}("getenv."+name)}
+     * {@link RuntimePermission RuntimePermission("getenv."+name)}
      * permission.  This may result in a {@link SecurityException}
      * being thrown.  If no exception is thrown the value of the
      * variable {@code name} is returned.
@@ -1055,7 +1055,7 @@
      * <p>If a security manager exists, its
      * {@link SecurityManager#checkPermission checkPermission}
      * method is called with a
-     * {@code {@link RuntimePermission}("getenv.*")} permission.
+     * {@link RuntimePermission RuntimePermission("getenv.*")} permission.
      * This may result in a {@link SecurityException} being thrown.
      *
      * <p>When passing information to a Java subprocess,
--- a/src/java.base/windows/classes/java/lang/ProcessImpl.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/java.base/windows/classes/java/lang/ProcessImpl.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1995, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1995, 2019, 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
@@ -106,6 +106,7 @@
         FileOutputStream f2 = null;
 
         try {
+            boolean forceNullOutputStream = false;
             long[] stdHandles;
             if (redirects == null) {
                 stdHandles = new long[] { -1L, -1L, -1L };
@@ -129,6 +130,9 @@
                     stdHandles[1] = fdAccess.getHandle(FileDescriptor.out);
                 } else if (redirects[1] instanceof ProcessBuilder.RedirectPipeImpl) {
                     stdHandles[1] = fdAccess.getHandle(((ProcessBuilder.RedirectPipeImpl) redirects[1]).getFd());
+                    // Force getInputStream to return a null stream,
+                    // the handle is directly assigned to the next process.
+                    forceNullOutputStream = true;
                 } else {
                     f1 = newFileOutputStream(redirects[1].file(),
                                              redirects[1].append());
@@ -149,7 +153,7 @@
             }
 
             Process p = new ProcessImpl(cmdarray, envblock, dir,
-                                   stdHandles, redirectErrorStream);
+                                   stdHandles, forceNullOutputStream, redirectErrorStream);
             if (redirects != null) {
                 // Copy the handles's if they are to be redirected to another process
                 if (stdHandles[0] >= 0
@@ -349,6 +353,7 @@
                         final String envblock,
                         final String path,
                         final long[] stdHandles,
+                        boolean forceNullOutputStream,
                         final boolean redirectErrorStream)
         throws IOException
     {
@@ -437,7 +442,7 @@
                     new FileOutputStream(stdin_fd));
             }
 
-            if (stdHandles[1] == -1L)
+            if (stdHandles[1] == -1L || forceNullOutputStream)
                 stdout_stream = ProcessBuilder.NullInputStream.INSTANCE;
             else {
                 FileDescriptor stdout_fd = new FileDescriptor();
--- a/src/jdk.compiler/share/classes/com/sun/tools/doclint/HtmlTag.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/jdk.compiler/share/classes/com/sun/tools/doclint/HtmlTag.java	Tue Jan 08 13:40:57 2019 +0530
@@ -305,6 +305,8 @@
     STRONG(BlockType.INLINE, EndKind.REQUIRED,
             EnumSet.of(Flag.EXPECT_CONTENT)),
 
+    STYLE(BlockType.OTHER, EndKind.REQUIRED),
+
     SUB(BlockType.INLINE, EndKind.REQUIRED,
             EnumSet.of(Flag.EXPECT_CONTENT, Flag.NO_NEST)),
 
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DocFilesHandlerImpl.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DocFilesHandlerImpl.java	Tue Jan 08 13:40:57 2019 +0530
@@ -31,6 +31,7 @@
 import com.sun.source.doctree.EndElementTree;
 import com.sun.source.doctree.StartElementTree;
 import com.sun.source.doctree.TextTree;
+import com.sun.source.util.DocTreeFactory;
 import com.sun.source.util.SimpleDocTreeVisitor;
 import com.sun.tools.doclint.HtmlTag;
 import com.sun.tools.doclint.HtmlTag.Attr;
@@ -43,6 +44,7 @@
 import jdk.javadoc.internal.doclets.toolkit.util.DocFileIOException;
 import jdk.javadoc.internal.doclets.toolkit.util.DocPath;
 import jdk.javadoc.internal.doclets.toolkit.util.DocPaths;
+import jdk.javadoc.internal.doclets.toolkit.util.DocletConstants;
 import jdk.javadoc.internal.doclets.toolkit.util.Utils;
 
 import javax.lang.model.element.Element;
@@ -51,6 +53,7 @@
 import javax.tools.FileObject;
 import javax.tools.JavaFileManager.Location;
 
+import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
 
@@ -140,13 +143,12 @@
                             srcfile.getPath(), dstdir.getPath());
                 } else {
                     if (Utils.toLowerCase(srcfile.getPath()).endsWith(".html")) {
-                        if (handleHtmlFile(srcfile, dstDocPath)) {
-                            continue;
-                        }
+                        handleHtmlFile(srcfile, dstDocPath);
+                    } else {
+                        configuration.messages.notice("doclet.Copying_File_0_To_Dir_1",
+                                srcfile.getPath(), dstdir.getPath());
+                        destfile.copyFile(srcfile);
                     }
-                    configuration.messages.notice("doclet.Copying_File_0_To_Dir_1",
-                            srcfile.getPath(), dstdir.getPath());
-                    destfile.copyFile(srcfile);
                 }
             } else if (srcfile.isDirectory()) {
                 if (configuration.copydocfilesubdirs
@@ -158,19 +160,18 @@
         }
     }
 
-    private boolean handleHtmlFile(DocFile srcfile, DocPath dstPath) throws DocFileIOException {
+    private void handleHtmlFile(DocFile srcfile, DocPath dstPath) throws DocFileIOException {
         Utils utils = configuration.utils;
         FileObject fileObject = srcfile.getFileObject();
         DocFileElement dfElement = new DocFileElement(element, fileObject);
 
-        if (shouldPassThrough(utils.getPreamble(dfElement))) {
-            return false;
-        }
-
         DocPath dfilePath = dstPath.resolve(srcfile.getName());
         HtmlDocletWriter docletWriter = new DocFileWriter(configuration, dfilePath, element);
         configuration.messages.notice("doclet.Generating_0", docletWriter.filename.getPath());
 
+        List<? extends DocTree> localTags = getLocalHeaderTags(utils.getPreamble(dfElement));
+        Content localTagsContent = docletWriter.commentTagsToContent(null, dfElement, localTags, false);
+
         String title = getWindowTitle(docletWriter, dfElement).trim();
         HtmlTree htmlContent = docletWriter.getBody(true, title);
         docletWriter.addTop(htmlContent);
@@ -193,70 +194,61 @@
         navBar.setUserFooter(docletWriter.getUserHeaderFooter(false));
         htmlContent.addContent(navBar.getContent(false));
         docletWriter.addBottom(htmlContent);
-        docletWriter.printHtmlDocument(Collections.emptyList(), false, htmlContent);
-        return true;
+        docletWriter.printHtmlDocument(Collections.emptyList(), false, localTagsContent, htmlContent);
     }
 
 
-    private boolean shouldPassThrough(List<? extends DocTree> dtrees) {
-        SimpleDocTreeVisitor<Boolean, Boolean> check = new SimpleDocTreeVisitor<Boolean, Boolean>() {
-            @Override
-            public Boolean visitStartElement(StartElementTree node, Boolean p) {
-                if (Utils.toLowerCase(node.getName().toString()).equals((Attr.STYLE.getText()))) {
-                    return true;
-                }
-                if (Utils.toLowerCase(node.getName().toString()).equals(HtmlTag.LINK.getText())) {
-                    for (DocTree dt : node.getAttributes()) {
-                        if (this.visit(dt, true))
-                            return true;
+    private List<? extends DocTree> getLocalHeaderTags(List<? extends DocTree> dtrees) {
+        List<DocTree> localTags = new ArrayList<>();
+        DocTreeFactory docTreeFactory = configuration.docEnv.getDocTrees().getDocTreeFactory();
+        boolean inHead = false;
+        boolean inTitle = false;
+        loop:
+        for (DocTree dt : dtrees) {
+            switch (dt.getKind()) {
+                case START_ELEMENT:
+                    StartElementTree startElem = (StartElementTree)dt;
+                    switch (HtmlTag.get(startElem.getName())) {
+                        case HEAD:
+                            inHead = true;
+                            break;
+                        case META:
+                            break;
+                        case TITLE:
+                            inTitle = true;
+                            break;
+                        default:
+                            if (inHead) {
+                                localTags.add(startElem);
+                                localTags.add(docTreeFactory.newTextTree(DocletConstants.NL));
+                            }
                     }
-                }
-                return false;
+                    break;
+                case END_ELEMENT:
+                    EndElementTree endElem = (EndElementTree)dt;
+                    switch (HtmlTag.get(endElem.getName())) {
+                        case HEAD:
+                            inHead = false;
+                            break loop;
+                        case TITLE:
+                            inTitle = false;
+                            break;
+                        default:
+                            if (inHead) {
+                                localTags.add(endElem);
+                                localTags.add(docTreeFactory.newTextTree(DocletConstants.NL));
+                            }
+                    }
+                    break;
+                case ENTITY:
+                case TEXT:
+                    if (inHead && !inTitle) {
+                        localTags.add(dt);
+                    }
+                    break;
             }
-
-            @Override
-            public Boolean visitAttribute(AttributeTree node, Boolean p) {
-                if (p == null || p == false) {
-                    return false;
-                }
-                if (Utils.toLowerCase(node.getName().toString()).equals("rel")) {
-                    for (DocTree dt :  node.getValue()) {
-                        Boolean found = new SimpleDocTreeVisitor<Boolean, ValueKind>() {
-
-                            @Override
-                            public Boolean visitText(TextTree node, ValueKind valueKind) {
-                                switch (valueKind) {
-                                    case EMPTY:
-                                        return false;
-                                    default:
-                                        return Utils.toLowerCase(node.getBody()).equals("stylesheet");
-                                }
-                            }
-
-                            @Override
-                            protected Boolean defaultAction(DocTree node, ValueKind valueKind) {
-                                return false;
-                            }
-
-                        }.visit(dt, node.getValueKind());
-
-                        if (found)
-                            return true;
-                    }
-                }
-                return false;
-            }
-
-            @Override
-            protected Boolean defaultAction(DocTree node, Boolean p) {
-                return false;
-            }
-        };
-        for (DocTree dt : dtrees) {
-            if (check.visit(dt, false))
-                return true;
         }
-        return false;
+        return localTags;
     }
 
     private String getWindowTitle(HtmlDocletWriter docletWriter, Element element) {
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java	Tue Jan 08 13:40:57 2019 +0530
@@ -427,7 +427,24 @@
      * @throws DocFileIOException if there is a problem writing the file
      */
     public void printHtmlDocument(List<String> metakeywords, boolean includeScript,
-            Content body) throws DocFileIOException {
+                                  Content body) throws DocFileIOException {
+        printHtmlDocument(metakeywords, includeScript, new ContentBuilder(), body);
+    }
+
+    /**
+     * Generates the HTML document tree and prints it out.
+     *
+     * @param metakeywords Array of String keywords for META tag. Each element
+     *                     of the array is assigned to a separate META tag.
+     *                     Pass in null for no array
+     * @param includeScript true if printing windowtitle script
+     *                      false for files that appear in the left-hand frames
+     * @param extraContent any additional content to be included in the HEAD element
+     * @param body the body htmltree to be included in the document
+     * @throws DocFileIOException if there is a problem writing the file
+     */
+    public void printHtmlDocument(List<String> metakeywords, boolean includeScript, Content extraContent,
+                                  Content body) throws DocFileIOException {
         DocType htmlDocType = DocType.forVersion(configuration.htmlVersion);
         Content htmlComment = contents.newPage;
         Head head = new Head(path, configuration.htmlVersion, configuration.docletVersion)
@@ -437,7 +454,8 @@
                 .addKeywords(metakeywords)
                 .setStylesheets(configuration.getMainStylesheet(), configuration.getAdditionalStylesheets())
                 .setUseModuleDirectories(configuration.useModuleDirectories)
-                .setIndex(configuration.createindex, mainBodyScript);
+                .setIndex(configuration.createindex, mainBodyScript)
+                .addContent(extraContent);
 
         Content htmlTree = HtmlTree.HTML(configuration.getLocale().getLanguage(), head.toContent(), body);
         HtmlDocument htmlDocument = new HtmlDocument(htmlDocType, htmlComment, htmlTree);
--- a/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/Head.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/markup/Head.java	Tue Jan 08 13:40:57 2019 +0530
@@ -254,10 +254,6 @@
             tree.addContent(HtmlTree.META("keywords", k));
         }
 
-        for (Content c : extraContent) {
-            tree.addContent(c);
-        }
-
         if (canonicalLink != null) {
             HtmlTree link = new HtmlTree(HtmlTag.LINK);
             link.addAttr(HtmlAttr.REL, "canonical");
@@ -267,6 +263,7 @@
 
         addStylesheets(tree);
         addScripts(tree);
+        extraContent.forEach(tree::addContent);
 
         return tree;
     }
--- a/test/hotspot/jtreg/ProblemList.txt	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/ProblemList.txt	Tue Jan 08 13:40:57 2019 +0530
@@ -61,6 +61,8 @@
 
 compiler/runtime/Test8168712.java 8211769,8211771 generic-ppc64,generic-ppc64le,linux-s390x
 
+compiler/loopopts/PeelingZeroTripCount.java 8216135 generic-all
+
 #############################################################################
 
 # :hotspot_gc
@@ -85,6 +87,7 @@
 runtime/appcds/javaldr/GCDuringDump.java 8208778 macosx-x64
 runtime/appcds/jigsaw/classpathtests/EmptyClassInBootClassPath.java 8213299 generic-all
 runtime/CompressedOops/UseCompressedOops.java 8079353 generic-all
+runtime/handshake/HandshakeWalkSuspendExitTest.java 8214174 generic-all
 runtime/RedefineTests/RedefineRunningMethods.java 8208778 macosx-x64
 runtime/SharedArchiveFile/SASymbolTableTest.java 8193639 solaris-all
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/hotspot/jtreg/compiler/loopopts/PeelingZeroTripCount.java	Tue Jan 08 13:40:57 2019 +0530
@@ -0,0 +1,56 @@
+/*
+ * Copyright (c) 2018, Red Hat, Inc. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8215044
+ * @summary C2 crash in loopTransform.cpp with assert(cl->trip_count() > 0) failed: peeling a fully unrolled loop
+ *
+ * @run main/othervm -XX:CompileOnly=PeelingZeroTripCount.test PeelingZeroTripCount
+ *
+ */
+
+public class PeelingZeroTripCount {
+
+    public static void main(String[] args) {
+        PeelingZeroTripCount issue = new PeelingZeroTripCount();
+        for (int i = 0; i < 10000; i++) {
+            issue.test(new int[999]);
+        }
+    }
+
+    public void test(int[] iaarg) {
+        int[] iarr = new int[777];
+        for (int i = 4; i > 0; i--) {
+            for (int j = 0; j <= i - 1; j++) {
+                int istep = 2 * j - i + 1;
+                int iadj = 0;
+                if (istep < 0) {
+                    iadj = iarr[0-istep] + iaarg[i-1];
+                } else {
+                    iadj = iarr[istep] + iaarg[i-1];
+                }
+            }
+        }
+    }
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test/hotspot/jtreg/compiler/rangechecks/RangeCheckEliminationScaleNotOne.java	Tue Jan 08 13:40:57 2019 +0530
@@ -0,0 +1,100 @@
+/*
+ * Copyright (c) 2018, Red Hat, Inc. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 only, as
+ * published by the Free Software Foundation.
+ *
+ * This code is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ * version 2 for more details (a copy is included in the LICENSE file that
+ * accompanied this code).
+ *
+ * You should have received a copy of the GNU General Public License version
+ * 2 along with this work; if not, write to the Free Software Foundation,
+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
+ * or visit www.oracle.com if you need additional information or have any
+ * questions.
+ */
+
+/*
+ * @test
+ * @bug 8215265
+ * @summary C2: range check elimination may allow illegal out of bound access
+ *
+ * @run main/othervm -XX:-TieredCompilation -XX:-BackgroundCompilation -XX:-UseOnStackReplacement -XX:-UseLoopPredicate RangeCheckEliminationScaleNotOne
+ *
+ */
+
+import java.util.Arrays;
+
+public class RangeCheckEliminationScaleNotOne {
+    public static void main(String[] args) {
+        {
+            int[] array = new int[199];
+            boolean[] flags = new boolean[100];
+            Arrays.fill(flags, true);
+            flags[0] = false;
+            flags[1] = false;
+            for (int i = 0; i < 20_000; i++) {
+                test1(100, array, 0, flags);
+            }
+            boolean ex = false;
+            try {
+                test1(100, array, -5, flags);
+            } catch (ArrayIndexOutOfBoundsException aie) {
+                ex = true;
+            }
+            if (!ex) {
+                throw new RuntimeException("no AIOOB exception");
+            }
+        }
+
+        {
+            int[] array = new int[199];
+            boolean[] flags = new boolean[100];
+            Arrays.fill(flags, true);
+            flags[0] = false;
+            flags[1] = false;
+            for (int i = 0; i < 20_000; i++) {
+                test2(100, array, 198, flags);
+            }
+            boolean ex = false;
+            try {
+                test2(100, array, 203, flags);
+            } catch (ArrayIndexOutOfBoundsException aie) {
+                ex = true;
+            }
+            if (!ex) {
+                throw new RuntimeException("no AIOOB exception");
+            }
+        }
+    }
+
+    private static int test1(int stop, int[] array, int offset, boolean[] flags) {
+        if (array == null) {}
+        int res = 0;
+        for (int i = 0; i < stop; i++) {
+            if (flags[i]) {
+                res += array[2 * i + offset];
+            }
+        }
+        return res;
+    }
+
+
+    private static int test2(int stop, int[] array, int offset, boolean[] flags) {
+        if (array == null) {}
+        int res = 0;
+        for (int i = 0; i < stop; i++) {
+            if (flags[i]) {
+                res += array[-2 * i + offset];
+            }
+        }
+        return res;
+    }
+}
--- a/test/hotspot/jtreg/runtime/SharedArchiveFile/SharedArchiveFile.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/runtime/SharedArchiveFile/SharedArchiveFile.java	Tue Jan 08 13:40:57 2019 +0530
@@ -47,6 +47,13 @@
         OutputAnalyzer out = CDSTestUtils.executeAndLog(pb, "SharedArchiveFile");
         CDSTestUtils.checkDump(out);
 
+        // -XX:+DumpSharedSpaces should behave the same as -Xshare:dump
+        pb = ProcessTools.createJavaProcessBuilder(true,
+                                "-XX:SharedArchiveFile=./SharedArchiveFile.jsa",
+                                "-XX:+DumpSharedSpaces");
+        out = CDSTestUtils.executeAndLog(pb, "SharedArchiveFile");
+        CDSTestUtils.checkDump(out);
+
         pb = ProcessTools.createJavaProcessBuilder(true,
                               "-XX:SharedArchiveFile=./SharedArchiveFile.jsa",
                               "-Xshare:on", "-version");
--- a/test/hotspot/jtreg/vmTestbase/nsk/jdi/AttachingConnector/attach/attach002.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jdi/AttachingConnector/attach/attach002.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2019, 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
@@ -203,6 +203,6 @@
                 return connector;
             }
         }
-        throw new Error("No appropriate connector");
+        throw new Error("No appropriate connector: " + connectorName);
     }
 }
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/Allocate/alloc001/TestDescription.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/Allocate/alloc001/TestDescription.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2018, 2019, 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
@@ -21,6 +21,7 @@
  * questions.
  */
 
+// Not run on AIX as it does not support ulimit -v.
 
 /*
  * @test
@@ -40,6 +41,7 @@
  *
  * @library /vmTestbase
  *          /test/lib
+ * @requires os.family != "aix"
  * @run driver jdk.test.lib.FileInstaller . .
  * @build nsk.jvmti.Allocate.alloc001
  * @run shell alloc001.sh
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/Allocate/alloc001/alloc001.bash	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/Allocate/alloc001/alloc001.bash	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 #!/bin/bash
-# Copyright (c) 2008, 2018, Oracle and/or its affiliates. All rights reserved.
+# Copyright (c) 2008, 2019, 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
@@ -41,7 +41,8 @@
         max_ulimit=1048576
         max_heap=256m
     else
-        max_ulimit=4194304
+        # AIX requires a 32-bit value here.
+        max_ulimit=4194303
         max_heap=512m
     fi
 
@@ -74,6 +75,7 @@
 
 export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:$TESTNATIVEPATH
 export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$TESTNATIVEPATH
+export LIBPATH=$LIBPATH:$TESTNATIVEPATH
 export PATH=$PATH:$TESTNATIVEPATH
 
 echo $JAVA ${JAVA_OPTS} nsk.jvmti.Allocate.alloc001
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/RetransformClasses/retransform003/TestDriver.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/RetransformClasses/retransform003/TestDriver.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2018, 2019, 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
@@ -76,8 +76,18 @@
                 "-agentlib:retransform003-03=id=3 can_retransform_classes=1",
                 nsk.jvmti.RetransformClasses.retransform003.class.getName()
         );
-        String envName = Platform.isWindows() ? "PATH" :
-                (Platform.isOSX() ? "DYLD_LIBRARY_PATH" : "LD_LIBRARY_PATH");
+
+        String envName;
+        if (Platform.isWindows()) {
+            envName = "PATH";
+        } else if (Platform.isOSX()) {
+            envName = "DYLD_LIBRARY_PATH";
+        } else if (Platform.isAix()) {
+            envName = "LIBPATH";
+        } else {
+            envName = "LD_LIBRARY_PATH";
+        }
+
         pb.environment()
           .merge(envName, ".", (x, y) -> y + File.pathSeparator + x);
 
--- a/test/hotspot/jtreg/vmTestbase/nsk/jvmti/SetNativeMethodPrefix/SetNativeMethodPrefix002/TestDriver.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/vmTestbase/nsk/jvmti/SetNativeMethodPrefix/SetNativeMethodPrefix002/TestDriver.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2018, 2019, 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
@@ -66,8 +66,18 @@
                 "-agentlib:SetNativeMethodPrefix002-03=trace=all prefix=wc_",
                 nsk.jvmti.SetNativeMethodPrefix.SetNativeMethodPrefix002.class.getName()
         );
-        String envName = Platform.isWindows() ? "PATH" :
-                (Platform.isOSX() ? "DYLD_LIBRARY_PATH" : "LD_LIBRARY_PATH");
+
+        String envName;
+        if (Platform.isWindows()) {
+            envName = "PATH";
+        } else if (Platform.isOSX()) {
+            envName = "DYLD_LIBRARY_PATH";
+        } else if (Platform.isAix()) {
+            envName = "LIBPATH";
+        } else {
+            envName = "LD_LIBRARY_PATH";
+        }
+
         pb.environment()
           .merge(envName, ".", (x, y) -> y + File.pathSeparator + x);
 
--- a/test/hotspot/jtreg/vmTestbase/nsk/share/jdi/ArgumentHandler.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/hotspot/jtreg/vmTestbase/nsk/share/jdi/ArgumentHandler.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2001, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2019, 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
@@ -533,8 +533,12 @@
         {"linux-sparcv9",   "com.sun.jdi.SharedMemoryAttach"},
         {"linux-aarch64",   "com.sun.jdi.SharedMemoryAttach"},
         {"linux-arm",       "com.sun.jdi.SharedMemoryAttach"},
+        {"linux-ppc64",     "com.sun.jdi.SharedMemoryAttach"},
+        {"linux-ppc64le",   "com.sun.jdi.SharedMemoryAttach"},
+        {"linux-s390x",     "com.sun.jdi.SharedMemoryAttach"},
         {"macosx-amd64",    "com.sun.jdi.SharedMemoryAttach"},
         {"mac-x64",         "com.sun.jdi.SharedMemoryAttach"},
+        {"aix-ppc64",       "com.sun.jdi.SharedMemoryAttach"},
 
             // listening connectors
         /*
@@ -559,8 +563,12 @@
         {"linux-sparcv9",   "com.sun.jdi.SharedMemoryListen"},
         {"linux-aarch64",   "com.sun.jdi.SharedMemoryListen"},
         {"linux-arm",       "com.sun.jdi.SharedMemoryListen"},
+        {"linux-ppc64",     "com.sun.jdi.SharedMemoryListen"},
+        {"linux-ppc64le",   "com.sun.jdi.SharedMemoryListen"},
+        {"linux-s390x",     "com.sun.jdi.SharedMemoryListen"},
         {"macosx-amd64",    "com.sun.jdi.SharedMemoryListen"},
         {"mac-x64",         "com.sun.jdi.SharedMemoryListen"},
+        {"aix-ppc64",       "com.sun.jdi.SharedMemoryListen"},
 
             // launching connectors
         /*
@@ -615,6 +623,15 @@
         {"linux-arm",       "com.sun.jdi.CommandLineLaunch", "dt_shmem"},
         {"linux-arm",       "com.sun.jdi.RawCommandLineLaunch", "dt_shmem"},
 
+        {"linux-ppc64",     "com.sun.jdi.CommandLineLaunch", "dt_shmem"},
+        {"linux-ppc64",     "com.sun.jdi.RawCommandLineLaunch", "dt_shmem"},
+
+        {"linux-ppc64le",   "com.sun.jdi.CommandLineLaunch", "dt_shmem"},
+        {"linux-ppc64le",   "com.sun.jdi.RawCommandLineLaunch", "dt_shmem"},
+
+        {"linux-s390x",     "com.sun.jdi.CommandLineLaunch", "dt_shmem"},
+        {"linux-s390x",     "com.sun.jdi.RawCommandLineLaunch", "dt_shmem"},
+
         {"windows-i586",    "com.sun.jdi.CommandLineLaunch", "dt_socket"},
         {"windows-i586",    "com.sun.jdi.RawCommandLineLaunch", "dt_socket"},
 
@@ -633,6 +650,9 @@
         {"mac-x64",         "com.sun.jdi.CommandLineLaunch", "dt_shmem"},
         {"mac-x64",         "com.sun.jdi.RawCommandLineLaunch", "dt_shmem"},
 
+        {"aix-ppc64",       "com.sun.jdi.CommandLineLaunch", "dt_shmem"},
+        {"aix-ppc64",       "com.sun.jdi.RawCommandLineLaunch", "dt_shmem"},
+
         // shared memory transport is implemented only on windows platform
         {"solaris-sparc",   "dt_shmem"},
         {"solaris-sparcv9", "dt_shmem"},
@@ -647,7 +667,11 @@
         {"linux-sparcv9",   "dt_shmem"},
         {"linux-aarch64",   "dt_shmem"},
         {"linux-arm",       "dt_shmem"},
+        {"linux-ppc64",     "dt_shmem"},
+        {"linux-ppc64le",   "dt_shmem"},
+        {"linux-s390x",     "dt_shmem"},
         {"macosx-amd64",    "dt_shmem"},
         {"mac-x64",         "dt_shmem"},
+        {"aix-ppc64",       "dt_shmem"},
     };
 }
--- a/test/jdk/java/lang/ProcessBuilder/PipelineTest.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/jdk/java/lang/ProcessBuilder/PipelineTest.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2015, 2017, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2019, 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
@@ -34,6 +34,8 @@
 
 /*
  * @test PipelineTest
+ * @bug 8211844
+ * @summary Tests for ProcessBuilder.startPipeline
  */
 
 public class PipelineTest {
@@ -170,7 +172,7 @@
     static void verify(String input, String expected, List<ProcessBuilder> builders) throws IOException {
         File infile = new File("test.in");
         File outfile = new File("test.out");
-        setFileContents(infile, expected);
+        setFileContents(infile, input);
         for (int i = 0; i < builders.size(); i++) {
             ProcessBuilder b = builders.get(i);
             if (i == 0) {
@@ -184,8 +186,8 @@
         verifyProcesses(processes);
         waitForAll(processes);
         String result = fileContents(outfile);
-        System.out.printf(" in: %s%nout: %s%n", input, expected);
-        check(result.equals(expected), "result not as expected");
+        check(result.equals(expected),
+                "result not as expected: " + result + ", expected: " + expected);
     }
 
     /**
@@ -219,11 +221,14 @@
     static void verifyProcesses(List<Process> processes) {
         for (int i = 0; i < processes.size(); i++) {
             Process p = processes.get(i);
+
             if (i != 0) {
                 verifyNullStream(p.getOutputStream(), "getOutputStream");
             }
+            if (i <= processes.size() - 1) {
+                verifyNullStream(p.getInputStream(), "getInputStream");
+            }
             if (i == processes.size() - 1) {
-                verifyNullStream(p.getInputStream(), "getInputStream");
                 verifyNullStream(p.getErrorStream(), "getErrorStream");
             }
         }
@@ -232,7 +237,7 @@
     static void verifyNullStream(OutputStream s, String msg) {
         try {
             s.write(0xff);
-            fail("Stream should have been a NullStream" + msg);
+            fail("Stream should have been a NullStream: " + msg);
         } catch (IOException ie) {
             // expected
         }
@@ -241,7 +246,7 @@
     static void verifyNullStream(InputStream s, String msg) {
         try {
             int len = s.read();
-            check(len == -1, "Stream should have been a NullStream" + msg);
+            check(len == -1, "Stream should have been a NullStream: " + msg);
         } catch (IOException ie) {
             // expected
         }
@@ -271,9 +276,12 @@
     //--------------------- Infrastructure ---------------------------
     static volatile int passed = 0, failed = 0;
     static void pass() {passed++;}
-    static void fail() {failed++; Thread.dumpStack();}
-    static void fail(String msg) {System.err.println(msg); fail();}
-    static void unexpected(Throwable t) {failed++; t.printStackTrace();}
+    static void fail() {failed++; new Exception("Stack trace").printStackTrace(System.out);}
+    static void fail(String msg) {
+        System.out.println(msg); failed++;
+        new Exception("Stack trace: " + msg).printStackTrace(System.out);
+    }
+    static void unexpected(Throwable t) {failed++; t.printStackTrace(System.out);}
     static void check(boolean cond) {if (cond) pass(); else fail();}
     static void check(boolean cond, String m) {if (cond) pass(); else fail(m);}
     static void equal(Object x, Object y) {
--- a/test/jdk/java/util/Locale/LocaleProviders.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/jdk/java/util/Locale/LocaleProviders.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2019, 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
@@ -237,12 +237,16 @@
     }
 
     static void bug8027289Test(String expectedCodePoint) {
-        char[] expectedSymbol = Character.toChars(Integer.valueOf(expectedCodePoint, 16));
-        NumberFormat nf = NumberFormat.getCurrencyInstance(Locale.CHINA);
-        char formatted = nf.format(7000).charAt(0);
-        System.out.println("returned: " + formatted + ", expected: " + expectedSymbol[0]);
-        if (formatted != expectedSymbol[0]) {
-            throw new RuntimeException("Unexpected Chinese currency symbol. returned: " + formatted + ", expected: " + expectedSymbol[0]);
+        if (System.getProperty("os.name").startsWith("Windows")) {
+            char[] expectedSymbol = Character.toChars(Integer.valueOf(expectedCodePoint, 16));
+            NumberFormat nf = NumberFormat.getCurrencyInstance(Locale.CHINA);
+            char formatted = nf.format(7000).charAt(0);
+            System.out.println("returned: " + formatted + ", expected: " + expectedSymbol[0]);
+            if (formatted != expectedSymbol[0]) {
+                throw new RuntimeException(
+                        "Unexpected Chinese currency symbol. returned: "
+                                + formatted + ", expected: " + expectedSymbol[0]);
+            }
         }
     }
 }
--- a/test/jdk/java/util/Locale/LocaleProvidersRun.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/jdk/java/util/Locale/LocaleProvidersRun.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2012, 2019, 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
@@ -25,7 +25,7 @@
  * @test
  * @bug 6336885 7196799 7197573 7198834 8000245 8000615 8001440 8008577
  *      8010666 8013086 8013233 8013903 8015960 8028771 8054482 8062006
- *      8150432
+ *      8150432 8215913
  * @summary tests for "java.locale.providers" system property
  * @library /test/lib
  * @build LocaleProviders
@@ -143,7 +143,7 @@
         //testing 8027289 fix, if the platform format default is zh_CN
         // this assumes Windows' currency symbol for zh_CN is \u00A5, the yen
         // (yuan) sign.
-        if (!defLang.equals("en") && !defCtry.equals("CN")){
+        if (defFmtLang.equals("zh") && defFmtCtry.equals("CN")) {
             testRun("JRE,HOST", "bug8027289Test", "FFE5", "", "");
             testRun("COMPAT,HOST", "bug8027289Test", "FFE5", "", "");
             testRun("HOST", "bug8027289Test", "00A5", "", "");
--- a/test/langtools/jdk/javadoc/doclet/testCopyFiles/TestCopyFiles.java	Mon Jan 07 11:02:11 2019 +0530
+++ b/test/langtools/jdk/javadoc/doclet/testCopyFiles/TestCopyFiles.java	Tue Jan 08 13:40:57 2019 +0530
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2019, 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
@@ -23,7 +23,7 @@
 
 /*
  * @test
- * @bug  8157349 8185985 8194953
+ * @bug  8157349 8185985 8194953 8214738
  * @summary  test copy of doc-files, and its contents for HTML meta content.
  * @library  ../../lib
  * @modules jdk.javadoc/jdk.javadoc.internal.tool
@@ -268,9 +268,22 @@
                 "-sourcepath", testSrc("packages"),
                 "p2");
         checkExit(Exit.OK);
-        checkOutput("p2/doc-files/case1.html", true, "<!-- Generated by javadoc");
-        checkOutput("p2/doc-files/case2.html", false, "<!-- Generated by javadoc");
-        checkOutput("p2/doc-files/case3.html", false, "<!-- Generated by javadoc");
-        checkOutput("p2/doc-files/case4.html", false, "<!-- Generated by javadoc");
+        checkOutput("p2/doc-files/case2.html", true,
+                "<!-- Generated by javadoc",
+                "<style type=\"text/css\">\n"
+                + "body {\n"
+                + "        font-family: Helvetica, Arial, sans-serif;\n"
+                + "        font-size: 14px;\n"
+                + "      }\n"
+                + "    </style>");
+        checkOutput("p2/doc-files/case3.html", true,
+                "<!-- Generated by javadoc",
+                "<style>\n"
+                + "h1 {color:red;}\n"
+                + "        p {color:blue;}\n"
+                + "      </style>");
+        checkOutput("p2/doc-files/case4.html", true,
+                "<!-- Generated by javadoc",
+                "<link rel=\"stylesheet\" type=\"text/css\" href=\"theme.css\">");
     }
 }