HomeWildfire Games

Fix JS incremental GC issue (destroyed realms are not collected).

Description

Fix JS incremental GC issue (destroyed realms are not collected).

Further work would be nice to be able to only collect zones that probably have garbage to collect, but that likely requires splitting our contexts in more zones.

0 A.D. had been running in incremental GC since 1.8.5. With the SM78 upgrade, I changed this to the new default "ZONE_INCREMENTAL", which GCs specific zones.
However, I failed to realise that deleted scriptInterfaces and their corresponding zones would no longer be collected.
This corrects for that.

Fixes rP24333.

Refs #5861

Differential Revision: https://code.wildfiregames.com/D3220