diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-10-11 11:45:38 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-10-11 11:45:38 +0000 |
commit | f44b0e5b4fbeb58fa1b5cff2be44c359f9438cf7 (patch) | |
tree | c40e617a9dcc062f5ffdfde5ecc8ea53addc409f /gc.c | |
parent | 73e014407f6a464284ac76c44a6985ea64a089e1 (diff) |
* gc.c, parse.y: support generational Symbol relatetd marking.
Each symbols has String objects respectively to represent
Symbols.
These objects are marked only when:
* full marking
* new symbols are added
This hack reduce symbols (related strings) marking time.
For example, on my Linux environment, the following code
"20_000_000.times{''}"
with 40k symbols (similar symbol number on Rails 3.2.14 app,
@jugyo tells me) boosts, from 7.3sec to 4.2sec.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'gc.c')
-rw-r--r-- | gc.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -3580,7 +3580,7 @@ gc_marks_body(rb_objspace_t *objspace, int minor_gc) mark_current_machine_context(objspace, th); MARK_CHECKPOINT; - rb_gc_mark_symbols(); + rb_gc_mark_symbols(minor_gc == 0); MARK_CHECKPOINT; rb_gc_mark_encodings(); |