Index: DamEngine/trunk/lib/DGSMStabDam/DGSMStabDAM.dll =================================================================== diff -u -r1453 -r1481 Binary files differ Index: DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/MultiCoreMacroStabilityTests.cs =================================================================== diff -u -r1478 -r1481 --- DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/MultiCoreMacroStabilityTests.cs (.../MultiCoreMacroStabilityTests.cs) (revision 1478) +++ DamEngine/trunk/src/Deltares.DamEngine.Interface.Tests/MultiCoreMacroStabilityTests.cs (.../MultiCoreMacroStabilityTests.cs) (revision 1481) @@ -49,7 +49,7 @@ // Based on ".data\DamEngineTestProjects\DAM Tutorial Design\DAM Tutorial Design.damx" // with Dam Classic rev.1059 // Select locations DWP_1 to DWP_12 - const int multiCoreCount = 2; + const int multiCoreCount = 4; const string fileName = @"TestFiles\MacroStabilityTutorialDesignInputFileMultipleLocations.xml"; const string fileNameOutputPrefix = @"TestFiles\MacroStabilityTutorialDesignMultipleLocations"; string inputString = File.ReadAllText(fileName); Index: DamEngine/trunk/src/Deltares.DamEngine.Calculators/General/Parallel.cs =================================================================== diff -u -r962 -r1481 --- DamEngine/trunk/src/Deltares.DamEngine.Calculators/General/Parallel.cs (.../Parallel.cs) (revision 962) +++ DamEngine/trunk/src/Deltares.DamEngine.Calculators/General/Parallel.cs (.../Parallel.cs) (revision 1481) @@ -110,6 +110,12 @@ threads.Add(thread); thread.Start(Context.CurrentContext); // Pass the current context as task context + if (i == 0) + { + // Delay after the first trhead is started to give DGSMStabDam.dll time to initiliaze + // If this is not included DGSMStabDam.dll crashes, because it is trying to initilialize muliple times + System.Threading.Thread.Sleep(1000); + } } foreach (var thread in threads)