Page MenuHomePhabricator

Current MITK Superbuild causes memory leak with Visual Studio 2012
Closed, ResolvedPublic

Description

When starting the current MITK-Superbuild

Date: 02.10.2013
Hash: 9fac40acdad29d1a8757caccb5abbfe4e936ba31

with Visual Studio 2012, memory will fill up and eventually causes windows to crash. This seems to affect many Visual Studio 2012 users (Michael B, Michael G, Bastian, Keno..) and their Dartclients. However, for some Visual Studio 2012 users, everything works fine (Stefan,Jasmin).

By looking at the Dartclient histories, the problem occured sometime after the 19.8.

I tried a few version:

Date: 19.8. Last Commit: Jan
faf3445801be908b3cda47520d6dfbb467b09b2e
--> Works

Date: 20.8 Last Commit: Sascha, Included a separate DCMTK build
35cc1065371155278710ef654cf4a3f2918b87ff
--> Seems to work, but build is not successful

Date: 20.9 Last Commit: Sascha, Added methods for creating temporary files and directories
3aae9ca11280f11a50066961847f96fe017ac2a4
--> Seems to work.

....

When looking at the Compiler output and the memory usage, it seems that all necessary Toolkits are downladed and configured at the same time in different threads. During this process, something goes wrong.

At a first look, i guess the "Qwt" toolkit causes problems, as it seems not to find the C compiler:

  • Detecting C compiler ABI info - failed

The compiler output shortly before crash is attached.
Note: The memory leakage begins already after the downloading phase!

Event Timeline

The problem lies within visual studio.

All projects in the solution are built parallel. This can (often) lead to memory overflow (even with 32 GB RAM).

The amount of parallel built projects can be reduced in
TOOLS -> OPTIONS -> PROJECTS AND SOLUTIONS -> BUILD AND RUN : Maximum Number of parallel project builds: Set this value to 3 or 4.

This is a global Visual Studio Setting and indepedent from the solution. So you propably have to set it only once. It is unclear if this setting is also used in the nightly Dartclient .. i will test this soon.