[Bug tree-optimization/35653] [4.3/4.4 Regression]: gcc-4.3 -O3/-ftree-vectorize regression: incorrect code generation
edwintorok at gmail dot com
gcc-bugzilla@gcc.gnu.org
Sun Mar 23 17:00:00 GMT 2008
------- Comment #8 from edwintorok at gmail dot com 2008-03-23 16:59 -------
(In reply to comment #7)
> Subject: Re: [4.3/4.4 Regression]: gcc-4.3 -O3/-ftree-vectorize regression:
> incorrect code generation
>
> This code violates c/c++ aliasing rules.
>
-Wstrict-aliasing doesn't give a warning about it.
Accessing the memory as uint32_t is done for performance reasons, the
alternative would be to use byte-sized accesses. When reading, it would involve
additional shift/or instructions.
If the pointer is not aligned at 4 bytes, then uint32_t can't be done?
If that is the case, a warning would be *very* useful.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35653
More information about the Gcc-bugs
mailing list