Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 Oct 2002 00:30:57 -0400 (EDT)
From:      Daniel Eischen <eischen@pcnet1.pcnet.com>
To:        Tim Robbins <tjr@FreeBSD.ORG>
Cc:        freebsd-arch@FreeBSD.ORG
Subject:   Re: Macros in <stdio.h>
Message-ID:  <Pine.GSO.4.10.10210140023020.14594-100000@pcnet1.pcnet.com>
In-Reply-To: <20021014094459.A25812@dilbert.robbins.dropbear.id.au>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, 14 Oct 2002, Tim Robbins wrote:

> Since revision 1.25 of src/include/stdio.h removed the macro versions of
> putc() and getc(), is there any reason why we shouldn't go the whole way
> and remove the rest of the macros (*_unlocked()) ?

These functions are defined by POSIX as thread-safe functions.
The are allowed to be implemented as macros, but not required
to be.  You need to add them as functions before you can remove
them as macros.

I am not sure whether the performance gain warrants keeping
them as macros or not.

> This would let us make FILE opaque and move the definition of
> struct __sFILE into src/lib/libc/stdio/local.h. This would also let us
> remove the __sFILEX hack.

-- 
Dan Eischen


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




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