diff options
author | dwight <dwight@10gen.com> | 2011-07-09 11:38:30 -0400 |
---|---|---|
committer | dwight <dwight@10gen.com> | 2011-07-09 11:38:30 -0400 |
commit | 0f3baac66794e65eeb80263c3c3ee1454cb8c732 (patch) | |
tree | b4dbd2015494a2f5ef924bf81d1c8d28764a62c1 /dbtests | |
parent | 40d1b5d2d079bdefa6656bd2282052525f768f3a (diff) | |
download | mongo-0f3baac66794e65eeb80263c3c3ee1454cb8c732.tar.gz |
prep for future profiling in vstudio
Diffstat (limited to 'dbtests')
-rw-r--r-- | dbtests/perftests.cpp | 50 |
1 files changed, 29 insertions, 21 deletions
diff --git a/dbtests/perftests.cpp b/dbtests/perftests.cpp index 039c308cb51..37e2bdc97c7 100644 --- a/dbtests/perftests.cpp +++ b/dbtests/perftests.cpp @@ -46,6 +46,9 @@ namespace mongo { } namespace PerfTests { + + const bool profiling = false; + typedef DBDirectClient DBClientType; //typedef DBClientConnection DBClientType; @@ -124,7 +127,7 @@ namespace PerfTests { virtual int expectationTimeMillis() { return -1; } // how long to run test. 0 is a sentinel which means just run the timed() method once and time it. - virtual int howLongMillis() { return 5000; } + virtual int howLongMillis() { return profiling ? 60000 : 5000; } /* override if your test output doesn't need that */ virtual bool showDurStats() { return true; } @@ -742,26 +745,31 @@ namespace PerfTests { cout << "stats test rps------ time-- " << dur::stats.curr->_CSVHeader() << endl; - add< Dummy >(); - add< TLS >(); - add< Malloc >(); - add< Timer >(); - add< CTM >(); - add< KeyTest >(); - add< Bldr >(); - add< StkBldr >(); - add< BSONIter >(); - add< BSONGetFields1 >(); - add< BSONGetFields2 >(); - add< ChecksumTest >(); - add< TaskQueueTest >(); - add< InsertDup >(); - add< Insert1 >(); - add< InsertRandom >(); - add< MoreIndexes<InsertRandom> >(); - add< Update1 >(); - add< MoreIndexes<Update1> >(); - add< InsertBig >(); + if( profiling ) { + add< Update1 >(); + } + else { + add< Dummy >(); + add< TLS >(); + add< Malloc >(); + add< Timer >(); + add< CTM >(); + add< KeyTest >(); + add< Bldr >(); + add< StkBldr >(); + add< BSONIter >(); + add< BSONGetFields1 >(); + add< BSONGetFields2 >(); + add< ChecksumTest >(); + add< TaskQueueTest >(); + add< InsertDup >(); + add< Insert1 >(); + add< InsertRandom >(); + add< MoreIndexes<InsertRandom> >(); + add< Update1 >(); + add< MoreIndexes<Update1> >(); + add< InsertBig >(); + } } } myall; } |