Skip to content
  • Sean Callanan's avatar
    Refactored the expression parser so that the IR · 8dfb68e0
    Sean Callanan authored
    and the JITted code are managed by a standalone
    class that handles memory management itself.
    
    I have removed RecordingMemoryManager and
    ProcessDataAllocator, which filled similar roles
    and had confusing ownership, with a common class
    called IRExecutionUnit.  The IRExecutionUnit
    manages all allocations ever made for an expression
    and frees them when it goes away.  It also contains
    the code generator and can vend the Module for an
    expression to other clases.
    
    The end goal here is to make the output of the
    expression parser re-usable; that is, to avoid
    re-parsing when re-parsing isn't necessary.
    
    I've also cleaned up some code and used weak pointers
    in more places.  Please let me know if you see any
    leaks; I checked myself as well but I might have
    missed a case.
    
    llvm-svn: 177364
    8dfb68e0
Loading