Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2 3 4

Author Topic: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)  (Read 8240 times)

juxari

  • Bay Watcher
    • View Profile

Hello everyone! I know this has been discussed before, but this will be my personal attempt to combat the issue and I will report my results in this topic.

The purpose of this topic is to test and find out the most effective way to play Dwarf Fort FPS wise. It's for both high and low end computer users, as to me it seems even the best computers face FPS death eventually, at least if the forts are not managed correctly.

I will use some unorthodox methods to eliminate FPS, including creating stone or metal from thin air instead of mining it to avoid the decreased FPS from mined out areas, and quatum stockpiling. Pretty much everything it takes to make a sustainable fortress design completely focused to be as great, big, and impressive as possible while trying to eliminate all the controllable sources of decreasing FPS.

If there is ANYONE here who DOES NOT get FPS death, please tell me the specs of your computer and how complex fortresses you are building. The fortresses immune to FPS death that are interesting regarding this topic are the ones as massive as possible (allowing people to have as much grandiosity as possible in their fortress design), spreading across the map and to the core of the earth. In other words, just how big fortress (both population and construction wise) are you able to build without FPS death and what are your computer specs? And have you tested this fortress design to be actually sustainable for a long in game time?

Personally I have been playing this great game since 2006 but the problem is every time I truly get addicted I for my misery find out that Dwarf Fortress is just too intense for my current computer. Every time I have gotten a new computer I sooner or later get the latest version of DF again though and get again addicted. Unfortunately to this date I have not been able to run DF to my complete satisfaction because the inevitable FPS death always claimed my mega projects and great citadels.

For reference, my newest computer is a pretty decent gaming laptop, as far as such things exist, with the following specs: i7-4700MQ (3.2 GHz when overclocking during DF), 8 GB RAM, AMD HD8970M for GPU). Unfortunately even with this setup my recent project also faced the FPS death although I managed to develop it further than ever before, to become a quite impressive 70 year old fortress with very complex magma moats, tree and obsidian farms, complex channel systems (while FPS drain from flowing liquids was minimized) and pretty much almost every cool thing that came to my mind. But unfortunately it was completely unplayable due to FPS of 20 to below 10 in the end.

Let's get to the point then, how to eliminate/Minimize the FPS Death.

What we know about FPS death? (borrowed from the great research of previous topics I have seen here)
- Creating objects decreases FPS, destroying objects helps to improve FPS at least after save/reload
- Mined out space decreases FPS, apparently even if sealed off later on.
- Path finding decreases FPS
- Large stockpiles are bad for FPS
- Dead creatures apparently stay in the games memory forever, possibly having the potential of affecting FPS forever. However, just how many dead becomes an issue I do not know so whether this truly is an issue in the long run is unknown. In DF mass death resulting from invasions of hundreds of enemies is in my opinion one of the better parts of the game and hopefully we do not need to turn invasions off.

Unknown effect on FPS (at least to me personally), BUT VERY IMPORTANT:
-Do constructions (walls, fortifications etc.) decrease FPS? Especially if above ground. Could we compensate the lack of mined out space below ground with impressive above ground citadels?

Methods to decrease FPS:
- I will be using the accelerated DF mod, as it promises an estimated FPS increase of around 25%. The trade off is losing some gem and stone types, but the core gameplay is unchanged.
- I will use modding to create a workshop that can create metal, stone, and gems without mining. This is to eliminate the FPS decrease from mined out areas. This is of course cheating, but it is probably necessary to keep the fortress immune to FPS death. Anything to keep the fort running smoothly.
- I will use quatum stockpiling in some cases to eliminate the FPS decrease from large stockpiles. I'm quite sure that not all stockpiles should be quatum stockpiles, however (plant stockpiles for example). I will experiment with my designs later on.
- It is necessary to create as few objects as possible at all times. It for example probably doesn't make sense to create more than 2 years worth of supplies of drink and prepared meals or too much clothing and armor etc.
- Path finding will be optimized with traffic zone allocation while the fortress is constructed. And it's a pain to do it afterwards for a large fort anyway.
- Excess items will be destroyed by manual dumping and atom smashing as this is apparently the best way to get rid of them FPS wise.

