[all-commits] [llvm/llvm-project] bc792a: [libc++] Encode additional ODR-affecting propertie...
Louis Dionne via All-commits
all-commits at lists.llvm.org
Thu Oct 26 06:05:31 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: bc792a284362696c91599f9ab01f74eda4b9108f
https://github.com/llvm/llvm-project/commit/bc792a284362696c91599f9ab01f74eda4b9108f
Author: Louis Dionne <ldionne.2 at gmail.com>
Date: 2023-10-26 (Thu, 26 Oct 2023)
Changed paths:
M libcxx/include/__config
A libcxx/test/libcxx/odr_signature.exceptions.sh.cpp
A libcxx/test/libcxx/odr_signature.hardening.sh.cpp
Log Message:
-----------
[libc++] Encode additional ODR-affecting properties in the ABI tag (#69669)
As explained in `__config`, we have an ABI tag that we use to ensure
that we don't run into ODR issues when mixing different versions of
libc++ in multiple TUs. However, the reasoning behind that extends not
only to different versions of libc++, but also to different
configurations of the same version of libc++. In fact, we've been aware
of this for a while but never really bothered to make the change because
ODR issues are often thought to be benign.
Well, it turns out that I just spent over an hour banging my head
against an issue that boils down to our lack of encoding of some ODR
properties in the ABI tag, so here's the patch we should have done a
long time ago.
For now, the ODR properties we encode in the ABI tag are:
- library version
- exceptions vs no-exceptions
- hardening mode
Those are all things that we support different values for on a per-TU
basis and they definitely affect ODR in a meaningful way. We can add
more properties later as we see fit.
More information about the All-commits
mailing list