From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id WAA09452; Tue, 1 Apr 2003 22:35:29 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id WAA09245 for ; Tue, 1 Apr 2003 22:35:26 +0200 (MET DST) Received: from lobus.fungible.com (adsl-64-161-114-2.dsl.snfc21.pacbell.net [64.161.114.2]) by nez-perce.inria.fr (8.11.1/8.11.1) with ESMTP id h31KZO920766 for ; Tue, 1 Apr 2003 22:35:24 +0200 (MET DST) Received: by lobus.fungible.com (Postfix, from userid 1000) id 2F2FF7F4D; Tue, 1 Apr 2003 12:35:20 -0800 (PST) Date: Tue, 1 Apr 2003 12:23:47 -0700 From-Tims-Fingers: true To: will@exomi.com Cc: brian.hurt@qlogic.com, caml-list@inria.fr In-reply-to: <6A2DCA04-6476-11D7-848D-000393863F70@exomi.com> (message from Ville-Pertti Keinonen on Tue, 1 Apr 2003 22:16:18 +0300) Subject: Re: [Caml-list] Bug? Printf, %X and negative numbers References: <6A2DCA04-6476-11D7-848D-000393863F70@exomi.com> Message-Id: <20030401203520.2F2FF7F4D@lobus.fungible.com> From: tim@fungible.com (Tim Freeman) X-Spam: no; 0.00; fungible:01 caml-list:01 bug:01 printf:01 pointers:01 tightly:01 precompute:01 ecdf:01 7180:01 arrays:01 gpg:02 worse:03 ignorance:03 allocated:03 scheme:03 Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk From: Ville-Pertti Keinonen >One way of doing this much faster is just having a the first word of >any mixed block (homogenous blocks aren't a problem) indicate the >number of pointers and always put the pointers first. > >Of course wasting an entire word on this is nasty when less bits would >do...but the bits of the current block header are pretty tightly >allocated. Most blocks are small, so one could make a scheme that fits the number of pointers into the current block header for small blocks and uses an extra word for larger blocks. This would have the desirable side effect of increasing the limit on the size of arrays. Code that accesses inside a block often knows the size of the block it's accessing, so you can often precompute whether that extra word is there and avoid taking a branch to decide whether to skip it. -- Tim Freeman tim@fungible.com Which is worse: ignorance or apathy? Who knows? Who cares? GPG public key fingerprint ECDF 46F8 3B80 BB9E 575D 7180 76DF FE00 34B1 5C78 ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners