0da1c5dcca
First commit of the 4.5 version (latest version available)
362 lines
23 KiB
HTML
362 lines
23 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<!--NewPage-->
|
|
<HTML>
|
|
<HEAD>
|
|
<!-- Generated by javadoc (build 1.6.0_33) on Tue Aug 20 12:20:44 EDT 2013 -->
|
|
<TITLE>
|
|
AbstractSyscall
|
|
</TITLE>
|
|
|
|
<META NAME="date" CONTENT="2013-08-20">
|
|
|
|
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
|
|
|
|
<SCRIPT type="text/javascript">
|
|
function windowTitle()
|
|
{
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="AbstractSyscall";
|
|
}
|
|
}
|
|
</SCRIPT>
|
|
<NOSCRIPT>
|
|
</NOSCRIPT>
|
|
|
|
</HEAD>
|
|
|
|
<BODY BGCOLOR="white" onload="windowTitle();">
|
|
<HR>
|
|
|
|
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<A NAME="navbar_top"><!-- --></A>
|
|
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
|
|
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
|
<TR>
|
|
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
|
<A NAME="navbar_top_firstrow"><!-- --></A>
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
|
<TR ALIGN="center" VALIGN="top">
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
|
|
</TR>
|
|
</TABLE>
|
|
</TD>
|
|
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
|
|
</EM>
|
|
</TD>
|
|
</TR>
|
|
|
|
<TR>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
PREV CLASS
|
|
<A HREF="../../../../mars/mips/instructions/syscalls/RandomStreams.html" title="class in mars.mips.instructions.syscalls"><B>NEXT CLASS</B></A></FONT></TD>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
<A HREF="../../../../index.html?mars/mips/instructions/syscalls/AbstractSyscall.html" target="_top"><B>FRAMES</B></A>
|
|
<A HREF="AbstractSyscall.html" target="_top"><B>NO FRAMES</B></A>
|
|
<SCRIPT type="text/javascript">
|
|
<!--
|
|
if(window==top) {
|
|
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
|
}
|
|
//-->
|
|
</SCRIPT>
|
|
<NOSCRIPT>
|
|
<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
|
|
</NOSCRIPT>
|
|
|
|
|
|
</FONT></TD>
|
|
</TR>
|
|
<TR>
|
|
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
|
SUMMARY: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
|
|
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
|
DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
|
|
</TR>
|
|
</TABLE>
|
|
<A NAME="skip-navbar_top"></A>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
|
|
<HR>
|
|
<!-- ======== START OF CLASS DATA ======== -->
|
|
<H2>
|
|
<FONT SIZE="-1">
|
|
mars.mips.instructions.syscalls</FONT>
|
|
<BR>
|
|
Class AbstractSyscall</H2>
|
|
<PRE>
|
|
<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
|
|
<IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>mars.mips.instructions.syscalls.AbstractSyscall</B>
|
|
</PRE>
|
|
<DL>
|
|
<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html" title="interface in mars.mips.instructions.syscalls">Syscall</A></DD>
|
|
</DL>
|
|
<DL>
|
|
<DT><B>Direct Known Subclasses:</B> <DD><A HREF="../../../../mars/mips/instructions/syscalls/SyscallClose.html" title="class in mars.mips.instructions.syscalls">SyscallClose</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallConfirmDialog.html" title="class in mars.mips.instructions.syscalls">SyscallConfirmDialog</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallExit.html" title="class in mars.mips.instructions.syscalls">SyscallExit</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallExit2.html" title="class in mars.mips.instructions.syscalls">SyscallExit2</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallInputDialogDouble.html" title="class in mars.mips.instructions.syscalls">SyscallInputDialogDouble</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallInputDialogFloat.html" title="class in mars.mips.instructions.syscalls">SyscallInputDialogFloat</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallInputDialogInt.html" title="class in mars.mips.instructions.syscalls">SyscallInputDialogInt</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallInputDialogString.html" title="class in mars.mips.instructions.syscalls">SyscallInputDialogString</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMessageDialog.html" title="class in mars.mips.instructions.syscalls">SyscallMessageDialog</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMessageDialogDouble.html" title="class in mars.mips.instructions.syscalls">SyscallMessageDialogDouble</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMessageDialogFloat.html" title="class in mars.mips.instructions.syscalls">SyscallMessageDialogFloat</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMessageDialogInt.html" title="class in mars.mips.instructions.syscalls">SyscallMessageDialogInt</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMessageDialogString.html" title="class in mars.mips.instructions.syscalls">SyscallMessageDialogString</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMidiOut.html" title="class in mars.mips.instructions.syscalls">SyscallMidiOut</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallMidiOutSync.html" title="class in mars.mips.instructions.syscalls">SyscallMidiOutSync</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallOpen.html" title="class in mars.mips.instructions.syscalls">SyscallOpen</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintChar.html" title="class in mars.mips.instructions.syscalls">SyscallPrintChar</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintDouble.html" title="class in mars.mips.instructions.syscalls">SyscallPrintDouble</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintFloat.html" title="class in mars.mips.instructions.syscalls">SyscallPrintFloat</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintInt.html" title="class in mars.mips.instructions.syscalls">SyscallPrintInt</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintIntBinary.html" title="class in mars.mips.instructions.syscalls">SyscallPrintIntBinary</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintIntHex.html" title="class in mars.mips.instructions.syscalls">SyscallPrintIntHex</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintIntUnsigned.html" title="class in mars.mips.instructions.syscalls">SyscallPrintIntUnsigned</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallPrintString.html" title="class in mars.mips.instructions.syscalls">SyscallPrintString</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallRandDouble.html" title="class in mars.mips.instructions.syscalls">SyscallRandDouble</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallRandFloat.html" title="class in mars.mips.instructions.syscalls">SyscallRandFloat</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallRandInt.html" title="class in mars.mips.instructions.syscalls">SyscallRandInt</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallRandIntRange.html" title="class in mars.mips.instructions.syscalls">SyscallRandIntRange</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallRandSeed.html" title="class in mars.mips.instructions.syscalls">SyscallRandSeed</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallRead.html" title="class in mars.mips.instructions.syscalls">SyscallRead</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallReadChar.html" title="class in mars.mips.instructions.syscalls">SyscallReadChar</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallReadDouble.html" title="class in mars.mips.instructions.syscalls">SyscallReadDouble</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallReadFloat.html" title="class in mars.mips.instructions.syscalls">SyscallReadFloat</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallReadInt.html" title="class in mars.mips.instructions.syscalls">SyscallReadInt</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallReadString.html" title="class in mars.mips.instructions.syscalls">SyscallReadString</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallSbrk.html" title="class in mars.mips.instructions.syscalls">SyscallSbrk</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallSleep.html" title="class in mars.mips.instructions.syscalls">SyscallSleep</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallTime.html" title="class in mars.mips.instructions.syscalls">SyscallTime</A>, <A HREF="../../../../mars/mips/instructions/syscalls/SyscallWrite.html" title="class in mars.mips.instructions.syscalls">SyscallWrite</A></DD>
|
|
</DL>
|
|
<HR>
|
|
<DL>
|
|
<DT><PRE>public abstract class <B>AbstractSyscall</B><DT>extends <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A><DT>implements <A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html" title="interface in mars.mips.instructions.syscalls">Syscall</A></DL>
|
|
</PRE>
|
|
|
|
<P>
|
|
Abstract class that a MIPS syscall system service may extend. A qualifying service
|
|
must be a class in the mars.mips.instructions.syscalls package that
|
|
implements the Syscall interface, must be compiled into a .class file,
|
|
and its .class file must be in the same folder as Syscall.class.
|
|
Mars will detect a qualifying syscall upon startup, create an instance
|
|
using its no-argument constructor and add it to its syscall list.
|
|
When its service is invoked at runtime ("syscall" instruction
|
|
with its service number stored in register $v0), its simulate()
|
|
method will be invoked.
|
|
<P>
|
|
|
|
<P>
|
|
<HR>
|
|
|
|
<P>
|
|
|
|
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
|
|
|
<A NAME="constructor_summary"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
|
<B>Constructor Summary</B></FONT></TH>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD><CODE><B><A HREF="../../../../mars/mips/instructions/syscalls/AbstractSyscall.html#AbstractSyscall(int, java.lang.String)">AbstractSyscall</A></B>(int number,
|
|
<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> name)</CODE>
|
|
|
|
<BR>
|
|
Constructor is provided so subclass may initialize instance variables.</TD>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<!-- ========== METHOD SUMMARY =========== -->
|
|
|
|
<A NAME="method_summary"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
|
|
<B>Method Summary</B></FONT></TH>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A></CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../mars/mips/instructions/syscalls/AbstractSyscall.html#getName()">getName</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Return the name you have chosen for this syscall.</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> int</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../mars/mips/instructions/syscalls/AbstractSyscall.html#getNumber()">getNumber</A></B>()</CODE>
|
|
|
|
<BR>
|
|
Return the assigned service number.</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE> void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../mars/mips/instructions/syscalls/AbstractSyscall.html#setNumber(int)">setNumber</A></B>(int num)</CODE>
|
|
|
|
<BR>
|
|
Set the service number.</TD>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
|
<CODE>abstract void</CODE></FONT></TD>
|
|
<TD><CODE><B><A HREF="../../../../mars/mips/instructions/syscalls/AbstractSyscall.html#simulate(mars.ProgramStatement)">simulate</A></B>(<A HREF="../../../../mars/ProgramStatement.html" title="class in mars">ProgramStatement</A> statement)</CODE>
|
|
|
|
<BR>
|
|
Performs syscall function.</TD>
|
|
</TR>
|
|
</TABLE>
|
|
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
|
<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
|
|
</TR>
|
|
<TR BGCOLOR="white" CLASS="TableRowColor">
|
|
<TD><CODE><A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<P>
|
|
|
|
<!-- ========= CONSTRUCTOR DETAIL ======== -->
|
|
|
|
<A NAME="constructor_detail"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
|
|
<B>Constructor Detail</B></FONT></TH>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<A NAME="AbstractSyscall(int, java.lang.String)"><!-- --></A><H3>
|
|
AbstractSyscall</H3>
|
|
<PRE>
|
|
public <B>AbstractSyscall</B>(int number,
|
|
<A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> name)</PRE>
|
|
<DL>
|
|
<DD>Constructor is provided so subclass may initialize instance variables.
|
|
<P>
|
|
<DL>
|
|
<DT><B>Parameters:</B><DD><CODE>number</CODE> - default assigned service number<DD><CODE>name</CODE> - service name which may be used for reference independent of number</DL>
|
|
</DL>
|
|
|
|
<!-- ============ METHOD DETAIL ========== -->
|
|
|
|
<A NAME="method_detail"><!-- --></A>
|
|
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
|
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
|
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
|
|
<B>Method Detail</B></FONT></TH>
|
|
</TR>
|
|
</TABLE>
|
|
|
|
<A NAME="getName()"><!-- --></A><H3>
|
|
getName</H3>
|
|
<PRE>
|
|
public <A HREF="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A> <B>getName</B>()</PRE>
|
|
<DL>
|
|
<DD>Return the name you have chosen for this syscall. This can be used by a MARS
|
|
user to refer to the service when choosing to override its default service
|
|
number in the configuration file.
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html#getName()">getName</A></CODE> in interface <CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html" title="interface in mars.mips.instructions.syscalls">Syscall</A></CODE></DL>
|
|
</DD>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>service name as a string</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="setNumber(int)"><!-- --></A><H3>
|
|
setNumber</H3>
|
|
<PRE>
|
|
public void <B>setNumber</B>(int num)</PRE>
|
|
<DL>
|
|
<DD>Set the service number. This is provided to allow MARS implementer or user
|
|
to override the default service number.
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html#setNumber(int)">setNumber</A></CODE> in interface <CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html" title="interface in mars.mips.instructions.syscalls">Syscall</A></CODE></DL>
|
|
</DD>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>num</CODE> - specified service number to override the default.</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="getNumber()"><!-- --></A><H3>
|
|
getNumber</H3>
|
|
<PRE>
|
|
public int <B>getNumber</B>()</PRE>
|
|
<DL>
|
|
<DD>Return the assigned service number. This is the number the MIPS programmer
|
|
must store into $v0 before issuing the SYSCALL instruction.
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html#getNumber()">getNumber</A></CODE> in interface <CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html" title="interface in mars.mips.instructions.syscalls">Syscall</A></CODE></DL>
|
|
</DD>
|
|
<DD><DL>
|
|
|
|
<DT><B>Returns:</B><DD>assigned service number</DL>
|
|
</DD>
|
|
</DL>
|
|
<HR>
|
|
|
|
<A NAME="simulate(mars.ProgramStatement)"><!-- --></A><H3>
|
|
simulate</H3>
|
|
<PRE>
|
|
public abstract void <B>simulate</B>(<A HREF="../../../../mars/ProgramStatement.html" title="class in mars">ProgramStatement</A> statement)
|
|
throws <A HREF="../../../../mars/ProcessingException.html" title="class in mars">ProcessingException</A></PRE>
|
|
<DL>
|
|
<DD>Performs syscall function. It will be invoked when the service is invoked
|
|
at simulation time. Service is identified by value stored in $v0.
|
|
<P>
|
|
<DD><DL>
|
|
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html#simulate(mars.ProgramStatement)">simulate</A></CODE> in interface <CODE><A HREF="../../../../mars/mips/instructions/syscalls/Syscall.html" title="interface in mars.mips.instructions.syscalls">Syscall</A></CODE></DL>
|
|
</DD>
|
|
<DD><DL>
|
|
<DT><B>Parameters:</B><DD><CODE>statement</CODE> - ProgramStatement object for this syscall instruction.
|
|
<DT><B>Throws:</B>
|
|
<DD><CODE><A HREF="../../../../mars/ProcessingException.html" title="class in mars">ProcessingException</A></CODE></DL>
|
|
</DD>
|
|
</DL>
|
|
<!-- ========= END OF CLASS DATA ========= -->
|
|
<HR>
|
|
|
|
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<A NAME="navbar_bottom"><!-- --></A>
|
|
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
|
|
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
|
<TR>
|
|
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
|
<A NAME="navbar_bottom_firstrow"><!-- --></A>
|
|
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
|
<TR ALIGN="center" VALIGN="top">
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
|
|
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
|
|
</TR>
|
|
</TABLE>
|
|
</TD>
|
|
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
|
|
</EM>
|
|
</TD>
|
|
</TR>
|
|
|
|
<TR>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
PREV CLASS
|
|
<A HREF="../../../../mars/mips/instructions/syscalls/RandomStreams.html" title="class in mars.mips.instructions.syscalls"><B>NEXT CLASS</B></A></FONT></TD>
|
|
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
|
<A HREF="../../../../index.html?mars/mips/instructions/syscalls/AbstractSyscall.html" target="_top"><B>FRAMES</B></A>
|
|
<A HREF="AbstractSyscall.html" target="_top"><B>NO FRAMES</B></A>
|
|
<SCRIPT type="text/javascript">
|
|
<!--
|
|
if(window==top) {
|
|
document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
|
}
|
|
//-->
|
|
</SCRIPT>
|
|
<NOSCRIPT>
|
|
<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
|
|
</NOSCRIPT>
|
|
|
|
|
|
</FONT></TD>
|
|
</TR>
|
|
<TR>
|
|
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
|
SUMMARY: NESTED | FIELD | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
|
|
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
|
DETAIL: FIELD | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
|
|
</TR>
|
|
</TABLE>
|
|
<A NAME="skip-navbar_bottom"></A>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
|
|
<HR>
|
|
|
|
</BODY>
|
|
</HTML>
|