View Issue Details

IDProjectCategoryView StatusLast Update
0000002Dwarf FortressDwarf Mode -- Embark/Setuppublic2010-06-09 06:45
Reporterdrowfx Assigned ToToady One  
PrioritynormalSeveritycrashReproducibilityalways
Status closedResolutionfixed 
Platformx86_64OSWindows 7OS VersionProfessional x64
Fixed in Version0.31.04 
Summary0000002: Crash when using site finder on large worlds (mem usage >2gb)
DescriptionWhen using the site finder on a 257x257 world, the memory consumption rises constantly and when it reaches 2 GiB, DF crashes. I suspect this is because there is no virtual memory left.
Steps To Reproduce1. Create a 257x257 map
2. Start playing, Fortress Mode, Use the site finder, search
3. Watch memory usage climb
4. crash
Tagscrash, memory, site finder

Relationships

has duplicate 0000019 closeduser6 Crashed during location select 
has duplicate 0000837 closeduser6 Searching for "Medium Savagery" caused runtime error 
has duplicate 0001055 closeduser6 Crash while looking for site with Find function 
has duplicate 0000958 closeduser6 Microsoft Visual C++ Runtime Library Error 
has duplicate 0001221 closeduser6 Huge RAM problem with site finder 
has duplicate 0001752 closeduser6 Runtime error/crash when activating serch for an embark spot. 
has duplicate 0000283 resolveduser6 Crash when searching for an embark location 
has duplicate 0000719 resolveduser6 "Find desired location" extremly slow 

Activities

xylo

2010-04-02 12:34

reporter   ~0000261

The crash @2GB is expected. 32bit windows applications have a 4GB memory space, but only 2GB can be used (the other 2GB is reserved for system use [think stack, etc]). If you're on a 32bit platform, booting with /3GB will move you from a 2GB/2GB process space split to a 3GB/1GB split. This may be enough to work around the crash, as it seems to be close to completing the search -- but I cannot test that now to confirm.

If this is not a memory leak, df.exe either needs to be optimized to use less memory or recompiled to be a 64bit executable. (The 64bit recompile would be nice however :) )

drowfx

2010-04-04 06:04

reporter   ~0000854

I know that. While it is correct behavior for the application to terminate when its address space is used up, DF should not use that much memory. And using /3GB is not a solution because there are enough applications and drivers that crash and burn when used with it.

Huggz

2010-04-05 12:44

reporter   ~0001168

Confirmed. The site finder works fine in 40d, but in 0.31.01 it takes FAR longer, and then crashes (for me after around an hour at 200ish/257).

wizjany

2010-04-06 14:27

reporter   ~0001583

I can confirm this as well. However it's slightly different for me. Just as my memory is filled (2GB, Win7 32 bit) Windows gives me a runtime error: "This program has requested the runtime to terminate it in an unusual way."

Kaelem Gaen

2010-04-13 00:48

reporter   ~0003217

I can confirm, though I forgot to check the Memory usage. Odd considering I'm on a 64-bit system, but I guess 32bit emulation will still crash if it gets to high.

(I have 8 GB of memory)

Arkaaito

2010-04-13 19:56

reporter   ~0003372

Confirmed on 64-bit system (Win7 Ultimate).

See also http://www.bay12games.com/dwarves/mantisbt/view.php?id=136, for when you reduce the overall map size just enough to make the finder not crash.

Toady One

2010-04-14 03:55

administrator   ~0003443

This should be handled for 0.31.04.

Issue History

Date Modified Username Field Change
2010-04-01 05:29 drowfx New Issue
2010-04-02 05:38 Todestool Tag Attached: site finder
2010-04-02 12:34 xylo Note Added: 0000261
2010-04-03 07:55 user6 Category General => Dwarf Mode -- Embark/Setup
2010-04-03 12:10 Aquillion Tag Attached: crash
2010-04-04 06:04 drowfx Note Added: 0000854
2010-04-05 12:44 Huggz Note Added: 0001168
2010-04-05 14:53 user6 Relationship added has duplicate 0000019
2010-04-06 14:27 wizjany Note Added: 0001583
2010-04-08 20:48 user6 Relationship added has duplicate 0000837
2010-04-12 13:15 user6 Relationship added has duplicate 0001055
2010-04-12 13:21 user6 Relationship added has duplicate 0000958
2010-04-12 13:22 user6 Summary Crash due to memory leak when using site finder => Crash when using site finder on large worlds (mem usage >2gb)
2010-04-12 13:22 user6 Sticky Issue No => Yes
2010-04-13 00:48 Kaelem Gaen Note Added: 0003217
2010-04-13 19:54 Arkaaito Tag Attached: memory
2010-04-13 19:56 Arkaaito Note Added: 0003372
2010-04-14 03:55 Toady One Note Added: 0003443
2010-04-14 03:55 Toady One Status new => resolved
2010-04-14 03:55 Toady One Fixed in Version => 0.31.04
2010-04-14 03:55 Toady One Resolution open => fixed
2010-04-14 03:55 Toady One Assigned To => Toady One
2010-04-16 01:00 user6 Relationship added has duplicate 0001221
2010-05-05 00:07 user6 Relationship added has duplicate 0001752
2010-06-02 13:07 user6 Sticky Issue Yes => No
2010-06-09 06:45 Toady One Status resolved => closed
2010-06-22 09:16 user6 Relationship added has duplicate 0000283
2010-06-22 09:16 user6 Relationship added has duplicate 0001886
2010-06-22 09:16 user6 Relationship deleted has duplicate 0001886
2010-07-20 09:04 user6 Relationship added has duplicate 0000719