[PATCH] D140868: [C] Make (c ? e1 : e2) noreturn only if both e1 and e2 are noreturn
Sam James via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 4 17:01:18 PST 2023
thesamesam added a comment.
Confirmed this patch fixes the miscompile.
Right. While the spec side needs discussion (and almost certainly addressing!), I don't think anyone in the real world is expecting the Clang behaviour vs the GCC one. The Clang one as-is is the one that's less conservative, as aggressively imposing Noreturn can only lead to something breaking.
I don't have ICC available to test.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D140868/new/
https://reviews.llvm.org/D140868
More information about the cfe-commits
mailing list