1
DF Dwarf Mode Discussion / Re: Pathfinding is not a major cause of FPS death
« on: January 31, 2023, 11:17:35 am »I did another 3-minute profile on my 260-citizen fort, this time with the knowledge of the source. Percents are going to overlap some. Specific seconds are not.
The slowest thing was line-of-sight checks. Due to the fact that it was only counting the checks in the function itself, this was a total of 14.7% of CPU time. However, if you remove one specific thing from line-of-sight checks (more on that later), it's 8%, and thus faster than the next thing. 13.181s in the function itself.
Great to see numbers here, thanks!
I know 14.7% doesn't point to any massive optimization potential, but -- is the line-of-sight implementation more amenable to a concurrent/thread-pool approach than the pathfinding? I would not expect LOS to use global mutable state, but I wouldn't have expected that for pathfinding either, so what do I know.
