Package mars.mips.instructions.syscalls
Class SyscallPrintIntUnsigned
java.lang.Object
mars.mips.instructions.syscalls.AbstractSyscall
mars.mips.instructions.syscalls.SyscallPrintIntUnsigned
- All Implemented Interfaces:
Syscall
Service to display integer stored in $a0 on the console as unsigned decimal.
-
Constructor Summary
ConstructorsConstructorDescriptionBuild an instance of the syscall with its default service number and name. -
Method Summary
Modifier and TypeMethodDescriptionvoid
simulate
(BasicStatement statement) Performs syscall function to print on the console the integer stored in $a0.Methods inherited from class mars.mips.instructions.syscalls.AbstractSyscall
getName, getNumber, setNumber
-
Constructor Details
-
SyscallPrintIntUnsigned
public SyscallPrintIntUnsigned()Build an instance of the syscall with its default service number and name.
-
-
Method Details
-
simulate
Performs syscall function to print on the console the integer stored in $a0. The value is treated as unsigned.- Specified by:
simulate
in interfaceSyscall
- Specified by:
simulate
in classAbstractSyscall
- Parameters:
statement
- BasicStatement object for this syscall instruction.- Throws:
SimulatorException
-