From owner-cvs-all@FreeBSD.ORG Tue Mar 16 17:43:08 2004 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D035716A4CE; Tue, 16 Mar 2004 17:43:08 -0800 (PST) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id CAD0C43D45; Tue, 16 Mar 2004 17:43:08 -0800 (PST) (envelope-from tjr@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.10/8.12.10) with ESMTP id i2H1h8Ge015878; Tue, 16 Mar 2004 17:43:08 -0800 (PST) (envelope-from tjr@repoman.freebsd.org) Received: (from tjr@localhost) by repoman.freebsd.org (8.12.10/8.12.10/Submit) id i2H1h837015877; Tue, 16 Mar 2004 17:43:08 -0800 (PST) (envelope-from tjr) Message-Id: <200403170143.i2H1h837015877@repoman.freebsd.org> From: "Tim J. Robbins" Date: Tue, 16 Mar 2004 17:43:08 -0800 (PST) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/include stdio.h src/lib/libc/stdio feof.c ferror.c fileno.c getc.c putc.c putchar.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Mar 2004 01:43:09 -0000 tjr 2004/03/16 17:43:08 PST FreeBSD src repository Modified files: include stdio.h lib/libc/stdio feof.c ferror.c fileno.c getc.c putc.c putchar.c Log: Re-add macro versions of getc(), getchar(), putc(), putchar(), feof(), ferror(), fileno() and clearerr(), using the value of __isthreaded to decide between the fast inline single-threaded code and the more general function equivalent. This gives most of the performance benefits of the old unsafe macros while preserving thread safety. Revision Changes Path 1.53 +16 -0 src/include/stdio.h 1.9 +2 -6 src/lib/libc/stdio/feof.c 1.9 +2 -6 src/lib/libc/stdio/ferror.c 1.10 +2 -6 src/lib/libc/stdio/fileno.c 1.12 +2 -0 src/lib/libc/stdio/getc.c 1.12 +2 -8 src/lib/libc/stdio/putc.c 1.12 +2 -8 src/lib/libc/stdio/putchar.c