Subject: Re: ncr53c9x changes proposed
To: None <pk@cs.few.eur.nl>
From: Gordon W. Ross <gwr@mc.com>
List: tech-kern
Date: 04/01/1997 16:52:35
> From: Paul Kranenburg <pk@cs.few.eur.nl>
> Date: Tue, 1 Apr 1997 23:42:22 +0200 (MET DST)
> They seem ok.
>
> Actually I thought I had done the timeout/untimeout reshuffling quite
> some time ago.. hmm maybe these got lost in transit to /sys/dev.
>
> Why do you need the `pad[3]' ?
There is no "need" for the padding, strictly speaking.
However, they represent a "micro-optimization" for m68k
machines. (I'm sure we all love micro-optimization! 8^)
The m68k compiler aligns structure members only to a 16
bit boundary (hold-over from ancien 16-bit bus 68k's) but
there is some performance gained by keeping 32-bit values
aligned on 32-bit boundaries on "modern" (Tee hee!) m68k's
with a 32-bit memory bus.
In this case, the optimization has no cost other than to
"dirty up" the strucure definitions. It would be nice if
instead, we could make the m68k compiler align structure
members on 32-bit boundaries unless told specificaly not
to do so for some special cases (i.e. struct frame).
In the mean time, I don't mind doing padding by hand.
I hope nobody minds an occasional "char pad[]" much.
They also make memory dumps in ddb easier to read...
Gordon