xo-interpreter2 stack: invoke closures w/ tail-call opt [WIP]
This commit is contained in:
parent
0ab3b63a38
commit
af4c37c575
15 changed files with 175 additions and 87 deletions
|
|
@ -7,6 +7,7 @@
|
|||
|
||||
namespace xo {
|
||||
using xo::mm::AGCObject;
|
||||
using xo::reflect::typeseq;
|
||||
|
||||
namespace scm {
|
||||
|
||||
|
|
@ -18,6 +19,18 @@ namespace xo {
|
|||
local_env_{local_env}
|
||||
{}
|
||||
|
||||
DVsmApplyClosureFrame *
|
||||
DVsmApplyClosureFrame::make(obj<AAllocator> mm,
|
||||
obj<AGCObject> stack,
|
||||
VsmInstr cont,
|
||||
DLocalEnv * local_env)
|
||||
{
|
||||
void * mem = mm.alloc(typeseq::id<DVsmApplyClosureFrame>(),
|
||||
sizeof(DVsmApplyClosureFrame));
|
||||
|
||||
return new (mem) DVsmApplyClosureFrame(stack, cont, local_env);
|
||||
}
|
||||
|
||||
std::size_t
|
||||
DVsmApplyClosureFrame::shallow_size() const noexcept
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue