Preventing gcc from aligning stack???

David Weinehall tao en acc.umu.se
Mie Ene 26 12:38:53 CST 2000


On Wed, 26 Jan 2000, Jamie Lokier wrote:

> David Weinehall wrote:
> > Oh, talking about alignment, how about anyone familiar with the inner
> > workings of gcc (2.7.2.3 in this case) tell me why I get this warning for
> > all newer v2.3.xx kernels:
> > 
> > sched.c:77: warning: alignment of `aligned_data' is greater than maximum
> > object file alignment
> 
> That's not i386 is it?

486.
 
> ELF, used by many targets, supports large alignments.  But formats like
> COFF and a.out do not, and GCC knows this.

Oki.
 
> Linux uses larger alignments for some things that should be aligned to a
> cache line, either to reduce SMP inter-processor traffic or simply
> because it's faster to read fewer cache lines for some critical things.

I doubt this is a good idea on 386's/486's, but I might be wrong...


/David
  _                                                                 _ 
 // David Weinehall <tao en acc.umu.se> /> Northern lights wander      \\
//  Project MCA Linux hacker        //  Dance across the winter sky // 
\>  http://www.acc.umu.se/~tao/    </   Full colour fire           </ 


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo en vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/



Más información sobre la lista de distribución Ayuda