# Dev 2609 x64 - Memory Leak, Process spawning and high CPU

**URL:** <https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597>\
**Category:** Previous Build Reports\
**Created:** [September 26, 2015, 3:05am UTC](https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597 "2015-09-26T03:05:23Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![DaWilko](https://avatars.discourse-cdn.com/v4/letter/d/ce73a5/32.png) [@DaWilko](https://discourse.stonehearth.net/u/DaWilko)\
**Post date:** [September 26, 2015, 3:05am UTC](https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597/1 "2015-09-26T03:05:23Z")

</div>

Going to try and get some screenshots and details.

What’s happening is that at around 19 hearthlings I start seeing significant performance issues. Originally I assumed it was engine or a slow memory leak. Turns out the game is spawning a 2nd instance of stonehearth.exe and rapidly going to high CPU / Memory.

\*\*

- The below error seems to kick it off:

\*\*  
develop-2609 (x64)  
radiant/modules/events.luac:40: assertion failed!  
stack traceback:  
[C]: ?  
[C]: in function 'assert’  
radiant/modules/events.luac:40: in function ‘trigger\_async’  
…/components/combat\_state/combat\_state\_component.luac:85: in function 'remove\_attack\_leash’  
stonehearth/services/server/unit\_control/party.luac:95: in function '\_update\_leashes’  
stonehearth/services/server/unit\_control/party.luac:76: in function '\_update\_party’  
stonehearth/services/server/unit\_control/party.luac:16: in function \<stonehearth/services/server/unit\_control/party.luac:13\>

Followed by

develop-2609 (x64)  
c++ exception: lua runtime error  
stack traceback:

Not long after starting I see a 2nd Stoneharth process start  
[http://imgur.com/BbB7nM1](http://imgur.com/BbB7nM1)

What happens next is the CPU and Memory from both Stonehearth processes climbs quickly (5-10mins) and reaches max CPU and high memory  
[http://imgur.com/6uqafO1](http://imgur.com/6uqafO1)

The UI stops responding, though the game continues to play out. I can click on the characters but I can’t interact with the UI at all or the menu system.

This is the end state, I am not longer able to control the game, but I can move the camera around (with lag) and click on objects. I am not able to interact with them in any way.  
[http://imgur.com/YdpNCj1](http://imgur.com/YdpNCj1)

When ending Stoneheath from right clicking on the task bar close window the 2nd Stonehearth process remains active consuming both CPU and Memory.

---

<div class="post-metadata">

**Author:** ![DaWilko](https://avatars.discourse-cdn.com/v4/letter/d/ce73a5/32.png) [@DaWilko](https://discourse.stonehearth.net/u/DaWilko)\
**Post date:** [September 26, 2015, 3:14am UTC](https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597/2 "2015-09-26T03:14:48Z")

</div>

Savegame link here, you need to play for a little for the issue to start.

> **[Dropbox - Error](https://www.dropbox.com/s/sdn5ol8wefm2mil/1443183636640.rar?dl=0)**
>
> Dropbox is a free service that lets you bring your photos, docs, and videos anywhere and share them easily. Never email yourself a file again!

---

<div class="post-metadata">

**Author:** ![8BitCrab](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.stonehearth.net/8bitcrab/32/48512_2.png) [@8BitCrab](https://discourse.stonehearth.net/u/8BitCrab)\
**Post date:** [September 26, 2015, 3:33am UTC](https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597/3 "2015-09-26T03:33:53Z")

</div>

> [@DaWilko](#):
>
> Savegame link here, you need to play for a little for the issue to start.[Dropbox - Error - Simplify your life](https://www.dropbox.com/s/sdn5ol8wefm2mil/1443183636640.rar?dl=0)

glad to see you provided a save file, @Albert will probably want to take a look at that.

---

<div class="post-metadata">

**Author:** ![Relyss](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.stonehearth.net/relyss/32/41785_2.png) [@Relyss](https://discourse.stonehearth.net/u/Relyss)\
**Post date:** [September 26, 2015, 9:22am UTC](https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597/4 "2015-09-26T09:22:09Z")

</div>

Having 2 Stonehearth processes is normal. What is not normal is that one of them doesn’t disappear after closing the game…

---

<div class="post-metadata">

**Author:** ![Cube1](https://sea2.discourse-cdn.com/flex022/user_avatar/discourse.stonehearth.net/cube1/32/53900_2.png) [@Cube1](https://discourse.stonehearth.net/u/Cube1)\
**Post date:** [September 27, 2015, 12:48pm UTC](https://discourse.stonehearth.net/t/dev-2609-x64-memory-leak-process-spawning-and-high-cpu/16597/5 "2015-09-27T12:48:34Z")

</div>

This is happening to me too!
