Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 Jul 1997 10:25:39 -0600
From:      Steve Passe <smp@csn.net>
To:        Bruce Evans <bde@zeta.org.au>
Cc:        cvs-all@FreeBSD.ORG, cvs-committers@FreeBSD.ORG, cvs-sys@FreeBSD.ORG, fsmp@FreeBSD.ORG
Subject:   Re: cvs commit: src/sys/sys lock.h src/sys/i386/include param.h smp.h  src/sys/i386/isa apic_ipl.s apic_vector.s ipl.s src/sys/i386/i386 exception.s  mp_machdep.c mpapic.c
Message-ID:  <199707241625.KAA21434@Ilsa.StevesCafe.com>
In-Reply-To: Your message of "Thu, 24 Jul 1997 19:17:00 %2B1000." <199707240917.TAA14432@godzilla.zeta.org.au> 

next in thread | previous in thread | raw e-mail | index | archive | help
Hi,

> >  Modified files:
> >    sys/sys              lock.h 
> >  Log:
> >  Forced 32bit alignment of struct simple_lock.
> >  
> >  Revision  Changes    Path
> >  1.5       +3 -2      src/sys/sys/lock.h
> 
> Erm, this is bogus.  sys/lock.h is supposed to be machine-independent.  It
> should have no knowledge of machine-dependent alignment requirements.
> Alignment is guaranteed if alignment of the machine-dependent struct is
> guaranteed.

this I buy, I'll fix it...

---
> >  Modified files:
> >    sys/i386/include     param.h smp.h 
> >  Log:
> >  Forced 32bit alignment of struct simple_lock in param.h.
> 
> Alignment of the machine-dependent struct was already guaranteed, since
> the struct contains an int, and 32-bit alignment of ints is guaranteed
> in practice (although the CPU does not require it) since misalignment
> would be inefficient.

this I disagree with.  I think of it as a comment, forcing the observer
to actually think about how the variable is to be used.

--
Steve Passe	| powered by
smp@csn.net	|            Symmetric MultiProcessor FreeBSD





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199707241625.KAA21434>