1//Original:/proj/frio/dv/testcases/seq/se_kills2/se_kills2.dsp 2// Description: Test se_kill for all supported types of RTL1 instructions 3# mach: bfin 4# sim: --environment operating 5 6#include "test.h" 7.include "testutils.inc" 8start 9 10// 11// Constants and Defines 12// 13 14include(selfcheck.inc) 15include(std.inc) 16include(symtable.inc) 17 18#ifndef STACKSIZE 19#define STACKSIZE 0x10 20#endif 21 22// 23// Reset/Bootstrap Code 24// (Here we should set the processor operating modes, initialize registers, 25// etc.) 26// 27 28BOOT: 29SP = 0 (Z); 30SP.L = KSTACK; // setup the stack pointer 31SP.H = KSTACK; 32FP = SP; // and frame pointer 33 34INIT_R_REGS(0); // initialize general purpose regs 35 36INIT_P_REGS(0); // initialize the pointers 37 38INIT_I_REGS(0); // initialize the dsp address regs 39INIT_M_REGS(0); 40INIT_L_REGS(0); 41INIT_B_REGS(0); 42 43ASTAT = r0; // reset sequencer registers 44 45// 46// The Main Program 47// 48 49START: 50 51 // **** YOUR CODE GOES HERE **** 52 // CHECK_INIT(p0, 0xFF7FFFFC); // original 53CHECK_INIT_DEF(p0); 54 55 R0 = 0; 56 R1 = 1; 57 R2 = 2; 58 R3 = 3; 59 R4 = 4; 60 R5 = 5; 61 R6 = 6; 62 R7 = 7; 63 P1 = 11; 64 // Assume CC is reset to 0. 65IF !CC JUMP NEXT1; // following instruction should be killed 66RAISE 13; 67 68NEXT1: 69 IF !CC JUMP NEXT2; 70EXCPT 15; 71 72NEXT2: 73 IF !CC JUMP NEXT3; 74 ( R7:0, P5:0 ) = [ SP ++ ]; 75 76NEXT3: 77 IF !CC JUMP NEXT4; 78 [ -- SP ] = ( R7:0, P5:0 ); 79 80NEXT4: 81 IF !CC JUMP NEXT5; 82EMUEXCPT; 83 84NEXT5: 85 IF !CC JUMP NEXT6; 86.dd 0xFACEBABE 87 88NEXT6: 89 IF !CC JUMP NEXT7; 90LINK 12; 91 92NEXT7: 93 IF !CC JUMP NEXT8; 94UNLINK; 95 96NEXT8: 97 IF !CC JUMP NEXT9; 98LSETUP (NEXT10, NEXT11) lc0 = p0; 99 100NEXT9: 101 IF !CC JUMP NEXT10; 102 103NEXT10: 104 IF !CC JUMP NEXT11; 105 106NEXT11: 107 IF !CC JUMP NEXT12; 108 109NEXT12: 110 IF !CC JUMP NEXT13; 111 112NEXT13: 113 IF !CC JUMP NEXT14; 114 115NEXT14: 116 IF !CC JUMP NEXT15; 117 118NEXT15: 119 IF !CC JUMP NEXT16; 120 121NEXT16: 122 123END: 124CHECKREG(r0, 0); 125CHECKREG(r1, 1); 126CHECKREG(r2, 2); 127CHECKREG(r3, 3); 128CHECKREG(r4, 4); 129CHECKREG(r5, 5); 130CHECKREG(r6, 6); 131CHECKREG(r7, 7); 132 133dbg_pass; // Call Endtest Macro 134 135//********************************************************************* 136// 137// Data Segment 138// 139 140//.data 0xF0000000 141.data 142DATA: 143 .space (0x010); // Some data space 144 145// Stack Segments 146 147 .space (STACKSIZE); 148KSTACK: 149