Performance optimization - post your saves

Post all other topics which do not belong to any other category.
Post Reply
orzelek
Smart Inserter
Smart Inserter
Posts: 3911
Joined: Fri Apr 03, 2015 10:20 am
Contact:

Re: Performance optimization - post your saves

Post by orzelek »

MightyMike wrote:that sounds awesome Rseding, that is almost the double of the UPS, so now we have to clean up some belts.
Or wait for effects of belt optimization - should improve it pretty significantly.
Assuming that Rsending doesn't have those in yet.

rich_dick_33
Burner Inserter
Burner Inserter
Posts: 11
Joined: Wed Feb 25, 2015 9:51 pm
Contact:

Re: Performance optimization - post your saves

Post by rich_dick_33 »

I'm getting massive lag in my base when placing rail, i got from 50-55 FPS/UPS down to 2-3 FPS/UPS i have some 300 trains etc
I have lots of mods but i cant see any problem with the mods on the debug screen just get a massive spike in the "waiting for update" that goes from 10-20 up to 300 plus,
Attachments
new start.zip
(21.99 MiB) Downloaded 179 times

User avatar
cpy
Filter Inserter
Filter Inserter
Posts: 839
Joined: Thu Jul 31, 2014 5:34 am
Contact:

Re: Performance optimization - post your saves

Post by cpy »

Anyone posted that sandstorm save video? :D

Bilka
Factorio Staff
Factorio Staff
Posts: 3118
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: Performance optimization - post your saves

Post by Bilka »

Hi,
when mining a lot of tree at the same time (for example by using the upgrade planner (mod)). The game will slow down to about 30 UPS (from 60) until all the little tree bits have fallen to the gound.
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13149
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Performance optimization - post your saves

Post by Rseding91 »

Bilka wrote:Hi,
when mining a lot of tree at the same time (for example by using the upgrade planner (mod)). The game will slow down to about 30 UPS (from 60) until all the little tree bits have fallen to the gound.
I already partially fixed that but it's not completely unavoidable. The little bits falling takes time.
If you want to get ahold of me I'm almost always on Discord.

quinor
Filter Inserter
Filter Inserter
Posts: 404
Joined: Thu Mar 07, 2013 3:07 pm
Contact:

Re: Performance optimization - post your saves

Post by quinor »

Maybye an option to turn particle effects off?

Rseding91
Factorio Staff
Factorio Staff
Posts: 13149
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Performance optimization - post your saves

Post by Rseding91 »

quinor wrote:Maybye an option to turn particle effects off?
If we're going to go that route there's no end. "It's slow when I do X" well yes because it takes CPU time to do *anything*. Don't do anything and it will be instant. You'll also have no game to play.
If you want to get ahold of me I'm almost always on Discord.

Bilka
Factorio Staff
Factorio Staff
Posts: 3118
Joined: Sat Aug 13, 2016 9:20 am
Contact:

Re: Performance optimization - post your saves

Post by Bilka »

Rseding91 wrote:
Bilka wrote:Hi,
when mining a lot of tree at the same time (for example by using the upgrade planner (mod)). The game will slow down to about 30 UPS (from 60) until all the little tree bits have fallen to the gound.
I already partially fixed that but it's not completely unavoidable. The little bits falling takes time.
Thank you for your work! I suspect someone in this thread already mentioned it, but opening the train overview when you have a lot of trains is also pretty slow. Same goes for opening the train inventory with the map and detailed view.
I'm an admin over at https://wiki.factorio.com. Feel free to contact me if there's anything wrong (or right) with it.

quinor
Filter Inserter
Filter Inserter
Posts: 404
Joined: Thu Mar 07, 2013 3:07 pm
Contact:

Re: Performance optimization - post your saves

Post by quinor »

Rseding91 wrote:
quinor wrote:Maybye an option to turn particle effects off?
If we're going to go that route there's no end. "It's slow when I do X" well yes because it takes CPU time to do *anything*. Don't do anything and it will be instant. You'll also have no game to play.

