1 1.1 christos /* 2 1.1 christos * Blackfin testcase for testing illegal/legal 64-bit opcodes (group 2) 3 1.1 christos * from userspace. we track all instructions which cause some sort of 4 1.1 christos * exception when run from userspace, this is normally EXCAUSE : 5 1.1 christos * - 0x22 : illegal instruction combination 6 1.1 christos * and walk every instruction from 0x0000 to 0xffff 7 1.1 christos */ 8 1.1 christos 9 1.1 christos # mach: bfin 10 1.1 christos # sim: --environment operating 11 1.1 christos 12 1.1 christos #include "test.h" 13 1.1 christos .include "testutils.inc" 14 1.1 christos 15 1.1 christos #define SE_ALL_BITS 16 16 1.1 christos #include "se_allopcodes.h" 17 1.1 christos 18 1.1 christos .macro se_all_load_insn 19 1.1 christos R2 = W[P5 + 6]; 20 1.1 christos R0 = R2; 21 1.1 christos .endm 22 1.1 christos 23 1.1 christos .macro se_all_next_insn 24 1.1 christos /* increment, and go again. */ 25 1.1 christos R0 = R2; 26 1.1 christos 27 1.1 christos R0 += 1; 28 1.1 christos /* finish once we hit the 32bit limit */ 29 1.1 christos imm32 R1, 0x10000; 30 1.1 christos CC = R1 == R0; 31 1.1 christos IF CC JUMP pass_lvl; 32 1.1 christos 33 1.1 christos W[P5 + 6] = R0; 34 1.1 christos .endm 35 1.1 christos 36 1.1 christos .macro se_all_insn_init 37 1.1 christos MNOP || NOP || NOP; 38 1.1 christos .endm 39 1.1 christos .macro se_all_insn_table 40 1.1 christos /* this table must be sorted, and end with zero */ 41 1.1 christos /* start end SEQSTAT */ 42 1.1 christos .dw 0x0001, 0x9bff, 0x22 43 1.1 christos .dw 0x9c60, 0x9c7f, 0x22 44 1.1 christos .dw 0x9ce0, 0x9cff, 0x22 45 1.1 christos .dw 0x9d60, 0x9d7f, 0x22 46 1.1 christos .dw 0x9e60, 0x9e7f, 0x22 47 1.1 christos .dw 0x9ee0, 0x9eff, 0x22 48 1.1 christos .dw 0x9f60, 0x9f7f, 0x22 49 1.1 christos .dw 0xa000, 0xffff, 0x22 50 1.1 christos .dw 0x0000, 0x0000, 0x00 51 1.1 christos .endm 52 1.1 christos 53 1.1 christos se_all_test 54