Skip to content

Commit

Permalink
remove SpaceMapRBTree (#6292)
Browse files Browse the repository at this point in the history
close #6289
  • Loading branch information
flowbehappy authored Nov 11, 2022
1 parent 11b6869 commit f1ef741
Show file tree
Hide file tree
Showing 8 changed files with 3 additions and 1,519 deletions.
544 changes: 0 additions & 544 deletions dbms/src/Storages/Page/V3/spacemap/RBTree.cpp

This file was deleted.

85 changes: 0 additions & 85 deletions dbms/src/Storages/Page/V3/spacemap/RBTree.h

This file was deleted.

4 changes: 0 additions & 4 deletions dbms/src/Storages/Page/V3/spacemap/SpaceMap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include <Core/Types.h>
#include <IO/WriteHelpers.h>
#include <Storages/Page/V3/spacemap/SpaceMap.h>
#include <Storages/Page/V3/spacemap/SpaceMapRBTree.h>
#include <Storages/Page/V3/spacemap/SpaceMapSTDMap.h>
#include <common/likely.h>
#include <limits.h>
Expand All @@ -36,9 +35,6 @@ SpaceMapPtr SpaceMap::createSpaceMap(SpaceMapType type, UInt64 start, UInt64 end
SpaceMapPtr smap;
switch (type)
{
case SMAP64_RBTREE:
smap = RBTreeSpaceMap::create(start, end);
break;
case SMAP64_STD_MAP:
smap = STDMapSpaceMap::create(start, end);
break;
Expand Down
5 changes: 1 addition & 4 deletions dbms/src/Storages/Page/V3/spacemap/SpaceMap.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,13 @@ class SpaceMap
enum SpaceMapType
{
SMAP64_INVALID = 0,
SMAP64_RBTREE = 1,
// <-- Here used to be another type, but we removed it already.
SMAP64_STD_MAP = 2,
};

/**
* Create a SpaceMap that manages space address [start, end).
* - type :
* - SMAP64_RBTREE : red-black tree implementation
* - SMAP64_STD_MAP: std::map implementation
* - start : begin of the space
* - end : end if the space
Expand Down Expand Up @@ -135,8 +134,6 @@ class SpaceMap
{
switch (type)
{
case SMAP64_RBTREE:
return "RB-Tree";
case SMAP64_STD_MAP:
return "STD Map";
default:
Expand Down
Loading

0 comments on commit f1ef741

Please sign in to comment.