Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: Any way to tell what is causing lag?  (Read 7551 times)

ptb_ptb

  • Bay Watcher
    • View Profile
Any way to tell what is causing lag?
« on: August 10, 2014, 04:14:11 am »

I have super bad FPS near a certain dwarf trade depot. There may be 4,000 dwarfs heaped up in a drunken pile underground; I don't know. Is there anyway to check for that sort of thing?

Also, I remember reading about population cap problems somewhere ... can't find it in the Mantis Bug Tracker. Do you think it's worth reporting this as a bug and uploading a save? Or is this stuff well known already?
Logged
()==[:::::::::::::>

sv-esk

  • Bay Watcher
  • sorry for my bad english
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #1 on: August 10, 2014, 05:09:13 am »

Is there anyway to check for that sort of thing?
How to determine site population?
Spoiler: LegendsViewer (click to show/hide)
Overpopulation bug was (partially?)fixed in 0.40.04.
« Last Edit: August 10, 2014, 05:26:26 am by sv-esk »
Logged

Robsoie

  • Bay Watcher
  • Urist McAngry
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #2 on: August 10, 2014, 05:24:20 am »

legendviewer and worldviewer can indeed tell how much pop there can be on each sites, usually it's the goblin sites (dark fortresses + pits) that are overpopulated (not rare to have 5 or more times the amount of the other races sites pop) even on short history and small world (reported on tracker).

But it's always good to report your laggy games, and upload the save (or the report isn't useful) as more saves to look if Toady don't have enough of them, it means then more chances to find the source of all those lag problems.

The game can pile several dozen of people into single tiles (reported on tracker), and with the spam of dialogues + broken emotions/reaction it can lead into so many calculations that that game will become slow.
There are pathfinding troubles too that can be a huge annoyance because the AI pathfinding bugs can make the game unplayable slow both in adventure or fortress modes
Logged

ptb_ptb

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #3 on: August 10, 2014, 05:50:07 am »

The results are in ...

Populations

265 Cats
234 Dwarves
218 Sheeps
218 Water Buffalos
218 Ducks
218 Dogs
218 Yaks
218 Donkeys
218 Guineafowls
218 Blue Peafowls
218 Goats
218 Chickens
218 Reindeers
218 Alpacas
218 One-humped Camels
218 Pigs
218 Turkeys
10 Dwarf Outcasts
4 Human Outcasts

... is that a lot? I'm getting FPS 3(2)

Bug Tracker report at
http://www.bay12games.com/dwarves/mantisbt/view.php?id=7931
« Last Edit: August 10, 2014, 06:14:26 am by ptb_ptb »
Logged
()==[:::::::::::::>

smjjames

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #4 on: August 10, 2014, 08:49:59 am »

The animals are definetly causing the lag, try having THAT many animals in fort mode, plus the pathing issues and cats trying to get through closed doors.
Logged

ptb_ptb

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #5 on: August 10, 2014, 08:52:55 am »

The animals are definetly causing the lag, try having THAT many animals in fort mode, plus the pathing issues and cats trying to get through closed doors.

Elsewhere there's a goblin dark fortress with 11,000 goblins and 5,000 trolls. :P
Logged
()==[:::::::::::::>

sv-esk

  • Bay Watcher
  • sorry for my bad english
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #6 on: August 10, 2014, 08:58:53 am »

I have used dfhack commands:
1)feature show 8
2)reveal
And I dont see so many animals. It seems, there are no "218-counted" animals at all. Where are they? In hell?(I cant reveal hell to check) Burrowed alive in walls? Found, finally. They are in the left upper corner in the first cavern. 5 creatures per tile.
Spoiler: animal flood (click to show/hide)
-----------
11,000 goblins and 5,000 trolls goblin dark fortresses are laggy but does not cause 2(2)FPS freeze. (I killed demon in it recently, and it wasnt masochism) , but your save does.
« Last Edit: August 10, 2014, 09:35:00 am by sv-esk »
Logged

smjjames

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #7 on: August 10, 2014, 09:58:40 am »

WHoa geeze, maybe post about that in the bug report related to this along with the screenshot? The pathing from those would definetly cause lag.
Logged

