[libcxx-commits] [PATCH] D126462: [libc++] Re-enable std::pair trivial copy constructor for FreeBSD >= 14
Dimitry Andric via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Thu May 26 09:23:07 PDT 2022
dim added a comment.
In D126462#3540371 <https://reviews.llvm.org/D126462#3540371>, @philnik wrote:
> In D126462#3539933 <https://reviews.llvm.org/D126462#3539933>, @emaste wrote:
>
>> Sounds good to me. We can bump the .so version in the base system, but how do we treat it upstream (i.e., here in llvm) and in the ports tree?
>
> Would it make sense from your side to to declare ABIv2 stable?
I had been sort of waiting for this, but after so many years I failed to hold my breath. :-) Because that would've solved our problem with the old std::pair ABI, obviously.
> It sounds to me like you break the ABI between FreeBSD 13 and 14, right? That would remove the problem of differing versions between upstream and the system version. No guarantees that we actually do this, but I would be in favour of setting such a precedent. (And we would probably need a few months to get everything going.)
Well, recently rG0d8cb8b399adcd17e8bf17be7814d030308c8b82 <https://reviews.llvm.org/rG0d8cb8b399adcd17e8bf17be7814d030308c8b82> broke builds on FreeBSD, precisely because of this old std::pair ABI, so that is mostly what triggered this. I remember there were some other programs (chromium or googletest, probably) that also had build issues, because they were silently assuming std::pair was trivially copyable.
Since FreeBSD attempts to keep ABIs stable in released versions, for our 12.x and 13.x branches there isn't any good way forward, except keeping the old ABI forever, until the branches reach EOL. But for 14.0, which is our trunk/main/head, there is no such ABI promise, therefore we can simply bump libc++.so to .2 now and fix the issue that way. If the upstream libc++ ABI version gets bumped to 2 though, we'll have to bump our .so to .3 I'm afraid, since the ELF soversion doesn't really allow "half-sized" version numbers.
That said, I'm unsure how many other downstream consumers are waiting for the upstream libc++ ABI to change? I haven't been following exactly what new features or incompatibilities have been covered by ABIv2; are there a lot of those?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D126462/new/
https://reviews.llvm.org/D126462
More information about the libcxx-commits
mailing list