LockSupport.parkNanos high CPU usage when driving a train
learnedtim opened this issue ยท 3 comments
Describe the Bug
When driving a train, all of my CPU cores will spike to 100%. All actions, like walking, shifting, jumping, etc. are delayed massively. I get FPS drops aswell.
After generating a report with Spark (https://spark.lucko.me/G1MqJhyk97), I saw LockSupport.parkNanos was taking up the entire server thread. Trying with less mods, just Create, Chipped, SteamNRails & FramedBlocks, the issue still occured.
Reproduction Steps
- Create a new profile with Create, FramedBlocks, SteamNRails and Chipped installed
- Create a train using those blocks, make it 3+ carriages long.
- Assemble and attempt to drive the train
...
(schematic below is the worst offender, although it happens with all trains I build)
fulltrain_1.zip
Expected Result
I can walk around normally, my CPU does not spike to 100% usage, nor does LockSupport.parkNanos take up the entire server thread.
Screenshots and Videos
Crash Report or Log
https://gist.github.com/kaibeckers/1a77bf2bb7dd18718dc5d742382bda7c
Operating System
Windows 11
Mod Version
0.5.0i
Minecraft Version
1.18.2
Forge Version
40.2.4
Other Mods
Chipped
FramedBlocks
Steam 'N Rails
Additional Context
Driving trains (and sometimes riding them) is practically impossible.
Removing all addons and upgrading to Create 0.5.1b helps, but definitely hasn't resolved the issue. I still get spikes when driving trains, just not as bad as before.