Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-123584

Updating blocks creates lag spikes proportional to geometry in chunk section

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Resolution: Unresolved
    • Affects Version/s: Minecraft 17w50a, Minecraft 18w01a, Minecraft 18w07c, Minecraft 18w09a, Minecraft 18w11a, Minecraft 18w19b, Minecraft 1.13-pre1, Minecraft 1.13-pre5, Minecraft 1.13-pre6, Minecraft 1.13-pre7, Minecraft 1.13-pre8, Minecraft 1.13-pre9, Minecraft 1.13-pre10, Minecraft 1.13, Minecraft 18w30b
    • Fix Version/s: None
    • Labels:
    • Confirmation Status:
      Confirmed

      Description

      The bug

      Any block change seems to trigger a redraw of the entire chunk section. This is most noticeable when breaking and replacing blocks, but is also caused by wheat growing, for example. Lag is increased depending on the geometry inside the chunk section – complex models like fences cause greater lag.

      This is client-side rendering issue since when filling large areas the command success message appears almost instantaneously in the log but the game freezes for some seconds.

      When the debug rendering pie chart is visible the following warnings are logged:

      [21:20:51] [Client thread/WARN]: Something's taking too long! 'root.gameRenderer.level.terrain_setup.rebuildNear.build near' took aprox 223.112349 ms
      [21:20:53] [Client thread/WARN]: Something's taking too long! 'root.gameRenderer.level.terrain_setup.rebuildNear.build near' took aprox 1796.166532 ms
      [21:20:53] [Client thread/WARN]: Something's taking too long! 'root.gameRenderer.level.terrain_setup.rebuildNear' took aprox 2046.063861 ms
      [21:20:53] [Client thread/WARN]: Something's taking too long! 'root.gameRenderer.level.terrain_setup' took aprox 2046.184909 ms
      [21:20:53] [Client thread/WARN]: Something's taking too long! 'root.gameRenderer.level' took aprox 2049.560368 ms
      [21:20:53] [Client thread/WARN]: Something's taking too long! 'root.gameRenderer' took aprox 2051.362563 ms
      [21:20:53] [Client thread/WARN]: Something's taking too long! 'root' took aprox 2054.692309 m
      

      How to reproduce

      1. Use the following command
        /fill ~1 ~1 ~1 ~5 ~5 ~5 oak_fence
        
      2. Place or break a block next to the filled fences

        Attachments

        1. lag spikes .png
          lag spikes .png
          1.60 MB
        2. MC-lag_spike_.mp4
          673 kB
        3. rebuildNear lag example world.zip
          393 kB
        4. Screenshot (930).png
          Screenshot (930).png
          130 kB
        5. Screenshot (931).png
          Screenshot (931).png
          207 kB
        6. Screenshot (932).png
          Screenshot (932).png
          24 kB

          Issue Links

            Activity

              People

              • Assignee:
                rherlitz [Mojang] Rikard Herlitz
                Reporter:
                marcono1234 [Mod] Marcono1234
              • Votes:
                271 Vote for this issue
                Watchers:
                95 Start watching this issue

                Dates

                • Created:
                  Updated:
                  CHK: