From owner-freebsd-performance@FreeBSD.ORG Tue Jan 1 22:44:51 2008 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C59E316A418 for ; Tue, 1 Jan 2008 22:44:51 +0000 (UTC) (envelope-from gofp-freebsd-performance@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 4666513C455 for ; Tue, 1 Jan 2008 22:44:51 +0000 (UTC) (envelope-from gofp-freebsd-performance@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1J9pqp-0002cv-4e for freebsd-performance@freebsd.org; Tue, 01 Jan 2008 22:44:47 +0000 Received: from 78-1-101-174.adsl.net.t-com.hr ([78.1.101.174]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 01 Jan 2008 22:44:47 +0000 Received: from ivoras by 78-1-101-174.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 01 Jan 2008 22:44:47 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-performance@freebsd.org From: Ivan Voras Date: Tue, 01 Jan 2008 23:44:18 +0100 Lines: 69 Message-ID: References: <20071230134354.GA63555@harmless.hu> <4777A65C.8020406@FreeBSD.org> <20071230141118.GA67574@harmless.hu> <4777AB9C.1010003@FreeBSD.org> <4779BBE8.2050608@FreeBSD.org> <20080101122249.GA81405@harmless.hu> <477A32EA.4070500@FreeBSD.org> <477A4BF1.3050709@FreeBSD.org> <20080101142116.GA94325@harmless.hu> <477A4E28.3010003@FreeBSD.org> <477AAC90.4050305@FreeBSD.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig6CEE54D3F0BA2EC9C26BE77C" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 78-1-101-174.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) In-Reply-To: <477AAC90.4050305@FreeBSD.org> X-Enigmail-Version: 0.95.5 Sender: news Subject: Re: mysql scaling questions X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Jan 2008 22:44:51 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig6CEE54D3F0BA2EC9C26BE77C Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Kris Kennaway wrote: > So it is using getpid? It should be fine on FreeBSD with the previous > provisos, but you also need to check Linux behaviour and compare on > identical hardware before you can draw conclusions. Here's the source of unixbench syscall benchmark: unsigned long iter; void report() { fprintf(stderr,"%ld loops\n", iter); exit(0); } int main(argc, argv) int argc; char *argv[]; { int duration; if (argc !=3D 2) { printf("Usage: %s duration\n", argv[0]); exit(1); } duration =3D atoi(argv[1]); iter =3D 0; wake_me(duration, report); while (1) { close(dup(0)); getpid(); getuid(); umask(022); iter++; } /* NOTREACHED */ } As I count it, getpid() is one of 5 syscalls made. Of these, getpid() and getuid() might be cached on Linux in some way, which actually could, with the difference in CPU speed, cause the difference. I can't check it on identical hardware. --------------enig6CEE54D3F0BA2EC9C26BE77C Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHesJIldnAQVacBcgRAh0NAKCh8a3gVrMwd/bPFJ6GSl7Vu4G8TQCfa3pg yDywMHr2UNqIGWAWdNKVo58= =Evqg -----END PGP SIGNATURE----- --------------enig6CEE54D3F0BA2EC9C26BE77C--