Because there is noplace to put the return address.
The register $ra
is already in use.
The picture shows main
calling
mySub
.
Two arguments are passed,
in $a0
and $a1
.
The subroutine reads the arguments from those
registers.
In the picture,
the arguments are set up with move
and li
instructions,
but any means of loading the argument registers
can be used.
The Simple Linkage Convention is limited in some obvious ways. A more advanced calling convention is discussed in the next chapter.
The caller and the subroutine should communicate only through arguments and return values all contained in registers. The code for the subroutine should not use any symbolic address defined in the caller.