Samlegamer / Macaw-s-Bridges-Compat

If you are a developer and you want to create a compatibility for the Macaw's Bridges mod you can use these examples.
1 stars 1 forks source link

[1.16.5] causes huge amount of memory usage during registry #19

Closed Kaleidio closed 1 year ago

Kaleidio commented 1 year ago

only ever alleviated with ferrite core, using this mod alongside the required mods and just a few others that aren't bloated whatsoever, the mod will tend to crash with out of memory error with just 4.5GB consumed.

Samlegamer commented 1 year ago

mod list ?

Kaleidio commented 1 year ago

BYG, BOP, Macaw's Bridges, and your bop/byg addons for it (together). allocate 3G or so to the profile. it will either freeze during registry or crash OOM. this does not happen with your addons removed (doesn't happen with other macaws mods co-installed such as lights...) and also does not happen with ferrite core installed. something is definitely happening during registry no question

Kaleidio commented 1 year ago

i will use visual vm next time to see if it will heap dump for me during any freezes so i can pinpoint the exact method at fault (pathtrace in the log won't explain)

Kaleidio commented 1 year ago

additionally it is also easy to reproduce simply by installed Kaleidio's Battle Pack from curse and adding your addons to it. remember to remove ferrite core as ferrite core optimizes that part of registry and literally doesn't let the crash occur

Nathan22211 commented 1 year ago

Using 1.19.2 here. adding ferrite core doesn't help in that version.

Samlegamer commented 1 year ago

I had tried 2 methods for byg the one with loops is the one in the form of list for registry but for the compat byg it brings almost no change, unlike the bop which is lighter (about 10 wood). I would advise to put forge in the last versions and to allocate 5go or more, it can also depend on your processor.

Kaleidio commented 1 year ago

that makes no sense as other compat mods (furniture) have been able to pull off full compat with much less ram, even though such mods have much more numerous and complex models.

i believe the issue is the models themselves for whatever reason are baking with an unexpectedly large amount of data. it should not take 2 gigabytes to bake only 200 odd models. minecraft itself has several thousand and its model cache is less than a gig

sketchmacaw commented 1 year ago

To resolve this issue, you need to update the blockstates to the new format I've made samlegamer. The old multipart causes memory issues, crashing, freezing etc..

Samlegamer commented 1 year ago

I released a patch for the bop version, I changed all the blockstates normally.

Samlegamer commented 1 year ago

byg patch available