/hg/release/icedtea6-1.12: 4 new changesets
andrew at icedtea.classpath.org
andrew at icedtea.classpath.org
Thu Aug 29 09:42:22 PDT 2013
changeset fd43ce34de24 in /hg/release/icedtea6-1.12
details: http://icedtea.classpath.org/hg/release/icedtea6-1.12?cmd=changeset;node=fd43ce34de24
author: Andrew John Hughes <gnu.andrew at redhat.com>
date: Thu Aug 29 16:11:28 2013 +0100
Fix TCK regression caused by backport of 7162902.
2013-08-28 Andrew John Hughes <gnu.andrew at redhat.com>
* Makefile.am:
(ICEDTEA_PATCHES): Add new backport.
* patches/openjdk/6893617-cnctx_always_uses_default_orb.patch:
Fixes TCK regression caused by 7162902.
changeset 7d370df4beac in /hg/release/icedtea6-1.12
details: http://icedtea.classpath.org/hg/release/icedtea6-1.12?cmd=changeset;node=7d370df4beac
author: Andrew John Hughes <gnu.andrew at redhat.com>
date: Thu Aug 29 16:14:55 2013 +0100
Add dependencies of 8013196 and remove SharedSecrets fragment of 8013196 which causes a TCK regression.
2013-08-05 Andrew John Hughes <gnu.andrew at redhat.com>
* Makefile.am:
(ICEDTEA_PATCHES): Add new patches.
* patches/openjdk/6636331-appcontext_concurrentmodificationexception.patch,
* patches/openjdk/6636370-appcontext_simplification.patch,
* patches/openjdk/7196533-timezone_bottleneck.patch:
Backport additional patches which relate to changes in 8013196.
* patches/openjdk/8013196-TimeZone_getDefault_throws_exception.patch:
Drop SharedSecrets changes which cause a TCK regression.
changeset f47f5152f6ac in /hg/release/icedtea6-1.12
details: http://icedtea.classpath.org/hg/release/icedtea6-1.12?cmd=changeset;node=f47f5152f6ac
author: Andrew John Hughes <gnu.andrew at redhat.com>
date: Thu Aug 29 16:16:25 2013 +0100
Fix naming of patch.
2013-08-06 Andrew John Hughes <gnu.andrew at redhat.com>
* 8013196-TimeZone_getDefault_throws_exception.patch:
Renamed to...
* 8013196-timezone_getdefault_throws_exception.patch:
...this.
* Makefile.am:
(ICEDTEA_PATCHES): Fix name of patch.
changeset e319de2968f3 in /hg/release/icedtea6-1.12
details: http://icedtea.classpath.org/hg/release/icedtea6-1.12?cmd=changeset;node=e319de2968f3
author: Andrew John Hughes <gnu.andrew at redhat.com>
date: Thu Aug 29 17:42:01 2013 +0100
Add latest tzdata updates.
2013-08-29 Andrew John Hughes <gnu.andrew at redhat.com>
* Makefile.am:
(ICEDTEA_PATCHES): Add new timezone data patches.
* patches/openjdk/8014469-tzdata2013c.patch,
* patches/openjdk/8020054-tzdata2013d.patch:
Latest tzdata updates.
diffstat:
ChangeLog | 35 +
Makefile.am | 11 +-
patches/openjdk/6636331-appcontext_concurrentmodificationexception.patch | 24 +
patches/openjdk/6636370-appcontext_simplification.patch | 178 +++++
patches/openjdk/6893617-cnctx_always_uses_default_orb.patch | 234 +++++++
patches/openjdk/7196533-timezone_bottleneck.patch | 66 ++
patches/openjdk/8013196-TimeZone_getDefault_throws_exception.patch | 58 -
patches/openjdk/8013196-timezone_getdefault_throws_exception.patch | 39 +
patches/openjdk/8014469-tzdata2013c.patch | 276 ++++++++
patches/openjdk/8020054-tzdata2013d.patch | 314 ++++++++++
10 files changed, 1174 insertions(+), 61 deletions(-)
diffs (truncated from 1291 to 500 lines):
diff -r a8496c2dd880 -r e319de2968f3 ChangeLog
--- a/ChangeLog Wed Jul 10 21:26:41 2013 +0100
+++ b/ChangeLog Thu Aug 29 17:42:01 2013 +0100
@@ -1,3 +1,38 @@
+2013-08-29 Andrew John Hughes <gnu.andrew at redhat.com>
+
+ * Makefile.am:
+ (ICEDTEA_PATCHES): Add new timezone data patches.
+ * patches/openjdk/8014469-tzdata2013c.patch,
+ * patches/openjdk/8020054-tzdata2013d.patch:
+ Latest tzdata updates.
+
+2013-08-06 Andrew John Hughes <gnu.andrew at redhat.com>
+
+ * 8013196-TimeZone_getDefault_throws_exception.patch:
+ Renamed to...
+ * 8013196-timezone_getdefault_throws_exception.patch:
+ ...this.
+ * Makefile.am:
+ (ICEDTEA_PATCHES): Fix name of patch.
+
+2013-08-05 Andrew John Hughes <gnu.andrew at redhat.com>
+
+ * Makefile.am:
+ (ICEDTEA_PATCHES): Add new patches.
+ * patches/openjdk/6636331-appcontext_concurrentmodificationexception.patch,
+ * patches/openjdk/6636370-appcontext_simplification.patch,
+ * patches/openjdk/7196533-timezone_bottleneck.patch:
+ Backport additional patches which relate to changes in 8013196.
+ * patches/openjdk/8013196-TimeZone_getDefault_throws_exception.patch:
+ Drop SharedSecrets changes which cause a TCK regression.
+
+2013-08-28 Andrew John Hughes <gnu.andrew at redhat.com>
+
+ * Makefile.am:
+ (ICEDTEA_PATCHES): Add new backport.
+ * patches/openjdk/6893617-cnctx_always_uses_default_orb.patch:
+ Fixes TCK regression caused by 7162902.
+
2013-07-10 Andrew John Hughes <gnu.andrew at redhat.com>
* configure.ac: Set to 1.12.7pre.
diff -r a8496c2dd880 -r e319de2968f3 Makefile.am
--- a/Makefile.am Wed Jul 10 21:26:41 2013 +0100
+++ b/Makefile.am Thu Aug 29 17:42:01 2013 +0100
@@ -683,7 +683,7 @@
patches/openjdk/8012112-MlibOpsTest_fails.patch \
patches/openjdk/8012617-arrayindexoutofbounds_linebreakmeasurer.patch \
patches/openjdk/8012933-appcontext_disposed_too_early.patch \
- patches/openjdk/8013196-TimeZone_getDefault_throws_exception.patch \
+ patches/openjdk/8013196-timezone_getdefault_throws_exception.patch \
patches/openjdk/8014427-raster_regression.patch \
patches/openjdk/8010727-empty_logger_name.patch \
patches/openjdk/8010939-logmanager_deadlock.patch \
@@ -704,8 +704,13 @@
patches/openjdk/7158483-tzdata2012c.patch \
patches/openjdk/7198570-tzdata2012f.patch \
patches/openjdk/8002225-tzdata2012i.patch \
- patches/openjdk/8009987-tzdata2013b.patch
-
+ patches/openjdk/8009987-tzdata2013b.patch \
+ patches/openjdk/6893617-cnctx_always_uses_default_orb.patch \
+ patches/openjdk/7196533-timezone_bottleneck.patch \
+ patches/openjdk/6636370-appcontext_simplification.patch \
+ patches/openjdk/6636331-appcontext_concurrentmodificationexception.patch \
+ patches/openjdk/8014469-tzdata2013c.patch \
+ patches/openjdk/8020054-tzdata2013d.patch
if WITH_RHINO
ICEDTEA_PATCHES += \
diff -r a8496c2dd880 -r e319de2968f3 patches/openjdk/6636331-appcontext_concurrentmodificationexception.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/openjdk/6636331-appcontext_concurrentmodificationexception.patch Thu Aug 29 17:42:01 2013 +0100
@@ -0,0 +1,24 @@
+# HG changeset patch
+# User son
+# Date 1205416264 -10800
+# Thu Mar 13 16:51:04 2008 +0300
+# Node ID c9ee9428aea9baa8e32691db1e14744002c70def
+# Parent bbd8e20d50523bbd89d10204e4f337a844f3cef1
+6636331: ConcurrentModificationException in AppContext code
+Summary: Added synchronization to AppContext.getAppContexts()
+Reviewed-by: art
+
+diff --git a/src/share/classes/sun/awt/AppContext.java b/src/share/classes/sun/awt/AppContext.java
+--- openjdk/jdk/src/share/classes/sun/awt/AppContext.java
++++ openjdk/jdk/src/share/classes/sun/awt/AppContext.java
+@@ -146,7 +146,9 @@
+ * Returns a set containing all <code>AppContext</code>s.
+ */
+ public static Set<AppContext> getAppContexts() {
+- return new HashSet<AppContext>(threadGroup2appContext.values());
++ synchronized (threadGroup2appContext) {
++ return new HashSet<AppContext>(threadGroup2appContext.values());
++ }
+ }
+
+ /* The main "system" AppContext, used by everything not otherwise
diff -r a8496c2dd880 -r e319de2968f3 patches/openjdk/6636370-appcontext_simplification.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/openjdk/6636370-appcontext_simplification.patch Thu Aug 29 17:42:01 2013 +0100
@@ -0,0 +1,178 @@
+diff -Nru openjdk.orig/jdk/src/share/classes/sun/awt/AppContext.java openjdk/jdk/src/share/classes/sun/awt/AppContext.java
+--- openjdk.orig/jdk/src/share/classes/sun/awt/AppContext.java 2013-08-05 16:49:37.120128300 +0100
++++ openjdk/jdk/src/share/classes/sun/awt/AppContext.java 2013-08-05 17:02:51.304664462 +0100
+@@ -151,7 +151,7 @@
+ contained in another AppContext. It is implicitly created for
+ standalone apps only (i.e. not applets)
+ */
+- private static AppContext mainAppContext = null;
++ private static volatile AppContext mainAppContext = null;
+
+ /*
+ * The hash map associated with this AppContext. A private delegate
+@@ -223,14 +223,15 @@
+ threadGroup2appContext.put(threadGroup, this);
+
+ this.contextClassLoader =
+- (ClassLoader) AccessController.doPrivileged(new PrivilegedAction() {
+- public Object run() {
++ AccessController.doPrivileged(new PrivilegedAction<ClassLoader>() {
++ public ClassLoader run() {
+ return Thread.currentThread().getContextClassLoader();
+ }
+ });
+ }
+
+- private static MostRecentThreadAppContext mostRecentThreadAppContext = null;
++ private static final ThreadLocal<AppContext> threadAppContext =
++ new ThreadLocal<AppContext>();
+
+ private final static void initMainAppContext() {
+ // On the main Thread, we get the ThreadGroup, make a corresponding
+@@ -270,30 +271,18 @@
+ return mainAppContext;
+ }
+
+- final Thread currentThread = Thread.currentThread();
++ AppContext appContext = threadAppContext.get();
+
+- AppContext appContext = null;
+-
+- // Note: this most recent Thread/AppContext caching is thread-hot.
+- // A simple test using SwingSet found that 96.8% of lookups
+- // were matched using the most recent Thread/AppContext. By
+- // instantiating a simple MostRecentThreadAppContext object on
+- // cache misses, the cache hits can be processed without
+- // synchronization.
+-
+- MostRecentThreadAppContext recent = mostRecentThreadAppContext;
+- if ((recent != null) && (recent.thread == currentThread)) {
+- appContext = recent.appContext; // Cache hit
+- } else {
+- appContext = (AppContext)AccessController.doPrivileged(
+- new PrivilegedAction() {
+- public Object run() {
+- // Get the current ThreadGroup, and look for it and its
+- // parents in the hash from ThreadGroup to AppContext --
+- // it should be found, because we use createNewContext()
+- // when new AppContext objects are created.
+- ThreadGroup currentThreadGroup = currentThread.getThreadGroup();
+- ThreadGroup threadGroup = currentThreadGroup;
++ if (null == appContext) {
++ appContext = AccessController.doPrivileged(new PrivilegedAction<AppContext>()
++ {
++ public AppContext run() {
++ // Get the current ThreadGroup, and look for it and its
++ // parents in the hash from ThreadGroup to AppContext --
++ // it should be found, because we use createNewContext()
++ // when new AppContext objects are created.
++ ThreadGroup currentThreadGroup = Thread.currentThread().getThreadGroup();
++ ThreadGroup threadGroup = currentThreadGroup;
+
+ // Special case: we implicitly create the main app context
+ // if no contexts have been created yet. This covers standalone apps
+@@ -308,28 +297,29 @@
+ }
+ }
+
+- AppContext context = threadGroup2appContext.get(threadGroup);
+- while (context == null) {
+- threadGroup = threadGroup.getParent();
+- if (threadGroup == null) {
+- return null;
++ AppContext context = threadGroup2appContext.get(threadGroup);
++ while (context == null) {
++ threadGroup = threadGroup.getParent();
++ if (threadGroup == null) {
++ return null;
++ }
++ context = threadGroup2appContext.get(threadGroup);
++ }
++
++ // In case we did anything in the above while loop, we add
++ // all the intermediate ThreadGroups to threadGroup2appContext
++ // so we won't spin again.
++ for (ThreadGroup tg = currentThreadGroup; tg != threadGroup; tg = tg.getParent()) {
++ threadGroup2appContext.put(tg, context);
++ }
++
++ // Now we're done, so we cache the latest key/value pair.
++ threadAppContext.set(context);
++
++
++ return context;
+ }
+- context = threadGroup2appContext.get(threadGroup);
+- }
+- // In case we did anything in the above while loop, we add
+- // all the intermediate ThreadGroups to threadGroup2appContext
+- // so we won't spin again.
+- for (ThreadGroup tg = currentThreadGroup; tg != threadGroup; tg = tg.getParent()) {
+- threadGroup2appContext.put(tg, context);
+- }
+-
+- // Now we're done, so we cache the latest key/value pair.
+- mostRecentThreadAppContext =
+- new MostRecentThreadAppContext(currentThread, context);
+-
+- return context;
+- }
+- });
++ });
+ }
+
+ return appContext;
+@@ -473,7 +463,7 @@
+ // Threads in the ThreadGroup to exit.
+
+ long startTime = System.currentTimeMillis();
+- long endTime = startTime + (long)THREAD_INTERRUPT_TIMEOUT;
++ long endTime = startTime + THREAD_INTERRUPT_TIMEOUT;
+ while ((this.threadGroup.activeCount() > 0) &&
+ (System.currentTimeMillis() < endTime)) {
+ try {
+@@ -488,7 +478,7 @@
+ // Threads in the ThreadGroup to die.
+
+ startTime = System.currentTimeMillis();
+- endTime = startTime + (long)THREAD_INTERRUPT_TIMEOUT;
++ endTime = startTime + THREAD_INTERRUPT_TIMEOUT;
+ while ((this.threadGroup.activeCount() > 0) &&
+ (System.currentTimeMillis() < endTime)) {
+ try {
+@@ -507,10 +497,7 @@
+ }
+ threadGroup2appContext.remove(this.threadGroup);
+
+- MostRecentThreadAppContext recent = mostRecentThreadAppContext;
+- if ((recent != null) && (recent.appContext == this))
+- mostRecentThreadAppContext = null;
+- // If the "most recent" points to this, clear it for GC
++ threadAppContext.set(null);
+
+ // Finally, we destroy the ThreadGroup entirely.
+ try {
+@@ -693,6 +680,7 @@
+ * Returns a string representation of this AppContext.
+ * @since 1.2
+ */
++ @Override
+ public String toString() {
+ return getClass().getName() + "[threadGroup=" + threadGroup.getName() + "]";
+ }
+@@ -842,15 +830,6 @@
+ }
+ }
+
+-final class MostRecentThreadAppContext {
+- final Thread thread;
+- final AppContext appContext;
+- MostRecentThreadAppContext(Thread key, AppContext value) {
+- thread = key;
+- appContext = value;
+- }
+-}
+-
+ final class MostRecentKeyValue {
+ Object key;
+ Object value;
diff -r a8496c2dd880 -r e319de2968f3 patches/openjdk/6893617-cnctx_always_uses_default_orb.patch
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/patches/openjdk/6893617-cnctx_always_uses_default_orb.patch Thu Aug 29 17:42:01 2013 +0100
@@ -0,0 +1,234 @@
+# HG changeset patch
+# User coffeys
+# Date 1340827826 -3600
+# Wed Jun 27 21:10:26 2012 +0100
+# Node ID 83f8283e47917f97b838257db5711e37be9b715e
+# Parent 352fad83e8447dec768064f60dc85934db32ef27
+6893617: JDK 6 CNCtx always uses the default ORB
+Reviewed-by: lancea
+
+diff --git a/src/share/classes/com/sun/jndi/cosnaming/CNCtx.java b/src/share/classes/com/sun/jndi/cosnaming/CNCtx.java
+--- openjdk/jdk/src/share/classes/com/sun/jndi/cosnaming/CNCtx.java
++++ openjdk/jdk/src/share/classes/com/sun/jndi/cosnaming/CNCtx.java
+@@ -1,5 +1,5 @@
+ /*
+- * Copyright (c) 1999, 2005, Oracle and/or its affiliates. All rights reserved.
++ * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+ *
+ * This code is free software; you can redistribute it and/or modify it
+@@ -59,8 +59,22 @@
+
+ private final static boolean debug = false;
+
++ /*
++ * Implement one shared ORB among all CNCtx. However, there is a public constructor
++ * accepting an ORB, so we need the option of using a given ORB.
++ */
++ private static ORB _defaultOrb;
+ ORB _orb; // used by ExceptionMapper and RMI/IIOP factory
+ public NamingContext _nc; // public for accessing underlying NamingContext
++
++ private synchronized static ORB getDefaultOrb() {
++ if (_defaultOrb == null) {
++ _defaultOrb = CorbaUtils.getOrb(null, -1,
++ new Hashtable<String, java.lang.Object>());
++ }
++ return _defaultOrb;
++ }
++
+ private NameComponent[] _name = null;
+
+ Hashtable _env; // used by ExceptionMapper
+@@ -113,8 +127,9 @@
+ // rest is the INS name
+ // Return the parsed form to prevent subsequent lookup
+ // from parsing the string as a composite name
+- // The caller should be aware that a toString() of the name
+- // will yield its INS syntax, rather than a composite syntax
++ // The caller should be aware that a toString() of the name,
++ // which came from the environment will yield its INS syntax,
++ // rather than a composite syntax
+ return new ResolveResult(ctx, parser.parse(rest));
+ }
+
+@@ -134,10 +149,10 @@
+ if (orb == null || nctx == null)
+ throw new ConfigurationException(
+ "Must supply ORB or NamingContext");
+- _orb = orb;
+- orbTracker = tracker;
+- if (orbTracker != null) {
+- orbTracker.incRefCount();
++ if (orb != null) {
++ _orb = orb;
++ } else {
++ _orb = getDefaultOrb();
+ }
+ _nc = nctx;
+ _env = env;
+@@ -211,10 +226,13 @@
+ org.omg.CORBA.ORB inOrb = null;
+ String ncIor = null;
+
+- if (env != null) {
++ if (inOrb == null && env != null) {
+ inOrb = (org.omg.CORBA.ORB) env.get("java.naming.corba.orb");
+ }
+
++ if (inOrb == null)
++ inOrb = getDefaultOrb(); // will create a default ORB if none exists
++
+ // Extract PROVIDER_URL from environment
+ String provUrl = null;
+ if (env != null) {
+@@ -225,13 +243,6 @@
+ // Initialize the root naming context by using the IOR supplied
+ // in the PROVIDER_URL
+ ncIor = getStringifiedIor(provUrl);
+-
+- if (inOrb == null) {
+-
+- // no ORB instance specified; create one using env and defaults
+- inOrb = CorbaUtils.getOrb(null, -1, env);
+- orbTracker = new OrbReuseTracker(inOrb);
+- }
+ setOrbAndRootContext(inOrb, ncIor);
+ } else if (provUrl != null) {
+ // Initialize the root naming context by using the URL supplied
+@@ -257,14 +268,8 @@
+ }
+ } else {
+ // No PROVIDER_URL supplied; initialize using defaults
+- if (inOrb == null) {
+-
+- // No ORB instance specified; create one using env and defaults
+- inOrb = CorbaUtils.getOrb(null, -1, env);
+- orbTracker = new OrbReuseTracker(inOrb);
+- if (debug) {
+- System.err.println("Getting default ORB: " + inOrb + env);
+- }
++ if (debug) {
++ System.err.println("Getting default ORB: " + inOrb + env);
+ }
+ setOrbAndRootContext(inOrb, (String)null);
+ }
+@@ -285,6 +290,10 @@
+ */
+ private String initUsingIiopUrl(ORB defOrb, String url, Hashtable env)
+ throws NamingException {
++
++ if (defOrb == null)
++ defOrb = getDefaultOrb();
++
+ try {
+ IiopUrl parsedUrl = new IiopUrl(url);
+
+@@ -296,19 +305,17 @@
+ addr = (IiopUrl.Address)addrs.elementAt(i);
+
+ try {
+- if (defOrb != null) {
+- try {
+- String tmpUrl = "corbaloc:iiop:" + addr.host
+- + ":" + addr.port + "/NameService";
+- if (debug) {
+- System.err.println("Using url: " + tmpUrl);
+- }
+- org.omg.CORBA.Object rootCtx =
+- defOrb.string_to_object(tmpUrl);
+- setOrbAndRootContext(defOrb, rootCtx);
+- return parsedUrl.getStringName();
+- } catch (Exception e) {} // keep going
+- }
++ try {
++ String tmpUrl = "corbaloc:iiop:" + addr.host
++ + ":" + addr.port + "/NameService";
++ if (debug) {
++ System.err.println("Using url: " + tmpUrl);
++ }
++ org.omg.CORBA.Object rootCtx =
++ defOrb.string_to_object(tmpUrl);
++ setOrbAndRootContext(defOrb, rootCtx);
++ return parsedUrl.getStringName();
++ } catch (Exception e) {} // keep going
+
+ // Get ORB
+ if (debug) {
+@@ -316,12 +323,8 @@
+ + " and port " + addr.port);
+ }
+
+- // Get ORB
+- ORB orb = CorbaUtils.getOrb(addr.host, addr.port, env);
+- orbTracker = new OrbReuseTracker(orb);
+-
+ // Assign to fields
+- setOrbAndRootContext(orb, (String)null);
++ setOrbAndRootContext(defOrb, (String)null);
+ return parsedUrl.getStringName();
+
+ } catch (NamingException ne) {
+@@ -343,18 +346,16 @@
+ */
+ private String initUsingCorbanameUrl(ORB orb, String url, Hashtable env)
+ throws NamingException {
++
++ if (orb == null)
++ orb = getDefaultOrb();
++
+ try {
+ CorbanameUrl parsedUrl = new CorbanameUrl(url);
+
+ String corbaloc = parsedUrl.getLocation();
+ String cosName = parsedUrl.getStringName();
+
+- if (orb == null) {
+-
+- // No ORB instance specified; create one using env and defaults
+- orb = CorbaUtils.getOrb(null, -1, env);
+- orbTracker = new OrbReuseTracker(orb);
+- }
+ setOrbAndRootContext(orb, corbaloc);
+
+ return parsedUrl.getStringName();
+@@ -1115,9 +1116,6 @@
+ }
+
+ synchronized public void incEnumCount() {
+- if (orbTracker == null) {
+- return;
+- }
+ enumCount++;
+ if (debug) {
+ System.out.println("incEnumCount, new count:" + enumCount);
+@@ -1126,9 +1124,6 @@
+
+ synchronized public void decEnumCount()
+ throws NamingException {
+- if (orbTracker == null) {
+- return;
+- }
+ enumCount--;
+ if (debug) {
+ System.out.println("decEnumCount, new count:" + enumCount +
+@@ -1140,14 +1135,15 @@
+ }
More information about the distro-pkg-dev
mailing list