Jump to content
Sign in to follow this  
carlostex

Arma 3 && Multithreading!!

Recommended Posts

Not sure if this has been asked, of there is a thread with a proper on topic discussion so i please ask moderators to close if there's a similar thread.

I would guess that with the complexity of the game, especially AI going forward, and now with CPU PhysX acceleration BIS will probably make the engine use more cores than present RV3. There are 6 and 8 cores from AMD and 4 core (8 threads) and 6 core (12 threads) from Intel.

To BIS:

1. Will Arma 3 will go further and use more than 4 cores?

2. Will Arma 3 make use of SMT?

I bet Suma is working on it.... :D

Share this post


Link to post
Share on other sites

I haven't really paid attention... How efficient are ArmA 2 and OA when it comes to multithreading? TONS of horsepower can now be had for very reasonable prices, and it would be great if ArmA 3 took full advantage. BI is one of the only game studios I still respect, due to them not jumping on the console bandwagon. Weather or not ArmA 3 will take full advantage of high end hardware, AT LEAST it wasn't designed for archaic console crap.

Share this post


Link to post
Share on other sites

Im quite sure its being worked on but i just hope they get the instructions / scaling or whatever its called, that they get it right and to full potential of VT too.

Share this post


Link to post
Share on other sites

BIS struggle to use 2 cores atm... I dunno what they are doing with the Arma engine but their latest take on helicopters had major issues using available CPU power... I want to see Arma engine eat my 2-4 cores to 80% at least before adding support for more.. ATM the engine struggles to even use the first core fully before going onto the next... often this results in each core using 25-50% of power and then the GPU only being utilized to 60-80%... The ARMA engine truly wonders me at times....

Share this post


Link to post
Share on other sites

please read dev blog about multicore and it was covered numerous times by us in this forum (search ftw) ...

ARMA 2: OA and TOH can use multicore fine (i think up to 32 cores), please realize that coding multithreaded application means You can't use 100% all cores and it scales down with each new core

atm. gain over 6 native cores is neglible

Share this post


Link to post
Share on other sites

Sounds like plans for Virtual threads are being taken into account than :)

Either way, as i understood the OP point; yes it can utilize multicores but apparently not to the extend that the more cores are in use, the smoother the game handles.

I mean it feels like the game still choking the CPU too much, no matter how many cores / VT are in use?

Share this post


Link to post
Share on other sites

atm. gain over 6 native cores is neglible

Well yeah that's where i was trying to reach when created thread. To know if gain over certain number of cores or threads is going to be more significant for Arma 3 than for older engine versions.

Share this post


Link to post
Share on other sites

One core uses 90%

All 3 others uselike 20%.

I say CPU scaling on ArmA 2 A2 OA CO is bad

Running on 3 cores seems to offer equal performance than on 4 cores here

Share this post


Link to post
Share on other sites

Well it's bad because load can not be as easily spread as you might think. Another core is not a magical 100% boost.

I guess the one core with 90% load is the one doing the wayfinding map for the ai. The rest probably one reading from hard drive, one for physics and another for the rest/general game.

This ai thing for example. Assuming it's something like a Dijkstra (probably not but that illustrates well) It just builds a lot of nodes and determines the "cost" to travel these nodes. Ohne node should cover something like 0.5m². You could process 100mx100m patches by different cores but sewing these patches together would be a real nightmare.

The hard drive managing core can't probably go any faster except if you have some SSD or RAID0.

Share this post


Link to post
Share on other sites

Yeah, multithreading in a game is a whole other ball game than, for example, multithreaded video encoding. In a game, threads need to be synchronized (basically wait for each other), among other considerations. If you have physics in its own thread, but there aren't currently many physics calculations to do, then that thread will spend most of its time waiting for other threads to complete on every "world tick". Nothing much you can do about it. Compare that with the aforementioned video encoding, where you can just keep throwing chunks of data at the worker threads until the job is done (usually keeping them at 100%) because it doesn't matter how fast each individual sub-task is completed. It's an asynchronous process, while games are synchronous by nature.

That's not to say that the threading implemented in Arma2 is perfect. There may well be room for improvement.

Share this post


Link to post
Share on other sites

i will quote suma again

ArmA 2 can use up to 31 cores in theory, but experiments have shown that with most scenes the gain above 4 cores is small and above 8 cores unmeasurable.

The explanation is Amdahl's law - only parts of the application is using all cores. See Real Virtuality Going Multicore blog.

---------- Post added at 13:58 ---------- Previous post was at 13:54 ----------

In build 76122 and newer the default for dualcores will be changed to -exThreads=3 based on user feedback.

We have also changed the cpu core detection, therefore depending on how many logical cpus are present, default -cpuCount values will be as follows:

