From f06002208d98a66532fa3f440454f2daa153e037 Mon Sep 17 00:00:00 2001 From: ko1 Date: Sun, 24 Nov 2013 19:08:33 +0000 Subject: * gc.c (gc_stat): add internal information. * heap_swept_slot * malloc_increase * malloc_limit * remembered_shady_object * remembered_shady_object_limit * old_object * old_object_limit * oldmalloc_increase * oldmalloc_limit * gc.c (gc_stat): rename names. * heap_live_num -> heap_live_slot * heap_free_num -> heap_free_slot * heap_final_slot -> heap_final_slot Quote from RDoc of GC.stat(): "The contents of the hash are implementation specific and may be changed in the future." * test/ruby/test_gc.rb: catch up this change. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43835 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_gc.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test/ruby/test_gc.rb') diff --git a/test/ruby/test_gc.rb b/test/ruby/test_gc.rb index 4ae34dc3b8..40c5b1471f 100644 --- a/test/ruby/test_gc.rb +++ b/test/ruby/test_gc.rb @@ -69,14 +69,14 @@ class TestGc < Test::Unit::TestCase GC.start GC.stat(stat) ObjectSpace.count_objects(count) - assert_equal(count[:TOTAL]-count[:FREE], stat[:heap_live_num]) - assert_equal(count[:FREE], stat[:heap_free_num]) + assert_equal(count[:TOTAL]-count[:FREE], stat[:heap_live_slot]) + assert_equal(count[:FREE], stat[:heap_free_slot]) # measure again without GC.start 1000.times{ "a" + "b" } GC.stat(stat) ObjectSpace.count_objects(count) - assert_equal(count[:FREE], stat[:heap_free_num]) + assert_equal(count[:FREE], stat[:heap_free_slot]) end def test_singleton_method -- cgit v1.2.3