On 31/01/2011, at 7:29 AM, john skaller wrote: > > Not so good: > > var ls = list (1,2); > var i:int; forall i in 0 upto 21 do > ls = rev (fold_left (fun (acc:list[int]) (x:int) => Cons(x,acc)) (rev ls) > ls); > println$ str i + " " + str (len ls); > done
What is very nice though: with one change, making "rev" inline again... Felix converted this program into a *single* top level C function. Fully inlined and tail optimised. Going up to level 23 with default GC settings: Ocaml 1.5 minutes, Felix 8 minutes. In this case the GC is called, and too often. -- john skaller skal...@users.sourceforge.net ------------------------------------------------------------------------------ Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)! Finally, a world-class log management solution at an even better price-free! Download using promo code Free_Logger_4_Dev2Dev. Offer expires February 28th, so secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsight-sfd2d _______________________________________________ Felix-language mailing list Felix-language@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/felix-language