progs/LOOP.j
changeset 93 4794759139ea
child 94 9ea667baf097
equal deleted inserted replaced
92:e85600529ca5 93:4794759139ea
       
     1 
       
     2 .class public LOOP.LOOP
       
     3 .super java/lang/Object
       
     4 
       
     5 .method public <init>()V
       
     6    aload_0
       
     7    invokenonvirtual java/lang/Object/<init>()V
       
     8    return
       
     9 .end method
       
    10 
       
    11 .method public static write(I)V 
       
    12     .limit locals 5 
       
    13     .limit stack 5 
       
    14     iload 0 
       
    15     getstatic java/lang/System/out Ljava/io/PrintStream; 
       
    16     swap 
       
    17     invokevirtual java/io/PrintStream/println(I)V 
       
    18     return 
       
    19 .end method
       
    20 
       
    21 
       
    22 .method public static main([Ljava/lang/String;)V
       
    23    .limit locals 200
       
    24    .limit stack 200
       
    25 
       
    26 ldc 750000
       
    27 istore 0
       
    28 iload 0
       
    29 istore 1
       
    30 iload 0
       
    31 istore 2
       
    32 iload 0
       
    33 istore 3
       
    34 
       
    35 Loop_begin_48:
       
    36 
       
    37 ldc 0
       
    38 iload 1
       
    39 if_icmpge Loop_end_49
       
    40 
       
    41 Loop_begin_50:
       
    42 
       
    43 ldc 0
       
    44 iload 2
       
    45 if_icmpge Loop_end_51
       
    46 
       
    47 Loop_begin_52:
       
    48 
       
    49 ldc 0
       
    50 iload 3
       
    51 if_icmpge Loop_end_53
       
    52 iload 3
       
    53 ldc 1
       
    54 isub
       
    55 istore 3
       
    56 goto Loop_begin_52
       
    57 
       
    58 Loop_end_53:
       
    59 
       
    60 iload 0
       
    61 istore 3
       
    62 iload 2
       
    63 ldc 1
       
    64 isub
       
    65 istore 2
       
    66 goto Loop_begin_50
       
    67 
       
    68 Loop_end_51:
       
    69 
       
    70 iload 0
       
    71 istore 2
       
    72 iload 1
       
    73 ldc 1
       
    74 isub
       
    75 istore 1
       
    76 goto Loop_begin_48
       
    77 
       
    78 Loop_end_49:
       
    79 
       
    80 iload 1
       
    81 invokestatic LOOP/LOOP/write(I)V
       
    82 iload 2
       
    83 invokestatic LOOP/LOOP/write(I)V
       
    84 iload 3
       
    85 invokestatic LOOP/LOOP/write(I)V
       
    86 
       
    87 
       
    88    return
       
    89 
       
    90 .end method