What I mean is, particles are purely graphical effect (or I'm convinced they are) and as for now they often cause massive lag spikes. As for me they're quite similar to clouds or smoke which already have got an option to be turned off, so why not do the same to boost performance on weaker hardware.

posila
Factorio Staff
Factorio Staff
Posts: 5200
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: Performance optimization - post your saves

Post by posila »

quinor wrote:What I mean is, particles are purely graphical effect (or I'm convinced they are) and as for now they often cause massive lag spikes. As for me they're quite similar to clouds or smoke which already have got an option to be turned off, so why not do the same to boost performance on weaker hardware.
I definitely want to make proper particle system one day. Currently, particles are entities as almost everything else (including smoke). If you disable smoke in graphics options, it is just not being rendered, but smoke entities are still created and simulated (even though this was greatly optimized in 0.12).

quinor
Filter Inserter
Filter Inserter
Posts: 404
Joined: Thu Mar 07, 2013 3:07 pm
Contact:

Re: Performance optimization - post your saves

Post by quinor »

That must hurt, posila. You have my sword on the task! Maybye (my wishes) .16?

Daid
Fast Inserter
Fast Inserter
Posts: 163
Joined: Sun Jul 03, 2016 7:42 am
Contact:

Re: Performance optimization - post your saves

Post by Daid »

posila wrote:
quinor wrote:What I mean is, particles are purely graphical effect (or I'm convinced they are) and as for now they often cause massive lag spikes. As for me they're quite similar to clouds or smoke which already have got an option to be turned off, so why not do the same to boost performance on weaker hardware.
I definitely want to make proper particle system one day. Currently, particles are entities as almost everything else (including smoke). If you disable smoke in graphics options, it is just not being rendered, but smoke entities are still created and simulated (even though this was greatly optimized in 0.12).
Still the rendering makes a huge difference on my machine. With smoke on, I get slowdowns as soon as I need 20 steamengines.

As for the particles from trees, a mod could remove those I guess. So if it's a mod that has performance issues with it, that mod could fix it :-)

Rseding91
Factorio Staff
Factorio Staff
Posts: 13149
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Performance optimization - post your saves

Post by Rseding91 »

Daid wrote:
posila wrote:
quinor wrote:What I mean is, particles are purely graphical effect (or I'm convinced they are) and as for now they often cause massive lag spikes. As for me they're quite similar to clouds or smoke which already have got an option to be turned off, so why not do the same to boost performance on weaker hardware.
I definitely want to make proper particle system one day. Currently, particles are entities as almost everything else (including smoke). If you disable smoke in graphics options, it is just not being rendered, but smoke entities are still created and simulated (even though this was greatly optimized in 0.12).
Still the rendering makes a huge difference on my machine. With smoke on, I get slowdowns as soon as I need 20 steamengines.

As for the particles from trees, a mod could remove those I guess. So if it's a mod that has performance issues with it, that mod could fix it :-)
The rendering of smoke makes 2 calls to pow(...) each time a smoke cloud is rendered on screen 60 times per second and that's sloooow. That's the impact you see. The actual rendering of it takes no measurable time after those other calculations are done.
If you want to get ahold of me I'm almost always on Discord.

quinor
Filter Inserter
Filter Inserter
Posts: 404
Joined: Thu Mar 07, 2013 3:07 pm
Contact:

Re: Performance optimization - post your saves

Post by quinor »

Is it something you can possibly cache? What are those pow() calls for?

posila
Factorio Staff
Factorio Staff
Posts: 5200
Joined: Thu Jun 11, 2015 1:35 pm
Contact:

Re: Performance optimization - post your saves

Post by posila »

quinor wrote:Is it something you can possibly cache? What are those pow() calls for?
https://www.factorio.com/blog/post/fff-84

Daid
Fast Inserter
Fast Inserter
Posts: 163
Joined: Sun Jul 03, 2016 7:42 am
Contact:

Re: Performance optimization - post your saves

Post by Daid »

quinor wrote:Is it something you can possibly cache? What are those pow() calls for?
Sounds more like a job for the mighty lookup table...

quinor
Filter Inserter
Filter Inserter
Posts: 404
Joined: Thu Mar 07, 2013 3:07 pm
Contact:

Re: Performance optimization - post your saves

Post by quinor »

Yeah, that's what I meant. Lookup table, not cache :) Anyway, might be a good optimization to do and a reasonably easy one.

Rseding91
Factorio Staff
Factorio Staff
Posts: 13149
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Performance optimization - post your saves

Post by Rseding91 »

Daid wrote:
quinor wrote:Is it something you can possibly cache? What are those pow() calls for?
Sounds more like a job for the mighty lookup table...
A lookup table for all possible values you might call pow(...) with? :P Just how many distinct values are their for the double data type?
If you want to get ahold of me I'm almost always on Discord.

fwyrl
Inserter
Inserter
Posts: 27
Joined: Fri Jul 01, 2016 10:54 pm
Contact:

Re: Performance optimization - post your saves

Post by fwyrl »

I also see an enormous graphical slowdown when doing non-map view of trains and zooming out. Even with only 5 trains, I notice a far larger performance hit than I would expect, even given that it's rendering double the stuff. I go from unflinching 59 (v-sync leaves me at 59 and not 60 for reasons outside my comprehension) to 5-15. On top of that, I even if have the map open, (so it should not - I believe? - be rendering the world where I am), I see no performance difference. Even more interestingly, the complexity (number of items to render) of the scene I switch to does not seem to impact performance. Simply opening the non-map view and zooming out all the way is enough.

Opening advanced information (alt) seems to cause slight frames drop, but this is really only noticeable on slower machines or large factories with thousands of robots.\

Aside from this and expected things like slight slowdown when pathfinding 200+ enemies through a crowded aria (forest), 2k+ robots causing ~10 fps drop, etc.. I'm finding nothing slowing me down over here

Edit: deleted save as it was not useful - an issue I believed it to have turned out empty upon further testing.

Edit 2: I also notice a 20 fps drop when opening production to 50 hours. No UPS drop, but thought I should mention it.

Daid
Fast Inserter
Fast Inserter
Posts: 163
Joined: Sun Jul 03, 2016 7:42 am
Contact:

Re: Performance optimization - post your saves

Post by Daid »

Rseding91 wrote:
Daid wrote:
quinor wrote:Is it something you can possibly cache? What are those pow() calls for?
Sounds more like a job for the mighty lookup table...
A lookup table for all possible values you might call pow(...) with? :P Just how many distinct values are their for the double data type?
You input ranges are most likely limited, as it's a visual effect, your output can be slightly inaccurate. I've done the same for atan2() in a project with great success.

Post Reply

Return to “General discussion”