1 /* Simulator instruction decoder for m32rbf.
3 THIS FILE IS MACHINE GENERATED WITH CGEN.
5 Copyright 1996-2018 Free Software Foundation, Inc.
7 This file is part of the GNU simulators.
9 This file is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation; either version 3, or (at your option)
14 It is distributed in the hope that it will be useful, but WITHOUT
15 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
16 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
17 License for more details.
19 You should have received a copy of the GNU General Public License along
20 with this program; if not, see <http://www.gnu.org/licenses/>.
24 #define WANT_CPU m32rbf
25 #define WANT_CPU_M32RBF
28 #include "sim-assert.h"
30 /* The instruction descriptor array.
31 This is computed at runtime. Space for it is not malloc'd to save a
32 teensy bit of cpu in the decoder. Moving it to malloc space is trivial
33 but won't be done until necessary (we don't currently support the runtime
34 addition of instructions nor an SMP machine with different cpus). */
35 static IDESC m32rbf_insn_data
[M32RBF_INSN__MAX
];
37 /* Commas between elements are contained in the macros.
38 Some of these are conditionally compiled out. */
40 static const struct insn_sem m32rbf_insn_sem
[] =
42 { VIRTUAL_INSN_X_INVALID
, M32RBF_INSN_X_INVALID
, M32RBF_SFMT_EMPTY
},
43 { VIRTUAL_INSN_X_AFTER
, M32RBF_INSN_X_AFTER
, M32RBF_SFMT_EMPTY
},
44 { VIRTUAL_INSN_X_BEFORE
, M32RBF_INSN_X_BEFORE
, M32RBF_SFMT_EMPTY
},
45 { VIRTUAL_INSN_X_CTI_CHAIN
, M32RBF_INSN_X_CTI_CHAIN
, M32RBF_SFMT_EMPTY
},
46 { VIRTUAL_INSN_X_CHAIN
, M32RBF_INSN_X_CHAIN
, M32RBF_SFMT_EMPTY
},
47 { VIRTUAL_INSN_X_BEGIN
, M32RBF_INSN_X_BEGIN
, M32RBF_SFMT_EMPTY
},
48 { M32R_INSN_ADD
, M32RBF_INSN_ADD
, M32RBF_SFMT_ADD
},
49 { M32R_INSN_ADD3
, M32RBF_INSN_ADD3
, M32RBF_SFMT_ADD3
},
50 { M32R_INSN_AND
, M32RBF_INSN_AND
, M32RBF_SFMT_ADD
},
51 { M32R_INSN_AND3
, M32RBF_INSN_AND3
, M32RBF_SFMT_AND3
},
52 { M32R_INSN_OR
, M32RBF_INSN_OR
, M32RBF_SFMT_ADD
},
53 { M32R_INSN_OR3
, M32RBF_INSN_OR3
, M32RBF_SFMT_OR3
},
54 { M32R_INSN_XOR
, M32RBF_INSN_XOR
, M32RBF_SFMT_ADD
},
55 { M32R_INSN_XOR3
, M32RBF_INSN_XOR3
, M32RBF_SFMT_AND3
},
56 { M32R_INSN_ADDI
, M32RBF_INSN_ADDI
, M32RBF_SFMT_ADDI
},
57 { M32R_INSN_ADDV
, M32RBF_INSN_ADDV
, M32RBF_SFMT_ADDV
},
58 { M32R_INSN_ADDV3
, M32RBF_INSN_ADDV3
, M32RBF_SFMT_ADDV3
},
59 { M32R_INSN_ADDX
, M32RBF_INSN_ADDX
, M32RBF_SFMT_ADDX
},
60 { M32R_INSN_BC8
, M32RBF_INSN_BC8
, M32RBF_SFMT_BC8
},
61 { M32R_INSN_BC24
, M32RBF_INSN_BC24
, M32RBF_SFMT_BC24
},
62 { M32R_INSN_BEQ
, M32RBF_INSN_BEQ
, M32RBF_SFMT_BEQ
},
63 { M32R_INSN_BEQZ
, M32RBF_INSN_BEQZ
, M32RBF_SFMT_BEQZ
},
64 { M32R_INSN_BGEZ
, M32RBF_INSN_BGEZ
, M32RBF_SFMT_BEQZ
},
65 { M32R_INSN_BGTZ
, M32RBF_INSN_BGTZ
, M32RBF_SFMT_BEQZ
},
66 { M32R_INSN_BLEZ
, M32RBF_INSN_BLEZ
, M32RBF_SFMT_BEQZ
},
67 { M32R_INSN_BLTZ
, M32RBF_INSN_BLTZ
, M32RBF_SFMT_BEQZ
},
68 { M32R_INSN_BNEZ
, M32RBF_INSN_BNEZ
, M32RBF_SFMT_BEQZ
},
69 { M32R_INSN_BL8
, M32RBF_INSN_BL8
, M32RBF_SFMT_BL8
},
70 { M32R_INSN_BL24
, M32RBF_INSN_BL24
, M32RBF_SFMT_BL24
},
71 { M32R_INSN_BNC8
, M32RBF_INSN_BNC8
, M32RBF_SFMT_BC8
},
72 { M32R_INSN_BNC24
, M32RBF_INSN_BNC24
, M32RBF_SFMT_BC24
},
73 { M32R_INSN_BNE
, M32RBF_INSN_BNE
, M32RBF_SFMT_BEQ
},
74 { M32R_INSN_BRA8
, M32RBF_INSN_BRA8
, M32RBF_SFMT_BRA8
},
75 { M32R_INSN_BRA24
, M32RBF_INSN_BRA24
, M32RBF_SFMT_BRA24
},
76 { M32R_INSN_CMP
, M32RBF_INSN_CMP
, M32RBF_SFMT_CMP
},
77 { M32R_INSN_CMPI
, M32RBF_INSN_CMPI
, M32RBF_SFMT_CMPI
},
78 { M32R_INSN_CMPU
, M32RBF_INSN_CMPU
, M32RBF_SFMT_CMP
},
79 { M32R_INSN_CMPUI
, M32RBF_INSN_CMPUI
, M32RBF_SFMT_CMPI
},
80 { M32R_INSN_DIV
, M32RBF_INSN_DIV
, M32RBF_SFMT_DIV
},
81 { M32R_INSN_DIVU
, M32RBF_INSN_DIVU
, M32RBF_SFMT_DIV
},
82 { M32R_INSN_REM
, M32RBF_INSN_REM
, M32RBF_SFMT_DIV
},
83 { M32R_INSN_REMU
, M32RBF_INSN_REMU
, M32RBF_SFMT_DIV
},
84 { M32R_INSN_JL
, M32RBF_INSN_JL
, M32RBF_SFMT_JL
},
85 { M32R_INSN_JMP
, M32RBF_INSN_JMP
, M32RBF_SFMT_JMP
},
86 { M32R_INSN_LD
, M32RBF_INSN_LD
, M32RBF_SFMT_LD
},
87 { M32R_INSN_LD_D
, M32RBF_INSN_LD_D
, M32RBF_SFMT_LD_D
},
88 { M32R_INSN_LDB
, M32RBF_INSN_LDB
, M32RBF_SFMT_LDB
},
89 { M32R_INSN_LDB_D
, M32RBF_INSN_LDB_D
, M32RBF_SFMT_LDB_D
},
90 { M32R_INSN_LDH
, M32RBF_INSN_LDH
, M32RBF_SFMT_LDH
},
91 { M32R_INSN_LDH_D
, M32RBF_INSN_LDH_D
, M32RBF_SFMT_LDH_D
},
92 { M32R_INSN_LDUB
, M32RBF_INSN_LDUB
, M32RBF_SFMT_LDB
},
93 { M32R_INSN_LDUB_D
, M32RBF_INSN_LDUB_D
, M32RBF_SFMT_LDB_D
},
94 { M32R_INSN_LDUH
, M32RBF_INSN_LDUH
, M32RBF_SFMT_LDH
},
95 { M32R_INSN_LDUH_D
, M32RBF_INSN_LDUH_D
, M32RBF_SFMT_LDH_D
},
96 { M32R_INSN_LD_PLUS
, M32RBF_INSN_LD_PLUS
, M32RBF_SFMT_LD_PLUS
},
97 { M32R_INSN_LD24
, M32RBF_INSN_LD24
, M32RBF_SFMT_LD24
},
98 { M32R_INSN_LDI8
, M32RBF_INSN_LDI8
, M32RBF_SFMT_LDI8
},
99 { M32R_INSN_LDI16
, M32RBF_INSN_LDI16
, M32RBF_SFMT_LDI16
},
100 { M32R_INSN_LOCK
, M32RBF_INSN_LOCK
, M32RBF_SFMT_LOCK
},
101 { M32R_INSN_MACHI
, M32RBF_INSN_MACHI
, M32RBF_SFMT_MACHI
},
102 { M32R_INSN_MACLO
, M32RBF_INSN_MACLO
, M32RBF_SFMT_MACHI
},
103 { M32R_INSN_MACWHI
, M32RBF_INSN_MACWHI
, M32RBF_SFMT_MACHI
},
104 { M32R_INSN_MACWLO
, M32RBF_INSN_MACWLO
, M32RBF_SFMT_MACHI
},
105 { M32R_INSN_MUL
, M32RBF_INSN_MUL
, M32RBF_SFMT_ADD
},
106 { M32R_INSN_MULHI
, M32RBF_INSN_MULHI
, M32RBF_SFMT_MULHI
},
107 { M32R_INSN_MULLO
, M32RBF_INSN_MULLO
, M32RBF_SFMT_MULHI
},
108 { M32R_INSN_MULWHI
, M32RBF_INSN_MULWHI
, M32RBF_SFMT_MULHI
},
109 { M32R_INSN_MULWLO
, M32RBF_INSN_MULWLO
, M32RBF_SFMT_MULHI
},
110 { M32R_INSN_MV
, M32RBF_INSN_MV
, M32RBF_SFMT_MV
},
111 { M32R_INSN_MVFACHI
, M32RBF_INSN_MVFACHI
, M32RBF_SFMT_MVFACHI
},
112 { M32R_INSN_MVFACLO
, M32RBF_INSN_MVFACLO
, M32RBF_SFMT_MVFACHI
},
113 { M32R_INSN_MVFACMI
, M32RBF_INSN_MVFACMI
, M32RBF_SFMT_MVFACHI
},
114 { M32R_INSN_MVFC
, M32RBF_INSN_MVFC
, M32RBF_SFMT_MVFC
},
115 { M32R_INSN_MVTACHI
, M32RBF_INSN_MVTACHI
, M32RBF_SFMT_MVTACHI
},
116 { M32R_INSN_MVTACLO
, M32RBF_INSN_MVTACLO
, M32RBF_SFMT_MVTACHI
},
117 { M32R_INSN_MVTC
, M32RBF_INSN_MVTC
, M32RBF_SFMT_MVTC
},
118 { M32R_INSN_NEG
, M32RBF_INSN_NEG
, M32RBF_SFMT_MV
},
119 { M32R_INSN_NOP
, M32RBF_INSN_NOP
, M32RBF_SFMT_NOP
},
120 { M32R_INSN_NOT
, M32RBF_INSN_NOT
, M32RBF_SFMT_MV
},
121 { M32R_INSN_RAC
, M32RBF_INSN_RAC
, M32RBF_SFMT_RAC
},
122 { M32R_INSN_RACH
, M32RBF_INSN_RACH
, M32RBF_SFMT_RAC
},
123 { M32R_INSN_RTE
, M32RBF_INSN_RTE
, M32RBF_SFMT_RTE
},
124 { M32R_INSN_SETH
, M32RBF_INSN_SETH
, M32RBF_SFMT_SETH
},
125 { M32R_INSN_SLL
, M32RBF_INSN_SLL
, M32RBF_SFMT_ADD
},
126 { M32R_INSN_SLL3
, M32RBF_INSN_SLL3
, M32RBF_SFMT_SLL3
},
127 { M32R_INSN_SLLI
, M32RBF_INSN_SLLI
, M32RBF_SFMT_SLLI
},
128 { M32R_INSN_SRA
, M32RBF_INSN_SRA
, M32RBF_SFMT_ADD
},
129 { M32R_INSN_SRA3
, M32RBF_INSN_SRA3
, M32RBF_SFMT_SLL3
},
130 { M32R_INSN_SRAI
, M32RBF_INSN_SRAI
, M32RBF_SFMT_SLLI
},
131 { M32R_INSN_SRL
, M32RBF_INSN_SRL
, M32RBF_SFMT_ADD
},
132 { M32R_INSN_SRL3
, M32RBF_INSN_SRL3
, M32RBF_SFMT_SLL3
},
133 { M32R_INSN_SRLI
, M32RBF_INSN_SRLI
, M32RBF_SFMT_SLLI
},
134 { M32R_INSN_ST
, M32RBF_INSN_ST
, M32RBF_SFMT_ST
},
135 { M32R_INSN_ST_D
, M32RBF_INSN_ST_D
, M32RBF_SFMT_ST_D
},
136 { M32R_INSN_STB
, M32RBF_INSN_STB
, M32RBF_SFMT_STB
},
137 { M32R_INSN_STB_D
, M32RBF_INSN_STB_D
, M32RBF_SFMT_STB_D
},
138 { M32R_INSN_STH
, M32RBF_INSN_STH
, M32RBF_SFMT_STH
},
139 { M32R_INSN_STH_D
, M32RBF_INSN_STH_D
, M32RBF_SFMT_STH_D
},
140 { M32R_INSN_ST_PLUS
, M32RBF_INSN_ST_PLUS
, M32RBF_SFMT_ST_PLUS
},
141 { M32R_INSN_ST_MINUS
, M32RBF_INSN_ST_MINUS
, M32RBF_SFMT_ST_PLUS
},
142 { M32R_INSN_SUB
, M32RBF_INSN_SUB
, M32RBF_SFMT_ADD
},
143 { M32R_INSN_SUBV
, M32RBF_INSN_SUBV
, M32RBF_SFMT_ADDV
},
144 { M32R_INSN_SUBX
, M32RBF_INSN_SUBX
, M32RBF_SFMT_ADDX
},
145 { M32R_INSN_TRAP
, M32RBF_INSN_TRAP
, M32RBF_SFMT_TRAP
},
146 { M32R_INSN_UNLOCK
, M32RBF_INSN_UNLOCK
, M32RBF_SFMT_UNLOCK
},
147 { M32R_INSN_CLRPSW
, M32RBF_INSN_CLRPSW
, M32RBF_SFMT_CLRPSW
},
148 { M32R_INSN_SETPSW
, M32RBF_INSN_SETPSW
, M32RBF_SFMT_SETPSW
},
149 { M32R_INSN_BSET
, M32RBF_INSN_BSET
, M32RBF_SFMT_BSET
},
150 { M32R_INSN_BCLR
, M32RBF_INSN_BCLR
, M32RBF_SFMT_BSET
},
151 { M32R_INSN_BTST
, M32RBF_INSN_BTST
, M32RBF_SFMT_BTST
},
154 static const struct insn_sem m32rbf_insn_sem_invalid
=
156 VIRTUAL_INSN_X_INVALID
, M32RBF_INSN_X_INVALID
, M32RBF_SFMT_EMPTY
159 /* Initialize an IDESC from the compile-time computable parts. */
162 init_idesc (SIM_CPU
*cpu
, IDESC
*id
, const struct insn_sem
*t
)
164 const CGEN_INSN
*insn_table
= CGEN_CPU_INSN_TABLE (CPU_CPU_DESC (cpu
))->init_entries
;
168 if ((int) t
->type
<= 0)
169 id
->idata
= & cgen_virtual_insn_table
[- (int) t
->type
];
171 id
->idata
= & insn_table
[t
->type
];
172 id
->attrs
= CGEN_INSN_ATTRS (id
->idata
);
173 /* Oh my god, a magic number. */
174 id
->length
= CGEN_INSN_BITSIZE (id
->idata
) / 8;
176 #if WITH_PROFILE_MODEL_P
177 id
->timing
= & MODEL_TIMING (CPU_MODEL (cpu
)) [t
->index
];
179 SIM_DESC sd
= CPU_STATE (cpu
);
180 SIM_ASSERT (t
->index
== id
->timing
->num
);
184 /* Semantic pointers are initialized elsewhere. */
187 /* Initialize the instruction descriptor table. */
190 m32rbf_init_idesc_table (SIM_CPU
*cpu
)
193 const struct insn_sem
*t
,*tend
;
194 int tabsize
= M32RBF_INSN__MAX
;
195 IDESC
*table
= m32rbf_insn_data
;
197 memset (table
, 0, tabsize
* sizeof (IDESC
));
199 /* First set all entries to the `invalid insn'. */
200 t
= & m32rbf_insn_sem_invalid
;
201 for (id
= table
, tabend
= table
+ tabsize
; id
< tabend
; ++id
)
202 init_idesc (cpu
, id
, t
);
204 /* Now fill in the values for the chosen cpu. */
205 for (t
= m32rbf_insn_sem
, tend
= t
+ ARRAY_SIZE (m32rbf_insn_sem
);
208 init_idesc (cpu
, & table
[t
->index
], t
);
211 /* Link the IDESC table into the cpu. */
212 CPU_IDESC (cpu
) = table
;
215 /* Given an instruction, return a pointer to its IDESC entry. */
218 m32rbf_decode (SIM_CPU
*current_cpu
, IADDR pc
,
219 CGEN_INSN_WORD base_insn
, CGEN_INSN_WORD entire_insn
,
222 /* Result of decoder. */
223 M32RBF_INSN_TYPE itype
;
226 CGEN_INSN_WORD insn
= base_insn
;
229 unsigned int val
= (((insn
>> 8) & (15 << 4)) | ((insn
>> 4) & (15 << 0)));
232 case 0 : itype
= M32RBF_INSN_SUBV
; goto extract_sfmt_addv
;
233 case 1 : itype
= M32RBF_INSN_SUBX
; goto extract_sfmt_addx
;
234 case 2 : itype
= M32RBF_INSN_SUB
; goto extract_sfmt_add
;
235 case 3 : itype
= M32RBF_INSN_NEG
; goto extract_sfmt_mv
;
236 case 4 : itype
= M32RBF_INSN_CMP
; goto extract_sfmt_cmp
;
237 case 5 : itype
= M32RBF_INSN_CMPU
; goto extract_sfmt_cmp
;
238 case 8 : itype
= M32RBF_INSN_ADDV
; goto extract_sfmt_addv
;
239 case 9 : itype
= M32RBF_INSN_ADDX
; goto extract_sfmt_addx
;
240 case 10 : itype
= M32RBF_INSN_ADD
; goto extract_sfmt_add
;
241 case 11 : itype
= M32RBF_INSN_NOT
; goto extract_sfmt_mv
;
242 case 12 : itype
= M32RBF_INSN_AND
; goto extract_sfmt_add
;
243 case 13 : itype
= M32RBF_INSN_XOR
; goto extract_sfmt_add
;
244 case 14 : itype
= M32RBF_INSN_OR
; goto extract_sfmt_add
;
246 if ((entire_insn
& 0xf8f0) == 0xf0)
247 { itype
= M32RBF_INSN_BTST
; goto extract_sfmt_btst
; }
248 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
249 case 16 : itype
= M32RBF_INSN_SRL
; goto extract_sfmt_add
;
250 case 18 : itype
= M32RBF_INSN_SRA
; goto extract_sfmt_add
;
251 case 20 : itype
= M32RBF_INSN_SLL
; goto extract_sfmt_add
;
252 case 22 : itype
= M32RBF_INSN_MUL
; goto extract_sfmt_add
;
253 case 24 : itype
= M32RBF_INSN_MV
; goto extract_sfmt_mv
;
254 case 25 : itype
= M32RBF_INSN_MVFC
; goto extract_sfmt_mvfc
;
255 case 26 : itype
= M32RBF_INSN_MVTC
; goto extract_sfmt_mvtc
;
258 unsigned int val
= (((insn
>> 8) & (1 << 0)));
262 if ((entire_insn
& 0xfff0) == 0x1ec0)
263 { itype
= M32RBF_INSN_JL
; goto extract_sfmt_jl
; }
264 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
266 if ((entire_insn
& 0xfff0) == 0x1fc0)
267 { itype
= M32RBF_INSN_JMP
; goto extract_sfmt_jmp
; }
268 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
269 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
273 if ((entire_insn
& 0xffff) == 0x10d6)
274 { itype
= M32RBF_INSN_RTE
; goto extract_sfmt_rte
; }
275 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
277 if ((entire_insn
& 0xfff0) == 0x10f0)
278 { itype
= M32RBF_INSN_TRAP
; goto extract_sfmt_trap
; }
279 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
280 case 32 : itype
= M32RBF_INSN_STB
; goto extract_sfmt_stb
;
281 case 34 : itype
= M32RBF_INSN_STH
; goto extract_sfmt_sth
;
282 case 36 : itype
= M32RBF_INSN_ST
; goto extract_sfmt_st
;
283 case 37 : itype
= M32RBF_INSN_UNLOCK
; goto extract_sfmt_unlock
;
284 case 38 : itype
= M32RBF_INSN_ST_PLUS
; goto extract_sfmt_st_plus
;
285 case 39 : itype
= M32RBF_INSN_ST_MINUS
; goto extract_sfmt_st_plus
;
286 case 40 : itype
= M32RBF_INSN_LDB
; goto extract_sfmt_ldb
;
287 case 41 : itype
= M32RBF_INSN_LDUB
; goto extract_sfmt_ldb
;
288 case 42 : itype
= M32RBF_INSN_LDH
; goto extract_sfmt_ldh
;
289 case 43 : itype
= M32RBF_INSN_LDUH
; goto extract_sfmt_ldh
;
290 case 44 : itype
= M32RBF_INSN_LD
; goto extract_sfmt_ld
;
291 case 45 : itype
= M32RBF_INSN_LOCK
; goto extract_sfmt_lock
;
292 case 46 : itype
= M32RBF_INSN_LD_PLUS
; goto extract_sfmt_ld_plus
;
293 case 48 : itype
= M32RBF_INSN_MULHI
; goto extract_sfmt_mulhi
;
294 case 49 : itype
= M32RBF_INSN_MULLO
; goto extract_sfmt_mulhi
;
295 case 50 : itype
= M32RBF_INSN_MULWHI
; goto extract_sfmt_mulhi
;
296 case 51 : itype
= M32RBF_INSN_MULWLO
; goto extract_sfmt_mulhi
;
297 case 52 : itype
= M32RBF_INSN_MACHI
; goto extract_sfmt_machi
;
298 case 53 : itype
= M32RBF_INSN_MACLO
; goto extract_sfmt_machi
;
299 case 54 : itype
= M32RBF_INSN_MACWHI
; goto extract_sfmt_machi
;
300 case 55 : itype
= M32RBF_INSN_MACWLO
; goto extract_sfmt_machi
;
301 case 64 : /* fall through */
302 case 65 : /* fall through */
303 case 66 : /* fall through */
304 case 67 : /* fall through */
305 case 68 : /* fall through */
306 case 69 : /* fall through */
307 case 70 : /* fall through */
308 case 71 : /* fall through */
309 case 72 : /* fall through */
310 case 73 : /* fall through */
311 case 74 : /* fall through */
312 case 75 : /* fall through */
313 case 76 : /* fall through */
314 case 77 : /* fall through */
315 case 78 : /* fall through */
316 case 79 : itype
= M32RBF_INSN_ADDI
; goto extract_sfmt_addi
;
317 case 80 : /* fall through */
318 case 81 : itype
= M32RBF_INSN_SRLI
; goto extract_sfmt_slli
;
319 case 82 : /* fall through */
320 case 83 : itype
= M32RBF_INSN_SRAI
; goto extract_sfmt_slli
;
321 case 84 : /* fall through */
322 case 85 : itype
= M32RBF_INSN_SLLI
; goto extract_sfmt_slli
;
325 unsigned int val
= (((insn
>> 0) & (1 << 0)));
329 if ((entire_insn
& 0xf0ff) == 0x5070)
330 { itype
= M32RBF_INSN_MVTACHI
; goto extract_sfmt_mvtachi
; }
331 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
333 if ((entire_insn
& 0xf0ff) == 0x5071)
334 { itype
= M32RBF_INSN_MVTACLO
; goto extract_sfmt_mvtachi
; }
335 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
336 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
340 if ((entire_insn
& 0xffff) == 0x5080)
341 { itype
= M32RBF_INSN_RACH
; goto extract_sfmt_rac
; }
342 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
344 if ((entire_insn
& 0xffff) == 0x5090)
345 { itype
= M32RBF_INSN_RAC
; goto extract_sfmt_rac
; }
346 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
349 unsigned int val
= (((insn
>> 0) & (3 << 0)));
353 if ((entire_insn
& 0xf0ff) == 0x50f0)
354 { itype
= M32RBF_INSN_MVFACHI
; goto extract_sfmt_mvfachi
; }
355 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
357 if ((entire_insn
& 0xf0ff) == 0x50f1)
358 { itype
= M32RBF_INSN_MVFACLO
; goto extract_sfmt_mvfachi
; }
359 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
361 if ((entire_insn
& 0xf0ff) == 0x50f2)
362 { itype
= M32RBF_INSN_MVFACMI
; goto extract_sfmt_mvfachi
; }
363 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
364 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
367 case 96 : /* fall through */
368 case 97 : /* fall through */
369 case 98 : /* fall through */
370 case 99 : /* fall through */
371 case 100 : /* fall through */
372 case 101 : /* fall through */
373 case 102 : /* fall through */
374 case 103 : /* fall through */
375 case 104 : /* fall through */
376 case 105 : /* fall through */
377 case 106 : /* fall through */
378 case 107 : /* fall through */
379 case 108 : /* fall through */
380 case 109 : /* fall through */
381 case 110 : /* fall through */
382 case 111 : itype
= M32RBF_INSN_LDI8
; goto extract_sfmt_ldi8
;
385 unsigned int val
= (((insn
>> 8) & (15 << 0)));
389 if ((entire_insn
& 0xffff) == 0x7000)
390 { itype
= M32RBF_INSN_NOP
; goto extract_sfmt_nop
; }
391 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
392 case 1 : itype
= M32RBF_INSN_SETPSW
; goto extract_sfmt_setpsw
;
393 case 2 : itype
= M32RBF_INSN_CLRPSW
; goto extract_sfmt_clrpsw
;
394 case 12 : itype
= M32RBF_INSN_BC8
; goto extract_sfmt_bc8
;
395 case 13 : itype
= M32RBF_INSN_BNC8
; goto extract_sfmt_bc8
;
396 case 14 : itype
= M32RBF_INSN_BL8
; goto extract_sfmt_bl8
;
397 case 15 : itype
= M32RBF_INSN_BRA8
; goto extract_sfmt_bra8
;
398 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
401 case 113 : /* fall through */
402 case 114 : /* fall through */
403 case 115 : /* fall through */
404 case 116 : /* fall through */
405 case 117 : /* fall through */
406 case 118 : /* fall through */
407 case 119 : /* fall through */
408 case 120 : /* fall through */
409 case 121 : /* fall through */
410 case 122 : /* fall through */
411 case 123 : /* fall through */
412 case 124 : /* fall through */
413 case 125 : /* fall through */
414 case 126 : /* fall through */
417 unsigned int val
= (((insn
>> 8) & (15 << 0)));
420 case 1 : itype
= M32RBF_INSN_SETPSW
; goto extract_sfmt_setpsw
;
421 case 2 : itype
= M32RBF_INSN_CLRPSW
; goto extract_sfmt_clrpsw
;
422 case 12 : itype
= M32RBF_INSN_BC8
; goto extract_sfmt_bc8
;
423 case 13 : itype
= M32RBF_INSN_BNC8
; goto extract_sfmt_bc8
;
424 case 14 : itype
= M32RBF_INSN_BL8
; goto extract_sfmt_bl8
;
425 case 15 : itype
= M32RBF_INSN_BRA8
; goto extract_sfmt_bra8
;
426 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
430 if ((entire_insn
& 0xfff00000) == 0x80400000)
431 { itype
= M32RBF_INSN_CMPI
; goto extract_sfmt_cmpi
; }
432 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
434 if ((entire_insn
& 0xfff00000) == 0x80500000)
435 { itype
= M32RBF_INSN_CMPUI
; goto extract_sfmt_cmpi
; }
436 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
437 case 136 : itype
= M32RBF_INSN_ADDV3
; goto extract_sfmt_addv3
;
438 case 138 : itype
= M32RBF_INSN_ADD3
; goto extract_sfmt_add3
;
439 case 140 : itype
= M32RBF_INSN_AND3
; goto extract_sfmt_and3
;
440 case 141 : itype
= M32RBF_INSN_XOR3
; goto extract_sfmt_and3
;
441 case 142 : itype
= M32RBF_INSN_OR3
; goto extract_sfmt_or3
;
443 if ((entire_insn
& 0xf0f0ffff) == 0x90000000)
444 { itype
= M32RBF_INSN_DIV
; goto extract_sfmt_div
; }
445 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
447 if ((entire_insn
& 0xf0f0ffff) == 0x90100000)
448 { itype
= M32RBF_INSN_DIVU
; goto extract_sfmt_div
; }
449 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
451 if ((entire_insn
& 0xf0f0ffff) == 0x90200000)
452 { itype
= M32RBF_INSN_REM
; goto extract_sfmt_div
; }
453 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
455 if ((entire_insn
& 0xf0f0ffff) == 0x90300000)
456 { itype
= M32RBF_INSN_REMU
; goto extract_sfmt_div
; }
457 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
458 case 152 : itype
= M32RBF_INSN_SRL3
; goto extract_sfmt_sll3
;
459 case 154 : itype
= M32RBF_INSN_SRA3
; goto extract_sfmt_sll3
;
460 case 156 : itype
= M32RBF_INSN_SLL3
; goto extract_sfmt_sll3
;
462 if ((entire_insn
& 0xf0ff0000) == 0x90f00000)
463 { itype
= M32RBF_INSN_LDI16
; goto extract_sfmt_ldi16
; }
464 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
465 case 160 : itype
= M32RBF_INSN_STB_D
; goto extract_sfmt_stb_d
;
466 case 162 : itype
= M32RBF_INSN_STH_D
; goto extract_sfmt_sth_d
;
467 case 164 : itype
= M32RBF_INSN_ST_D
; goto extract_sfmt_st_d
;
469 if ((entire_insn
& 0xf8f00000) == 0xa0600000)
470 { itype
= M32RBF_INSN_BSET
; goto extract_sfmt_bset
; }
471 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
473 if ((entire_insn
& 0xf8f00000) == 0xa0700000)
474 { itype
= M32RBF_INSN_BCLR
; goto extract_sfmt_bset
; }
475 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
476 case 168 : itype
= M32RBF_INSN_LDB_D
; goto extract_sfmt_ldb_d
;
477 case 169 : itype
= M32RBF_INSN_LDUB_D
; goto extract_sfmt_ldb_d
;
478 case 170 : itype
= M32RBF_INSN_LDH_D
; goto extract_sfmt_ldh_d
;
479 case 171 : itype
= M32RBF_INSN_LDUH_D
; goto extract_sfmt_ldh_d
;
480 case 172 : itype
= M32RBF_INSN_LD_D
; goto extract_sfmt_ld_d
;
481 case 176 : itype
= M32RBF_INSN_BEQ
; goto extract_sfmt_beq
;
482 case 177 : itype
= M32RBF_INSN_BNE
; goto extract_sfmt_beq
;
484 if ((entire_insn
& 0xfff00000) == 0xb0800000)
485 { itype
= M32RBF_INSN_BEQZ
; goto extract_sfmt_beqz
; }
486 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
488 if ((entire_insn
& 0xfff00000) == 0xb0900000)
489 { itype
= M32RBF_INSN_BNEZ
; goto extract_sfmt_beqz
; }
490 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
492 if ((entire_insn
& 0xfff00000) == 0xb0a00000)
493 { itype
= M32RBF_INSN_BLTZ
; goto extract_sfmt_beqz
; }
494 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
496 if ((entire_insn
& 0xfff00000) == 0xb0b00000)
497 { itype
= M32RBF_INSN_BGEZ
; goto extract_sfmt_beqz
; }
498 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
500 if ((entire_insn
& 0xfff00000) == 0xb0c00000)
501 { itype
= M32RBF_INSN_BLEZ
; goto extract_sfmt_beqz
; }
502 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
504 if ((entire_insn
& 0xfff00000) == 0xb0d00000)
505 { itype
= M32RBF_INSN_BGTZ
; goto extract_sfmt_beqz
; }
506 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
508 if ((entire_insn
& 0xf0ff0000) == 0xd0c00000)
509 { itype
= M32RBF_INSN_SETH
; goto extract_sfmt_seth
; }
510 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
511 case 224 : /* fall through */
512 case 225 : /* fall through */
513 case 226 : /* fall through */
514 case 227 : /* fall through */
515 case 228 : /* fall through */
516 case 229 : /* fall through */
517 case 230 : /* fall through */
518 case 231 : /* fall through */
519 case 232 : /* fall through */
520 case 233 : /* fall through */
521 case 234 : /* fall through */
522 case 235 : /* fall through */
523 case 236 : /* fall through */
524 case 237 : /* fall through */
525 case 238 : /* fall through */
526 case 239 : itype
= M32RBF_INSN_LD24
; goto extract_sfmt_ld24
;
527 case 240 : /* fall through */
528 case 241 : /* fall through */
529 case 242 : /* fall through */
530 case 243 : /* fall through */
531 case 244 : /* fall through */
532 case 245 : /* fall through */
533 case 246 : /* fall through */
534 case 247 : /* fall through */
535 case 248 : /* fall through */
536 case 249 : /* fall through */
537 case 250 : /* fall through */
538 case 251 : /* fall through */
539 case 252 : /* fall through */
540 case 253 : /* fall through */
541 case 254 : /* fall through */
544 unsigned int val
= (((insn
>> 8) & (3 << 0)));
548 if ((entire_insn
& 0xff000000) == 0xfc000000)
549 { itype
= M32RBF_INSN_BC24
; goto extract_sfmt_bc24
; }
550 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
552 if ((entire_insn
& 0xff000000) == 0xfd000000)
553 { itype
= M32RBF_INSN_BNC24
; goto extract_sfmt_bc24
; }
554 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
556 if ((entire_insn
& 0xff000000) == 0xfe000000)
557 { itype
= M32RBF_INSN_BL24
; goto extract_sfmt_bl24
; }
558 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
560 if ((entire_insn
& 0xff000000) == 0xff000000)
561 { itype
= M32RBF_INSN_BRA24
; goto extract_sfmt_bra24
; }
562 itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
563 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
566 default : itype
= M32RBF_INSN_X_INVALID
; goto extract_sfmt_empty
;
571 /* The instruction has been decoded, now extract the fields. */
575 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
576 #define FLD(f) abuf->fields.sfmt_empty.f
579 /* Record the fields for the semantic handler. */
580 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_empty", (char *) 0));
588 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
589 CGEN_INSN_WORD insn
= entire_insn
;
590 #define FLD(f) abuf->fields.sfmt_add.f
594 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
595 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
597 /* Record the fields for the semantic handler. */
600 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
601 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
602 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_add", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, (char *) 0));
604 #if WITH_PROFILE_MODEL_P
605 /* Record the fields for profiling. */
606 if (PROFILE_MODEL_P (current_cpu
))
619 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
620 CGEN_INSN_WORD insn
= entire_insn
;
621 #define FLD(f) abuf->fields.sfmt_add3.f
626 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
627 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
628 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
630 /* Record the fields for the semantic handler. */
631 FLD (f_simm16
) = f_simm16
;
634 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
635 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
636 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_add3", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
638 #if WITH_PROFILE_MODEL_P
639 /* Record the fields for profiling. */
640 if (PROFILE_MODEL_P (current_cpu
))
652 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
653 CGEN_INSN_WORD insn
= entire_insn
;
654 #define FLD(f) abuf->fields.sfmt_and3.f
659 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
660 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
661 f_uimm16
= EXTRACT_MSB0_UINT (insn
, 32, 16, 16);
663 /* Record the fields for the semantic handler. */
665 FLD (f_uimm16
) = f_uimm16
;
667 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
668 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
669 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_and3", "f_r2 0x%x", 'x', f_r2
, "f_uimm16 0x%x", 'x', f_uimm16
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
671 #if WITH_PROFILE_MODEL_P
672 /* Record the fields for profiling. */
673 if (PROFILE_MODEL_P (current_cpu
))
685 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
686 CGEN_INSN_WORD insn
= entire_insn
;
687 #define FLD(f) abuf->fields.sfmt_and3.f
692 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
693 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
694 f_uimm16
= EXTRACT_MSB0_UINT (insn
, 32, 16, 16);
696 /* Record the fields for the semantic handler. */
698 FLD (f_uimm16
) = f_uimm16
;
700 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
701 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
702 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_or3", "f_r2 0x%x", 'x', f_r2
, "f_uimm16 0x%x", 'x', f_uimm16
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
704 #if WITH_PROFILE_MODEL_P
705 /* Record the fields for profiling. */
706 if (PROFILE_MODEL_P (current_cpu
))
718 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
719 CGEN_INSN_WORD insn
= entire_insn
;
720 #define FLD(f) abuf->fields.sfmt_addi.f
724 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
725 f_simm8
= EXTRACT_MSB0_SINT (insn
, 16, 8, 8);
727 /* Record the fields for the semantic handler. */
729 FLD (f_simm8
) = f_simm8
;
730 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
731 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_addi", "f_r1 0x%x", 'x', f_r1
, "f_simm8 0x%x", 'x', f_simm8
, "dr 0x%x", 'x', f_r1
, (char *) 0));
733 #if WITH_PROFILE_MODEL_P
734 /* Record the fields for profiling. */
735 if (PROFILE_MODEL_P (current_cpu
))
747 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
748 CGEN_INSN_WORD insn
= entire_insn
;
749 #define FLD(f) abuf->fields.sfmt_add.f
753 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
754 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
756 /* Record the fields for the semantic handler. */
759 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
760 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
761 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_addv", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, (char *) 0));
763 #if WITH_PROFILE_MODEL_P
764 /* Record the fields for profiling. */
765 if (PROFILE_MODEL_P (current_cpu
))
778 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
779 CGEN_INSN_WORD insn
= entire_insn
;
780 #define FLD(f) abuf->fields.sfmt_add3.f
785 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
786 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
787 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
789 /* Record the fields for the semantic handler. */
790 FLD (f_simm16
) = f_simm16
;
793 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
794 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
795 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_addv3", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
797 #if WITH_PROFILE_MODEL_P
798 /* Record the fields for profiling. */
799 if (PROFILE_MODEL_P (current_cpu
))
811 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
812 CGEN_INSN_WORD insn
= entire_insn
;
813 #define FLD(f) abuf->fields.sfmt_add.f
817 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
818 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
820 /* Record the fields for the semantic handler. */
823 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
824 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
825 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_addx", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, (char *) 0));
827 #if WITH_PROFILE_MODEL_P
828 /* Record the fields for profiling. */
829 if (PROFILE_MODEL_P (current_cpu
))
842 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
843 CGEN_INSN_WORD insn
= entire_insn
;
844 #define FLD(f) abuf->fields.sfmt_bl8.f
847 f_disp8
= ((((EXTRACT_MSB0_SINT (insn
, 16, 8, 8)) << (2))) + (((pc
) & (-4))));
849 /* Record the fields for the semantic handler. */
850 FLD (i_disp8
) = f_disp8
;
851 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bc8", "disp8 0x%x", 'x', f_disp8
, (char *) 0));
853 #if WITH_PROFILE_MODEL_P
854 /* Record the fields for profiling. */
855 if (PROFILE_MODEL_P (current_cpu
))
865 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
866 CGEN_INSN_WORD insn
= entire_insn
;
867 #define FLD(f) abuf->fields.sfmt_bl24.f
870 f_disp24
= ((((EXTRACT_MSB0_SINT (insn
, 32, 8, 24)) << (2))) + (pc
));
872 /* Record the fields for the semantic handler. */
873 FLD (i_disp24
) = f_disp24
;
874 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bc24", "disp24 0x%x", 'x', f_disp24
, (char *) 0));
876 #if WITH_PROFILE_MODEL_P
877 /* Record the fields for profiling. */
878 if (PROFILE_MODEL_P (current_cpu
))
888 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
889 CGEN_INSN_WORD insn
= entire_insn
;
890 #define FLD(f) abuf->fields.sfmt_beq.f
895 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
896 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
897 f_disp16
= ((((EXTRACT_MSB0_SINT (insn
, 32, 16, 16)) << (2))) + (pc
));
899 /* Record the fields for the semantic handler. */
902 FLD (i_disp16
) = f_disp16
;
903 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
904 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
905 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_beq", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "disp16 0x%x", 'x', f_disp16
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
907 #if WITH_PROFILE_MODEL_P
908 /* Record the fields for profiling. */
909 if (PROFILE_MODEL_P (current_cpu
))
911 FLD (in_src1
) = f_r1
;
912 FLD (in_src2
) = f_r2
;
921 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
922 CGEN_INSN_WORD insn
= entire_insn
;
923 #define FLD(f) abuf->fields.sfmt_beq.f
927 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
928 f_disp16
= ((((EXTRACT_MSB0_SINT (insn
, 32, 16, 16)) << (2))) + (pc
));
930 /* Record the fields for the semantic handler. */
932 FLD (i_disp16
) = f_disp16
;
933 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
934 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_beqz", "f_r2 0x%x", 'x', f_r2
, "disp16 0x%x", 'x', f_disp16
, "src2 0x%x", 'x', f_r2
, (char *) 0));
936 #if WITH_PROFILE_MODEL_P
937 /* Record the fields for profiling. */
938 if (PROFILE_MODEL_P (current_cpu
))
940 FLD (in_src2
) = f_r2
;
949 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
950 CGEN_INSN_WORD insn
= entire_insn
;
951 #define FLD(f) abuf->fields.sfmt_bl8.f
954 f_disp8
= ((((EXTRACT_MSB0_SINT (insn
, 16, 8, 8)) << (2))) + (((pc
) & (-4))));
956 /* Record the fields for the semantic handler. */
957 FLD (i_disp8
) = f_disp8
;
958 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bl8", "disp8 0x%x", 'x', f_disp8
, (char *) 0));
960 #if WITH_PROFILE_MODEL_P
961 /* Record the fields for profiling. */
962 if (PROFILE_MODEL_P (current_cpu
))
964 FLD (out_h_gr_SI_14
) = 14;
973 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
974 CGEN_INSN_WORD insn
= entire_insn
;
975 #define FLD(f) abuf->fields.sfmt_bl24.f
978 f_disp24
= ((((EXTRACT_MSB0_SINT (insn
, 32, 8, 24)) << (2))) + (pc
));
980 /* Record the fields for the semantic handler. */
981 FLD (i_disp24
) = f_disp24
;
982 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bl24", "disp24 0x%x", 'x', f_disp24
, (char *) 0));
984 #if WITH_PROFILE_MODEL_P
985 /* Record the fields for profiling. */
986 if (PROFILE_MODEL_P (current_cpu
))
988 FLD (out_h_gr_SI_14
) = 14;
997 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
998 CGEN_INSN_WORD insn
= entire_insn
;
999 #define FLD(f) abuf->fields.sfmt_bl8.f
1002 f_disp8
= ((((EXTRACT_MSB0_SINT (insn
, 16, 8, 8)) << (2))) + (((pc
) & (-4))));
1004 /* Record the fields for the semantic handler. */
1005 FLD (i_disp8
) = f_disp8
;
1006 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bra8", "disp8 0x%x", 'x', f_disp8
, (char *) 0));
1008 #if WITH_PROFILE_MODEL_P
1009 /* Record the fields for profiling. */
1010 if (PROFILE_MODEL_P (current_cpu
))
1020 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1021 CGEN_INSN_WORD insn
= entire_insn
;
1022 #define FLD(f) abuf->fields.sfmt_bl24.f
1025 f_disp24
= ((((EXTRACT_MSB0_SINT (insn
, 32, 8, 24)) << (2))) + (pc
));
1027 /* Record the fields for the semantic handler. */
1028 FLD (i_disp24
) = f_disp24
;
1029 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bra24", "disp24 0x%x", 'x', f_disp24
, (char *) 0));
1031 #if WITH_PROFILE_MODEL_P
1032 /* Record the fields for profiling. */
1033 if (PROFILE_MODEL_P (current_cpu
))
1043 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1044 CGEN_INSN_WORD insn
= entire_insn
;
1045 #define FLD(f) abuf->fields.sfmt_st_plus.f
1049 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1050 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1052 /* Record the fields for the semantic handler. */
1055 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1056 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1057 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_cmp", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1059 #if WITH_PROFILE_MODEL_P
1060 /* Record the fields for profiling. */
1061 if (PROFILE_MODEL_P (current_cpu
))
1063 FLD (in_src1
) = f_r1
;
1064 FLD (in_src2
) = f_r2
;
1073 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1074 CGEN_INSN_WORD insn
= entire_insn
;
1075 #define FLD(f) abuf->fields.sfmt_st_d.f
1079 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1080 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1082 /* Record the fields for the semantic handler. */
1083 FLD (f_simm16
) = f_simm16
;
1085 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1086 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_cmpi", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1088 #if WITH_PROFILE_MODEL_P
1089 /* Record the fields for profiling. */
1090 if (PROFILE_MODEL_P (current_cpu
))
1092 FLD (in_src2
) = f_r2
;
1101 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1102 CGEN_INSN_WORD insn
= entire_insn
;
1103 #define FLD(f) abuf->fields.sfmt_add.f
1107 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1108 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1110 /* Record the fields for the semantic handler. */
1113 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1114 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1115 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_div", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, (char *) 0));
1117 #if WITH_PROFILE_MODEL_P
1118 /* Record the fields for profiling. */
1119 if (PROFILE_MODEL_P (current_cpu
))
1123 FLD (out_dr
) = f_r1
;
1132 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1133 CGEN_INSN_WORD insn
= entire_insn
;
1134 #define FLD(f) abuf->fields.sfmt_jl.f
1137 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1139 /* Record the fields for the semantic handler. */
1141 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1142 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_jl", "f_r2 0x%x", 'x', f_r2
, "sr 0x%x", 'x', f_r2
, (char *) 0));
1144 #if WITH_PROFILE_MODEL_P
1145 /* Record the fields for profiling. */
1146 if (PROFILE_MODEL_P (current_cpu
))
1149 FLD (out_h_gr_SI_14
) = 14;
1158 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1159 CGEN_INSN_WORD insn
= entire_insn
;
1160 #define FLD(f) abuf->fields.sfmt_jl.f
1163 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1165 /* Record the fields for the semantic handler. */
1167 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1168 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_jmp", "f_r2 0x%x", 'x', f_r2
, "sr 0x%x", 'x', f_r2
, (char *) 0));
1170 #if WITH_PROFILE_MODEL_P
1171 /* Record the fields for profiling. */
1172 if (PROFILE_MODEL_P (current_cpu
))
1183 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1184 CGEN_INSN_WORD insn
= entire_insn
;
1185 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1189 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1190 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1192 /* Record the fields for the semantic handler. */
1195 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1196 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1197 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ld", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1199 #if WITH_PROFILE_MODEL_P
1200 /* Record the fields for profiling. */
1201 if (PROFILE_MODEL_P (current_cpu
))
1204 FLD (out_dr
) = f_r1
;
1213 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1214 CGEN_INSN_WORD insn
= entire_insn
;
1215 #define FLD(f) abuf->fields.sfmt_add3.f
1220 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1221 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1222 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1224 /* Record the fields for the semantic handler. */
1225 FLD (f_simm16
) = f_simm16
;
1228 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1229 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1230 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ld_d", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1232 #if WITH_PROFILE_MODEL_P
1233 /* Record the fields for profiling. */
1234 if (PROFILE_MODEL_P (current_cpu
))
1237 FLD (out_dr
) = f_r1
;
1246 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1247 CGEN_INSN_WORD insn
= entire_insn
;
1248 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1252 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1253 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1255 /* Record the fields for the semantic handler. */
1258 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1259 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1260 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ldb", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1262 #if WITH_PROFILE_MODEL_P
1263 /* Record the fields for profiling. */
1264 if (PROFILE_MODEL_P (current_cpu
))
1267 FLD (out_dr
) = f_r1
;
1276 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1277 CGEN_INSN_WORD insn
= entire_insn
;
1278 #define FLD(f) abuf->fields.sfmt_add3.f
1283 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1284 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1285 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1287 /* Record the fields for the semantic handler. */
1288 FLD (f_simm16
) = f_simm16
;
1291 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1292 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1293 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ldb_d", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1295 #if WITH_PROFILE_MODEL_P
1296 /* Record the fields for profiling. */
1297 if (PROFILE_MODEL_P (current_cpu
))
1300 FLD (out_dr
) = f_r1
;
1309 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1310 CGEN_INSN_WORD insn
= entire_insn
;
1311 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1315 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1316 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1318 /* Record the fields for the semantic handler. */
1321 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1322 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1323 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ldh", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1325 #if WITH_PROFILE_MODEL_P
1326 /* Record the fields for profiling. */
1327 if (PROFILE_MODEL_P (current_cpu
))
1330 FLD (out_dr
) = f_r1
;
1339 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1340 CGEN_INSN_WORD insn
= entire_insn
;
1341 #define FLD(f) abuf->fields.sfmt_add3.f
1346 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1347 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1348 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1350 /* Record the fields for the semantic handler. */
1351 FLD (f_simm16
) = f_simm16
;
1354 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1355 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1356 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ldh_d", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1358 #if WITH_PROFILE_MODEL_P
1359 /* Record the fields for profiling. */
1360 if (PROFILE_MODEL_P (current_cpu
))
1363 FLD (out_dr
) = f_r1
;
1370 extract_sfmt_ld_plus
:
1372 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1373 CGEN_INSN_WORD insn
= entire_insn
;
1374 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1378 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1379 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1381 /* Record the fields for the semantic handler. */
1384 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1385 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1386 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ld_plus", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1388 #if WITH_PROFILE_MODEL_P
1389 /* Record the fields for profiling. */
1390 if (PROFILE_MODEL_P (current_cpu
))
1393 FLD (out_dr
) = f_r1
;
1394 FLD (out_sr
) = f_r2
;
1403 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1404 CGEN_INSN_WORD insn
= entire_insn
;
1405 #define FLD(f) abuf->fields.sfmt_ld24.f
1409 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1410 f_uimm24
= EXTRACT_MSB0_UINT (insn
, 32, 8, 24);
1412 /* Record the fields for the semantic handler. */
1414 FLD (i_uimm24
) = f_uimm24
;
1415 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1416 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ld24", "f_r1 0x%x", 'x', f_r1
, "uimm24 0x%x", 'x', f_uimm24
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1418 #if WITH_PROFILE_MODEL_P
1419 /* Record the fields for profiling. */
1420 if (PROFILE_MODEL_P (current_cpu
))
1422 FLD (out_dr
) = f_r1
;
1431 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1432 CGEN_INSN_WORD insn
= entire_insn
;
1433 #define FLD(f) abuf->fields.sfmt_addi.f
1437 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1438 f_simm8
= EXTRACT_MSB0_SINT (insn
, 16, 8, 8);
1440 /* Record the fields for the semantic handler. */
1441 FLD (f_simm8
) = f_simm8
;
1443 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1444 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ldi8", "f_simm8 0x%x", 'x', f_simm8
, "f_r1 0x%x", 'x', f_r1
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1446 #if WITH_PROFILE_MODEL_P
1447 /* Record the fields for profiling. */
1448 if (PROFILE_MODEL_P (current_cpu
))
1450 FLD (out_dr
) = f_r1
;
1459 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1460 CGEN_INSN_WORD insn
= entire_insn
;
1461 #define FLD(f) abuf->fields.sfmt_add3.f
1465 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1466 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1468 /* Record the fields for the semantic handler. */
1469 FLD (f_simm16
) = f_simm16
;
1471 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1472 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_ldi16", "f_simm16 0x%x", 'x', f_simm16
, "f_r1 0x%x", 'x', f_r1
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1474 #if WITH_PROFILE_MODEL_P
1475 /* Record the fields for profiling. */
1476 if (PROFILE_MODEL_P (current_cpu
))
1478 FLD (out_dr
) = f_r1
;
1487 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1488 CGEN_INSN_WORD insn
= entire_insn
;
1489 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1493 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1494 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1496 /* Record the fields for the semantic handler. */
1499 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1500 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1501 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_lock", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1503 #if WITH_PROFILE_MODEL_P
1504 /* Record the fields for profiling. */
1505 if (PROFILE_MODEL_P (current_cpu
))
1508 FLD (out_dr
) = f_r1
;
1517 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1518 CGEN_INSN_WORD insn
= entire_insn
;
1519 #define FLD(f) abuf->fields.sfmt_st_plus.f
1523 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1524 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1526 /* Record the fields for the semantic handler. */
1529 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1530 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1531 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_machi", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1533 #if WITH_PROFILE_MODEL_P
1534 /* Record the fields for profiling. */
1535 if (PROFILE_MODEL_P (current_cpu
))
1537 FLD (in_src1
) = f_r1
;
1538 FLD (in_src2
) = f_r2
;
1547 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1548 CGEN_INSN_WORD insn
= entire_insn
;
1549 #define FLD(f) abuf->fields.sfmt_st_plus.f
1553 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1554 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1556 /* Record the fields for the semantic handler. */
1559 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1560 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1561 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_mulhi", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1563 #if WITH_PROFILE_MODEL_P
1564 /* Record the fields for profiling. */
1565 if (PROFILE_MODEL_P (current_cpu
))
1567 FLD (in_src1
) = f_r1
;
1568 FLD (in_src2
) = f_r2
;
1577 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1578 CGEN_INSN_WORD insn
= entire_insn
;
1579 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1583 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1584 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1586 /* Record the fields for the semantic handler. */
1589 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1590 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1591 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_mv", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1593 #if WITH_PROFILE_MODEL_P
1594 /* Record the fields for profiling. */
1595 if (PROFILE_MODEL_P (current_cpu
))
1598 FLD (out_dr
) = f_r1
;
1605 extract_sfmt_mvfachi
:
1607 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1608 CGEN_INSN_WORD insn
= entire_insn
;
1609 #define FLD(f) abuf->fields.sfmt_seth.f
1612 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1614 /* Record the fields for the semantic handler. */
1616 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1617 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_mvfachi", "f_r1 0x%x", 'x', f_r1
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1619 #if WITH_PROFILE_MODEL_P
1620 /* Record the fields for profiling. */
1621 if (PROFILE_MODEL_P (current_cpu
))
1623 FLD (out_dr
) = f_r1
;
1632 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1633 CGEN_INSN_WORD insn
= entire_insn
;
1634 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1638 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1639 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1641 /* Record the fields for the semantic handler. */
1644 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1645 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_mvfc", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1647 #if WITH_PROFILE_MODEL_P
1648 /* Record the fields for profiling. */
1649 if (PROFILE_MODEL_P (current_cpu
))
1651 FLD (out_dr
) = f_r1
;
1658 extract_sfmt_mvtachi
:
1660 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1661 CGEN_INSN_WORD insn
= entire_insn
;
1662 #define FLD(f) abuf->fields.sfmt_st_plus.f
1665 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1667 /* Record the fields for the semantic handler. */
1669 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1670 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_mvtachi", "f_r1 0x%x", 'x', f_r1
, "src1 0x%x", 'x', f_r1
, (char *) 0));
1672 #if WITH_PROFILE_MODEL_P
1673 /* Record the fields for profiling. */
1674 if (PROFILE_MODEL_P (current_cpu
))
1676 FLD (in_src1
) = f_r1
;
1685 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1686 CGEN_INSN_WORD insn
= entire_insn
;
1687 #define FLD(f) abuf->fields.sfmt_ld_plus.f
1691 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1692 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1694 /* Record the fields for the semantic handler. */
1697 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1698 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_mvtc", "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, (char *) 0));
1700 #if WITH_PROFILE_MODEL_P
1701 /* Record the fields for profiling. */
1702 if (PROFILE_MODEL_P (current_cpu
))
1713 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1714 #define FLD(f) abuf->fields.sfmt_empty.f
1717 /* Record the fields for the semantic handler. */
1718 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_nop", (char *) 0));
1726 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1727 #define FLD(f) abuf->fields.sfmt_empty.f
1730 /* Record the fields for the semantic handler. */
1731 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_rac", (char *) 0));
1739 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1740 #define FLD(f) abuf->fields.sfmt_empty.f
1743 /* Record the fields for the semantic handler. */
1744 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_rte", (char *) 0));
1746 #if WITH_PROFILE_MODEL_P
1747 /* Record the fields for profiling. */
1748 if (PROFILE_MODEL_P (current_cpu
))
1758 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1759 CGEN_INSN_WORD insn
= entire_insn
;
1760 #define FLD(f) abuf->fields.sfmt_seth.f
1764 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1765 f_hi16
= EXTRACT_MSB0_UINT (insn
, 32, 16, 16);
1767 /* Record the fields for the semantic handler. */
1768 FLD (f_hi16
) = f_hi16
;
1770 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1771 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_seth", "f_hi16 0x%x", 'x', f_hi16
, "f_r1 0x%x", 'x', f_r1
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1773 #if WITH_PROFILE_MODEL_P
1774 /* Record the fields for profiling. */
1775 if (PROFILE_MODEL_P (current_cpu
))
1777 FLD (out_dr
) = f_r1
;
1786 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1787 CGEN_INSN_WORD insn
= entire_insn
;
1788 #define FLD(f) abuf->fields.sfmt_add3.f
1793 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1794 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1795 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1797 /* Record the fields for the semantic handler. */
1798 FLD (f_simm16
) = f_simm16
;
1801 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
1802 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1803 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_sll3", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_r1 0x%x", 'x', f_r1
, "sr 0x%x", 'x', f_r2
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1805 #if WITH_PROFILE_MODEL_P
1806 /* Record the fields for profiling. */
1807 if (PROFILE_MODEL_P (current_cpu
))
1810 FLD (out_dr
) = f_r1
;
1819 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1820 CGEN_INSN_WORD insn
= entire_insn
;
1821 #define FLD(f) abuf->fields.sfmt_slli.f
1825 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1826 f_uimm5
= EXTRACT_MSB0_UINT (insn
, 16, 11, 5);
1828 /* Record the fields for the semantic handler. */
1830 FLD (f_uimm5
) = f_uimm5
;
1831 FLD (i_dr
) = & CPU (h_gr
)[f_r1
];
1832 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_slli", "f_r1 0x%x", 'x', f_r1
, "f_uimm5 0x%x", 'x', f_uimm5
, "dr 0x%x", 'x', f_r1
, (char *) 0));
1834 #if WITH_PROFILE_MODEL_P
1835 /* Record the fields for profiling. */
1836 if (PROFILE_MODEL_P (current_cpu
))
1839 FLD (out_dr
) = f_r1
;
1848 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1849 CGEN_INSN_WORD insn
= entire_insn
;
1850 #define FLD(f) abuf->fields.sfmt_st_plus.f
1854 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1855 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1857 /* Record the fields for the semantic handler. */
1860 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1861 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1862 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_st", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1864 #if WITH_PROFILE_MODEL_P
1865 /* Record the fields for profiling. */
1866 if (PROFILE_MODEL_P (current_cpu
))
1868 FLD (in_src1
) = f_r1
;
1869 FLD (in_src2
) = f_r2
;
1878 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1879 CGEN_INSN_WORD insn
= entire_insn
;
1880 #define FLD(f) abuf->fields.sfmt_st_d.f
1885 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1886 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1887 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1889 /* Record the fields for the semantic handler. */
1890 FLD (f_simm16
) = f_simm16
;
1893 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1894 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1895 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_st_d", "f_simm16 0x%x", 'x', f_simm16
, "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1897 #if WITH_PROFILE_MODEL_P
1898 /* Record the fields for profiling. */
1899 if (PROFILE_MODEL_P (current_cpu
))
1901 FLD (in_src1
) = f_r1
;
1902 FLD (in_src2
) = f_r2
;
1911 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1912 CGEN_INSN_WORD insn
= entire_insn
;
1913 #define FLD(f) abuf->fields.sfmt_st_plus.f
1917 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1918 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1920 /* Record the fields for the semantic handler. */
1923 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1924 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1925 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_stb", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1927 #if WITH_PROFILE_MODEL_P
1928 /* Record the fields for profiling. */
1929 if (PROFILE_MODEL_P (current_cpu
))
1931 FLD (in_src1
) = f_r1
;
1932 FLD (in_src2
) = f_r2
;
1941 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1942 CGEN_INSN_WORD insn
= entire_insn
;
1943 #define FLD(f) abuf->fields.sfmt_st_d.f
1948 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
1949 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
1950 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
1952 /* Record the fields for the semantic handler. */
1953 FLD (f_simm16
) = f_simm16
;
1956 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1957 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1958 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_stb_d", "f_simm16 0x%x", 'x', f_simm16
, "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1960 #if WITH_PROFILE_MODEL_P
1961 /* Record the fields for profiling. */
1962 if (PROFILE_MODEL_P (current_cpu
))
1964 FLD (in_src1
) = f_r1
;
1965 FLD (in_src2
) = f_r2
;
1974 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
1975 CGEN_INSN_WORD insn
= entire_insn
;
1976 #define FLD(f) abuf->fields.sfmt_st_plus.f
1980 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
1981 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
1983 /* Record the fields for the semantic handler. */
1986 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
1987 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
1988 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_sth", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
1990 #if WITH_PROFILE_MODEL_P
1991 /* Record the fields for profiling. */
1992 if (PROFILE_MODEL_P (current_cpu
))
1994 FLD (in_src1
) = f_r1
;
1995 FLD (in_src2
) = f_r2
;
2004 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2005 CGEN_INSN_WORD insn
= entire_insn
;
2006 #define FLD(f) abuf->fields.sfmt_st_d.f
2011 f_r1
= EXTRACT_MSB0_UINT (insn
, 32, 4, 4);
2012 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
2013 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
2015 /* Record the fields for the semantic handler. */
2016 FLD (f_simm16
) = f_simm16
;
2019 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
2020 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
2021 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_sth_d", "f_simm16 0x%x", 'x', f_simm16
, "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
2023 #if WITH_PROFILE_MODEL_P
2024 /* Record the fields for profiling. */
2025 if (PROFILE_MODEL_P (current_cpu
))
2027 FLD (in_src1
) = f_r1
;
2028 FLD (in_src2
) = f_r2
;
2035 extract_sfmt_st_plus
:
2037 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2038 CGEN_INSN_WORD insn
= entire_insn
;
2039 #define FLD(f) abuf->fields.sfmt_st_plus.f
2043 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
2044 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
2046 /* Record the fields for the semantic handler. */
2049 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
2050 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
2051 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_st_plus", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
2053 #if WITH_PROFILE_MODEL_P
2054 /* Record the fields for profiling. */
2055 if (PROFILE_MODEL_P (current_cpu
))
2057 FLD (in_src1
) = f_r1
;
2058 FLD (in_src2
) = f_r2
;
2059 FLD (out_src2
) = f_r2
;
2068 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2069 CGEN_INSN_WORD insn
= entire_insn
;
2070 #define FLD(f) abuf->fields.sfmt_trap.f
2073 f_uimm4
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
2075 /* Record the fields for the semantic handler. */
2076 FLD (f_uimm4
) = f_uimm4
;
2077 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_trap", "f_uimm4 0x%x", 'x', f_uimm4
, (char *) 0));
2079 #if WITH_PROFILE_MODEL_P
2080 /* Record the fields for profiling. */
2081 if (PROFILE_MODEL_P (current_cpu
))
2089 extract_sfmt_unlock
:
2091 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2092 CGEN_INSN_WORD insn
= entire_insn
;
2093 #define FLD(f) abuf->fields.sfmt_st_plus.f
2097 f_r1
= EXTRACT_MSB0_UINT (insn
, 16, 4, 4);
2098 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
2100 /* Record the fields for the semantic handler. */
2103 FLD (i_src1
) = & CPU (h_gr
)[f_r1
];
2104 FLD (i_src2
) = & CPU (h_gr
)[f_r2
];
2105 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_unlock", "f_r1 0x%x", 'x', f_r1
, "f_r2 0x%x", 'x', f_r2
, "src1 0x%x", 'x', f_r1
, "src2 0x%x", 'x', f_r2
, (char *) 0));
2107 #if WITH_PROFILE_MODEL_P
2108 /* Record the fields for profiling. */
2109 if (PROFILE_MODEL_P (current_cpu
))
2111 FLD (in_src1
) = f_r1
;
2112 FLD (in_src2
) = f_r2
;
2119 extract_sfmt_clrpsw
:
2121 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2122 CGEN_INSN_WORD insn
= entire_insn
;
2123 #define FLD(f) abuf->fields.sfmt_clrpsw.f
2126 f_uimm8
= EXTRACT_MSB0_UINT (insn
, 16, 8, 8);
2128 /* Record the fields for the semantic handler. */
2129 FLD (f_uimm8
) = f_uimm8
;
2130 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_clrpsw", "f_uimm8 0x%x", 'x', f_uimm8
, (char *) 0));
2136 extract_sfmt_setpsw
:
2138 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2139 CGEN_INSN_WORD insn
= entire_insn
;
2140 #define FLD(f) abuf->fields.sfmt_clrpsw.f
2143 f_uimm8
= EXTRACT_MSB0_UINT (insn
, 16, 8, 8);
2145 /* Record the fields for the semantic handler. */
2146 FLD (f_uimm8
) = f_uimm8
;
2147 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_setpsw", "f_uimm8 0x%x", 'x', f_uimm8
, (char *) 0));
2155 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2156 CGEN_INSN_WORD insn
= entire_insn
;
2157 #define FLD(f) abuf->fields.sfmt_bset.f
2162 f_uimm3
= EXTRACT_MSB0_UINT (insn
, 32, 5, 3);
2163 f_r2
= EXTRACT_MSB0_UINT (insn
, 32, 12, 4);
2164 f_simm16
= EXTRACT_MSB0_SINT (insn
, 32, 16, 16);
2166 /* Record the fields for the semantic handler. */
2167 FLD (f_simm16
) = f_simm16
;
2169 FLD (f_uimm3
) = f_uimm3
;
2170 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
2171 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_bset", "f_simm16 0x%x", 'x', f_simm16
, "f_r2 0x%x", 'x', f_r2
, "f_uimm3 0x%x", 'x', f_uimm3
, "sr 0x%x", 'x', f_r2
, (char *) 0));
2173 #if WITH_PROFILE_MODEL_P
2174 /* Record the fields for profiling. */
2175 if (PROFILE_MODEL_P (current_cpu
))
2186 const IDESC
*idesc
= &m32rbf_insn_data
[itype
];
2187 CGEN_INSN_WORD insn
= entire_insn
;
2188 #define FLD(f) abuf->fields.sfmt_bset.f
2192 f_uimm3
= EXTRACT_MSB0_UINT (insn
, 16, 5, 3);
2193 f_r2
= EXTRACT_MSB0_UINT (insn
, 16, 12, 4);
2195 /* Record the fields for the semantic handler. */
2197 FLD (f_uimm3
) = f_uimm3
;
2198 FLD (i_sr
) = & CPU (h_gr
)[f_r2
];
2199 CGEN_TRACE_EXTRACT (current_cpu
, abuf
, (current_cpu
, pc
, "sfmt_btst", "f_r2 0x%x", 'x', f_r2
, "f_uimm3 0x%x", 'x', f_uimm3
, "sr 0x%x", 'x', f_r2
, (char *) 0));
2201 #if WITH_PROFILE_MODEL_P
2202 /* Record the fields for profiling. */
2203 if (PROFILE_MODEL_P (current_cpu
))