From owner-cvs-src@FreeBSD.ORG Mon Jan 28 16:23:55 2008 Return-Path: Delivered-To: cvs-src@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 16CF916A417; Mon, 28 Jan 2008 16:23:55 +0000 (UTC) (envelope-from yar@comp.chem.msu.su) Received: from comp.chem.msu.su (comp.chem.msu.su [158.250.32.97]) by mx1.freebsd.org (Postfix) with ESMTP id 6FF4313C4D3; Mon, 28 Jan 2008 16:23:54 +0000 (UTC) (envelope-from yar@comp.chem.msu.su) Received: from comp.chem.msu.su (localhost [127.0.0.1]) by comp.chem.msu.su (8.13.4/8.13.4) with ESMTP id m0SGNpe4007250; Mon, 28 Jan 2008 19:23:51 +0300 (MSK) (envelope-from yar@comp.chem.msu.su) Received: (from yar@localhost) by comp.chem.msu.su (8.13.4/8.13.4/Submit) id m0SGNoPc007249; Mon, 28 Jan 2008 19:23:50 +0300 (MSK) (envelope-from yar) Date: Mon, 28 Jan 2008 19:23:50 +0300 From: Yar Tikhiy To: Dag-Erling Sm?rgrav , cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org, "David O'Brien" Message-ID: <20080128162350.GQ49535@comp.chem.msu.su> References: <200801261709.m0QH9f2D024309@repoman.freebsd.org> <20080127043334.GA75235@dragon.NUXI.org> <20080127053813.GH49535@comp.chem.msu.su> <20080127094653.GA74753@dragon.NUXI.org> <20080128053514.GK49535@comp.chem.msu.su> <86odb6usm6.fsf@ds4.des.no> <20080128111434.GA68277@owl.midgard.homeip.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080128111434.GA68277@owl.midgard.homeip.net> User-Agent: Mutt/1.5.9i Cc: Subject: Re: cvs commit: src UPDATING src/include fts.h src/lib/libc/gen Makefile.inc Symbol.map fts-compat.c fts-compat.h fts.3 fts.c src/sys/sys param.h X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 Jan 2008 16:23:55 -0000 On Mon, Jan 28, 2008 at 12:14:35PM +0100, Erik Trulsson wrote: > On Mon, Jan 28, 2008 at 11:55:29AM +0100, Dag-Erling Sm?rgrav wrote: > > > > > Userland code should be portable and useful to other systems in the > > > chosen domain of compatibility, e.g., C99 or POSIX, unless there > > > are substantial reasons for it not to. That's how different projects > > > can benefit from each other's work. > > > > Both C99 and POSIX *require* int64_t and uint64_t on all platforms that > > have 64-bit integer types. > > > > FreeBSD has never run on any platform that doesn't. I don't think > > NetBSD or OpenBSD has either, nor Solaris, nor Linux to my knowledge. > > Those are all good reasons for why using 'int64_t' would be OK. > None of it is a reason for why using 'long long' would not be OK when you > want at least 64 bits, but do not require exactly 64 bits. Thank you for telling this very valid point. People tend to forget that [u]intN_t types are actually called for only when a particular _exact_ bit width is needed, e.g., to get unsigned arithmetics modulo 2^N, or to match a hardware register or a network packet field. -- Yar