[Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code

2021-07-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 --- Comment #5 from Andrew Pinski --- -fsanitize=unreachable will find the C++ cases right now. For C, it is a little harder because it is only undefined if the value is used.

[Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code

2021-07-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 --- Comment #4 from Andrew Pinski --- (In reply to Andrew Pinski from comment #3) > I thought it was defined unless the return value is actually used. To answer my own question: For C it is. For C++ it is not; it is undefined if there is no ret

[Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code

2018-06-25 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 --- Comment #3 from Andrew Pinski --- I thought it was defined unless the return value is actually used.

[Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code

2018-06-25 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 Richard Biener changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed|

[Bug middle-end/86284] Insert trap instruction in place of missing return statement on dodgy code

2018-06-23 Thread glisse at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86284 --- Comment #1 from Marc Glisse --- -fsanitize=return ?