Return to BSD News archive
Xref: sserve comp.os.386bsd.misc:1169 comp.os.linux:55892
Newsgroups: comp.os.386bsd.misc,comp.os.linux
Path: sserve!newshost.anu.edu.au!munnari.oz.au!bruce.cs.monash.edu.au!monu6!jacobi.maths.monash.edu.au!billm
From: billm@jacobi.maths.monash.edu.au (WE Metzenthen)
Subject: Re: FYI.. benchmarks on linux and 386bsd
Message-ID: <1993Oct8.003931.3166@monu6.cc.monash.edu.au>
Sender: news@monu6.cc.monash.edu.au (Usenet system)
Organization: Monash University
X-Newsreader: TIN [version 1.1 PL6]
References: <2915to$crd@GRAPEVINE.LCS.MIT.EDU>
Date: Fri, 8 Oct 1993 00:39:31 GMT
Lines: 34
Chris Metcalf (metcalf@CATFISH.LCS.MIT.EDU) wrote:
: In article <CGD.93Oct6131315@eden.cs.berkeley.edu>, Chris Demetriou wrote:
: >but for {386,Free,Net}BSD, you're definitely wrong, hz is 100,
:
: Unfortunately, dhry typically doesn't find the system-specific value of
: HZ, and it will default to 60 in this case. This would have happened under
: Linux (which defines only CLK_TCK, not HZ, in its include files); perhaps
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
: *BSD defines HZ, or perhaps dhry had been built with -DHZ=100 under *BSD.
: This is still the only way to explain the original discrepancy in timings.
:
: A quick check of MIPS Ultrix 4.3, SunOS 4.1.3, NextStep 2.1 and Vax BSD 4.3
: reveals that all of them use HZ=60 when returning a value via times(),
: by the way; my guess at HZ in BSD was based on Vax BSD.
: --
: Chris Metcalf, MIT Laboratory for Computer Science
: metcalf@cag.lcs.mit.edu // +1 (617) 253-7766
It does, at least on my system, via <sys/param.h>:
#include <sys/param.h>
main() { printf("HZ is %d\n", HZ); }
just gave
HZ is 100
on my machine.
--
Bill Metzenthen
Mathematics Department
Monash University
Clayton, Victoria, Australia
email: billm@vaxc.cc.monash.edu.au
billm@euler.maths.monash.edu.au