Bug - Waiting for Info Using Drum Machines via CLI Bogs Down Mafia

Farflier

New member
I use the CLI command to farm sandworms; "use X drum machine"
After about 100-200 sandworms fought in this way, mafia begins to lag severely. I use them in lots of 100, it takes just a couple minutes for it to automate my first 100, and then the next bunch I do usually takes half an hour or more.
I have experienced and dealt with this problem every day for almost a year now, and finally decided it might be good to report it. I update to the current daily build once a day, and the problem has persisted through the last 2000 or so daily builds. I've been able to fix it just by shutting down mafia completely and re-opening a fresh instance to finish the rest of my sandworms.

Hope this is helpful, if you have any questions or require more information please Kmail me ingame @ Farflier (#2070646)

Cheers
 

roippi

Developer
You need to make very sure that that actually fixes your problem.

If it does, this has to be marked "won't fix." All that button does is force Java to do garbage collection, which it should be doing anyway automatically when your heap fills up. What do the numbers say on that bar after running a bunch of drum machines? And what java version are you running?
 

xKiv

Active member
You need to make very sure that that actually fixes your problem.

If it does, this has to be marked "won't fix." All that button does is force Java to do garbage collection, which it should be doing anyway automatically when your heap fills up. What do the numbers say on that bar after running a bunch of drum machines? And what java version are you running?

AFAIK, System.gc will force a full, stop-world cycle (unless disabled by java properties), over all generations.
Automated gc under default java options (different in different versions of java) will *maybe* do that if you are completely out of memory (according to java heap sizing). Some of them might also leave some dangling dead object to be collected in a later cycle, or do other not-completely-savory things.

But if full GC (as opposed to automatic) helps, I would suspect either swapping (java heap doesn't fit in available physical RAM), or RAM problems (starts using different chip, different chip is slower), or badly configured gc (so that it spends a lot of time collecting, but doesn't find most of the garbage, so the heap fills up fast again, so java spends a lot of time collecting, but doesn't find, ... etc ...).
 

Farflier

New member
You need to make very sure that that actually fixes your problem.

If it does, this has to be marked "won't fix." All that button does is force Java to do garbage collection, which it should be doing anyway automatically when your heap fills up. What do the numbers say on that bar after running a bunch of drum machines? And what java version are you running?

I am running java version 1.6.0_33 (Sun Microsystems)

So, this is what happened today:
At startup, my bar was about 25000kb-35000kb / 253440kb.
After the first set of 100, the bar was fluctuating between 70000kb and 90000kb / 253440kb and processing the drum machines had slowed down quite a bit as usual.
I pressed the garbage button, bringing the bar down to about 40000-50000kb / 253440kb, processing the drum machines a bit faster but not as fast as it did in the beginning.
However, after only 20 further drum machines the bar was already back up to 70000+ kb.
I shutdown mafia completely, and reopened - the bar had reset to the original 25000-35000kb range.
Upon finishing the rest of my drum machines, the bar had climbed back up to 50000-55000kb, however the processing had not slowed down according to my human eye - I was watching it the whole time.

So, I hope this information helps... honestly I'm not sure how to interpret this data, myself.
 

roippi

Developer
Well, here's where this gets really unfun. There's two options:

1) Send me a few hundred drum machines. 300 at least.
2) Send me a heap dump from right after logging in, one after you run 100 drum machines, and one after you then run GC.

#2 involves installing a JDK and running some tools, then sending me around 200MB in files. I'd prefer #1.
 
Top