Support for multicore in pathfinding? - Page 2

Support for multicore in pathfinding?

Requests for features in the spring code.

Moderator: Moderators

User avatar
Argh
Posts: 10920
Joined: 21 Feb 2005, 03:38

Re: Support for multicore in pathfinding?

Post by Argh »

Pathfinding is an inherently slow problem, and everywhere you're told to cache the data or put it in the world as prebuilt markers and waypoints. The latter system falls apart when the word terraforming and dynamic terrain appears.
QFT. Multi-core would make sense if it was offloading the pathfinder to the second core if it existed, freeing up the first core for other CPU-gobbling stuff, like cegtag.

However, as a single-core-owning person with quite a lot less than 2GB of RAM, I'd hate to see what happened to my poor PC if it got hit with major new requirements...
User avatar
SwiftSpear
Classic Community Lead
Posts: 7287
Joined: 12 Aug 2005, 09:29

Re: Support for multicore in pathfinding?

Post by SwiftSpear »

MadRat wrote:But the purpose of the thread was to talk about what multicores could be tasked with, not the effect it would have if you tried to do the same on a single cpu system.
Working in either vaccume is useless. We need a system that doesn't overtax single cores while at the same time allows multicores the ability to exploit their abilities.
User avatar
TradeMark
Posts: 4867
Joined: 17 Feb 2006, 15:58

Re: Support for multicore in pathfinding?

Post by TradeMark »

MadRat wrote:But the purpose of the thread was to talk about what multicores could be tasked with, not the effect it would have if you tried to do the same on a single cpu system.
yeah, i just wanted some use for my 3 other cores, feels a waste.
Archangel of Death
Posts: 854
Joined: 28 Jan 2005, 18:15

Re: Support for multicore in pathfinding?

Post by Archangel of Death »

Know what is interesting? The other day while playing Spring with task manager open I noticed I was at 100% computer usage... and it was all spring... and setting spring to one core reduced my framerate signigicantly.

Spring is multi-threaded now?
Last edited by Archangel of Death on 22 Jan 2008, 23:35, edited 1 time in total.
Kloot
Spring Developer
Posts: 1867
Joined: 08 Oct 2006, 16:58

Re: Support for multicore in pathfinding?

Post by Kloot »

No, unless you count the server thread (which
causes so little load it doesn't matter on what
core it runs).
User avatar
TradeMark
Posts: 4867
Joined: 17 Feb 2006, 15:58

Re: Support for multicore in pathfinding?

Post by TradeMark »

Hey, is the pathfinding gonna support threading?

Like one thread for "8" paths, and one for "32" paths, would fasten it up, and would be easy to implement?
User avatar
TheFatController
Balanced Annihilation Developer
Posts: 1177
Joined: 10 Dec 2006, 18:46

Re: Support for multicore in pathfinding?

Post by TheFatController »

I suppose it would be possible to write a lobby feature that used the spring code to generate the pathing file in /paths/ for you in the battle screen using the correct map/mod.

(and of course automatically stop and unlock the file if the game started before it was finished).
User avatar
MadRat
Posts: 532
Joined: 24 Oct 2006, 13:45

Re: Support for multicore in pathfinding?

Post by MadRat »

Would it be easier to delay/prevent spring from launching until its completed the pathing?
User avatar
Snipawolf
Posts: 4357
Joined: 12 Dec 2005, 01:49

Re: Support for multicore in pathfinding?

Post by Snipawolf »

TradeMark wrote:
MadRat wrote:But the purpose of the thread was to talk about what multicores could be tasked with, not the effect it would have if you tried to do the same on a single cpu system.
yeah, i just wanted some use for my 3 other cores, feels a waste.
I compile maps for my friend for Source with the other 3 cores I have. Well, I used to. Now he has a workstation from his dad's work place with two Xeon 3ghz processors.
User avatar
Das Bruce
Posts: 3544
Joined: 23 Nov 2005, 06:16

Re: Support for multicore in pathfinding?

Post by Das Bruce »

imbaczek wrote:yeah, the pathfinder is one of those /* code below is sacred, you must not touch it */ places.

that, and it works, no need to make it faster tbh.
WTF

Now please correct me if I'm wrong but I remember a time in spring when we had dynamic craters! The battle field would become pockmarked, artillery could cause an area to become unsuitable to certain units, it was awesome. The main reason it was removed (and again, correct me if I'm wrong) was because pathfinding was too slow to deal with the changing terrain, causing mass lag.

Some people did like their maps being mushed but that can be changed with hardness and I'm sure some inspired person could limit the amount terrain could move.
User avatar
Peet
Malcontent
Posts: 4384
Joined: 27 Feb 2006, 22:04

Re: Support for multicore in pathfinding?

Post by Peet »

It was only removed modside (BA).
User avatar
NOiZE
Balanced Annihilation Developer
Posts: 3984
Joined: 28 Apr 2005, 19:29

Re: Support for multicore in pathfinding?

Post by NOiZE »

But indeed as reason that it was too slow.
Post Reply

Return to “Feature Requests”