cvs commit: src/sys/sys sched.h src/sys/posix4
ksched.c src/sys/kern sched_4bsd.c sched_core.c sched_ule.c
Xin LI
delphij at delphij.net
Thu Jun 15 09:49:05 UTC 2006
在 2006-06-15四的 10:29 +0100,Robert Watson写道:
> On Thu, 15 Jun 2006, Xin LI wrote:
> [...]> A question that might be related: We have sched_sizeof_proc(), etc. in
> > every scheduler, which returns a constant. Is it worthy to convert them to
> > constants that just expand inline during the kernel compile?
>
> It should make no difference -- sched_sizeof_proc() is evaluated exactly once,
> when the process zone is created. After that, the size is cached in the
> process zone and never re-evaluated. The current model allows the size to be
> calculated based on data structures private to sched_foo.c, which has some
> nice implementation hiding advantages :-).
Oh... Yes that's quite reasonable. Thanks for the explanation!
Cheers,
--
Xin LI <delphij delphij net> http://www.delphij.net/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: =?UTF-8?Q?=E8=BF=99=E6=98=AF=E4=BF=A1=E4=BB=B6=E7=9A=84=E6=95=B0?=
=?UTF-8?Q?=E5=AD=97=E7=AD=BE=E5=90=8D=E9=83=A8=E5=88=86?=
Url : http://lists.freebsd.org/pipermail/cvs-src/attachments/20060615/6f7505bc/attachment.pgp
More information about the cvs-src
mailing list