When make_tree() creates the left-justified base table (uint64_t *B)
it does so with 64-bit stores:
B[k] = sofar;
But B points to memory in the zero-length array "uint32_t tt[0]" at the
end of struct decoder_state. Since tt's type is uint32_t, it is only
aligned to a four byte boundary, and so the 64-bit store in make_tree()
causes an unaligned trap on strict platforms like sparc.
When make_tree() creates the left-justified base table (uint64_t *B) it does so with 64-bit stores:
But B points to memory in the zero-length array "uint32_t tt[0]" at the end of struct decoder_state. Since tt's type is uint32_t, it is only aligned to a four byte boundary, and so the 64-bit store in make_tree() causes an unaligned trap on strict platforms like sparc.