https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #12 from Martin Liška ---
Author: marxin
Date: Wed Dec 20 08:50:56 2017
New Revision: 255851
URL: https://gcc.gnu.org/viewcvs?rev=255851&root=gcc&view=rev
Log:
Add two test-cases for (PR middle-end/82404).
2017-12-20 Martin Liska
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #11 from Martin Liška ---
(In reply to Antony Polukhin from comment #10)
> Do we need a autotest on that to make sure that cmp won't appear again?
Yes, there's patch request:
https://gcc.gnu.org/ml/gcc-patches/2017-12/msg01228.html
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #10 from Antony Polukhin ---
Do we need a autotest on that to make sure that cmp won't appear again?
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
Martin Liška changed:
What|Removed |Added
Status|NEW |RESOLVED
Resolution|---
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #8 from Martin Liška ---
Author: marxin
Date: Mon Nov 6 09:02:15 2017
New Revision: 254437
URL: https://gcc.gnu.org/viewcvs?rev=254437&root=gcc&view=rev
Log:
Instrument function exit with __builtin_unreachable in C++
2017-11-06 Ma
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #7 from Jonathan Wakely ---
Clang's transformation is not based on the valid values of the enumeration, but
the fact that there's a missing return statement, so if you call it with an
argument that isn't one of the cases it's UB. The
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #6
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #5 from Martin Liška ---
(In reply to Martin Liška from comment #3)
> I can work on that, Andrew can you point to differences in between C and C++
> differences of enum values?
Scoper enumeration is here answer I guess.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #4 from Martin Liška ---
I can confirm in C, clang adds guard checks:
$ cat pr82405-2.c
enum eShape { eSquare, eCircle, eShpere, eTetraeder };
double test_switch_native(enum eShape shape, double r) {
switch(shape) {
case eSq
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
Martin Liška changed:
What|Removed |Added
Status|UNCONFIRMED |NEW
Last reconfirmed|
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
--- Comment #2 from Andrew Pinski ---
Oh this has to be c++ because of enum class.
So gcc just does not use the undefinedness here.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82404
Andrew Pinski changed:
What|Removed |Added
Component|target |middle-end
--- Comment #1 from Andrew Pi
12 matches
Mail list logo