1 # frv testcase to generate insn_access_error interrupt
3 # sim: --memory-region 0xfe800000,0x7f0500 --memory-region 0xfeff0540,0xfb00
4 .include "testutils.inc"
10 and_spr_immed -4081,tbr ; clear tbr.tt
12 inc_gr_immed 0x020,gr17 ; address of exception handler
17 set_spr_addr handler,lr
21 set_gr_addr 0xfe800000,gr17
22 jmpl @(gr17,gr0) ; cause interrupt
27 set_gr_addr 0xfefffffc,gr17
28 jmpl @(gr17,gr0) ; cause interrupt
35 test_spr_immed 0x1,esfr1 ; esr0 is active
36 ; test_spr_gr epcr0,gr17 ; epcr0 is not used
37 test_spr_bits 0x0001,0,0x1,esr0 ; esr0 is valid
38 test_spr_bits 0x003e,1,0x2,esr0 ; esr0.ec is set
39 test_spr_bits 0x0800,11,0x0,esr0 ; esr0.eav is not set