📄 load.asm
字号:
;
; Copyright 1999 by Texas Instruments Incorporated.
; All rights reserved. Property of Texas Instruments Incorporated.
; Restricted rights to use, duplicate or disclose this code are
; granted through contract.
; U.S. Patent Nos. 5,283,900 5,392,448
;
; "@(#) BIOS-C54x 3.01b 09-07-99 (bios54x-b15)"
;
; Copyright 1999 by Texas Instruments Incorporated.
; All rights reserved. Property of Texas Instruments Incorporated.
; Restricted rights to use, duplicate or disclose this code are
; granted through contract.
; U.S. Patent Nos. 5,283,900 5,392,448
;
;
.mmregs
.global _load
.text
N .set 24 ; multiple of four.
;
; ======== _load ========
; This function simulates a load on the DSP by executing N * loopCount
; instructions, where loopCount is the input parameter to load().
;
; true execution time: (loadValue)*((N/4 + 25) + 13
;
; void load(unsigned int loadValue)
;
; Preconditions: a = loadValue
;
; Postconditions: none.
;
; Modifies: a
;
_load:
sub #1, a
stlm a, ar4 ; ar4 = loopCount - 1
ld #(N/4-2), a ; a = (N / 4) - 2
loop:
stlm a,brc ; initialize count register for block rpt
nop
nop
rptb $1
nop
nop
; nop ; add +1
nop
$1 nop
banz loop, *ar4-
; rpt #10
; nop ; if add +10
; nop
.if __far_mode ; -mf flag will assemble far mode return opcode
fret
.else
ret
.endif
;/* end load() */
.end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -