sizeof struct
    Doug Gwyn 
    gwyn at smoke.BRL.MIL
       
    Thu Sep  7 14:15:08 AEST 1989
    
    
  
In article <14529 at haddock.ima.isc.com> karl at haddock.ima.isc.com (Karl Heuer) writes:
>In this particular case, the processor doesn't require any special alignment
>for the structure in question, but the implementation pads it anyway.  (As is
>its right, silly though it may be.)  It's not a bug, just a misfeature.
It's not necessarily silly.  When the first VAX C compiler was implemented,
the implementors decided to longword-align such things even though the VAX
is byte-addressable.  It made typical programs run faster on the only model
available at that time (VAX-11/780).  That was due to the operation of the
memory buffer cache.
    
    
More information about the Comp.lang.c
mailing list