https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122986
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- >The values are initialized, so this seems like an optimization bug. No there is undefined behavior due to aliasing violations. You store to light as a struct Image32 (which contains 4 uint8_t) but then do a load via uint32_t. And from an aliasing point of view, uint32_t and Image32 can't alias.
