Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Does Dumping items actually improve FPS?  (Read 757 times)

Crossroads Inc.

  • Bay Watcher
  • Joined in the great Migration of 2009
    • View Profile
Does Dumping items actually improve FPS?
« on: November 26, 2009, 11:46:27 am »

I started an experiment recently, rather then dumping things into my Bottomless pit... I built a small 1x1 tile where everyone drops things... Currently I have around 17screens worth of dumped items all on one little square.  If I detach it, and let it all plummet away, will it have a noticeable effect? Or is the act of gathering it up from all over the map and putting it in one tile enough to improve PFS?
Logged
Ask not what the Dwarfs can do for you...
But ask.... why are they drunk all the time?

NecroRebel

  • Bay Watcher
    • View Profile
Re: Does Dumping items actually improve FPS?
« Reply #1 on: November 26, 2009, 12:11:58 pm »

It does help to destroy items, in my experience. In one fort, I had some 50,000 stones and then designated all of the 1-value ones for dumping down my UGRiver-ending pit, since I had obsidian layers to play with and didn't want my masons or crafters to use the crummy stone. My FPS started at about 15-20, and creeped upwards by about 1 every 1500 stones that were vanished. By the time I abandoned that fort (due to a very badly placed orc siege), I had about 25-30 FPS despite actually gaining twenty or so dwarves and about as many animals in that same timeframe.

Just having it sit there probably won't help, however; they still take up cycles to locate as long as they still exist, so their effect on FPS should still be present as well.
Logged
A Better Magma Pump Stack: For all your high-FPS surface-level magma installation needs!

Christes

  • Bay Watcher
    • View Profile
Re: Does Dumping items actually improve FPS?
« Reply #2 on: November 26, 2009, 12:39:17 pm »

What about building constructions from the stone?
Logged

Derakon

  • Bay Watcher
    • View Profile
Re: Does Dumping items actually improve FPS?
« Reply #3 on: November 26, 2009, 12:43:06 pm »

The question really is if it's the destruction, or simply the forbidding, that speeds things up. I assume that the cost of all those extra items is in searching through them when a dwarf needs an item for a job (e.g. finding the closest stone to make mugs out of). If the items are forbidden, then they wouldn't be considered (and in fact, would be in a separate list entirely so they wouldn't even have to be looked at, assuming the code is written halfway intelligently).

I've heard tell that you can get the same effect of dumping all your rock if you just wall it off and make it inaccessible. It follows that forbidding the rock should accomplish the same thing.
Logged
Jetblade - an open-source Metroid/Castlevania game with procedurally-generated levels

Retro

  • Bay Watcher
  • o7
    • View Profile
Re: Does Dumping items actually improve FPS?
« Reply #4 on: November 26, 2009, 01:40:17 pm »

Forbidding doesn't help, from recent experience; nor does hiding. The problem is, there's just so many units that the game is keeping track of.

I carved out 200,000 stone a couple days ago (it took like two full days with 33 legendary +5 miners, to give a sense of scale) on top of the 50k I already had. At 150k (100k dug out) I was noticing my serious framerate issues at 2-5 FPS (which wasn't ALL that bad if you thought long-term), and as I got closer to 250k the game had dropped below 1 FPS and sometimes just froze up for no reason.

To destroy the stone, I set the types dug out to boil away. 200k stone gone in about ten minutes including freezeup time, and I was back up to 18 FPS or so when pathfinding was light.

So yeah, very big difference there, but that's on a very large scale, as well. Forbidding and/or hiding all the layers of stone I was dealing with didn't help in the least, either, so that's not really an effective tactic. You really need to just destroy that stuff.

Not sure about constructed walls form the loose stone and so on, but constructed walls do show up on the stocks screen as purple-marked rocks that zoom to the wall, so I guess the core material is still being kept track of by the game.
« Last Edit: November 29, 2009, 07:21:39 pm by Retro »
Logged

Vicomt

  • Bay Watcher
  • Just call me Vic.
    • View Profile
    • Steam Profile
Re: Does Dumping items actually improve FPS?
« Reply #5 on: November 26, 2009, 02:48:48 pm »

It probably depends on how Toady has implemented the storage of items, if, as said above, the used rocks get moved to a different array (sorry for the programmer speak, it's how I think) then those items shouldn't even be considered as a valid target for a job, however, if they're just flagged as being used, they'll still impact.

It also depends on what items your talking about, for rocks, they're valid targets for many different job requests and all have to be checked to see if they're needed or not, but when transformed into blocks, not so much, and anyway, transforming them to blocks should essentially delete the rock, and create a new block, which should move them out of the rocks array.

I would assume that if any of the items arrays (rocks, blocks, seeds, anything else) has a great number of individual items, and that particular item type is being used heavily by job requests, the time taken just to find the correct item for the job would increase significantly.

lesson being, don't let any of your stocks grow out of control ;)

darkflagrance

  • Bay Watcher
  • Carry on, carry on
    • View Profile
Re: Does Dumping items actually improve FPS?
« Reply #6 on: November 26, 2009, 06:05:36 pm »

It probably depends on how Toady has implemented the storage of items, if, as said above, the used rocks get moved to a different array (sorry for the programmer speak, it's how I think) then those items shouldn't even be considered as a valid target for a job, however, if they're just flagged as being used, they'll still impact.

It also depends on what items your talking about, for rocks, they're valid targets for many different job requests and all have to be checked to see if they're needed or not, but when transformed into blocks, not so much, and anyway, transforming them to blocks should essentially delete the rock, and create a new block, which should move them out of the rocks array.

I would assume that if any of the items arrays (rocks, blocks, seeds, anything else) has a great number of individual items, and that particular item type is being used heavily by job requests, the time taken just to find the correct item for the job would increase significantly.

lesson being, don't let any of your stocks grow out of control ;)


Of course, thousands of rocks and rock blocks are inevitable when you are trying to make a 15 z-level cathedral and a surrounding city of twenty-four ten z-level towers with a massive sky bridge for traders running down the middle, surrounded by a wall that goes up twenty z-levels in front of the face of the mountain (a recent fort of mine which died to fps).

If even constructed rocks contribute to lag, it might that the inevitable fate of ultra-megaproject fortresses like Flarechannels to succumb to the <10 fps syndrome...
Logged
...as if nothing really matters...
   
The Legend of Tholtig Cryptbrain: 8000 dead elves and a cyclops

Tired of going decades without goblin sieges? Try The Fortress Defense Mod

Vicomt

  • Bay Watcher
  • Just call me Vic.
    • View Profile
    • Steam Profile
Re: Does Dumping items actually improve FPS?
« Reply #7 on: November 26, 2009, 07:33:16 pm »

If even constructed rocks contribute to lag, it might that the inevitable fate of ultra-megaproject fortresses like Flarechannels to succumb to the <10 fps syndrome...

As I sit here, babying my own megaproject along, I ponder on the inevitability of it. It amazes me that DF can handle that much data and still run at all. I'm starting to compare Toady to Braben for his ingenuity.
« Last Edit: November 26, 2009, 07:34:58 pm by Vicomt »
Logged