1 1

...

6 6

7 7

8 4

9 4

10 5

11 5

12 6

13 6

14 7

....

Some day hopefully we will find a time to provide a proper HT detection, but until then I think the above provides quite reasonable default settings.

all in all ... you need realize that having 1000 cores is not going to help You as long there is sequential code which has it's minimal timeframe which must be always met

Share this post


Link to post
Share on other sites

Well, that was the Situation in early ArmA2...

Hasn't there been any improvement made for ArmA3?

I mean, i dunno if i got that right, but lets say with 8 cores, there should be no Problem of dedicating a single core to PhysX and another single core for AI, or even two for AI... Even though they won't scale to a 100% because of given reasons, still it should help with calculating these demanding tasks.

Share this post


Link to post
Share on other sites

improvements is something else, but people expect unrealistic results ...

if You have 8 cores, you will benefit from OS tasks offloading, GPU drivers offloading as they now multithreaded

(and it will be even better when NVIDIA and AMD finalize it for DX11 drivers)

now You talk about dedicating core here and there for PhysX and AI, but You somehow forgot about thread syncing etc.

Share this post


Link to post
Share on other sites

yes people should know a little bit of programming code and what it means when one core does this and another this, but the finals product of both is needed to move on with new calculations. before both didnt end, there cannot be another clac. so one core must wait . in a perfect world all calcs would need the same power so all could finish the same time and so on. but inr eality thats not the case so one core idles till his friend is ready again :D

there are some tricks, but you cant make code so that it gains 100% from more cores.. beacuse it would mean with 999^999 cores everything could be calculated in 1 millisecond.. but thats not possible. like 200 cooks cannot make a cake in 1 second when 1 cook needs 200 seconds..

Share this post


Link to post
Share on other sites
improvements is something else, but people expect unrealistic results ...

if You have 8 cores, you will benefit from OS tasks offloading, GPU drivers offloading as they now multithreaded

(and it will be even better when NVIDIA and AMD finalize it for DX11 drivers)

now You talk about dedicating core here and there for PhysX and AI, but You somehow forgot about thread syncing etc.

At the moment what I see, particularly on the dedicated server is one core being absolutely crushed and a tiny amount used of a second core.

Could all AI decision making not fully utilise (I mean run at 100%) an entire core of its own (or as many cores as are required to make CQB work well) and the main thread just seek updates (give me the best course of action for this unit right NOW) as and when it has-time/needs-to? Thread syncing in this scenario should be a non-issue and the AI thread should have no issues with read-only access to the game's state (for all units).

Share this post


Link to post
Share on other sites

I would be happy if Arma 3 would just support 4 cores and also use these 4 cores to its full ability and not having 1 core at 100%, one core at 80% and two others sitting idle at 20 to 30% as it is now (shamefully). BF3 is one great example of a game which shows excellent scalling is possible across multiple platforms with CPU threads and GPU's, so nothing is impossible.

improvements is something else, but people expect unrealistic results ...

"Impossible is a word to be found only in the dictionary of fools." (Napeleon Bonaparte)

"It always seems impossible until its done." (Nelson Mandela)

"Nothing is impossible, the word itself says 'I'm possible'!" (Audrey Hepburn)

“The impossible is often the untried.†(Jim Goodwin)

“Success is determined by those whom prove the impossible, possible.†(James W. Pence)

Do I need to go on? Demanding the impossible is not about demanding unrealistic goals, it is simply about reshaping the borders of realism.

Share this post


Link to post
Share on other sites

Impossible means something way different the unrealistic. Back to start. :)

Or at times it is better not say/write something if one has no clue AND is not willing to educate oneself or listen to the insights of others.

Share this post


Link to post
Share on other sites

Luckily you don't have any authority to determine what could be written and what not, let alone you have any insight in my level of education and abilities.

Please inform yourself of the existance of synonyms (tada) before you try to make a clever comment again and tell others what to write/say/think and what not.

So keep your insults (1. I have no clue, 2. I am not educated nor willing, 3. I don't listen to others) for yourself next time. Thanks in advance.

Edited by Bravo_Two_Zeroq

Share this post


Link to post
Share on other sites
I would be happy if Arma 3 would just support 4 cores and also use these 4 cores to its full ability and not having 1 core at 100%, one core at 80% and two others sitting idle at 20 to 30% as it is now (shamefully). BF3 is one great example of a game which shows excellent scalling is possible across multiple platforms with CPU threads and GPU's, so nothing is impossible.

Two very different game engines with very different coding approaches and challenges, so I think this may be a poor comparison. But yes, it's probably not impossible to make it more efficient, and I'm sure the programmers are doing their best to make it so, given the abundance of quad-core CPUs nowdays.

Additionally I think it would be a bad idea when comparing two engines to say one's more optimized than the other just because it uses 100% of all CPU cores (Note that I'm using a hypothetical example here, not BF3). Rather than this meaning that it threads well, it could also mean that its code is inefficient compared to the other, as it needs more CPU cycles to do the same job.

