• Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community.

Why are SimCitys cities so small? Because EA didn't make it for multicore CPU's

Joined
Nov 22, 2012
Messages
679 (0.36/day)
Likes
738
System Name Hard Times
Processor X3450@4Ghz
Motherboard Asus P7H55M
Cooling Hyper 212 Evo
Memory 12gb DDR3 1333Mhz CL 9@1600 CL7
Video Card(s) Gigabyte GTX 980 Xtreme@1500Mhz
Storage SanDisk Extreme 120Gb SSD (os) , WD Caviar Blue 2 TB (Games), WD Caviar Green 1TB (Storage)
Display(s) 32" Samsung HDTV 1080P
Case Fractal Design Focus G Mini
Audio Device(s) Onboard HDMI
Power Supply EVGA G2 550w
Software Windows 10 Pro CU
#51
It's 2013, why opt for single threaded when you can get so much more from a multi-threaded engine :shadedshu

If everything can run fine on a single core lets all just go back to semprons shall we? No, I didn't think so.
 
Joined
Jul 30, 2007
Messages
6,560 (1.71/day)
Likes
835
System Name Vintage
Processor i7 - 3770K @ Stock
Cooling Scythe Zipang II
Memory 2x4GB Crucial DDR3
Video Card(s) MSI GTX970
Storage M4 124GB SSD// WD Black 640GB// WD Black 1TB//Samsung F3 1.5TB
Display(s) Samsung SM223BW 21.6"
Case Generic
Power Supply Corsair HX 520W
Software Windows 7
#52
It's 2013, why opt for single threaded when you can get so much more from a multi-threaded engine :shadedshu

If everything can run fine on a single core lets all just go back to semprons shall we? No, I didn't think so.
Blame the developer. And it has yet to be proven that it is going to be an issue.
 
Joined
Nov 22, 2012
Messages
679 (0.36/day)
Likes
738
System Name Hard Times
Processor X3450@4Ghz
Motherboard Asus P7H55M
Cooling Hyper 212 Evo
Memory 12gb DDR3 1333Mhz CL 9@1600 CL7
Video Card(s) Gigabyte GTX 980 Xtreme@1500Mhz
Storage SanDisk Extreme 120Gb SSD (os) , WD Caviar Blue 2 TB (Games), WD Caviar Green 1TB (Storage)
Display(s) 32" Samsung HDTV 1080P
Case Fractal Design Focus G Mini
Audio Device(s) Onboard HDMI
Power Supply EVGA G2 550w
Software Windows 10 Pro CU
#53
Blame the developer. And it has yet to be proven that it is going to be an issue.
I am. Regardless of any possible issues, it's just sheer laziness. End Of.

You can get more out of modern hardware, hell some older games have even been updated along the way to encompass the benefits that multi-threading brings. Valve games and Wow to name just two examples off the top of my head.

It's precisely this "laissez faire" attitude that allows these developers to get away with shoddy work. It's in THEIR hands, not ours.
 
Joined
Jul 30, 2007
Messages
6,560 (1.71/day)
Likes
835
System Name Vintage
Processor i7 - 3770K @ Stock
Cooling Scythe Zipang II
Memory 2x4GB Crucial DDR3
Video Card(s) MSI GTX970
Storage M4 124GB SSD// WD Black 640GB// WD Black 1TB//Samsung F3 1.5TB
Display(s) Samsung SM223BW 21.6"
Case Generic
Power Supply Corsair HX 520W
Software Windows 7
#54
It's SimCity. Did you really expect it to be a masterpiece?
 
Joined
Nov 22, 2012
Messages
679 (0.36/day)
Likes
738
System Name Hard Times
Processor X3450@4Ghz
Motherboard Asus P7H55M
Cooling Hyper 212 Evo
Memory 12gb DDR3 1333Mhz CL 9@1600 CL7
Video Card(s) Gigabyte GTX 980 Xtreme@1500Mhz
Storage SanDisk Extreme 120Gb SSD (os) , WD Caviar Blue 2 TB (Games), WD Caviar Green 1TB (Storage)
Display(s) 32" Samsung HDTV 1080P
Case Fractal Design Focus G Mini
Audio Device(s) Onboard HDMI
Power Supply EVGA G2 550w
Software Windows 10 Pro CU
#55
It's SimCity. Did you really expect it to be a masterpiece?
Actually, if they put time and thought into the game, the right resources and utilized modern hardware. Yes, it could be. Any game could be when done right, just look at minecraft?
 

