Revert MFTSearch changes.

This commit is contained in:
qianlifeng
2014-10-23 23:23:40 +08:00
parent 755e7bc232
commit 30afc095b9
6 changed files with 266 additions and 188 deletions

View File

@@ -16,7 +16,7 @@ namespace Wox.Test
var searchtimestart = DateTime.Now;
MFTSearcher.IndexAllVolumes();
var searchtimeend = DateTime.Now;
Console.WriteLine(string.Format("{0} file indexed, {1}ms has spent.", MFTSearcher.IndexedRecordsCount, searchtimeend.Subtract(searchtimestart).TotalMilliseconds));
Console.WriteLine(string.Format("{0} file indexed, {1}ms has spent.", MFTSearcher.IndexedFileCount, searchtimeend.Subtract(searchtimestart).TotalMilliseconds));
searchtimestart = DateTime.Now;
List<MFTSearchRecord> mftSearchRecords = MFTSearcher.Search("q");
@@ -34,6 +34,7 @@ namespace Wox.Test
{
long oldWorkingSet = System.Diagnostics.Process.GetCurrentProcess().WorkingSet64;
MFTSearcher.IndexAllVolumes();
GC.Collect();
long newWorkingSet = System.Diagnostics.Process.GetCurrentProcess().WorkingSet64;
Console.WriteLine(string.Format("Index: {0}M", (newWorkingSet - oldWorkingSet)/(1024*1024)));