Edited by Dingo8
Rephrased second sentence to make it clearer

Share this post


Link to post
Share on other sites

A comparison is always made by two different things by definition ;). Not the same, but comparable I guess. I don't say Arma 3 has to scale as good as BF3 which is the modern standard for scalling, I recognize that BF3 supports multiple platforms for example and has to scale very good while Arma 3 is just for PC. And then there is also a budget difference as well as size differences between both teams. So I won't even hope Arma 3 will get as good as BF3 when it comes to scalling.

But since a majority has at least a quad-core processor as is the standard nowadays, I hope for any improvement over Arma 2 and not only offloading all none-Arma applications to the remaining cores. Would be a waste if Arma 3 could offer all those graphical and other improvements while people with sufficient calculation power could not handle it as Arma 3 can not distribute enough across multiple threads and people have to overclock to 4,5+ GHz to make the first core fast enough to handle all non-threaded coding. But I'm hopefull, as Arma 3 is also going to support multiple GPU configurations at last.

Share this post


Link to post
Share on other sites

@Bravo_Two_Zeroq : where do you get this piece of information ?

... But I'm hopefull, as Arma 3 is also going to support multiple GPU configurations at last.

Share this post


Link to post
Share on other sites

"Impossible is a word to be found only in the dictionary of fools." (Napeleon Bonaparte)

"It always seems impossible until its done." (Nelson Mandela)

"Nothing is impossible, the word itself says 'I'm possible'!" (Audrey Hepburn)

“The impossible is often the untried.†(Jim Goodwin)

“Success is determined by those whom prove the impossible, possible.†(James W. Pence)

Do I need to go on? Demanding the impossible is not about demanding unrealistic goals, it is simply about reshaping the borders of realism.

Humanity really needs to teach processors those things. I'm having a mental image of an old PIII with GeForce 2 and 256MB of RAM getting inspired and springing to life to run Crysis 3 at 120FPS with victorious and uplifting music playing in the background while a developer sits next to it yelling "Yeah, you can do it buddy! I believe in you!".

  • Like 1

Share this post


Link to post
Share on other sites

Well, I will take back that SLI is going to get better in Arma 3 as BIS is pointing at nVidia and AMD for driver development, but here is something about it that it will support it out of the box at least, and more importantly 3D will be supported as well. Appart from multithreading a second big plus would be an actual benefit of having a SLI or CrossFireX configuration and I clearly don't mean an increase of 10 or 15 fps for adding a second GTX 580 (or GTX 680), but a scalling in the area of 60%-80%. Cooperation is key here and unfortenately this is not only dependent on BIS.

"Everyeye:We would like to know, if possible, which of these technical features you are planning to introduce out-of-the-box: SLI / Crossfire, Nvidia Vision / AMD 3DHD, Nvidia Surround / AMD Eyefinity?

Ivan Buchta:The engine has been capable of running on a multi-GPU setup since Arma 2; however, things work a bit differently: the hardware manufacturers maintain compatibility with the games, not vice versa. Regarding the new technologies, NVIDIA Vision and Surround as well as AMD 3DHD and EyeFinity are partially supported since Arrowhead, and we hope to be able to further enhance and expand the support."

source

@Sniperwolf

Crysis 1 never, Crysis 2 maybe and Crysis 3 will be propably ported to Android and ARM architecture, so who knows what your Pentium III might be able to achieve...

Share this post


Link to post
Share on other sites

i must again repeat that SLI/Crossfire support in 90% not responsibility or even within 'grasp' of game developer

what developer can is support variety of API calls/enhancements like NVIDIA Surround and AMD Eyefinity via theirs libraries

which mean e.g. better positioned HUD on multiple displays, no issues with stereo or 3D displays,

better work across 2+ displays (e.g. 3,4,6 displays, horizontal/vertical placement of these etc)

but there is not much (except detecting the video memory, frame buffer properly) what can be done for multi GPU configs

usually the IHV like NVIDIA and AMD provides predefined profile for drivers which determine AA type and method of multiGPU calculations for the the game

Share this post


Link to post
Share on other sites

Don't recall if I proclaimed otherwise, not blaming the developer in any case when it comes to multi GPU support. But a game developer can make the game good enough so it becomes popular, and when it becomes popular the driversupport will come automatically ;).

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  

×