Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 26 Jan 1997 17:50:53 +0100
From:      Poul-Henning Kamp <phk@critter.dk.tfs.com>
To:        Bruce Evans <bde@zeta.org.au>
Cc:        dg@root.com, swallace@ece.uci.edu, current@FreeBSD.ORG
Subject:   Re: exec bug 
Message-ID:  <7597.854297453@critter.dk.tfs.com>
In-Reply-To: Your message of "Mon, 27 Jan 1997 00:50:34 %2B1100." <199701261350.AAA31786@godzilla.zeta.org.au> 

next in thread | previous in thread | raw e-mail | index | archive | help
In message <199701261350.AAA31786@godzilla.zeta.org.au>, Bruce Evans writes:

>What is the library malloc()+free() doing to be 5 times slower than
>read+lseek()?  The kernel malloc() is fast enough to use :-).  It takes
>a couple of usec for small allocations.

You're timing the initialization and allocation of the "page table".
Try adding
	 free(malloc(1));
before you take the first timestamp.

--
Poul-Henning Kamp           | phk@FreeBSD.ORG       FreeBSD Core-team.
http://www.freebsd.org/~phk | phk@login.dknet.dk    Private mailbox.
whois: [PHK]                | phk@tfs.com           TRW Financial Systems, Inc.
Power and ignorance is a disgusting cocktail.



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