[MLton] Monadic MLton.Vector.create with update
Daniel C. Wang
danwang@CS.Princeton.EDU
Thu, 30 Mar 2006 19:16:44 -0800
Well, for large arrays, I was thinking there might be some page
remapping tricks that could be used. As well as potentially a separate
allocation arena for growable buffers. Anyway, I agree this is a corner
case. It just poped into my head as I was thinking about the various
interface alternatives.
Stephen Weeks wrote:
>> Another generalization that I think would require runtime support would be
>>
>> val unfoldi_s: 'b * (int * 'b -> ('a * 'b) option) -> 'a vector
>>
>> where the length of the resulting vector is not known, but unfolding
>> terminates by returning NONE.
>> I suspect you'd want special runtime support to make this
>> efficient.
>>
>
> What kind of support are you thinking of? I don't see anything in the
> current MLton primitives that would let this be implemented more
> efficiently than a double-the-buffer approach, which one can do
> without any special support.
>
> _______________________________________________
> MLton mailing list
> MLton@mlton.org
> http://mlton.org/mailman/listinfo/mlton
>