refactor focusing on xo-alloc2/ xo-gc/ write-barrier

ability to inform allocator of gco->gco mutation, via AAllocator i/face.
This commit is contained in:
Roland Conybeare 2026-05-01 19:54:26 -04:00
commit 99e5032b1e
3 changed files with 4 additions and 8 deletions

View file

@ -6,7 +6,6 @@
#pragma once #pragma once
#include <xo/alloc2/Allocator.hpp> #include <xo/alloc2/Allocator.hpp>
//#include <xo/alloc2/Collector.hpp>
#include <xo/alloc2/GCObjectVisitor.hpp> #include <xo/alloc2/GCObjectVisitor.hpp>
#include <xo/facet/obj.hpp> #include <xo/facet/obj.hpp>
#include <xo/indentlog/print/ppindentinfo.hpp> #include <xo/indentlog/print/ppindentinfo.hpp>
@ -16,8 +15,6 @@
//#include <cstdio> //#include <cstdio>
namespace xo { namespace xo {
namespace mm { class ACollector; }
namespace scm { namespace scm {
/** @class DString /** @class DString
* @brief String implementation with gc hooks * @brief String implementation with gc hooks
@ -46,8 +43,6 @@ namespace xo {
using const_iterator = const char *; using const_iterator = const char *;
/** xo allocator **/ /** xo allocator **/
using AAllocator = xo::mm::AAllocator; using AAllocator = xo::mm::AAllocator;
/** garbage collector **/
//using ACollector = xo::mm::ACollector;
/** object visitor (garbage collector proxy) **/ /** object visitor (garbage collector proxy) **/
using AGCObjectVisitor = xo::mm::AGCObjectVisitor; using AGCObjectVisitor = xo::mm::AGCObjectVisitor;
/** visitor hint **/ /** visitor hint **/

View file

@ -43,7 +43,7 @@ namespace xo {
///@{ ///@{
using size_type = xo::mm::AGCObject::size_type; using size_type = xo::mm::AGCObject::size_type;
using AAllocator = xo::mm::AGCObject::AAllocator; using AAllocator = xo::mm::AGCObject::AAllocator;
using ACollector = xo::mm::AGCObject::ACollector; //using ACollector = xo::mm::AGCObject::ACollector;
using AGCObjectVisitor = xo::mm::AGCObject::AGCObjectVisitor; using AGCObjectVisitor = xo::mm::AGCObject::AGCObjectVisitor;
using VisitReason = xo::mm::AGCObject::VisitReason; using VisitReason = xo::mm::AGCObject::VisitReason;
using Copaque = xo::mm::AGCObject::Copaque; using Copaque = xo::mm::AGCObject::Copaque;
@ -67,4 +67,4 @@ when @p fn invokes garbage collector reentry point **/
} /*namespace scm*/ } /*namespace scm*/
} /*namespace xo*/ } /*namespace xo*/
/* end */ /* end */

View file

@ -6,7 +6,8 @@
#include "init_stringtable2.hpp" #include "init_stringtable2.hpp"
#include "StringOps.hpp" #include "StringOps.hpp"
#include <xo/alloc2/Allocator.hpp> #include <xo/alloc2/Allocator.hpp>
#include <xo/alloc2/arena/IAllocator_DArena.hpp> #include <xo/alloc2/Arena.hpp>
//#include <xo/alloc2/arena/IAllocator_DArena.hpp>
#include <catch2/catch.hpp> #include <catch2/catch.hpp>
#include <cctype> #include <cctype>
#include <cstring> #include <cstring>