Astral Sorcery

Astral Sorcery

63M Downloads

EnchantmentUpgradeHelper performance issue

Sir-Will opened this issue ยท 10 comments

commented

There are more enchantments where this looks the same.

commented

Need some context for what this actually represents for overall load.

commented

What do you mean?

commented

You are pointing at something that's using so little of the time the snapshot prints that even the jvmprofiler rounds it to 0. Whatever you're trying to resolve as performance impact, something that gets rounded to 0% of time used is hardly what you're looking for.

Given you wanted to point at the lint you had selected. On the other part it's about 2% which is not an impact worth mentioning either, given whatever you're trying to look for.

commented

Where do you read 0%? It's 1.6% for isPlayerFakeMP which shows up for multiple other enchantments so it's more then 1.6%

commented

Learn how to interpret jvm snapshots or take what you hear from experienced people. Don't make up stuff that suits your case.

Percentages of time used are shown behind the time the call used up.
In that case above for example, EnchantMagnet.onEntityUpdate uses up 2.1% of the time snapshotted. That's it. 2.1% total. Anything shown in the hierarchy below is just that 2.1% split up into the following calls to further look down into the stack for specific calls.

commented

For the specific call isPlayerFakeMP you mentioned, it took up 9ms from all the time you've ran the snapshot in total.
All calls in all instances during your time recorded took up that amount of time; 1.6% of that time, relatively speaking. Hardly a noteworthly amount.

commented

@HellFirePvP I believe he means that this happens for every enchantment. You can see at the very top the Magnet Enchantment, the others are not visible on the screenshot.

commented

Then need the full thing. Because 2.1%, or fractions of a percent, is nothing when the server isn't dying.

And, again, not what the screenshots are indicating.

commented

commented

Welp. As most of the overhead comes from the mod state lookup, i'll see to it to cache that as it shouldn't change to begin with after startup. Still, wouldn't expect that to take up the amount of time that it does.