[libcxx-commits] [libcxx] [libc++][hardening] Rework how the assertion handler can be overridden. (PR #77883)

Konstantin Varlamov via libcxx-commits libcxx-commits at lists.llvm.org
Thu Jan 11 23:34:38 PST 2024


var-const wrote:

@nico Hi Nico, this patch still needs some work to update the documentation, but I wanted to give you a heads-up as soon as possible. This patch is not a breaking change (the new `_LIBCPP_ASSERTION_HANDLER` still calls `_LIBCPP_VERBOSE_ABORT`, so the existing mechanisms for overriding verbose abort should still work), but an immediate follow-up will make the assertion handler call `__builtin_trap` instead, which would essentially force projects to use the new mechanism (overriding verbose abort wouldn't produce errors but will effectively become a no-op as hardening failures will ignore it). We hope it makes transition easier by introducing an intermediate state where both the old and the new overriding mechanisms work.

Please let us know if you have any concerns or feedback regarding this direction. Thanks!

https://github.com/llvm/llvm-project/pull/77883


More information about the libcxx-commits mailing list