Bullet Optimisation

Everything about development and the OpenMW source code.
User avatar
gus
Posts: 390
Joined: 11 Aug 2011, 15:41

Bullet Optimisation

Post by gus »

Let's starts back where we finished last time:

First, here is the link to the previous discussion:
http://openmw.org/forum/viewtopic.php?f=13&t=129

So K1ll, could you do some testing for me? More specifically, could you go in libs/openengine/bullet/physic.cpp and look at line 285 :

Code: Select all

dynamicsWorld->stepSimulation(deltaT,1,1/50.);
and try out some different values? For exemple:

Code: Select all

dynamicsWorld->stepSimulation(deltaT,1,1/30.);

Code: Select all

dynamicsWorld->stepSimulation(deltaT,1,1/20.);

Code: Select all

dynamicsWorld->stepSimulation(deltaT,1,1/10.);

Code: Select all

dynamicsWorld->stepSimulation(deltaT,1,1.);

Code: Select all

dynamicsWorld->stepSimulation(deltaT,1,5.);
And report the FPS?

Could you also do it for this?

Code: Select all

dynamicsWorld->stepSimulation(deltaT,10,1/10.);

Code: Select all

dynamicsWorld->stepSimulation(deltaT,0,1/10.);
K1ll
Posts: 184
Joined: 06 Aug 2011, 21:54

Re: Bullet Optimisation

Post by K1ll »

Sorry for replying so late, but i was a bit busy this weekend.

I'll test those changes tomorrow at least on my old laptop mentioned in the old thread and my ubuntu 10.10 64 bit desktop.
User avatar
gus
Posts: 390
Joined: 11 Aug 2011, 15:41

Re: Bullet Optimisation

Post by gus »

Thanks!
BTW,5 hours is pretty short for me ;)
K1ll
Posts: 184
Joined: 06 Aug 2011, 21:54

Re: Bullet Optimisation

Post by K1ll »

Well i have run tests with all the values you suggested. These are the results:

Parameter Value(s) | Interior fps (in Beshara) | Exterior fps (in Vivec)

Old Laptop:
1/50. | 28 | < 0
1/30. | 28-29 | < 0
1/20. | 51-53 | < 0
1/10. | (75) 80-85 | < 0
1. | 112-116 | < 0
5. | 113-117 | 0-11

10., 1/50. | 3 | < 0
0. 1/50. | 28-29 | < 0


Dekstop:
1/50. | 65-66 | 1
1/30. | 106-107 | 1
1/20. |124 | 1
(1/10. | 143 | 1
1.| 158-159 | 7-8
5. | 159-161 | 5-20

10., 1/50 | 63-66 | 1
0., 1/50 | 57-58 | 1
User avatar
gus
Posts: 390
Joined: 11 Aug 2011, 15:41

Re: Bullet Optimisation

Post by gus »

Could you do the same bench (just do few of them, like 1/50., 1/10. and 1.) with line 346 to 369 commented? (you can use /* */ to comment things)

And can i also have your desktop config?
K1ll
Posts: 184
Joined: 06 Aug 2011, 21:54

Re: Bullet Optimisation

Post by K1ll »

Here are the tests with the changes applied:

Old Laptop
1/50. | 28-29 | 0
1/10. | 85-86 | 0
1. | 110-113 | 0
5. | 111-115 | 4-12

Dekstop
1/50. | 72-75 | 1
1/10. | 143-144 | 1
1. | 159-160 | 8
5. | 162-163 | 8-22

Not much of a difference though.

The specs of my Desktop:

Ubuntu Maverick Meerkat 10.10 64 bit
AMD Athlon 64 X2 Dual Core Processor 6000+
8 GB DDR2 Ram
Nvidia GeForce 9800 GTX+ with 512 MB video ram
User avatar
gus
Posts: 390
Joined: 11 Aug 2011, 15:41

Re: Bullet Optimisation

Post by gus »

Would it be possible to have a test on windows on the same machines? This would be very useful, as if it run correctly on windows, it might be a bug in bullet and not in OpenMW.

PS:a very stupid question: you compiled in release mode right?
K1ll
Posts: 184
Joined: 06 Aug 2011, 21:54

Re: Bullet Optimisation

Post by K1ll »

I don't have windows on the old laptop (it runs way to slow on it) but i can test it with win xp and win 7 on my desktop if you could compile the tests and upload the binaries.

I'm pretty sure that i don't use debug binaries atleast i didn't specify it explicitly.
User avatar
gus
Posts: 390
Joined: 11 Aug 2011, 15:41

Re: Bullet Optimisation

Post by gus »

Here is a windows version:
http://www.megaupload.com/?d=8I70P6V5

Edit: BTW Zini, you can merge my bullet_bug branch in the main branch. There is a performance boost in this branch.
K1ll
Posts: 184
Joined: 06 Aug 2011, 21:54

Re: Bullet Optimisation

Post by K1ll »

I've tested on Windows XP and it has similar slowdowns they are just not as noticeable since sadly openmw seems to run a lot faster on windows in general.

In Beshara i had ca 250 fps and in Vivec it still managed to get 70+ fps. Without pyhsics i had nearly 500 fps in Beshara and about 200 fps in Vivec.
Post Reply