File tree Expand file tree Collapse file tree
src/observer/storage/buffer Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -72,7 +72,7 @@ struct BPFileHeader
7272 * 能够分配的最大的页面个数,即bitmap的字节数 乘以8
7373 */
7474 static const int MAX_PAGE_NUM =
75- (BP_PAGE_DATA_SIZE - sizeof (buffer_pool_id) - sizeof (page_count) - sizeof (allocated_pages)) * 8 ;
75+ (BP_PAGE_DATA_SIZE - sizeof (buffer_pool_id) - sizeof (page_count) - sizeof (allocated_pages)) * 8 ;
7676 string to_string () const ;
7777};
7878
@@ -351,5 +351,5 @@ class BufferPoolManager final
351351 common::Mutex lock_;
352352 unordered_map<string, DiskBufferPool *> buffer_pools_;
353353 unordered_map<int32_t , DiskBufferPool *> id_to_buffer_pools_;
354- atomic<int32_t > next_buffer_pool_id_{1 }; // 系统启动时,会打开所有的表,这样就可以知道当前系统最大的ID是多少了
354+ atomic<int32_t > next_buffer_pool_id_{1 }; // 系统启动时,会打开所有的表,这样就可以知道当前系统最大的ID是多少了
355355};
Original file line number Diff line number Diff line change @@ -24,8 +24,7 @@ static constexpr PageNum BP_INVALID_PAGE_NUM = -1;
2424static constexpr PageNum BP_HEADER_PAGE = 0 ;
2525
2626static constexpr const int BP_PAGE_SIZE = (1 << 13 );
27- static constexpr const int BP_PAGE_DATA_SIZE = (BP_PAGE_SIZE - sizeof (LSN ) - sizeof (CheckSum ));
28- /**
27+ static constexpr const int BP_PAGE_DATA_SIZE = (BP_PAGE_SIZE - sizeof (LSN ) - sizeof (CheckSum ));/**
2928 * @brief 表示一个页面,可能放在内存或磁盘上
3029 * @ingroup BufferPool
3130 */
You can’t perform that action at this time.
0 commit comments