The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
From: Attila Rajmund Nohl <attila.r.n...@gmail.com>
Date: Wed, 25 Jul 2012 15:44:35 +0200
Local: Wed, Jul 25 2012 9:44 am
Subject: Re: [erlang-questions] Memory-effective queue handling
2012/7/25 Richard Carlsson <carlsson.rich...@gmail.com>:
[...] > You'd only run out of space if the queue is so long that you don't have
It might happen. According to the crash dump the process in question uses
> memory enough to call lists:reverse() on the current in-half of the queue > (and after that, the old queue will immediately become garbage). Can that > really be the case? Stack+heap: 228065700 words of memory. I store a tuple of bigint and a small integer in the
> But you should be able to improve the behaviour of the above code by using
Thanks.
> queue:peek_r(Q) instead of queue:out(Q), and then call queue:drop_r(Q) in > the second case clause only, so no rewriting of the queue representation is > done unless necessary. _______________________________________________ erlang-questions mailing list erlang-questi...@erlang.org http://erlang.org/mailman/listinfo/erlang-questions You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||