Please post anything you can think of to help with the FPS death immune fortress design.

My initial plan is to embark on a 3x3 embark space on flat lands with 1 cave system and with no flowing water (as these decreases FPS). Flat lands because I want to know if above ground construction can be used to compensate the inevitable limited mining below ground. Initial population cap is 60, hopefully with good frot design we can increase it above 100 later on. All designs that involve flowing water or magma will be replaced by creating a source of magma and water with DFHack in a contained area to eliminate FPS drain from pump stacks and such and overall the FPS drain from flowing liquids will be kept at minimum by careful design. I will try to keep mining out of below ground to the minimum as well although it probably is not too bad to mine out apartment complexes and workshops below ground. The plan is to have all industry on one level as there are rumors path finding through z levels might decrease FPS. Mining for minerals will be replaced with modding a workshop that gives these materials from thin air, though. An alternative might be obsidian farming and glass and clay block creation legitimately as this does not require mining. Same for wood as tree farms are not feasible considering the large space they need, while it is also legitimately possible to survive with the above ground tree chopping (in my last fortress I had 10 completely mined out floors only to grow trees underground and it was still sometimes a bit slow to get the wood I wanted). Only guard animals will be allowed in the fortress, all other animals will be butchered or caged.

I will post my designs and results later on as I design and construct the new fortress.
« Last Edit: March 29, 2014, 09:03:32 pm by juxari »
Logged

Necrisha

  • Bay Watcher
  • 0.0 0.o o.0 o.o -.- zzzZ
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #1 on: March 29, 2014, 09:39:23 pm »

autodump-destroy-here is your friend, use it often. Also create as little clothing as possible, use military squads to clothe your dorfs in armour as it doesn't wear out over time. Not Trading is a another good option later in game as every item that was brought on caravans, as well as everything that has been traded is still stored in memory, So removing the trading depot once trading is no longer needed for survival.
Logged
EDIT: Keas restricted to tropical forests where they belong.  Those evil, EVIL, foul little things.
 
Edit: The baby murderer became a friend of the fortress, which started a loyalty cascade, and now most of the squad is dead.

juxari

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #2 on: March 30, 2014, 01:02:27 am »

autodump-destroy-here is your friend, use it often. Also create as little clothing as possible, use military squads to clothe your dorfs in armour as it doesn't wear out over time. Not Trading is a another good option later in game as every item that was brought on caravans, as well as everything that has been traded is still stored in memory, So removing the trading depot once trading is no longer needed for survival.

autodum destroy is very practical, but in a previous topic it was said that atom smashing is somehow a better option. I'm not exactly sure why that would be however.

I didn't know about trading affecting FPS. I will try to eliminate trading altogether in my fortress.
« Last Edit: March 30, 2014, 01:04:30 am by juxari »
Logged

TruePikachu

  • Bay Watcher
  • Accomplished System Administrator
    • View Profile
    • cDusto (my personal server)
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #3 on: March 30, 2014, 01:55:35 am »

I don't know how many of these threads have appeared before, but given that it is plural and not a single thread which would still be active to this day, they probably all ended badly.

An important thing to remember is that computer specs, while a good contribuiter to FPS, doesn't necessairily translate well into comparing system results - you won't be able to give a multiplier on which to adjust FPS counts given hardware. Additionally, software (especially system services) plays in very strongly. As a result, it isn't very plausable to share absolute FPS counts, even when sharing system specs.

Something which will really help contribute information about lag causes is someone with a disassembler and a debugger, and has experience with DF's backend. I only partially qualify, not enough to help. But a lot of the questions (like with item-contributed lag) can be confirmed by checking the item chain to see if things get released from it properly, and other related stuff.

The biggest bottleneck that I'm aware of is pathfinding, and it will generally always be a bottleneck.

