diff -r e85600529ca5 -r 4794759139ea progs/LOOP.j --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/progs/LOOP.j Sat Jun 15 09:23:18 2013 -0400 @@ -0,0 +1,90 @@ + +.class public LOOP.LOOP +.super java/lang/Object + +.method public ()V + aload_0 + invokenonvirtual java/lang/Object/()V + return +.end method + +.method public static write(I)V + .limit locals 5 + .limit stack 5 + iload 0 + getstatic java/lang/System/out Ljava/io/PrintStream; + swap + invokevirtual java/io/PrintStream/println(I)V + return +.end method + + +.method public static main([Ljava/lang/String;)V + .limit locals 200 + .limit stack 200 + +ldc 750000 +istore 0 +iload 0 +istore 1 +iload 0 +istore 2 +iload 0 +istore 3 + +Loop_begin_48: + +ldc 0 +iload 1 +if_icmpge Loop_end_49 + +Loop_begin_50: + +ldc 0 +iload 2 +if_icmpge Loop_end_51 + +Loop_begin_52: + +ldc 0 +iload 3 +if_icmpge Loop_end_53 +iload 3 +ldc 1 +isub +istore 3 +goto Loop_begin_52 + +Loop_end_53: + +iload 0 +istore 3 +iload 2 +ldc 1 +isub +istore 2 +goto Loop_begin_50 + +Loop_end_51: + +iload 0 +istore 2 +iload 1 +ldc 1 +isub +istore 1 +goto Loop_begin_48 + +Loop_end_49: + +iload 1 +invokestatic LOOP/LOOP/write(I)V +iload 2 +invokestatic LOOP/LOOP/write(I)V +iload 3 +invokestatic LOOP/LOOP/write(I)V + + + return + +.end method