coursework/cw04.tex
changeset 706 b560f78781b9
parent 630 9b1c15c3eb6f
child 719 0de3527e6ae3
equal deleted inserted replaced
705:bfc8703b1527 706:b560f78781b9
     5 
     5 
     6 \begin{document}
     6 \begin{document}
     7 
     7 
     8 %https://github.com/Storyyeller/Krakatau
     8 %https://github.com/Storyyeller/Krakatau
     9 %https://docs.oracle.com/javase/specs/jvms/se7/html/
     9 %https://docs.oracle.com/javase/specs/jvms/se7/html/
       
    10 
       
    11 % Jasmin Tutorial
       
    12 %http://saksagan.ceng.metu.edu.tr/courses/ceng444/link/jvm-cpm.html
    10 
    13 
    11 \section*{Coursework 4 (Strand 1)}
    14 \section*{Coursework 4 (Strand 1)}
    12 
    15 
    13 \noindent This coursework is worth 6\% and is due on 13
    16 \noindent This coursework is worth 6\% and is due on 13
    14 December at 18:00. You are asked to implement a compiler for
    17 December at 18:00. You are asked to implement a compiler for
   381 Label1: 
   384 Label1: 
   382       getstatic java/lang/System/in Ljava/io/InputStream; 
   385       getstatic java/lang/System/in Ljava/io/InputStream; 
   383       invokevirtual java/io/InputStream/read()I 
   386       invokevirtual java/io/InputStream/read()I 
   384       istore 2 
   387       istore 2 
   385       iload 2 
   388       iload 2 
   386       ldc 10   ; the newline delimiter 
   389       ldc 10  ; the newline delimiter for Unix (Windows 13)
   387       isub 
   390       isub 
   388       ifeq Label2 
   391       ifeq Label2 
   389       iload 2 
   392       iload 2 
   390       ldc 32   ; the space delimiter 
   393       ldc 32   ; the space delimiter 
   391       isub 
   394       isub