/hg/icedtea7: Bring in new JDK build cleanups and HotSpot fixes ...

andrew at icedtea.classpath.org andrew at icedtea.classpath.org
Thu Jul 28 16:04:44 PDT 2011


changeset 05dda6fb5ced in /hg/icedtea7
details: http://icedtea.classpath.org/hg/icedtea7?cmd=changeset;node=05dda6fb5ced
author: Andrew John Hughes <ahughes at redhat.com>
date: Fri Jul 29 00:04:28 2011 +0100

	Bring in new JDK build cleanups and HotSpot fixes for Zero/Shark.

	2011-07-28 Andrew John Hughes <ahughes at redhat.com>

	 Bring in new JDK build cleanups and HotSpot fixes
	for Zero/Shark.
		* Makefile.am: (JDK_CHANGESET): Updated.
	(JDK_SHA256SUM): Likewise. (HOTSPOT_CHANGESET): Likewise.
	(HOTSPOT_SHA256SUM): Likewise. (ICEDTEA_BOOT_PATCHES): Add
	new patch.
		* patches/boot/ecj-diamond.patch,
		* patches/boot/ecj-stringswitch.patch: Updated with new cases.
		* patches/boot/use_target_6_for_bootstrap_classes.patch: New
	patch. Force source/target to 6 rather than 7 when building
	classes needed by the bootstrap tools.


diffstat:

 ChangeLog                                             |   18 +
 Makefile.am                                           |   11 +-
 patches/boot/ecj-diamond.patch                        |  399 +++++------------
 patches/boot/ecj-stringswitch.patch                   |  170 +++---
 patches/boot/use_target_6_for_bootstrap_classes.patch |   59 ++
 5 files changed, 289 insertions(+), 368 deletions(-)

diffs (truncated from 2577 to 500 lines):

diff -r 0eac7d4e7536 -r 05dda6fb5ced ChangeLog
--- a/ChangeLog	Wed Jul 20 12:12:22 2011 +0200
+++ b/ChangeLog	Fri Jul 29 00:04:28 2011 +0100
@@ -1,3 +1,21 @@
+2011-07-28  Andrew John Hughes  <ahughes at redhat.com>
+
+	Bring in new JDK build cleanups and
+	HotSpot fixes for Zero/Shark.
+	* Makefile.am:
+	(JDK_CHANGESET): Updated.
+	(JDK_SHA256SUM): Likewise.
+	(HOTSPOT_CHANGESET): Likewise.
+	(HOTSPOT_SHA256SUM): Likewise.
+	(ICEDTEA_BOOT_PATCHES): Add new patch.
+	* patches/boot/ecj-diamond.patch,
+	* patches/boot/ecj-stringswitch.patch:
+	Updated with new cases.
+	* patches/boot/use_target_6_for_bootstrap_classes.patch:
+	New patch.  Force source/target to 6
+	rather than 7 when building classes needed
+	by the bootstrap tools.
+
 2011-07-20  Marc Schoenefeld <mschoene at redhat.com>
 	    Pavel Tisnovsky  <ptisnovs at redhat.com>
 
diff -r 0eac7d4e7536 -r 05dda6fb5ced Makefile.am
--- a/Makefile.am	Wed Jul 20 12:12:22 2011 +0200
+++ b/Makefile.am	Fri Jul 29 00:04:28 2011 +0100
@@ -3,18 +3,18 @@
 OPENJDK_VERSION = b147
 
 CORBA_CHANGESET = 616c760dc288
-HOTSPOT_CHANGESET = 5d5c6ef3435d
+HOTSPOT_CHANGESET = d438a5890756
 JAXP_CHANGESET = c40983d6ae70
 JAXWS_CHANGESET = 83db5e316798
-JDK_CHANGESET = 483d8dacfbd8
+JDK_CHANGESET = 4783dfaed9f9
 LANGTOOLS_CHANGESET = 0df09c966a29
 OPENJDK_CHANGESET = 3defd24c2671
 
 CORBA_SHA256SUM = 7589c42e88b4342750bea5afa306cc662cc9c5f7607fad96f70083ce70f4526e
