Page 1 of 1

Single core?

Posted: Thu Jan 26, 2017 6:12 pm
by Nich
Why is factorio required to run on a single core? I have been looking into the depths of the of the fourms the past week and I can not seem to see why.

From what I have picked up every thing in factorio is an object. Ore, parts, buildings, (individual bullets or maybe just the clips with a bullets attribute)

The argument I have heard is that because it is a simulation everything must be processed in order. I.E

If you have 3 belts A, B, and C. B can not know its input until it has A's output and same for C.


However this is thinking about the problem completely backwards. Every object has a buffer and knows what it is going to do so outputs can be calculated in parallel. Then once all the outputs are known all the inputs can be calculated in parallel. This will however cause a 1/60th delay in an assembler starting after the first time it has received product because it will not be processed until the output has already been processed but this can be accounted for by decreasing the build time by 1/60th of a second

Re: Single core?

Posted: Thu Jan 26, 2017 7:36 pm
by Yoyobuae
Nich wrote:However this is thinking about the problem completely backwards. Every object has a buffer and knows what it is going to do so outputs can be calculated in parallel. Then once all the outputs are known all the inputs can be calculated in parallel. This will however cause a 1/60th delay in an assembler starting after the first time it has received product because it will not be processed until the output has already been processed but this can be accounted for by decreasing the build time by 1/60th of a second
There's also belts, and bots, and inserters, liquids in pipes/pumps and there's circuit network, and logistic network... Before you know it takes several seconds for one part of the factory to react to something that happens on the other side of the factory.

The way it is now everything reacts instantly (within the same tick).

Re: Single core?

Posted: Fri Jan 27, 2017 12:05 am
by d4rkpl4y3r
viewtopic.php?f=5&t=39893&start=60#p238247

Read that to get insight into parallelism in factorio and how it doesn't really help.