Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

store to misaligned address / for type 'int64_t', which requires 8 byte alignment #189

Closed
malaterre opened this issue Apr 26, 2016 · 3 comments
Assignees
Labels
Bug A bug in the source code

Comments

@malaterre
Copy link

OpenEXR test suite fails on m68k and sparc64. OpenEXR rely on undefined behavior for accessing 8 byte aligned data.

Full backtrace is:

Running testCopyDeepScanLine

Testing raw data copy in DeepScanLineInput/OutputFile:

[New Thread 0xfffff80101c85910 (LWP 20279)]
[New Thread 0xfffff80102485910 (LWP 20280)]
[New Thread 0xfffff80102c85910 (LWP 20281)]
[New Thread 0xfffff80103485910 (LWP 20282)]
Testing files with 1 channels 100 times.
generating compression 0 writing copying
Program received signal SIGBUS, Bus error.
Imf_2_2::DeepScanLineInputFile::rawPixelData
(this=this@entry=0x7feffffef08, firstScanLine=,
pixelData=0x3cbb30 "", pixelDataSize=@0x7feffffeca0: 8220) at
ImfDeepScanLineInputFile.cpp:1464
1464 *(Int64 *) (pixelData+4) =sampleCountTableSize;
(gdb) bt full
#0 Imf_2_2::DeepScanLineInputFile::rawPixelData

(this=this@entry=0x7feffffef08, firstScanLine=,
pixelData=0x3cbb30 "", pixelDataSize=@0x7feffffeca0: 8220) at
ImfDeepScanLineInputFile.cpp:1464
minY = 51
lineBufferNumber =
lineOffset = 2220
lock = {_mutex = @0x33cc40, _locked = false}
yInFile = 51
sampleCountTableSize = 2152
packedDataSize = 6040
totalSizeRequired = 8220
big_enough =
#1 0xfffff801008836b8 in Imf_2_2::DeepScanLineOutputFile::copyPixels

(this=this@entry=0x7feffffef18, in=...) at
ImfDeepScanLineOutputFile.cpp:1480
unpackedDataSize =
dataSize = 8220
packedSampleCountSize =
packedDataSize =
sampleCountTable =
pixelData =
lock = {_mutex = @0x33c3c0, _locked = false}
hdr =
inHdr =
dataWindow =
data = std::vector of length 8220, capacity 8220 = {0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000', 0 '\000',
0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000',
0 '\000'...}
#2 0x0000000000189994 in (anonymous namespace)::copyFile

(copy_filename="/var/tmp/IlmImfTest_EMVUZQZE/imf_test_copy_deep_scanline_copy.exr",
source_filename="/var/tmp/IlmImfTest_EMVUZQZE/imf_test_copy_deep_scanline_source.exr")
at testCopyDeepScanLine.cpp:224
in_file = {<Imf_2_2::GenericInputFile> =
{_vptr.GenericInputFile = 0xfffff80100a97bb0 <vtable for
Imf_2_2::DeepScanLineInputFile+16>}, _data = 0x33bfe0}
out_file = {<Imf_2_2::GenericOutputFile> =
{_vptr.GenericOutputFile = 0xfffff80100a97c00 <vtable for
Imf_2_2::DeepScanLineOutputFile+16>}, _data = 0x341190}
#3 (anonymous namespace)::readCopyWriteTest

(tempDir="/var/tmp/IlmImfTest_EMVUZQZE/",
channelCount=channelCount@entry=1, testTimes=testTimes@entry=100) at
testCopyDeepScanLine.cpp:404
compressionIndex = 0
compression = Imf_2_2::NO_COMPRESSION
i = 0
source_filename =
"/var/tmp/IlmImfTest_EMVUZQZE/imf_test_copy_deep_scanline_source.exr"
copy_filename =
"/var/tmp/IlmImfTest_EMVUZQZE/imf_test_copy_deep_scanline_copy.exr"
#4 0x0000000000189be8 in testCopyDeepScanLine

(tempDir="/var/tmp/IlmImfTest_EMVUZQZE/") at
testCopyDeepScanLine.cpp:428
numThreads = 0
PRETTY_FUNCTION = "void testCopyDeepScanLine(const string&)"
#5 0x0000000000118870 in main (argc=,

argv=0x7fefffff638) at main.cpp:182
rand48 = {_state = {6487, 20709, 10507}}
tempDir = "/var/tmp/IlmImfTest_EMVUZQZE/"
ss =
(gdb)

@malaterre
Copy link
Author

Original bug report: https://bugs.debian.org/822583

@malaterre
Copy link
Author

@cary-ilm cary-ilm added the Bug A bug in the source code label Jun 29, 2019
@cary-ilm cary-ilm added this to the Needs Attention milestone Jun 29, 2019
@cary-ilm cary-ilm self-assigned this Jul 11, 2019
@cary-ilm
Copy link
Member

Looking into the backlog of open OpenEXR issues. The OpenEXR maintainers don't have access to m68k or sparc64 machines, if anyone would like to volunteer a fix, we'd be happy to review it, but barring that, we have to say OpenEXR is not supported on those systems. Closing the issue for now, feel free to reopen or file a new issue if you'd like to pursue it further.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in the source code
Projects
None yet
Development

No branches or pull requests

2 participants