xo-alloc: utest: fix broken alloc utests

This commit is contained in:
Roland Conybeare 2025-11-15 16:38:18 -05:00
commit 1c97e2aa93
5 changed files with 82 additions and 40 deletions

View file

@ -14,7 +14,9 @@ set(SELF_SRCS
)
xo_add_shared_library4(${SELF_LIB} ${PROJECT_NAME}Targets ${PROJECT_VERSION} 1 ${SELF_SRCS})
# xo-unit used for time measurement
xo_dependency(${SELF_LIB} xo_unit)
xo_dependency(${SELF_LIB} indentlog)
xo_dependency(${SELF_LIB} reflect)
xo_dependency(${SELF_LIB} callback)

View file

@ -201,12 +201,24 @@ namespace xo {
return retval;
}
std::size_t
GC::pagesize() const
{
return nursery_to()->page_size();
}
std::size_t
GC::nursery_from_allocated() const
{
return nursery_from()->allocated();
}
std::size_t
GC::nursery_to_allocated() const
{
return nursery_to()->allocated();
}
std::size_t
GC::nursery_to_reserved() const
{