[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freebsd-hackers
Subject:    Re: scanf in the kernel?
From:       Mike Smith <mike () smith ! net ! au>
Date:       1998-10-31 20:04:07
[Download RAW message or body]

> On Fri, Oct 30, 1998 at 10:25:39AM -0500, Bill Fumerola wrote:
> > I'm not a kernel-hacking kind of guy, but I know just from personal C
> > experiences that scanf makes things a lot easier to change later on and
> > easier to get a visual representation of. scanf and sprintf have become my
> > friend.
> > 

> I am not one either but I thought the *printf commands are very
> expensive (to the processer) and something as low level as the kernel
> would one try to avoid these???

One would generally try to avoid having them anywhere in a critical 
path, certainly, but they're not actually that expensive, and there's 
always a tradeoff between speed and maintainability.

-- 
\\  Sometimes you're ahead,       \\  Mike Smith
\\  sometimes you're behind.      \\  mike@smith.net.au
\\  The race is long, and in the  \\  msmith@freebsd.org
\\  end it's only with yourself.  \\  msmith@cdrom.com



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic