changeset 12992:bf9634b1089e

8197030: Perf regression on all platforms with 8u171-b03 - early lambda use Reviewed-by: weijun
author coffeys
date Tue, 13 Feb 2018 09:25:02 +0000
parents d1ff85e2e682
children d70c21e5b413
files src/share/classes/sun/security/util/ManifestDigester.java
diffstat 1 files changed, 8 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/sun/security/util/ManifestDigester.java	Wed Feb 07 00:09:23 2018 -0800
+++ b/src/share/classes/sun/security/util/ManifestDigester.java	Tue Feb 13 09:25:02 2018 +0000
@@ -169,10 +169,15 @@
                             }
                         }
 
-                        entries.computeIfAbsent(nameBuf.toString(),
-                                                dummy -> new Entry())
+                        Entry e = entries.get(nameBuf.toString());
+                        if (e == null) {
+                            entries.put(nameBuf.toString(), new Entry()
                                 .addSection(new Section(start, sectionLen,
-                                        sectionLenWithBlank, rawBytes));
+                                    sectionLenWithBlank, rawBytes)));
+                        } else {
+                            e.addSection(new Section(start, sectionLen,
+                                    sectionLenWithBlank, rawBytes));
+                        }
 
                     } catch (java.io.UnsupportedEncodingException uee) {
                         throw new IllegalStateException(