Redstone conduit causes excessive rendering when attached to block adjacent to liquid
dbjorge opened this issue ยท 2 comments
Issue Description:
A redstone conduit attached to a block that is adjacent to any liquid causes excessive render processing every time the liquid block considers flowing.
What happens:
As soon as you lay down this configuration of blocks, you can observe that the amount of time the F3 profiler shows being spent in root.gameRenderer.level.terrain_setup.rebuildNear.build near.unspecified
approximately doubles.
The performance impact is easily observable in the profiler with just Ender IO installed. However, the impact is more significant in larger modpacks; in the motivating case (a custom modpack with 71 mods), this causes noticeable rendering jitter at a rate that appears to coincide with the rate that the liquid in question would flow at (ie, the spikes are further apart if lava is used than water).
The issue:
- Does not repro with other types of EnderIO conduits
- Does not repro with vanilla comparators, observers, or redstone trails
- Repros with a variety of different liquids and conduit-attached-blocks (but the rate of the performance spikes varies with the flow rate of the liquid)
- Repros regardless of whether the adjacent liquid is a source block or not
- Repros regardless of whether the conduit is set to input/output/both (but not if the conduit is adjacent-to-but-not-connected-to the block in question)
What you expected to happen:
This configuration shouldn't have noticeably worse performance than the same configuration without the liquid block.
Steps to reproduce:
- Create a new empty world using the versions specified below
- Dig a hole 1 block deep and fill it with water
- Open the debug menu with Shift+F3 and navigate the pie profiler to
root.gameRenderer.level
- Attach a redstone conduit to any block adjacent to the water
- Observe the increase in
terrain_setup
usage
Affected Versions (Do not use "latest"):
- EnderIO: 5.0.51
- EnderCore: 1.12.2-0.5.69
- Minecraft: 1.12.2
- Forge: 14.23.5.2846
- SpongeForge? no
- Optifine? no
- Single Player and/or Server? repros on both
Your most recent log file where the issue was present:
https://gist.github.com/dbjorge/c71b59b7d9e4db4fc7d0df1ce4ebf860