Support for multi-core processors

The place to request or suggest new ideas and features.
Post Reply
sharahome
Posts: 3
Joined: Mon Sep 19, 2022 8:35 am

Mon Sep 19, 2022 2:04 pm

Please enable multithreading support for processors. The game chokes on one thread of the first processor core. Moreover, the game engines support multithreading.

User avatar
Shidan
Moderator
Posts: 1234
Joined: Mon Oct 22, 2012 1:41 pm

Mon Sep 19, 2022 4:33 pm

The engine does not support multi-threading on the version of the engine they are currently using. They would need to upgrade the engine, which would take insane amounts of developer time, and create tons of issues they'd have to fix.

Not to mention, it was put to a vote in the community years ago now whether to focus on porting Kenshi to a new engine, or work on Kenshi 2 (which is already being made in a new engine), and the community voted overwhelmingly to work on Kenshi 2. So such an undertaking is long since out of the question.

User avatar
Hatsune_Neko
Moderator
Posts: 4086
Joined: Sun Apr 21, 2013 9:59 am
Location: Columbus, OH

Wed Sep 21, 2022 12:02 am

they was gonna update it to Ogre 2.0+, which supported multithreading. but they then changed to Unreal. and started working on porting that, but during that time, another game studio near by gave them an estimate of how long it would take to do so.

to port all assets to Unreal would take at least 6 years. porting with Ogre was not as good as well. from single threaded to multithreaded requires basically an entire game recoding. basically making the game over.

even though i would love for teh Devs to port the engine over, I also don't want them to, as porting would kill every mod made so far.
Do you believe the sexes should be equal?
Oh heavens no.
Then Men would become unmanageable

Current computer specs.
AMD FX-8150 - Eight Core, 3.60GHz
NVidia GTX 1050TI
24GB Corsair Vengeance DDR3 1600 MHz Ram
WD 1tb HD, 870 EVO 1TB SSD

sharahome
Posts: 3
Joined: Mon Sep 19, 2022 8:35 am

Sat Sep 24, 2022 1:51 pm

Then the question arises:
Why port old content to the new OGRE engine when you can adapt the new OGRE engine to see the old content?

User avatar
Hatsune_Neko
Moderator
Posts: 4086
Joined: Sun Apr 21, 2013 9:59 am
Location: Columbus, OH

Sat Sep 24, 2022 11:29 pm

Because doing either would roughly take the same amount of time.
They basically have to make a new game. changing from single threaded to multithreaded is a big programing challenge. and very time consuming. you have to rewrite the entire code.

When considering a piece of code that runs in a single thread, you don’t need to worry about variables changing or the operations being only half done or how to control other threads at all. So we introduce new concepts like locks, memory models and thread controls and priorities and this introduces a whole bunch of new possible problems.
  • When can you exit? Sometimes simply calling exit will cause other unreaped threads to crash as the main thread cleans up before exit.
  • What happens when I take locks in random orders? (deadlocks)
  • When can I guarantee that what one thread wrote to memory is even visible to other threads (surprising answers here).
    Priority inversion when a low priority thread takes a lock and high priority threads wait for them.
  • How does one thread efficiently waiting for events from other threads (maybe condition variables).
  • With all that extra cache, can I design the app to make use of the extra cache. i.e. managing cache/memory affinity. (This can lead to superlinear speedups if done right)
  • New issues around libraries that manage event passing.
  • Surprising sequence of operations, e.g. A callback being called before the function that initiated the callback returns - i.e. All functions that initiate a asynchronous operation must return void.
  • Efficiently incrementing/operating a value (atomic operations).
  • Too many threads can cause the application to run slower. Limiting the number of total threads created and using thread pools to manage thread count.
Just to name a few. Now, all these problems are well researched and good solutions exist for all of them, however, to answer your question, none of these are considered in single threaded programming which is the reason multithreaded programming is harder.

As for content, it has to be changed as well for the multithread coding.
It would be easier to make a new game from the ground up instead.
Do you believe the sexes should be equal?
Oh heavens no.
Then Men would become unmanageable

Current computer specs.
AMD FX-8150 - Eight Core, 3.60GHz
NVidia GTX 1050TI
24GB Corsair Vengeance DDR3 1600 MHz Ram
WD 1tb HD, 870 EVO 1TB SSD

sharahome
Posts: 3
Joined: Mon Sep 19, 2022 8:35 am

Tue Jul 11, 2023 10:29 am

And if you just update the render version to the current one so that the render has support for multithreading?

User avatar
Hatsune_Neko
Moderator
Posts: 4086
Joined: Sun Apr 21, 2013 9:59 am
Location: Columbus, OH

Tue Jul 11, 2023 11:43 pm

sharahome wrote:
Tue Jul 11, 2023 10:29 am
And if you just update the render version to the current one so that the render has support for multithreading?
it requires the entire engine to be replaced and assets redone. which is around a 6 year project.
Do you believe the sexes should be equal?
Oh heavens no.
Then Men would become unmanageable

Current computer specs.
AMD FX-8150 - Eight Core, 3.60GHz
NVidia GTX 1050TI
24GB Corsair Vengeance DDR3 1600 MHz Ram
WD 1tb HD, 870 EVO 1TB SSD

Post Reply
  • Information
  • Who is online

    Users browsing this forum: No registered users and 3 guests