Measure code
MODIFY
WalletWasabi/Io/DigestableSafeIoManager.cs
WalletWasabi/Io/DigestableSafeIoManager.cs
using System.Collections.Generic;
+using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Text;
@@ -76,6 +77,10 @@ public class DigestableSafeIoManager : SafeIoManager
return;
}
+ Stopwatch stopWatchAll = Stopwatch.StartNew();
+
+ try
+ {
IoHelpers.EnsureContainingDirectoryExists(NewFilePath);
if (File.Exists(NewFilePath))
{
@@ -145,6 +150,11 @@ public class DigestableSafeIoManager : SafeIoManager
SafeMoveNewToOriginal();
await WriteOutHashAsync(hash).ConfigureAwait(false);
}
+ finally
+ {
+ Logger.LogDebug($"TODO-DELETE-ME: Total time: {stopWatchAll.Elapsed}");
+ }
+ }
#endregion IoOperations

Measure code