Commits on Aug 16, 2011
  1. Added the lit test script and config files

    Lit is a python testing script taken from the LLVM project.
    It finds tests, runs them, and reports the results.
    committed Aug 16, 2011
  2. Print a marker for the final result closure

    The marker is used to verify the correct output for tests.
    committed Aug 16, 2011
  3. Add interp command line parameter to set base dir

    Sets the base directory from where bytecode files are
    searched for. Should implement a full loader path, but this
    is ok for now.
    committed Aug 15, 2011
  4. Updated gitignore

    committed Aug 16, 2011
Commits on Aug 12, 2011
  1. Clean up codgen debug output

    committed Aug 12, 2011
  2. Removed unused emit_ x64 instructions

    These were originally copied from LuaJIT.
    committed Aug 12, 2011
  3. Use cost model for spilling regsiter in allocator

    The cost to spill is a combination of the reference number
    plus an extra bit for those values that flow to phi nodes.
    Due to the organization of the IR, constants will have a
    smaller cost than values defined outside the loop, which
    will have a smaller cost than values defined inside the
    loop. The extra phi-factor tries to ensure that values in
    phi nodes will get a register.
    committed Aug 12, 2011
  4. Run asm codegen when finshed recording trace

    Previously we were running the codegen right before
    executing the trace. This was causing the extra IR
    instructions not to be emitted to the correct buffer (they
    were going to J->cur != F). We should be running the
    codegen at this point anyway.
    committed Aug 12, 2011
  5. Added some debugging statements

    committed Aug 12, 2011
  6. Added code to restore snapshot on trace exit

    The snapshot restoration appears to be working correct, but
    the example does not produce the correct answer
    committed Aug 11, 2011
  7. Change sps_scale to just scale the spill slot

    The previous version was also subtracting SPS_FIRST so that
    we could use all the spill slots. The problem is that the
    spill area is zero indexed (i.e. spills[0] is the first
    spill), but SPS_FIRST cannot be zero because a zero means
    no spill slot is allocated. As a result we simply don't use
    the first spill slot. This makes it easy to index into
    spills[ir->s] without having to worry about re-adjusting the
    committed Aug 11, 2011
  8. Fix FREF to index from base[0] instead of base[-1]

    The base pointer points to base[-1] during exection of a
    trace. The fref appears to be indexed off of base[0], so we
    need to scale it properly in the codegen.
    committed Aug 11, 2011
  9. Added some debug output

    committed Aug 10, 2011
  10. Added codegen for LOOP instruction

    We now correctly generate the backwards branch for a loop.
    Correct codgen for resolving phi node mismatches.
    Correct codgen for fixing phi nodes spilled outside loop
    Phi nodes that are spilled only outside a loop need to have
    IR_RENAMEs emitted for them.  We need to do this because if
    the LHS was spilled outside of the loop the snapshot
    restoration will attempt to load it from the spill slot.
    This spill slot will be out of date as the value changes in
    the loop.  We emit a rename to ensure that snapshots will
    restore the value from the register inside the loop.
    committed Aug 10, 2011
  11. Added codegen for PHI instructions

    We still need to do the codegen for the LOOP instruction to
    actually generate the proper code, but we have the
    allocation for the RHS of PHI instructions working.
    committed Aug 10, 2011
  12. Do not generate a position independent interp exe

    Using a position independent executable was causing the
    address for stg_IND_info to jump around because the OS X
    10.7 randomizes the starting address of the executable.
    These varations were causing needless mental overhead to
    my debugging efforts in the code generator.
    committed Aug 5, 2011
  13. Updated gitignore

    committed Aug 5, 2011
  14. Rearrange the code a bit

    committed Aug 4, 2011
  15. Change asmEnter to pass the heap pointer

    Instead of passing the base pointer as an argument we pass
    the heap pointer. The base pointer is read directly out of
    the Thread struct. For now, the heap pointer is faked with a
    bit of malloced memory.
    committed Aug 4, 2011
  16. Reorganzie the code a bit

    committed Aug 4, 2011
  17. Change spill slots to start at 1

    Spill slot 0 means no spill.
    committed Aug 4, 2011
  18. Formatting

    committed Aug 4, 2011
Commits on Aug 4, 2011
Commits on Aug 3, 2011