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: PR target/40838: gcc shouldn't assume that the stack is aligned


"H.J. Lu" <hjl.tools@gmail.com> writes:

> Vectorizer may not call assign_*_temp at all. Instead, x86 backend
> may call gen_reg_rtx to generate pseudo registers when expanding
> vector statement.

It simply does not make sense to change the vectorizer, of all things,
to set the stack alignment.  Stack alignment depends upon the
types/modes of automatic variables stored on the stack.  Therefore,
you should set the required stack alignment based on the creation of
automatic variables.  Ideally you would set the required stack
alignment for automatic variables stored on the stack, but apparently
you can't change the stack alignment after expand (though I don't see
why not).  So if you can't set the stack alignment based on automatic
variables stored on the stack, then you should set it based on the
creation of automatic variables.

Ian


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