|
10 | 10 | #include <random>
|
11 | 11 |
|
12 | 12 | extern "C" {
|
| 13 | +#include "redis/sds.h" |
13 | 14 | #include "redis/zmalloc.h"
|
14 |
| -#include "redis/zset.h" |
15 | 15 | }
|
16 | 16 |
|
17 | 17 | #include "base/gtest.h"
|
@@ -300,6 +300,7 @@ TEST_F(BPTreeSetTest, HalfRanges) {
|
300 | 300 | ASSERT_TRUE(path.Empty());
|
301 | 301 | }
|
302 | 302 |
|
| 303 | +#if 0 |
303 | 304 | TEST_F(BPTreeSetTest, MemoryUsage) {
|
304 | 305 | zskiplist* zsl = zslCreate();
|
305 | 306 | std::vector<sds> sds_vec;
|
@@ -346,6 +347,7 @@ TEST_F(BPTreeSetTest, MemoryUsage) {
|
346 | 347 | ASSERT_GT(mi_alloc.used(), 0u);
|
347 | 348 | LOG(INFO) << "df btree: " << double(mi_alloc.used()) / sds_vec.size() << " bytes per entry";
|
348 | 349 | }
|
| 350 | +#endif |
349 | 351 |
|
350 | 352 | TEST_F(BPTreeSetTest, InsertSDS) {
|
351 | 353 | vector<ZsetPolicy::KeyT> vals;
|
@@ -453,6 +455,7 @@ static void BM_FindRandomBPTree(benchmark::State& state) {
|
453 | 455 | }
|
454 | 456 | BENCHMARK(BM_FindRandomBPTree)->Arg(1024)->Arg(1 << 16)->Arg(1 << 20);
|
455 | 457 |
|
| 458 | +#if 0 |
456 | 459 | static void BM_FindRandomZSL(benchmark::State& state) {
|
457 | 460 | zskiplist* zsl = zslCreate();
|
458 | 461 | unsigned iters = state.range(0);
|
@@ -485,6 +488,7 @@ static void BM_FindRandomZSL(benchmark::State& state) {
|
485 | 488 | }
|
486 | 489 | }
|
487 | 490 | BENCHMARK(BM_FindRandomZSL)->Arg(1024)->Arg(1 << 16)->Arg(1 << 20);
|
| 491 | +#endif |
488 | 492 |
|
489 | 493 | void RegisterBPTreeBench() {
|
490 | 494 | auto* tlh = mi_heap_get_backing();
|
|
0 commit comments