Post
Unpacked memory profiler and found a ~50% memory reduction. github.com/ruby/rdoc/pu...
github.comReduce memory allocations for RI and POT generators by skatkov · Pull Request #1788 · ruby/rdocEach documented method currently retains an array of RDoc::Parser::RubyColorizer::ColoredToken objects and their fragmented source strings.
This data is unnecessary for:
RI, whose serialized metho...
POT (translation file) generator is now 11x faster with these. github.com/ruby/rdoc/pu...
github.comPOT serialization optimization (with 87% improvement) by skatkov · Pull Request #1789 · ruby/rdocString#+ creates a new string and copies everything accumulated so far. Repeating that for tens of thousands of entries is quadratic.
I replaced the repeated concatenation with one join.
Benchmark ...
0 reposts2 likes
No replies yet.