mirror of
https://github.com/fumiama/fumidb.git
synced 2026-06-09 20:50:38 +08:00
优化内存分配
This commit is contained in:
@@ -23,11 +23,11 @@ typedef uint64_t key_t;
|
||||
|
||||
// 为类型 type 创建索引
|
||||
// 返回:索引头节点的指针 index
|
||||
void* create_index(int fd, type_t t);
|
||||
void* create_index(int fd, type_t t, void* buf);
|
||||
|
||||
// 加载类型 type 的索引
|
||||
// 返回:索引头节点的指针 index
|
||||
void* load_index(int fd, type_t t, uint64_t ptr);
|
||||
void* load_index(int fd, type_t t, uint64_t ptr, void* buf);
|
||||
|
||||
// 插入一条索引
|
||||
int insert_item(int fd, type_t t, void* index, key_t k, uint64_t ptr);
|
||||
|
||||
Reference in New Issue
Block a user