[Bug nptl/22351] Unaligned pthread_cond_t stopped working

carlos at redhat dot com sourceware-bugzilla@sourceware.org
Fri Oct 27 02:15:00 GMT 2017


https://sourceware.org/bugzilla/show_bug.cgi?id=22351

--- Comment #5 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to Tulio Magno Quites Machado Filho from comment #4)
> Re-opening this bug, so that my previous comment receive a reply.

There isn't much to say really. It's not supported. You have to know *exactly*
how every structure in the packed structure is going to be accessed and if
that's safe. In the case of POSIX threads, the person packing the structure
doesn't know how it will be accessed, and violating the ABI by packing is a
failure of the programmer. In some cases we can make this *safer* by
introducing explicit padding, but the lead element can still be unaligned, and
there is not way to fix that.

It can fail with any forced packing that happens to not honour what the actual
structures need, including pack(4), on hppa you needed aligned(16) for the ldcw
to work!

I think this is still a RESOLVED/INVALID use case.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Glibc-bugs mailing list