Factorio

Factorio

View Stats:
Raaleth Sep 26, 2020 @ 2:08am
UPS and CPU usage
Hi there,

so I'm running a small megafactory (2k SPM). I seem to be getting UPS issues with it, with UPS dropping to about 45 - 50 at times.

The odd thing is, I noticed that during these slowdowns my CPU use doesn't go beyond 60% or so.

Is there a setting I'm missing, or is the game just designed not to hog 100% CPU?

My config:

Intel i5-7600k
16 GB RAM, 3000 MHz DDR4
GPU: Geforce GTX 1070
The game is installed on an SSD drive.

Example screenshot: https://i.imgur.com/29UNAV4.png

TBH I thought that an i5-7600k would be enough to run a megabase, but turns out I might want to revise that idea.

Thanks in advance for any responses!
Last edited by Raaleth; Sep 26, 2020 @ 2:10am
< >
Showing 1-15 of 31 comments
ShutEye_DK Sep 26, 2020 @ 3:01am 
Factorio can't use all of the 4 cores of your CPU.
I think it uses 2 - and if it does it sounds about right with 60% if 2 cores are at 100%.
Raaleth Sep 26, 2020 @ 3:47am 
Doesn't seem like it, according o both Windows resource monitor and Open Hardware Monitor all four cores are usually utilised at about 50 - 60%.
Might be a cache memory bottleneck, that won't show on windows resource monitor and I doubt many others can show it either. Could be your motherboard or the connection between that and your SSD. Finding the bottleneck can be tricky, and it might not even be Factorio causing the issue but something in the background like windows update.
PunCrathod Sep 26, 2020 @ 7:44am 
The only part of the simulation that is multithreaded in factorio is the fluidpipes.



Originally posted by Raaleth:
Doesn't seem like it, according o both Windows resource monitor and Open Hardware Monitor all four cores are usually utilised at about 50 - 60%.
This is completely normal. A threads can hop from one core to another at any time windows feels like it. And windows likes to use all cores equally. The main simulation thread however can only run on one core at a time. Get a program called process explorer. Right click on factorios process and click properties. Then in the treads tab you can see how much cpu each thread is taking.

Also are you sure your ram is running at 3000mhz. By default every bios sets ram to run at the lowest speed the cpu supports to help compatibility. You can use a program called cpu-z to check what speed your ram is running at.
Raaleth Sep 26, 2020 @ 8:12am 
Originally posted by PunCrathod:
The only part of the simulation that is multithreaded in factorio is the fluidpipes.

(...)
This is completely normal. A threads can hop from one core to another at any time windows feels like it. And windows likes to use all cores equally. The main simulation thread however can only run on one core at a time. Get a program called process explorer. Right click on factorios process and click properties. Then in the treads tab you can see how much cpu each thread is taking.

Also are you sure your ram is running at 3000mhz. By default every bios sets ram to run at the lowest speed the cpu supports to help compatibility. You can use a program called cpu-z to check what speed your ram is running at.
Thanks for the tips.

I installed the software you mentioned. Seems like the main Factorio thread is using about 17% of the CPU (if I'm interpreting the info correctly), the rest use between 0.08 and 2.5%.

Since one core would be 25%, using 17% total of the CPU power on one core would translate into using about 68% of that core.

Does that mean that if I was to look for a CPU for Factorio, I should go with the best single thread performance? I know that games like Cities Skylines and Stellaris also rely primarily on single thread performance, so it'd make sense.

I also checked RAM, it says:

NB Frequency: 3800.00MHz

DRAM frequency: 1067.7 MHz

Not sure what that means, I'd assume 3800.00MHz means it's running at full capacity?

cswiger Sep 26, 2020 @ 8:34am 
"NB Frequency" is the speed of the chipset, the part that connects the memory to the CPU. It normally works at the fastest speed that your CPU can run.

"DRAM Frequency" is the speed that your memory is running at and 1067 MHz means DDR2133. That's above the DDR minimum speed, which is something like 666 MHz / DDR1333, so your machine seems to be using the faster speed. You can check the SPD tab and look for the fastest speed profile listed, likely as "XMP-2133".
Ryan Sep 26, 2020 @ 9:30am 
I'll leave these here since you are interested in how PC hardware affects Factorio performance. They are older posts, but the ideas should still be relevant:

Factorio RAM benchmarks: https://docs.google.com/spreadsheets/d/1-zJqfZ9NpiEAveltOfBoICgT5dTbETb1nz5ZmuySX7A/edit#gid=1699517607
Factorio RAM Timings: https://imgur.com/2FPr3su

Factorio Performance Test: https://www.reddit.com/r/factorio/comments/4h647g/factorio_performance_test_cpuram_based_fpsups/

https://steamcommunity.com/app/427520/discussions/0/1474221865189830016/
Magma Dragoon Sep 26, 2020 @ 12:52pm 
Originally posted by Raaleth:
DRAM frequency: 1067.7 MHz
2133 is the maximum JEDEC speed, you need to enable XMP/DOCP in BIOS.
ShutEye_DK Sep 26, 2020 @ 1:45pm 
Originally posted by Magma Dragoon:
Originally posted by Raaleth:
DRAM frequency: 1067.7 MHz
2133 is the maximum JEDEC speed, you need to enable XMP/DOCP in BIOS.
AFAIK 1067 MHz is the actual frequence - the 2133 is the datarate (MT/s), which is used to name the module. Somewhat confusing :)