smjjames

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #8 on: August 10, 2014, 11:28:45 am »

Could someone use DFhack to look at my save in the report at http://www.bay12games.com/dwarves/mantisbt/view.php?id=7821 ? I think it might actually be the same thing as this one.
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #9 on: August 10, 2014, 12:06:43 pm »

Yikes, it took me about a minute to advance a single frame. Here's what "exterminate" returns:
Code: [Select]
[DFHack]# exterminate
 BIRD_SWALLOW_CAVE_GIANT 1
 BLIND_CAVE_OGRE 1
 GIANT_EARTHWORM 1
 OLM_GIANT 1
 RAT_LARGE 1
 REACHER 1
 VORACIOUS_CAVE_CRAWLER 1
 JABBERER 2
 RAT_GIANT 2
 TOAD_GIANT 2
 TROLL 2
 CROCODILE_CAVE 3
 IMP_FIRE 3
 MOLEMARIAN 3
 CAVE_BLOB 4
 HUMAN 5
 MAGMA_CRAB 5
 POND_GRABBER 5
 TROGLODYTE 6
 FLESH_BALL 18
 CRUNDLE 19
 CREEPING_EYE 32
 DWARF 198
 ALPACA 954
 BIRD_PEAFOWL_BLUE 954
 DONKEY 954
 HORSE 954
 RABBIT 954
 SHEEP 954
 BIRD_TURKEY 1908
 CAT 1908
Obviously a case of overpopulation.
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

smjjames

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #10 on: August 10, 2014, 12:14:42 pm »

Sheeeit, I swear that LegendsViewer said that the population was nowhere near that for my save. Could be a case of duplicating population......
Logged

sv-esk

  • Bay Watcher
  • sorry for my bad english
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #11 on: August 10, 2014, 12:19:17 pm »

Could someone use DFhack to look at my save in the report at http://www.bay12games.com/dwarves/mantisbt/view.php?id=7821 ? I think it might actually be the same thing as this one.
Same corner.


Exterminated all these animals and moved your character to corpses - http://www.mediafire.com/download/w8y5hdujj38rdl8/region_bug2.zip. No more mayor freezes
« Last Edit: August 10, 2014, 12:23:51 pm by sv-esk »
Logged

lethosor

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #12 on: August 10, 2014, 12:58:08 pm »

I posted some findings on smjjames's report - it appears that the animal populations are renegerating after sleeping/waiting. (I was unable to determine if they spawned in the same location, since DF froze up completely shortly after running "exterminate".)
Logged
DFHack - Dwarf Manipulator (Lua) - DF Wiki talk

There was a typo in the siegers' campfire code. When the fires went out, so did the game.

smjjames

  • Bay Watcher
    • View Profile
Re: Any way to tell what is causing lag?
« Reply #13 on: August 11, 2014, 06:30:01 pm »

Going to get test saves in for 40.08, and have a save or two before it gets all laggy for you guys to analyze.

The population of this fortress according to Legends Viewer is:

212 Dwarves
33 Dogs
24 Cavies
24 Cats
20 Guineafowls
15 Ducks
12 Pigs
12 Reindeers
12 Alpacas
10 Humans
10 Blue Peafowls
2 Water Buffaloes

I found a hamlet a bit earlier that was supposed to have 25 humans in it, but it turned out to be completely abandoned, no mead hall either. So, it's possible that LegendsViewer is wrong on the population.

http://dffd.wimbli.com/file.php?id=9360
Exiting fast travel landed me on the roof and it's already rather laggy, almost dark tower level laggy. It still makes it barely playable and probably unplayable for those on lower end machines. Also, more than one entrance to it would be nice, so I don't have to run all the way around it just to find the entrance. The combat movement arrows are also displaying for some reason, not sure why.

Waited 4 hours at trade depot, http://dffd.wimbli.com/file.php?id=9361 The lag got somewhat worse, not the horrible lag I had with the other one, but it's still unplayable lag.

http://dffd.wimbli.com/file.php?id=9362 Waited 4 hours again and the lag is..... actually a bit better than at arrival??? The trade depot also seems to have broken because I can't take stuff from it where I could earlier.
« Last Edit: August 11, 2014, 07:06:27 pm by smjjames »
Logged