img2ktx icon indicating copy to clipboard operation
img2ktx copied to clipboard

DEADLYSIGNAL when compress into BC3 format

Open frokaikan opened this issue 7 years ago • 2 comments

I use cmake to build the library then run: ./img2ktx -o out.ktx -f BC3 input/not_kitty.png here's not_kitty.png: not_kitty.zip

Loaded input/not_kitty.png -- width=32 height=32 comp=3
compressing mip 0 layer 0: width=32 height=32 pitch_x=32 pitch_y=32
AddressSanitizer:DEADLYSIGNAL
=================================================================
==3641==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x0000008c0f2a bp 0x7ffd3a604c00 sp 0x7ffd3a604778 T0)
==3641==The signal is caused by a READ memory access.
==3641==Hint: address points to the zero page.
    #0 0x8c0f29 in _fini (/opt/img2ktx/img2ktx+0x8c0f29)

AddressSanitizer can not provide additional info.
SUMMARY: AddressSanitizer: SEGV (/opt/img2ktx/img2ktx+0x8c0f29) in _fini
==3641==ABORTING

frokaikan avatar Aug 16 '18 02:08 frokaikan

I'm afraid I don't have a Unix system to test on right now, and running on Windows seems to produce the expected output successfully. However, there's a decent chance that whatever ASan is complaining about is in ispc_texcomp, and I happen to be in the middle of replacing the ispc_texcomp compression backend with AMD's Compressonator. If you're curious (and haven't lost interest or found an alternative tool by now -- sorry for the delay in investigating!), I can point you towards the branch where this work is happening and you can see if the problem has disappeared along with the old backend.

cdwfs avatar Nov 25 '18 23:11 cdwfs

This will likely be fixed by #6 once the branch is merged

cdwfs avatar Jan 10 '20 01:01 cdwfs