https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #12 from Wilhelm M ---
(In reply to Wilhelm M from comment #11)
> Without an underlying type but with -fshort-enums the underlying type should
> be as small as possible. In this case this should be a uint8_t. But in this
> case we ge
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #11 from Wilhelm M ---
Without an underlying type but with -fshort-enums the underlying type should be
as small as possible. In this case this should be a uint8_t. But in this case
we get a 16-bit value for mState. This is a clear vi
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
Jakub Jelinek changed:
What|Removed |Added
CC||jakub at gcc dot gnu.org
--- Comment #1
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
Martin Liška changed:
What|Removed |Added
Status|ASSIGNED|NEW
Assignee|marxin at gcc dot
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
Martin Liška changed:
What|Removed |Added
Assignee|unassigned at gcc dot gnu.org |marxin at gcc dot
gnu.org
Ev
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #7 from Marc Glisse ---
(Wilhelm, when you post testcases, please post the full file including the
#include lines)
(In reply to Richard Biener from comment #5)
> Did you try -fstrict-enums?
IIUC, even if optimizations using -fstric
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #6 from Wilhelm M ---
(In reply to Richard Biener from comment #5)
> Did you try -fstrict-enums?
Yes, that doesn't change anything.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
Richard Biener changed:
What|Removed |Added
Keywords||missed-optimization
--- Comment #5 fro
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #4 from Wilhelm M ---
In the following class the static data member is accessible via explicit
template instantiation from the outside. So the compiler cannot reason that the
value is in [0,2]. But this does not hold for the function
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #3 from Wilhelm M ---
(In reply to Andrew Pinski from comment #1)
> > In the following example the default-case
>
> Yes it can. You can pass a 0xf to that function and still have well defined
> behavior.
Oh yes, thank you for the
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #2 from Andrew Pinski ---
There is one part which GCC could optimize better that is the store.
There might be another bug about that too.
Note as I mentioned __builtin_unreachable is needed if truely the value coming
inside g is out
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107622
--- Comment #1 from Andrew Pinski ---
> In the following example the default-case
Yes it can. You can pass a 0xf to that function and still have well defined
behavior.
12 matches
Mail list logo