Skip to content

Commit

Permalink
Adds closure mask for dynamic blocks created in soft VM
Browse files Browse the repository at this point in the history
Issue: #17
Issue: #92
  • Loading branch information
0x7CFE committed Aug 6, 2016
1 parent 878db08 commit 6a1167e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/MethodCompiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -992,6 +992,9 @@ llvm::Function* MethodCompiler::compileDynamicBlock(TBlock* block)
type::Type blockTemps(globals.arrayClass, type::Type::tkArray);
createBlockTypes(block, *blockGraph, blockType, blockArguments, blockTemps, closureTypes);

const uint32_t closureMask = getClosureMask(*blockGraph);
block->stackTop.setRawValue(closureMask);

// Check if function was already compiled
const std::string& blockFunctionName = getDynamicBlockFunctionName(blockType, blockArguments, blockTemps);
if (Function* const blockFunction = m_JITModule->getFunction(blockFunctionName))
Expand Down

0 comments on commit 6a1167e

Please sign in to comment.