-HOTSPOT_SHA256SUM = e0114f1beb395065fbe1421a248f7169898bde47ac7b33a81f354de453e3b5b1
+HOTSPOT_SHA256SUM = efa3512d4c29306a4e16f854bd2416e6917cdb1741efe0826401c7e0ee13645a
 JAXP_SHA256SUM = 6ab0cab1965edb28e4093b55436abd04fbffe0b0251016043c75246c4ee9dc2d
 JAXWS_SHA256SUM = 5567c90ce2857016365b2e346783a3b16ec0e76b80586a0371f601b4fed01f21
-JDK_SHA256SUM = c698a60613673bfc2e25d7b4d163b192116d5ce7d1a1fb63a1c6349686ce30d7
+JDK_SHA256SUM = 8eaecc9db0a9a2266f67b661caaa35a8207263975dc0560a9e82ee83819a6d73
 LANGTOOLS_SHA256SUM = 0118daf4d280d0a56f657fac640ac191ec42a7f49cc12a0693bd0fdd04ec684a
 OPENJDK_SHA256SUM = 4043a75c2c4385dd735f8dbbf2369311ce1b951217c9dbe9bba9609e24eb291e
 
@@ -370,7 +370,8 @@
 	patches/boot/ecj-multicatch.patch \
 	patches/boot/ecj-trywithresources.patch \
 	patches/boot/ecj-autoboxing.patch \
-	patches/boot/xsltproc.patch
+	patches/boot/xsltproc.patch \
+	patches/boot/use_target_6_for_bootstrap_classes.patch
 
 if CP39408_JAVAH
 ICEDTEA_BOOT_PATCHES += patches/boot/pr39408.patch
diff -r 0eac7d4e7536 -r 05dda6fb5ced patches/boot/ecj-diamond.patch
--- a/patches/boot/ecj-diamond.patch	Wed Jul 20 12:12:22 2011 +0200
+++ b/patches/boot/ecj-diamond.patch	Fri Jul 29 00:04:28 2011 +0100
@@ -1,7 +1,7 @@
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java	2011-04-14 01:29:58.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java	2011-07-12 16:56:06.686259706 +0100
-@@ -104,9 +104,9 @@
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java	2011-07-27 14:31:14.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Attribute.java	2011-07-27 15:21:43.611371943 +0100
+@@ -103,9 +103,9 @@
          return this.def.compareTo(that.def);
      }
  
@@ -14,7 +14,7 @@
  
      // Canonicalized lists of trivial attrs (Deprecated, etc.)
      // are used by trimToSize, in order to reduce footprint
