From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,56525db28240414a X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.224.174.74 with SMTP id s10mr10710667qaz.1.1343098470857; Mon, 23 Jul 2012 19:54:30 -0700 (PDT) Received: by 10.66.84.41 with SMTP id v9mr127222pay.43.1343098470449; Mon, 23 Jul 2012 19:54:30 -0700 (PDT) Path: a15ni76572691qag.0!nntp.google.com!x2no4442932qaj.0!news-out.google.com!b9ni36561452pbl.0!nntp.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!news-in-01.newsfeed.easynews.com!easynews.com!easynews!novia!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nrc-news.nrc.ca!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail From: Keean Schupke Newsgroups: comp.lang.ada Subject: Re: Efficient Sequential Access to Arrays Date: Thu, 19 Jul 2012 12:58:33 -0700 (PDT) Organization: http://groups.google.com Message-ID: <3dbfa883-54c8-4269-a567-26dde8ead4cd@googlegroups.com> References: <9d4d4463-4c7e-40f4-a167-933eb056c6a5@googlegroups.com> <5007ecf3$0$9507$9b4e6d93@newsspool1.arcor-online.net> NNTP-Posting-Host: 82.44.19.199 Mime-Version: 1.0 X-Trace: posting.google.com 1342727914 29829 127.0.0.1 (19 Jul 2012 19:58:34 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Thu, 19 Jul 2012 19:58:34 +0000 (UTC) In-Reply-To: <5007ecf3$0$9507$9b4e6d93@newsspool1.arcor-online.net> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=82.44.19.199; posting-account=T5Z2vAoAAAB8ExE3yV3f56dVATtEMNcM User-Agent: G2/1.0 X-Received-Bytes: 2492 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Date: 2012-07-19T12:58:33-07:00 List-Id: On Thursday, 19 July 2012 12:18:11 UTC+1, Georg Bauhaus wrote: > On 19.07.12 12:41, Keean Schupke wrote: > > What is more of a problem is that the node structure is 32 bytes lon= g, so two nodes fit in a 64bit cache line, and the index operation is shift= left by 5. Adding the extra Index word will probably slow things down sign= ificantly, unless we can save some space elsewhere in the structure. > >=20 > > I may be able to replace one Integer with a Short_Int, and use a Sho= rt_Int for the index. I think this could be worth trying. >=20 > I'll assume it is a 32 bit program already? (As GNAT uses 32 bis > for addresses then, not 64.) Its a 64bit platform, so the pointers are 64bits but the integers 32bit. I = think what I was thinking is with the indexed version, I may be able to shr= ink the whole data structure from 32bytes to 16bytes, and that would fit 4 = elements in a cache line instead of two. Maybe this would make up for the s= lower indexed addressing. It will try and post my results. Cheers, Keean.