# HG changeset patch # User Andrew John Hughes # Date 1390241329 0 # Node ID cb0efad69ad36250f66f87c4575d9f36e66ae3d7 # Parent c9ac092141ed6762312fada7c19d7b43eff11cf2 D729448: 32-bit alignment on mips and mipsel 2013-11-21 Andrew John Hughes * Makefile.am: (ICEDTEA_PATCHES): Add new patch. * patches/d729448-32_bit_alignment.patch: Fix alignment on mips and mipsel. diff -r c9ac092141ed -r cb0efad69ad3 ChangeLog --- a/ChangeLog Thu Sep 19 17:00:58 2013 +0100 +++ b/ChangeLog Mon Jan 20 18:08:49 2014 +0000 @@ -1,3 +1,10 @@ +2013-11-21 Andrew John Hughes + + * Makefile.am: + (ICEDTEA_PATCHES): Add new patch. + * patches/d729448-32_bit_alignment.patch: + Fix alignment on mips and mipsel. + 2013-09-19 Andrew John Hughes * configure.ac: diff -r c9ac092141ed -r cb0efad69ad3 Makefile.am --- a/Makefile.am Thu Sep 19 17:00:58 2013 +0100 +++ b/Makefile.am Mon Jan 20 18:08:49 2014 +0000 @@ -813,7 +813,8 @@ patches/openjdk/6980681-corba_deadlock.patch \ patches/openjdk/7162902-corba_fixes.patch \ patches/traceable.patch \ - patches/openjdk/6893617-cnctx_always_uses_default_orb.patch + patches/openjdk/6893617-cnctx_always_uses_default_orb.patch \ + patches/d729448-32_bit_alignment.patch if WITH_RHINO ICEDTEA_PATCHES += \ diff -r c9ac092141ed -r cb0efad69ad3 patches/d729448-32_bit_alignment.patch --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/d729448-32_bit_alignment.patch Mon Jan 20 18:08:49 2014 +0000 @@ -0,0 +1,47 @@ +# HG changeset patch +# User andrew +# Date 1384967615 0 +# Wed Nov 20 17:13:35 2013 +0000 +# Node ID 05b64403a1917ddd9e0dd3880a5707e083ed9aba +# Parent 9d01164b2dfc36fb13984cb0854b2c7a9e4dbfbe +D729448: 32-bit alignment on mips and mipsel + +diff -r 9d01164b2dfc -r 05b64403a191 src/share/vm/interpreter/bytecodeInterpreter.hpp +--- openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.hpp Tue Nov 12 17:58:35 2013 +0000 ++++ openjdk/hotspot/src/share/vm/interpreter/bytecodeInterpreter.hpp Wed Nov 20 17:13:35 2013 +0000 +@@ -60,7 +60,16 @@ + jlong l; + jdouble d; + uint32_t v[2]; +-}; ++} ++#ifndef _LP64 ++ /* Hotspot only aligns the union to the uintptr_t type, that is 32 bit ++ on a 32-bit CPU. Accesses to double values should be 64-bit aligned ++ on at least MIPS and SPARC. Declare it to GCC for all 32-bit CPUs, ++ as it might also help GCC to select the best instruction on other ++ CPUs. */ ++ __attribute__ ((packed, aligned (4))) ++#endif ++; + + + typedef class BytecodeInterpreter* interpreterState; +@@ -172,7 +181,16 @@ + jlong l; + jdouble d; + uint32_t v[2]; +-}; ++} ++#ifndef _LP64 ++ /* Hotspot only aligns the union to the uintptr_t type, that is 32 bit ++ on a 32-bit CPU. Accesses to double values should be 64-bit aligned ++ on at least MIPS and SPARC. Declare it to GCC for all 32-bit CPUs, ++ as it might also help GCC to select the best instruction on other ++ CPUs. */ ++ __attribute__ ((packed, aligned (4))) ++#endif ++; + + /* + * Generic 32-bit wide "Java slot" definition. This type occurs