EDIT: So OP: Your RAM is not running at 3000 MT/s. Nor at 1500 MHz.
Last edited by ShutEye_DK; Sep 26, 2020 @ 1:47pm
PunCrathod Sep 26, 2020 @ 3:39pm 
Originally posted by ShutEye_DK:
Originally posted by Magma Dragoon:
2133 is the maximum JEDEC speed, you need to enable XMP/DOCP in BIOS.
AFAIK 1067 MHz is the actual frequence - the 2133 is the datarate (MT/s), which is used to name the module. Somewhat confusing :)

EDIT: So OP: Your RAM is not running at 3000 MT/s. Nor at 1500 MHz.
Technically 3000MHz DDR4 is also correct. It's just telling you the frequency of transfer operations.
For further elaboration DDR memory(double data rate memory) can do a memory transfer operation on both rising and falling edges of the clock signal. The marketing is based on the frequency of memory transfer operations while cpu-z reports the frequency of the clock. Thus if you have 3000 mhz DDR4 running at it's marketed speed then cpu-z should say DRAM frequency: 1500.0 MHz

Originally posted by Raaleth:
DRAM frequency: 1067.7 MHz

Yours is saying 1067MHz in cpu-z so your ram is running at 2133MHz.
This is easy to fix in modern bios. When rebooting you press F2 or del(depending on your motherboard model) when the bios is loading to enter the bios menu. Find an option that mentions XMP or extreme memory profile. And turn it on. Or if it gives multiple choices select DDR4 3000MHz. If there is no XMP or extreme memory profile anywhere in the bios then there probably is a DRAM target frequency options somewhere. Depending on the model of the motherboard this can be either the DRAM clock or the frequency of transfer operations. For ddr4 the lowest clock is 800mhz and lowest transfer frequency is 1600mhz. There should also be a current target DRAM frequency indicator somewhere where you can check.

If this sounds too hard then there are plenty of tutorial videos on youtube showing exactly how to do this. There probably are videos for your exact motherboard that show exactly where the right setting is and how to change it to the correct value.

Do note that this will not make your games run 50% faster. It might not make any difference at all.
ShutEye_DK Sep 26, 2020 @ 4:15pm 
Originally posted by PunCrathod:
...
Technically 3000MHz DDR4 is also correct.
...
Well not really. It is just one of those things that, over time, came to be be normal to use.

MHz is the clockspeed of the RAM (in this case 1067 MHz).
MT/s is the transfer rate of the RAM (in this case 2133 MT/s).

I don't know how old you are, but the first DDR SDRAM was not called DDR-200 MHz.
They were just called DDR-200, and had a clockspeed of 100 MHz.
Not trying to be condescending, but I can actually remember when they came out :)

But ...eh... this is getting OT :)
PunCrathod Sep 26, 2020 @ 4:43pm 
Originally posted by ShutEye_DK:
Originally posted by PunCrathod:
...
Technically 3000MHz DDR4 is also correct.
...
Well not really. It is just one of those things that, over time, came to be be normal to use.

MHz is the clockspeed of the RAM (in this case 1067 MHz).
MT/s is the transfer rate of the RAM (in this case 2133 MT/s).

I don't know how old you are, but the first DDR SDRAM was not called DDR-200 MHz.
They were just called DDR-200, and had a clockspeed of 100 MHz.
Not trying to be condescending, but I can actually remember when they came out :)

But ...eh... this is getting OT :)
Hz is just 1/s. So if something can be measured in x/s then it can also be measured in Hz. What why and when is irrelevant.

Edit: Oh and I have a 256kb ddr-200 stick on my table right now from the first computer I ever had so age is not an issue.

Edit edit. Oh and even funnier is that the DRAM frequency does not even refer to the memory clock. It actually refers to the I/O bus clock. For ddr4 the memory clock is actually 200-400 MHz depending on model.
Last edited by PunCrathod; Sep 26, 2020 @ 4:59pm
ShutEye_DK Sep 26, 2020 @ 5:13pm 
Originally posted by PunCrathod:
Originally posted by ShutEye_DK:
Well not really. It is just one of those things that, over time, came to be be normal to use.

MHz is the clockspeed of the RAM (in this case 1067 MHz).
MT/s is the transfer rate of the RAM (in this case 2133 MT/s).

I don't know how old you are, but the first DDR SDRAM was not called DDR-200 MHz.
They were just called DDR-200, and had a clockspeed of 100 MHz.
Not trying to be condescending, but I can actually remember when they came out :)

But ...eh... this is getting OT :)
Hz is just 1/s. So if something can be measured in x/s then it can also be measured in Hz. What why and when is irrelevant.

Edit: Oh and I have a 256kb ddr-200 stick on my table right now from the first computer I ever had so age is not an issue.
Not irrelevant. It brings confusion. Just read this thread.

256KB? The smallest that came out was 64MB (yeah I had to look it up haha :) )
I remember my first PC having a whopping 320MB. That was A LOT at the time.
Magma Dragoon Sep 26, 2020 @ 5:31pm 
OP doesn't need to know the true meaning of MCLK, he needs to select the memory profile that matches the advertised speed and primary timings of his RAM
ShutEye_DK Sep 26, 2020 @ 6:00pm 
Originally posted by Magma Dragoon:
OP doesn't need to know the true meaning of MCLK, he needs to select the memory profile that matches the advertised speed and primary timings of his RAM
Yeah. As I wrote: OT. I'll stop now :)
< >
Showing 1-15 of 31 comments
Per page: 1530 50

Date Posted: Sep 26, 2020 @ 2:08am
Posts: 31