From 952f6b3ed1fca02944be260ece517a5db94d2ef3 Mon Sep 17 00:00:00 2001 From: Omair Majid Date: Wed, 16 Apr 2014 10:21:21 -0400 Subject: [PATCH] Revert upstream fix for S8035283 This fix is was not included in the icedtea 7 patches, and possibly causes a crash on i686. --- java-1.8.0-openjdk.spec | 7 +++++++ revert-8035283.patch | 41 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 revert-8035283.patch diff --git a/java-1.8.0-openjdk.spec b/java-1.8.0-openjdk.spec index 5d60bc0..f97ba86 100644 --- a/java-1.8.0-openjdk.spec +++ b/java-1.8.0-openjdk.spec @@ -211,6 +211,9 @@ Patch102: %{name}-size_t.patch # Patch for PPC/PPC64 Patch103: %{name}-ppc-zero-hotspot.patch +# Revert an upstream commit; possibly causes a jit crash +Patch104: revert-8035283.patch + Patch201: system-libjpeg.patch Patch202: system-libpng.patch Patch203: system-lcms.patch @@ -425,6 +428,7 @@ sh %{SOURCE12} %patch6 %patch99 +%patch104 # Type fixes for s390 %ifarch s390 s390x @@ -1095,6 +1099,9 @@ exit 0 %{_jvmdir}/%{jredir}/lib/accessibility.properties %changelog +* Wed Apr 16 2014 Omair Majid - 1:1.8.0.5-1.b13 +- Revert upstream patch for S8035283. Possibly causes a crash on i686. + * Tue Apr 15 2014 Omair Majid - 1:1.8.0.5-1.b13 - Update to the latest security release: OpenJDK8 u5 b13 diff --git a/revert-8035283.patch b/revert-8035283.patch new file mode 100644 index 0000000..1774b29 --- /dev/null +++ b/revert-8035283.patch @@ -0,0 +1,41 @@ +diff --git jdk8/hotspot/src/share/vm/opto/output.cpp jdk8/hotspot/src/share/vm/opto/output.cpp +--- jdk8/hotspot/src/share/vm/opto/output.cpp ++++ jdk8/hotspot/src/share/vm/opto/output.cpp +@@ -344,11 +344,6 @@ + uint* jmp_offset = NEW_RESOURCE_ARRAY(uint,nblocks); + uint* jmp_size = NEW_RESOURCE_ARRAY(uint,nblocks); + int* jmp_nidx = NEW_RESOURCE_ARRAY(int ,nblocks); +- +- // Collect worst case block paddings +- int* block_worst_case_pad = NEW_RESOURCE_ARRAY(int, nblocks); +- memset(block_worst_case_pad, 0, nblocks * sizeof(int)); +- + DEBUG_ONLY( uint *jmp_target = NEW_RESOURCE_ARRAY(uint,nblocks); ) + DEBUG_ONLY( uint *jmp_rule = NEW_RESOURCE_ARRAY(uint,nblocks); ) + +@@ -465,7 +460,6 @@ + last_avoid_back_to_back_adr += max_loop_pad; + } + blk_size += max_loop_pad; +- block_worst_case_pad[i + 1] = max_loop_pad; + } + } + +@@ -505,16 +499,9 @@ + if (bnum > i) { // adjust following block's offset + offset -= adjust_block_start; + } +- +- // This block can be a loop header, account for the padding +- // in the previous block. +- int block_padding = block_worst_case_pad[i]; +- assert(i == 0 || block_padding == 0 || br_offs >= block_padding, "Should have at least a padding on top"); + // In the following code a nop could be inserted before + // the branch which will increase the backward distance. +- bool needs_padding = ((uint)(br_offs - block_padding) == last_may_be_short_branch_adr); +- assert(!needs_padding || jmp_offset[i] == 0, "padding only branches at the beginning of block"); +- ++ bool needs_padding = ((uint)br_offs == last_may_be_short_branch_adr); + if (needs_padding && offset <= 0) + offset -= nop_size; +