Hello,
I'm hoping someone can tell me what's wrong with the small linear assembly function I wrote for a C6713 below, to copy integers from one buffer to another (with variable increment size). When used for 1024 samples, only about 380 get copied correctly. If using the C memcpy() call, all 1024 are copied correctly.
Regards,
Robert
----------------------------------------------
.global _cp_i2i
_cp_i2i: .cproc dst, src, d_inc, s_inc, size
.reg aa
.no_mdep
lp_0: .trip size
ldh *src++[s_inc], aa
sth aa, *dst++[d_inc]
[size] sub size, 1, size
[size] b lp_0
.return
.endproc