6502 装配 JMP
如果我使用这个操作码
JMP
Jump to New Location
(PC+1) -> PCL
(PC+2) -> PCH
N Z C I D V
- - - - - -
addressing assembler opc bytes cycles
absolute JMP oper 4C 3 3
并给它一个十六进制值,比如 0x0604,它会跳转到该位置执行那里的内容,然后继续直到它返回到 JMP 语句,还是会执行 0x0604 处的内容,然后执行联合管理计划
If I use this opcode
JMP
Jump to New Location
(PC+1) -> PCL
(PC+2) -> PCH
N Z C I D V
- - - - - -
addressing assembler opc bytes cycles
absolute JMP oper 4C 3 3
and give it a hex value of say 0x0604 will it jump to that location execute what's there and then continue until it gets back to the JMP statement, or will it execute whats at 0x0604 and then do the next instruction after the JMP
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
JMP $0604
指令会将程序计数器更改为值$0604
,然后开始执行从地址$0604
开始的指令。它不会返回到JMP
之后的指令。为此,您需要将JMP
更改为JSR
,并确保$604
处的子例程代码具有RTS 指令从子程序返回。
A
JMP $0604
instruction will change the program counter to the value$0604
and then start executing the instructions starting at address$0604
. It will not return back to the instruction after theJMP
. To accomplish that you need to change theJMP
to aJSR
, and make sure the subroutine code at$604
has anRTS
instruction to return from the subroutine.