Blood Magic

Blood Magic

90M Downloads

long delay while client loading with BM 1.7.10-1.3.1-7

NoX-programer opened this issue · 9 comments

commented

After the line

[20:54:55] [Client thread/INFO]: [WayofTime.alchemicalWizardry.common.book.BookParser:parseTextFile:38]: I am in an island of files!

in the log of client Minecraft is hanging up for 2m10s and only then continues loading. And this is on my desktop PC with Intel(R) Core(TM) i7-3970X CPU @ 3.50GHz. Other people using this modpack have to wait even very much longer, up to 10m! Please make a fix removing this delay.

Hand-maded ModPack, BloodMagic-1.7.10-1.3.1-7, full modlist: http://pastebin.com/rS3bHY3s

BTW, it wil be cool if you add the link to this issue tracker on www.minecraftforum.net (may be to FAQ).

commented

This is very odd, since I did add something to alleviate this burden already... Did it not make it into the version or something?

commented

Version BloodMagic-1.7.10-1.3.0b-3 don't hangs up client loading for long, BloodMagic-1.7.10-1.3.1-7 do. I've rolled back to 1.3.0b-3 to not have this problem. Sec, I'll switch back to 1.3.1-7 to give you the log.

commented

http://rghost.ru/7c96brxkp - here is the logs. That's strange that my office computer (Intel I5) have only 47 secs of that delay... Anyway, different computers, different delay.
lines appear so:
[16:31:01] [Client thread/INFO]: [WayofTime.alchemicalWizardry.common.book.BookParser:parseTextFile:38]: I am in an island of files!
[16:31:48] [Client thread/INFO]: Adding the following recipe to the Compression Handler: 1xtile.blockGold@0
[16:31:48] [Client thread/INFO]: Adding the following recipe to the Compression Handler: 1xtile.blockIron@0
[16:31:48] [Client thread/INFO]: Adding the following recipe to the Compression Handler: 1xtile.blockDiamond@0

A few hours later I can check again my home computer with Intel I7, which have 2m10s delay here.

commented

When, if ever, do the following lines appear? "Adding the following recipe to the Compression Handler:"

commented

Oh, really... so the delay isn't at the compression handler, but is actually in the book parser? Or is it still working away at the pre-handler? Hmmm... The issue might be in my book parser and not my compression registry if that is the case. I don't see why, though, since the parser only really manipulates strings.

commented

Really strange - home computer, Intel I7, same delay about 2m10s (much longer than on I5!). If you not succeed to replay the delay, I can assist - may be we need some "debug" version which will be more verbose at log output when book parser & pre-handler is working?
(What it can do so long with a books? Maybe it cycles too much due to typo?)
(offtop: I've heard that processor cooler is increasing RPM at the delay so it is intensively loads the CPU)

commented

Your book parser has some O(n²) or even O(n³) loops.
From what I can see, the calls to Minecraft's listFormattedStringToWidth method are pretty expensive and you're making a lot of them.
Maybe you should use an alternative beause in all the times you call this function you're never actually using the result - only how many lines it has.

I suggest using a profiler to see where the culprits are though.

commented

Ok, so I will definitely disable that for now until I can get it running at a reasonable rate. Don't expect a -8 until next week, however - lots of IRL projects needa doin'!~

commented

Fixed