EDIT: `autodump destroy` removes the items from the item chain, but wasn't written by Toady. Atom smashing might not remove items from the chain (I don't know if it does or not), but is written by Toady. Toady authoring the code is important, as we ('we' being the DF hacking community) can't be sure we know everything related to the item chain. So if atom smashing does remove items from the chain, it might be better then `autodump destroy`.
« Last Edit: March 30, 2014, 01:58:58 am by TruePikachu »
Logged
He likes Pokémon, composing ≡«☼characters☼»≡, Windows for its compatability, Linux for its security, and Pikachu for its electric capabilities. When possible, he prefers to consume pasta. He absolutely detests Apple.

enizer

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #4 on: March 30, 2014, 07:23:33 am »

One curious thing I ran into recently, my main computer, am3 1100T(6 cores at 3.3ghz) 8gb ddr2 800 ATI HD 6850
had a fortress I had been running for 7 years, and it was down to 22 fps.
I was showing my brother something, so I moved my DF install over to my secondary computer, which is a FM2 A10-5800k (4 cores 3.8ghz, on-chip HD 7660d) , 8gb ddr3 2133, using the on-chip for graphics, that computer, on the same save, got a stable 40 fps.

That got my thinking, that FM2 APU is only slightly faster in single core performance, the on-chip video card is somewhat slower then the HD 6850(surprisingly not by a very wide margin though) but had nearly double the FPS.
the only thing I can think of, does the faster memory really matter THAT much?

In other news stuffing all redundant animals in cages, and selling them to the next caravan got fps up to 35..
I also notice that the 1x1 stairway to the cavern causes a huge fps drop whenever something happens to draw haulers or soldiers there.. will design wider staircases next time
Logged

smjjames

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #5 on: March 30, 2014, 09:58:22 am »

I think everybody gets FPS death at some point, just takes longer for some than others.

autodump-destroy-here is your friend, use it often. Also create as little clothing as possible, use military squads to clothe your dorfs in armour as it doesn't wear out over time. Not Trading is a another good option later in game as every item that was brought on caravans, as well as everything that has been traded is still stored in memory, So removing the trading depot once trading is no longer needed for survival.

autodum destroy is very practical, but in a previous topic it was said that atom smashing is somehow a better option. I'm not exactly sure why that would be however.

Maybe because it feels a little less cheaty? I use the autodump destroy-here on clothing left on the battlefield which got claimed and am not waiting for dwarves to pick up, for example.
Logged

Necrisha

  • Bay Watcher
  • 0.0 0.o o.0 o.o -.- zzzZ
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #6 on: March 30, 2014, 10:26:27 am »

I never liked atom smashers though. took too long to figure out a configuration that either didn't kill dwarves, or didn't get found by building destroyers...
Logged
EDIT: Keas restricted to tropical forests where they belong.  Those evil, EVIL, foul little things.
 
Edit: The baby murderer became a friend of the fortress, which started a loyalty cascade, and now most of the squad is dead.

juxari

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #7 on: March 30, 2014, 10:50:25 am »

Update:

I'm running a fort around year 10 now. FPS is capped at 100 still with 84 modded dwarfs with no needs. I modded my dwarfs because I'm currently trying to find out whether above ground construction will drain FPS in the long run and I have this far built a fort of around 20 000 platinum and admantine blocks. This far I have mined almost no underground space at all and everything seems fine. No playing around with liquids yet besides minimal magma forge, smelter and glass maker workshops.
Logged

Deepblade

  • Bay Watcher
  • Tholtarmid
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #8 on: March 30, 2014, 11:04:51 am »

I think it eventually will slow you down. If I remember correctly the game has to keep track of each of those blocks used in the construction. But, with how few things you have to track a few thousand blocks shouldn't be a problem.
Logged
Deepblade's Standardized Creature Parts, for when you're pissed about all the different types of animal products there are.

EvilBob22

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #9 on: March 30, 2014, 11:29:54 am »

Graphics processors are crucial outside of DF, but DF uses very basic graphics controls, so as long as the graphics are less than 15 or 20 years old, they won't make any difference. 

As had been stated many times, DF is not multi-threaded, so multi-core CPUs don't help; a two core 3.2 Ghz machine will run DF better than an eight core 3.0 Ghz machine.  Memory size doesn't seem to help much either.  From what others have said, it sounds like DF is a 32-bit app, and can only use 2 Gb of memory.  I have no personal knowledge of the memory size limitations though.

