URL
https://opencores.org/ocsvn/xulalx25soc/xulalx25soc/trunk
Subversion Repositories xulalx25soc
[/] [xulalx25soc/] [trunk/] [bench/] [asm/] [genlrs.S] - Rev 47
Go to most recent revision | Compare with Previous | Blame | View Log
//////////////////////////////////////////////////////////////////////////////////// Filename: genlrs.S//// Project: XuLA2 board//// Purpose:////// Creator: Dan Gisselquist, Ph.D.// Gisselquist Technology, LLC////////////////////////////////////////////////////////////////////////////////////// Copyright (C) 2015, Gisselquist Technology, LLC//// This program is free software (firmware): you can redistribute it and/or// modify it under the terms of the GNU General Public License as published// by the Free Software Foundation, either version 3 of the License, or (at// your option) any later version.//// This program is distributed in the hope that it will be useful, but WITHOUT// ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY or// FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License// for more details.//// License: GPL, v3, as defined and found on www.gnu.org,// http://www.gnu.org/licenses/gpl.html////////////////////////////////////////////////////////////////////////////////////////entry:; ; R0 -- used by test_lrs; ; R1 -- used by test_lrs; ; R2 -- used by test_lrs; ; R3 = return addressLDI 0x80000000,R4 ; TapsLDI 0x00800000,R6 ; Current Memory AddressMOV R6,R7 ; Start of memoryLDI 0x00ffffff,R8 ; End of memorytest_next_lrs:MOV __HERE__+2(PC),R3BRA test_lrsCMP 0,R0BGE next_tap_setSTO R0,(R6)ADD 1,R6AND R8,R6OR R7,R6next_tap_set:ADD 1,R4BNZ test_next_lrsHALTtest_lrs:; R0 = taps on entry; R0 = length on return; R3 = return PC addressCLR R1 ; R1 will be our lengthLDI 1,R2 ; R2 will be our filltest_lrs_loop:LSR 1,R2XOR.C R0,R2ADD 1,R1CMP 1,R2BNZ test_lrs_loopMOV R1,R0MOV R3,PC
Go to most recent revision | Compare with Previous | Blame | View Log
