# HG changeset patch # User dsamersoff # Date 1482231232 0 # Node ID 6eeb895b1a6f2ce2ac0bb257e23d4788db320466 # Parent 0b0ae99d86396b67158b1572d0ca04d4ecb2da15# Parent 9d8028808e7875ecd18f0ffb472d6a914aa87917 Merge diff -r 0b0ae99d8639 -r 6eeb895b1a6f hotspot/src/share/vm/logging/logFileStreamOutput.cpp --- a/hotspot/src/share/vm/logging/logFileStreamOutput.cpp Tue Dec 20 13:35:40 2016 +0300 +++ b/hotspot/src/share/vm/logging/logFileStreamOutput.cpp Tue Dec 20 10:53:52 2016 +0000 @@ -29,11 +29,17 @@ #include "memory/allocation.inline.hpp" static bool initialized; -static char stdoutmem[sizeof(LogStdoutOutput)]; -static char stderrmem[sizeof(LogStderrOutput)]; +static union { + char stdoutmem[sizeof(LogStdoutOutput)]; + jlong dummy; +} aligned_stdoutmem; +static union { + char stderrmem[sizeof(LogStderrOutput)]; + jlong dummy; +} aligned_stderrmem; -LogStdoutOutput &StdoutLog = reinterpret_cast(stdoutmem); -LogStderrOutput &StderrLog = reinterpret_cast(stderrmem); +LogStdoutOutput &StdoutLog = reinterpret_cast(aligned_stdoutmem.stdoutmem); +LogStderrOutput &StderrLog = reinterpret_cast(aligned_stderrmem.stderrmem); LogFileStreamInitializer::LogFileStreamInitializer() { if (!initialized) {