Class Mmu<A extends Address<?>>

  • All Implemented Interfaces:
    Buffer<ru.ispras.fortress.data.types.bitvector.BitVector,​A>, MemoryDevice

    public abstract class Mmu<A extends Address<?>>
    extends java.lang.Object
    implements Buffer<ru.ispras.fortress.data.types.bitvector.BitVector,​A>, MemoryDevice
    • Constructor Summary

      Constructors 
      Constructor Description
      Mmu​(Address<A> addressCreator)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean isHit​(A address)
      Checks whether the given address hits the buffer.
      boolean isInitialized​(ru.ispras.fortress.data.types.bitvector.BitVector address)
      Checks whether the specified address location has been initialized.
      ru.ispras.fortress.data.types.bitvector.BitVector load​(ru.ispras.fortress.data.types.bitvector.BitVector address)
      Loads data from the given address.
      void resetState()
      Resets the state of the buffer.
      void store​(ru.ispras.fortress.data.types.bitvector.BitVector address, int offset, ru.ispras.fortress.data.types.bitvector.BitVector data)
      Stores the specified data at the given address.
      void store​(ru.ispras.fortress.data.types.bitvector.BitVector address, ru.ispras.fortress.data.types.bitvector.BitVector data)
      Stores the specified data at the given address.
      void writeEntry​(A address, int lower, int upper, ru.ispras.fortress.data.types.bitvector.BitVector newData)
      Writes the data associated w/ the given address into the given field of the entry.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Mmu

        public Mmu​(Address<A> addressCreator)
    • Method Detail

      • isInitialized

        public boolean isInitialized​(ru.ispras.fortress.data.types.bitvector.BitVector address)
        Description copied from interface: MemoryDevice
        Checks whether the specified address location has been initialized.
        Specified by:
        isInitialized in interface MemoryDevice
        Parameters:
        address - Address to be checked.
        Returns:
        true is the address location is initialized or false otherwise.
      • isHit

        public boolean isHit​(A address)
        Description copied from interface: Buffer
        Checks whether the given address hits the buffer.
        Specified by:
        isHit in interface Buffer<ru.ispras.fortress.data.types.bitvector.BitVector,​A extends Address<?>>
        Parameters:
        address - the address.
        Returns:
        true iff the address hits the buffer.
      • load

        public ru.ispras.fortress.data.types.bitvector.BitVector load​(ru.ispras.fortress.data.types.bitvector.BitVector address)
        Description copied from interface: MemoryDevice
        Loads data from the given address.
        Specified by:
        load in interface MemoryDevice
        Parameters:
        address - Load address.
        Returns:
        Data of size equal to returned by MemoryDevice.getDataBitSize().
      • store

        public void store​(ru.ispras.fortress.data.types.bitvector.BitVector address,
                          int offset,
                          ru.ispras.fortress.data.types.bitvector.BitVector data)
        Description copied from interface: MemoryDevice
        Stores the specified data at the given address.
        Specified by:
        store in interface MemoryDevice
        Parameters:
        address - Store address.
        offset - Data offset in bits.
        data - Data of size equal to MemoryDevice.getDataBitSize() - offset.
      • store

        public void store​(ru.ispras.fortress.data.types.bitvector.BitVector address,
                          ru.ispras.fortress.data.types.bitvector.BitVector data)
        Description copied from interface: MemoryDevice
        Stores the specified data at the given address.
        Specified by:
        store in interface MemoryDevice
        Parameters:
        address - Store address.
        data - Data of size equal to returned by MemoryDevice.getDataBitSize().
      • writeEntry

        public final void writeEntry​(A address,
                                     int lower,
                                     int upper,
                                     ru.ispras.fortress.data.types.bitvector.BitVector newData)
        Description copied from interface: Buffer
        Writes the data associated w/ the given address into the given field of the entry.
        Specified by:
        writeEntry in interface Buffer<ru.ispras.fortress.data.types.bitvector.BitVector,​A extends Address<?>>
        Parameters:
        address - the address.
        lower - the lower bit.
        upper - the upper bit.
        newData - the new data.
      • resetState

        public void resetState()
        Description copied from interface: Buffer
        Resets the state of the buffer.
        Specified by:
        resetState in interface Buffer<ru.ispras.fortress.data.types.bitvector.BitVector,​A extends Address<?>>