org.kiama.example.obr

RISCEncoder

class RISCEncoder extends AnyRef

Translate RISC programs into RISC assembly code. Completes the code generation (e.g., by allocating registers). The resulting code is made available as a list of RISC machine instructions.

Source
RISCEncoder.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. RISCEncoder
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new RISCEncoder()

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. val code: Builder[Assembler, Seq[Assembler]]

    The code sequence that is being assembled.

  9. def emit(instr: Assembler): Unit

    Emit a RISC instruction.

  10. def emitcomment(text: String): Unit

    Emit a comment.

  11. def encode(p: RISCProg): Unit

    Encode the given RISC program by emitting the prologue, then the encoding of each of the program's instructions, then the epilogue.

  12. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  14. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  15. val firsttemp: Int

    First and last temporary registers

  16. def gentarget(): Label

    Generate a brand new target label.

    Generate a brand new target label. Shares counter with the transformation phase so that labels are unique.

  17. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  18. def getassem: AssemCode

    Return the raw assembler code

  19. def getcode: Code

    Compute the final code sequence.

    Compute the final code sequence. Compared to the one in the code buffer, symbolic labels are resolved into numeric displacements and all pseudo-instructions (comments and labels) are stripped before the code is returned.

  20. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  21. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  22. val lasttemp: Int

  23. val memreg: Int

    Local register to use for base address of memory block.

  24. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  25. final def notify(): Unit

    Definition Classes
    AnyRef
  26. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  27. val reg: (RISCTree) ⇒ RegNo

    Register allocation - we use an attribute grammar to implement a stack style allocation of registers.

    Register allocation - we use an attribute grammar to implement a stack style allocation of registers. Unless a specific node type is handled by a special case, this attribution assumes that the children of each node will be evaluated in left to right order.

  28. def resetcode(): Unit

    Reset the code cache

  29. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  30. def toString(): String

    Definition Classes
    AnyRef → Any
  31. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  32. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  33. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped