我现在用DM642开发板学习CCS,现在有一个例程是C5400的,我想照着例程学一下,可是发现指令与C64xx不兼容.有个函数不知怎么改成C64xx的,请大家给指点一下! 附件为整个原程序,怎么改成为C64xx下的程序呢? 下面为我想改动的部分: xtern void load(unsigned int loadValue) .mmregs
.global _load
.text
N .set 1000 ; multiple of four.
; ; ======== _load ======== ; This function simulates a load on the DSP by executing N * loadValue ; instructions, where loadValue is the input parameter to load(). ; ; true execution time: (loadValue)*((N/4 + 25) + 13 ; ; Preconditions: a = loadValue ; ; Postconditions: none. ; ; Modifies: a ; ; void load(unsigned int loadValue) ; _load: bc done, aeq ; done if a = 0 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 $1 nop banz loop, *ar4- 75 done: .if __far_mode ; -mf flag will assemble far mode return opcode fret .else ret .endif ;/* end load() */ .end 相关链接:https://bbs.21ic.com/upfiles/img/20096/200962718482883.rar |