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

Xi Ruoyao <xry111 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |xry111 at gcc dot gnu.org

--- Comment #7 from Xi Ruoyao <xry111 at gcc dot gnu.org> ---
(In reply to Mikhail Mitskevich from comment #4)
> (In reply to Andrew Pinski from comment #1)
> >  belt_mac_st* st = &state;
> >  belt_mac_st* st2 = &state2;
> >  ((word*)(st->s))[0] = 0, ((word*)(st->s))[1] = 0;
> >  ((word*)(st->r))[0] = 0, ((word*)(st->r))[1] = 0;
> >  st->filled = 0;
> > 
> > I am 99% sure those are aliasing rule violations.
> > 
> > Does -fno-strict-aliasing help?
> 
> With -fno-strict-aliasing option code works as well as with -O1 option.

Then it's likely the code is buggy, not GCC is buggy (unless you have some
fancy type attributes on "word" or "belt_mac_st").

Reply via email to