Thanks puzzler for the explanation.
I tried out your `unchunk` and its works nicely..

I then googled around about chunk and memory issues..

I found most issues about chunking and stack overflow.. 
here.. https://stuartsierra.com/2015/04/26/clojure-donts-concat       
[which is very good read for this question as well.. the diagram of 
lazy-seq's is great.]
with 
https://groups.google.com/forum/#!topic/clojure-dev/ewBuyloeiFs/discussion 
[Left recursion with concat as said in above article as well would stack 
overflow].

However, none talked about memory consumption.. Do anyone know about good 
practices with `chunking` and `memory consumption` ?
*Can i say that : as long tail of recursive calls are happening due to 
chunking.. all the memory of intermediate steps is present at the same 
time.. leading to heavy memory usage.. ?*  or is it something more subtle..

Some graphs that i found while profiling :

<https://lh3.googleusercontent.com/-E2PFxgZcXTc/Vw6GI9F_jtI/AAAAAAAAAKU/z8iwE3LYct8EGqSXuETR-yrHUCvDIolywCLcB/s1600/long-recursive-concat-map-calls.png>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to