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]

Re: Double alignment patches for x86


>> I remember the patch, but I thought you said it wasn't actually meant to
>> be installed, just for folks to start playing with?
> 
> Exactly.  As long as no one demonstrates that the patch has a positive
> effect, there is no reason to install it.  I mentioned it so that John
> could avoid duplicating the effort.

Too late. :-)

>> Did you get any feedback?
>
> Toon Moene ran some benchmarks, but did not get conclusive results.  All
> messages related to this are in the December egcs-patches archive, for
> those who are interested.

I'm a bit concern about redefining BIGGEST_ALIGNMENT / GET_MODE_ALIGNMENT
since:

  1) This affects all BLKmode stack allocations which is excessive
     in the case of simple integer structures.

  2) This affects the assumed alignment of an object.  This will cause
     problems in the case of a machine where the startup doesn't align
     the stack (in addition to the current problem which occurs with
     nested functions).  It may cause problems in other situations as
     well.  For example ... doesn't this also impact the assumed alignment
     of static objects?  What happens when linking with a runtime library
     which has doubles aligned on 32 bit boundaries?

The approach I took is similar to how extra alignment of static objects
is handled.  I defined a new macro (LOCAL_ALIGNMENT) which is used
by assign_stack_local and friends to increase the alignment "behind
the scenes".  This way egcs doesn't assume that an object is aligned
on a more strict boundary than may actually be the case.  Using a macro
(which is similar to DATA_ALIGNMENT in operation) also allows more
flexibility in describing the alignment characteristics then your change
to emit-rtl.c.

-- John
-------------------------------------------------------------------------
|   Feith Systems  |   Voice: 1-215-646-8000  |  Email: john@feith.com  |
|    John Wehle    |     Fax: 1-215-540-5495  |                         |
-------------------------------------------------------------------------



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