[#74190] [Ruby trunk Feature#12134] Comparison between `true` and `false` — duerst@...
Issue #12134 has been updated by Martin D端rst.
3 messages
2016/03/07
[#74269] Type systems for Ruby — Rob Blanco <ml@...>
Dear ruby-core,
5 messages
2016/03/10
[#74395] [Ruby trunk Feature#12142] Hash tables with open addressing — shyouhei@...
Issue #12142 has been updated by Shyouhei Urabe.
3 messages
2016/03/17
[ruby-core:74184] Re: [Ruby trunk Feature#12142] Hash tables with open addressing
From:
SASADA Koichi <ko1@...>
Date:
2016-03-06 18:59:52 UTC
List:
ruby-core #74184
On 2016/03/07 3:37, vmakarov@redhat.com wrote:
> I don't think it is a leak. What you measure is the maximal residential size. I think the table is rebuilt many times and memory for previous version of tables is freed but it is not freed to OS by MRI (or glibc. I don't know yet what allocation library is used by MRI). Still this is *very* bad. I should definitely to investigate and fix it. I believe I know how to fix it. I should reuse the array elements when it is possible. Thanks for pointing this out.
trunk (without your patch):
$ for i in 1 10 100 1000 10000 100000 1000000 10000000
> do /usr/bin/time -f%Mkb ./miniruby -e "h=Hash.new; $i.times{|i|h[i] =
i; h.delete(i-1)}"
> done
3504kb
3504kb
3512kb
3508kb
3504kb
3516kb
3516kb
3516kb
This is what I asked in my comment.
> * (rare case) so many deletion can keep spaces (does it collected? i need to read code more)
>
...
>
> We can generalize the last issue as "compaction".
> This is what I didn't touch this issue yet (maybe not a big problem).
And you didn't response about that :)
--
// SASADA Koichi at atdot dot net
Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>