org.xwt.mips
Class Interpreter

java.lang.Object
  extended byorg.xwt.mips.VM
      extended byorg.xwt.mips.Interpreter
All Implemented Interfaces:
org.xwt.mips.Errno, org.xwt.mips.Syscalls

public class Interpreter
extends VM


Nested Class Summary
 class Interpreter.DebugShutdownHook
           
 
Nested classes inherited from class org.xwt.mips.VM
VM.EmulationException, VM.FaultException, VM.FileDescriptor, VM.FileFileInfo, VM.InputStreamFD, VM.OutputStreamFD, VM.ReadFaultException, VM.RegularFileDescriptor, VM.WriteFaultException
 
Field Summary
 
Fields inherited from class org.xwt.mips.VM
__ELASTERROR, A0, A1, A2, A3, ARGS_ADDR, AT, brk, BRK_LIMIT, DONE, EACCES, EADDRINUSE, EADDRNOTAVAIL, EADV, EAFNOSUPPORT, EAGAIN, EALREADY, EBADE, EBADF, EBADFD, EBADMSG, EBADR, EBADRQC, EBADSLT, EBFONT, EBUSY, ECASECLASH, ECHILD, ECHRNG, ECOMM, ECONNABORTED, ECONNREFUSED, ECONNRESET, EDEADLK, EDEADLOCK, EDESTADDRREQ, EDOM, EDOTDOT, EDQUOT, EEXIST, EFAULT, EFBIG, EFTYPE, EHOSTDOWN, EHOSTUNREACH, EIDRM, EILSEQ, EINPROGRESS, EINTR, EINVAL, EIO, EISCONN, EISDIR, ELBIN, ELIBACC, ELIBBAD, ELIBEXEC, ELIBMAX, ELIBSCN, ELNRNG, ELOOP, EMFILE, EMLINK, EMSGSIZE, EMULTIHOP, ENAMETOOLONG, ENETDOWN, ENETRESET, ENETUNREACH, ENFILE, ENMFILE, ENOANO, ENOBUFS, ENOCSI, ENODATA, ENODEV, ENOENT, ENOEXEC, ENOLCK, ENOLINK, ENOMEDIUM, ENOMEM, ENOMSG, ENONET, ENOPKG, ENOPROTOOPT, ENOSHARE, ENOSPC, ENOSR, ENOSTR, ENOSYS, ENOTBLK, ENOTCONN, ENOTDIR, ENOTEMPTY, ENOTSOCK, ENOTSUP, ENOTTY, ENOTUNIQ, entryPoint, ENXIO, EOPNOTSUPP, EOVERFLOW, EPERM, EPFNOSUPPORT, EPIPE, EPROCLIM, EPROTO, EPROTONOSUPPORT, EPROTOTYPE, ERANGE, EREMCHG, EREMOTE, EROFS, ESHUTDOWN, ESOCKTNOSUPPORT, ESPIPE, ESRCH, ESRMNT, ESTALE, ETIME, ETIMEDOUT, ETOOMANYREFS, ETXTBSY, EUNATCH, EUSERS, EXDEV, EXFULL, exitStatus, FP, GP, INITIAL_SP, INITIALIZED, K0, K1, PAGE_SHIFT, PAGE_SIZE, PAGE_WORDS, PAUSED, PID, RA, readPages, RUNNING, S0, S1, S2, S3, S4, S5, S6, S7, SP, STACK_PAGES, state, SYS_close, SYS_exit, SYS_fstat, SYS_getpid, SYS_isatty, SYS_kill, SYS_null, SYS_open, SYS_pause, SYS_read, SYS_sbrk, SYS_seek, SYS_write, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, TOTAL_PAGES, UNINITIALIZED, USER_INFO_ADDR, V0, V1, writePages, ZERO
 
Constructor Summary
Interpreter()
           
Interpreter(byte[] image)
           
Interpreter(java.lang.String image)
           
 
Method Summary
protected  void _start(int pc)
           
 void execute()
           
static void main(java.lang.String[] argv)
           
 java.lang.String sourceLine(int pc)
           
 
Methods inherited from class org.xwt.mips.VM
copyin, copyout, cstring, exitStatus, getState, getUserInfo, initPage, max, memRead, memWrite, min, run, sbrk, setUserInfo, start, syscall, toHex
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Interpreter

public Interpreter()

Interpreter

public Interpreter(java.lang.String image)
            throws java.io.IOException

Interpreter

public Interpreter(byte[] image)
            throws java.io.IOException
Method Detail

execute

public void execute()
             throws VM.EmulationException
Specified by:
execute in class VM
Throws:
VM.EmulationException

_start

protected void _start(int pc)
Specified by:
_start in class VM

sourceLine

public java.lang.String sourceLine(int pc)

main

public static void main(java.lang.String[] argv)
                 throws java.lang.Exception
Throws:
java.lang.Exception