summary refs log tree commit diff
path: root/gnu/packages/patches/icedtea-6-hotspot-gcc-segfault-workaround.patch
blob: ef090e0ec9f91fabb771f064d1a2c3b8be77f306 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# HG changeset patch
# User Gábor Boskovits <boskovits@gmail.com>
# Date 1530519413 -7200
#      Mon Jul 02 10:16:53 2018 +0200
# Node ID 77e5bc9e238a28d17e097647badc04ed67a6a452
# Parent  1ae05a34e052d1672b4a7894ddf5fc2f662eb861
Fix gcc segfault.

diff -r 1ae05a34e052 -r 77e5bc9e238a src/share/vm/opto/output.cpp
--- a/src/share/vm/opto/output.cpp	Sun Dec 25 23:52:13 2016 +0000
+++ b/src/share/vm/opto/output.cpp	Mon Jul 02 10:16:53 2018 +0200
@@ -1758,6 +1758,8 @@
 
 // Initializer for class Scheduling
 
+volatile const void *eePointer = Pipeline_Use::elaborated_elements;
+
 Scheduling::Scheduling(Arena *arena, Compile &compile)
   : _arena(arena),
     _cfg(compile.cfg()),
@@ -1802,8 +1804,8 @@
 
   // Clear the bundling information
   memcpy(_bundle_use_elements,
-    Pipeline_Use::elaborated_elements,
-    sizeof(Pipeline_Use::elaborated_elements));
+	 (void *)eePointer,
+    11*sizeof(Pipeline_Use_Element));
 
   // Get the last node
   Block *bb = _cfg->_blocks[_cfg->_blocks.size()-1];
@@ -1854,8 +1856,8 @@
   _bundle_use.reset();
 
   memcpy(_bundle_use_elements,
-    Pipeline_Use::elaborated_elements,
-    sizeof(Pipeline_Use::elaborated_elements));
+	 (void *)eePointer,
+    11*sizeof(Pipeline_Use_Element));
 }
 
 //------------------------------ScheduleAndBundle------------------------------