From owner-freebsd-hackers Mon Oct 16 07:15:21 1995 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.6.12/8.6.6) id HAA08818 for hackers-outgoing; Mon, 16 Oct 1995 07:15:21 -0700 Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.2.228.19]) by freefall.freebsd.org (8.6.12/8.6.6) with ESMTP id HAA08807 for ; Mon, 16 Oct 1995 07:15:13 -0700 Received: (from bde@localhost) by godzilla.zeta.org.au (8.6.9/8.6.9) id AAA30026; Tue, 17 Oct 1995 00:08:44 +1000 Date: Tue, 17 Oct 1995 00:08:44 +1000 From: Bruce Evans Message-Id: <199510161408.AAA30026@godzilla.zeta.org.au> To: ache@astral.msk.su, phk@critter.tfs.com Subject: Re: A couple problems in FreeBSD 2.1.0-950922-SNAP Cc: bde@zeta.org.au, hackers@freefall.freebsd.org, j@uriah.heep.sax.de, kaleb@x.org Sender: owner-hackers@FreeBSD.org Precedence: bulk >running it on sbin: >100% use ctype!!! >So my suspection was right. This mainly proves that the library modules are even more excessively interdependent than at first appearance. I investigated why /sbin/dset references ctype: 1) dset references mkstemp() for some reason. mkstemp() uses only isdigit() from among the ctype functions. isdigit() isn't dependent on the locale, but it drags in locale stuff anyway. 2) dset references vfprintf() which references __dtoa(). __dtoa() doesn't reference ny ctype functions, but it is implemented in the same module as strtod() which does. strtod() references only isspace() among the ctype functions (it uses comparisons with '0' and '9' instead of isdigit()). Almost everything references printf so 2) applies to almost everything. Thus we have about 55 * 20K of bloat in [s]bin mainly for the stupid reason that a function that is almost never called (strtod()) needs to know what a space is. strtoul() etc. use isspace() too. They are used more often than strtod() and it's much more important that spaces work right than that bases > 36 work right, so ignore my previous mail saying that locales aren't important for strtoul() etc. Bruce