renamed functions.

This commit is contained in:
2022-02-21 11:16:50 +08:00
parent 676554bc86
commit 9376568d47
2 changed files with 4 additions and 4 deletions

View File

@@ -198,10 +198,10 @@ namespace hgl
}
/**
* 求数值对齐后的值
* 求数值对齐后的值(仅支持2次幂)
*/
template<typename T>
inline T hgl_align2(const T &value,const T &alignment)
inline T hgl_align_pow2(const T &value,const T &alignment)
{
const T align_size=alignment-1;

View File

@@ -23,7 +23,7 @@ namespace hgl
int active; ///<有多少个key是活跃的
int idle; ///<有多少个key是闲置的
int can_free; ///<不在active/idle中但可以从idle中释放的个数
int non_existent; ///<active/idle中都不存在的key有多少个
int not_found; ///<active/idle中都不存在的key有多少个
};
/**
@@ -64,7 +64,7 @@ namespace hgl
if(idle_items.KeyExist(*kp))
++(stats.idle);
else
++(stats.non_existent);
++(stats.not_found);
++kp;
}