------- Comment #7 from rguenth at gcc dot gnu dot org  2010-02-09 23:18 -------
(In reply to comment #6)
> > Your pointer isn't properly aligned to be accessed via uint32_t*.
> 
> That's hardly satisfactory an answer.  GCC has always generated working code 
> on
> non-strict alignment platforms in this case and one can expect it to continue.
> 
> Moreover, the psABI is explicit:
> 
> "Like the Intel386 architecture, the AMD64 architecture in general does not
> require all data accesses to be properly aligned. Misaligned data accesses are
> slower than aligned accesses but otherwise behave identically. The only
> exception is that __m128 must always be aligned properly."
> 
> and there is no __m128 in the source code.

The C language standard says such pointer invokes undefined behavior.  The
non-working code is vectorized, and vectorized code can have strict
alignment requirements.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43009

Reply via email to