-@@ -116,7 +116,7 @@
+@@ -115,7 +115,7 @@
          synchronized (canonLists) {
              List<Attribute> cl = canonLists.get(al);
              if (cl == null) {
@@ -23,7 +23,7 @@
                  cl.addAll(al);
                  cl = Collections.unmodifiableList(cl);
                  canonLists.put(al, cl);
-@@ -337,9 +337,9 @@
+@@ -336,9 +336,9 @@
  
          public void addAttribute(Attribute a) {
              if (attributes == null)
@@ -35,7 +35,7 @@
              attributes.add(a);
          }
  
-@@ -347,7 +347,7 @@
+@@ -346,7 +346,7 @@
              if (attributes == null)       return null;
              if (!attributes.contains(a))  return null;
              if (!(attributes instanceof ArrayList))
@@ -72,8 +72,8 @@
          for (int i = 0; i < layout.length(); i++) {
              if (layout.charAt(i++) != '[')
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java	2011-07-12 15:23:26.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java	2011-07-12 16:56:06.702259970 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java	2011-07-27 15:09:07.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/BandStructure.java	2011-07-28 01:35:06.947366341 +0100
 @@ -257,7 +257,7 @@
          assert(basicCodings[_meta_default] == null);
          assert(basicCodings[_meta_canon_min] != null);
@@ -103,7 +103,7 @@
  
      // Well-known attributes:
      protected final Attribute.Layout attrCodeEmpty;
-@@ -1713,11 +1713,11 @@
+@@ -1713,16 +1713,16 @@
      protected final Attribute.Layout attrConstantValue;
  
      // Mapping from Attribute.Layout to Integer (inverse of attrDefs)
@@ -117,9 +117,15 @@
      {
          for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) {
              assert(attrIndexLimit[i] == 0);
+             attrIndexLimit[i] = 32;  // just for the sake of predefs.
+-            attrDefs.set(i, new ArrayList<>(Collections.nCopies(
++            attrDefs.set(i, new ArrayList<Attribute.Layout>(Collections.nCopies(
+                     attrIndexLimit[i], (Attribute.Layout)null)));
+ 
+         }
 @@ -1912,7 +1912,7 @@
  
-     protected List getPredefinedAttrs(int ctype) {
+     protected List<Attribute.Layout> getPredefinedAttrs(int ctype) {
          assert(attrIndexLimit[ctype] != 0);
 -        List<Attribute.Layout> res = new ArrayList<>(attrIndexLimit[ctype]);
 +        List<Attribute.Layout> res = new ArrayList<Attribute.Layout>(attrIndexLimit[ctype]);
@@ -136,8 +142,8 @@
          return true;
      }
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java	2011-07-12 15:23:26.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java	2011-07-12 16:56:06.702259970 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java	2011-07-27 15:09:06.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ClassReader.java	2011-07-27 15:21:43.619372073 +0100
 @@ -466,7 +466,7 @@
  
      void readInnerClasses(Class cls) throws IOException {
@@ -149,7 +155,7 @@
                  new InnerClass(readClassRef(),
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java
 --- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java	2011-04-14 01:29:58.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java	2011-07-12 16:56:06.702259970 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/CodingChooser.java	2011-07-27 15:21:43.663372790 +0100
 @@ -743,9 +743,9 @@
          // Steps 1/2/3 are interdependent, and may be iterated.
          // Steps 4 and 5 may be decided independently afterward.
@@ -186,8 +192,8 @@
                  if (popset.add(values[i]))  popvals.add(values[i]);
              }
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java	2011-04-14 01:29:58.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java	2011-07-12 16:56:06.702259970 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java	2011-07-27 14:31:14.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Coding.java	2011-07-27 15:21:43.663372790 +0100
 @@ -402,7 +402,7 @@
      private static Map<Coding, Coding> codeMap;
  
@@ -198,9 +204,9 @@
          Coding x1 = codeMap.get(x0);
          if (x1 == null)  codeMap.put(x0, x1 = x0);
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java	2011-04-14 01:29:58.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java	2011-07-12 16:56:06.702259970 +0100
-@@ -919,7 +919,7 @@
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java	2011-07-27 14:31:14.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/ConstantPool.java	2011-07-27 15:21:43.679373050 +0100
+@@ -915,7 +915,7 @@
      public static
      Index[] partition(Index ix, int[] keys) {
          // %%% Should move this into class Index.
@@ -209,7 +215,7 @@
          Entry[] cpMap = ix.cpMap;
          assert(keys.length == cpMap.length);
          for (int i = 0; i < keys.length; i++) {
-@@ -930,7 +930,7 @@
+@@ -926,7 +926,7 @@
              }
              List<Entry> part = parts.get(key);
              if (part == null) {
@@ -218,7 +224,7 @@
              }
              part.add(cpMap[i]);
          }
-@@ -1137,7 +1137,7 @@
+@@ -1133,7 +1133,7 @@
      void completeReferencesIn(Set<Entry> cpRefs, boolean flattenSigs) {
          cpRefs.remove(null);
          for (ListIterator<Entry> work =
@@ -228,8 +234,8 @@
              Entry e = work.previous();
              work.remove();          // pop stack
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java	2011-07-12 15:23:26.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java	2011-07-12 16:56:06.702259970 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java	2011-07-27 15:09:07.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Driver.java	2011-07-27 15:21:43.683373115 +0100
 @@ -59,7 +59,7 @@
                  ResourceBundle.getBundle("com.sun.java.util.jar.pack.DriverResource");
  
@@ -268,7 +274,7 @@
              String[] words = optline.split("\\p{Space}+");
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java
 --- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java	2011-04-14 01:29:58.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java	2011-07-12 16:56:06.702259970 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/FixedList.java	2011-07-27 15:21:43.683373115 +0100
 @@ -45,7 +45,7 @@
      private final ArrayList<E> flist;
  
@@ -279,8 +285,8 @@
          for (int i = 0 ; i < capacity ; i++) {
              flist.add(null);
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java	2011-07-12 15:23:26.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java	2011-07-12 16:56:06.702259970 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java	2011-07-27 15:09:06.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/Package.java	2011-07-27 15:23:52.897478020 +0100
 @@ -112,7 +112,7 @@
      public static final Attribute.Layout attrSourceFileSpecial;
      public static final Map<Attribute.Layout, Attribute> attrDefs;
@@ -299,7 +305,7 @@
  
      public List<Package.Class> getClasses() {
          return classes;
-@@ -264,7 +264,7 @@
+@@ -263,7 +263,7 @@
              if (olda == null)
                  return;  // no SourceFile attr.
              String obvious = getObviousSourceFile();
@@ -308,7 +314,7 @@
              olda.visitRefs(this, VRM_PACKAGE, ref);
              Utf8Entry sfName = (Utf8Entry) ref.get(0);
              Attribute a = olda;
-@@ -292,7 +292,7 @@
+@@ -291,7 +291,7 @@
              if (a != olda) {
                  if (verbose > 2)
                      Utils.log.fine("recoding obvious SourceFile="+obvious);
@@ -317,7 +323,7 @@
                  int where = newAttrs.indexOf(olda);
                  newAttrs.set(where, a);
                  setAttributes(newAttrs);
-@@ -322,7 +322,7 @@
+@@ -321,7 +321,7 @@
          }
  
          public void setInnerClasses(Collection<InnerClass> ics) {
@@ -326,7 +332,7 @@
              // Edit the attribute list, if necessary.
              Attribute a = getAttribute(attrInnerClassesEmpty);
              if (innerClasses != null && a == null)
-@@ -341,7 +341,7 @@
+@@ -340,7 +340,7 @@
           *  with that of Package.this.allInnerClasses.
           */
          public List<InnerClass> computeGloballyImpliedICs() {
@@ -335,7 +341,7 @@
              {   // This block temporarily displaces this.innerClasses.
                  ArrayList<InnerClass> innerClassesSaved = innerClasses;
                  innerClasses = null;  // ignore for the moment
-@@ -350,7 +350,7 @@
+@@ -349,7 +349,7 @@
              }
              ConstantPool.completeReferencesIn(cpRefs, true);
  
@@ -344,7 +350,7 @@
              for (Entry e : cpRefs) {
                  // Restrict cpRefs to InnerClasses entries only.
                  if (!(e instanceof ClassEntry))  continue;
-@@ -366,7 +366,7 @@
+@@ -365,7 +365,7 @@
              // This loop is structured this way so as to accumulate
              // entries into impliedICs in an order which reflects
              // the order of allInnerClasses.
@@ -353,7 +359,7 @@
              for (InnerClass ic : allInnerClasses) {
                  // This one is locally relevant if it describes
                  // a member of the current class, or if the current
-@@ -409,8 +409,8 @@
+@@ -408,8 +408,8 @@
                  // Diff is A since I is empty.
              }
              // (I*A) is non-trivial
@@ -364,7 +370,7 @@
              impliedICs.addAll(actualICs);
              impliedICs.removeAll(center);
              // Diff is now I^A = (I+A)-(I*A).
-@@ -539,7 +539,7 @@
+@@ -538,7 +538,7 @@
                  super(flags, descriptor);
                  assert(!descriptor.isMethod());
                  if (fields == null)
@@ -373,7 +379,7 @@
                  boolean added = fields.add(this);
                  assert(added);
                  order = fields.size();
-@@ -564,7 +564,7 @@
+@@ -563,7 +563,7 @@
                  super(flags, descriptor);
                  assert(descriptor.isMethod());
                  if (methods == null)
@@ -382,7 +388,7 @@
                  boolean added = methods.add(this);
                  assert(added);
              }
-@@ -732,14 +732,14 @@
+@@ -728,14 +728,14 @@
      }
  
      // What non-class files are in this unit?
@@ -399,16 +405,25 @@
          for (Class cls : classes) {
              assert(cls.file.isClassStub());
              classStubs.add(cls.file);
-@@ -859,7 +859,7 @@
+@@ -749,7 +749,7 @@
+         int modtime = NO_MODTIME;
+         int options = 0;  // random flag bits, such as deflate_hint
+         Class stubClass;  // if this is a stub, here's the class
+-        ArrayList<byte[]> prepend = new ArrayList<>();  // list of byte[]
++        ArrayList<byte[]> prepend = new ArrayList<byte[]>();  // list of byte[]
+         java.io.ByteArrayOutputStream append = new ByteArrayOutputStream();
+ 
+         File(Utf8Entry name) {
+@@ -852,7 +852,7 @@
          public InputStream getInputStream() {
              InputStream in = new ByteArrayInputStream(append.toByteArray());
              if (prepend.isEmpty())  return in;
 -            List<InputStream> isa = new ArrayList<>(prepend.size()+1);
 +            List<InputStream> isa = new ArrayList<InputStream>(prepend.size()+1);
-             for (Iterator i = prepend.iterator(); i.hasNext(); ) {
-                 byte[] bytes = (byte[]) i.next();
+             for (byte[] bytes : prepend) {
                  isa.add(new ByteArrayInputStream(bytes));
-@@ -896,7 +896,7 @@
+             }
+@@ -888,7 +888,7 @@
      }
  
      // Is there a globally declared table of inner classes?
@@ -417,7 +432,7 @@
      Map<ClassEntry, InnerClass>   allInnerClassesByThis;
  
      public
-@@ -911,7 +911,7 @@
+@@ -903,7 +903,7 @@
          allInnerClasses.addAll(ics);
  
          // Make an index:
@@ -426,7 +441,7 @@
          for (InnerClass ic : allInnerClasses) {
              Object pic = allInnerClassesByThis.put(ic.thisClass, ic);
              assert(pic == null);  // caller must ensure key uniqueness!
-@@ -1302,7 +1302,7 @@
+@@ -1290,7 +1290,7 @@
  
      // Use this before writing the class files.
      void ensureAllClassFiles() {
@@ -436,8 +451,8 @@
              // Add to the end of ths list:
              if (!fileSet.contains(cls.file))
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java	2011-07-12 15:23:26.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java	2011-07-12 16:56:06.702259970 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java	2011-07-27 15:09:07.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageReader.java	2011-07-27 15:21:43.739374028 +0100
 @@ -686,7 +686,7 @@
          cp_Signature_classes.expectLength(getIntTotal(numSigClasses));
          cp_Signature_classes.readFrom(in);
@@ -524,15 +539,15 @@
              bits = attrBits;  // iterate again
              for (int ai = 0; bits != 0; ai++) {
 @@ -1596,7 +1596,7 @@
-     @SuppressWarnings("unchecked")
-     void readAttrs(int ctype, Collection holders) throws IOException {
+     void readAttrs(int ctype, Collection<? extends Attribute.Holder> holders)
+             throws IOException {
          // Decode band values into attributes.
 -        Set<Attribute.Layout> sawDefs = new HashSet<>();
 +        Set<Attribute.Layout> sawDefs = new HashSet<Attribute.Layout>();
          ByteArrayOutputStream buf = new ByteArrayOutputStream();
-         for (Iterator i = holders.iterator(); i.hasNext(); ) {
-             final Attribute.Holder h = (Attribute.Holder) i.next();
-@@ -1800,7 +1800,7 @@
+         for (final Attribute.Holder h : holders) {
+             if (h.attributes == null)  continue;
+@@ -1799,7 +1799,7 @@
          // scratch buffer for collecting code::
          byte[] buf = new byte[1<<12];
          // record of all switch opcodes (these are variable-length)
@@ -541,7 +556,7 @@
          for (int k = 0; k < allCodes.length; k++) {
              Code c = allCodes[k];
          scanOneMethod:
-@@ -1916,7 +1916,7 @@
+@@ -1915,7 +1915,7 @@
  
              Set<Entry> ldcRefSet = ldcRefMap.get(curClass);
              if (ldcRefSet == null)
@@ -551,8 +566,8 @@
              ClassEntry thisClass  = curClass.thisClass;
              ClassEntry superClass = curClass.superClass;
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java	2011-07-12 15:23:26.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java	2011-07-12 16:56:06.706260036 +0100
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java	2011-07-27 15:09:07.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackageWriter.java	2011-07-27 15:21:43.747374158 +0100
 @@ -116,7 +116,7 @@
      int[][]     attrCounts;       // count attr. occurences
  
@@ -571,8 +586,8 @@
          int bestCount = 0;
          int bestVersion = -1;
          for (Class cls : pkg.classes) {
-@@ -729,7 +729,7 @@
-     @SuppressWarnings("unchecked")
+@@ -728,7 +728,7 @@
+ 
      void collectAttributeLayouts() {
          maxFlags = new int[ATTR_CONTEXT_LIMIT];
 -        allLayouts = new FixedList<>(ATTR_CONTEXT_LIMIT);
@@ -580,7 +595,7 @@
          for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) {
              allLayouts.set(i, new HashMap<Attribute.Layout, int[]>());
          }
-@@ -774,7 +774,7 @@
+@@ -773,7 +773,7 @@
          }
          // Collect counts for both predefs. and custom defs.
          // Decide on custom, local attribute definitions.
@@ -589,16 +604,16 @@
          attrCounts = new int[ATTR_CONTEXT_LIMIT][];
          for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) {
              // Now the remaining defs in allLayouts[i] need attr. indexes.
-@@ -889,7 +889,7 @@
- 
-     @SuppressWarnings("unchecked")
+@@ -888,7 +888,7 @@
+     Attribute.Layout[] attrDefsWritten;
+ 
      void writeAttrDefs() throws IOException {
 -        List<Object[]> defList = new ArrayList<>();
 +        List<Object[]> defList = new ArrayList<Object[]>();
          for (int i = 0; i < ATTR_CONTEXT_LIMIT; i++) {
              int limit = attrDefs.get(i).size();
              for (int j = 0; j < limit; j++) {
-@@ -1007,7 +1007,7 @@
+@@ -1005,7 +1005,7 @@
      void collectInnerClasses() {
          // Capture inner classes, removing them from individual classes.
          // Irregular inner classes must stay local, though.
@@ -608,9 +623,9 @@
          for (Class cls : pkg.classes) {
              if (!cls.hasInnerClasses())  continue;
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java
---- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java	2011-04-14 01:29:58.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java	2011-07-12 16:56:06.710260102 +0100
-@@ -183,8 +183,8 @@
+--- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java	2011-07-27 14:31:14.000000000 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PackerImpl.java	2011-07-27 15:21:43.755374288 +0100
+@@ -181,8 +181,8 @@
          final Map<Attribute.Layout, Attribute> attrDefs;
          final Map<Attribute.Layout, String> attrCommands;
          {
@@ -621,7 +636,7 @@
              String[] keys = {
                  Pack200.Packer.CLASS_ATTRIBUTE_PFX,
                  Pack200.Packer.FIELD_ATTRIBUTE_PFX,
-@@ -593,7 +593,7 @@
+@@ -590,7 +590,7 @@
                  assert(pkg.files.containsAll(pkg.getClassStubs()));
                  // Order of stubs in file list must agree with classes.
                  List<Package.File> res = pkg.files;
@@ -630,7 +645,7 @@
                         .retainAll(pkg.getClassStubs()) || true);
                  assert(res.equals(pkg.getClassStubs()));
              }
-@@ -626,7 +626,7 @@
+@@ -623,7 +623,7 @@
  
          List<InFile> scanJar(JarFile jf) throws IOException {
              // Collect jar entries, preserving order.
@@ -641,7 +656,7 @@
                      InFile inFile = new InFile(jf, je);
 diff -Nru openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java
 --- openjdk-boot.orig/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java	2011-04-14 01:29:59.000000000 +0100
-+++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java	2011-07-12 16:56:06.714260168 +0100
++++ openjdk-boot/jdk/src/share/classes/com/sun/java/util/jar/pack/PopulationCoding.java	2011-07-27 15:21:43.755374288 +0100



More information about the distro-pkg-dev mailing list