moved global state from code_heap into vm

db4
Phil Dawes 2009-08-17 21:37:13 +01:00
parent 221c0ac5c8
commit 396eeeba34
3 changed files with 2 additions and 5 deletions

View File

@ -3,8 +3,6 @@
namespace factor
{
heap code;
/* Allocate a code heap during startup */
void factorvm::init_code_heap(cell size)
{
@ -159,7 +157,6 @@ PRIMITIVE(code_room)
PRIMITIVE_GETVM()->vmprim_code_room();
}
static unordered_map<heap_block *,char *> forwarding;
code_block *factorvm::forward_xt(code_block *compiled)
{

View File

@ -1,8 +1,6 @@
namespace factor
{
/* compiled code */
extern heap code;
void init_code_heap(cell size);

View File

@ -468,6 +468,8 @@ struct factorvm {
code_block *add_code_block(cell type,cell code_,cell labels_,cell relocation_,cell literals_);
//code_heap
heap code;
unordered_map<heap_block *,char *> forwarding;
void init_code_heap(cell size);
bool in_code_heap_p(cell ptr);
void jit_compile_word(cell word_, cell def_, bool relocate);