Folia/patches
Spottedleaf 1128810029 Always recalculate light list on protochunk deserialize
I noticed during my stress testing that the total size of the
light list was far too large, which indicates many duplicates.
For me, this caused many GC problems which made stress testing
harder.

It turns out, it was possible for the light list recalculation
logic to occur _and_ the addition of the light list data from
the NBT data. Since there is no logic to de-duplicate this list,
every chunk load would re-add all light sources into the light
list and the light list would grow uncontrollably.

Since the recalculation logic would often run, I have
decided to solve this by discarding the data on disk and always
just calculating the list from the chunk data alone. Additionally,
I have applied an optimization from Vanilla 1.20 to avoid
searching sections without light sources by first checking the
palette for possible block sources.

Now my stress tests do not have issues with GC at all.
2023-05-15 20:37:29 -07:00
..
api Undo making JavaPlugin#logger field public (see PaperMC/Paper#9125) (#76) 2023-05-14 18:10:49 -07:00
server Always recalculate light list on protochunk deserialize 2023-05-15 20:37:29 -07:00