newtekie1

Semi-Retired Folder
Joined
Nov 22, 2005
Messages
24,416 (5.50/day)
Likes
10,550
Location
Indiana, USA
Processor Intel Core i7 8700K@4.8GHz(Quick and dirty)
Motherboard AsRock Z370 Taichi
Cooling Corsair H110i GTX
Memory 32GB Corsair DDR4-3000
Video Card(s) PNY XLR8 GTX1060 6GB
Storage 480GB Crucial MX200 + 2TB Seagate Solid State Hybrid Drive with 128GB OCZ Synapse SSD Cache
Display(s) QNIX QX2710 1440p@120Hz
Case Fractal Design Define S
Audio Device(s) Onboard is good enough for me
Power Supply Corsair HX850
Software Windows 10 Pro x64
#56
It's 2013, why opt for single threaded when you can get so much more from a multi-threaded engine :shadedshu

If everything can run fine on a single core lets all just go back to semprons shall we? No, I didn't think so.
You keep saying they could get so much more from a multi-threaded engine, but the fact is they couldn't. The engine is graphically limited, not CPU limited, so the added development cost to make the engine multi-threaded would be wasted.

Any game could be when done right, just look at minecraft?

Minecraft is single threaded...:rolleyes:
 

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
21,066 (6.22/day)
Likes
10,191
Location
IA, USA
System Name BY-2015
Processor Intel Core i7-6700K (4 x 4.00 GHz) w/ HT and Turbo on
Motherboard MSI Z170A GAMING M7
Cooling Scythe Kotetsu
Memory 2 x Kingston HyperX DDR4-2133 8 GiB
Video Card(s) PowerColor PCS+ 390 8 GiB DVI + HDMI
Storage Crucial MX300 275 GB, Seagate 6 TB 7200 RPM
Display(s) Samsung SyncMaster T240 24" LCD (1920x1200 HDMI) + Samsung SyncMaster 906BW 19" LCD (1440x900 DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay
Audio Device(s) Realtek Onboard, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse SteelSeries Sensei RAW
Keyboard Tesoro Excalibur
Software Windows 10 Pro 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
#57
Minecraft is very poorly executed (pathetic frame rates for how little there is to render), mostly runs on a single thread, and is CPU dependent when windowed.
 

de.das.dude

Pro Indian Modder
Joined
Jun 13, 2010
Messages
8,203 (2.95/day)
Likes
2,394
Location
Pune
System Name la de da... | Samsung NP355V5C-S05IN
Processor FX 8320 | AMD A8-4500
Motherboard ASRock 990FX Extreme 4 | Samsung something something
Cooling CM Hyper 212 EVO push:pull+ 1 panaflow 113CFM + 2 x 120mm NZXTs | Coolermaster Notepal
Memory 2x4GB DDR3 Corsair Vengeance 1600MHz CL9 | Samsunng 4GB + 2GB DDR3 1600MHz
Video Card(s) AMD 7790 GHZ edition! | 7670M + 7640G
Storage 1TB WD10EZEX | W.D 500GB Green AADS | Samsung 1TB
Display(s) dell S2240l 1080p IPS 21.5" | Samsung antiglare 15.6"
Case NZXT Guardian 921RB(@home) and Antec ASK4000B U3(Current)
Audio Device(s) Realtek ALC892 with THX True Studio | Realtek something
Power Supply Corsair GS600 | 90W Brick, 6 cell 48000mAh battery
Mouse Logitech G400, GOD TIER MOUSE!! LOGitech F310 gamepad!
Keyboard Logitech K200
Software Windows 8.1 x64 | Windows 8.1 x64
Benchmark Scores real men do bench presses not bench marks.
#58
so EA is in ties with intel, and they too are hellbent on destroying AMD


EA sucks anyways, their stuff is consumer vomit.
 
Joined
Aug 10, 2007
Messages
4,064 (1.06/day)
Likes
1,130
Location
Geneva, FL, USA
Processor Intel i5-6600
Motherboard ASRock H170M-ITX
Cooling Cooler Master Geminii S524
Memory G.Skill DDR4-2133 16GB (8GB x 2)
Video Card(s) Gigabyte R9-380X 4GB
Storage Samsung 950 EVO 250GB (mSATA)
Display(s) LG 29UM69G-B 2560x1080 IPS
Case Lian Li PC-Q25
Audio Device(s) Realtek ALC892
Power Supply Seasonic SS-460FL2
Mouse Logitech G700s
Keyboard Logitech G110
Software Windows 10 Pro
#59
EA sucks anyways, their stuff is consumer vomit.
EA did alright with SC4, but's that largely because Maxis was one of their slow-to-absorb divisions (like being thrown into a sarlacc). There was just enough of that Maxis spirit left in 2001-2003 to make a decent enough sequel. Today, they're just another soulless code factory under the control of Evil Ambition. SC5 is clear evidence of this, being more of an upgrade to Farmville than a true sequel advancing the series.
 
Joined
Nov 22, 2012
Messages
679 (0.36/day)
Likes
738
System Name Hard Times
Processor X3450@4Ghz
Motherboard Asus P7H55M
Cooling Hyper 212 Evo
Memory 12gb DDR3 1333Mhz CL 9@1600 CL7
Video Card(s) Gigabyte GTX 980 Xtreme@1500Mhz
Storage SanDisk Extreme 120Gb SSD (os) , WD Caviar Blue 2 TB (Games), WD Caviar Green 1TB (Storage)
Display(s) 32" Samsung HDTV 1080P
Case Fractal Design Focus G Mini
Audio Device(s) Onboard HDMI
Power Supply EVGA G2 550w
Software Windows 10 Pro CU
#60
You keep saying they could get so much more from a multi-threaded engine, but the fact is they couldn't. The engine is graphically limited, not CPU limited, so the added development cost to make the engine multi-threaded would be wasted.




Minecraft is single threaded...:rolleyes:
Ha HA :laugh: That shows me :D

It's amazing what you can do with a single thread lol Although Ford says it runs poorly so surely that backups the point .... :confused:
 
Last edited:

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
21,066 (6.22/day)
Likes
10,191
Location
IA, USA
System Name BY-2015
Processor Intel Core i7-6700K (4 x 4.00 GHz) w/ HT and Turbo on
Motherboard MSI Z170A GAMING M7
Cooling Scythe Kotetsu
Memory 2 x Kingston HyperX DDR4-2133 8 GiB
Video Card(s) PowerColor PCS+ 390 8 GiB DVI + HDMI
Storage Crucial MX300 275 GB, Seagate 6 TB 7200 RPM
Display(s) Samsung SyncMaster T240 24" LCD (1920x1200 HDMI) + Samsung SyncMaster 906BW 19" LCD (1440x900 DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay
Audio Device(s) Realtek Onboard, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse SteelSeries Sensei RAW
Keyboard Tesoro Excalibur
Software Windows 10 Pro 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
#61
This thread isn't about Minecraft but, case in point: just standing still with my system (in the specs), the FPS is 50-93 and ~45 while moving. Using water to harvest about 500 worth of a crop will drop it to 19 FPS. My server, which has dual Xeon E5310 quad core processors and a HD 5570 gets 20-30 FPS standing still and ~20 FPS moving (constant dips into the single digits). With BOINC running 100% on both systems, the FPS drops by about half.
 
Last edited:
Joined
Jun 6, 2012
Messages
514 (0.25/day)
Likes
168
Processor Intel Core 2 QX6850
Motherboard ABIT AB9 Pro
Cooling Zalman CNPS-9900 MAX-R
Memory Patriot PDC24G6400LLK (4x 2 GB)
Video Card(s) Palit GeForce GTX 560 Ti Twin Light Turbo
Storage Not Enough!
Display(s) Samsung T240HD
Case NZXT Zero
Audio Device(s) Creative Labs Sound Blaster X-Fi Elite Pro
Power Supply Thortech Thunderbolt Plus TTBPK00G 1000W
Mouse Logitech G600
Keyboard CM Storm Trigger (Cherry MX Brown)
Software NOT Windows 10
#62
EA did alright with SC4, but's that largely because Maxis was one of their slow-to-absorb divisions (like being thrown into a sarlacc). There was just enough of that Maxis spirit left in 2001-2003 to make a decent enough sequel. Today, they're just another soulless code factory under the control of Evil Ambition. SC5 is clear evidence of this, being more of an upgrade to Farmville than a true sequel advancing the series.
I can see why the devs went for the two-core approach; quad-cores became mainstream not too long ago and they're trying to broaden their potential target market (people who will run the game on their 2008 Core 2 Duo systems). It's understandable, so I'm not too upset about that. I'd more worried about general crappy programing. The Sims 3 has a notorious issue involving the lack of a frame rate limit despite the game engine not being able to render more than 30 FPS. This meant GPUs needlessly thrashing to render the game at 120+ FPS despite the fact that most frames would be identical. Thank the gods there was a mod for that. Great way to kill a GPU though. :shadedshu

I think the other reason for making SimCity 2013 smaller was to keep it from being too complex. SimCity 4 was great and all, but the devs (Will Wright himself included) were worried that SimCity 4 had begun to become too complex and that it was alienating potential newcomers. I guess the whole interconnecting cities thing was a bit too much.

We all know the result of that was SimCity Societies. It went too much in the other direction. The game would've been alright if it didn't have to live up to the SimCity name and wasn't marred by programing inefficiencies that made it more demanding than Crysis.
 

Bo$$

Lab Extraordinaire
Joined
May 7, 2009
Messages
5,626 (1.77/day)
Likes
971
Location
London, UK
System Name Desktop | Server
Processor Intel i7 2700k @ 4.4GHZ | AMD 5350 @ 2500MHZ
Motherboard Asus P7Z77-V Pro | Asus AM1I-A
Cooling GeLID Tranquilo | Stock Air
Memory Crucial Ballistix 2x8GB CL8 1600MHZ | Corsair Vengence 2x4GB CL9 1600MHZ
Video Card(s) Gainward GTX 780 Phantom GLH | PNY GTX 750Ti
Storage Samsung 840 EVO 250GB + 4TB WD Red | 2x Seagate Barracuda 2TB
Display(s) Samsung S27D390H + Asus VE276Q | Headless
Case Fractal Design R5 | CM Elite 110
Audio Device(s) Asus Xonar D1 w/Otone Stilo 5.1 and Creative Fatal1ty headset
Power Supply EVGA Supernova 850 G2| Corsair CX430M
Mouse Razer Imperator 2012
Keyboard Corsair K90
Software Windows 7 SP1 X64 | Ubuntu 16.04LTS
#63
I played the beta, it intrigued me, i've never played SimCity. only city builder i've played was Caesar III. From my experience it was quite pleasurable and seemed easy to get into. I must say it was an oversight to leave it single threaded but to make it highly paralleled would have made it perform worse on some other configurations. I think they didn't really know their target market and TBH it looks pretty good, those who want to play it, buckle up, for the rest just stick to the old versions and be happy
 

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
21,066 (6.22/day)
Likes
10,191
Location
IA, USA
System Name BY-2015
Processor Intel Core i7-6700K (4 x 4.00 GHz) w/ HT and Turbo on
Motherboard MSI Z170A GAMING M7
Cooling Scythe Kotetsu
Memory 2 x Kingston HyperX DDR4-2133 8 GiB
Video Card(s) PowerColor PCS+ 390 8 GiB DVI + HDMI
Storage Crucial MX300 275 GB, Seagate 6 TB 7200 RPM
Display(s) Samsung SyncMaster T240 24" LCD (1920x1200 HDMI) + Samsung SyncMaster 906BW 19" LCD (1440x900 DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay
Audio Device(s) Realtek Onboard, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse SteelSeries Sensei RAW
Keyboard Tesoro Excalibur
Software Windows 10 Pro 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
#64
I guess the whole interconnecting cities thing was a bit too much.
No, it was the micromanagement required to balance the budget. You'd have to adjust range of service buildings as well as their budget to match the requirements of the facility (e.g. make schools only be funded enough to handle all the kids).

SimCity 4 was substantially harder to turn a profit than any of the previous games. It really didn't add much (except U Drive) to the SimCity 3000 formula.


We all know the result of that was SimCity Societies. It went too much in the other direction. The game would've been alright if it didn't have to live up to the SimCity name and wasn't marred by programing inefficiencies that made it more demanding than Crysis.
SimCity Societies was the SimVille idea expanded--a merger of SimCity and The Sims (Will Wright always wanted to do that). SimCity 5 is the spiritual successor to SimCity Societies but going back to the original SimCity formula where you zone and demand builds as opposed to building most buildings yourself.

SimCity Societies wasn't demanding at all on hardware.
 
Joined
Feb 18, 2010
Messages
1,721 (0.59/day)
Likes
415
System Name Eldritch
Processor AMD Ryzen 5 1500X
Motherboard MSI B350 PC Mate
Cooling Satan's butthole after going to Taco Bell
Memory 16 GB G.Skill FlareX
Video Card(s) nVidia (Gigabyte) GT 740 2GB
Storage 80 GB IBM, 2 TB WD Green, 512 GB Samsung 960 Pro
Display(s) Dell 2007WFP
Software Debian Buster
#65
I must say it was an oversight to leave it single threaded but to make it highly paralleled would have made it perform worse on some other configurations.
Oh hardly, with clever use of arrays and thread-local storage the game would never have to touch a mutex.

And before Ford tries to jump on me, consider this:
Code:
for (uint64_t i = currentthreadid; i < whateverarraycount; i += numberofthreads){
    dosomething(whateverarray[i]);}
 
Last edited:

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
21,066 (6.22/day)
Likes
10,191
Location
IA, USA
System Name BY-2015
Processor Intel Core i7-6700K (4 x 4.00 GHz) w/ HT and Turbo on
Motherboard MSI Z170A GAMING M7
Cooling Scythe Kotetsu
Memory 2 x Kingston HyperX DDR4-2133 8 GiB
Video Card(s) PowerColor PCS+ 390 8 GiB DVI + HDMI
Storage Crucial MX300 275 GB, Seagate 6 TB 7200 RPM
Display(s) Samsung SyncMaster T240 24" LCD (1920x1200 HDMI) + Samsung SyncMaster 906BW 19" LCD (1440x900 DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay
Audio Device(s) Realtek Onboard, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse SteelSeries Sensei RAW
Keyboard Tesoro Excalibur
Software Windows 10 Pro 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
Joined
Feb 18, 2010
Messages
1,721 (0.59/day)
Likes
415
System Name Eldritch
Processor AMD Ryzen 5 1500X
Motherboard MSI B350 PC Mate
Cooling Satan's butthole after going to Taco Bell
Memory 16 GB G.Skill FlareX
Video Card(s) nVidia (Gigabyte) GT 740 2GB
Storage 80 GB IBM, 2 TB WD Green, 512 GB Samsung 960 Pro
Display(s) Dell 2007WFP
Software Debian Buster
#67
Except that no two threads would ever touch the same object in whateverarray (maybe I should put that in somewhere, I'll go edit it).
 

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
21,066 (6.22/day)
Likes
10,191
Location
IA, USA
System Name BY-2015
Processor Intel Core i7-6700K (4 x 4.00 GHz) w/ HT and Turbo on
Motherboard MSI Z170A GAMING M7
Cooling Scythe Kotetsu
Memory 2 x Kingston HyperX DDR4-2133 8 GiB
Video Card(s) PowerColor PCS+ 390 8 GiB DVI + HDMI
Storage Crucial MX300 275 GB, Seagate 6 TB 7200 RPM
Display(s) Samsung SyncMaster T240 24" LCD (1920x1200 HDMI) + Samsung SyncMaster 906BW 19" LCD (1440x900 DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay
Audio Device(s) Realtek Onboard, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse SteelSeries Sensei RAW
Keyboard Tesoro Excalibur
Software Windows 10 Pro 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
#68
If "whateverarray" was your entities, you basically just bottlenecked the entire game whenever a single entity requires a big update.

The array itself is liable to create cross-thread reference issues (two threads try to modify the same element simutaneously and the application implodes).

Additionally, to be synchronized, "dosomething" needs to check a global state and update it notifying all other related threads that is busy or ready. Even when doing synchronized, it's only as fast as the slowest thread.
 
Joined
Feb 18, 2010
Messages
1,721 (0.59/day)
Likes
415
System Name Eldritch
Processor AMD Ryzen 5 1500X
Motherboard MSI B350 PC Mate
Cooling Satan's butthole after going to Taco Bell
Memory 16 GB G.Skill FlareX
Video Card(s) nVidia (Gigabyte) GT 740 2GB
Storage 80 GB IBM, 2 TB WD Green, 512 GB Samsung 960 Pro
Display(s) Dell 2007WFP
Software Debian Buster
#69
Yes, slowest thread and weakest link and all that, but having a single thread do everything and the big update on the one entity would never be faster.

And if you'd look at my code snippet you'd know that no two threads would ever touch the same object in the array. currentthreadid is the sequence that the thread is created in (0, 1, 2, 3, etc.), as long as no thread's currentthreadid is above numberofthreads they will never touch.

And, yes, if it needs to check or mess with a global, then sure, you might need a mutex, but there are even ways around that.
 
Last edited:

FordGT90Concept

"I go fast!1!11!1!"
Joined
Oct 13, 2008
Messages
21,066 (6.22/day)
Likes
10,191
Location
IA, USA
System Name BY-2015
Processor Intel Core i7-6700K (4 x 4.00 GHz) w/ HT and Turbo on
Motherboard MSI Z170A GAMING M7
Cooling Scythe Kotetsu
Memory 2 x Kingston HyperX DDR4-2133 8 GiB
Video Card(s) PowerColor PCS+ 390 8 GiB DVI + HDMI
Storage Crucial MX300 275 GB, Seagate 6 TB 7200 RPM
Display(s) Samsung SyncMaster T240 24" LCD (1920x1200 HDMI) + Samsung SyncMaster 906BW 19" LCD (1440x900 DVI)
Case Coolermaster HAF 932 w/ USB 3.0 5.25" bay
Audio Device(s) Realtek Onboard, Micca OriGen+
Power Supply Enermax Platimax 850w
Mouse SteelSeries Sensei RAW
Keyboard Tesoro Excalibur
Software Windows 10 Pro 64-bit
Benchmark Scores Faster than the tortoise; slower than the hare.
#70
At the end of the day, all x86 processors are procedural and that's its greatest weakness. Specific things have to be done in a specific order in order for the next task to be completed. Your example completely lacks context and only multithreads one task. Dozens of tasks have to be completed every game tick and many of them can't be completed until something else is completed first.

In your example, the primary weakness is "whateverarray." It needs to be populated and/or updated and that is happening in the main thread before any multithreading relative to it even begins. Preparing to multithread can take more time than the actual mulithtreaded task.


Case in point, updating the "agents" are likely to be the biggest burden on the CPU. It can't be multithreaded the way you described because agents interact with each other. For example, agent a driving in a car behind agent b can't move ahead of agent b until agent b updates. When you have a hundred cars in a traffic jam, you have to update them in order from the first car which is looking for a way out of the jam to the last car that can't do anything this tick except notify the user that there's a problem. You can't update the last car until you know all cars in front of it aren't moving. No amount of multithreading is going to fix that.

I'm sure the game thread is idle most of the time except when dealing with user inputs so the simulating of the agents are going to be a bulk of the processing load and there's no reason to separate it.
 
Last edited:
Joined
Feb 18, 2010
Messages
1,721 (0.59/day)
Likes
415
System Name Eldritch
Processor AMD Ryzen 5 1500X
Motherboard MSI B350 PC Mate
Cooling Satan's butthole after going to Taco Bell
Memory 16 GB G.Skill FlareX
Video Card(s) nVidia (Gigabyte) GT 740 2GB
Storage 80 GB IBM, 2 TB WD Green, 512 GB Samsung 960 Pro
Display(s) Dell 2007WFP
Software Debian Buster
#71
At the end of the day, all x86 processors are procedural and that's its greatest weakness. Specific things have to be done in a specific order in order for the next task to be completed. Your example completely lacks context and only multithreads one task. Dozens of tasks have to be completed every game tick and many of them can't be completed until something else is completed first.
So put in stages, have all the threads work on an array of whatevers and then wait for them all to be done and then work on array of whateverelses.

In your example, the primary weakness is "whateverarray." It needs to be populated and/or updated and that is happening in the main thread before any multithreading relative to it even begins. Preparing to multithread can take more time than the actual mulithtreaded task.
Are you telling me that they aren't already in an array? How are they stored, as global or local variables?

Case in point, updating the "agents" are likely to be the biggest burden on the CPU. It can't be multithreaded the way you described because agents interact with each other. For example, agent a driving in a car behind agent b can't move ahead of agent b until agent b updates. When you have a hundred cars in a traffic jam, you have to update them in order from the first car which is looking for a way out of the jam to the last car that can't do anything this tick except notify the user that there's a problem. You can't update the last car until you know all cars in front of it aren't moving. No amount of multithreading is going to fix that.
Doing it sequentially is not better, you still have to figure out which agents are going to exit the road soonest (in order to have a decent sequential chain that will leave space for the ones behind it), except that you can account for agents that are about to exit 4 or 6 or 8 roads instead of one at a time. At worst (at intersections where you have a choice, probably) you will have to wait for at least the one choice you want to open up, but even then if your chain-building part is decent enough you'll never have to worry about that either.

I'm sure the game thread is idle most of the time except when dealing with user inputs so the simulating of the agents are going to be a bulk of the processing load and there's no reason to separate it.
Or you could just not seperate it.
 

lyndonguitar

I play games
Joined
Apr 1, 2010
Messages
1,865 (0.65/day)
Likes
524
Location
Philippines
System Name X6 | Lyndon-ROG
Processor Intel Core i7-8700k | Intel Core i7 6700HQ
Motherboard Gigabyte Z370 Aorus Gaming 5 | Asus ROG-GL552VX
Cooling Deepcool Captain 240EX
Memory 16GB Corsair Vengeance LED | 8 GB
Video Card(s) NVIDIA GTX 1080 8 GB GDDR5X | NVIDIA GeForce GTX 950M 4GB
Storage SSDs: 500GB, HDDs: 2TB, 2TB, 3TB | SSD: 250GB, HDD: 1TB
Display(s) BenQ XL2411 1080p@144Hz, 32" HDTV, 19" Monitor | 15.6"1080p
Case Cougar Panzer Max
Audio Device(s) Corsair Gaming H1500 7.1 | ROCCAT Kave 5.1 | Edifier M3200
Power Supply EVGA 750GQ
Mouse Razer Deathadder Chroma | Logitech G302 | Mad Catz Cyborg R.A.T. 5
Keyboard Corsair Vengeance K70 Cherry MX Red
Software Windows 10
#72
It may not be a big performance issue, but we could sure use more and maximize the performance, as almost everyone have multicore cpus now.

For small-normal sized cities it will be smooth, but c'mon its a sandbox game, a City Building game! the hardware should be the bottleneck not the software. :shadedshu
 

Aquinus

Resident Wat-man
Joined
Jan 28, 2012
Messages
10,515 (4.81/day)
Likes
5,597
Location
Concord, NH
System Name Kratos
Processor Intel Core i7 3930k @ 4.2Ghz
Motherboard ASUS P9X79 Deluxe
Cooling Zalman CPNS9900MAX 130mm
Memory G.Skill DDR3-2133, 16gb (4x4gb) @ 9-11-10-28-108-1T 1.65v
Video Card(s) MSI AMD Radeon R9 390 GAMING 8GB @ PCI-E 3.0
Storage 2x120Gb SATA3 Corsair Force GT Raid-0, 4x1Tb RAID-5, 1x500GB
Display(s) 1x LG 27UD69P (4k), 2x Dell S2340M (1080p)
Case Antec 1200
Audio Device(s) Onboard Realtek® ALC898 8-Channel High Definition Audio
Power Supply Seasonic 1000-watt 80 PLUS Platinum
Mouse Logitech G602
Keyboard Rosewill RK-9100
Software Ubuntu 17.10
Benchmark Scores Benchmarks aren't everything.
#73
So put in stages, have all the threads work on an array of whatevers and then wait for them all to be done and then work on array of whateverelses.
You make it sounds like everything can run in parallel and that there are no interdependence between threads. If two things depend on one thing, then a mutex and locking would very much be necessary. I suspect a lot of things are shared and that programming this to be multi-threaded might not result in the benefits you're looking for.

Are you telling me that they aren't already in an array? How are they stored, as global or local variables?
I'm saying that we don't know how they're stored and you can't make the assumptions you're making right now about the code, even more so when it's something that's closed source. It very well could be harder to implement multi-threading than you think. In fact it probably is.

Doing it sequentially is not better, you still have to figure out which agents are going to exit the road soonest (in order to have a decent sequential chain that will leave space for the ones behind it), except that you can account for agents that are about to exit 4 or 6 or 8 roads instead of one at a time. At worst (at intersections where you have a choice, probably) you will have to wait for at least the one choice you want to open up, but even then if your chain-building part is decent enough you'll never have to worry about that either.
It's faster depending on the set of data, but I think at this point you're spewing out bulls**t unless your a Maxis developer. In the case you are, I can blame you for potentially poor design decisions and if you aren't, I can blame you for talking about something you know nothing about.

Or you could just not seperate it.
I'm sure that the developers at EA didn't introduce more multi-threading (if you read that twitter post, it DOES NOT say that it isn't multi-threaded, it only says the sim and game-loop aren't, which means audio and rendering could be). So I would stop guessing and get your panties out of a bunch because anyone who isn't a Maxis developer isn't going to know for sure. Also unless performance was an issue, i wouldn't make a task multi-threaded unless I really benefited from it. We don't know if it will be a bottleneck so its a poor decision to just instantly assume that it will because you don't know what is happening with the game while it was in development.
 
Last edited:
Joined
Apr 12, 2010
Messages
1,261 (0.44/day)
Likes
328
Processor Core i7 920
Motherboard Asus P6T v2
Cooling Noctua D-14
Memory OCZ Gold 1600
Video Card(s) Powercolor PCS+ 5870
Storage Samsung SpinPoint F3 1 TB
Display(s) Samsung LE-B530 37" TV
Case Lian Li PC-B25F
Audio Device(s) N/A
Power Supply Thermaltake Toughpower 700w
Software Windows 7 64-bit
#74
Joined
Aug 10, 2007
Messages
4,064 (1.06/day)
Likes
1,130
Location
Geneva, FL, USA
Processor Intel i5-6600
Motherboard ASRock H170M-ITX
Cooling Cooler Master Geminii S524
Memory G.Skill DDR4-2133 16GB (8GB x 2)
Video Card(s) Gigabyte R9-380X 4GB
Storage Samsung 950 EVO 250GB (mSATA)
Display(s) LG 29UM69G-B 2560x1080 IPS
Case Lian Li PC-Q25
Audio Device(s) Realtek ALC892
Power Supply Seasonic SS-460FL2
Mouse Logitech G700s
Keyboard Logitech G110
Software Windows 10 Pro
#75
I can see why the devs went for the two-core approach; quad-cores became mainstream not too long ago and they're trying to broaden their potential target market (people who will run the game on their 2008 Core 2 Duo systems). It's understandable, so I'm not too upset about that. I'd more worried about general crappy programing. The Sims 3 has a notorious issue involving the lack of a frame rate limit despite the game engine not being able to render more than 30 FPS. This meant GPUs needlessly thrashing to render the game at 120+ FPS despite the fact that most frames would be identical. Thank the gods there was a mod for that. Great way to kill a GPU though. :shadedshu



I think the other reason for making SimCity 2013 smaller was to keep it from being too complex. SimCity 4 was great and all, but the devs (Will Wright himself included) were worried that SimCity 4 had begun to become too complex and that it was alienating potential newcomers. I guess the whole interconnecting cities thing was a bit too much.

We all know the result of that was SimCity Societies. It went too much in the other direction. The game would've been alright if it didn't have to live up to the SimCity name and wasn't marred by programing inefficiencies that made it more demanding than Crysis.
Oh, I know. Like my first post touched upon, they could make a game that scales (both in the technical and gameplay sense), but there's not enough Simcity diehards to make it worth it. Besides, if they put out a game as deep as the previous ones where cities are built over weeks and sometimes months, then other EA titles aren't getting bought. So there's financial incentive to nerf Simcity.