3 ; { dg-do assemble { target cris-*-* } }
5 ; A variant of exbwtest.s. This is an example of invalid use of the broken-
6 ; dot-word function. The nearest label occurs about 32 kbytes after the primary
7 ; jump table so the secondary jump table can't be reached by word displace-
8 ; ments and the broken words overflow.
14 ; for (i=0; i <= 3; i++) {
15 ; result[i] = funct(i);
19 ; Register use : r1 - i
43 ; case 0 : return 0x1111;
44 ; case 1 : return 0x2222;
45 ; case 2 : return 0x3333;
46 ; case 3 : return 0x4444;
52 ; Register use : r1 - pjt address
57 pjt: .word near1 - pjt
62 ; Note that the line-number of the source-location of the error
63 ; seems slightly off from the user perspective, but it's the
64 ; best I could get without major changes in BW-handling. Not
65 ; sure it it's worth fixing. May need adjustments if
66 ; BW-handling changes. Four errors from four .words are what's
69 .space 32760,0xFF; { dg-error "Adjusted signed \.word \(.*\) overflow.*" }
71 near1: move.w 0x1111,r0
75 near2: move.w 0x2222,r0
79 far1: move.w 0x3333,r0
83 far2: move.w 0x4444,r0
88 result: .space 4 * 2 ; static uword result[4];