GC: optimize sweeping and allocation#2520
Conversation
…on of recoverable page
|
Thanks for your pull request, @rainers! Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub fetch digger
dub run digger -- build "master + druntime#2520" |
|
Ouch, sweep and recover cannot be combined if dtors of dead objeccts still access other dead objects. Closing for now... |
The dtors are not supposed to access GC allocated objects though, as the order in which they run is not guaranteed. So isn't that exhibiting an issue in current current ? |
It seems to happen in std.regex for reference counting. We could enforce it (by allowing crashes) but it also pretty much restricts even more what can sensibly be done in a dtor. Right now, other dead objects without a dtor are still in a valid state. |
|
Added WIP: need to cleanup the history now that part of the changes have been reverted... |
Shouldn't that be done with |
Sorry, can't tell. The regex code is indistinguishable from magic. I just noted that a pointer in a dead object was modified by 1. |
|
Shall we summon our wizard in chief, @DmitryOlshansky ? |
|
I'll split this into a couple of smaller PRs. |
The druntime-benchmarks mostly don't show a huge difference for these changes, but rand_small changes from
on win64 to
Results are more impressive for the extended vdparser test also shown here:
is changed to