📄 test.s
字号:
;;
;; the assembler used debug interface to user logic of nios module;
;; nasys_vector_table is interrupt vector table;
;; na_plus_0_irq is interrupt value of interface to user logic;
;; na_plus_0 is address of interface to user logic;
;;
.include "excalibur.s"
.text
.global _start
_start:
MOVIA %l0,plus_irq@h
MOVIA %l1,nasys_vector_table
PFX na_plus_0_irq
ST [%l1],%l0 ; install trap handler
movia %l0,na_plus_0
movia %g1,10000
movi %g2,1
movi %g3,0
stp [%l0,2],%g1
stp [%l0,0],%g2
stp [%l0,0],%g3
movia %g0,10
pfx 9
wrctl %l0
loop: nop
br loop
nop
nop
plus_irq:
movia %l0,na_plus_0
inc %g0
cmp %g0,%g1
ifs cc_eq
movi %g0,0
nop
stp [%l0,1],%g0
stp [%l0,0],%g2
stp [%l0,0],%g3
tret %o7
nop
; end of file
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -