[Bug c++/84724] [7/8 Regression] internal compiler error: in single_succ_edge, at basic-block.h:339 with a declaration of __builtin_trap

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Mar 6 11:55:00 GMT 2018


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84724

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org,
                   |                            |jason at gcc dot gnu.org

--- Comment #3 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
The C FE has quite a lot of code in this case, e.g.
match_builtin_function_types, which the C++ FE doesn't seem to have, and indeed
the C FE leaves the __builtin_trap decl untouched after warning, while the C++
FE changes it.

The ICE in this case isn't caused by a mismatch between __builtin_trap ()
return type, but rather the lack of noreturn attribute on the new decl.
Though I'm sure that redefining similar way many other builtins that GCC emits
on its own or expects a particular arguments or return types will cause many
other ICEs.


More information about the Gcc-bugs mailing list