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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |RESOLVED
         Resolution|---                         |INVALID

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Christian Franke from comment #2)
> If the builtin is also noreturn on the other (non-x86) platforms, a cosmetic
> issue remains only:
> libssp/ssp.c contains dead code with a misleading comment which suggests
> that __builtin_trap() may return under some unknown circumstances. The
> section starting with 'Try very hard to exit. ...' could be replaced by
> __builtin_trap().

__builtin_trap can never return.  If the target does not define a pattern for
trap, it will expand to a call to abort.  If a target ever defines it to
something that it returns, then it is broken ...

Really libssp code is generic and works always, just was programmed just in
case.

Yes GCC removes the "break" but that does not mean libssp code is wrong or
anything, just that the code is doing what is expected to do.  illegal
instruction signals are not maskable; they are recoverable from though but who
in the right mind would setup a signal handler to do that?

Reply via email to