This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH i386 5/8] [AVX-512] Extend vectorizer hooks.


> > x86-64 ABI has clause about aligning static vars to 128bit boundary at a
> > given size.  This was introduced to aid compiler to generate aligned
> > vector store/load even if the object may bind to other object file.
> > This is set to stone and can not be changed for AVX/SSE.
> 
> Yes, but that's irrelevant in 32-bit mode.
> 
> > For other objects that are fully under local control we can bump up
> > alignment more.  I remember this code was originally supposed to bump up
> > to 128bits since it was written long before AVX.  I suppose it would make
> > sense to do so when AVX is enabled and we anticipate to use it.
> 
> So the same unexpected side-effect (decreasing the alignment) probably happened 
> when the maximum alignment was bumped from 128 to 256.

Yes, that code was written with only one vector mode in mind.
It would be nice to have some data if the code helps at all though, but I guess
it would be sanner to bump alignment up to largest enabled vector mode that
is smaller than object size instead of what we do now.

Honza


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]