On Wed, Jul 31, 2013 at 05:01:35PM +0300, Javor Kliachev wrote: > Hello, > > In the documentation it is stated, that pair sets defined like this > [(1..100,123)] are in fact translated to > [(1,123),(2,123),(3,123),...,(100,123)] and hence there is an > considerably increased memory footprint. > > Is this also true if the right member of the pair is defined as a range > or as *: > > [(123,*)] =?= [(123,0),(123,1),(123,2),...,(123,65535)] > > Should I consider an eventual intensive memory usage in both cases?
No. Pair sets like [(123,10..100)], [(123,*)] or even [(10..100,*)] are efficient. Think about it like the value on the right side sudivides the value on the left side, therefore (123,10..100) is one interval from (123,10) to (123,100), while (10..100,123) is many small (single-pair) intervals. -- Elen sila lumenn' omentielvo Ondrej 'SanTiago' Zajicek (email: [email protected]) OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net) "To err is human -- to blame it on a computer is even more so."
signature.asc
Description: Digital signature
