1 /* Simulator instruction decoder for crisv32f.
2
3 THIS FILE IS MACHINE GENERATED WITH CGEN.
4
5 Copyright 1996-2010 Free Software Foundation, Inc.
6
7 This file is part of the GNU simulators.
8
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)
12 any later version.
13
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.
18
19 You should have received a copy of the GNU General Public License along
20 with this program; if not, write to the Free Software Foundation, Inc.,
21 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
22
23 */
24
25 #define WANT_CPU crisv32f
26 #define WANT_CPU_CRISV32F
27
28 #include "sim-main.h"
29 #include "sim-assert.h"
30 #include "cgen-ops.h"
31
32 /* The instruction descriptor array.
33 This is computed at runtime. Space for it is not malloc'd to save a
34 teensy bit of cpu in the decoder. Moving it to malloc space is trivial
35 but won't be done until necessary (we don't currently support the runtime
36 addition of instructions nor an SMP machine with different cpus). */
37 static IDESC crisv32f_insn_data[CRISV32F_INSN__MAX];
38
39 /* Commas between elements are contained in the macros.
40 Some of these are conditionally compiled out. */
41
42 static const struct insn_sem crisv32f_insn_sem[] =
43 {
44 { VIRTUAL_INSN_X_INVALID, CRISV32F_INSN_X_INVALID, CRISV32F_SFMT_EMPTY },
45 { VIRTUAL_INSN_X_AFTER, CRISV32F_INSN_X_AFTER, CRISV32F_SFMT_EMPTY },
46 { VIRTUAL_INSN_X_BEFORE, CRISV32F_INSN_X_BEFORE, CRISV32F_SFMT_EMPTY },
47 { VIRTUAL_INSN_X_CTI_CHAIN, CRISV32F_INSN_X_CTI_CHAIN, CRISV32F_SFMT_EMPTY },
48 { VIRTUAL_INSN_X_CHAIN, CRISV32F_INSN_X_CHAIN, CRISV32F_SFMT_EMPTY },
49 { VIRTUAL_INSN_X_BEGIN, CRISV32F_INSN_X_BEGIN, CRISV32F_SFMT_EMPTY },
50 { CRIS_INSN_MOVE_B_R, CRISV32F_INSN_MOVE_B_R, CRISV32F_SFMT_MOVE_B_R },
51 { CRIS_INSN_MOVE_W_R, CRISV32F_INSN_MOVE_W_R, CRISV32F_SFMT_MOVE_B_R },
52 { CRIS_INSN_MOVE_D_R, CRISV32F_INSN_MOVE_D_R, CRISV32F_SFMT_MOVE_D_R },
53 { CRIS_INSN_MOVEQ, CRISV32F_INSN_MOVEQ, CRISV32F_SFMT_MOVEQ },
54 { CRIS_INSN_MOVS_B_R, CRISV32F_INSN_MOVS_B_R, CRISV32F_SFMT_MOVS_B_R },
55 { CRIS_INSN_MOVS_W_R, CRISV32F_INSN_MOVS_W_R, CRISV32F_SFMT_MOVS_B_R },
56 { CRIS_INSN_MOVU_B_R, CRISV32F_INSN_MOVU_B_R, CRISV32F_SFMT_MOVS_B_R },
57 { CRIS_INSN_MOVU_W_R, CRISV32F_INSN_MOVU_W_R, CRISV32F_SFMT_MOVS_B_R },
58 { CRIS_INSN_MOVECBR, CRISV32F_INSN_MOVECBR, CRISV32F_SFMT_MOVECBR },
59 { CRIS_INSN_MOVECWR, CRISV32F_INSN_MOVECWR, CRISV32F_SFMT_MOVECWR },
60 { CRIS_INSN_MOVECDR, CRISV32F_INSN_MOVECDR, CRISV32F_SFMT_MOVECDR },
61 { CRIS_INSN_MOVSCBR, CRISV32F_INSN_MOVSCBR, CRISV32F_SFMT_MOVSCBR },
62 { CRIS_INSN_MOVSCWR, CRISV32F_INSN_MOVSCWR, CRISV32F_SFMT_MOVSCWR },
63 { CRIS_INSN_MOVUCBR, CRISV32F_INSN_MOVUCBR, CRISV32F_SFMT_MOVUCBR },
64 { CRIS_INSN_MOVUCWR, CRISV32F_INSN_MOVUCWR, CRISV32F_SFMT_MOVUCWR },
65 { CRIS_INSN_ADDQ, CRISV32F_INSN_ADDQ, CRISV32F_SFMT_ADDQ },
66 { CRIS_INSN_SUBQ, CRISV32F_INSN_SUBQ, CRISV32F_SFMT_ADDQ },
67 { CRIS_INSN_CMP_R_B_R, CRISV32F_INSN_CMP_R_B_R, CRISV32F_SFMT_CMP_R_B_R },
68 { CRIS_INSN_CMP_R_W_R, CRISV32F_INSN_CMP_R_W_R, CRISV32F_SFMT_CMP_R_B_R },
69 { CRIS_INSN_CMP_R_D_R, CRISV32F_INSN_CMP_R_D_R, CRISV32F_SFMT_CMP_R_B_R },
70 { CRIS_INSN_CMP_M_B_M, CRISV32F_INSN_CMP_M_B_M, CRISV32F_SFMT_CMP_M_B_M },
71 { CRIS_INSN_CMP_M_W_M, CRISV32F_INSN_CMP_M_W_M, CRISV32F_SFMT_CMP_M_W_M },
72 { CRIS_INSN_CMP_M_D_M, CRISV32F_INSN_CMP_M_D_M, CRISV32F_SFMT_CMP_M_D_M },
73 { CRIS_INSN_CMPCBR, CRISV32F_INSN_CMPCBR, CRISV32F_SFMT_CMPCBR },
74 { CRIS_INSN_CMPCWR, CRISV32F_INSN_CMPCWR, CRISV32F_SFMT_CMPCWR },
75 { CRIS_INSN_CMPCDR, CRISV32F_INSN_CMPCDR, CRISV32F_SFMT_CMPCDR },
76 { CRIS_INSN_CMPQ, CRISV32F_INSN_CMPQ, CRISV32F_SFMT_CMPQ },
77 { CRIS_INSN_CMPS_M_B_M, CRISV32F_INSN_CMPS_M_B_M, CRISV32F_SFMT_CMP_M_B_M },
78 { CRIS_INSN_CMPS_M_W_M, CRISV32F_INSN_CMPS_M_W_M, CRISV32F_SFMT_CMP_M_W_M },
79 { CRIS_INSN_CMPSCBR, CRISV32F_INSN_CMPSCBR, CRISV32F_SFMT_CMPCBR },
80 { CRIS_INSN_CMPSCWR, CRISV32F_INSN_CMPSCWR, CRISV32F_SFMT_CMPCWR },
81 { CRIS_INSN_CMPU_M_B_M, CRISV32F_INSN_CMPU_M_B_M, CRISV32F_SFMT_CMP_M_B_M },
82 { CRIS_INSN_CMPU_M_W_M, CRISV32F_INSN_CMPU_M_W_M, CRISV32F_SFMT_CMP_M_W_M },
83 { CRIS_INSN_CMPUCBR, CRISV32F_INSN_CMPUCBR, CRISV32F_SFMT_CMPUCBR },
84 { CRIS_INSN_CMPUCWR, CRISV32F_INSN_CMPUCWR, CRISV32F_SFMT_CMPUCWR },
85 { CRIS_INSN_MOVE_M_B_M, CRISV32F_INSN_MOVE_M_B_M, CRISV32F_SFMT_MOVE_M_B_M },
86 { CRIS_INSN_MOVE_M_W_M, CRISV32F_INSN_MOVE_M_W_M, CRISV32F_SFMT_MOVE_M_W_M },
87 { CRIS_INSN_MOVE_M_D_M, CRISV32F_INSN_MOVE_M_D_M, CRISV32F_SFMT_MOVE_M_D_M },
88 { CRIS_INSN_MOVS_M_B_M, CRISV32F_INSN_MOVS_M_B_M, CRISV32F_SFMT_MOVS_M_B_M },
89 { CRIS_INSN_MOVS_M_W_M, CRISV32F_INSN_MOVS_M_W_M, CRISV32F_SFMT_MOVS_M_W_M },
90 { CRIS_INSN_MOVU_M_B_M, CRISV32F_INSN_MOVU_M_B_M, CRISV32F_SFMT_MOVS_M_B_M },
91 { CRIS_INSN_MOVU_M_W_M, CRISV32F_INSN_MOVU_M_W_M, CRISV32F_SFMT_MOVS_M_W_M },
92 { CRIS_INSN_MOVE_R_SPRV32, CRISV32F_INSN_MOVE_R_SPRV32, CRISV32F_SFMT_MOVE_R_SPRV32 },
93 { CRIS_INSN_MOVE_SPR_RV32, CRISV32F_INSN_MOVE_SPR_RV32, CRISV32F_SFMT_MOVE_SPR_RV32 },
94 { CRIS_INSN_MOVE_M_SPRV32, CRISV32F_INSN_MOVE_M_SPRV32, CRISV32F_SFMT_MOVE_M_SPRV32 },
95 { CRIS_INSN_MOVE_C_SPRV32_P2, CRISV32F_INSN_MOVE_C_SPRV32_P2, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
96 { CRIS_INSN_MOVE_C_SPRV32_P3, CRISV32F_INSN_MOVE_C_SPRV32_P3, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
97 { CRIS_INSN_MOVE_C_SPRV32_P5, CRISV32F_INSN_MOVE_C_SPRV32_P5, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
98 { CRIS_INSN_MOVE_C_SPRV32_P6, CRISV32F_INSN_MOVE_C_SPRV32_P6, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
99 { CRIS_INSN_MOVE_C_SPRV32_P7, CRISV32F_INSN_MOVE_C_SPRV32_P7, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
100 { CRIS_INSN_MOVE_C_SPRV32_P9, CRISV32F_INSN_MOVE_C_SPRV32_P9, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
101 { CRIS_INSN_MOVE_C_SPRV32_P10, CRISV32F_INSN_MOVE_C_SPRV32_P10, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
102 { CRIS_INSN_MOVE_C_SPRV32_P11, CRISV32F_INSN_MOVE_C_SPRV32_P11, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
103 { CRIS_INSN_MOVE_C_SPRV32_P12, CRISV32F_INSN_MOVE_C_SPRV32_P12, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
104 { CRIS_INSN_MOVE_C_SPRV32_P13, CRISV32F_INSN_MOVE_C_SPRV32_P13, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
105 { CRIS_INSN_MOVE_C_SPRV32_P14, CRISV32F_INSN_MOVE_C_SPRV32_P14, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
106 { CRIS_INSN_MOVE_C_SPRV32_P15, CRISV32F_INSN_MOVE_C_SPRV32_P15, CRISV32F_SFMT_MOVE_C_SPRV32_P2 },
107 { CRIS_INSN_MOVE_SPR_MV32, CRISV32F_INSN_MOVE_SPR_MV32, CRISV32F_SFMT_MOVE_SPR_MV32 },
108 { CRIS_INSN_MOVE_SS_R, CRISV32F_INSN_MOVE_SS_R, CRISV32F_SFMT_MOVE_SS_R },
109 { CRIS_INSN_MOVE_R_SS, CRISV32F_INSN_MOVE_R_SS, CRISV32F_SFMT_MOVE_R_SS },
110 { CRIS_INSN_MOVEM_R_M_V32, CRISV32F_INSN_MOVEM_R_M_V32, CRISV32F_SFMT_MOVEM_R_M_V32 },
111 { CRIS_INSN_MOVEM_M_R_V32, CRISV32F_INSN_MOVEM_M_R_V32, CRISV32F_SFMT_MOVEM_M_R_V32 },
112 { CRIS_INSN_ADD_B_R, CRISV32F_INSN_ADD_B_R, CRISV32F_SFMT_ADD_B_R },
113 { CRIS_INSN_ADD_W_R, CRISV32F_INSN_ADD_W_R, CRISV32F_SFMT_ADD_B_R },
114 { CRIS_INSN_ADD_D_R, CRISV32F_INSN_ADD_D_R, CRISV32F_SFMT_ADD_D_R },
115 { CRIS_INSN_ADD_M_B_M, CRISV32F_INSN_ADD_M_B_M, CRISV32F_SFMT_ADD_M_B_M },
116 { CRIS_INSN_ADD_M_W_M, CRISV32F_INSN_ADD_M_W_M, CRISV32F_SFMT_ADD_M_W_M },
117 { CRIS_INSN_ADD_M_D_M, CRISV32F_INSN_ADD_M_D_M, CRISV32F_SFMT_ADD_M_D_M },
118 { CRIS_INSN_ADDCBR, CRISV32F_INSN_ADDCBR, CRISV32F_SFMT_ADDCBR },
119 { CRIS_INSN_ADDCWR, CRISV32F_INSN_ADDCWR, CRISV32F_SFMT_ADDCWR },
120 { CRIS_INSN_ADDCDR, CRISV32F_INSN_ADDCDR, CRISV32F_SFMT_ADDCDR },
121 { CRIS_INSN_ADDS_B_R, CRISV32F_INSN_ADDS_B_R, CRISV32F_SFMT_ADD_D_R },
122 { CRIS_INSN_ADDS_W_R, CRISV32F_INSN_ADDS_W_R, CRISV32F_SFMT_ADD_D_R },
123 { CRIS_INSN_ADDS_M_B_M, CRISV32F_INSN_ADDS_M_B_M, CRISV32F_SFMT_ADDS_M_B_M },
124 { CRIS_INSN_ADDS_M_W_M, CRISV32F_INSN_ADDS_M_W_M, CRISV32F_SFMT_ADDS_M_W_M },
125 { CRIS_INSN_ADDSCBR, CRISV32F_INSN_ADDSCBR, CRISV32F_SFMT_ADDSCBR },
126 { CRIS_INSN_ADDSCWR, CRISV32F_INSN_ADDSCWR, CRISV32F_SFMT_ADDSCWR },
127 { CRIS_INSN_ADDU_B_R, CRISV32F_INSN_ADDU_B_R, CRISV32F_SFMT_ADD_D_R },
128 { CRIS_INSN_ADDU_W_R, CRISV32F_INSN_ADDU_W_R, CRISV32F_SFMT_ADD_D_R },
129 { CRIS_INSN_ADDU_M_B_M, CRISV32F_INSN_ADDU_M_B_M, CRISV32F_SFMT_ADDS_M_B_M },
130 { CRIS_INSN_ADDU_M_W_M, CRISV32F_INSN_ADDU_M_W_M, CRISV32F_SFMT_ADDS_M_W_M },
131 { CRIS_INSN_ADDUCBR, CRISV32F_INSN_ADDUCBR, CRISV32F_SFMT_ADDSCBR },
132 { CRIS_INSN_ADDUCWR, CRISV32F_INSN_ADDUCWR, CRISV32F_SFMT_ADDSCWR },
133 { CRIS_INSN_SUB_B_R, CRISV32F_INSN_SUB_B_R, CRISV32F_SFMT_ADD_B_R },
134 { CRIS_INSN_SUB_W_R, CRISV32F_INSN_SUB_W_R, CRISV32F_SFMT_ADD_B_R },
135 { CRIS_INSN_SUB_D_R, CRISV32F_INSN_SUB_D_R, CRISV32F_SFMT_ADD_D_R },
136 { CRIS_INSN_SUB_M_B_M, CRISV32F_INSN_SUB_M_B_M, CRISV32F_SFMT_ADD_M_B_M },
137 { CRIS_INSN_SUB_M_W_M, CRISV32F_INSN_SUB_M_W_M, CRISV32F_SFMT_ADD_M_W_M },
138 { CRIS_INSN_SUB_M_D_M, CRISV32F_INSN_SUB_M_D_M, CRISV32F_SFMT_ADD_M_D_M },
139 { CRIS_INSN_SUBCBR, CRISV32F_INSN_SUBCBR, CRISV32F_SFMT_ADDCBR },
140 { CRIS_INSN_SUBCWR, CRISV32F_INSN_SUBCWR, CRISV32F_SFMT_ADDCWR },
141 { CRIS_INSN_SUBCDR, CRISV32F_INSN_SUBCDR, CRISV32F_SFMT_ADDCDR },
142 { CRIS_INSN_SUBS_B_R, CRISV32F_INSN_SUBS_B_R, CRISV32F_SFMT_ADD_D_R },
143 { CRIS_INSN_SUBS_W_R, CRISV32F_INSN_SUBS_W_R, CRISV32F_SFMT_ADD_D_R },
144 { CRIS_INSN_SUBS_M_B_M, CRISV32F_INSN_SUBS_M_B_M, CRISV32F_SFMT_ADDS_M_B_M },
145 { CRIS_INSN_SUBS_M_W_M, CRISV32F_INSN_SUBS_M_W_M, CRISV32F_SFMT_ADDS_M_W_M },
146 { CRIS_INSN_SUBSCBR, CRISV32F_INSN_SUBSCBR, CRISV32F_SFMT_ADDSCBR },
147 { CRIS_INSN_SUBSCWR, CRISV32F_INSN_SUBSCWR, CRISV32F_SFMT_ADDSCWR },
148 { CRIS_INSN_SUBU_B_R, CRISV32F_INSN_SUBU_B_R, CRISV32F_SFMT_ADD_D_R },
149 { CRIS_INSN_SUBU_W_R, CRISV32F_INSN_SUBU_W_R, CRISV32F_SFMT_ADD_D_R },
150 { CRIS_INSN_SUBU_M_B_M, CRISV32F_INSN_SUBU_M_B_M, CRISV32F_SFMT_ADDS_M_B_M },
151 { CRIS_INSN_SUBU_M_W_M, CRISV32F_INSN_SUBU_M_W_M, CRISV32F_SFMT_ADDS_M_W_M },
152 { CRIS_INSN_SUBUCBR, CRISV32F_INSN_SUBUCBR, CRISV32F_SFMT_ADDSCBR },
153 { CRIS_INSN_SUBUCWR, CRISV32F_INSN_SUBUCWR, CRISV32F_SFMT_ADDSCWR },
154 { CRIS_INSN_ADDC_R, CRISV32F_INSN_ADDC_R, CRISV32F_SFMT_ADD_D_R },
155 { CRIS_INSN_ADDC_M, CRISV32F_INSN_ADDC_M, CRISV32F_SFMT_ADDC_M },
156 { CRIS_INSN_ADDC_C, CRISV32F_INSN_ADDC_C, CRISV32F_SFMT_ADDCDR },
157 { CRIS_INSN_LAPC_D, CRISV32F_INSN_LAPC_D, CRISV32F_SFMT_LAPC_D },
158 { CRIS_INSN_LAPCQ, CRISV32F_INSN_LAPCQ, CRISV32F_SFMT_LAPCQ },
159 { CRIS_INSN_ADDI_B_R, CRISV32F_INSN_ADDI_B_R, CRISV32F_SFMT_ADDI_B_R },
160 { CRIS_INSN_ADDI_W_R, CRISV32F_INSN_ADDI_W_R, CRISV32F_SFMT_ADDI_B_R },
161 { CRIS_INSN_ADDI_D_R, CRISV32F_INSN_ADDI_D_R, CRISV32F_SFMT_ADDI_B_R },
162 { CRIS_INSN_NEG_B_R, CRISV32F_INSN_NEG_B_R, CRISV32F_SFMT_NEG_B_R },
163 { CRIS_INSN_NEG_W_R, CRISV32F_INSN_NEG_W_R, CRISV32F_SFMT_NEG_B_R },
164 { CRIS_INSN_NEG_D_R, CRISV32F_INSN_NEG_D_R, CRISV32F_SFMT_NEG_D_R },
165 { CRIS_INSN_TEST_M_B_M, CRISV32F_INSN_TEST_M_B_M, CRISV32F_SFMT_TEST_M_B_M },
166 { CRIS_INSN_TEST_M_W_M, CRISV32F_INSN_TEST_M_W_M, CRISV32F_SFMT_TEST_M_W_M },
167 { CRIS_INSN_TEST_M_D_M, CRISV32F_INSN_TEST_M_D_M, CRISV32F_SFMT_TEST_M_D_M },
168 { CRIS_INSN_MOVE_R_M_B_M, CRISV32F_INSN_MOVE_R_M_B_M, CRISV32F_SFMT_MOVE_R_M_B_M },
169 { CRIS_INSN_MOVE_R_M_W_M, CRISV32F_INSN_MOVE_R_M_W_M, CRISV32F_SFMT_MOVE_R_M_W_M },
170 { CRIS_INSN_MOVE_R_M_D_M, CRISV32F_INSN_MOVE_R_M_D_M, CRISV32F_SFMT_MOVE_R_M_D_M },
171 { CRIS_INSN_MULS_B, CRISV32F_INSN_MULS_B, CRISV32F_SFMT_MULS_B },
172 { CRIS_INSN_MULS_W, CRISV32F_INSN_MULS_W, CRISV32F_SFMT_MULS_B },
173 { CRIS_INSN_MULS_D, CRISV32F_INSN_MULS_D, CRISV32F_SFMT_MULS_B },
174 { CRIS_INSN_MULU_B, CRISV32F_INSN_MULU_B, CRISV32F_SFMT_MULS_B },
175 { CRIS_INSN_MULU_W, CRISV32F_INSN_MULU_W, CRISV32F_SFMT_MULS_B },
176 { CRIS_INSN_MULU_D, CRISV32F_INSN_MULU_D, CRISV32F_SFMT_MULS_B },
177 { CRIS_INSN_MCP, CRISV32F_INSN_MCP, CRISV32F_SFMT_MCP },
178 { CRIS_INSN_DSTEP, CRISV32F_INSN_DSTEP, CRISV32F_SFMT_DSTEP },
179 { CRIS_INSN_ABS, CRISV32F_INSN_ABS, CRISV32F_SFMT_MOVS_B_R },
180 { CRIS_INSN_AND_B_R, CRISV32F_INSN_AND_B_R, CRISV32F_SFMT_AND_B_R },
181 { CRIS_INSN_AND_W_R, CRISV32F_INSN_AND_W_R, CRISV32F_SFMT_AND_B_R },
182 { CRIS_INSN_AND_D_R, CRISV32F_INSN_AND_D_R, CRISV32F_SFMT_AND_D_R },
183 { CRIS_INSN_AND_M_B_M, CRISV32F_INSN_AND_M_B_M, CRISV32F_SFMT_AND_M_B_M },
184 { CRIS_INSN_AND_M_W_M, CRISV32F_INSN_AND_M_W_M, CRISV32F_SFMT_AND_M_W_M },
185 { CRIS_INSN_AND_M_D_M, CRISV32F_INSN_AND_M_D_M, CRISV32F_SFMT_AND_M_D_M },
186 { CRIS_INSN_ANDCBR, CRISV32F_INSN_ANDCBR, CRISV32F_SFMT_ANDCBR },
187 { CRIS_INSN_ANDCWR, CRISV32F_INSN_ANDCWR, CRISV32F_SFMT_ANDCWR },
188 { CRIS_INSN_ANDCDR, CRISV32F_INSN_ANDCDR, CRISV32F_SFMT_ANDCDR },
189 { CRIS_INSN_ANDQ, CRISV32F_INSN_ANDQ, CRISV32F_SFMT_ANDQ },
190 { CRIS_INSN_ORR_B_R, CRISV32F_INSN_ORR_B_R, CRISV32F_SFMT_AND_B_R },
191 { CRIS_INSN_ORR_W_R, CRISV32F_INSN_ORR_W_R, CRISV32F_SFMT_AND_B_R },
192 { CRIS_INSN_ORR_D_R, CRISV32F_INSN_ORR_D_R, CRISV32F_SFMT_AND_D_R },
193 { CRIS_INSN_OR_M_B_M, CRISV32F_INSN_OR_M_B_M, CRISV32F_SFMT_AND_M_B_M },
194 { CRIS_INSN_OR_M_W_M, CRISV32F_INSN_OR_M_W_M, CRISV32F_SFMT_AND_M_W_M },
195 { CRIS_INSN_OR_M_D_M, CRISV32F_INSN_OR_M_D_M, CRISV32F_SFMT_AND_M_D_M },
196 { CRIS_INSN_ORCBR, CRISV32F_INSN_ORCBR, CRISV32F_SFMT_ANDCBR },
197 { CRIS_INSN_ORCWR, CRISV32F_INSN_ORCWR, CRISV32F_SFMT_ANDCWR },
198 { CRIS_INSN_ORCDR, CRISV32F_INSN_ORCDR, CRISV32F_SFMT_ANDCDR },
199 { CRIS_INSN_ORQ, CRISV32F_INSN_ORQ, CRISV32F_SFMT_ANDQ },
200 { CRIS_INSN_XOR, CRISV32F_INSN_XOR, CRISV32F_SFMT_DSTEP },
201 { CRIS_INSN_SWAP, CRISV32F_INSN_SWAP, CRISV32F_SFMT_SWAP },
202 { CRIS_INSN_ASRR_B_R, CRISV32F_INSN_ASRR_B_R, CRISV32F_SFMT_AND_B_R },
203 { CRIS_INSN_ASRR_W_R, CRISV32F_INSN_ASRR_W_R, CRISV32F_SFMT_AND_B_R },
204 { CRIS_INSN_ASRR_D_R, CRISV32F_INSN_ASRR_D_R, CRISV32F_SFMT_AND_D_R },
205 { CRIS_INSN_ASRQ, CRISV32F_INSN_ASRQ, CRISV32F_SFMT_ASRQ },
206 { CRIS_INSN_LSRR_B_R, CRISV32F_INSN_LSRR_B_R, CRISV32F_SFMT_LSRR_B_R },
207 { CRIS_INSN_LSRR_W_R, CRISV32F_INSN_LSRR_W_R, CRISV32F_SFMT_LSRR_B_R },
208 { CRIS_INSN_LSRR_D_R, CRISV32F_INSN_LSRR_D_R, CRISV32F_SFMT_LSRR_D_R },
209 { CRIS_INSN_LSRQ, CRISV32F_INSN_LSRQ, CRISV32F_SFMT_ASRQ },
210 { CRIS_INSN_LSLR_B_R, CRISV32F_INSN_LSLR_B_R, CRISV32F_SFMT_LSRR_B_R },
211 { CRIS_INSN_LSLR_W_R, CRISV32F_INSN_LSLR_W_R, CRISV32F_SFMT_LSRR_B_R },
212 { CRIS_INSN_LSLR_D_R, CRISV32F_INSN_LSLR_D_R, CRISV32F_SFMT_LSRR_D_R },
213 { CRIS_INSN_LSLQ, CRISV32F_INSN_LSLQ, CRISV32F_SFMT_ASRQ },
214 { CRIS_INSN_BTST, CRISV32F_INSN_BTST, CRISV32F_SFMT_BTST },
215 { CRIS_INSN_BTSTQ, CRISV32F_INSN_BTSTQ, CRISV32F_SFMT_BTSTQ },
216 { CRIS_INSN_SETF, CRISV32F_INSN_SETF, CRISV32F_SFMT_SETF },
217 { CRIS_INSN_CLEARF, CRISV32F_INSN_CLEARF, CRISV32F_SFMT_SETF },
218 { CRIS_INSN_RFE, CRISV32F_INSN_RFE, CRISV32F_SFMT_RFE },
219 { CRIS_INSN_SFE, CRISV32F_INSN_SFE, CRISV32F_SFMT_SFE },
220 { CRIS_INSN_RFG, CRISV32F_INSN_RFG, CRISV32F_SFMT_RFG },
221 { CRIS_INSN_RFN, CRISV32F_INSN_RFN, CRISV32F_SFMT_RFN },
222 { CRIS_INSN_HALT, CRISV32F_INSN_HALT, CRISV32F_SFMT_HALT },
223 { CRIS_INSN_BCC_B, CRISV32F_INSN_BCC_B, CRISV32F_SFMT_BCC_B },
224 { CRIS_INSN_BA_B, CRISV32F_INSN_BA_B, CRISV32F_SFMT_BA_B },
225 { CRIS_INSN_BCC_W, CRISV32F_INSN_BCC_W, CRISV32F_SFMT_BCC_W },
226 { CRIS_INSN_BA_W, CRISV32F_INSN_BA_W, CRISV32F_SFMT_BA_W },
227 { CRIS_INSN_JAS_R, CRISV32F_INSN_JAS_R, CRISV32F_SFMT_JAS_R },
228 { CRIS_INSN_JAS_C, CRISV32F_INSN_JAS_C, CRISV32F_SFMT_JAS_C },
229 { CRIS_INSN_JUMP_P, CRISV32F_INSN_JUMP_P, CRISV32F_SFMT_JUMP_P },
230 { CRIS_INSN_BAS_C, CRISV32F_INSN_BAS_C, CRISV32F_SFMT_BAS_C },
231 { CRIS_INSN_JASC_R, CRISV32F_INSN_JASC_R, CRISV32F_SFMT_JASC_R },
232 { CRIS_INSN_JASC_C, CRISV32F_INSN_JASC_C, CRISV32F_SFMT_JAS_C },
233 { CRIS_INSN_BASC_C, CRISV32F_INSN_BASC_C, CRISV32F_SFMT_BAS_C },
234 { CRIS_INSN_BREAK, CRISV32F_INSN_BREAK, CRISV32F_SFMT_BREAK },
235 { CRIS_INSN_BOUND_R_B_R, CRISV32F_INSN_BOUND_R_B_R, CRISV32F_SFMT_DSTEP },
236 { CRIS_INSN_BOUND_R_W_R, CRISV32F_INSN_BOUND_R_W_R, CRISV32F_SFMT_DSTEP },
237 { CRIS_INSN_BOUND_R_D_R, CRISV32F_INSN_BOUND_R_D_R, CRISV32F_SFMT_DSTEP },
238 { CRIS_INSN_BOUND_CB, CRISV32F_INSN_BOUND_CB, CRISV32F_SFMT_BOUND_CB },
239 { CRIS_INSN_BOUND_CW, CRISV32F_INSN_BOUND_CW, CRISV32F_SFMT_BOUND_CW },
240 { CRIS_INSN_BOUND_CD, CRISV32F_INSN_BOUND_CD, CRISV32F_SFMT_BOUND_CD },
241 { CRIS_INSN_SCC, CRISV32F_INSN_SCC, CRISV32F_SFMT_SCC },
242 { CRIS_INSN_LZ, CRISV32F_INSN_LZ, CRISV32F_SFMT_MOVS_B_R },
243 { CRIS_INSN_ADDOQ, CRISV32F_INSN_ADDOQ, CRISV32F_SFMT_ADDOQ },
244 { CRIS_INSN_ADDO_M_B_M, CRISV32F_INSN_ADDO_M_B_M, CRISV32F_SFMT_ADDO_M_B_M },
245 { CRIS_INSN_ADDO_M_W_M, CRISV32F_INSN_ADDO_M_W_M, CRISV32F_SFMT_ADDO_M_W_M },
246 { CRIS_INSN_ADDO_M_D_M, CRISV32F_INSN_ADDO_M_D_M, CRISV32F_SFMT_ADDO_M_D_M },
247 { CRIS_INSN_ADDO_CB, CRISV32F_INSN_ADDO_CB, CRISV32F_SFMT_ADDO_CB },
248 { CRIS_INSN_ADDO_CW, CRISV32F_INSN_ADDO_CW, CRISV32F_SFMT_ADDO_CW },
249 { CRIS_INSN_ADDO_CD, CRISV32F_INSN_ADDO_CD, CRISV32F_SFMT_ADDO_CD },
250 { CRIS_INSN_ADDI_ACR_B_R, CRISV32F_INSN_ADDI_ACR_B_R, CRISV32F_SFMT_ADDI_ACR_B_R },
251 { CRIS_INSN_ADDI_ACR_W_R, CRISV32F_INSN_ADDI_ACR_W_R, CRISV32F_SFMT_ADDI_ACR_B_R },
252 { CRIS_INSN_ADDI_ACR_D_R, CRISV32F_INSN_ADDI_ACR_D_R, CRISV32F_SFMT_ADDI_ACR_B_R },
253 { CRIS_INSN_FIDXI, CRISV32F_INSN_FIDXI, CRISV32F_SFMT_FIDXI },
254 { CRIS_INSN_FTAGI, CRISV32F_INSN_FTAGI, CRISV32F_SFMT_FIDXI },
255 { CRIS_INSN_FIDXD, CRISV32F_INSN_FIDXD, CRISV32F_SFMT_FIDXI },
256 { CRIS_INSN_FTAGD, CRISV32F_INSN_FTAGD, CRISV32F_SFMT_FIDXI },
257 };
258
259 static const struct insn_sem crisv32f_insn_sem_invalid =
260 {
261 VIRTUAL_INSN_X_INVALID, CRISV32F_INSN_X_INVALID, CRISV32F_SFMT_EMPTY
262 };
263
264 /* Initialize an IDESC from the compile-time computable parts. */
265
266 static INLINE void
init_idesc(SIM_CPU * cpu,IDESC * id,const struct insn_sem * t)267 init_idesc (SIM_CPU *cpu, IDESC *id, const struct insn_sem *t)
268 {
269 const CGEN_INSN *insn_table = CGEN_CPU_INSN_TABLE (CPU_CPU_DESC (cpu))->init_entries;
270
271 id->num = t->index;
272 id->sfmt = t->sfmt;
273 if ((int) t->type <= 0)
274 id->idata = & cgen_virtual_insn_table[- (int) t->type];
275 else
276 id->idata = & insn_table[t->type];
277 id->attrs = CGEN_INSN_ATTRS (id->idata);
278 /* Oh my god, a magic number. */
279 id->length = CGEN_INSN_BITSIZE (id->idata) / 8;
280
281 #if WITH_PROFILE_MODEL_P
282 id->timing = & MODEL_TIMING (CPU_MODEL (cpu)) [t->index];
283 {
284 SIM_DESC sd = CPU_STATE (cpu);
285 SIM_ASSERT (t->index == id->timing->num);
286 }
287 #endif
288
289 /* Semantic pointers are initialized elsewhere. */
290 }
291
292 /* Initialize the instruction descriptor table. */
293
294 void
crisv32f_init_idesc_table(SIM_CPU * cpu)295 crisv32f_init_idesc_table (SIM_CPU *cpu)
296 {
297 IDESC *id,*tabend;
298 const struct insn_sem *t,*tend;
299 int tabsize = CRISV32F_INSN__MAX;
300 IDESC *table = crisv32f_insn_data;
301
302 memset (table, 0, tabsize * sizeof (IDESC));
303
304 /* First set all entries to the `invalid insn'. */
305 t = & crisv32f_insn_sem_invalid;
306 for (id = table, tabend = table + tabsize; id < tabend; ++id)
307 init_idesc (cpu, id, t);
308
309 /* Now fill in the values for the chosen cpu. */
310 for (t = crisv32f_insn_sem, tend = t + sizeof (crisv32f_insn_sem) / sizeof (*t);
311 t != tend; ++t)
312 {
313 init_idesc (cpu, & table[t->index], t);
314 }
315
316 /* Link the IDESC table into the cpu. */
317 CPU_IDESC (cpu) = table;
318 }
319
320 /* Given an instruction, return a pointer to its IDESC entry. */
321
322 const IDESC *
crisv32f_decode(SIM_CPU * current_cpu,IADDR pc,CGEN_INSN_WORD base_insn,ARGBUF * abuf)323 crisv32f_decode (SIM_CPU *current_cpu, IADDR pc,
324 CGEN_INSN_WORD base_insn,
325 ARGBUF *abuf)
326 {
327 /* Result of decoder. */
328 CRISV32F_INSN_TYPE itype;
329
330 {
331 CGEN_INSN_WORD insn = base_insn;
332
333 {
334 unsigned int val = (((insn >> 4) & (255 << 0)));
335 switch (val)
336 {
337 case 0 : /* fall through */
338 case 1 : /* fall through */
339 case 2 : /* fall through */
340 case 3 : /* fall through */
341 case 4 : /* fall through */
342 case 5 : /* fall through */
343 case 6 : /* fall through */
344 case 7 : /* fall through */
345 case 8 : /* fall through */
346 case 9 : /* fall through */
347 case 10 : /* fall through */
348 case 11 : /* fall through */
349 case 12 : /* fall through */
350 case 13 : /* fall through */
351 case 14 : /* fall through */
352 case 15 :
353 {
354 unsigned int val = (((insn >> 12) & (15 << 0)));
355 switch (val)
356 {
357 case 0 : /* fall through */
358 case 1 : /* fall through */
359 case 2 : /* fall through */
360 case 3 : /* fall through */
361 case 4 : /* fall through */
362 case 5 : /* fall through */
363 case 6 : /* fall through */
364 case 7 : /* fall through */
365 case 8 : /* fall through */
366 case 9 : /* fall through */
367 case 10 : /* fall through */
368 case 11 : /* fall through */
369 case 12 : /* fall through */
370 case 13 : /* fall through */
371 case 15 : itype = CRISV32F_INSN_BCC_B; goto extract_sfmt_bcc_b;
372 case 14 : itype = CRISV32F_INSN_BA_B; goto extract_sfmt_ba_b;
373 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
374 }
375 }
376 case 16 : /* fall through */
377 case 17 : /* fall through */
378 case 18 : /* fall through */
379 case 19 : /* fall through */
380 case 20 : /* fall through */
381 case 21 : /* fall through */
382 case 22 : /* fall through */
383 case 23 : /* fall through */
384 case 24 : /* fall through */
385 case 25 : /* fall through */
386 case 26 : /* fall through */
387 case 27 : /* fall through */
388 case 28 : /* fall through */
389 case 29 : /* fall through */
390 case 30 : /* fall through */
391 case 31 : itype = CRISV32F_INSN_ADDOQ; goto extract_sfmt_addoq;
392 case 32 : /* fall through */
393 case 33 : /* fall through */
394 case 34 : /* fall through */
395 case 35 : itype = CRISV32F_INSN_ADDQ; goto extract_sfmt_addq;
396 case 36 : /* fall through */
397 case 37 : /* fall through */
398 case 38 : /* fall through */
399 case 39 : itype = CRISV32F_INSN_MOVEQ; goto extract_sfmt_moveq;
400 case 40 : /* fall through */
401 case 41 : /* fall through */
402 case 42 : /* fall through */
403 case 43 : itype = CRISV32F_INSN_SUBQ; goto extract_sfmt_addq;
404 case 44 : /* fall through */
405 case 45 : /* fall through */
406 case 46 : /* fall through */
407 case 47 : itype = CRISV32F_INSN_CMPQ; goto extract_sfmt_cmpq;
408 case 48 : /* fall through */
409 case 49 : /* fall through */
410 case 50 : /* fall through */
411 case 51 : itype = CRISV32F_INSN_ANDQ; goto extract_sfmt_andq;
412 case 52 : /* fall through */
413 case 53 : /* fall through */
414 case 54 : /* fall through */
415 case 55 : itype = CRISV32F_INSN_ORQ; goto extract_sfmt_andq;
416 case 56 : /* fall through */
417 case 57 : itype = CRISV32F_INSN_BTSTQ; goto extract_sfmt_btstq;
418 case 58 : /* fall through */
419 case 59 : itype = CRISV32F_INSN_ASRQ; goto extract_sfmt_asrq;
420 case 60 : /* fall through */
421 case 61 : itype = CRISV32F_INSN_LSLQ; goto extract_sfmt_asrq;
422 case 62 : /* fall through */
423 case 63 : itype = CRISV32F_INSN_LSRQ; goto extract_sfmt_asrq;
424 case 64 : itype = CRISV32F_INSN_ADDU_B_R; goto extract_sfmt_add_d_r;
425 case 65 : itype = CRISV32F_INSN_ADDU_W_R; goto extract_sfmt_add_d_r;
426 case 66 : itype = CRISV32F_INSN_ADDS_B_R; goto extract_sfmt_add_d_r;
427 case 67 : itype = CRISV32F_INSN_ADDS_W_R; goto extract_sfmt_add_d_r;
428 case 68 : itype = CRISV32F_INSN_MOVU_B_R; goto extract_sfmt_movs_b_r;
429 case 69 : itype = CRISV32F_INSN_MOVU_W_R; goto extract_sfmt_movs_b_r;
430 case 70 : itype = CRISV32F_INSN_MOVS_B_R; goto extract_sfmt_movs_b_r;
431 case 71 : itype = CRISV32F_INSN_MOVS_W_R; goto extract_sfmt_movs_b_r;
432 case 72 : itype = CRISV32F_INSN_SUBU_B_R; goto extract_sfmt_add_d_r;
433 case 73 : itype = CRISV32F_INSN_SUBU_W_R; goto extract_sfmt_add_d_r;
434 case 74 : itype = CRISV32F_INSN_SUBS_B_R; goto extract_sfmt_add_d_r;
435 case 75 : itype = CRISV32F_INSN_SUBS_W_R; goto extract_sfmt_add_d_r;
436 case 76 : itype = CRISV32F_INSN_LSLR_B_R; goto extract_sfmt_lsrr_b_r;
437 case 77 : itype = CRISV32F_INSN_LSLR_W_R; goto extract_sfmt_lsrr_b_r;
438 case 78 : itype = CRISV32F_INSN_LSLR_D_R; goto extract_sfmt_lsrr_d_r;
439 case 79 : itype = CRISV32F_INSN_BTST; goto extract_sfmt_btst;
440 case 80 : itype = CRISV32F_INSN_ADDI_B_R; goto extract_sfmt_addi_b_r;
441 case 81 : itype = CRISV32F_INSN_ADDI_W_R; goto extract_sfmt_addi_b_r;
442 case 82 : itype = CRISV32F_INSN_ADDI_D_R; goto extract_sfmt_addi_b_r;
443 case 83 : itype = CRISV32F_INSN_SCC; goto extract_sfmt_scc;
444 case 84 : itype = CRISV32F_INSN_ADDI_ACR_B_R; goto extract_sfmt_addi_acr_b_r;
445 case 85 : itype = CRISV32F_INSN_ADDI_ACR_W_R; goto extract_sfmt_addi_acr_b_r;
446 case 86 : itype = CRISV32F_INSN_ADDI_ACR_D_R; goto extract_sfmt_addi_acr_b_r;
447 case 87 : itype = CRISV32F_INSN_ADDC_R; goto extract_sfmt_add_d_r;
448 case 88 : itype = CRISV32F_INSN_NEG_B_R; goto extract_sfmt_neg_b_r;
449 case 89 : itype = CRISV32F_INSN_NEG_W_R; goto extract_sfmt_neg_b_r;
450 case 90 : itype = CRISV32F_INSN_NEG_D_R; goto extract_sfmt_neg_d_r;
451 case 91 : itype = CRISV32F_INSN_SETF; goto extract_sfmt_setf;
452 case 92 : itype = CRISV32F_INSN_BOUND_R_B_R; goto extract_sfmt_dstep;
453 case 93 : itype = CRISV32F_INSN_BOUND_R_W_R; goto extract_sfmt_dstep;
454 case 94 : itype = CRISV32F_INSN_BOUND_R_D_R; goto extract_sfmt_dstep;
455 case 95 : itype = CRISV32F_INSN_CLEARF; goto extract_sfmt_setf;
456 case 96 : itype = CRISV32F_INSN_ADD_B_R; goto extract_sfmt_add_b_r;
457 case 97 : itype = CRISV32F_INSN_ADD_W_R; goto extract_sfmt_add_b_r;
458 case 98 : itype = CRISV32F_INSN_ADD_D_R; goto extract_sfmt_add_d_r;
459 case 99 : itype = CRISV32F_INSN_MOVE_R_SPRV32; goto extract_sfmt_move_r_sprv32;
460 case 100 : itype = CRISV32F_INSN_MOVE_B_R; goto extract_sfmt_move_b_r;
461 case 101 : itype = CRISV32F_INSN_MOVE_W_R; goto extract_sfmt_move_b_r;
462 case 102 : itype = CRISV32F_INSN_MOVE_D_R; goto extract_sfmt_move_d_r;
463 case 103 : itype = CRISV32F_INSN_MOVE_SPR_RV32; goto extract_sfmt_move_spr_rv32;
464 case 104 : itype = CRISV32F_INSN_SUB_B_R; goto extract_sfmt_add_b_r;
465 case 105 : itype = CRISV32F_INSN_SUB_W_R; goto extract_sfmt_add_b_r;
466 case 106 : itype = CRISV32F_INSN_SUB_D_R; goto extract_sfmt_add_d_r;
467 case 107 : itype = CRISV32F_INSN_ABS; goto extract_sfmt_movs_b_r;
468 case 108 : itype = CRISV32F_INSN_CMP_R_B_R; goto extract_sfmt_cmp_r_b_r;
469 case 109 : itype = CRISV32F_INSN_CMP_R_W_R; goto extract_sfmt_cmp_r_b_r;
470 case 110 : itype = CRISV32F_INSN_CMP_R_D_R; goto extract_sfmt_cmp_r_b_r;
471 case 111 : itype = CRISV32F_INSN_DSTEP; goto extract_sfmt_dstep;
472 case 112 : itype = CRISV32F_INSN_AND_B_R; goto extract_sfmt_and_b_r;
473 case 113 : itype = CRISV32F_INSN_AND_W_R; goto extract_sfmt_and_b_r;
474 case 114 : itype = CRISV32F_INSN_AND_D_R; goto extract_sfmt_and_d_r;
475 case 115 : itype = CRISV32F_INSN_LZ; goto extract_sfmt_movs_b_r;
476 case 116 : itype = CRISV32F_INSN_ORR_B_R; goto extract_sfmt_and_b_r;
477 case 117 : itype = CRISV32F_INSN_ORR_W_R; goto extract_sfmt_and_b_r;
478 case 118 : itype = CRISV32F_INSN_ORR_D_R; goto extract_sfmt_and_d_r;
479 case 119 : itype = CRISV32F_INSN_SWAP; goto extract_sfmt_swap;
480 case 120 : itype = CRISV32F_INSN_ASRR_B_R; goto extract_sfmt_and_b_r;
481 case 121 : itype = CRISV32F_INSN_ASRR_W_R; goto extract_sfmt_and_b_r;
482 case 122 : itype = CRISV32F_INSN_ASRR_D_R; goto extract_sfmt_and_d_r;
483 case 123 : itype = CRISV32F_INSN_XOR; goto extract_sfmt_dstep;
484 case 124 : itype = CRISV32F_INSN_LSRR_B_R; goto extract_sfmt_lsrr_b_r;
485 case 125 : itype = CRISV32F_INSN_LSRR_W_R; goto extract_sfmt_lsrr_b_r;
486 case 126 : itype = CRISV32F_INSN_LSRR_D_R; goto extract_sfmt_lsrr_d_r;
487 case 127 : itype = CRISV32F_INSN_MCP; goto extract_sfmt_mcp;
488 case 128 : itype = CRISV32F_INSN_ADDU_M_B_M; goto extract_sfmt_adds_m_b_m;
489 case 129 : itype = CRISV32F_INSN_ADDU_M_W_M; goto extract_sfmt_adds_m_w_m;
490 case 130 : itype = CRISV32F_INSN_ADDS_M_B_M; goto extract_sfmt_adds_m_b_m;
491 case 131 : itype = CRISV32F_INSN_ADDS_M_W_M; goto extract_sfmt_adds_m_w_m;
492 case 132 : itype = CRISV32F_INSN_MOVU_M_B_M; goto extract_sfmt_movs_m_b_m;
493 case 133 : itype = CRISV32F_INSN_MOVU_M_W_M; goto extract_sfmt_movs_m_w_m;
494 case 134 : itype = CRISV32F_INSN_MOVS_M_B_M; goto extract_sfmt_movs_m_b_m;
495 case 135 : itype = CRISV32F_INSN_MOVS_M_W_M; goto extract_sfmt_movs_m_w_m;
496 case 136 : itype = CRISV32F_INSN_SUBU_M_B_M; goto extract_sfmt_adds_m_b_m;
497 case 137 : itype = CRISV32F_INSN_SUBU_M_W_M; goto extract_sfmt_adds_m_w_m;
498 case 138 : itype = CRISV32F_INSN_SUBS_M_B_M; goto extract_sfmt_adds_m_b_m;
499 case 139 : itype = CRISV32F_INSN_SUBS_M_W_M; goto extract_sfmt_adds_m_w_m;
500 case 140 : itype = CRISV32F_INSN_CMPU_M_B_M; goto extract_sfmt_cmp_m_b_m;
501 case 141 : itype = CRISV32F_INSN_CMPU_M_W_M; goto extract_sfmt_cmp_m_w_m;
502 case 142 : itype = CRISV32F_INSN_CMPS_M_B_M; goto extract_sfmt_cmp_m_b_m;
503 case 143 : itype = CRISV32F_INSN_CMPS_M_W_M; goto extract_sfmt_cmp_m_w_m;
504 case 144 : itype = CRISV32F_INSN_MULU_B; goto extract_sfmt_muls_b;
505 case 145 : itype = CRISV32F_INSN_MULU_W; goto extract_sfmt_muls_b;
506 case 146 : itype = CRISV32F_INSN_MULU_D; goto extract_sfmt_muls_b;
507 case 147 :
508 {
509 unsigned int val = (((insn >> 12) & (15 << 0)));
510 switch (val)
511 {
512 case 2 :
513 if ((base_insn & 0xffff) == 0x2930)
514 { itype = CRISV32F_INSN_RFE; goto extract_sfmt_rfe; }
515 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
516 case 3 :
517 if ((base_insn & 0xffff) == 0x3930)
518 { itype = CRISV32F_INSN_SFE; goto extract_sfmt_sfe; }
519 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
520 case 4 :
521 if ((base_insn & 0xffff) == 0x4930)
522 { itype = CRISV32F_INSN_RFG; goto extract_sfmt_rfg; }
523 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
524 case 5 :
525 if ((base_insn & 0xffff) == 0x5930)
526 { itype = CRISV32F_INSN_RFN; goto extract_sfmt_rfn; }
527 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
528 case 14 : itype = CRISV32F_INSN_BREAK; goto extract_sfmt_break;
529 case 15 :
530 if ((base_insn & 0xffff) == 0xf930)
531 { itype = CRISV32F_INSN_HALT; goto extract_sfmt_halt; }
532 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
533 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
534 }
535 }
536 case 148 : itype = CRISV32F_INSN_ADDO_M_B_M; goto extract_sfmt_addo_m_b_m;
537 case 149 : itype = CRISV32F_INSN_ADDO_M_W_M; goto extract_sfmt_addo_m_w_m;
538 case 150 : itype = CRISV32F_INSN_ADDO_M_D_M; goto extract_sfmt_addo_m_d_m;
539 case 151 : itype = CRISV32F_INSN_LAPCQ; goto extract_sfmt_lapcq;
540 case 154 : itype = CRISV32F_INSN_ADDC_M; goto extract_sfmt_addc_m;
541 case 155 : itype = CRISV32F_INSN_JAS_R; goto extract_sfmt_jas_r;
542 case 159 :
543 if ((base_insn & 0xfff) == 0x9f0)
544 { itype = CRISV32F_INSN_JUMP_P; goto extract_sfmt_jump_p; }
545 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
546 case 160 : itype = CRISV32F_INSN_ADD_M_B_M; goto extract_sfmt_add_m_b_m;
547 case 161 : itype = CRISV32F_INSN_ADD_M_W_M; goto extract_sfmt_add_m_w_m;
548 case 162 : itype = CRISV32F_INSN_ADD_M_D_M; goto extract_sfmt_add_m_d_m;
549 case 163 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
550 case 164 : itype = CRISV32F_INSN_MOVE_M_B_M; goto extract_sfmt_move_m_b_m;
551 case 165 : itype = CRISV32F_INSN_MOVE_M_W_M; goto extract_sfmt_move_m_w_m;
552 case 166 : itype = CRISV32F_INSN_MOVE_M_D_M; goto extract_sfmt_move_m_d_m;
553 case 167 : /* fall through */
554 case 231 : itype = CRISV32F_INSN_MOVE_SPR_MV32; goto extract_sfmt_move_spr_mv32;
555 case 168 : itype = CRISV32F_INSN_SUB_M_B_M; goto extract_sfmt_add_m_b_m;
556 case 169 : itype = CRISV32F_INSN_SUB_M_W_M; goto extract_sfmt_add_m_w_m;
557 case 170 : itype = CRISV32F_INSN_SUB_M_D_M; goto extract_sfmt_add_m_d_m;
558 case 171 :
559 {
560 unsigned int val = (((insn >> 12) & (1 << 0)));
561 switch (val)
562 {
563 case 0 :
564 if ((base_insn & 0xfff0) == 0xab0)
565 { itype = CRISV32F_INSN_FIDXD; goto extract_sfmt_fidxi; }
566 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
567 case 1 :
568 if ((base_insn & 0xfff0) == 0x1ab0)
569 { itype = CRISV32F_INSN_FTAGD; goto extract_sfmt_fidxi; }
570 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
571 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
572 }
573 }
574 case 172 : itype = CRISV32F_INSN_CMP_M_B_M; goto extract_sfmt_cmp_m_b_m;
575 case 173 : itype = CRISV32F_INSN_CMP_M_W_M; goto extract_sfmt_cmp_m_w_m;
576 case 174 : itype = CRISV32F_INSN_CMP_M_D_M; goto extract_sfmt_cmp_m_d_m;
577 case 176 : itype = CRISV32F_INSN_AND_M_B_M; goto extract_sfmt_and_m_b_m;
578 case 177 : itype = CRISV32F_INSN_AND_M_W_M; goto extract_sfmt_and_m_w_m;
579 case 178 : itype = CRISV32F_INSN_AND_M_D_M; goto extract_sfmt_and_m_d_m;
580 case 179 : itype = CRISV32F_INSN_JASC_R; goto extract_sfmt_jasc_r;
581 case 180 : itype = CRISV32F_INSN_OR_M_B_M; goto extract_sfmt_and_m_b_m;
582 case 181 : itype = CRISV32F_INSN_OR_M_W_M; goto extract_sfmt_and_m_w_m;
583 case 182 : itype = CRISV32F_INSN_OR_M_D_M; goto extract_sfmt_and_m_d_m;
584 case 183 : itype = CRISV32F_INSN_MOVE_R_SS; goto extract_sfmt_move_r_ss;
585 case 184 : /* fall through */
586 case 248 :
587 if ((base_insn & 0xfbf0) == 0xb80)
588 { itype = CRISV32F_INSN_TEST_M_B_M; goto extract_sfmt_test_m_b_m; }
589 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
590 case 185 : /* fall through */
591 case 249 :
592 if ((base_insn & 0xfbf0) == 0xb90)
593 { itype = CRISV32F_INSN_TEST_M_W_M; goto extract_sfmt_test_m_w_m; }
594 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
595 case 186 : /* fall through */
596 case 250 :
597 if ((base_insn & 0xfbf0) == 0xba0)
598 { itype = CRISV32F_INSN_TEST_M_D_M; goto extract_sfmt_test_m_d_m; }
599 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
600 case 187 : /* fall through */
601 case 251 : itype = CRISV32F_INSN_MOVEM_M_R_V32; goto extract_sfmt_movem_m_r_v32;
602 case 188 : /* fall through */
603 case 252 : itype = CRISV32F_INSN_MOVE_R_M_B_M; goto extract_sfmt_move_r_m_b_m;
604 case 189 : /* fall through */
605 case 253 : itype = CRISV32F_INSN_MOVE_R_M_W_M; goto extract_sfmt_move_r_m_w_m;
606 case 190 : /* fall through */
607 case 254 : itype = CRISV32F_INSN_MOVE_R_M_D_M; goto extract_sfmt_move_r_m_d_m;
608 case 191 : /* fall through */
609 case 255 : itype = CRISV32F_INSN_MOVEM_R_M_V32; goto extract_sfmt_movem_r_m_v32;
610 case 192 :
611 {
612 unsigned int val = (((insn >> 0) & (15 << 0)));
613 switch (val)
614 {
615 case 0 : /* fall through */
616 case 1 : /* fall through */
617 case 2 : /* fall through */
618 case 3 : /* fall through */
619 case 4 : /* fall through */
620 case 5 : /* fall through */
621 case 6 : /* fall through */
622 case 7 : /* fall through */
623 case 8 : /* fall through */
624 case 9 : /* fall through */
625 case 10 : /* fall through */
626 case 11 : /* fall through */
627 case 12 : /* fall through */
628 case 13 : /* fall through */
629 case 14 : itype = CRISV32F_INSN_ADDU_M_B_M; goto extract_sfmt_adds_m_b_m;
630 case 15 : itype = CRISV32F_INSN_ADDUCBR; goto extract_sfmt_addscbr;
631 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
632 }
633 }
634 case 193 :
635 {
636 unsigned int val = (((insn >> 0) & (15 << 0)));
637 switch (val)
638 {
639 case 0 : /* fall through */
640 case 1 : /* fall through */
641 case 2 : /* fall through */
642 case 3 : /* fall through */
643 case 4 : /* fall through */
644 case 5 : /* fall through */
645 case 6 : /* fall through */
646 case 7 : /* fall through */
647 case 8 : /* fall through */
648 case 9 : /* fall through */
649 case 10 : /* fall through */
650 case 11 : /* fall through */
651 case 12 : /* fall through */
652 case 13 : /* fall through */
653 case 14 : itype = CRISV32F_INSN_ADDU_M_W_M; goto extract_sfmt_adds_m_w_m;
654 case 15 : itype = CRISV32F_INSN_ADDUCWR; goto extract_sfmt_addscwr;
655 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
656 }
657 }
658 case 194 :
659 {
660 unsigned int val = (((insn >> 0) & (15 << 0)));
661 switch (val)
662 {
663 case 0 : /* fall through */
664 case 1 : /* fall through */
665 case 2 : /* fall through */
666 case 3 : /* fall through */
667 case 4 : /* fall through */
668 case 5 : /* fall through */
669 case 6 : /* fall through */
670 case 7 : /* fall through */
671 case 8 : /* fall through */
672 case 9 : /* fall through */
673 case 10 : /* fall through */
674 case 11 : /* fall through */
675 case 12 : /* fall through */
676 case 13 : /* fall through */
677 case 14 : itype = CRISV32F_INSN_ADDS_M_B_M; goto extract_sfmt_adds_m_b_m;
678 case 15 : itype = CRISV32F_INSN_ADDSCBR; goto extract_sfmt_addscbr;
679 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
680 }
681 }
682 case 195 :
683 {
684 unsigned int val = (((insn >> 0) & (15 << 0)));
685 switch (val)
686 {
687 case 0 : /* fall through */
688 case 1 : /* fall through */
689 case 2 : /* fall through */
690 case 3 : /* fall through */
691 case 4 : /* fall through */
692 case 5 : /* fall through */
693 case 6 : /* fall through */
694 case 7 : /* fall through */
695 case 8 : /* fall through */
696 case 9 : /* fall through */
697 case 10 : /* fall through */
698 case 11 : /* fall through */
699 case 12 : /* fall through */
700 case 13 : /* fall through */
701 case 14 : itype = CRISV32F_INSN_ADDS_M_W_M; goto extract_sfmt_adds_m_w_m;
702 case 15 : itype = CRISV32F_INSN_ADDSCWR; goto extract_sfmt_addscwr;
703 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
704 }
705 }
706 case 196 :
707 {
708 unsigned int val = (((insn >> 0) & (15 << 0)));
709 switch (val)
710 {
711 case 0 : /* fall through */
712 case 1 : /* fall through */
713 case 2 : /* fall through */
714 case 3 : /* fall through */
715 case 4 : /* fall through */
716 case 5 : /* fall through */
717 case 6 : /* fall through */
718 case 7 : /* fall through */
719 case 8 : /* fall through */
720 case 9 : /* fall through */
721 case 10 : /* fall through */
722 case 11 : /* fall through */
723 case 12 : /* fall through */
724 case 13 : /* fall through */
725 case 14 : itype = CRISV32F_INSN_MOVU_M_B_M; goto extract_sfmt_movs_m_b_m;
726 case 15 : itype = CRISV32F_INSN_MOVUCBR; goto extract_sfmt_movucbr;
727 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
728 }
729 }
730 case 197 :
731 {
732 unsigned int val = (((insn >> 0) & (15 << 0)));
733 switch (val)
734 {
735 case 0 : /* fall through */
736 case 1 : /* fall through */
737 case 2 : /* fall through */
738 case 3 : /* fall through */
739 case 4 : /* fall through */
740 case 5 : /* fall through */
741 case 6 : /* fall through */
742 case 7 : /* fall through */
743 case 8 : /* fall through */
744 case 9 : /* fall through */
745 case 10 : /* fall through */
746 case 11 : /* fall through */
747 case 12 : /* fall through */
748 case 13 : /* fall through */
749 case 14 : itype = CRISV32F_INSN_MOVU_M_W_M; goto extract_sfmt_movs_m_w_m;
750 case 15 : itype = CRISV32F_INSN_MOVUCWR; goto extract_sfmt_movucwr;
751 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
752 }
753 }
754 case 198 :
755 {
756 unsigned int val = (((insn >> 0) & (15 << 0)));
757 switch (val)
758 {
759 case 0 : /* fall through */
760 case 1 : /* fall through */
761 case 2 : /* fall through */
762 case 3 : /* fall through */
763 case 4 : /* fall through */
764 case 5 : /* fall through */
765 case 6 : /* fall through */
766 case 7 : /* fall through */
767 case 8 : /* fall through */
768 case 9 : /* fall through */
769 case 10 : /* fall through */
770 case 11 : /* fall through */
771 case 12 : /* fall through */
772 case 13 : /* fall through */
773 case 14 : itype = CRISV32F_INSN_MOVS_M_B_M; goto extract_sfmt_movs_m_b_m;
774 case 15 : itype = CRISV32F_INSN_MOVSCBR; goto extract_sfmt_movscbr;
775 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
776 }
777 }
778 case 199 :
779 {
780 unsigned int val = (((insn >> 0) & (15 << 0)));
781 switch (val)
782 {
783 case 0 : /* fall through */
784 case 1 : /* fall through */
785 case 2 : /* fall through */
786 case 3 : /* fall through */
787 case 4 : /* fall through */
788 case 5 : /* fall through */
789 case 6 : /* fall through */
790 case 7 : /* fall through */
791 case 8 : /* fall through */
792 case 9 : /* fall through */
793 case 10 : /* fall through */
794 case 11 : /* fall through */
795 case 12 : /* fall through */
796 case 13 : /* fall through */
797 case 14 : itype = CRISV32F_INSN_MOVS_M_W_M; goto extract_sfmt_movs_m_w_m;
798 case 15 : itype = CRISV32F_INSN_MOVSCWR; goto extract_sfmt_movscwr;
799 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
800 }
801 }
802 case 200 :
803 {
804 unsigned int val = (((insn >> 0) & (15 << 0)));
805 switch (val)
806 {
807 case 0 : /* fall through */
808 case 1 : /* fall through */
809 case 2 : /* fall through */
810 case 3 : /* fall through */
811 case 4 : /* fall through */
812 case 5 : /* fall through */
813 case 6 : /* fall through */
814 case 7 : /* fall through */
815 case 8 : /* fall through */
816 case 9 : /* fall through */
817 case 10 : /* fall through */
818 case 11 : /* fall through */
819 case 12 : /* fall through */
820 case 13 : /* fall through */
821 case 14 : itype = CRISV32F_INSN_SUBU_M_B_M; goto extract_sfmt_adds_m_b_m;
822 case 15 : itype = CRISV32F_INSN_SUBUCBR; goto extract_sfmt_addscbr;
823 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
824 }
825 }
826 case 201 :
827 {
828 unsigned int val = (((insn >> 0) & (15 << 0)));
829 switch (val)
830 {
831 case 0 : /* fall through */
832 case 1 : /* fall through */
833 case 2 : /* fall through */
834 case 3 : /* fall through */
835 case 4 : /* fall through */
836 case 5 : /* fall through */
837 case 6 : /* fall through */
838 case 7 : /* fall through */
839 case 8 : /* fall through */
840 case 9 : /* fall through */
841 case 10 : /* fall through */
842 case 11 : /* fall through */
843 case 12 : /* fall through */
844 case 13 : /* fall through */
845 case 14 : itype = CRISV32F_INSN_SUBU_M_W_M; goto extract_sfmt_adds_m_w_m;
846 case 15 : itype = CRISV32F_INSN_SUBUCWR; goto extract_sfmt_addscwr;
847 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
848 }
849 }
850 case 202 :
851 {
852 unsigned int val = (((insn >> 0) & (15 << 0)));
853 switch (val)
854 {
855 case 0 : /* fall through */
856 case 1 : /* fall through */
857 case 2 : /* fall through */
858 case 3 : /* fall through */
859 case 4 : /* fall through */
860 case 5 : /* fall through */
861 case 6 : /* fall through */
862 case 7 : /* fall through */
863 case 8 : /* fall through */
864 case 9 : /* fall through */
865 case 10 : /* fall through */
866 case 11 : /* fall through */
867 case 12 : /* fall through */
868 case 13 : /* fall through */
869 case 14 : itype = CRISV32F_INSN_SUBS_M_B_M; goto extract_sfmt_adds_m_b_m;
870 case 15 : itype = CRISV32F_INSN_SUBSCBR; goto extract_sfmt_addscbr;
871 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
872 }
873 }
874 case 203 :
875 {
876 unsigned int val = (((insn >> 0) & (15 << 0)));
877 switch (val)
878 {
879 case 0 : /* fall through */
880 case 1 : /* fall through */
881 case 2 : /* fall through */
882 case 3 : /* fall through */
883 case 4 : /* fall through */
884 case 5 : /* fall through */
885 case 6 : /* fall through */
886 case 7 : /* fall through */
887 case 8 : /* fall through */
888 case 9 : /* fall through */
889 case 10 : /* fall through */
890 case 11 : /* fall through */
891 case 12 : /* fall through */
892 case 13 : /* fall through */
893 case 14 : itype = CRISV32F_INSN_SUBS_M_W_M; goto extract_sfmt_adds_m_w_m;
894 case 15 : itype = CRISV32F_INSN_SUBSCWR; goto extract_sfmt_addscwr;
895 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
896 }
897 }
898 case 204 :
899 {
900 unsigned int val = (((insn >> 0) & (15 << 0)));
901 switch (val)
902 {
903 case 0 : /* fall through */
904 case 1 : /* fall through */
905 case 2 : /* fall through */
906 case 3 : /* fall through */
907 case 4 : /* fall through */
908 case 5 : /* fall through */
909 case 6 : /* fall through */
910 case 7 : /* fall through */
911 case 8 : /* fall through */
912 case 9 : /* fall through */
913 case 10 : /* fall through */
914 case 11 : /* fall through */
915 case 12 : /* fall through */
916 case 13 : /* fall through */
917 case 14 : itype = CRISV32F_INSN_CMPU_M_B_M; goto extract_sfmt_cmp_m_b_m;
918 case 15 : itype = CRISV32F_INSN_CMPUCBR; goto extract_sfmt_cmpucbr;
919 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
920 }
921 }
922 case 205 :
923 {
924 unsigned int val = (((insn >> 0) & (15 << 0)));
925 switch (val)
926 {
927 case 0 : /* fall through */
928 case 1 : /* fall through */
929 case 2 : /* fall through */
930 case 3 : /* fall through */
931 case 4 : /* fall through */
932 case 5 : /* fall through */
933 case 6 : /* fall through */
934 case 7 : /* fall through */
935 case 8 : /* fall through */
936 case 9 : /* fall through */
937 case 10 : /* fall through */
938 case 11 : /* fall through */
939 case 12 : /* fall through */
940 case 13 : /* fall through */
941 case 14 : itype = CRISV32F_INSN_CMPU_M_W_M; goto extract_sfmt_cmp_m_w_m;
942 case 15 : itype = CRISV32F_INSN_CMPUCWR; goto extract_sfmt_cmpucwr;
943 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
944 }
945 }
946 case 206 :
947 {
948 unsigned int val = (((insn >> 0) & (15 << 0)));
949 switch (val)
950 {
951 case 0 : /* fall through */
952 case 1 : /* fall through */
953 case 2 : /* fall through */
954 case 3 : /* fall through */
955 case 4 : /* fall through */
956 case 5 : /* fall through */
957 case 6 : /* fall through */
958 case 7 : /* fall through */
959 case 8 : /* fall through */
960 case 9 : /* fall through */
961 case 10 : /* fall through */
962 case 11 : /* fall through */
963 case 12 : /* fall through */
964 case 13 : /* fall through */
965 case 14 : itype = CRISV32F_INSN_CMPS_M_B_M; goto extract_sfmt_cmp_m_b_m;
966 case 15 : itype = CRISV32F_INSN_CMPSCBR; goto extract_sfmt_cmpcbr;
967 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
968 }
969 }
970 case 207 :
971 {
972 unsigned int val = (((insn >> 0) & (15 << 0)));
973 switch (val)
974 {
975 case 0 : /* fall through */
976 case 1 : /* fall through */
977 case 2 : /* fall through */
978 case 3 : /* fall through */
979 case 4 : /* fall through */
980 case 5 : /* fall through */
981 case 6 : /* fall through */
982 case 7 : /* fall through */
983 case 8 : /* fall through */
984 case 9 : /* fall through */
985 case 10 : /* fall through */
986 case 11 : /* fall through */
987 case 12 : /* fall through */
988 case 13 : /* fall through */
989 case 14 : itype = CRISV32F_INSN_CMPS_M_W_M; goto extract_sfmt_cmp_m_w_m;
990 case 15 : itype = CRISV32F_INSN_CMPSCWR; goto extract_sfmt_cmpcwr;
991 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
992 }
993 }
994 case 208 : itype = CRISV32F_INSN_MULS_B; goto extract_sfmt_muls_b;
995 case 209 : itype = CRISV32F_INSN_MULS_W; goto extract_sfmt_muls_b;
996 case 210 : itype = CRISV32F_INSN_MULS_D; goto extract_sfmt_muls_b;
997 case 211 :
998 {
999 unsigned int val = (((insn >> 12) & (1 << 0)));
1000 switch (val)
1001 {
1002 case 0 :
1003 if ((base_insn & 0xfff0) == 0xd30)
1004 { itype = CRISV32F_INSN_FIDXI; goto extract_sfmt_fidxi; }
1005 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1006 case 1 :
1007 if ((base_insn & 0xfff0) == 0x1d30)
1008 { itype = CRISV32F_INSN_FTAGI; goto extract_sfmt_fidxi; }
1009 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1010 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1011 }
1012 }
1013 case 212 :
1014 {
1015 unsigned int val = (((insn >> 0) & (15 << 0)));
1016 switch (val)
1017 {
1018 case 0 : /* fall through */
1019 case 1 : /* fall through */
1020 case 2 : /* fall through */
1021 case 3 : /* fall through */
1022 case 4 : /* fall through */
1023 case 5 : /* fall through */
1024 case 6 : /* fall through */
1025 case 7 : /* fall through */
1026 case 8 : /* fall through */
1027 case 9 : /* fall through */
1028 case 10 : /* fall through */
1029 case 11 : /* fall through */
1030 case 12 : /* fall through */
1031 case 13 : /* fall through */
1032 case 14 : itype = CRISV32F_INSN_ADDO_M_B_M; goto extract_sfmt_addo_m_b_m;
1033 case 15 : itype = CRISV32F_INSN_ADDO_CB; goto extract_sfmt_addo_cb;
1034 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1035 }
1036 }
1037 case 213 :
1038 {
1039 unsigned int val = (((insn >> 0) & (15 << 0)));
1040 switch (val)
1041 {
1042 case 0 : /* fall through */
1043 case 1 : /* fall through */
1044 case 2 : /* fall through */
1045 case 3 : /* fall through */
1046 case 4 : /* fall through */
1047 case 5 : /* fall through */
1048 case 6 : /* fall through */
1049 case 7 : /* fall through */
1050 case 8 : /* fall through */
1051 case 9 : /* fall through */
1052 case 10 : /* fall through */
1053 case 11 : /* fall through */
1054 case 12 : /* fall through */
1055 case 13 : /* fall through */
1056 case 14 : itype = CRISV32F_INSN_ADDO_M_W_M; goto extract_sfmt_addo_m_w_m;
1057 case 15 : itype = CRISV32F_INSN_ADDO_CW; goto extract_sfmt_addo_cw;
1058 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1059 }
1060 }
1061 case 214 :
1062 {
1063 unsigned int val = (((insn >> 0) & (15 << 0)));
1064 switch (val)
1065 {
1066 case 0 : /* fall through */
1067 case 1 : /* fall through */
1068 case 2 : /* fall through */
1069 case 3 : /* fall through */
1070 case 4 : /* fall through */
1071 case 5 : /* fall through */
1072 case 6 : /* fall through */
1073 case 7 : /* fall through */
1074 case 8 : /* fall through */
1075 case 9 : /* fall through */
1076 case 10 : /* fall through */
1077 case 11 : /* fall through */
1078 case 12 : /* fall through */
1079 case 13 : /* fall through */
1080 case 14 : itype = CRISV32F_INSN_ADDO_M_D_M; goto extract_sfmt_addo_m_d_m;
1081 case 15 : itype = CRISV32F_INSN_ADDO_CD; goto extract_sfmt_addo_cd;
1082 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1083 }
1084 }
1085 case 215 :
1086 if ((base_insn & 0xfff) == 0xd7f)
1087 { itype = CRISV32F_INSN_LAPC_D; goto extract_sfmt_lapc_d; }
1088 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1089 case 218 :
1090 {
1091 unsigned int val = (((insn >> 0) & (15 << 0)));
1092 switch (val)
1093 {
1094 case 0 : /* fall through */
1095 case 1 : /* fall through */
1096 case 2 : /* fall through */
1097 case 3 : /* fall through */
1098 case 4 : /* fall through */
1099 case 5 : /* fall through */
1100 case 6 : /* fall through */
1101 case 7 : /* fall through */
1102 case 8 : /* fall through */
1103 case 9 : /* fall through */
1104 case 10 : /* fall through */
1105 case 11 : /* fall through */
1106 case 12 : /* fall through */
1107 case 13 : /* fall through */
1108 case 14 : itype = CRISV32F_INSN_ADDC_M; goto extract_sfmt_addc_m;
1109 case 15 : itype = CRISV32F_INSN_ADDC_C; goto extract_sfmt_addcdr;
1110 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1111 }
1112 }
1113 case 219 :
1114 if ((base_insn & 0xfff) == 0xdbf)
1115 { itype = CRISV32F_INSN_JAS_C; goto extract_sfmt_jas_c; }
1116 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1117 case 220 :
1118 if ((base_insn & 0xfff) == 0xdcf)
1119 { itype = CRISV32F_INSN_BOUND_CB; goto extract_sfmt_bound_cb; }
1120 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1121 case 221 :
1122 if ((base_insn & 0xfff) == 0xddf)
1123 { itype = CRISV32F_INSN_BOUND_CW; goto extract_sfmt_bound_cw; }
1124 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1125 case 222 :
1126 if ((base_insn & 0xfff) == 0xdef)
1127 { itype = CRISV32F_INSN_BOUND_CD; goto extract_sfmt_bound_cd; }
1128 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1129 case 223 :
1130 {
1131 unsigned int val = (((insn >> 12) & (15 << 0)));
1132 switch (val)
1133 {
1134 case 0 : /* fall through */
1135 case 1 : /* fall through */
1136 case 2 : /* fall through */
1137 case 3 : /* fall through */
1138 case 4 : /* fall through */
1139 case 5 : /* fall through */
1140 case 6 : /* fall through */
1141 case 7 : /* fall through */
1142 case 8 : /* fall through */
1143 case 9 : /* fall through */
1144 case 10 : /* fall through */
1145 case 11 : /* fall through */
1146 case 12 : /* fall through */
1147 case 13 : /* fall through */
1148 case 15 :
1149 if ((base_insn & 0xfff) == 0xdff)
1150 { itype = CRISV32F_INSN_BCC_W; goto extract_sfmt_bcc_w; }
1151 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1152 case 14 :
1153 if ((base_insn & 0xffff) == 0xedff)
1154 { itype = CRISV32F_INSN_BA_W; goto extract_sfmt_ba_w; }
1155 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1156 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1157 }
1158 }
1159 case 224 :
1160 {
1161 unsigned int val = (((insn >> 0) & (15 << 0)));
1162 switch (val)
1163 {
1164 case 0 : /* fall through */
1165 case 1 : /* fall through */
1166 case 2 : /* fall through */
1167 case 3 : /* fall through */
1168 case 4 : /* fall through */
1169 case 5 : /* fall through */
1170 case 6 : /* fall through */
1171 case 7 : /* fall through */
1172 case 8 : /* fall through */
1173 case 9 : /* fall through */
1174 case 10 : /* fall through */
1175 case 11 : /* fall through */
1176 case 12 : /* fall through */
1177 case 13 : /* fall through */
1178 case 14 : itype = CRISV32F_INSN_ADD_M_B_M; goto extract_sfmt_add_m_b_m;
1179 case 15 : itype = CRISV32F_INSN_ADDCBR; goto extract_sfmt_addcbr;
1180 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1181 }
1182 }
1183 case 225 :
1184 {
1185 unsigned int val = (((insn >> 0) & (15 << 0)));
1186 switch (val)
1187 {
1188 case 0 : /* fall through */
1189 case 1 : /* fall through */
1190 case 2 : /* fall through */
1191 case 3 : /* fall through */
1192 case 4 : /* fall through */
1193 case 5 : /* fall through */
1194 case 6 : /* fall through */
1195 case 7 : /* fall through */
1196 case 8 : /* fall through */
1197 case 9 : /* fall through */
1198 case 10 : /* fall through */
1199 case 11 : /* fall through */
1200 case 12 : /* fall through */
1201 case 13 : /* fall through */
1202 case 14 : itype = CRISV32F_INSN_ADD_M_W_M; goto extract_sfmt_add_m_w_m;
1203 case 15 : itype = CRISV32F_INSN_ADDCWR; goto extract_sfmt_addcwr;
1204 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1205 }
1206 }
1207 case 226 :
1208 {
1209 unsigned int val = (((insn >> 0) & (15 << 0)));
1210 switch (val)
1211 {
1212 case 0 : /* fall through */
1213 case 1 : /* fall through */
1214 case 2 : /* fall through */
1215 case 3 : /* fall through */
1216 case 4 : /* fall through */
1217 case 5 : /* fall through */
1218 case 6 : /* fall through */
1219 case 7 : /* fall through */
1220 case 8 : /* fall through */
1221 case 9 : /* fall through */
1222 case 10 : /* fall through */
1223 case 11 : /* fall through */
1224 case 12 : /* fall through */
1225 case 13 : /* fall through */
1226 case 14 : itype = CRISV32F_INSN_ADD_M_D_M; goto extract_sfmt_add_m_d_m;
1227 case 15 : itype = CRISV32F_INSN_ADDCDR; goto extract_sfmt_addcdr;
1228 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1229 }
1230 }
1231 case 227 :
1232 {
1233 unsigned int val = (((insn >> 12) & (15 << 0)));
1234 switch (val)
1235 {
1236 case 0 : /* fall through */
1237 case 1 : /* fall through */
1238 case 4 : /* fall through */
1239 case 8 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1240 case 2 :
1241 {
1242 unsigned int val = (((insn >> 0) & (15 << 0)));
1243 switch (val)
1244 {
1245 case 0 : /* fall through */
1246 case 1 : /* fall through */
1247 case 2 : /* fall through */
1248 case 3 : /* fall through */
1249 case 4 : /* fall through */
1250 case 5 : /* fall through */
1251 case 6 : /* fall through */
1252 case 7 : /* fall through */
1253 case 8 : /* fall through */
1254 case 9 : /* fall through */
1255 case 10 : /* fall through */
1256 case 11 : /* fall through */
1257 case 12 : /* fall through */
1258 case 13 : /* fall through */
1259 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1260 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P2; goto extract_sfmt_move_c_sprv32_p2;
1261 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1262 }
1263 }
1264 case 3 :
1265 {
1266 unsigned int val = (((insn >> 0) & (15 << 0)));
1267 switch (val)
1268 {
1269 case 0 : /* fall through */
1270 case 1 : /* fall through */
1271 case 2 : /* fall through */
1272 case 3 : /* fall through */
1273 case 4 : /* fall through */
1274 case 5 : /* fall through */
1275 case 6 : /* fall through */
1276 case 7 : /* fall through */
1277 case 8 : /* fall through */
1278 case 9 : /* fall through */
1279 case 10 : /* fall through */
1280 case 11 : /* fall through */
1281 case 12 : /* fall through */
1282 case 13 : /* fall through */
1283 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1284 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P3; goto extract_sfmt_move_c_sprv32_p2;
1285 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1286 }
1287 }
1288 case 5 :
1289 {
1290 unsigned int val = (((insn >> 0) & (15 << 0)));
1291 switch (val)
1292 {
1293 case 0 : /* fall through */
1294 case 1 : /* fall through */
1295 case 2 : /* fall through */
1296 case 3 : /* fall through */
1297 case 4 : /* fall through */
1298 case 5 : /* fall through */
1299 case 6 : /* fall through */
1300 case 7 : /* fall through */
1301 case 8 : /* fall through */
1302 case 9 : /* fall through */
1303 case 10 : /* fall through */
1304 case 11 : /* fall through */
1305 case 12 : /* fall through */
1306 case 13 : /* fall through */
1307 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1308 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P5; goto extract_sfmt_move_c_sprv32_p2;
1309 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1310 }
1311 }
1312 case 6 :
1313 {
1314 unsigned int val = (((insn >> 0) & (15 << 0)));
1315 switch (val)
1316 {
1317 case 0 : /* fall through */
1318 case 1 : /* fall through */
1319 case 2 : /* fall through */
1320 case 3 : /* fall through */
1321 case 4 : /* fall through */
1322 case 5 : /* fall through */
1323 case 6 : /* fall through */
1324 case 7 : /* fall through */
1325 case 8 : /* fall through */
1326 case 9 : /* fall through */
1327 case 10 : /* fall through */
1328 case 11 : /* fall through */
1329 case 12 : /* fall through */
1330 case 13 : /* fall through */
1331 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1332 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P6; goto extract_sfmt_move_c_sprv32_p2;
1333 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1334 }
1335 }
1336 case 7 :
1337 {
1338 unsigned int val = (((insn >> 0) & (15 << 0)));
1339 switch (val)
1340 {
1341 case 0 : /* fall through */
1342 case 1 : /* fall through */
1343 case 2 : /* fall through */
1344 case 3 : /* fall through */
1345 case 4 : /* fall through */
1346 case 5 : /* fall through */
1347 case 6 : /* fall through */
1348 case 7 : /* fall through */
1349 case 8 : /* fall through */
1350 case 9 : /* fall through */
1351 case 10 : /* fall through */
1352 case 11 : /* fall through */
1353 case 12 : /* fall through */
1354 case 13 : /* fall through */
1355 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1356 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P7; goto extract_sfmt_move_c_sprv32_p2;
1357 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1358 }
1359 }
1360 case 9 :
1361 {
1362 unsigned int val = (((insn >> 0) & (15 << 0)));
1363 switch (val)
1364 {
1365 case 0 : /* fall through */
1366 case 1 : /* fall through */
1367 case 2 : /* fall through */
1368 case 3 : /* fall through */
1369 case 4 : /* fall through */
1370 case 5 : /* fall through */
1371 case 6 : /* fall through */
1372 case 7 : /* fall through */
1373 case 8 : /* fall through */
1374 case 9 : /* fall through */
1375 case 10 : /* fall through */
1376 case 11 : /* fall through */
1377 case 12 : /* fall through */
1378 case 13 : /* fall through */
1379 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1380 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P9; goto extract_sfmt_move_c_sprv32_p2;
1381 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1382 }
1383 }
1384 case 10 :
1385 {
1386 unsigned int val = (((insn >> 0) & (15 << 0)));
1387 switch (val)
1388 {
1389 case 0 : /* fall through */
1390 case 1 : /* fall through */
1391 case 2 : /* fall through */
1392 case 3 : /* fall through */
1393 case 4 : /* fall through */
1394 case 5 : /* fall through */
1395 case 6 : /* fall through */
1396 case 7 : /* fall through */
1397 case 8 : /* fall through */
1398 case 9 : /* fall through */
1399 case 10 : /* fall through */
1400 case 11 : /* fall through */
1401 case 12 : /* fall through */
1402 case 13 : /* fall through */
1403 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1404 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P10; goto extract_sfmt_move_c_sprv32_p2;
1405 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1406 }
1407 }
1408 case 11 :
1409 {
1410 unsigned int val = (((insn >> 0) & (15 << 0)));
1411 switch (val)
1412 {
1413 case 0 : /* fall through */
1414 case 1 : /* fall through */
1415 case 2 : /* fall through */
1416 case 3 : /* fall through */
1417 case 4 : /* fall through */
1418 case 5 : /* fall through */
1419 case 6 : /* fall through */
1420 case 7 : /* fall through */
1421 case 8 : /* fall through */
1422 case 9 : /* fall through */
1423 case 10 : /* fall through */
1424 case 11 : /* fall through */
1425 case 12 : /* fall through */
1426 case 13 : /* fall through */
1427 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1428 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P11; goto extract_sfmt_move_c_sprv32_p2;
1429 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1430 }
1431 }
1432 case 12 :
1433 {
1434 unsigned int val = (((insn >> 0) & (15 << 0)));
1435 switch (val)
1436 {
1437 case 0 : /* fall through */
1438 case 1 : /* fall through */
1439 case 2 : /* fall through */
1440 case 3 : /* fall through */
1441 case 4 : /* fall through */
1442 case 5 : /* fall through */
1443 case 6 : /* fall through */
1444 case 7 : /* fall through */
1445 case 8 : /* fall through */
1446 case 9 : /* fall through */
1447 case 10 : /* fall through */
1448 case 11 : /* fall through */
1449 case 12 : /* fall through */
1450 case 13 : /* fall through */
1451 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1452 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P12; goto extract_sfmt_move_c_sprv32_p2;
1453 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1454 }
1455 }
1456 case 13 :
1457 {
1458 unsigned int val = (((insn >> 0) & (15 << 0)));
1459 switch (val)
1460 {
1461 case 0 : /* fall through */
1462 case 1 : /* fall through */
1463 case 2 : /* fall through */
1464 case 3 : /* fall through */
1465 case 4 : /* fall through */
1466 case 5 : /* fall through */
1467 case 6 : /* fall through */
1468 case 7 : /* fall through */
1469 case 8 : /* fall through */
1470 case 9 : /* fall through */
1471 case 10 : /* fall through */
1472 case 11 : /* fall through */
1473 case 12 : /* fall through */
1474 case 13 : /* fall through */
1475 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1476 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P13; goto extract_sfmt_move_c_sprv32_p2;
1477 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1478 }
1479 }
1480 case 14 :
1481 {
1482 unsigned int val = (((insn >> 0) & (15 << 0)));
1483 switch (val)
1484 {
1485 case 0 : /* fall through */
1486 case 1 : /* fall through */
1487 case 2 : /* fall through */
1488 case 3 : /* fall through */
1489 case 4 : /* fall through */
1490 case 5 : /* fall through */
1491 case 6 : /* fall through */
1492 case 7 : /* fall through */
1493 case 8 : /* fall through */
1494 case 9 : /* fall through */
1495 case 10 : /* fall through */
1496 case 11 : /* fall through */
1497 case 12 : /* fall through */
1498 case 13 : /* fall through */
1499 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1500 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P14; goto extract_sfmt_move_c_sprv32_p2;
1501 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1502 }
1503 }
1504 case 15 :
1505 {
1506 unsigned int val = (((insn >> 0) & (15 << 0)));
1507 switch (val)
1508 {
1509 case 0 : /* fall through */
1510 case 1 : /* fall through */
1511 case 2 : /* fall through */
1512 case 3 : /* fall through */
1513 case 4 : /* fall through */
1514 case 5 : /* fall through */
1515 case 6 : /* fall through */
1516 case 7 : /* fall through */
1517 case 8 : /* fall through */
1518 case 9 : /* fall through */
1519 case 10 : /* fall through */
1520 case 11 : /* fall through */
1521 case 12 : /* fall through */
1522 case 13 : /* fall through */
1523 case 14 : itype = CRISV32F_INSN_MOVE_M_SPRV32; goto extract_sfmt_move_m_sprv32;
1524 case 15 : itype = CRISV32F_INSN_MOVE_C_SPRV32_P15; goto extract_sfmt_move_c_sprv32_p2;
1525 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1526 }
1527 }
1528 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1529 }
1530 }
1531 case 228 :
1532 {
1533 unsigned int val = (((insn >> 0) & (15 << 0)));
1534 switch (val)
1535 {
1536 case 0 : /* fall through */
1537 case 1 : /* fall through */
1538 case 2 : /* fall through */
1539 case 3 : /* fall through */
1540 case 4 : /* fall through */
1541 case 5 : /* fall through */
1542 case 6 : /* fall through */
1543 case 7 : /* fall through */
1544 case 8 : /* fall through */
1545 case 9 : /* fall through */
1546 case 10 : /* fall through */
1547 case 11 : /* fall through */
1548 case 12 : /* fall through */
1549 case 13 : /* fall through */
1550 case 14 : itype = CRISV32F_INSN_MOVE_M_B_M; goto extract_sfmt_move_m_b_m;
1551 case 15 : itype = CRISV32F_INSN_MOVECBR; goto extract_sfmt_movecbr;
1552 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1553 }
1554 }
1555 case 229 :
1556 {
1557 unsigned int val = (((insn >> 0) & (15 << 0)));
1558 switch (val)
1559 {
1560 case 0 : /* fall through */
1561 case 1 : /* fall through */
1562 case 2 : /* fall through */
1563 case 3 : /* fall through */
1564 case 4 : /* fall through */
1565 case 5 : /* fall through */
1566 case 6 : /* fall through */
1567 case 7 : /* fall through */
1568 case 8 : /* fall through */
1569 case 9 : /* fall through */
1570 case 10 : /* fall through */
1571 case 11 : /* fall through */
1572 case 12 : /* fall through */
1573 case 13 : /* fall through */
1574 case 14 : itype = CRISV32F_INSN_MOVE_M_W_M; goto extract_sfmt_move_m_w_m;
1575 case 15 : itype = CRISV32F_INSN_MOVECWR; goto extract_sfmt_movecwr;
1576 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1577 }
1578 }
1579 case 230 :
1580 {
1581 unsigned int val = (((insn >> 0) & (15 << 0)));
1582 switch (val)
1583 {
1584 case 0 : /* fall through */
1585 case 1 : /* fall through */
1586 case 2 : /* fall through */
1587 case 3 : /* fall through */
1588 case 4 : /* fall through */
1589 case 5 : /* fall through */
1590 case 6 : /* fall through */
1591 case 7 : /* fall through */
1592 case 8 : /* fall through */
1593 case 9 : /* fall through */
1594 case 10 : /* fall through */
1595 case 11 : /* fall through */
1596 case 12 : /* fall through */
1597 case 13 : /* fall through */
1598 case 14 : itype = CRISV32F_INSN_MOVE_M_D_M; goto extract_sfmt_move_m_d_m;
1599 case 15 : itype = CRISV32F_INSN_MOVECDR; goto extract_sfmt_movecdr;
1600 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1601 }
1602 }
1603 case 232 :
1604 {
1605 unsigned int val = (((insn >> 0) & (15 << 0)));
1606 switch (val)
1607 {
1608 case 0 : /* fall through */
1609 case 1 : /* fall through */
1610 case 2 : /* fall through */
1611 case 3 : /* fall through */
1612 case 4 : /* fall through */
1613 case 5 : /* fall through */
1614 case 6 : /* fall through */
1615 case 7 : /* fall through */
1616 case 8 : /* fall through */
1617 case 9 : /* fall through */
1618 case 10 : /* fall through */
1619 case 11 : /* fall through */
1620 case 12 : /* fall through */
1621 case 13 : /* fall through */
1622 case 14 : itype = CRISV32F_INSN_SUB_M_B_M; goto extract_sfmt_add_m_b_m;
1623 case 15 : itype = CRISV32F_INSN_SUBCBR; goto extract_sfmt_addcbr;
1624 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1625 }
1626 }
1627 case 233 :
1628 {
1629 unsigned int val = (((insn >> 0) & (15 << 0)));
1630 switch (val)
1631 {
1632 case 0 : /* fall through */
1633 case 1 : /* fall through */
1634 case 2 : /* fall through */
1635 case 3 : /* fall through */
1636 case 4 : /* fall through */
1637 case 5 : /* fall through */
1638 case 6 : /* fall through */
1639 case 7 : /* fall through */
1640 case 8 : /* fall through */
1641 case 9 : /* fall through */
1642 case 10 : /* fall through */
1643 case 11 : /* fall through */
1644 case 12 : /* fall through */
1645 case 13 : /* fall through */
1646 case 14 : itype = CRISV32F_INSN_SUB_M_W_M; goto extract_sfmt_add_m_w_m;
1647 case 15 : itype = CRISV32F_INSN_SUBCWR; goto extract_sfmt_addcwr;
1648 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1649 }
1650 }
1651 case 234 :
1652 {
1653 unsigned int val = (((insn >> 0) & (15 << 0)));
1654 switch (val)
1655 {
1656 case 0 : /* fall through */
1657 case 1 : /* fall through */
1658 case 2 : /* fall through */
1659 case 3 : /* fall through */
1660 case 4 : /* fall through */
1661 case 5 : /* fall through */
1662 case 6 : /* fall through */
1663 case 7 : /* fall through */
1664 case 8 : /* fall through */
1665 case 9 : /* fall through */
1666 case 10 : /* fall through */
1667 case 11 : /* fall through */
1668 case 12 : /* fall through */
1669 case 13 : /* fall through */
1670 case 14 : itype = CRISV32F_INSN_SUB_M_D_M; goto extract_sfmt_add_m_d_m;
1671 case 15 : itype = CRISV32F_INSN_SUBCDR; goto extract_sfmt_addcdr;
1672 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1673 }
1674 }
1675 case 235 :
1676 if ((base_insn & 0xfff) == 0xebf)
1677 { itype = CRISV32F_INSN_BAS_C; goto extract_sfmt_bas_c; }
1678 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1679 case 236 :
1680 {
1681 unsigned int val = (((insn >> 0) & (15 << 0)));
1682 switch (val)
1683 {
1684 case 0 : /* fall through */
1685 case 1 : /* fall through */
1686 case 2 : /* fall through */
1687 case 3 : /* fall through */
1688 case 4 : /* fall through */
1689 case 5 : /* fall through */
1690 case 6 : /* fall through */
1691 case 7 : /* fall through */
1692 case 8 : /* fall through */
1693 case 9 : /* fall through */
1694 case 10 : /* fall through */
1695 case 11 : /* fall through */
1696 case 12 : /* fall through */
1697 case 13 : /* fall through */
1698 case 14 : itype = CRISV32F_INSN_CMP_M_B_M; goto extract_sfmt_cmp_m_b_m;
1699 case 15 : itype = CRISV32F_INSN_CMPCBR; goto extract_sfmt_cmpcbr;
1700 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1701 }
1702 }
1703 case 237 :
1704 {
1705 unsigned int val = (((insn >> 0) & (15 << 0)));
1706 switch (val)
1707 {
1708 case 0 : /* fall through */
1709 case 1 : /* fall through */
1710 case 2 : /* fall through */
1711 case 3 : /* fall through */
1712 case 4 : /* fall through */
1713 case 5 : /* fall through */
1714 case 6 : /* fall through */
1715 case 7 : /* fall through */
1716 case 8 : /* fall through */
1717 case 9 : /* fall through */
1718 case 10 : /* fall through */
1719 case 11 : /* fall through */
1720 case 12 : /* fall through */
1721 case 13 : /* fall through */
1722 case 14 : itype = CRISV32F_INSN_CMP_M_W_M; goto extract_sfmt_cmp_m_w_m;
1723 case 15 : itype = CRISV32F_INSN_CMPCWR; goto extract_sfmt_cmpcwr;
1724 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1725 }
1726 }
1727 case 238 :
1728 {
1729 unsigned int val = (((insn >> 0) & (15 << 0)));
1730 switch (val)
1731 {
1732 case 0 : /* fall through */
1733 case 1 : /* fall through */
1734 case 2 : /* fall through */
1735 case 3 : /* fall through */
1736 case 4 : /* fall through */
1737 case 5 : /* fall through */
1738 case 6 : /* fall through */
1739 case 7 : /* fall through */
1740 case 8 : /* fall through */
1741 case 9 : /* fall through */
1742 case 10 : /* fall through */
1743 case 11 : /* fall through */
1744 case 12 : /* fall through */
1745 case 13 : /* fall through */
1746 case 14 : itype = CRISV32F_INSN_CMP_M_D_M; goto extract_sfmt_cmp_m_d_m;
1747 case 15 : itype = CRISV32F_INSN_CMPCDR; goto extract_sfmt_cmpcdr;
1748 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1749 }
1750 }
1751 case 239 :
1752 if ((base_insn & 0xfff) == 0xeff)
1753 { itype = CRISV32F_INSN_BASC_C; goto extract_sfmt_bas_c; }
1754 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1755 case 240 :
1756 {
1757 unsigned int val = (((insn >> 0) & (15 << 0)));
1758 switch (val)
1759 {
1760 case 0 : /* fall through */
1761 case 1 : /* fall through */
1762 case 2 : /* fall through */
1763 case 3 : /* fall through */
1764 case 4 : /* fall through */
1765 case 5 : /* fall through */
1766 case 6 : /* fall through */
1767 case 7 : /* fall through */
1768 case 8 : /* fall through */
1769 case 9 : /* fall through */
1770 case 10 : /* fall through */
1771 case 11 : /* fall through */
1772 case 12 : /* fall through */
1773 case 13 : /* fall through */
1774 case 14 : itype = CRISV32F_INSN_AND_M_B_M; goto extract_sfmt_and_m_b_m;
1775 case 15 : itype = CRISV32F_INSN_ANDCBR; goto extract_sfmt_andcbr;
1776 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1777 }
1778 }
1779 case 241 :
1780 {
1781 unsigned int val = (((insn >> 0) & (15 << 0)));
1782 switch (val)
1783 {
1784 case 0 : /* fall through */
1785 case 1 : /* fall through */
1786 case 2 : /* fall through */
1787 case 3 : /* fall through */
1788 case 4 : /* fall through */
1789 case 5 : /* fall through */
1790 case 6 : /* fall through */
1791 case 7 : /* fall through */
1792 case 8 : /* fall through */
1793 case 9 : /* fall through */
1794 case 10 : /* fall through */
1795 case 11 : /* fall through */
1796 case 12 : /* fall through */
1797 case 13 : /* fall through */
1798 case 14 : itype = CRISV32F_INSN_AND_M_W_M; goto extract_sfmt_and_m_w_m;
1799 case 15 : itype = CRISV32F_INSN_ANDCWR; goto extract_sfmt_andcwr;
1800 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1801 }
1802 }
1803 case 242 :
1804 {
1805 unsigned int val = (((insn >> 0) & (15 << 0)));
1806 switch (val)
1807 {
1808 case 0 : /* fall through */
1809 case 1 : /* fall through */
1810 case 2 : /* fall through */
1811 case 3 : /* fall through */
1812 case 4 : /* fall through */
1813 case 5 : /* fall through */
1814 case 6 : /* fall through */
1815 case 7 : /* fall through */
1816 case 8 : /* fall through */
1817 case 9 : /* fall through */
1818 case 10 : /* fall through */
1819 case 11 : /* fall through */
1820 case 12 : /* fall through */
1821 case 13 : /* fall through */
1822 case 14 : itype = CRISV32F_INSN_AND_M_D_M; goto extract_sfmt_and_m_d_m;
1823 case 15 : itype = CRISV32F_INSN_ANDCDR; goto extract_sfmt_andcdr;
1824 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1825 }
1826 }
1827 case 243 :
1828 if ((base_insn & 0xfff) == 0xf3f)
1829 { itype = CRISV32F_INSN_JASC_C; goto extract_sfmt_jas_c; }
1830 itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1831 case 244 :
1832 {
1833 unsigned int val = (((insn >> 0) & (15 << 0)));
1834 switch (val)
1835 {
1836 case 0 : /* fall through */
1837 case 1 : /* fall through */
1838 case 2 : /* fall through */
1839 case 3 : /* fall through */
1840 case 4 : /* fall through */
1841 case 5 : /* fall through */
1842 case 6 : /* fall through */
1843 case 7 : /* fall through */
1844 case 8 : /* fall through */
1845 case 9 : /* fall through */
1846 case 10 : /* fall through */
1847 case 11 : /* fall through */
1848 case 12 : /* fall through */
1849 case 13 : /* fall through */
1850 case 14 : itype = CRISV32F_INSN_OR_M_B_M; goto extract_sfmt_and_m_b_m;
1851 case 15 : itype = CRISV32F_INSN_ORCBR; goto extract_sfmt_andcbr;
1852 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1853 }
1854 }
1855 case 245 :
1856 {
1857 unsigned int val = (((insn >> 0) & (15 << 0)));
1858 switch (val)
1859 {
1860 case 0 : /* fall through */
1861 case 1 : /* fall through */
1862 case 2 : /* fall through */
1863 case 3 : /* fall through */
1864 case 4 : /* fall through */
1865 case 5 : /* fall through */
1866 case 6 : /* fall through */
1867 case 7 : /* fall through */
1868 case 8 : /* fall through */
1869 case 9 : /* fall through */
1870 case 10 : /* fall through */
1871 case 11 : /* fall through */
1872 case 12 : /* fall through */
1873 case 13 : /* fall through */
1874 case 14 : itype = CRISV32F_INSN_OR_M_W_M; goto extract_sfmt_and_m_w_m;
1875 case 15 : itype = CRISV32F_INSN_ORCWR; goto extract_sfmt_andcwr;
1876 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1877 }
1878 }
1879 case 246 :
1880 {
1881 unsigned int val = (((insn >> 0) & (15 << 0)));
1882 switch (val)
1883 {
1884 case 0 : /* fall through */
1885 case 1 : /* fall through */
1886 case 2 : /* fall through */
1887 case 3 : /* fall through */
1888 case 4 : /* fall through */
1889 case 5 : /* fall through */
1890 case 6 : /* fall through */
1891 case 7 : /* fall through */
1892 case 8 : /* fall through */
1893 case 9 : /* fall through */
1894 case 10 : /* fall through */
1895 case 11 : /* fall through */
1896 case 12 : /* fall through */
1897 case 13 : /* fall through */
1898 case 14 : itype = CRISV32F_INSN_OR_M_D_M; goto extract_sfmt_and_m_d_m;
1899 case 15 : itype = CRISV32F_INSN_ORCDR; goto extract_sfmt_andcdr;
1900 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1901 }
1902 }
1903 case 247 : itype = CRISV32F_INSN_MOVE_SS_R; goto extract_sfmt_move_ss_r;
1904 default : itype = CRISV32F_INSN_X_INVALID; goto extract_sfmt_empty;
1905 }
1906 }
1907 }
1908
1909 /* The instruction has been decoded, now extract the fields. */
1910
1911 extract_sfmt_empty:
1912 {
1913 const IDESC *idesc = &crisv32f_insn_data[itype];
1914 #define FLD(f) abuf->fields.sfmt_empty.f
1915
1916
1917 /* Record the fields for the semantic handler. */
1918 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_empty", (char *) 0));
1919
1920 #undef FLD
1921 return idesc;
1922 }
1923
1924 extract_sfmt_move_b_r:
1925 {
1926 const IDESC *idesc = &crisv32f_insn_data[itype];
1927 CGEN_INSN_WORD insn = base_insn;
1928 #define FLD(f) abuf->fields.sfmt_addc_m.f
1929 UINT f_operand2;
1930 UINT f_operand1;
1931
1932 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
1933 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
1934
1935 /* Record the fields for the semantic handler. */
1936 FLD (f_operand1) = f_operand1;
1937 FLD (f_operand2) = f_operand2;
1938 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_b_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
1939
1940 #if WITH_PROFILE_MODEL_P
1941 /* Record the fields for profiling. */
1942 if (PROFILE_MODEL_P (current_cpu))
1943 {
1944 FLD (in_Rs) = f_operand1;
1945 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
1946 }
1947 #endif
1948 #undef FLD
1949 return idesc;
1950 }
1951
1952 extract_sfmt_move_d_r:
1953 {
1954 const IDESC *idesc = &crisv32f_insn_data[itype];
1955 CGEN_INSN_WORD insn = base_insn;
1956 #define FLD(f) abuf->fields.sfmt_addc_m.f
1957 UINT f_operand2;
1958 UINT f_operand1;
1959
1960 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
1961 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
1962
1963 /* Record the fields for the semantic handler. */
1964 FLD (f_operand1) = f_operand1;
1965 FLD (f_operand2) = f_operand2;
1966 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_d_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
1967
1968 #if WITH_PROFILE_MODEL_P
1969 /* Record the fields for profiling. */
1970 if (PROFILE_MODEL_P (current_cpu))
1971 {
1972 FLD (in_Rs) = f_operand1;
1973 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
1974 }
1975 #endif
1976 #undef FLD
1977 return idesc;
1978 }
1979
1980 extract_sfmt_moveq:
1981 {
1982 const IDESC *idesc = &crisv32f_insn_data[itype];
1983 CGEN_INSN_WORD insn = base_insn;
1984 #define FLD(f) abuf->fields.sfmt_moveq.f
1985 UINT f_operand2;
1986 INT f_s6;
1987
1988 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
1989 f_s6 = EXTRACT_LSB0_SINT (insn, 16, 5, 6);
1990
1991 /* Record the fields for the semantic handler. */
1992 FLD (f_s6) = f_s6;
1993 FLD (f_operand2) = f_operand2;
1994 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_moveq", "f_s6 0x%x", 'x', f_s6, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
1995
1996 #if WITH_PROFILE_MODEL_P
1997 /* Record the fields for profiling. */
1998 if (PROFILE_MODEL_P (current_cpu))
1999 {
2000 FLD (out_Rd) = f_operand2;
2001 }
2002 #endif
2003 #undef FLD
2004 return idesc;
2005 }
2006
2007 extract_sfmt_movs_b_r:
2008 {
2009 const IDESC *idesc = &crisv32f_insn_data[itype];
2010 CGEN_INSN_WORD insn = base_insn;
2011 #define FLD(f) abuf->fields.sfmt_muls_b.f
2012 UINT f_operand2;
2013 UINT f_operand1;
2014
2015 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2016 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2017
2018 /* Record the fields for the semantic handler. */
2019 FLD (f_operand1) = f_operand1;
2020 FLD (f_operand2) = f_operand2;
2021 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movs_b_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2022
2023 #if WITH_PROFILE_MODEL_P
2024 /* Record the fields for profiling. */
2025 if (PROFILE_MODEL_P (current_cpu))
2026 {
2027 FLD (in_Rs) = f_operand1;
2028 FLD (out_Rd) = f_operand2;
2029 }
2030 #endif
2031 #undef FLD
2032 return idesc;
2033 }
2034
2035 extract_sfmt_movecbr:
2036 {
2037 const IDESC *idesc = &crisv32f_insn_data[itype];
2038 CGEN_INSN_WORD insn = base_insn;
2039 #define FLD(f) abuf->fields.sfmt_addcbr.f
2040 INT f_indir_pc__byte;
2041 UINT f_operand2;
2042 /* Contents of trailing part of insn. */
2043 UINT word_1;
2044
2045 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2046 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2047 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2048
2049 /* Record the fields for the semantic handler. */
2050 FLD (f_operand2) = f_operand2;
2051 FLD (f_indir_pc__byte) = f_indir_pc__byte;
2052 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movecbr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
2053
2054 #if WITH_PROFILE_MODEL_P
2055 /* Record the fields for profiling. */
2056 if (PROFILE_MODEL_P (current_cpu))
2057 {
2058 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
2059 }
2060 #endif
2061 #undef FLD
2062 return idesc;
2063 }
2064
2065 extract_sfmt_movecwr:
2066 {
2067 const IDESC *idesc = &crisv32f_insn_data[itype];
2068 CGEN_INSN_WORD insn = base_insn;
2069 #define FLD(f) abuf->fields.sfmt_addcwr.f
2070 INT f_indir_pc__word;
2071 UINT f_operand2;
2072 /* Contents of trailing part of insn. */
2073 UINT word_1;
2074
2075 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2076 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2077 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2078
2079 /* Record the fields for the semantic handler. */
2080 FLD (f_operand2) = f_operand2;
2081 FLD (f_indir_pc__word) = f_indir_pc__word;
2082 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movecwr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
2083
2084 #if WITH_PROFILE_MODEL_P
2085 /* Record the fields for profiling. */
2086 if (PROFILE_MODEL_P (current_cpu))
2087 {
2088 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
2089 }
2090 #endif
2091 #undef FLD
2092 return idesc;
2093 }
2094
2095 extract_sfmt_movecdr:
2096 {
2097 const IDESC *idesc = &crisv32f_insn_data[itype];
2098 CGEN_INSN_WORD insn = base_insn;
2099 #define FLD(f) abuf->fields.sfmt_bound_cd.f
2100 INT f_indir_pc__dword;
2101 UINT f_operand2;
2102 /* Contents of trailing part of insn. */
2103 UINT word_1;
2104
2105 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2106 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
2107 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2108
2109 /* Record the fields for the semantic handler. */
2110 FLD (f_indir_pc__dword) = f_indir_pc__dword;
2111 FLD (f_operand2) = f_operand2;
2112 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movecdr", "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2113
2114 #if WITH_PROFILE_MODEL_P
2115 /* Record the fields for profiling. */
2116 if (PROFILE_MODEL_P (current_cpu))
2117 {
2118 FLD (out_Rd) = f_operand2;
2119 }
2120 #endif
2121 #undef FLD
2122 return idesc;
2123 }
2124
2125 extract_sfmt_movscbr:
2126 {
2127 const IDESC *idesc = &crisv32f_insn_data[itype];
2128 CGEN_INSN_WORD insn = base_insn;
2129 #define FLD(f) abuf->fields.sfmt_bound_cb.f
2130 UINT f_operand2;
2131 INT f_indir_pc__byte;
2132 /* Contents of trailing part of insn. */
2133 UINT word_1;
2134
2135 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2136 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2137 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2138
2139 /* Record the fields for the semantic handler. */
2140 FLD (f_indir_pc__byte) = f_indir_pc__byte;
2141 FLD (f_operand2) = f_operand2;
2142 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movscbr", "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2143
2144 #if WITH_PROFILE_MODEL_P
2145 /* Record the fields for profiling. */
2146 if (PROFILE_MODEL_P (current_cpu))
2147 {
2148 FLD (out_Rd) = f_operand2;
2149 }
2150 #endif
2151 #undef FLD
2152 return idesc;
2153 }
2154
2155 extract_sfmt_movscwr:
2156 {
2157 const IDESC *idesc = &crisv32f_insn_data[itype];
2158 CGEN_INSN_WORD insn = base_insn;
2159 #define FLD(f) abuf->fields.sfmt_bound_cw.f
2160 UINT f_operand2;
2161 INT f_indir_pc__word;
2162 /* Contents of trailing part of insn. */
2163 UINT word_1;
2164
2165 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2166 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2167 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2168
2169 /* Record the fields for the semantic handler. */
2170 FLD (f_indir_pc__word) = f_indir_pc__word;
2171 FLD (f_operand2) = f_operand2;
2172 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movscwr", "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2173
2174 #if WITH_PROFILE_MODEL_P
2175 /* Record the fields for profiling. */
2176 if (PROFILE_MODEL_P (current_cpu))
2177 {
2178 FLD (out_Rd) = f_operand2;
2179 }
2180 #endif
2181 #undef FLD
2182 return idesc;
2183 }
2184
2185 extract_sfmt_movucbr:
2186 {
2187 const IDESC *idesc = &crisv32f_insn_data[itype];
2188 CGEN_INSN_WORD insn = base_insn;
2189 #define FLD(f) abuf->fields.sfmt_bound_cb.f
2190 UINT f_operand2;
2191 INT f_indir_pc__byte;
2192 /* Contents of trailing part of insn. */
2193 UINT word_1;
2194
2195 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2196 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2197 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2198
2199 /* Record the fields for the semantic handler. */
2200 FLD (f_indir_pc__byte) = f_indir_pc__byte;
2201 FLD (f_operand2) = f_operand2;
2202 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movucbr", "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2203
2204 #if WITH_PROFILE_MODEL_P
2205 /* Record the fields for profiling. */
2206 if (PROFILE_MODEL_P (current_cpu))
2207 {
2208 FLD (out_Rd) = f_operand2;
2209 }
2210 #endif
2211 #undef FLD
2212 return idesc;
2213 }
2214
2215 extract_sfmt_movucwr:
2216 {
2217 const IDESC *idesc = &crisv32f_insn_data[itype];
2218 CGEN_INSN_WORD insn = base_insn;
2219 #define FLD(f) abuf->fields.sfmt_bound_cw.f
2220 UINT f_operand2;
2221 INT f_indir_pc__word;
2222 /* Contents of trailing part of insn. */
2223 UINT word_1;
2224
2225 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2226 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2227 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2228
2229 /* Record the fields for the semantic handler. */
2230 FLD (f_indir_pc__word) = f_indir_pc__word;
2231 FLD (f_operand2) = f_operand2;
2232 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movucwr", "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2233
2234 #if WITH_PROFILE_MODEL_P
2235 /* Record the fields for profiling. */
2236 if (PROFILE_MODEL_P (current_cpu))
2237 {
2238 FLD (out_Rd) = f_operand2;
2239 }
2240 #endif
2241 #undef FLD
2242 return idesc;
2243 }
2244
2245 extract_sfmt_addq:
2246 {
2247 const IDESC *idesc = &crisv32f_insn_data[itype];
2248 CGEN_INSN_WORD insn = base_insn;
2249 #define FLD(f) abuf->fields.sfmt_addq.f
2250 UINT f_operand2;
2251 UINT f_u6;
2252
2253 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2254 f_u6 = EXTRACT_LSB0_UINT (insn, 16, 5, 6);
2255
2256 /* Record the fields for the semantic handler. */
2257 FLD (f_operand2) = f_operand2;
2258 FLD (f_u6) = f_u6;
2259 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addq", "f_operand2 0x%x", 'x', f_operand2, "f_u6 0x%x", 'x', f_u6, (char *) 0));
2260
2261 #if WITH_PROFILE_MODEL_P
2262 /* Record the fields for profiling. */
2263 if (PROFILE_MODEL_P (current_cpu))
2264 {
2265 FLD (in_Rd) = f_operand2;
2266 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
2267 }
2268 #endif
2269 #undef FLD
2270 return idesc;
2271 }
2272
2273 extract_sfmt_cmp_r_b_r:
2274 {
2275 const IDESC *idesc = &crisv32f_insn_data[itype];
2276 CGEN_INSN_WORD insn = base_insn;
2277 #define FLD(f) abuf->fields.sfmt_muls_b.f
2278 UINT f_operand2;
2279 UINT f_operand1;
2280
2281 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2282 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2283
2284 /* Record the fields for the semantic handler. */
2285 FLD (f_operand2) = f_operand2;
2286 FLD (f_operand1) = f_operand1;
2287 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp_r_b_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
2288
2289 #if WITH_PROFILE_MODEL_P
2290 /* Record the fields for profiling. */
2291 if (PROFILE_MODEL_P (current_cpu))
2292 {
2293 FLD (in_Rd) = f_operand2;
2294 FLD (in_Rs) = f_operand1;
2295 }
2296 #endif
2297 #undef FLD
2298 return idesc;
2299 }
2300
2301 extract_sfmt_cmp_m_b_m:
2302 {
2303 const IDESC *idesc = &crisv32f_insn_data[itype];
2304 CGEN_INSN_WORD insn = base_insn;
2305 #define FLD(f) abuf->fields.sfmt_addc_m.f
2306 UINT f_operand2;
2307 UINT f_memmode;
2308 UINT f_operand1;
2309
2310 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2311 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2312 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2313
2314 /* Record the fields for the semantic handler. */
2315 FLD (f_operand2) = f_operand2;
2316 FLD (f_operand1) = f_operand1;
2317 FLD (f_memmode) = f_memmode;
2318 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp_m_b_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2319
2320 #if WITH_PROFILE_MODEL_P
2321 /* Record the fields for profiling. */
2322 if (PROFILE_MODEL_P (current_cpu))
2323 {
2324 FLD (in_Rd) = f_operand2;
2325 FLD (in_Rs) = f_operand1;
2326 FLD (out_Rs) = f_operand1;
2327 }
2328 #endif
2329 #undef FLD
2330 return idesc;
2331 }
2332
2333 extract_sfmt_cmp_m_w_m:
2334 {
2335 const IDESC *idesc = &crisv32f_insn_data[itype];
2336 CGEN_INSN_WORD insn = base_insn;
2337 #define FLD(f) abuf->fields.sfmt_addc_m.f
2338 UINT f_operand2;
2339 UINT f_memmode;
2340 UINT f_operand1;
2341
2342 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2343 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2344 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2345
2346 /* Record the fields for the semantic handler. */
2347 FLD (f_operand2) = f_operand2;
2348 FLD (f_operand1) = f_operand1;
2349 FLD (f_memmode) = f_memmode;
2350 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp_m_w_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2351
2352 #if WITH_PROFILE_MODEL_P
2353 /* Record the fields for profiling. */
2354 if (PROFILE_MODEL_P (current_cpu))
2355 {
2356 FLD (in_Rd) = f_operand2;
2357 FLD (in_Rs) = f_operand1;
2358 FLD (out_Rs) = f_operand1;
2359 }
2360 #endif
2361 #undef FLD
2362 return idesc;
2363 }
2364
2365 extract_sfmt_cmp_m_d_m:
2366 {
2367 const IDESC *idesc = &crisv32f_insn_data[itype];
2368 CGEN_INSN_WORD insn = base_insn;
2369 #define FLD(f) abuf->fields.sfmt_addc_m.f
2370 UINT f_operand2;
2371 UINT f_memmode;
2372 UINT f_operand1;
2373
2374 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2375 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2376 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2377
2378 /* Record the fields for the semantic handler. */
2379 FLD (f_operand2) = f_operand2;
2380 FLD (f_operand1) = f_operand1;
2381 FLD (f_memmode) = f_memmode;
2382 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp_m_d_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2383
2384 #if WITH_PROFILE_MODEL_P
2385 /* Record the fields for profiling. */
2386 if (PROFILE_MODEL_P (current_cpu))
2387 {
2388 FLD (in_Rd) = f_operand2;
2389 FLD (in_Rs) = f_operand1;
2390 FLD (out_Rs) = f_operand1;
2391 }
2392 #endif
2393 #undef FLD
2394 return idesc;
2395 }
2396
2397 extract_sfmt_cmpcbr:
2398 {
2399 const IDESC *idesc = &crisv32f_insn_data[itype];
2400 CGEN_INSN_WORD insn = base_insn;
2401 #define FLD(f) abuf->fields.sfmt_bound_cb.f
2402 INT f_indir_pc__byte;
2403 UINT f_operand2;
2404 /* Contents of trailing part of insn. */
2405 UINT word_1;
2406
2407 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2408 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2409 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2410
2411 /* Record the fields for the semantic handler. */
2412 FLD (f_operand2) = f_operand2;
2413 FLD (f_indir_pc__byte) = f_indir_pc__byte;
2414 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpcbr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
2415
2416 #if WITH_PROFILE_MODEL_P
2417 /* Record the fields for profiling. */
2418 if (PROFILE_MODEL_P (current_cpu))
2419 {
2420 FLD (in_Rd) = f_operand2;
2421 }
2422 #endif
2423 #undef FLD
2424 return idesc;
2425 }
2426
2427 extract_sfmt_cmpcwr:
2428 {
2429 const IDESC *idesc = &crisv32f_insn_data[itype];
2430 CGEN_INSN_WORD insn = base_insn;
2431 #define FLD(f) abuf->fields.sfmt_bound_cw.f
2432 INT f_indir_pc__word;
2433 UINT f_operand2;
2434 /* Contents of trailing part of insn. */
2435 UINT word_1;
2436
2437 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2438 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2439 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2440
2441 /* Record the fields for the semantic handler. */
2442 FLD (f_operand2) = f_operand2;
2443 FLD (f_indir_pc__word) = f_indir_pc__word;
2444 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpcwr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
2445
2446 #if WITH_PROFILE_MODEL_P
2447 /* Record the fields for profiling. */
2448 if (PROFILE_MODEL_P (current_cpu))
2449 {
2450 FLD (in_Rd) = f_operand2;
2451 }
2452 #endif
2453 #undef FLD
2454 return idesc;
2455 }
2456
2457 extract_sfmt_cmpcdr:
2458 {
2459 const IDESC *idesc = &crisv32f_insn_data[itype];
2460 CGEN_INSN_WORD insn = base_insn;
2461 #define FLD(f) abuf->fields.sfmt_bound_cd.f
2462 INT f_indir_pc__dword;
2463 UINT f_operand2;
2464 /* Contents of trailing part of insn. */
2465 UINT word_1;
2466
2467 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2468 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
2469 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2470
2471 /* Record the fields for the semantic handler. */
2472 FLD (f_operand2) = f_operand2;
2473 FLD (f_indir_pc__dword) = f_indir_pc__dword;
2474 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpcdr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, (char *) 0));
2475
2476 #if WITH_PROFILE_MODEL_P
2477 /* Record the fields for profiling. */
2478 if (PROFILE_MODEL_P (current_cpu))
2479 {
2480 FLD (in_Rd) = f_operand2;
2481 }
2482 #endif
2483 #undef FLD
2484 return idesc;
2485 }
2486
2487 extract_sfmt_cmpq:
2488 {
2489 const IDESC *idesc = &crisv32f_insn_data[itype];
2490 CGEN_INSN_WORD insn = base_insn;
2491 #define FLD(f) abuf->fields.sfmt_andq.f
2492 UINT f_operand2;
2493 INT f_s6;
2494
2495 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2496 f_s6 = EXTRACT_LSB0_SINT (insn, 16, 5, 6);
2497
2498 /* Record the fields for the semantic handler. */
2499 FLD (f_operand2) = f_operand2;
2500 FLD (f_s6) = f_s6;
2501 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpq", "f_operand2 0x%x", 'x', f_operand2, "f_s6 0x%x", 'x', f_s6, (char *) 0));
2502
2503 #if WITH_PROFILE_MODEL_P
2504 /* Record the fields for profiling. */
2505 if (PROFILE_MODEL_P (current_cpu))
2506 {
2507 FLD (in_Rd) = f_operand2;
2508 }
2509 #endif
2510 #undef FLD
2511 return idesc;
2512 }
2513
2514 extract_sfmt_cmpucbr:
2515 {
2516 const IDESC *idesc = &crisv32f_insn_data[itype];
2517 CGEN_INSN_WORD insn = base_insn;
2518 #define FLD(f) abuf->fields.sfmt_bound_cb.f
2519 INT f_indir_pc__byte;
2520 UINT f_operand2;
2521 /* Contents of trailing part of insn. */
2522 UINT word_1;
2523
2524 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2525 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2526 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2527
2528 /* Record the fields for the semantic handler. */
2529 FLD (f_operand2) = f_operand2;
2530 FLD (f_indir_pc__byte) = f_indir_pc__byte;
2531 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpucbr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
2532
2533 #if WITH_PROFILE_MODEL_P
2534 /* Record the fields for profiling. */
2535 if (PROFILE_MODEL_P (current_cpu))
2536 {
2537 FLD (in_Rd) = f_operand2;
2538 }
2539 #endif
2540 #undef FLD
2541 return idesc;
2542 }
2543
2544 extract_sfmt_cmpucwr:
2545 {
2546 const IDESC *idesc = &crisv32f_insn_data[itype];
2547 CGEN_INSN_WORD insn = base_insn;
2548 #define FLD(f) abuf->fields.sfmt_bound_cw.f
2549 INT f_indir_pc__word;
2550 UINT f_operand2;
2551 /* Contents of trailing part of insn. */
2552 UINT word_1;
2553
2554 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2555 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
2556 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2557
2558 /* Record the fields for the semantic handler. */
2559 FLD (f_operand2) = f_operand2;
2560 FLD (f_indir_pc__word) = f_indir_pc__word;
2561 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpucwr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
2562
2563 #if WITH_PROFILE_MODEL_P
2564 /* Record the fields for profiling. */
2565 if (PROFILE_MODEL_P (current_cpu))
2566 {
2567 FLD (in_Rd) = f_operand2;
2568 }
2569 #endif
2570 #undef FLD
2571 return idesc;
2572 }
2573
2574 extract_sfmt_move_m_b_m:
2575 {
2576 const IDESC *idesc = &crisv32f_insn_data[itype];
2577 CGEN_INSN_WORD insn = base_insn;
2578 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
2579 UINT f_operand2;
2580 UINT f_memmode;
2581 UINT f_operand1;
2582
2583 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2584 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2585 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2586
2587 /* Record the fields for the semantic handler. */
2588 FLD (f_operand1) = f_operand1;
2589 FLD (f_operand2) = f_operand2;
2590 FLD (f_memmode) = f_memmode;
2591 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_m_b_m", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2592
2593 #if WITH_PROFILE_MODEL_P
2594 /* Record the fields for profiling. */
2595 if (PROFILE_MODEL_P (current_cpu))
2596 {
2597 FLD (in_Rs) = f_operand1;
2598 FLD (out_Rs) = f_operand1;
2599 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
2600 }
2601 #endif
2602 #undef FLD
2603 return idesc;
2604 }
2605
2606 extract_sfmt_move_m_w_m:
2607 {
2608 const IDESC *idesc = &crisv32f_insn_data[itype];
2609 CGEN_INSN_WORD insn = base_insn;
2610 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
2611 UINT f_operand2;
2612 UINT f_memmode;
2613 UINT f_operand1;
2614
2615 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2616 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2617 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2618
2619 /* Record the fields for the semantic handler. */
2620 FLD (f_operand1) = f_operand1;
2621 FLD (f_operand2) = f_operand2;
2622 FLD (f_memmode) = f_memmode;
2623 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_m_w_m", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2624
2625 #if WITH_PROFILE_MODEL_P
2626 /* Record the fields for profiling. */
2627 if (PROFILE_MODEL_P (current_cpu))
2628 {
2629 FLD (in_Rs) = f_operand1;
2630 FLD (out_Rs) = f_operand1;
2631 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
2632 }
2633 #endif
2634 #undef FLD
2635 return idesc;
2636 }
2637
2638 extract_sfmt_move_m_d_m:
2639 {
2640 const IDESC *idesc = &crisv32f_insn_data[itype];
2641 CGEN_INSN_WORD insn = base_insn;
2642 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
2643 UINT f_operand2;
2644 UINT f_memmode;
2645 UINT f_operand1;
2646
2647 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2648 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2649 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2650
2651 /* Record the fields for the semantic handler. */
2652 FLD (f_operand1) = f_operand1;
2653 FLD (f_operand2) = f_operand2;
2654 FLD (f_memmode) = f_memmode;
2655 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_m_d_m", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2656
2657 #if WITH_PROFILE_MODEL_P
2658 /* Record the fields for profiling. */
2659 if (PROFILE_MODEL_P (current_cpu))
2660 {
2661 FLD (in_Rs) = f_operand1;
2662 FLD (out_Rs) = f_operand1;
2663 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
2664 }
2665 #endif
2666 #undef FLD
2667 return idesc;
2668 }
2669
2670 extract_sfmt_movs_m_b_m:
2671 {
2672 const IDESC *idesc = &crisv32f_insn_data[itype];
2673 CGEN_INSN_WORD insn = base_insn;
2674 #define FLD(f) abuf->fields.sfmt_movs_m_b_m.f
2675 UINT f_operand2;
2676 UINT f_memmode;
2677 UINT f_operand1;
2678
2679 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2680 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2681 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2682
2683 /* Record the fields for the semantic handler. */
2684 FLD (f_operand1) = f_operand1;
2685 FLD (f_memmode) = f_memmode;
2686 FLD (f_operand2) = f_operand2;
2687 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movs_m_b_m", "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2688
2689 #if WITH_PROFILE_MODEL_P
2690 /* Record the fields for profiling. */
2691 if (PROFILE_MODEL_P (current_cpu))
2692 {
2693 FLD (in_Rs) = f_operand1;
2694 FLD (out_Rd) = f_operand2;
2695 FLD (out_Rs) = f_operand1;
2696 }
2697 #endif
2698 #undef FLD
2699 return idesc;
2700 }
2701
2702 extract_sfmt_movs_m_w_m:
2703 {
2704 const IDESC *idesc = &crisv32f_insn_data[itype];
2705 CGEN_INSN_WORD insn = base_insn;
2706 #define FLD(f) abuf->fields.sfmt_movs_m_b_m.f
2707 UINT f_operand2;
2708 UINT f_memmode;
2709 UINT f_operand1;
2710
2711 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2712 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2713 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2714
2715 /* Record the fields for the semantic handler. */
2716 FLD (f_operand1) = f_operand1;
2717 FLD (f_memmode) = f_memmode;
2718 FLD (f_operand2) = f_operand2;
2719 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movs_m_w_m", "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2720
2721 #if WITH_PROFILE_MODEL_P
2722 /* Record the fields for profiling. */
2723 if (PROFILE_MODEL_P (current_cpu))
2724 {
2725 FLD (in_Rs) = f_operand1;
2726 FLD (out_Rd) = f_operand2;
2727 FLD (out_Rs) = f_operand1;
2728 }
2729 #endif
2730 #undef FLD
2731 return idesc;
2732 }
2733
2734 extract_sfmt_move_r_sprv32:
2735 {
2736 const IDESC *idesc = &crisv32f_insn_data[itype];
2737 CGEN_INSN_WORD insn = base_insn;
2738 #define FLD(f) abuf->fields.sfmt_move_m_sprv32.f
2739 UINT f_operand2;
2740 UINT f_operand1;
2741
2742 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2743 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2744
2745 /* Record the fields for the semantic handler. */
2746 FLD (f_operand1) = f_operand1;
2747 FLD (f_operand2) = f_operand2;
2748 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_r_sprv32", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2749
2750 #if WITH_PROFILE_MODEL_P
2751 /* Record the fields for profiling. */
2752 if (PROFILE_MODEL_P (current_cpu))
2753 {
2754 FLD (in_Rs) = f_operand1;
2755 FLD (out_Pd) = f_operand2;
2756 }
2757 #endif
2758 #undef FLD
2759 return idesc;
2760 }
2761
2762 extract_sfmt_move_spr_rv32:
2763 {
2764 const IDESC *idesc = &crisv32f_insn_data[itype];
2765 CGEN_INSN_WORD insn = base_insn;
2766 #define FLD(f) abuf->fields.sfmt_mcp.f
2767 UINT f_operand2;
2768 UINT f_operand1;
2769
2770 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2771 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2772
2773 /* Record the fields for the semantic handler. */
2774 FLD (f_operand2) = f_operand2;
2775 FLD (f_operand1) = f_operand1;
2776 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_spr_rv32", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
2777
2778 #if WITH_PROFILE_MODEL_P
2779 /* Record the fields for profiling. */
2780 if (PROFILE_MODEL_P (current_cpu))
2781 {
2782 FLD (in_Ps) = f_operand2;
2783 FLD (out_h_gr_SI_index_of__INT_Rs) = FLD (f_operand1);
2784 }
2785 #endif
2786 #undef FLD
2787 return idesc;
2788 }
2789
2790 extract_sfmt_move_m_sprv32:
2791 {
2792 const IDESC *idesc = &crisv32f_insn_data[itype];
2793 CGEN_INSN_WORD insn = base_insn;
2794 #define FLD(f) abuf->fields.sfmt_move_m_sprv32.f
2795 UINT f_operand2;
2796 UINT f_memmode;
2797 UINT f_operand1;
2798
2799 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2800 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2801 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2802
2803 /* Record the fields for the semantic handler. */
2804 FLD (f_operand1) = f_operand1;
2805 FLD (f_operand2) = f_operand2;
2806 FLD (f_memmode) = f_memmode;
2807 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_m_sprv32", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2808
2809 #if WITH_PROFILE_MODEL_P
2810 /* Record the fields for profiling. */
2811 if (PROFILE_MODEL_P (current_cpu))
2812 {
2813 FLD (in_Rs) = f_operand1;
2814 FLD (out_Pd) = f_operand2;
2815 FLD (out_Rs) = f_operand1;
2816 }
2817 #endif
2818 #undef FLD
2819 return idesc;
2820 }
2821
2822 extract_sfmt_move_c_sprv32_p2:
2823 {
2824 const IDESC *idesc = &crisv32f_insn_data[itype];
2825 CGEN_INSN_WORD insn = base_insn;
2826 #define FLD(f) abuf->fields.sfmt_move_c_sprv32_p2.f
2827 INT f_indir_pc__dword;
2828 UINT f_operand2;
2829 /* Contents of trailing part of insn. */
2830 UINT word_1;
2831
2832 word_1 = GETIMEMUSI (current_cpu, pc + 2);
2833 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
2834 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2835
2836 /* Record the fields for the semantic handler. */
2837 FLD (f_indir_pc__dword) = f_indir_pc__dword;
2838 FLD (f_operand2) = f_operand2;
2839 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_c_sprv32_p2", "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2840
2841 #if WITH_PROFILE_MODEL_P
2842 /* Record the fields for profiling. */
2843 if (PROFILE_MODEL_P (current_cpu))
2844 {
2845 FLD (out_Pd) = f_operand2;
2846 }
2847 #endif
2848 #undef FLD
2849 return idesc;
2850 }
2851
2852 extract_sfmt_move_spr_mv32:
2853 {
2854 const IDESC *idesc = &crisv32f_insn_data[itype];
2855 CGEN_INSN_WORD insn = base_insn;
2856 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
2857 UINT f_operand2;
2858 UINT f_memmode;
2859 UINT f_operand1;
2860
2861 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2862 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2863 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2864
2865 /* Record the fields for the semantic handler. */
2866 FLD (f_operand2) = f_operand2;
2867 FLD (f_operand1) = f_operand1;
2868 FLD (f_memmode) = f_memmode;
2869 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_spr_mv32", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2870
2871 #if WITH_PROFILE_MODEL_P
2872 /* Record the fields for profiling. */
2873 if (PROFILE_MODEL_P (current_cpu))
2874 {
2875 FLD (in_Ps) = f_operand2;
2876 FLD (in_Rs) = f_operand1;
2877 FLD (out_Rs) = f_operand1;
2878 }
2879 #endif
2880 #undef FLD
2881 return idesc;
2882 }
2883
2884 extract_sfmt_move_ss_r:
2885 {
2886 const IDESC *idesc = &crisv32f_insn_data[itype];
2887 CGEN_INSN_WORD insn = base_insn;
2888 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
2889 UINT f_operand2;
2890 UINT f_operand1;
2891
2892 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2893 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2894
2895 /* Record the fields for the semantic handler. */
2896 FLD (f_operand2) = f_operand2;
2897 FLD (f_operand1) = f_operand1;
2898 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_ss_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
2899
2900 #if WITH_PROFILE_MODEL_P
2901 /* Record the fields for profiling. */
2902 if (PROFILE_MODEL_P (current_cpu))
2903 {
2904 FLD (out_Rs) = f_operand1;
2905 }
2906 #endif
2907 #undef FLD
2908 return idesc;
2909 }
2910
2911 extract_sfmt_move_r_ss:
2912 {
2913 const IDESC *idesc = &crisv32f_insn_data[itype];
2914 CGEN_INSN_WORD insn = base_insn;
2915 #define FLD(f) abuf->fields.sfmt_mcp.f
2916 UINT f_operand2;
2917 UINT f_operand1;
2918
2919 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2920 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2921
2922 /* Record the fields for the semantic handler. */
2923 FLD (f_operand1) = f_operand1;
2924 FLD (f_operand2) = f_operand2;
2925 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_r_ss", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
2926
2927 #if WITH_PROFILE_MODEL_P
2928 /* Record the fields for profiling. */
2929 if (PROFILE_MODEL_P (current_cpu))
2930 {
2931 FLD (in_Rs) = f_operand1;
2932 }
2933 #endif
2934 #undef FLD
2935 return idesc;
2936 }
2937
2938 extract_sfmt_movem_r_m_v32:
2939 {
2940 const IDESC *idesc = &crisv32f_insn_data[itype];
2941 CGEN_INSN_WORD insn = base_insn;
2942 #define FLD(f) abuf->fields.sfmt_movem_r_m_v32.f
2943 UINT f_operand2;
2944 UINT f_memmode;
2945 UINT f_operand1;
2946
2947 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2948 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2949 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2950
2951 /* Record the fields for the semantic handler. */
2952 FLD (f_operand2) = f_operand2;
2953 FLD (f_operand1) = f_operand1;
2954 FLD (f_memmode) = f_memmode;
2955 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movem_r_m_v32", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
2956
2957 #if WITH_PROFILE_MODEL_P
2958 /* Record the fields for profiling. */
2959 if (PROFILE_MODEL_P (current_cpu))
2960 {
2961 FLD (in_Rd) = f_operand2;
2962 FLD (in_Rs) = f_operand1;
2963 FLD (in_h_gr_SI_0) = 0;
2964 FLD (in_h_gr_SI_1) = 1;
2965 FLD (in_h_gr_SI_10) = 10;
2966 FLD (in_h_gr_SI_11) = 11;
2967 FLD (in_h_gr_SI_12) = 12;
2968 FLD (in_h_gr_SI_13) = 13;
2969 FLD (in_h_gr_SI_14) = 14;
2970 FLD (in_h_gr_SI_15) = 15;
2971 FLD (in_h_gr_SI_2) = 2;
2972 FLD (in_h_gr_SI_3) = 3;
2973 FLD (in_h_gr_SI_4) = 4;
2974 FLD (in_h_gr_SI_5) = 5;
2975 FLD (in_h_gr_SI_6) = 6;
2976 FLD (in_h_gr_SI_7) = 7;
2977 FLD (in_h_gr_SI_8) = 8;
2978 FLD (in_h_gr_SI_9) = 9;
2979 FLD (out_Rs) = f_operand1;
2980 }
2981 #endif
2982 #undef FLD
2983 return idesc;
2984 }
2985
2986 extract_sfmt_movem_m_r_v32:
2987 {
2988 const IDESC *idesc = &crisv32f_insn_data[itype];
2989 CGEN_INSN_WORD insn = base_insn;
2990 #define FLD(f) abuf->fields.sfmt_movem_m_r_v32.f
2991 UINT f_operand2;
2992 UINT f_memmode;
2993 UINT f_operand1;
2994
2995 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
2996 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
2997 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
2998
2999 /* Record the fields for the semantic handler. */
3000 FLD (f_operand2) = f_operand2;
3001 FLD (f_operand1) = f_operand1;
3002 FLD (f_memmode) = f_memmode;
3003 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_movem_m_r_v32", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3004
3005 #if WITH_PROFILE_MODEL_P
3006 /* Record the fields for profiling. */
3007 if (PROFILE_MODEL_P (current_cpu))
3008 {
3009 FLD (in_Rd) = f_operand2;
3010 FLD (in_Rs) = f_operand1;
3011 FLD (out_Rs) = f_operand1;
3012 FLD (out_h_gr_SI_0) = 0;
3013 FLD (out_h_gr_SI_1) = 1;
3014 FLD (out_h_gr_SI_10) = 10;
3015 FLD (out_h_gr_SI_11) = 11;
3016 FLD (out_h_gr_SI_12) = 12;
3017 FLD (out_h_gr_SI_13) = 13;
3018 FLD (out_h_gr_SI_14) = 14;
3019 FLD (out_h_gr_SI_15) = 15;
3020 FLD (out_h_gr_SI_2) = 2;
3021 FLD (out_h_gr_SI_3) = 3;
3022 FLD (out_h_gr_SI_4) = 4;
3023 FLD (out_h_gr_SI_5) = 5;
3024 FLD (out_h_gr_SI_6) = 6;
3025 FLD (out_h_gr_SI_7) = 7;
3026 FLD (out_h_gr_SI_8) = 8;
3027 FLD (out_h_gr_SI_9) = 9;
3028 }
3029 #endif
3030 #undef FLD
3031 return idesc;
3032 }
3033
3034 extract_sfmt_add_b_r:
3035 {
3036 const IDESC *idesc = &crisv32f_insn_data[itype];
3037 CGEN_INSN_WORD insn = base_insn;
3038 #define FLD(f) abuf->fields.sfmt_addc_m.f
3039 UINT f_operand2;
3040 UINT f_operand1;
3041
3042 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3043 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3044
3045 /* Record the fields for the semantic handler. */
3046 FLD (f_operand2) = f_operand2;
3047 FLD (f_operand1) = f_operand1;
3048 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add_b_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3049
3050 #if WITH_PROFILE_MODEL_P
3051 /* Record the fields for profiling. */
3052 if (PROFILE_MODEL_P (current_cpu))
3053 {
3054 FLD (in_Rd) = f_operand2;
3055 FLD (in_Rs) = f_operand1;
3056 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3057 }
3058 #endif
3059 #undef FLD
3060 return idesc;
3061 }
3062
3063 extract_sfmt_add_d_r:
3064 {
3065 const IDESC *idesc = &crisv32f_insn_data[itype];
3066 CGEN_INSN_WORD insn = base_insn;
3067 #define FLD(f) abuf->fields.sfmt_addc_m.f
3068 UINT f_operand2;
3069 UINT f_operand1;
3070
3071 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3072 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3073
3074 /* Record the fields for the semantic handler. */
3075 FLD (f_operand2) = f_operand2;
3076 FLD (f_operand1) = f_operand1;
3077 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add_d_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3078
3079 #if WITH_PROFILE_MODEL_P
3080 /* Record the fields for profiling. */
3081 if (PROFILE_MODEL_P (current_cpu))
3082 {
3083 FLD (in_Rd) = f_operand2;
3084 FLD (in_Rs) = f_operand1;
3085 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3086 }
3087 #endif
3088 #undef FLD
3089 return idesc;
3090 }
3091
3092 extract_sfmt_add_m_b_m:
3093 {
3094 const IDESC *idesc = &crisv32f_insn_data[itype];
3095 CGEN_INSN_WORD insn = base_insn;
3096 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3097 UINT f_operand2;
3098 UINT f_memmode;
3099 UINT f_operand1;
3100
3101 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3102 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3103 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3104
3105 /* Record the fields for the semantic handler. */
3106 FLD (f_operand2) = f_operand2;
3107 FLD (f_operand1) = f_operand1;
3108 FLD (f_memmode) = f_memmode;
3109 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add_m_b_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3110
3111 #if WITH_PROFILE_MODEL_P
3112 /* Record the fields for profiling. */
3113 if (PROFILE_MODEL_P (current_cpu))
3114 {
3115 FLD (in_Rd) = f_operand2;
3116 FLD (in_Rs) = f_operand1;
3117 FLD (out_Rs) = f_operand1;
3118 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3119 }
3120 #endif
3121 #undef FLD
3122 return idesc;
3123 }
3124
3125 extract_sfmt_add_m_w_m:
3126 {
3127 const IDESC *idesc = &crisv32f_insn_data[itype];
3128 CGEN_INSN_WORD insn = base_insn;
3129 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3130 UINT f_operand2;
3131 UINT f_memmode;
3132 UINT f_operand1;
3133
3134 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3135 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3136 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3137
3138 /* Record the fields for the semantic handler. */
3139 FLD (f_operand2) = f_operand2;
3140 FLD (f_operand1) = f_operand1;
3141 FLD (f_memmode) = f_memmode;
3142 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add_m_w_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3143
3144 #if WITH_PROFILE_MODEL_P
3145 /* Record the fields for profiling. */
3146 if (PROFILE_MODEL_P (current_cpu))
3147 {
3148 FLD (in_Rd) = f_operand2;
3149 FLD (in_Rs) = f_operand1;
3150 FLD (out_Rs) = f_operand1;
3151 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3152 }
3153 #endif
3154 #undef FLD
3155 return idesc;
3156 }
3157
3158 extract_sfmt_add_m_d_m:
3159 {
3160 const IDESC *idesc = &crisv32f_insn_data[itype];
3161 CGEN_INSN_WORD insn = base_insn;
3162 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3163 UINT f_operand2;
3164 UINT f_memmode;
3165 UINT f_operand1;
3166
3167 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3168 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3169 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3170
3171 /* Record the fields for the semantic handler. */
3172 FLD (f_operand2) = f_operand2;
3173 FLD (f_operand1) = f_operand1;
3174 FLD (f_memmode) = f_memmode;
3175 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add_m_d_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3176
3177 #if WITH_PROFILE_MODEL_P
3178 /* Record the fields for profiling. */
3179 if (PROFILE_MODEL_P (current_cpu))
3180 {
3181 FLD (in_Rd) = f_operand2;
3182 FLD (in_Rs) = f_operand1;
3183 FLD (out_Rs) = f_operand1;
3184 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3185 }
3186 #endif
3187 #undef FLD
3188 return idesc;
3189 }
3190
3191 extract_sfmt_addcbr:
3192 {
3193 const IDESC *idesc = &crisv32f_insn_data[itype];
3194 CGEN_INSN_WORD insn = base_insn;
3195 #define FLD(f) abuf->fields.sfmt_addcbr.f
3196 INT f_indir_pc__byte;
3197 UINT f_operand2;
3198 /* Contents of trailing part of insn. */
3199 UINT word_1;
3200
3201 word_1 = GETIMEMUSI (current_cpu, pc + 2);
3202 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
3203 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3204
3205 /* Record the fields for the semantic handler. */
3206 FLD (f_operand2) = f_operand2;
3207 FLD (f_indir_pc__byte) = f_indir_pc__byte;
3208 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addcbr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
3209
3210 #if WITH_PROFILE_MODEL_P
3211 /* Record the fields for profiling. */
3212 if (PROFILE_MODEL_P (current_cpu))
3213 {
3214 FLD (in_Rd) = f_operand2;
3215 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3216 }
3217 #endif
3218 #undef FLD
3219 return idesc;
3220 }
3221
3222 extract_sfmt_addcwr:
3223 {
3224 const IDESC *idesc = &crisv32f_insn_data[itype];
3225 CGEN_INSN_WORD insn = base_insn;
3226 #define FLD(f) abuf->fields.sfmt_addcwr.f
3227 INT f_indir_pc__word;
3228 UINT f_operand2;
3229 /* Contents of trailing part of insn. */
3230 UINT word_1;
3231
3232 word_1 = GETIMEMUSI (current_cpu, pc + 2);
3233 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
3234 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3235
3236 /* Record the fields for the semantic handler. */
3237 FLD (f_operand2) = f_operand2;
3238 FLD (f_indir_pc__word) = f_indir_pc__word;
3239 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addcwr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
3240
3241 #if WITH_PROFILE_MODEL_P
3242 /* Record the fields for profiling. */
3243 if (PROFILE_MODEL_P (current_cpu))
3244 {
3245 FLD (in_Rd) = f_operand2;
3246 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3247 }
3248 #endif
3249 #undef FLD
3250 return idesc;
3251 }
3252
3253 extract_sfmt_addcdr:
3254 {
3255 const IDESC *idesc = &crisv32f_insn_data[itype];
3256 CGEN_INSN_WORD insn = base_insn;
3257 #define FLD(f) abuf->fields.sfmt_addcdr.f
3258 INT f_indir_pc__dword;
3259 UINT f_operand2;
3260 /* Contents of trailing part of insn. */
3261 UINT word_1;
3262
3263 word_1 = GETIMEMUSI (current_cpu, pc + 2);
3264 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
3265 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3266
3267 /* Record the fields for the semantic handler. */
3268 FLD (f_operand2) = f_operand2;
3269 FLD (f_indir_pc__dword) = f_indir_pc__dword;
3270 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addcdr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, (char *) 0));
3271
3272 #if WITH_PROFILE_MODEL_P
3273 /* Record the fields for profiling. */
3274 if (PROFILE_MODEL_P (current_cpu))
3275 {
3276 FLD (in_Rd) = f_operand2;
3277 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3278 }
3279 #endif
3280 #undef FLD
3281 return idesc;
3282 }
3283
3284 extract_sfmt_adds_m_b_m:
3285 {
3286 const IDESC *idesc = &crisv32f_insn_data[itype];
3287 CGEN_INSN_WORD insn = base_insn;
3288 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3289 UINT f_operand2;
3290 UINT f_memmode;
3291 UINT f_operand1;
3292
3293 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3294 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3295 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3296
3297 /* Record the fields for the semantic handler. */
3298 FLD (f_operand2) = f_operand2;
3299 FLD (f_operand1) = f_operand1;
3300 FLD (f_memmode) = f_memmode;
3301 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_adds_m_b_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3302
3303 #if WITH_PROFILE_MODEL_P
3304 /* Record the fields for profiling. */
3305 if (PROFILE_MODEL_P (current_cpu))
3306 {
3307 FLD (in_Rd) = f_operand2;
3308 FLD (in_Rs) = f_operand1;
3309 FLD (out_Rs) = f_operand1;
3310 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3311 }
3312 #endif
3313 #undef FLD
3314 return idesc;
3315 }
3316
3317 extract_sfmt_adds_m_w_m:
3318 {
3319 const IDESC *idesc = &crisv32f_insn_data[itype];
3320 CGEN_INSN_WORD insn = base_insn;
3321 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3322 UINT f_operand2;
3323 UINT f_memmode;
3324 UINT f_operand1;
3325
3326 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3327 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3328 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3329
3330 /* Record the fields for the semantic handler. */
3331 FLD (f_operand2) = f_operand2;
3332 FLD (f_operand1) = f_operand1;
3333 FLD (f_memmode) = f_memmode;
3334 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_adds_m_w_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3335
3336 #if WITH_PROFILE_MODEL_P
3337 /* Record the fields for profiling. */
3338 if (PROFILE_MODEL_P (current_cpu))
3339 {
3340 FLD (in_Rd) = f_operand2;
3341 FLD (in_Rs) = f_operand1;
3342 FLD (out_Rs) = f_operand1;
3343 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3344 }
3345 #endif
3346 #undef FLD
3347 return idesc;
3348 }
3349
3350 extract_sfmt_addscbr:
3351 {
3352 const IDESC *idesc = &crisv32f_insn_data[itype];
3353 CGEN_INSN_WORD insn = base_insn;
3354 #define FLD(f) abuf->fields.sfmt_addcbr.f
3355 INT f_indir_pc__byte;
3356 UINT f_operand2;
3357 /* Contents of trailing part of insn. */
3358 UINT word_1;
3359
3360 word_1 = GETIMEMUSI (current_cpu, pc + 2);
3361 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
3362 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3363
3364 /* Record the fields for the semantic handler. */
3365 FLD (f_operand2) = f_operand2;
3366 FLD (f_indir_pc__byte) = f_indir_pc__byte;
3367 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addscbr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
3368
3369 #if WITH_PROFILE_MODEL_P
3370 /* Record the fields for profiling. */
3371 if (PROFILE_MODEL_P (current_cpu))
3372 {
3373 FLD (in_Rd) = f_operand2;
3374 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3375 }
3376 #endif
3377 #undef FLD
3378 return idesc;
3379 }
3380
3381 extract_sfmt_addscwr:
3382 {
3383 const IDESC *idesc = &crisv32f_insn_data[itype];
3384 CGEN_INSN_WORD insn = base_insn;
3385 #define FLD(f) abuf->fields.sfmt_addcwr.f
3386 INT f_indir_pc__word;
3387 UINT f_operand2;
3388 /* Contents of trailing part of insn. */
3389 UINT word_1;
3390
3391 word_1 = GETIMEMUSI (current_cpu, pc + 2);
3392 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
3393 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3394
3395 /* Record the fields for the semantic handler. */
3396 FLD (f_operand2) = f_operand2;
3397 FLD (f_indir_pc__word) = f_indir_pc__word;
3398 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addscwr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
3399
3400 #if WITH_PROFILE_MODEL_P
3401 /* Record the fields for profiling. */
3402 if (PROFILE_MODEL_P (current_cpu))
3403 {
3404 FLD (in_Rd) = f_operand2;
3405 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3406 }
3407 #endif
3408 #undef FLD
3409 return idesc;
3410 }
3411
3412 extract_sfmt_addc_m:
3413 {
3414 const IDESC *idesc = &crisv32f_insn_data[itype];
3415 CGEN_INSN_WORD insn = base_insn;
3416 #define FLD(f) abuf->fields.sfmt_addc_m.f
3417 UINT f_operand2;
3418 UINT f_memmode;
3419 UINT f_operand1;
3420
3421 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3422 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3423 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3424
3425 /* Record the fields for the semantic handler. */
3426 FLD (f_operand2) = f_operand2;
3427 FLD (f_operand1) = f_operand1;
3428 FLD (f_memmode) = f_memmode;
3429 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addc_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3430
3431 #if WITH_PROFILE_MODEL_P
3432 /* Record the fields for profiling. */
3433 if (PROFILE_MODEL_P (current_cpu))
3434 {
3435 FLD (in_Rd) = f_operand2;
3436 FLD (in_Rs) = f_operand1;
3437 FLD (out_Rs) = f_operand1;
3438 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3439 }
3440 #endif
3441 #undef FLD
3442 return idesc;
3443 }
3444
3445 extract_sfmt_lapc_d:
3446 {
3447 const IDESC *idesc = &crisv32f_insn_data[itype];
3448 CGEN_INSN_WORD insn = base_insn;
3449 #define FLD(f) abuf->fields.sfmt_lapc_d.f
3450 SI f_indir_pc__dword_pcrel;
3451 UINT f_operand2;
3452 /* Contents of trailing part of insn. */
3453 UINT word_1;
3454
3455 word_1 = GETIMEMUSI (current_cpu, pc + 2);
3456 f_indir_pc__dword_pcrel = ((pc) + ((0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0))));
3457 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3458
3459 /* Record the fields for the semantic handler. */
3460 FLD (f_operand2) = f_operand2;
3461 FLD (i_const32_pcrel) = f_indir_pc__dword_pcrel;
3462 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lapc_d", "f_operand2 0x%x", 'x', f_operand2, "const32_pcrel 0x%x", 'x', f_indir_pc__dword_pcrel, (char *) 0));
3463
3464 #if WITH_PROFILE_MODEL_P
3465 /* Record the fields for profiling. */
3466 if (PROFILE_MODEL_P (current_cpu))
3467 {
3468 FLD (out_Rd) = f_operand2;
3469 }
3470 #endif
3471 #undef FLD
3472 return idesc;
3473 }
3474
3475 extract_sfmt_lapcq:
3476 {
3477 const IDESC *idesc = &crisv32f_insn_data[itype];
3478 CGEN_INSN_WORD insn = base_insn;
3479 #define FLD(f) abuf->fields.sfmt_lapcq.f
3480 UINT f_operand2;
3481 SI f_qo;
3482
3483 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3484 f_qo = ((pc) + (((EXTRACT_LSB0_UINT (insn, 16, 3, 4)) << (1))));
3485
3486 /* Record the fields for the semantic handler. */
3487 FLD (f_operand2) = f_operand2;
3488 FLD (i_qo) = f_qo;
3489 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lapcq", "f_operand2 0x%x", 'x', f_operand2, "qo 0x%x", 'x', f_qo, (char *) 0));
3490
3491 #if WITH_PROFILE_MODEL_P
3492 /* Record the fields for profiling. */
3493 if (PROFILE_MODEL_P (current_cpu))
3494 {
3495 FLD (out_Rd) = f_operand2;
3496 }
3497 #endif
3498 #undef FLD
3499 return idesc;
3500 }
3501
3502 extract_sfmt_addi_b_r:
3503 {
3504 const IDESC *idesc = &crisv32f_insn_data[itype];
3505 CGEN_INSN_WORD insn = base_insn;
3506 #define FLD(f) abuf->fields.sfmt_addc_m.f
3507 UINT f_operand2;
3508 UINT f_operand1;
3509
3510 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3511 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3512
3513 /* Record the fields for the semantic handler. */
3514 FLD (f_operand2) = f_operand2;
3515 FLD (f_operand1) = f_operand1;
3516 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addi_b_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3517
3518 #if WITH_PROFILE_MODEL_P
3519 /* Record the fields for profiling. */
3520 if (PROFILE_MODEL_P (current_cpu))
3521 {
3522 FLD (in_Rd) = f_operand2;
3523 FLD (in_Rs) = f_operand1;
3524 FLD (out_Rs) = f_operand1;
3525 }
3526 #endif
3527 #undef FLD
3528 return idesc;
3529 }
3530
3531 extract_sfmt_neg_b_r:
3532 {
3533 const IDESC *idesc = &crisv32f_insn_data[itype];
3534 CGEN_INSN_WORD insn = base_insn;
3535 #define FLD(f) abuf->fields.sfmt_addc_m.f
3536 UINT f_operand2;
3537 UINT f_operand1;
3538
3539 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3540 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3541
3542 /* Record the fields for the semantic handler. */
3543 FLD (f_operand1) = f_operand1;
3544 FLD (f_operand2) = f_operand2;
3545 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_neg_b_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
3546
3547 #if WITH_PROFILE_MODEL_P
3548 /* Record the fields for profiling. */
3549 if (PROFILE_MODEL_P (current_cpu))
3550 {
3551 FLD (in_Rs) = f_operand1;
3552 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3553 }
3554 #endif
3555 #undef FLD
3556 return idesc;
3557 }
3558
3559 extract_sfmt_neg_d_r:
3560 {
3561 const IDESC *idesc = &crisv32f_insn_data[itype];
3562 CGEN_INSN_WORD insn = base_insn;
3563 #define FLD(f) abuf->fields.sfmt_addc_m.f
3564 UINT f_operand2;
3565 UINT f_operand1;
3566
3567 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3568 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3569
3570 /* Record the fields for the semantic handler. */
3571 FLD (f_operand1) = f_operand1;
3572 FLD (f_operand2) = f_operand2;
3573 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_neg_d_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
3574
3575 #if WITH_PROFILE_MODEL_P
3576 /* Record the fields for profiling. */
3577 if (PROFILE_MODEL_P (current_cpu))
3578 {
3579 FLD (in_Rs) = f_operand1;
3580 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3581 }
3582 #endif
3583 #undef FLD
3584 return idesc;
3585 }
3586
3587 extract_sfmt_test_m_b_m:
3588 {
3589 const IDESC *idesc = &crisv32f_insn_data[itype];
3590 CGEN_INSN_WORD insn = base_insn;
3591 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
3592 UINT f_memmode;
3593 UINT f_operand1;
3594
3595 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3596 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3597
3598 /* Record the fields for the semantic handler. */
3599 FLD (f_operand1) = f_operand1;
3600 FLD (f_memmode) = f_memmode;
3601 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_test_m_b_m", "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3602
3603 #if WITH_PROFILE_MODEL_P
3604 /* Record the fields for profiling. */
3605 if (PROFILE_MODEL_P (current_cpu))
3606 {
3607 FLD (in_Rs) = f_operand1;
3608 FLD (out_Rs) = f_operand1;
3609 }
3610 #endif
3611 #undef FLD
3612 return idesc;
3613 }
3614
3615 extract_sfmt_test_m_w_m:
3616 {
3617 const IDESC *idesc = &crisv32f_insn_data[itype];
3618 CGEN_INSN_WORD insn = base_insn;
3619 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
3620 UINT f_memmode;
3621 UINT f_operand1;
3622
3623 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3624 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3625
3626 /* Record the fields for the semantic handler. */
3627 FLD (f_operand1) = f_operand1;
3628 FLD (f_memmode) = f_memmode;
3629 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_test_m_w_m", "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3630
3631 #if WITH_PROFILE_MODEL_P
3632 /* Record the fields for profiling. */
3633 if (PROFILE_MODEL_P (current_cpu))
3634 {
3635 FLD (in_Rs) = f_operand1;
3636 FLD (out_Rs) = f_operand1;
3637 }
3638 #endif
3639 #undef FLD
3640 return idesc;
3641 }
3642
3643 extract_sfmt_test_m_d_m:
3644 {
3645 const IDESC *idesc = &crisv32f_insn_data[itype];
3646 CGEN_INSN_WORD insn = base_insn;
3647 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
3648 UINT f_memmode;
3649 UINT f_operand1;
3650
3651 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3652 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3653
3654 /* Record the fields for the semantic handler. */
3655 FLD (f_operand1) = f_operand1;
3656 FLD (f_memmode) = f_memmode;
3657 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_test_m_d_m", "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3658
3659 #if WITH_PROFILE_MODEL_P
3660 /* Record the fields for profiling. */
3661 if (PROFILE_MODEL_P (current_cpu))
3662 {
3663 FLD (in_Rs) = f_operand1;
3664 FLD (out_Rs) = f_operand1;
3665 }
3666 #endif
3667 #undef FLD
3668 return idesc;
3669 }
3670
3671 extract_sfmt_move_r_m_b_m:
3672 {
3673 const IDESC *idesc = &crisv32f_insn_data[itype];
3674 CGEN_INSN_WORD insn = base_insn;
3675 #define FLD(f) abuf->fields.sfmt_addc_m.f
3676 UINT f_operand2;
3677 UINT f_memmode;
3678 UINT f_operand1;
3679
3680 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3681 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3682 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3683
3684 /* Record the fields for the semantic handler. */
3685 FLD (f_operand2) = f_operand2;
3686 FLD (f_operand1) = f_operand1;
3687 FLD (f_memmode) = f_memmode;
3688 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_r_m_b_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3689
3690 #if WITH_PROFILE_MODEL_P
3691 /* Record the fields for profiling. */
3692 if (PROFILE_MODEL_P (current_cpu))
3693 {
3694 FLD (in_Rd) = f_operand2;
3695 FLD (in_Rs) = f_operand1;
3696 FLD (out_Rs) = f_operand1;
3697 }
3698 #endif
3699 #undef FLD
3700 return idesc;
3701 }
3702
3703 extract_sfmt_move_r_m_w_m:
3704 {
3705 const IDESC *idesc = &crisv32f_insn_data[itype];
3706 CGEN_INSN_WORD insn = base_insn;
3707 #define FLD(f) abuf->fields.sfmt_addc_m.f
3708 UINT f_operand2;
3709 UINT f_memmode;
3710 UINT f_operand1;
3711
3712 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3713 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3714 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3715
3716 /* Record the fields for the semantic handler. */
3717 FLD (f_operand2) = f_operand2;
3718 FLD (f_operand1) = f_operand1;
3719 FLD (f_memmode) = f_memmode;
3720 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_r_m_w_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3721
3722 #if WITH_PROFILE_MODEL_P
3723 /* Record the fields for profiling. */
3724 if (PROFILE_MODEL_P (current_cpu))
3725 {
3726 FLD (in_Rd) = f_operand2;
3727 FLD (in_Rs) = f_operand1;
3728 FLD (out_Rs) = f_operand1;
3729 }
3730 #endif
3731 #undef FLD
3732 return idesc;
3733 }
3734
3735 extract_sfmt_move_r_m_d_m:
3736 {
3737 const IDESC *idesc = &crisv32f_insn_data[itype];
3738 CGEN_INSN_WORD insn = base_insn;
3739 #define FLD(f) abuf->fields.sfmt_addc_m.f
3740 UINT f_operand2;
3741 UINT f_memmode;
3742 UINT f_operand1;
3743
3744 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3745 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3746 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3747
3748 /* Record the fields for the semantic handler. */
3749 FLD (f_operand2) = f_operand2;
3750 FLD (f_operand1) = f_operand1;
3751 FLD (f_memmode) = f_memmode;
3752 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_move_r_m_d_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3753
3754 #if WITH_PROFILE_MODEL_P
3755 /* Record the fields for profiling. */
3756 if (PROFILE_MODEL_P (current_cpu))
3757 {
3758 FLD (in_Rd) = f_operand2;
3759 FLD (in_Rs) = f_operand1;
3760 FLD (out_Rs) = f_operand1;
3761 }
3762 #endif
3763 #undef FLD
3764 return idesc;
3765 }
3766
3767 extract_sfmt_muls_b:
3768 {
3769 const IDESC *idesc = &crisv32f_insn_data[itype];
3770 CGEN_INSN_WORD insn = base_insn;
3771 #define FLD(f) abuf->fields.sfmt_muls_b.f
3772 UINT f_operand2;
3773 UINT f_operand1;
3774
3775 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3776 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3777
3778 /* Record the fields for the semantic handler. */
3779 FLD (f_operand2) = f_operand2;
3780 FLD (f_operand1) = f_operand1;
3781 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_muls_b", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3782
3783 #if WITH_PROFILE_MODEL_P
3784 /* Record the fields for profiling. */
3785 if (PROFILE_MODEL_P (current_cpu))
3786 {
3787 FLD (in_Rd) = f_operand2;
3788 FLD (in_Rs) = f_operand1;
3789 FLD (out_Rd) = f_operand2;
3790 FLD (out_h_sr_SI_7) = 7;
3791 }
3792 #endif
3793 #undef FLD
3794 return idesc;
3795 }
3796
3797 extract_sfmt_mcp:
3798 {
3799 const IDESC *idesc = &crisv32f_insn_data[itype];
3800 CGEN_INSN_WORD insn = base_insn;
3801 #define FLD(f) abuf->fields.sfmt_mcp.f
3802 UINT f_operand2;
3803 UINT f_operand1;
3804
3805 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3806 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3807
3808 /* Record the fields for the semantic handler. */
3809 FLD (f_operand2) = f_operand2;
3810 FLD (f_operand1) = f_operand1;
3811 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mcp", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3812
3813 #if WITH_PROFILE_MODEL_P
3814 /* Record the fields for profiling. */
3815 if (PROFILE_MODEL_P (current_cpu))
3816 {
3817 FLD (in_Ps) = f_operand2;
3818 FLD (in_Rs) = f_operand1;
3819 FLD (out_h_gr_SI_index_of__INT_Rs) = FLD (f_operand1);
3820 }
3821 #endif
3822 #undef FLD
3823 return idesc;
3824 }
3825
3826 extract_sfmt_dstep:
3827 {
3828 const IDESC *idesc = &crisv32f_insn_data[itype];
3829 CGEN_INSN_WORD insn = base_insn;
3830 #define FLD(f) abuf->fields.sfmt_muls_b.f
3831 UINT f_operand2;
3832 UINT f_operand1;
3833
3834 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3835 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3836
3837 /* Record the fields for the semantic handler. */
3838 FLD (f_operand2) = f_operand2;
3839 FLD (f_operand1) = f_operand1;
3840 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_dstep", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3841
3842 #if WITH_PROFILE_MODEL_P
3843 /* Record the fields for profiling. */
3844 if (PROFILE_MODEL_P (current_cpu))
3845 {
3846 FLD (in_Rd) = f_operand2;
3847 FLD (in_Rs) = f_operand1;
3848 FLD (out_Rd) = f_operand2;
3849 }
3850 #endif
3851 #undef FLD
3852 return idesc;
3853 }
3854
3855 extract_sfmt_and_b_r:
3856 {
3857 const IDESC *idesc = &crisv32f_insn_data[itype];
3858 CGEN_INSN_WORD insn = base_insn;
3859 #define FLD(f) abuf->fields.sfmt_addc_m.f
3860 UINT f_operand2;
3861 UINT f_operand1;
3862
3863 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3864 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3865
3866 /* Record the fields for the semantic handler. */
3867 FLD (f_operand2) = f_operand2;
3868 FLD (f_operand1) = f_operand1;
3869 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and_b_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3870
3871 #if WITH_PROFILE_MODEL_P
3872 /* Record the fields for profiling. */
3873 if (PROFILE_MODEL_P (current_cpu))
3874 {
3875 FLD (in_Rd) = f_operand2;
3876 FLD (in_Rs) = f_operand1;
3877 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3878 }
3879 #endif
3880 #undef FLD
3881 return idesc;
3882 }
3883
3884 extract_sfmt_and_d_r:
3885 {
3886 const IDESC *idesc = &crisv32f_insn_data[itype];
3887 CGEN_INSN_WORD insn = base_insn;
3888 #define FLD(f) abuf->fields.sfmt_addc_m.f
3889 UINT f_operand2;
3890 UINT f_operand1;
3891
3892 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3893 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3894
3895 /* Record the fields for the semantic handler. */
3896 FLD (f_operand2) = f_operand2;
3897 FLD (f_operand1) = f_operand1;
3898 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and_d_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
3899
3900 #if WITH_PROFILE_MODEL_P
3901 /* Record the fields for profiling. */
3902 if (PROFILE_MODEL_P (current_cpu))
3903 {
3904 FLD (in_Rd) = f_operand2;
3905 FLD (in_Rs) = f_operand1;
3906 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
3907 }
3908 #endif
3909 #undef FLD
3910 return idesc;
3911 }
3912
3913 extract_sfmt_and_m_b_m:
3914 {
3915 const IDESC *idesc = &crisv32f_insn_data[itype];
3916 CGEN_INSN_WORD insn = base_insn;
3917 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3918 UINT f_operand2;
3919 UINT f_memmode;
3920 UINT f_operand1;
3921
3922 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3923 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3924 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3925
3926 /* Record the fields for the semantic handler. */
3927 FLD (f_operand2) = f_operand2;
3928 FLD (f_operand1) = f_operand1;
3929 FLD (f_memmode) = f_memmode;
3930 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and_m_b_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3931
3932 #if WITH_PROFILE_MODEL_P
3933 /* Record the fields for profiling. */
3934 if (PROFILE_MODEL_P (current_cpu))
3935 {
3936 FLD (in_Rd) = f_operand2;
3937 FLD (in_Rs) = f_operand1;
3938 FLD (out_Rs) = f_operand1;
3939 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3940 }
3941 #endif
3942 #undef FLD
3943 return idesc;
3944 }
3945
3946 extract_sfmt_and_m_w_m:
3947 {
3948 const IDESC *idesc = &crisv32f_insn_data[itype];
3949 CGEN_INSN_WORD insn = base_insn;
3950 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3951 UINT f_operand2;
3952 UINT f_memmode;
3953 UINT f_operand1;
3954
3955 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3956 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3957 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3958
3959 /* Record the fields for the semantic handler. */
3960 FLD (f_operand2) = f_operand2;
3961 FLD (f_operand1) = f_operand1;
3962 FLD (f_memmode) = f_memmode;
3963 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and_m_w_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3964
3965 #if WITH_PROFILE_MODEL_P
3966 /* Record the fields for profiling. */
3967 if (PROFILE_MODEL_P (current_cpu))
3968 {
3969 FLD (in_Rd) = f_operand2;
3970 FLD (in_Rs) = f_operand1;
3971 FLD (out_Rs) = f_operand1;
3972 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
3973 }
3974 #endif
3975 #undef FLD
3976 return idesc;
3977 }
3978
3979 extract_sfmt_and_m_d_m:
3980 {
3981 const IDESC *idesc = &crisv32f_insn_data[itype];
3982 CGEN_INSN_WORD insn = base_insn;
3983 #define FLD(f) abuf->fields.sfmt_add_m_b_m.f
3984 UINT f_operand2;
3985 UINT f_memmode;
3986 UINT f_operand1;
3987
3988 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
3989 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
3990 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
3991
3992 /* Record the fields for the semantic handler. */
3993 FLD (f_operand2) = f_operand2;
3994 FLD (f_operand1) = f_operand1;
3995 FLD (f_memmode) = f_memmode;
3996 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and_m_d_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
3997
3998 #if WITH_PROFILE_MODEL_P
3999 /* Record the fields for profiling. */
4000 if (PROFILE_MODEL_P (current_cpu))
4001 {
4002 FLD (in_Rd) = f_operand2;
4003 FLD (in_Rs) = f_operand1;
4004 FLD (out_Rs) = f_operand1;
4005 FLD (out_h_gr_SI_if__SI_andif__DFLT_prefix_set_not__UINT_inc_index_of__INT_Rs_index_of__INT_Rd) = ((ANDIF (GET_H_INSN_PREFIXED_P (), (! (FLD (f_memmode))))) ? (FLD (f_operand1)) : (FLD (f_operand2)));
4006 }
4007 #endif
4008 #undef FLD
4009 return idesc;
4010 }
4011
4012 extract_sfmt_andcbr:
4013 {
4014 const IDESC *idesc = &crisv32f_insn_data[itype];
4015 CGEN_INSN_WORD insn = base_insn;
4016 #define FLD(f) abuf->fields.sfmt_addcbr.f
4017 INT f_indir_pc__byte;
4018 UINT f_operand2;
4019 /* Contents of trailing part of insn. */
4020 UINT word_1;
4021
4022 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4023 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
4024 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4025
4026 /* Record the fields for the semantic handler. */
4027 FLD (f_operand2) = f_operand2;
4028 FLD (f_indir_pc__byte) = f_indir_pc__byte;
4029 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andcbr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
4030
4031 #if WITH_PROFILE_MODEL_P
4032 /* Record the fields for profiling. */
4033 if (PROFILE_MODEL_P (current_cpu))
4034 {
4035 FLD (in_Rd) = f_operand2;
4036 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
4037 }
4038 #endif
4039 #undef FLD
4040 return idesc;
4041 }
4042
4043 extract_sfmt_andcwr:
4044 {
4045 const IDESC *idesc = &crisv32f_insn_data[itype];
4046 CGEN_INSN_WORD insn = base_insn;
4047 #define FLD(f) abuf->fields.sfmt_addcwr.f
4048 INT f_indir_pc__word;
4049 UINT f_operand2;
4050 /* Contents of trailing part of insn. */
4051 UINT word_1;
4052
4053 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4054 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
4055 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4056
4057 /* Record the fields for the semantic handler. */
4058 FLD (f_operand2) = f_operand2;
4059 FLD (f_indir_pc__word) = f_indir_pc__word;
4060 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andcwr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
4061
4062 #if WITH_PROFILE_MODEL_P
4063 /* Record the fields for profiling. */
4064 if (PROFILE_MODEL_P (current_cpu))
4065 {
4066 FLD (in_Rd) = f_operand2;
4067 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
4068 }
4069 #endif
4070 #undef FLD
4071 return idesc;
4072 }
4073
4074 extract_sfmt_andcdr:
4075 {
4076 const IDESC *idesc = &crisv32f_insn_data[itype];
4077 CGEN_INSN_WORD insn = base_insn;
4078 #define FLD(f) abuf->fields.sfmt_addcdr.f
4079 INT f_indir_pc__dword;
4080 UINT f_operand2;
4081 /* Contents of trailing part of insn. */
4082 UINT word_1;
4083
4084 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4085 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
4086 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4087
4088 /* Record the fields for the semantic handler. */
4089 FLD (f_operand2) = f_operand2;
4090 FLD (f_indir_pc__dword) = f_indir_pc__dword;
4091 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andcdr", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, (char *) 0));
4092
4093 #if WITH_PROFILE_MODEL_P
4094 /* Record the fields for profiling. */
4095 if (PROFILE_MODEL_P (current_cpu))
4096 {
4097 FLD (in_Rd) = f_operand2;
4098 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
4099 }
4100 #endif
4101 #undef FLD
4102 return idesc;
4103 }
4104
4105 extract_sfmt_andq:
4106 {
4107 const IDESC *idesc = &crisv32f_insn_data[itype];
4108 CGEN_INSN_WORD insn = base_insn;
4109 #define FLD(f) abuf->fields.sfmt_andq.f
4110 UINT f_operand2;
4111 INT f_s6;
4112
4113 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4114 f_s6 = EXTRACT_LSB0_SINT (insn, 16, 5, 6);
4115
4116 /* Record the fields for the semantic handler. */
4117 FLD (f_operand2) = f_operand2;
4118 FLD (f_s6) = f_s6;
4119 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_andq", "f_operand2 0x%x", 'x', f_operand2, "f_s6 0x%x", 'x', f_s6, (char *) 0));
4120
4121 #if WITH_PROFILE_MODEL_P
4122 /* Record the fields for profiling. */
4123 if (PROFILE_MODEL_P (current_cpu))
4124 {
4125 FLD (in_Rd) = f_operand2;
4126 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
4127 }
4128 #endif
4129 #undef FLD
4130 return idesc;
4131 }
4132
4133 extract_sfmt_swap:
4134 {
4135 const IDESC *idesc = &crisv32f_insn_data[itype];
4136 CGEN_INSN_WORD insn = base_insn;
4137 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
4138 UINT f_operand2;
4139 UINT f_operand1;
4140
4141 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4142 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4143
4144 /* Record the fields for the semantic handler. */
4145 FLD (f_operand1) = f_operand1;
4146 FLD (f_operand2) = f_operand2;
4147 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_swap", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
4148
4149 #if WITH_PROFILE_MODEL_P
4150 /* Record the fields for profiling. */
4151 if (PROFILE_MODEL_P (current_cpu))
4152 {
4153 FLD (in_Rs) = f_operand1;
4154 FLD (out_Rs) = f_operand1;
4155 }
4156 #endif
4157 #undef FLD
4158 return idesc;
4159 }
4160
4161 extract_sfmt_asrq:
4162 {
4163 const IDESC *idesc = &crisv32f_insn_data[itype];
4164 CGEN_INSN_WORD insn = base_insn;
4165 #define FLD(f) abuf->fields.sfmt_asrq.f
4166 UINT f_operand2;
4167 UINT f_u5;
4168
4169 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4170 f_u5 = EXTRACT_LSB0_UINT (insn, 16, 4, 5);
4171
4172 /* Record the fields for the semantic handler. */
4173 FLD (f_operand2) = f_operand2;
4174 FLD (f_u5) = f_u5;
4175 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_asrq", "f_operand2 0x%x", 'x', f_operand2, "f_u5 0x%x", 'x', f_u5, (char *) 0));
4176
4177 #if WITH_PROFILE_MODEL_P
4178 /* Record the fields for profiling. */
4179 if (PROFILE_MODEL_P (current_cpu))
4180 {
4181 FLD (in_Rd) = f_operand2;
4182 FLD (out_Rd) = f_operand2;
4183 }
4184 #endif
4185 #undef FLD
4186 return idesc;
4187 }
4188
4189 extract_sfmt_lsrr_b_r:
4190 {
4191 const IDESC *idesc = &crisv32f_insn_data[itype];
4192 CGEN_INSN_WORD insn = base_insn;
4193 #define FLD(f) abuf->fields.sfmt_addc_m.f
4194 UINT f_operand2;
4195 UINT f_operand1;
4196
4197 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4198 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4199
4200 /* Record the fields for the semantic handler. */
4201 FLD (f_operand2) = f_operand2;
4202 FLD (f_operand1) = f_operand1;
4203 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lsrr_b_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
4204
4205 #if WITH_PROFILE_MODEL_P
4206 /* Record the fields for profiling. */
4207 if (PROFILE_MODEL_P (current_cpu))
4208 {
4209 FLD (in_Rd) = f_operand2;
4210 FLD (in_Rs) = f_operand1;
4211 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
4212 }
4213 #endif
4214 #undef FLD
4215 return idesc;
4216 }
4217
4218 extract_sfmt_lsrr_d_r:
4219 {
4220 const IDESC *idesc = &crisv32f_insn_data[itype];
4221 CGEN_INSN_WORD insn = base_insn;
4222 #define FLD(f) abuf->fields.sfmt_addc_m.f
4223 UINT f_operand2;
4224 UINT f_operand1;
4225
4226 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4227 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4228
4229 /* Record the fields for the semantic handler. */
4230 FLD (f_operand2) = f_operand2;
4231 FLD (f_operand1) = f_operand1;
4232 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lsrr_d_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
4233
4234 #if WITH_PROFILE_MODEL_P
4235 /* Record the fields for profiling. */
4236 if (PROFILE_MODEL_P (current_cpu))
4237 {
4238 FLD (in_Rd) = f_operand2;
4239 FLD (in_Rs) = f_operand1;
4240 FLD (out_h_gr_SI_index_of__INT_Rd) = FLD (f_operand2);
4241 }
4242 #endif
4243 #undef FLD
4244 return idesc;
4245 }
4246
4247 extract_sfmt_btst:
4248 {
4249 const IDESC *idesc = &crisv32f_insn_data[itype];
4250 CGEN_INSN_WORD insn = base_insn;
4251 #define FLD(f) abuf->fields.sfmt_muls_b.f
4252 UINT f_operand2;
4253 UINT f_operand1;
4254
4255 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4256 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4257
4258 /* Record the fields for the semantic handler. */
4259 FLD (f_operand2) = f_operand2;
4260 FLD (f_operand1) = f_operand1;
4261 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_btst", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
4262
4263 #if WITH_PROFILE_MODEL_P
4264 /* Record the fields for profiling. */
4265 if (PROFILE_MODEL_P (current_cpu))
4266 {
4267 FLD (in_Rd) = f_operand2;
4268 FLD (in_Rs) = f_operand1;
4269 }
4270 #endif
4271 #undef FLD
4272 return idesc;
4273 }
4274
4275 extract_sfmt_btstq:
4276 {
4277 const IDESC *idesc = &crisv32f_insn_data[itype];
4278 CGEN_INSN_WORD insn = base_insn;
4279 #define FLD(f) abuf->fields.sfmt_asrq.f
4280 UINT f_operand2;
4281 UINT f_u5;
4282
4283 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4284 f_u5 = EXTRACT_LSB0_UINT (insn, 16, 4, 5);
4285
4286 /* Record the fields for the semantic handler. */
4287 FLD (f_operand2) = f_operand2;
4288 FLD (f_u5) = f_u5;
4289 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_btstq", "f_operand2 0x%x", 'x', f_operand2, "f_u5 0x%x", 'x', f_u5, (char *) 0));
4290
4291 #if WITH_PROFILE_MODEL_P
4292 /* Record the fields for profiling. */
4293 if (PROFILE_MODEL_P (current_cpu))
4294 {
4295 FLD (in_Rd) = f_operand2;
4296 }
4297 #endif
4298 #undef FLD
4299 return idesc;
4300 }
4301
4302 extract_sfmt_setf:
4303 {
4304 const IDESC *idesc = &crisv32f_insn_data[itype];
4305 CGEN_INSN_WORD insn = base_insn;
4306 #define FLD(f) abuf->fields.sfmt_setf.f
4307 UINT f_operand2;
4308 UINT f_operand1;
4309 UINT f_dstsrc;
4310
4311 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4312 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4313 f_dstsrc = ((((f_operand1) | (((f_operand2) << (4))))) & (255));
4314
4315 /* Record the fields for the semantic handler. */
4316 FLD (f_dstsrc) = f_dstsrc;
4317 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_setf", "f_dstsrc 0x%x", 'x', f_dstsrc, (char *) 0));
4318
4319 #undef FLD
4320 return idesc;
4321 }
4322
4323 extract_sfmt_rfe:
4324 {
4325 const IDESC *idesc = &crisv32f_insn_data[itype];
4326 #define FLD(f) abuf->fields.sfmt_rfe.f
4327
4328
4329 /* Record the fields for the semantic handler. */
4330 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_rfe", (char *) 0));
4331
4332 #if WITH_PROFILE_MODEL_P
4333 /* Record the fields for profiling. */
4334 if (PROFILE_MODEL_P (current_cpu))
4335 {
4336 FLD (in_h_sr_SI_13) = 13;
4337 FLD (out_h_sr_SI_13) = 13;
4338 }
4339 #endif
4340 #undef FLD
4341 return idesc;
4342 }
4343
4344 extract_sfmt_sfe:
4345 {
4346 const IDESC *idesc = &crisv32f_insn_data[itype];
4347 #define FLD(f) abuf->fields.sfmt_rfe.f
4348
4349
4350 /* Record the fields for the semantic handler. */
4351 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_sfe", (char *) 0));
4352
4353 #if WITH_PROFILE_MODEL_P
4354 /* Record the fields for profiling. */
4355 if (PROFILE_MODEL_P (current_cpu))
4356 {
4357 FLD (in_h_sr_SI_13) = 13;
4358 FLD (out_h_sr_SI_13) = 13;
4359 }
4360 #endif
4361 #undef FLD
4362 return idesc;
4363 }
4364
4365 extract_sfmt_rfg:
4366 {
4367 const IDESC *idesc = &crisv32f_insn_data[itype];
4368 #define FLD(f) abuf->fields.sfmt_empty.f
4369
4370
4371 /* Record the fields for the semantic handler. */
4372 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_rfg", (char *) 0));
4373
4374 #if WITH_PROFILE_MODEL_P
4375 /* Record the fields for profiling. */
4376 if (PROFILE_MODEL_P (current_cpu))
4377 {
4378 }
4379 #endif
4380 #undef FLD
4381 return idesc;
4382 }
4383
4384 extract_sfmt_rfn:
4385 {
4386 const IDESC *idesc = &crisv32f_insn_data[itype];
4387 #define FLD(f) abuf->fields.sfmt_rfe.f
4388
4389
4390 /* Record the fields for the semantic handler. */
4391 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_rfn", (char *) 0));
4392
4393 #if WITH_PROFILE_MODEL_P
4394 /* Record the fields for profiling. */
4395 if (PROFILE_MODEL_P (current_cpu))
4396 {
4397 FLD (in_h_sr_SI_13) = 13;
4398 FLD (out_h_sr_SI_13) = 13;
4399 }
4400 #endif
4401 #undef FLD
4402 return idesc;
4403 }
4404
4405 extract_sfmt_halt:
4406 {
4407 const IDESC *idesc = &crisv32f_insn_data[itype];
4408 #define FLD(f) abuf->fields.sfmt_empty.f
4409
4410
4411 /* Record the fields for the semantic handler. */
4412 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_halt", (char *) 0));
4413
4414 #if WITH_PROFILE_MODEL_P
4415 /* Record the fields for profiling. */
4416 if (PROFILE_MODEL_P (current_cpu))
4417 {
4418 }
4419 #endif
4420 #undef FLD
4421 return idesc;
4422 }
4423
4424 extract_sfmt_bcc_b:
4425 {
4426 const IDESC *idesc = &crisv32f_insn_data[itype];
4427 CGEN_INSN_WORD insn = base_insn;
4428 #define FLD(f) abuf->fields.sfmt_bcc_b.f
4429 UINT f_operand2;
4430 UINT f_disp9_lo;
4431 INT f_disp9_hi;
4432 INT f_disp9;
4433
4434 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4435 f_disp9_lo = EXTRACT_LSB0_UINT (insn, 16, 7, 7);
4436 f_disp9_hi = EXTRACT_LSB0_SINT (insn, 16, 0, 1);
4437 {
4438 SI tmp_abslo;
4439 SI tmp_absval;
4440 tmp_abslo = ((f_disp9_lo) << (1));
4441 tmp_absval = ((((((f_disp9_hi) != (0))) ? ((~ (255))) : (0))) | (tmp_abslo));
4442 f_disp9 = ((((pc) + (tmp_absval))) + (((GET_H_V32_V32 ()) ? (0) : (2))));
4443 }
4444
4445 /* Record the fields for the semantic handler. */
4446 FLD (f_operand2) = f_operand2;
4447 FLD (i_o_pcrel) = f_disp9;
4448 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bcc_b", "f_operand2 0x%x", 'x', f_operand2, "o_pcrel 0x%x", 'x', f_disp9, (char *) 0));
4449
4450 #if WITH_PROFILE_MODEL_P
4451 /* Record the fields for profiling. */
4452 if (PROFILE_MODEL_P (current_cpu))
4453 {
4454 }
4455 #endif
4456 #undef FLD
4457 return idesc;
4458 }
4459
4460 extract_sfmt_ba_b:
4461 {
4462 const IDESC *idesc = &crisv32f_insn_data[itype];
4463 CGEN_INSN_WORD insn = base_insn;
4464 #define FLD(f) abuf->fields.sfmt_bcc_b.f
4465 UINT f_disp9_lo;
4466 INT f_disp9_hi;
4467 INT f_disp9;
4468
4469 f_disp9_lo = EXTRACT_LSB0_UINT (insn, 16, 7, 7);
4470 f_disp9_hi = EXTRACT_LSB0_SINT (insn, 16, 0, 1);
4471 {
4472 SI tmp_abslo;
4473 SI tmp_absval;
4474 tmp_abslo = ((f_disp9_lo) << (1));
4475 tmp_absval = ((((((f_disp9_hi) != (0))) ? ((~ (255))) : (0))) | (tmp_abslo));
4476 f_disp9 = ((((pc) + (tmp_absval))) + (((GET_H_V32_V32 ()) ? (0) : (2))));
4477 }
4478
4479 /* Record the fields for the semantic handler. */
4480 FLD (i_o_pcrel) = f_disp9;
4481 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ba_b", "o_pcrel 0x%x", 'x', f_disp9, (char *) 0));
4482
4483 #if WITH_PROFILE_MODEL_P
4484 /* Record the fields for profiling. */
4485 if (PROFILE_MODEL_P (current_cpu))
4486 {
4487 }
4488 #endif
4489 #undef FLD
4490 return idesc;
4491 }
4492
4493 extract_sfmt_bcc_w:
4494 {
4495 const IDESC *idesc = &crisv32f_insn_data[itype];
4496 CGEN_INSN_WORD insn = base_insn;
4497 #define FLD(f) abuf->fields.sfmt_bcc_w.f
4498 SI f_indir_pc__word_pcrel;
4499 UINT f_operand2;
4500 /* Contents of trailing part of insn. */
4501 UINT word_1;
4502
4503 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4504 f_indir_pc__word_pcrel = ((EXTHISI (((HI) (UINT) ((0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0)))))) + (((pc) + (((GET_H_V32_V32 ()) ? (0) : (4))))));
4505 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4506
4507 /* Record the fields for the semantic handler. */
4508 FLD (f_operand2) = f_operand2;
4509 FLD (i_o_word_pcrel) = f_indir_pc__word_pcrel;
4510 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bcc_w", "f_operand2 0x%x", 'x', f_operand2, "o_word_pcrel 0x%x", 'x', f_indir_pc__word_pcrel, (char *) 0));
4511
4512 #if WITH_PROFILE_MODEL_P
4513 /* Record the fields for profiling. */
4514 if (PROFILE_MODEL_P (current_cpu))
4515 {
4516 }
4517 #endif
4518 #undef FLD
4519 return idesc;
4520 }
4521
4522 extract_sfmt_ba_w:
4523 {
4524 const IDESC *idesc = &crisv32f_insn_data[itype];
4525 CGEN_INSN_WORD insn = base_insn;
4526 #define FLD(f) abuf->fields.sfmt_bcc_w.f
4527 SI f_indir_pc__word_pcrel;
4528 /* Contents of trailing part of insn. */
4529 UINT word_1;
4530
4531 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4532 f_indir_pc__word_pcrel = ((EXTHISI (((HI) (UINT) ((0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0)))))) + (((pc) + (((GET_H_V32_V32 ()) ? (0) : (4))))));
4533
4534 /* Record the fields for the semantic handler. */
4535 FLD (i_o_word_pcrel) = f_indir_pc__word_pcrel;
4536 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ba_w", "o_word_pcrel 0x%x", 'x', f_indir_pc__word_pcrel, (char *) 0));
4537
4538 #if WITH_PROFILE_MODEL_P
4539 /* Record the fields for profiling. */
4540 if (PROFILE_MODEL_P (current_cpu))
4541 {
4542 }
4543 #endif
4544 #undef FLD
4545 return idesc;
4546 }
4547
4548 extract_sfmt_jas_r:
4549 {
4550 const IDESC *idesc = &crisv32f_insn_data[itype];
4551 CGEN_INSN_WORD insn = base_insn;
4552 #define FLD(f) abuf->fields.sfmt_move_m_sprv32.f
4553 UINT f_operand2;
4554 UINT f_operand1;
4555
4556 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4557 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4558
4559 /* Record the fields for the semantic handler. */
4560 FLD (f_operand1) = f_operand1;
4561 FLD (f_operand2) = f_operand2;
4562 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jas_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
4563
4564 #if WITH_PROFILE_MODEL_P
4565 /* Record the fields for profiling. */
4566 if (PROFILE_MODEL_P (current_cpu))
4567 {
4568 FLD (in_Rs) = f_operand1;
4569 FLD (out_Pd) = f_operand2;
4570 }
4571 #endif
4572 #undef FLD
4573 return idesc;
4574 }
4575
4576 extract_sfmt_jas_c:
4577 {
4578 const IDESC *idesc = &crisv32f_insn_data[itype];
4579 CGEN_INSN_WORD insn = base_insn;
4580 #define FLD(f) abuf->fields.sfmt_move_c_sprv32_p2.f
4581 INT f_indir_pc__dword;
4582 UINT f_operand2;
4583 /* Contents of trailing part of insn. */
4584 UINT word_1;
4585
4586 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4587 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
4588 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4589
4590 /* Record the fields for the semantic handler. */
4591 FLD (f_indir_pc__dword) = f_indir_pc__dword;
4592 FLD (f_operand2) = f_operand2;
4593 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jas_c", "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
4594
4595 #if WITH_PROFILE_MODEL_P
4596 /* Record the fields for profiling. */
4597 if (PROFILE_MODEL_P (current_cpu))
4598 {
4599 FLD (out_Pd) = f_operand2;
4600 }
4601 #endif
4602 #undef FLD
4603 return idesc;
4604 }
4605
4606 extract_sfmt_jump_p:
4607 {
4608 const IDESC *idesc = &crisv32f_insn_data[itype];
4609 CGEN_INSN_WORD insn = base_insn;
4610 #define FLD(f) abuf->fields.sfmt_mcp.f
4611 UINT f_operand2;
4612
4613 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4614
4615 /* Record the fields for the semantic handler. */
4616 FLD (f_operand2) = f_operand2;
4617 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jump_p", "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
4618
4619 #if WITH_PROFILE_MODEL_P
4620 /* Record the fields for profiling. */
4621 if (PROFILE_MODEL_P (current_cpu))
4622 {
4623 FLD (in_Ps) = f_operand2;
4624 }
4625 #endif
4626 #undef FLD
4627 return idesc;
4628 }
4629
4630 extract_sfmt_bas_c:
4631 {
4632 const IDESC *idesc = &crisv32f_insn_data[itype];
4633 CGEN_INSN_WORD insn = base_insn;
4634 #define FLD(f) abuf->fields.sfmt_bas_c.f
4635 SI f_indir_pc__dword_pcrel;
4636 UINT f_operand2;
4637 /* Contents of trailing part of insn. */
4638 UINT word_1;
4639
4640 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4641 f_indir_pc__dword_pcrel = ((pc) + ((0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0))));
4642 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4643
4644 /* Record the fields for the semantic handler. */
4645 FLD (f_operand2) = f_operand2;
4646 FLD (i_const32_pcrel) = f_indir_pc__dword_pcrel;
4647 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bas_c", "f_operand2 0x%x", 'x', f_operand2, "const32_pcrel 0x%x", 'x', f_indir_pc__dword_pcrel, (char *) 0));
4648
4649 #if WITH_PROFILE_MODEL_P
4650 /* Record the fields for profiling. */
4651 if (PROFILE_MODEL_P (current_cpu))
4652 {
4653 FLD (out_Pd) = f_operand2;
4654 }
4655 #endif
4656 #undef FLD
4657 return idesc;
4658 }
4659
4660 extract_sfmt_jasc_r:
4661 {
4662 const IDESC *idesc = &crisv32f_insn_data[itype];
4663 CGEN_INSN_WORD insn = base_insn;
4664 #define FLD(f) abuf->fields.sfmt_move_m_sprv32.f
4665 UINT f_operand2;
4666 UINT f_operand1;
4667
4668 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4669 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4670
4671 /* Record the fields for the semantic handler. */
4672 FLD (f_operand1) = f_operand1;
4673 FLD (f_operand2) = f_operand2;
4674 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jasc_r", "f_operand1 0x%x", 'x', f_operand1, "f_operand2 0x%x", 'x', f_operand2, (char *) 0));
4675
4676 #if WITH_PROFILE_MODEL_P
4677 /* Record the fields for profiling. */
4678 if (PROFILE_MODEL_P (current_cpu))
4679 {
4680 FLD (in_Rs) = f_operand1;
4681 FLD (out_Pd) = f_operand2;
4682 }
4683 #endif
4684 #undef FLD
4685 return idesc;
4686 }
4687
4688 extract_sfmt_break:
4689 {
4690 const IDESC *idesc = &crisv32f_insn_data[itype];
4691 CGEN_INSN_WORD insn = base_insn;
4692 #define FLD(f) abuf->fields.sfmt_break.f
4693 UINT f_u4;
4694
4695 f_u4 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4696
4697 /* Record the fields for the semantic handler. */
4698 FLD (f_u4) = f_u4;
4699 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_break", "f_u4 0x%x", 'x', f_u4, (char *) 0));
4700
4701 #if WITH_PROFILE_MODEL_P
4702 /* Record the fields for profiling. */
4703 if (PROFILE_MODEL_P (current_cpu))
4704 {
4705 }
4706 #endif
4707 #undef FLD
4708 return idesc;
4709 }
4710
4711 extract_sfmt_bound_cb:
4712 {
4713 const IDESC *idesc = &crisv32f_insn_data[itype];
4714 CGEN_INSN_WORD insn = base_insn;
4715 #define FLD(f) abuf->fields.sfmt_bound_cb.f
4716 INT f_indir_pc__byte;
4717 UINT f_operand2;
4718 /* Contents of trailing part of insn. */
4719 UINT word_1;
4720
4721 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4722 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
4723 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4724
4725 /* Record the fields for the semantic handler. */
4726 FLD (f_operand2) = f_operand2;
4727 FLD (f_indir_pc__byte) = f_indir_pc__byte;
4728 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bound_cb", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
4729
4730 #if WITH_PROFILE_MODEL_P
4731 /* Record the fields for profiling. */
4732 if (PROFILE_MODEL_P (current_cpu))
4733 {
4734 FLD (in_Rd) = f_operand2;
4735 FLD (out_Rd) = f_operand2;
4736 }
4737 #endif
4738 #undef FLD
4739 return idesc;
4740 }
4741
4742 extract_sfmt_bound_cw:
4743 {
4744 const IDESC *idesc = &crisv32f_insn_data[itype];
4745 CGEN_INSN_WORD insn = base_insn;
4746 #define FLD(f) abuf->fields.sfmt_bound_cw.f
4747 INT f_indir_pc__word;
4748 UINT f_operand2;
4749 /* Contents of trailing part of insn. */
4750 UINT word_1;
4751
4752 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4753 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
4754 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4755
4756 /* Record the fields for the semantic handler. */
4757 FLD (f_operand2) = f_operand2;
4758 FLD (f_indir_pc__word) = f_indir_pc__word;
4759 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bound_cw", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
4760
4761 #if WITH_PROFILE_MODEL_P
4762 /* Record the fields for profiling. */
4763 if (PROFILE_MODEL_P (current_cpu))
4764 {
4765 FLD (in_Rd) = f_operand2;
4766 FLD (out_Rd) = f_operand2;
4767 }
4768 #endif
4769 #undef FLD
4770 return idesc;
4771 }
4772
4773 extract_sfmt_bound_cd:
4774 {
4775 const IDESC *idesc = &crisv32f_insn_data[itype];
4776 CGEN_INSN_WORD insn = base_insn;
4777 #define FLD(f) abuf->fields.sfmt_bound_cd.f
4778 INT f_indir_pc__dword;
4779 UINT f_operand2;
4780 /* Contents of trailing part of insn. */
4781 UINT word_1;
4782
4783 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4784 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
4785 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4786
4787 /* Record the fields for the semantic handler. */
4788 FLD (f_operand2) = f_operand2;
4789 FLD (f_indir_pc__dword) = f_indir_pc__dword;
4790 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bound_cd", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, (char *) 0));
4791
4792 #if WITH_PROFILE_MODEL_P
4793 /* Record the fields for profiling. */
4794 if (PROFILE_MODEL_P (current_cpu))
4795 {
4796 FLD (in_Rd) = f_operand2;
4797 FLD (out_Rd) = f_operand2;
4798 }
4799 #endif
4800 #undef FLD
4801 return idesc;
4802 }
4803
4804 extract_sfmt_scc:
4805 {
4806 const IDESC *idesc = &crisv32f_insn_data[itype];
4807 CGEN_INSN_WORD insn = base_insn;
4808 #define FLD(f) abuf->fields.sfmt_move_spr_mv32.f
4809 UINT f_operand2;
4810 UINT f_operand1;
4811
4812 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4813 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4814
4815 /* Record the fields for the semantic handler. */
4816 FLD (f_operand2) = f_operand2;
4817 FLD (f_operand1) = f_operand1;
4818 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_scc", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
4819
4820 #if WITH_PROFILE_MODEL_P
4821 /* Record the fields for profiling. */
4822 if (PROFILE_MODEL_P (current_cpu))
4823 {
4824 FLD (out_Rs) = f_operand1;
4825 }
4826 #endif
4827 #undef FLD
4828 return idesc;
4829 }
4830
4831 extract_sfmt_addoq:
4832 {
4833 const IDESC *idesc = &crisv32f_insn_data[itype];
4834 CGEN_INSN_WORD insn = base_insn;
4835 #define FLD(f) abuf->fields.sfmt_addoq.f
4836 UINT f_operand2;
4837 INT f_s8;
4838
4839 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4840 f_s8 = EXTRACT_LSB0_SINT (insn, 16, 7, 8);
4841
4842 /* Record the fields for the semantic handler. */
4843 FLD (f_operand2) = f_operand2;
4844 FLD (f_s8) = f_s8;
4845 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addoq", "f_operand2 0x%x", 'x', f_operand2, "f_s8 0x%x", 'x', f_s8, (char *) 0));
4846
4847 #if WITH_PROFILE_MODEL_P
4848 /* Record the fields for profiling. */
4849 if (PROFILE_MODEL_P (current_cpu))
4850 {
4851 FLD (in_Rd) = f_operand2;
4852 }
4853 #endif
4854 #undef FLD
4855 return idesc;
4856 }
4857
4858 extract_sfmt_addo_m_b_m:
4859 {
4860 const IDESC *idesc = &crisv32f_insn_data[itype];
4861 CGEN_INSN_WORD insn = base_insn;
4862 #define FLD(f) abuf->fields.sfmt_addc_m.f
4863 UINT f_operand2;
4864 UINT f_memmode;
4865 UINT f_operand1;
4866
4867 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4868 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
4869 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4870
4871 /* Record the fields for the semantic handler. */
4872 FLD (f_operand2) = f_operand2;
4873 FLD (f_operand1) = f_operand1;
4874 FLD (f_memmode) = f_memmode;
4875 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addo_m_b_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
4876
4877 #if WITH_PROFILE_MODEL_P
4878 /* Record the fields for profiling. */
4879 if (PROFILE_MODEL_P (current_cpu))
4880 {
4881 FLD (in_Rd) = f_operand2;
4882 FLD (in_Rs) = f_operand1;
4883 FLD (out_Rs) = f_operand1;
4884 }
4885 #endif
4886 #undef FLD
4887 return idesc;
4888 }
4889
4890 extract_sfmt_addo_m_w_m:
4891 {
4892 const IDESC *idesc = &crisv32f_insn_data[itype];
4893 CGEN_INSN_WORD insn = base_insn;
4894 #define FLD(f) abuf->fields.sfmt_addc_m.f
4895 UINT f_operand2;
4896 UINT f_memmode;
4897 UINT f_operand1;
4898
4899 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4900 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
4901 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4902
4903 /* Record the fields for the semantic handler. */
4904 FLD (f_operand2) = f_operand2;
4905 FLD (f_operand1) = f_operand1;
4906 FLD (f_memmode) = f_memmode;
4907 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addo_m_w_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
4908
4909 #if WITH_PROFILE_MODEL_P
4910 /* Record the fields for profiling. */
4911 if (PROFILE_MODEL_P (current_cpu))
4912 {
4913 FLD (in_Rd) = f_operand2;
4914 FLD (in_Rs) = f_operand1;
4915 FLD (out_Rs) = f_operand1;
4916 }
4917 #endif
4918 #undef FLD
4919 return idesc;
4920 }
4921
4922 extract_sfmt_addo_m_d_m:
4923 {
4924 const IDESC *idesc = &crisv32f_insn_data[itype];
4925 CGEN_INSN_WORD insn = base_insn;
4926 #define FLD(f) abuf->fields.sfmt_addc_m.f
4927 UINT f_operand2;
4928 UINT f_memmode;
4929 UINT f_operand1;
4930
4931 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4932 f_memmode = EXTRACT_LSB0_UINT (insn, 16, 10, 1);
4933 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
4934
4935 /* Record the fields for the semantic handler. */
4936 FLD (f_operand2) = f_operand2;
4937 FLD (f_operand1) = f_operand1;
4938 FLD (f_memmode) = f_memmode;
4939 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addo_m_d_m", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, "f_memmode 0x%x", 'x', f_memmode, (char *) 0));
4940
4941 #if WITH_PROFILE_MODEL_P
4942 /* Record the fields for profiling. */
4943 if (PROFILE_MODEL_P (current_cpu))
4944 {
4945 FLD (in_Rd) = f_operand2;
4946 FLD (in_Rs) = f_operand1;
4947 FLD (out_Rs) = f_operand1;
4948 }
4949 #endif
4950 #undef FLD
4951 return idesc;
4952 }
4953
4954 extract_sfmt_addo_cb:
4955 {
4956 const IDESC *idesc = &crisv32f_insn_data[itype];
4957 CGEN_INSN_WORD insn = base_insn;
4958 #define FLD(f) abuf->fields.sfmt_bound_cb.f
4959 INT f_indir_pc__byte;
4960 UINT f_operand2;
4961 /* Contents of trailing part of insn. */
4962 UINT word_1;
4963
4964 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4965 f_indir_pc__byte = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
4966 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4967
4968 /* Record the fields for the semantic handler. */
4969 FLD (f_operand2) = f_operand2;
4970 FLD (f_indir_pc__byte) = f_indir_pc__byte;
4971 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addo_cb", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__byte 0x%x", 'x', f_indir_pc__byte, (char *) 0));
4972
4973 #if WITH_PROFILE_MODEL_P
4974 /* Record the fields for profiling. */
4975 if (PROFILE_MODEL_P (current_cpu))
4976 {
4977 FLD (in_Rd) = f_operand2;
4978 }
4979 #endif
4980 #undef FLD
4981 return idesc;
4982 }
4983
4984 extract_sfmt_addo_cw:
4985 {
4986 const IDESC *idesc = &crisv32f_insn_data[itype];
4987 CGEN_INSN_WORD insn = base_insn;
4988 #define FLD(f) abuf->fields.sfmt_bound_cw.f
4989 INT f_indir_pc__word;
4990 UINT f_operand2;
4991 /* Contents of trailing part of insn. */
4992 UINT word_1;
4993
4994 word_1 = GETIMEMUSI (current_cpu, pc + 2);
4995 f_indir_pc__word = (0|(EXTRACT_LSB0_UINT (word_1, 32, 15, 16) << 0));
4996 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
4997
4998 /* Record the fields for the semantic handler. */
4999 FLD (f_operand2) = f_operand2;
5000 FLD (f_indir_pc__word) = f_indir_pc__word;
5001 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addo_cw", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__word 0x%x", 'x', f_indir_pc__word, (char *) 0));
5002
5003 #if WITH_PROFILE_MODEL_P
5004 /* Record the fields for profiling. */
5005 if (PROFILE_MODEL_P (current_cpu))
5006 {
5007 FLD (in_Rd) = f_operand2;
5008 }
5009 #endif
5010 #undef FLD
5011 return idesc;
5012 }
5013
5014 extract_sfmt_addo_cd:
5015 {
5016 const IDESC *idesc = &crisv32f_insn_data[itype];
5017 CGEN_INSN_WORD insn = base_insn;
5018 #define FLD(f) abuf->fields.sfmt_bound_cd.f
5019 INT f_indir_pc__dword;
5020 UINT f_operand2;
5021 /* Contents of trailing part of insn. */
5022 UINT word_1;
5023
5024 word_1 = GETIMEMUSI (current_cpu, pc + 2);
5025 f_indir_pc__dword = (0|(EXTRACT_LSB0_UINT (word_1, 32, 31, 32) << 0));
5026 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
5027
5028 /* Record the fields for the semantic handler. */
5029 FLD (f_operand2) = f_operand2;
5030 FLD (f_indir_pc__dword) = f_indir_pc__dword;
5031 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addo_cd", "f_operand2 0x%x", 'x', f_operand2, "f_indir_pc__dword 0x%x", 'x', f_indir_pc__dword, (char *) 0));
5032
5033 #if WITH_PROFILE_MODEL_P
5034 /* Record the fields for profiling. */
5035 if (PROFILE_MODEL_P (current_cpu))
5036 {
5037 FLD (in_Rd) = f_operand2;
5038 }
5039 #endif
5040 #undef FLD
5041 return idesc;
5042 }
5043
5044 extract_sfmt_addi_acr_b_r:
5045 {
5046 const IDESC *idesc = &crisv32f_insn_data[itype];
5047 CGEN_INSN_WORD insn = base_insn;
5048 #define FLD(f) abuf->fields.sfmt_muls_b.f
5049 UINT f_operand2;
5050 UINT f_operand1;
5051
5052 f_operand2 = EXTRACT_LSB0_UINT (insn, 16, 15, 4);
5053 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
5054
5055 /* Record the fields for the semantic handler. */
5056 FLD (f_operand2) = f_operand2;
5057 FLD (f_operand1) = f_operand1;
5058 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addi_acr_b_r", "f_operand2 0x%x", 'x', f_operand2, "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
5059
5060 #if WITH_PROFILE_MODEL_P
5061 /* Record the fields for profiling. */
5062 if (PROFILE_MODEL_P (current_cpu))
5063 {
5064 FLD (in_Rd) = f_operand2;
5065 FLD (in_Rs) = f_operand1;
5066 }
5067 #endif
5068 #undef FLD
5069 return idesc;
5070 }
5071
5072 extract_sfmt_fidxi:
5073 {
5074 const IDESC *idesc = &crisv32f_insn_data[itype];
5075 CGEN_INSN_WORD insn = base_insn;
5076 #define FLD(f) abuf->fields.sfmt_mcp.f
5077 UINT f_operand1;
5078
5079 f_operand1 = EXTRACT_LSB0_UINT (insn, 16, 3, 4);
5080
5081 /* Record the fields for the semantic handler. */
5082 FLD (f_operand1) = f_operand1;
5083 TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_fidxi", "f_operand1 0x%x", 'x', f_operand1, (char *) 0));
5084
5085 #if WITH_PROFILE_MODEL_P
5086 /* Record the fields for profiling. */
5087 if (PROFILE_MODEL_P (current_cpu))
5088 {
5089 FLD (in_Rs) = f_operand1;
5090 }
5091 #endif
5092 #undef FLD
5093 return idesc;
5094 }
5095
5096 }
5097