belated feedback Alex Shinn (16 Apr 2021 15:00 UTC)
Re: belated feedback Bradley Lucier (16 Apr 2021 17:08 UTC)
Re: belated feedback John Cowan (16 Apr 2021 18:25 UTC)
Re: belated feedback Bradley Lucier (17 Apr 2021 21:48 UTC)
Re: belated feedback Alex Shinn (18 Apr 2021 23:45 UTC)
Re: belated feedback Bradley Lucier (16 Apr 2021 23:46 UTC)
Re: belated feedback Alex Shinn (17 Apr 2021 00:03 UTC)
Re: belated feedback Bradley Lucier (17 Apr 2021 01:10 UTC)
Re: belated feedback Alex Shinn (17 Apr 2021 01:22 UTC)
Re: belated feedback Alex Shinn (30 Apr 2021 05:41 UTC)
Re: belated feedback Bradley Lucier (30 Apr 2021 14:17 UTC)
Re: belated feedback John Cowan (30 Apr 2021 15:04 UTC)
Re: belated feedback Bradley Lucier (30 Apr 2021 16:42 UTC)
Re: belated feedback Alex Shinn (01 May 2021 09:27 UTC)
array-elements-in-order? (Was: belated feedback) Bradley Lucier (16 Jan 2022 19:08 UTC)

Re: belated feedback Bradley Lucier 30 Apr 2021 14:16 UTC


On 4/30/21 1:40 AM, Alex Shinn wrote:
> On Sat, Apr 17, 2021 at 10:22 AM Alex Shinn <xxxxxx@gmail.com> wrote:
 >
> FYI I've implemented the indexer optimization/flattening in Chibi head.
> I use the same approach for reshaping and just verify agreement on
> offsets when taking one step in every dimension from the old and new
> domains.  I'm pretty sure this works (it passes all the tests) but haven't
> proved it.

Interesting.

> Note the resulting indexers are more optimized than in the SRFI 179
> reference implementation.  Your indexers are subtracting out the lower
> bounds from the indexes on each call (optimizing out the first few 0 lower
> bound cases), but you can just subtract that out from the base offset in
> advance, whether or not the value is 0.

When I wrote that I wanted to avoid bignum intermediate computations
when all the lower and upper bounds and the final index are fixnums.
Around the same time Marc Feeley had refactored the Gambit runtime to
allow building Gambit with only fixnums and flonums in the numeric
"tower", so perhaps that influenced my thinking.

Brad