Created
March 23, 2016 20:52
-
-
Save paulbatum/a21c6ca8dca81afb9e0e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Threading.Tasks; | |
using System.Diagnostics; | |
static Dictionary<int,byte[]> Allocations = new Dictionary<int,byte[]>(); | |
public static async Task Run(string id, int message, TraceWriter log) | |
{ | |
log.Verbose($"Machine: {Environment.MachineName}"); | |
for(int i=0; i< 100; i++) | |
{ | |
Allocations[i] = new Byte[message / 100]; | |
log.Verbose($"Allocation count: {Allocations.Count}"); | |
log.Verbose($"Private Memory Size: {Process.GetCurrentProcess().PrivateMemorySize64 / 1000000}mb"); | |
await Task.Delay(500); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment