Jump to content
Sign in to follow this  
Rommel

Mission Performance Loss (70256)

Recommended Posts

http://dev-heaven.net/issues/5147

As was reported, just thought I'd post here in hope to get it sorted sooner.

Description:

Placing units down on the map, then deleting them, will cause overall performance loss regardless of how you clean them up. It appears to be more dependent on bulk placement, meaning a thousand groups map spawned, but only one at a time, however if you place 40 groups down, then delete them straight away.

You will have lingering performance loss.

Reproduction mission attached to the DH post.

Notes:

In an attempt to clean up everything, I delete all group way points, units, and groups themselves to ensure the map becomes very close to 'empty'. No difference.

Tested on Build 70256.

Share this post


Link to post
Share on other sites

I also like to see improvements in mission performance. There has been many patches to improve FPS with 0-2 when player is alone on the map. Same time the missions are leaking and causing FPS to drop with 10-15 at least for no good reason. Dead bodies are eating FPS like alive AI and there seems to be decreasing entity limit (units, bodies, vehicles, static weapons) which starts from about 100 and gets lower during the playtime. If you go over the entity limit then you cant never get much of the FPS back. And there is noticeable stuttering.

For example, I have 60 entityes at start in mission with 35FPS. During the 1 hour playtime there is spawning and deleting with keeping the entityes under 80 all the time. Finally I have 55 entityes and FPS is only 20.

The same performance drop can be seen in official missions like warfare and even manhattan.

And I am also deleting unused the groups away so the FPS drop isnt caused by that.

Here is my issue reports with simple test missions:

http://dev-heaven.net/issues/10544

http://dev-heaven.net/issues/10542

Edited by SaOk

Share this post


Link to post
Share on other sites

Ok some data for you devs. These tests were repeated three times with same result.

5*15 = 60 units.
After deletion, 60fps.

10*15 = 120 units.
After deletion, 60fps.

15*15 = 180 units.
After deletion, 60fps.

20*15 = 240 units.
After deletion, 60fps.

25*15 = 300 units.
After deletion, 45fps.

30*15 = 360 units.
After deletion, 30fps.

35*15 = 420 units.
After deletion, 28fps.

This ... is stupid :P

Somewhere you have some CPU wasting cycles, that occur (at least for me) around 260 units...

---------- Post added at 06:47 AM ---------- Previous post was at 06:10 AM ----------

Because pretty pictures make everything understandable.

10166345.gif

And now some proper data and testing capabiliitiesfor the developers.

Groups Units FPS Before FPS After

2 11 58.82 55.56

3 21 55.56 55.56

4 31 55.56 55.56

5 41 55.56 55.56

6 51 45.45 55.56

7 61 55.56 55.56

8 71 55.56 55.56

9 81 41.67 58.82

10 91 43.48 55.56

11 101 55.56 58.82

12 111 45.45 55.56

13 121 43.48 55.56

14 131 55.56 55.56

15 141 43.48 55.56

16 151 41.67 55.56

17 161 38.46 55.56

18 171 31.25 55.56

19 181 32.26 58.82

20 191 28.57 58.82

21 201 23.26 58.82

22 211 23.26 58.82

23 221 26.32 55.56

24 231 21.74 58.82

25 241 23.81 55.56

26 251 21.28 55.56

27 261 20.83 55.56

28 271 27.03 52.63

29 281 23.81 43.48

30 291 21.28 43.48

31 301 23.81 50

32 311 21.28 47.62

33 321 18.87 43.48

34 331 17.54 41.67

35 341 18.52 40

36 351 16.95 37.04

37 361 19.61 37.04

38 371 18.87 34.48

39 381 18.52 35.71

40 391 18.52 32.26

41 401 18.87 32.26

Script to run to test it yourself.

testLoc = [2500,2500,0];

_delete = {
{
	deletevehicle _x;
} foreach (allunits - [player]);
{
	{deletewaypoint _x} foreach (waypoints _x);
	deletegroup _x;
} foreach allGroups;
{
	deletevehicle _x;
} foreach (vehicles - [vehicle player]);
};

_getinfo = {
[count allgroups,
count allunits,
count vehicles,
diag_fpsmin]
};

_dump = {
diag_log str [
	"\ngroups",(_this select 0), 
	"\nallunits",(_this select 1),
	"\nvehicles",(_this select 2),
	"\nFPS during",(_this select 3),
	"\nFPS after", diag_fpsmin
];
};

_create = {
private "_x";
private "_y";
private "_z";
_x = (testLoc select 0) + random 100;
_y = (testLoc select 1) + random 100;
_z = (testLoc select 2) + random 100;
[[_x,_y,_z], west, 10] call bis_fnc_spawngroup
};

_i = 1;
while {true} do {
_y = _i;
while {_y > 0} do {
	[] call _create;
	_y = _y - 1;
};
sleep 3;
_info = [] call _getinfo;
[] call _delete;
sleep 3;
hint format ["Test %1 Complete",_i];
private "_info";
_info call _dump;
_i = _i + 1;
sleep 3;
};

Edited by Rommel

Share this post


Link to post
Share on other sites

Nice repro. Adding into the work queue.

Share this post


Link to post
Share on other sites

Great to hear that there could be a fix coming in future. :)

What computer you have, Rommel? You seem to have at least 2.4 times better performance than I have (I have the drop at 100 units). I clocked my Q6600 to 3.4Ghz, but looks like its still too slow and old. Rest of my specs: 4Gt, HD4890, Vista 64bit.

Edited by SaOk

Share this post


Link to post
Share on other sites

Haha.

I have a E6750 @ 3.2, ATI HD4890 (512), 4GB RAM (3.4 technically ->) and XP 32bit.

I'm very glad to hear there may be a fix, nothing beats a MP mission with 2000 (deleted) AI across the map, and players reporting to me they have 60FPS (unless they are present during the deletion of AI), while the server chugs at 20 because of this (players can reset their mission by rejoining, server can't).

Share this post


Link to post
Share on other sites

Yea just done some testing with Rommel and im sooo happy to see Suma posting on this issue! Cant wait.

Share this post


Link to post
Share on other sites

Amazing news! I cant wait to test the next beta. :)

Share this post


Link to post
Share on other sites

Well that's a pretty significant fix. Great work, BIS. As always. :D

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×