TUKLIB_FAST_UNALIGNED_ACCESS must not be defined in src/lib/liblzma/config.h on strict alignment architectures

M. Warner Losh imp at bsdimp.com
Mon Sep 13 13:46:16 UTC 2010


In message: <20100913090903.GA56310 at ci0.org>
            Olivier Houchard <mlfbsd at ci0.org> writes:
: On Wed, Sep 08, 2010 at 01:37:20AM +0200, crest wrote:
: > I noticed that /usr/bin/xz crashed with signal 10 on a Feroceon 
: > 88FR131 rev 1 CPU and traced back to an unaligned 16 bit memory access 
: > in liblzma. This is enabled by TUKLIB_FAST_UNALIGNED_ACCESS in 
: > src/lib/liblzma/config.h. Uncommenting this line fixed the problem. 
: > This may cost some performance on non strict aligment architectures 
: > (e.g. x86, most ppc). Passing it via CFLAGS instead of config.h based 
: > on architecture would fix this problem.
: 
: Hi,
: 
: 
: We define __NO_STRICT_ALIGNMENT in machine/_types.h for machine which can do
: unaligned access, so maybe defining TUKLIB_FAST_UNALIGNED_ACCESS only if
: __NO_STRICT_ALIGNMENT is there would do the trick ?

I was going to suggest the same thing...

Warner


More information about the freebsd-arm mailing list