comet2コマンド実行時のリセット位置を変更
[YACASL2.git] / test / integration / casl2 / sum_10_s / 0.txt
1 ../../../../casl2 -s ../../../../as/FUNC/sum_10.casl
2
3 Assemble ../../../../as/FUNC/sum_10.casl (0)
4 ../../../../as/FUNC/sum_10.casl:    1:;;; sum_10.casl
5 ../../../../as/FUNC/sum_10.casl:    2:;;; 出力 GR0: 1から10までの整数をすべて加算した値
6 ../../../../as/FUNC/sum_10.casl:    3:MAIN    START
7 ../../../../as/FUNC/sum_10.casl:    4:        PUSH    0,GR1
8 ../../../../as/FUNC/sum_10.casl:    5:        LAD     GR0,0           ; GR0を初期化
9 ../../../../as/FUNC/sum_10.casl:    6:        LD      GR1,FST         ; GR1に初項を転送
10 ../../../../as/FUNC/sum_10.casl:    7:LOOP    ADDL    GR0,GR1         ; ループ先頭
11 ../../../../as/FUNC/sum_10.casl:    8:        ADDL    GR1,STEP        ; GR1 <- GR1 + 公差
12 ../../../../as/FUNC/sum_10.casl:    9:        CPL     GR1,LST         ; GR1が末項より大きい場合は終了
13 ../../../../as/FUNC/sum_10.casl:   10:        JPL     FIN             ; ↓
14 ../../../../as/FUNC/sum_10.casl:   11:        JUMP    LOOP            ; ループ終端
15 ../../../../as/FUNC/sum_10.casl:   12:FIN     POP     GR1
16 ../../../../as/FUNC/sum_10.casl:   13:        RET
17 ../../../../as/FUNC/sum_10.casl:   14:FST     DC      1               ; 初項
18 ../../../../as/FUNC/sum_10.casl:   15:LST     DC      10              ; 末項
19 ../../../../as/FUNC/sum_10.casl:   16:STEP    DC      1               ; 公差
20 ../../../../as/FUNC/sum_10.casl:   17:        END
21
22 Assemble ../../../../as/FUNC/sum_10.casl (1)