TOS - RTSHC08.c

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

TOS - RTSHC08.c

跳至解决方案
1,614 次查看
roberto_m
Contributor III

Hi to all,

Looking into RTSHC08.c I've found:

void _ICMP(int j, ...) {
/* DESC:     16 bit compare i <rel> j
   IN:       X:A i, TOS j
   OUT:
   WRITTEN:  A,H,X */

  asm {
                CPX     j:0
                BNE     _ICMP_0
                CMP     j:1
                BEQ     _ICMP_0
                CLRA
                BCS     _ICMP_1
                LDA     #2
  _ICMP_1:       ;
                CMP     #1
  _ICMP_0:       ; // flags are set for i - j
                _PUL_RA
                AIS     #2                      ; // free pushed parameter
                JMP     0,X ! {HX+SR}, {HX+A}
  }
}

 

What is TOS? It is very popular in that file, but no documentation on it. Is it a command? what does it mean (transfer on stack?)?

标签 (1)
0 项奖励
回复
1 解答
1,018 次查看
tonyp
Senior Contributor II

TOS (in this context) usually stands for Top Of Stack.

在原帖中查看解决方案

0 项奖励
回复
1 回复
1,019 次查看
tonyp
Senior Contributor II

TOS (in this context) usually stands for Top Of Stack.

0 项奖励
回复