[Linux] Lag & kick/crash with high number of units

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

[Linux] Lag & kick/crash with high number of units

Postby Gandhi » Thu 8 May 2014 01:56

Hello... No problem at all normally, even in 10 vs. 10 when unit count remains 'normal' - but when major cheap tank spam happens and lots of units move at once, framerate drops, lag occurs and sometimes ends in a kick. Kick happened once today and once before (login name: gandhi), but I have encountered lag before in similar situations.

Specifications:
- Debian Wheezy (mostly)
- Linux 3.13-1-686-pae
- Intel Core i7-2600
- Radeon HD 5770 (yes, my graphics are ugly and I don't care at all - though I run at 2560x1600 on a 30" display) using latest fglrx (14.3~beta1.0-1) (AMD non-free)
- 8 GB RAM, SSD etc.
- Internet access: Numéricable 30/5Mb.s^-1 (Speetested) in Courbevoie with no significant traffic
- No CPU load other than W:ALB

From what I read on this forum, I am hitting the CPU ceiling... With an i7-2600 ? Is such quad-core processor really not enough ?

Next time I play, I'll try to reproduce the behaviour and have a CPU graph. Meanwhile, any ideas ?

This elicits memories of playing Total Annihilation on a Pentium 75 with the unit count ceiling removal patch...
Last edited by Gandhi on Fri 8 Aug 2014 16:35, edited 2 times in total.

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Gandhi » Fri 9 May 2014 00:28

Successfully reproduced being kicked - this time with only 12 minutes to go until the end of that nice 10vs10 Ragnarok... Lots of action by lots of units triggers the framerate drop and subsequent kick reliably.

This time, I set up some monitoring... The following image shows activity during the game, getting kicked and exiting the game (full version of the image - each vertical pixel line is one second):
Image

The overall load remains perfectly acceptable on my system at values below 80%. One core seems particularly occupied at the end - it seems correlated with the abnormal behaviour, but its load barely climbs above 90% and never reaches saturation at 100%.

The sequence of events according to this graph is as follows:
  1. Cessation of network traffic
  2. Drop in RAM usage
  3. Drop in CPU usage

But from a dstat log I get a slightly different story: it shows a burst of disk writing activity when network traffic ceases. According to it, the sequence of events is as follows:
  1. Cessation of network traffic, drop in user CPU usage and drop in context switching activity, simultaneously
  2. Burst of disk writing activity, with matching CPU waiting. The drop in RAM usage occurs around there, but I do not know if it is simultaneous.
  3. Drop in CPU usage

Here is part of the dstat log (each line is one second - so this is only the transition timespan) :

Code: Select all

----total-cpu-usage---- -dsk/total- -net/total- ---paging-- ---system--
usr sys idl wai hiq siq| read  writ| recv  send|  in   out | int   csw
 21   3  75   0   0   0|   0     0 |6685B 3190B|   0     0 |6011    94k
 21   4  75   0   0   0|   0     0 |6743B 2940B|   0     0 |6137    98k
 21   4  76   0   0   0|   0     0 |7102B 3072B|   0     0 |6125    92k
 20   3  76   0   0   0|   0     0 |6571B 4170B|   0     0 |6315    90k
 19   4  77   0   0   0|   0    20k|6806B 3128B|   0     0 |5403    74k
 21   4  75   0   0   0|   0     0 |6228B 2640B|   0     0 |5663    87k
 19   4  76   0   0   1|   0     0 |6500B 2990B|   0     0 |5555    96k
 21   4  75   0   0   0|   0    40k|7289B 2998B|   0     0 |6264    94k
 16   3  81   0   0   0|   0     0 |1478B 1020B|   0     0 |4175    40k
 14   2  84   0   0   0|   0     0 |   0   130B|   0     0 |3590    15k
  6   5  85   4   0   0| 332k  112M| 237B    0 |   0     0 |2925  9102
  1   2  87  10   0   0| 100k  192M|   0     0 |   0     0 |2047  6515
  1   1  88  10   0   0|  96k  254M|   0     0 |   0     0 |2340  5437
  1   1  88  10   0   0|  28k  246M| 161B  690B|   0     0 |2290  5510
  1   2  87  11   0   0| 976k  190M| 724B  346B|   0     0 |2036  5358
  2   3  96   0   0   0|   0    16M| 860B 1368B|   0     0 |1500  5304
  1   1  98   0   0   0|   0    24k|6594B   15k|   0     0 |1246  4058
  2   1  97   0   0   0|   0    20k| 444B  588B|   0     0 |1509  5788
  1   1  98   0   0   0|   0  8192B|   0    70B|   0     0 | 810  2649
  2   1  98   0   0   0|   0     0 |  64B   64B|   0     0 | 812  2672
  1   0  98   0   0   0|   0   124k|   0     0 |   0     0 | 754  2560
  1   1  98   0   0   0|   0     0 |   0    70B|   0     0 | 771  2697
  1   1  98   0   0   0|   0     0 |   0     0 |   0     0 | 752  2598
  1   1  98   0   0   0|   0     0 |   0   690B|   0     0 | 754  2569
  1   1  98   0   0   0|   0     0 |   0     0 |   0     0 | 770  2584


Any of that rings some bells ?

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Gandhi » Sat 10 May 2014 03:05

Reproduced again... Everything works perfectly with my luxury deck but with my spam deck I end up getting kicked. Well... I guess I'll play with the luxury deck a bit !

User avatar
Shifu
Lieutenant General
Posts: 4196
Joined: Wed 13 Jul 2011 16:06
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Shifu » Sat 10 May 2014 12:14

You only get kicked in 10v10 with high unit amount, right?

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Gandhi » Sat 10 May 2014 13:27

Shifu wrote:You only get kicked in 10v10 with high unit amount, right?

Yes - especially when lots of units get moving simultaneously. For example when I stage large masses of infantry and tanks (lets say a hundred units) the game holds, but when I order them to assault, the framerate slows and the lag ends up in a kick.
Last edited by Gandhi on Sun 11 May 2014 02:18, edited 2 times in total.

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Gandhi » Sun 11 May 2014 02:17

Upgraded fglrx from 14.3~beta1.0-1 to 14.4-2 - seems to solve the problem - I went romping over Ragnarok with Polish hordes of T34-85, PT-76, ASU-85 and oceans of infantry... No kick. Some occasional hiccups, but nothing like it was.

Also, I was sometimes encountering graphical artefacts in the icons that reminded me of memory corruption in JPEG (now that I think of it, I should have mentioned it). I thought that it was unrelated, but they have also disappeared.

Looks like I suffered once more from AMD's sad bug-ridden driver - I would buy more of their graphic adapters if they had the good sense to liberate their code so that decent drivers can be had.

I'll post here in a few days to confirm or infirm this resolution.

User avatar
Shifu
Lieutenant General
Posts: 4196
Joined: Wed 13 Jul 2011 16:06
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Shifu » Sun 11 May 2014 13:30

Great to hear - thanks for sharing!

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Gandhi » Fri 16 May 2014 01:07

Well... I just did not push it enough... With my high-tech Soviet deck I encountered slight icon graphical corruption after a while and then in a game with my 75' Polish deck I finally encountered the framerate slowdown and then the kick... It took a lot of units moving at once, but the problem is reproduced. From a subjective feel, which is usually worthless in testing, it took more to achieve that this time, but I wouldn't bet too much on it - I would prefer playing in a some sort of debug mode to log the number of moving units and the total number, visible or not visible...

So basically we are back to square one, but with a slight suspicion that causes of the problem may be found deeper in the graphics stack.

Too bad - I love playing with large numbers of units... I guess I'll have to do without it until I solve this...

Grmbl.

Would a replay file help ? I could ask someone I played with tonight when the kick happened - a nice fellow player by the name of Degradeable might have it.

User avatar
Gandhi
Corporal
Posts: 44
Joined: Tue 14 Jan 2014 12:46
Location: Paris, France
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby Gandhi » Fri 25 Jul 2014 02:06

Apart from the graphical corruption pattern bug that appears late enough in W:ALB that restarting it after each game is sufficient for avoiding its effect, W:ALB works well enough with low unit count decks that I felt like pushing my luck and trying to use my favourite Polish flood deck. Well... With many units, the framerate gradually drops and later it ends in the game crashing - no kick message, no disconnection warning countdown: just the application disappearing suddenly.

I can reliably reproduce this behaviour, so here are a couple of crash dumps :
http://rezo.grabeuh.com/WALB/crashes/15 ... 784218.dmp
http://rezo.grabeuh.com/WALB/crashes/56 ... 5cefca.dmp

I noticed that the crash happens when there is a lot of action going on. In one of those games, it was time for a final push so I had selected almost all my units and ordered them to the far corner of the map... Instant crash as soon as they started moving !

I know that W:ALB may not be your top priority at the moment... But since the graphical corruption pattern bug keeps me from playing W:RD at all W:ALB is my bread and butter at the moment ! So tell me if you need more information - I'll be delighted if anyone takes a look at this problem !

User avatar
FLX
Lieutenant General
Posts: 4008
Joined: Fri 16 Mar 2012 10:43
Location: Paris
Contact:

Re: [Linux] Lag & kick when unit count goes through the roof

Postby FLX » Fri 25 Jul 2014 02:12

The processor load depends of the total amount of units in the game, not ony yours, so if you play with your "luxury deck" while every other player play with a spam deck you will certainly get kicked.

I'll show this thread to the tech section to see if it can help.
Image
Be nice or I nerf your favorite unit !

Who is online

Users browsing this forum: No registered users and 0 guests