This is the mail archive of the gcc@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: -malign-*=0 vs 2


On Mon, Dec 08, 1997 at 11:55:23PM -0700, Jeffrey A Law wrote:
>   In message <199712081630.LAA19482@onsager.chem.mcgill.ca.>you write:
>   > to zero (for my pentium), but would like someone to comment on why this is 
>   > correct, and why Linus is wrong.
> I think you would have to ask Linux why he did things like that.

Linus found out that the 16 byte alignment was simply excessive and not necessary.
He did not try to use zero alignment, which should be as fast as 16 byte alignment,
so he stuck with the (IMHO) 4 byte alignment.

Anyhow, kernel speed wasn't that much of an issue, since time-critical paths
are full of hand-optimized assembler anyway, and the memory loss
due to the big alignment was considerable.

      -----==-                                              |
      ----==-- _                                            |
      ---==---(_)__  __ ____  __       Marc Lehmann       +--
      --==---/ / _ \/ // /\ \/ /       pcg@goof.com       |e|
      -=====/_/_//_/\_,_/ /_/\_\                          --+
    The choice of a GNU generation                        |
                                                          |


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