[Bug c++/84525] GCC7: generate movaps instruction when assign to unaligned __int128*

buaa.zhaoc at gmail dot com gcc-bugzilla@gcc.gnu.org
Fri Feb 23 08:54:00 GMT 2018


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

--- Comment #4 from Zhao Chun <buaa.zhaoc at gmail dot com> ---
(In reply to Jakub Jelinek from comment #3)
> (In reply to Zhao Chun from comment #2)
> > Thanks for you explain.
> > It looks some weird to me. 
> > If the type was int64_t or others, this can work.
> 
> No, it would be invalid too.  It may appear to work.
> 
> > Is there some specs to say that __int128 is 16-byte aligned?
> 
> Just check the __alignof__ (__int128) value?

Yes, you'er right.

Is there good way to assign value to unaligned int type except memcpy?


More information about the Gcc-bugs mailing list