Interface Memory

  • All Superinterfaces:
    All Known Implementing Classes:

    public interface Memory
    extends Plugin
    Memory plugin root interface.

    Memory can define a "memory context", which can enable additional non-standard functionality, which can be used by other plugins.

    See Also:
    • Method Detail

      • setProgramLocation

        void setProgramLocation​(int location)
        Sets program start address.

        This method is called by main module when compiler finishes compilation process and return known start address of compiled program. This start address is then used by CPU, in reset operation - PC (program counter, or something similar) should be set to this address, accessible via IMemoryContext.getProgramStart() method.

        location - starting memory position (address) of a program
      • getSize

        int getSize()
        Gets size of memory.

        If memory uses some techniques as banking, real size of the memory is not computed. It is only returned a value set in architecture configuration.

        basic size of the memory
      • getProgramLocation

        int getProgramLocation()
        Gets program's start address.

        The start address is set invoking memory's method Memory.setProgramStart() by main module when compiler finishes compilation process of a program and if the compiler know the starting address. This address is used by main module for CPU reset process.

        program's start address in memory