From owner-freebsd-standards Fri Apr 5 1: 1:31 2002 Delivered-To: freebsd-standards@freebsd.org Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by hub.freebsd.org (Postfix) with ESMTP id 8B56A37B416 for ; Fri, 5 Apr 2002 01:01:28 -0800 (PST) Received: from bde.zeta.org.au (bde.zeta.org.au [203.2.228.102]) by mailman.zeta.org.au (8.9.3/8.8.7) with ESMTP id TAA20291; Fri, 5 Apr 2002 19:01:19 +1000 Date: Fri, 5 Apr 2002 18:49:19 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Dima Dorfman Cc: standards@FreeBSD.ORG Subject: Re: %j length modifier in kernel printf In-Reply-To: <20020405080000.754FB3E31@bazooka.trit.org> Message-ID: <20020405184249.S3947-100000@gamplex.bde.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-standards@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 5 Apr 2002, Dima Dorfman wrote: > I've implemented the %j and %z (named %Z (for now?), since %z is > signed hex) length modifiers in the kernel printf(). The patch below > has been tested on i386, and appears to work okay. My primary concern > with it is breaking sign extension stuff; I've run tests to check that > I didn't break it completely, but it's very possible that I still > missed some corner cases. I don't like the restructuring of the code (lm functions). I think the kernel kvprintf should be much like the userland __vfprintf except for not having support for floating point (yet?) or the positional parameters bloat (ever). Are the significant complications for the extra formats in the kernel printf? > Also note that printf now uses intmax_t arithmetic even for shorter > types. This has some performance implications, but I don't think > kernel printf is used anywhere where such micropessimizations would be > noticeable. I agree, but this takes us further from the userland printf. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-standards" in the body of the message