1 // Copyright (c) 2011-present, Facebook, Inc. All rights reserved.
2 // This source code is licensed under both the GPLv2 (found in the
3 // COPYING file in the root directory) and Apache 2.0 License
4 // (found in the LICENSE.Apache file in the root directory).
13 // How much perf stats to collect. Affects perf_context and iostats_context.
14 enum PerfLevel
: unsigned char {
15 kUninitialized
= 0, // unknown setting
16 kDisable
= 1, // disable perf stats
17 kEnableCount
= 2, // enable only count stats
18 kEnableTimeExceptForMutex
= 3, // Other than count stats, also enable time
19 // stats except for mutexes
20 kEnableTime
= 4, // enable count and time stats
21 kOutOfBounds
= 5 // N.B. Must always be the last value!
24 // set the perf stats level for current thread
25 void SetPerfLevel(PerfLevel level
);
27 // get current perf stats level for current thread
28 PerfLevel
GetPerfLevel();
30 } // namespace rocksdb