I suspect that some shared pages are invalidated because some static string don't have their coderange set eagerly.
So the first time they are scanned, the entire memory page is invalidated.
Being able to see the coderange in ObjectSpace would help debug this.
And in addition dump currently call is_broken_string() and is_ascii_string() which both end up scanning the string and assigning coderange. I think it's undesirable as dump should be read only.
ObjectSpace.dump: Include string coderange
I suspect that some shared pages are invalidated because
some static string don't have their coderange set eagerly.
So the first time they are scanned, the entire memory page is
invalidated.
Being able to see the coderange in
ObjectSpacewould help debugthis.
And in addition
dumpcurrently callis_broken_string()andis_ascii_string()which both end up scanning the string and assigning coderange. I think it's
undesirable as
dumpshould be read only.