[erlang-questions] eep: multiple patterns

Per Melin <>
Fri May 30 17:38:34 CEST 2008


2008/5/30 Sean Hinde <>:
> As I understand it, the problem of poor performance with large message
> queues is not specifically related to selective receive, but is related to
> garbage collection of a large queue however it grows.

If I send 100k 'foo' messages and then 100k 'bar' messages to a
process, and then do a catch-all receive until there are no messages
left, that takes 0.03 seconds.

If I do a selective receive of only the 'bar' messages, it takes 90 seconds.



More information about the erlang-questions mailing list