[Haskell-cafe] fast Array operations: foldl, drop

Henning Thielemann lemming at henning-thielemann.de
Thu Nov 29 04:46:16 EST 2007


I thought operations like "foldl'" and "drop" must be very fast on arrays
(especially UArray) with appropriate pointer tricks, I mean pointer
incrementing instead of indexing for "foldl'" and a pointer into the array
for "drop". Is it planned to add such functions? Ok, if "foldl f x .
elems" and "listArray (i,sufficientlyBig) . drop n . elems" are fused to
high speed code, then these functions do not need to materialize in the
API.


More information about the Haskell-Cafe mailing list