Package iota

Class NNaiveRegisterAllocator

java.lang.Object
iota.NRegisterAllocator
iota.NNaiveRegisterAllocator

class NNaiveRegisterAllocator extends NRegisterAllocator
A register allocator that uses a naive round-robin approach to allocate physical registers to virtual registers.
  • Constructor Details

    • NNaiveRegisterAllocator

      public NNaiveRegisterAllocator(NControlFlowGraph cfg)
      Constructs an NNaiveRegisterAllocator object.
      Parameters:
      cfg - control flow graph for the method.
  • Method Details

    • run

      public void run()
      Allocates physical registers to virtual registers.
      Specified by:
      run in class NRegisterAllocator