Interaction with the operating system (often for the purpose of I/O operations) can be done using system calls, aka “SuperVisor Calls” (hence SVC) or SoftWare Interrupt. (SWI)

System calls are invoked with the SVC instruction. Most operating systems require that the code indicating which system call is to be run should be in a register (usually R0) as it is non-trivial and unnecessarily resource-intensive to retrieve the immediate operand of the instruction.

For the purpose of this section, the required syscall routine should be indicated by the immediate operand of the SVC instruction, and according to the following specification:

Immediate OperandFunction
0Output the character stored in R0
1Read a single character from the user into R0
2Terminate the process.
3Output the null-terminated string that starts at the address held in R0
4Output the value in R0 as an integer in base-10 (denary/decimal)
5Read an integer in base-10 from the user and store it in R0