Package mars.mips.hardware
Class AddressErrorException
java.lang.Object
java.lang.Throwable
java.lang.Exception
mars.mips.hardware.AddressErrorException
- All Implemented Interfaces:
Serializable
Represents MIPS AddressErrorException. This is generated by the assembler when the
source code references a memory address not valid for the context.
- Version:
- August 2003
- Author:
- Pete Sanderson
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionAddressErrorException
(String message, int type, int address) Constructor for the AddressErrorException class -
Method Summary
Modifier and TypeMethodDescriptionint
Get the erroneous memory address.int
getType()
Get the exception type (load or store).Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
AddressErrorException
Constructor for the AddressErrorException class- Parameters:
message
- The error message, which will be followed by the address.type
- The exception type: Exceptions.ADDRESS_EXCEPTION_LOAD, Exceptions.ADDRESS_EXCEPTION_STOREaddress
- The erroneous memory address.
-
-
Method Details
-
getType
public int getType()Get the exception type (load or store).- Returns:
- The exception type: Exceptions.ADDRESS_EXCEPTION_LOAD, Exceptions.ADDRESS_EXCEPTION_STORE
-
getAddress
public int getAddress()Get the erroneous memory address.- Returns:
- The erroneous memory address.
-