This seems to agree with enizer's observations: the first (slower in DF) machine runs as if it is a single core 3.3 Ghz, 2 Gb 800 RAM (graphics irrelevant), and the second one runs like a single core 3.8 Ghz, 2 Gb 2133 RAM machine.


I never liked atom smashers though. took too long to figure out a configuration that either didn't kill dwarves, or didn't get found by building destroyers...
I don't use them, but I would think the secret is to have them in a pit with no access, and to dump from above.
Logged
I will run the experiment to completion anyway, however. Even if the only reason why there is a punctured equilibrium in the fortress is because I have been brutally butchering babies
EDIT: I just remembered that dwarves can't equip halberds. That might explain why the squads that use them always die.

juxari

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #10 on: March 30, 2014, 11:32:02 am »

I think it eventually will slow you down. If I remember correctly the game has to keep track of each of those blocks used in the construction. But, with how few things you have to track a few thousand blocks shouldn't be a problem.

I might eventually test this by deconstructing or collapsing the fortress and see is destroying the constructions and all the materials used will remove the possible FPS drain. This far I don't have any FPS drain, however.
Logged

Nil Eyeglazed

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #11 on: March 30, 2014, 03:18:22 pm »

Ptw!

An important thing to remember is that computer specs, while a good contribuiter to FPS, doesn't necessairily translate well into comparing system results - you won't be able to give a multiplier on which to adjust FPS counts given hardware. Additionally, software (especially system services) plays in very strongly. As a result, it isn't very plausable to share absolute FPS counts, even when sharing system specs.

Really?  So are you saying that it might be possible for my computer to run one game faster than yours, while yours ran a different game faster than mine?

That got my thinking, that FM2 APU is only slightly faster in single core performance

I'm not familiar with those processors, but are you basing that just on clock speed (ghz)?  Processor performance is about a lot more than just clock speed these days.
Logged
He he he.  Yeah, it almost looks done...  alas...  those who are in your teens, hold on until your twenties...  those in your twenties, your thirties...  others, cling to life as you are able...<P>It should be pretty fun though.

enizer

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #12 on: March 30, 2014, 04:04:21 pm »

various benchmarks rated the single core performance of the A10 5800k around 20% higher then that of the 1100T
the A10-5800k supports some new instructions, but they are not widely supported yet, and i'm pretty sure dwarf fortress isnt using those

As far as no-graphics single thread programs go, these computers should be very similar, and yet, the performance difference is huge,
the biggest difference is ram speed, so it makes me wonder, is ram speed a huge factor for dwarf fortress, or is it something else that's making the difference?
« Last Edit: March 30, 2014, 04:32:20 pm by enizer »
Logged

BoredVirulence

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #13 on: March 30, 2014, 04:15:11 pm »

is ram speed a huge factor for dwarf fortress, or is it something else that's making the difference?
RAM speed should be a big factor. Every tick temperature calculations are done for every tile, not to mention pathfinding referencing hundreds of tiles per pathfind attempt. Not to mention fluid calculations that will be done per tick to many different tiles if you have fluids moving. And under most circumstances the map data should be too large to squeeze into a cache.

RAM is most likely the bottleneck. Although I think I've heard that saving/reloading DF makes a difference.
Logged

enizer

  • Bay Watcher
    • View Profile
Re: My Attempt to Eliminate/Minimize the FPS Death (HELP NEEDED!)
« Reply #14 on: March 30, 2014, 04:32:32 pm »

A quick test, slowing the memory to 1333, changed the speed from 40 to 34, hmm, that's more then i thought initially, but not all of it,

still though, where I live, the difference between 8gb ddr3 1600 and 8gb ddr3 2133 is about, 130$, vs 140$ so clearly it's a bad idea to cheap out on ram in any case, with that tiny price difference :)
« Last Edit: March 30, 2014, 04:36:23 pm by enizer »
Logged
Pages: [1] 2 3 4