xref: /netbsd/external/gpl3/gdb/dist/sim/m32r/decode.c (revision 1424dfb3)
166e63ce3Schristos /* Simulator instruction decoder for m32rbf.
266e63ce3Schristos 
366e63ce3Schristos THIS FILE IS MACHINE GENERATED WITH CGEN.
466e63ce3Schristos 
5*1424dfb3Schristos Copyright 1996-2020 Free Software Foundation, Inc.
666e63ce3Schristos 
766e63ce3Schristos This file is part of the GNU simulators.
866e63ce3Schristos 
966e63ce3Schristos    This file is free software; you can redistribute it and/or modify
1066e63ce3Schristos    it under the terms of the GNU General Public License as published by
1166e63ce3Schristos    the Free Software Foundation; either version 3, or (at your option)
1266e63ce3Schristos    any later version.
1366e63ce3Schristos 
1466e63ce3Schristos    It is distributed in the hope that it will be useful, but WITHOUT
1566e63ce3Schristos    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
1666e63ce3Schristos    or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
1766e63ce3Schristos    License for more details.
1866e63ce3Schristos 
1966e63ce3Schristos    You should have received a copy of the GNU General Public License along
2048596154Schristos    with this program; if not, see <http://www.gnu.org/licenses/>.
2166e63ce3Schristos 
2266e63ce3Schristos */
2366e63ce3Schristos 
2466e63ce3Schristos #define WANT_CPU m32rbf
2566e63ce3Schristos #define WANT_CPU_M32RBF
2666e63ce3Schristos 
2766e63ce3Schristos #include "sim-main.h"
2866e63ce3Schristos #include "sim-assert.h"
2966e63ce3Schristos 
3066e63ce3Schristos /* The instruction descriptor array.
3166e63ce3Schristos    This is computed at runtime.  Space for it is not malloc'd to save a
3266e63ce3Schristos    teensy bit of cpu in the decoder.  Moving it to malloc space is trivial
3366e63ce3Schristos    but won't be done until necessary (we don't currently support the runtime
3466e63ce3Schristos    addition of instructions nor an SMP machine with different cpus).  */
3566e63ce3Schristos static IDESC m32rbf_insn_data[M32RBF_INSN__MAX];
3666e63ce3Schristos 
3766e63ce3Schristos /* Commas between elements are contained in the macros.
3866e63ce3Schristos    Some of these are conditionally compiled out.  */
3966e63ce3Schristos 
4066e63ce3Schristos static const struct insn_sem m32rbf_insn_sem[] =
4166e63ce3Schristos {
4266e63ce3Schristos   { VIRTUAL_INSN_X_INVALID, M32RBF_INSN_X_INVALID, M32RBF_SFMT_EMPTY },
4366e63ce3Schristos   { VIRTUAL_INSN_X_AFTER, M32RBF_INSN_X_AFTER, M32RBF_SFMT_EMPTY },
4466e63ce3Schristos   { VIRTUAL_INSN_X_BEFORE, M32RBF_INSN_X_BEFORE, M32RBF_SFMT_EMPTY },
4566e63ce3Schristos   { VIRTUAL_INSN_X_CTI_CHAIN, M32RBF_INSN_X_CTI_CHAIN, M32RBF_SFMT_EMPTY },
4666e63ce3Schristos   { VIRTUAL_INSN_X_CHAIN, M32RBF_INSN_X_CHAIN, M32RBF_SFMT_EMPTY },
4766e63ce3Schristos   { VIRTUAL_INSN_X_BEGIN, M32RBF_INSN_X_BEGIN, M32RBF_SFMT_EMPTY },
4866e63ce3Schristos   { M32R_INSN_ADD, M32RBF_INSN_ADD, M32RBF_SFMT_ADD },
4966e63ce3Schristos   { M32R_INSN_ADD3, M32RBF_INSN_ADD3, M32RBF_SFMT_ADD3 },
5066e63ce3Schristos   { M32R_INSN_AND, M32RBF_INSN_AND, M32RBF_SFMT_ADD },
5166e63ce3Schristos   { M32R_INSN_AND3, M32RBF_INSN_AND3, M32RBF_SFMT_AND3 },
5266e63ce3Schristos   { M32R_INSN_OR, M32RBF_INSN_OR, M32RBF_SFMT_ADD },
5366e63ce3Schristos   { M32R_INSN_OR3, M32RBF_INSN_OR3, M32RBF_SFMT_OR3 },
5466e63ce3Schristos   { M32R_INSN_XOR, M32RBF_INSN_XOR, M32RBF_SFMT_ADD },
5566e63ce3Schristos   { M32R_INSN_XOR3, M32RBF_INSN_XOR3, M32RBF_SFMT_AND3 },
5666e63ce3Schristos   { M32R_INSN_ADDI, M32RBF_INSN_ADDI, M32RBF_SFMT_ADDI },
5766e63ce3Schristos   { M32R_INSN_ADDV, M32RBF_INSN_ADDV, M32RBF_SFMT_ADDV },
5866e63ce3Schristos   { M32R_INSN_ADDV3, M32RBF_INSN_ADDV3, M32RBF_SFMT_ADDV3 },
5966e63ce3Schristos   { M32R_INSN_ADDX, M32RBF_INSN_ADDX, M32RBF_SFMT_ADDX },
6066e63ce3Schristos   { M32R_INSN_BC8, M32RBF_INSN_BC8, M32RBF_SFMT_BC8 },
6166e63ce3Schristos   { M32R_INSN_BC24, M32RBF_INSN_BC24, M32RBF_SFMT_BC24 },
6266e63ce3Schristos   { M32R_INSN_BEQ, M32RBF_INSN_BEQ, M32RBF_SFMT_BEQ },
6366e63ce3Schristos   { M32R_INSN_BEQZ, M32RBF_INSN_BEQZ, M32RBF_SFMT_BEQZ },
6466e63ce3Schristos   { M32R_INSN_BGEZ, M32RBF_INSN_BGEZ, M32RBF_SFMT_BEQZ },
6566e63ce3Schristos   { M32R_INSN_BGTZ, M32RBF_INSN_BGTZ, M32RBF_SFMT_BEQZ },
6666e63ce3Schristos   { M32R_INSN_BLEZ, M32RBF_INSN_BLEZ, M32RBF_SFMT_BEQZ },
6766e63ce3Schristos   { M32R_INSN_BLTZ, M32RBF_INSN_BLTZ, M32RBF_SFMT_BEQZ },
6866e63ce3Schristos   { M32R_INSN_BNEZ, M32RBF_INSN_BNEZ, M32RBF_SFMT_BEQZ },
6966e63ce3Schristos   { M32R_INSN_BL8, M32RBF_INSN_BL8, M32RBF_SFMT_BL8 },
7066e63ce3Schristos   { M32R_INSN_BL24, M32RBF_INSN_BL24, M32RBF_SFMT_BL24 },
7166e63ce3Schristos   { M32R_INSN_BNC8, M32RBF_INSN_BNC8, M32RBF_SFMT_BC8 },
7266e63ce3Schristos   { M32R_INSN_BNC24, M32RBF_INSN_BNC24, M32RBF_SFMT_BC24 },
7366e63ce3Schristos   { M32R_INSN_BNE, M32RBF_INSN_BNE, M32RBF_SFMT_BEQ },
7466e63ce3Schristos   { M32R_INSN_BRA8, M32RBF_INSN_BRA8, M32RBF_SFMT_BRA8 },
7566e63ce3Schristos   { M32R_INSN_BRA24, M32RBF_INSN_BRA24, M32RBF_SFMT_BRA24 },
7666e63ce3Schristos   { M32R_INSN_CMP, M32RBF_INSN_CMP, M32RBF_SFMT_CMP },
7766e63ce3Schristos   { M32R_INSN_CMPI, M32RBF_INSN_CMPI, M32RBF_SFMT_CMPI },
7866e63ce3Schristos   { M32R_INSN_CMPU, M32RBF_INSN_CMPU, M32RBF_SFMT_CMP },
7966e63ce3Schristos   { M32R_INSN_CMPUI, M32RBF_INSN_CMPUI, M32RBF_SFMT_CMPI },
8066e63ce3Schristos   { M32R_INSN_DIV, M32RBF_INSN_DIV, M32RBF_SFMT_DIV },
8166e63ce3Schristos   { M32R_INSN_DIVU, M32RBF_INSN_DIVU, M32RBF_SFMT_DIV },
8266e63ce3Schristos   { M32R_INSN_REM, M32RBF_INSN_REM, M32RBF_SFMT_DIV },
8366e63ce3Schristos   { M32R_INSN_REMU, M32RBF_INSN_REMU, M32RBF_SFMT_DIV },
8466e63ce3Schristos   { M32R_INSN_JL, M32RBF_INSN_JL, M32RBF_SFMT_JL },
8566e63ce3Schristos   { M32R_INSN_JMP, M32RBF_INSN_JMP, M32RBF_SFMT_JMP },
8666e63ce3Schristos   { M32R_INSN_LD, M32RBF_INSN_LD, M32RBF_SFMT_LD },
8766e63ce3Schristos   { M32R_INSN_LD_D, M32RBF_INSN_LD_D, M32RBF_SFMT_LD_D },
8866e63ce3Schristos   { M32R_INSN_LDB, M32RBF_INSN_LDB, M32RBF_SFMT_LDB },
8966e63ce3Schristos   { M32R_INSN_LDB_D, M32RBF_INSN_LDB_D, M32RBF_SFMT_LDB_D },
9066e63ce3Schristos   { M32R_INSN_LDH, M32RBF_INSN_LDH, M32RBF_SFMT_LDH },
9166e63ce3Schristos   { M32R_INSN_LDH_D, M32RBF_INSN_LDH_D, M32RBF_SFMT_LDH_D },
9266e63ce3Schristos   { M32R_INSN_LDUB, M32RBF_INSN_LDUB, M32RBF_SFMT_LDB },
9366e63ce3Schristos   { M32R_INSN_LDUB_D, M32RBF_INSN_LDUB_D, M32RBF_SFMT_LDB_D },
9466e63ce3Schristos   { M32R_INSN_LDUH, M32RBF_INSN_LDUH, M32RBF_SFMT_LDH },
9566e63ce3Schristos   { M32R_INSN_LDUH_D, M32RBF_INSN_LDUH_D, M32RBF_SFMT_LDH_D },
9666e63ce3Schristos   { M32R_INSN_LD_PLUS, M32RBF_INSN_LD_PLUS, M32RBF_SFMT_LD_PLUS },
9766e63ce3Schristos   { M32R_INSN_LD24, M32RBF_INSN_LD24, M32RBF_SFMT_LD24 },
9866e63ce3Schristos   { M32R_INSN_LDI8, M32RBF_INSN_LDI8, M32RBF_SFMT_LDI8 },
9966e63ce3Schristos   { M32R_INSN_LDI16, M32RBF_INSN_LDI16, M32RBF_SFMT_LDI16 },
10066e63ce3Schristos   { M32R_INSN_LOCK, M32RBF_INSN_LOCK, M32RBF_SFMT_LOCK },
10166e63ce3Schristos   { M32R_INSN_MACHI, M32RBF_INSN_MACHI, M32RBF_SFMT_MACHI },
10266e63ce3Schristos   { M32R_INSN_MACLO, M32RBF_INSN_MACLO, M32RBF_SFMT_MACHI },
10366e63ce3Schristos   { M32R_INSN_MACWHI, M32RBF_INSN_MACWHI, M32RBF_SFMT_MACHI },
10466e63ce3Schristos   { M32R_INSN_MACWLO, M32RBF_INSN_MACWLO, M32RBF_SFMT_MACHI },
10566e63ce3Schristos   { M32R_INSN_MUL, M32RBF_INSN_MUL, M32RBF_SFMT_ADD },
10666e63ce3Schristos   { M32R_INSN_MULHI, M32RBF_INSN_MULHI, M32RBF_SFMT_MULHI },
10766e63ce3Schristos   { M32R_INSN_MULLO, M32RBF_INSN_MULLO, M32RBF_SFMT_MULHI },
10866e63ce3Schristos   { M32R_INSN_MULWHI, M32RBF_INSN_MULWHI, M32RBF_SFMT_MULHI },
10966e63ce3Schristos   { M32R_INSN_MULWLO, M32RBF_INSN_MULWLO, M32RBF_SFMT_MULHI },
11066e63ce3Schristos   { M32R_INSN_MV, M32RBF_INSN_MV, M32RBF_SFMT_MV },
11166e63ce3Schristos   { M32R_INSN_MVFACHI, M32RBF_INSN_MVFACHI, M32RBF_SFMT_MVFACHI },
11266e63ce3Schristos   { M32R_INSN_MVFACLO, M32RBF_INSN_MVFACLO, M32RBF_SFMT_MVFACHI },
11366e63ce3Schristos   { M32R_INSN_MVFACMI, M32RBF_INSN_MVFACMI, M32RBF_SFMT_MVFACHI },
11466e63ce3Schristos   { M32R_INSN_MVFC, M32RBF_INSN_MVFC, M32RBF_SFMT_MVFC },
11566e63ce3Schristos   { M32R_INSN_MVTACHI, M32RBF_INSN_MVTACHI, M32RBF_SFMT_MVTACHI },
11666e63ce3Schristos   { M32R_INSN_MVTACLO, M32RBF_INSN_MVTACLO, M32RBF_SFMT_MVTACHI },
11766e63ce3Schristos   { M32R_INSN_MVTC, M32RBF_INSN_MVTC, M32RBF_SFMT_MVTC },
11866e63ce3Schristos   { M32R_INSN_NEG, M32RBF_INSN_NEG, M32RBF_SFMT_MV },
11966e63ce3Schristos   { M32R_INSN_NOP, M32RBF_INSN_NOP, M32RBF_SFMT_NOP },
12066e63ce3Schristos   { M32R_INSN_NOT, M32RBF_INSN_NOT, M32RBF_SFMT_MV },
12166e63ce3Schristos   { M32R_INSN_RAC, M32RBF_INSN_RAC, M32RBF_SFMT_RAC },
12266e63ce3Schristos   { M32R_INSN_RACH, M32RBF_INSN_RACH, M32RBF_SFMT_RAC },
12366e63ce3Schristos   { M32R_INSN_RTE, M32RBF_INSN_RTE, M32RBF_SFMT_RTE },
12466e63ce3Schristos   { M32R_INSN_SETH, M32RBF_INSN_SETH, M32RBF_SFMT_SETH },
12566e63ce3Schristos   { M32R_INSN_SLL, M32RBF_INSN_SLL, M32RBF_SFMT_ADD },
12666e63ce3Schristos   { M32R_INSN_SLL3, M32RBF_INSN_SLL3, M32RBF_SFMT_SLL3 },
12766e63ce3Schristos   { M32R_INSN_SLLI, M32RBF_INSN_SLLI, M32RBF_SFMT_SLLI },
12866e63ce3Schristos   { M32R_INSN_SRA, M32RBF_INSN_SRA, M32RBF_SFMT_ADD },
12966e63ce3Schristos   { M32R_INSN_SRA3, M32RBF_INSN_SRA3, M32RBF_SFMT_SLL3 },
13066e63ce3Schristos   { M32R_INSN_SRAI, M32RBF_INSN_SRAI, M32RBF_SFMT_SLLI },
13166e63ce3Schristos   { M32R_INSN_SRL, M32RBF_INSN_SRL, M32RBF_SFMT_ADD },
13266e63ce3Schristos   { M32R_INSN_SRL3, M32RBF_INSN_SRL3, M32RBF_SFMT_SLL3 },
13366e63ce3Schristos   { M32R_INSN_SRLI, M32RBF_INSN_SRLI, M32RBF_SFMT_SLLI },
13466e63ce3Schristos   { M32R_INSN_ST, M32RBF_INSN_ST, M32RBF_SFMT_ST },
13566e63ce3Schristos   { M32R_INSN_ST_D, M32RBF_INSN_ST_D, M32RBF_SFMT_ST_D },
13666e63ce3Schristos   { M32R_INSN_STB, M32RBF_INSN_STB, M32RBF_SFMT_STB },
13766e63ce3Schristos   { M32R_INSN_STB_D, M32RBF_INSN_STB_D, M32RBF_SFMT_STB_D },
13866e63ce3Schristos   { M32R_INSN_STH, M32RBF_INSN_STH, M32RBF_SFMT_STH },
13966e63ce3Schristos   { M32R_INSN_STH_D, M32RBF_INSN_STH_D, M32RBF_SFMT_STH_D },
14066e63ce3Schristos   { M32R_INSN_ST_PLUS, M32RBF_INSN_ST_PLUS, M32RBF_SFMT_ST_PLUS },
14166e63ce3Schristos   { M32R_INSN_ST_MINUS, M32RBF_INSN_ST_MINUS, M32RBF_SFMT_ST_PLUS },
14266e63ce3Schristos   { M32R_INSN_SUB, M32RBF_INSN_SUB, M32RBF_SFMT_ADD },
14366e63ce3Schristos   { M32R_INSN_SUBV, M32RBF_INSN_SUBV, M32RBF_SFMT_ADDV },
14466e63ce3Schristos   { M32R_INSN_SUBX, M32RBF_INSN_SUBX, M32RBF_SFMT_ADDX },
14566e63ce3Schristos   { M32R_INSN_TRAP, M32RBF_INSN_TRAP, M32RBF_SFMT_TRAP },
14666e63ce3Schristos   { M32R_INSN_UNLOCK, M32RBF_INSN_UNLOCK, M32RBF_SFMT_UNLOCK },
14766e63ce3Schristos   { M32R_INSN_CLRPSW, M32RBF_INSN_CLRPSW, M32RBF_SFMT_CLRPSW },
14866e63ce3Schristos   { M32R_INSN_SETPSW, M32RBF_INSN_SETPSW, M32RBF_SFMT_SETPSW },
14966e63ce3Schristos   { M32R_INSN_BSET, M32RBF_INSN_BSET, M32RBF_SFMT_BSET },
15066e63ce3Schristos   { M32R_INSN_BCLR, M32RBF_INSN_BCLR, M32RBF_SFMT_BSET },
15166e63ce3Schristos   { M32R_INSN_BTST, M32RBF_INSN_BTST, M32RBF_SFMT_BTST },
15266e63ce3Schristos };
15366e63ce3Schristos 
15466e63ce3Schristos static const struct insn_sem m32rbf_insn_sem_invalid =
15566e63ce3Schristos {
15666e63ce3Schristos   VIRTUAL_INSN_X_INVALID, M32RBF_INSN_X_INVALID, M32RBF_SFMT_EMPTY
15766e63ce3Schristos };
15866e63ce3Schristos 
15966e63ce3Schristos /* Initialize an IDESC from the compile-time computable parts.  */
16066e63ce3Schristos 
16166e63ce3Schristos static INLINE void
init_idesc(SIM_CPU * cpu,IDESC * id,const struct insn_sem * t)16266e63ce3Schristos init_idesc (SIM_CPU *cpu, IDESC *id, const struct insn_sem *t)
16366e63ce3Schristos {
16466e63ce3Schristos   const CGEN_INSN *insn_table = CGEN_CPU_INSN_TABLE (CPU_CPU_DESC (cpu))->init_entries;
16566e63ce3Schristos 
16666e63ce3Schristos   id->num = t->index;
16766e63ce3Schristos   id->sfmt = t->sfmt;
16866e63ce3Schristos   if ((int) t->type <= 0)
16966e63ce3Schristos     id->idata = & cgen_virtual_insn_table[- (int) t->type];
17066e63ce3Schristos   else
17166e63ce3Schristos     id->idata = & insn_table[t->type];
17266e63ce3Schristos   id->attrs = CGEN_INSN_ATTRS (id->idata);
17366e63ce3Schristos   /* Oh my god, a magic number.  */
17466e63ce3Schristos   id->length = CGEN_INSN_BITSIZE (id->idata) / 8;
17566e63ce3Schristos 
17666e63ce3Schristos #if WITH_PROFILE_MODEL_P
17766e63ce3Schristos   id->timing = & MODEL_TIMING (CPU_MODEL (cpu)) [t->index];
17866e63ce3Schristos   {
17966e63ce3Schristos     SIM_DESC sd = CPU_STATE (cpu);
18066e63ce3Schristos     SIM_ASSERT (t->index == id->timing->num);
18166e63ce3Schristos   }
18266e63ce3Schristos #endif
18366e63ce3Schristos 
18466e63ce3Schristos   /* Semantic pointers are initialized elsewhere.  */
18566e63ce3Schristos }
18666e63ce3Schristos 
18766e63ce3Schristos /* Initialize the instruction descriptor table.  */
18866e63ce3Schristos 
18966e63ce3Schristos void
m32rbf_init_idesc_table(SIM_CPU * cpu)19066e63ce3Schristos m32rbf_init_idesc_table (SIM_CPU *cpu)
19166e63ce3Schristos {
19266e63ce3Schristos   IDESC *id,*tabend;
19366e63ce3Schristos   const struct insn_sem *t,*tend;
19466e63ce3Schristos   int tabsize = M32RBF_INSN__MAX;
19566e63ce3Schristos   IDESC *table = m32rbf_insn_data;
19666e63ce3Schristos 
19766e63ce3Schristos   memset (table, 0, tabsize * sizeof (IDESC));
19866e63ce3Schristos 
19966e63ce3Schristos   /* First set all entries to the `invalid insn'.  */
20066e63ce3Schristos   t = & m32rbf_insn_sem_invalid;
20166e63ce3Schristos   for (id = table, tabend = table + tabsize; id < tabend; ++id)
20266e63ce3Schristos     init_idesc (cpu, id, t);
20366e63ce3Schristos 
20466e63ce3Schristos   /* Now fill in the values for the chosen cpu.  */
2051c468f90Schristos   for (t = m32rbf_insn_sem, tend = t + ARRAY_SIZE (m32rbf_insn_sem);
20666e63ce3Schristos        t != tend; ++t)
20766e63ce3Schristos     {
20866e63ce3Schristos       init_idesc (cpu, & table[t->index], t);
20966e63ce3Schristos     }
21066e63ce3Schristos 
21166e63ce3Schristos   /* Link the IDESC table into the cpu.  */
21266e63ce3Schristos   CPU_IDESC (cpu) = table;
21366e63ce3Schristos }
21466e63ce3Schristos 
21566e63ce3Schristos /* Given an instruction, return a pointer to its IDESC entry.  */
21666e63ce3Schristos 
21766e63ce3Schristos const IDESC *
m32rbf_decode(SIM_CPU * current_cpu,IADDR pc,CGEN_INSN_WORD base_insn,CGEN_INSN_WORD entire_insn,ARGBUF * abuf)21866e63ce3Schristos m32rbf_decode (SIM_CPU *current_cpu, IADDR pc,
21966e63ce3Schristos               CGEN_INSN_WORD base_insn, CGEN_INSN_WORD entire_insn,
22066e63ce3Schristos               ARGBUF *abuf)
22166e63ce3Schristos {
22266e63ce3Schristos   /* Result of decoder.  */
22366e63ce3Schristos   M32RBF_INSN_TYPE itype;
22466e63ce3Schristos 
22566e63ce3Schristos   {
22666e63ce3Schristos     CGEN_INSN_WORD insn = base_insn;
22766e63ce3Schristos 
22866e63ce3Schristos     {
22966e63ce3Schristos       unsigned int val = (((insn >> 8) & (15 << 4)) | ((insn >> 4) & (15 << 0)));
23066e63ce3Schristos       switch (val)
23166e63ce3Schristos       {
23266e63ce3Schristos       case 0 : itype = M32RBF_INSN_SUBV; goto extract_sfmt_addv;
23366e63ce3Schristos       case 1 : itype = M32RBF_INSN_SUBX; goto extract_sfmt_addx;
23466e63ce3Schristos       case 2 : itype = M32RBF_INSN_SUB; goto extract_sfmt_add;
23566e63ce3Schristos       case 3 : itype = M32RBF_INSN_NEG; goto extract_sfmt_mv;
23666e63ce3Schristos       case 4 : itype = M32RBF_INSN_CMP; goto extract_sfmt_cmp;
23766e63ce3Schristos       case 5 : itype = M32RBF_INSN_CMPU; goto extract_sfmt_cmp;
23866e63ce3Schristos       case 8 : itype = M32RBF_INSN_ADDV; goto extract_sfmt_addv;
23966e63ce3Schristos       case 9 : itype = M32RBF_INSN_ADDX; goto extract_sfmt_addx;
24066e63ce3Schristos       case 10 : itype = M32RBF_INSN_ADD; goto extract_sfmt_add;
24166e63ce3Schristos       case 11 : itype = M32RBF_INSN_NOT; goto extract_sfmt_mv;
24266e63ce3Schristos       case 12 : itype = M32RBF_INSN_AND; goto extract_sfmt_add;
24366e63ce3Schristos       case 13 : itype = M32RBF_INSN_XOR; goto extract_sfmt_add;
24466e63ce3Schristos       case 14 : itype = M32RBF_INSN_OR; goto extract_sfmt_add;
24566e63ce3Schristos       case 15 :
24666e63ce3Schristos         if ((entire_insn & 0xf8f0) == 0xf0)
24766e63ce3Schristos           { itype = M32RBF_INSN_BTST; goto extract_sfmt_btst; }
24866e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
24966e63ce3Schristos       case 16 : itype = M32RBF_INSN_SRL; goto extract_sfmt_add;
25066e63ce3Schristos       case 18 : itype = M32RBF_INSN_SRA; goto extract_sfmt_add;
25166e63ce3Schristos       case 20 : itype = M32RBF_INSN_SLL; goto extract_sfmt_add;
25266e63ce3Schristos       case 22 : itype = M32RBF_INSN_MUL; goto extract_sfmt_add;
25366e63ce3Schristos       case 24 : itype = M32RBF_INSN_MV; goto extract_sfmt_mv;
25466e63ce3Schristos       case 25 : itype = M32RBF_INSN_MVFC; goto extract_sfmt_mvfc;
25566e63ce3Schristos       case 26 : itype = M32RBF_INSN_MVTC; goto extract_sfmt_mvtc;
25666e63ce3Schristos       case 28 :
25766e63ce3Schristos         {
25866e63ce3Schristos           unsigned int val = (((insn >> 8) & (1 << 0)));
25966e63ce3Schristos           switch (val)
26066e63ce3Schristos           {
26166e63ce3Schristos           case 0 :
26266e63ce3Schristos             if ((entire_insn & 0xfff0) == 0x1ec0)
26366e63ce3Schristos               { itype = M32RBF_INSN_JL; goto extract_sfmt_jl; }
26466e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
26566e63ce3Schristos           case 1 :
26666e63ce3Schristos             if ((entire_insn & 0xfff0) == 0x1fc0)
26766e63ce3Schristos               { itype = M32RBF_INSN_JMP; goto extract_sfmt_jmp; }
26866e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
26966e63ce3Schristos           default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
27066e63ce3Schristos           }
27166e63ce3Schristos         }
27266e63ce3Schristos       case 29 :
27366e63ce3Schristos         if ((entire_insn & 0xffff) == 0x10d6)
27466e63ce3Schristos           { itype = M32RBF_INSN_RTE; goto extract_sfmt_rte; }
27566e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
27666e63ce3Schristos       case 31 :
27766e63ce3Schristos         if ((entire_insn & 0xfff0) == 0x10f0)
27866e63ce3Schristos           { itype = M32RBF_INSN_TRAP; goto extract_sfmt_trap; }
27966e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
28066e63ce3Schristos       case 32 : itype = M32RBF_INSN_STB; goto extract_sfmt_stb;
28166e63ce3Schristos       case 34 : itype = M32RBF_INSN_STH; goto extract_sfmt_sth;
28266e63ce3Schristos       case 36 : itype = M32RBF_INSN_ST; goto extract_sfmt_st;
28366e63ce3Schristos       case 37 : itype = M32RBF_INSN_UNLOCK; goto extract_sfmt_unlock;
28466e63ce3Schristos       case 38 : itype = M32RBF_INSN_ST_PLUS; goto extract_sfmt_st_plus;
28566e63ce3Schristos       case 39 : itype = M32RBF_INSN_ST_MINUS; goto extract_sfmt_st_plus;
28666e63ce3Schristos       case 40 : itype = M32RBF_INSN_LDB; goto extract_sfmt_ldb;
28766e63ce3Schristos       case 41 : itype = M32RBF_INSN_LDUB; goto extract_sfmt_ldb;
28866e63ce3Schristos       case 42 : itype = M32RBF_INSN_LDH; goto extract_sfmt_ldh;
28966e63ce3Schristos       case 43 : itype = M32RBF_INSN_LDUH; goto extract_sfmt_ldh;
29066e63ce3Schristos       case 44 : itype = M32RBF_INSN_LD; goto extract_sfmt_ld;
29166e63ce3Schristos       case 45 : itype = M32RBF_INSN_LOCK; goto extract_sfmt_lock;
29266e63ce3Schristos       case 46 : itype = M32RBF_INSN_LD_PLUS; goto extract_sfmt_ld_plus;
29366e63ce3Schristos       case 48 : itype = M32RBF_INSN_MULHI; goto extract_sfmt_mulhi;
29466e63ce3Schristos       case 49 : itype = M32RBF_INSN_MULLO; goto extract_sfmt_mulhi;
29566e63ce3Schristos       case 50 : itype = M32RBF_INSN_MULWHI; goto extract_sfmt_mulhi;
29666e63ce3Schristos       case 51 : itype = M32RBF_INSN_MULWLO; goto extract_sfmt_mulhi;
29766e63ce3Schristos       case 52 : itype = M32RBF_INSN_MACHI; goto extract_sfmt_machi;
29866e63ce3Schristos       case 53 : itype = M32RBF_INSN_MACLO; goto extract_sfmt_machi;
29966e63ce3Schristos       case 54 : itype = M32RBF_INSN_MACWHI; goto extract_sfmt_machi;
30066e63ce3Schristos       case 55 : itype = M32RBF_INSN_MACWLO; goto extract_sfmt_machi;
30166e63ce3Schristos       case 64 : /* fall through */
30266e63ce3Schristos       case 65 : /* fall through */
30366e63ce3Schristos       case 66 : /* fall through */
30466e63ce3Schristos       case 67 : /* fall through */
30566e63ce3Schristos       case 68 : /* fall through */
30666e63ce3Schristos       case 69 : /* fall through */
30766e63ce3Schristos       case 70 : /* fall through */
30866e63ce3Schristos       case 71 : /* fall through */
30966e63ce3Schristos       case 72 : /* fall through */
31066e63ce3Schristos       case 73 : /* fall through */
31166e63ce3Schristos       case 74 : /* fall through */
31266e63ce3Schristos       case 75 : /* fall through */
31366e63ce3Schristos       case 76 : /* fall through */
31466e63ce3Schristos       case 77 : /* fall through */
31566e63ce3Schristos       case 78 : /* fall through */
31666e63ce3Schristos       case 79 : itype = M32RBF_INSN_ADDI; goto extract_sfmt_addi;
31766e63ce3Schristos       case 80 : /* fall through */
31866e63ce3Schristos       case 81 : itype = M32RBF_INSN_SRLI; goto extract_sfmt_slli;
31966e63ce3Schristos       case 82 : /* fall through */
32066e63ce3Schristos       case 83 : itype = M32RBF_INSN_SRAI; goto extract_sfmt_slli;
32166e63ce3Schristos       case 84 : /* fall through */
32266e63ce3Schristos       case 85 : itype = M32RBF_INSN_SLLI; goto extract_sfmt_slli;
32366e63ce3Schristos       case 87 :
32466e63ce3Schristos         {
32566e63ce3Schristos           unsigned int val = (((insn >> 0) & (1 << 0)));
32666e63ce3Schristos           switch (val)
32766e63ce3Schristos           {
32866e63ce3Schristos           case 0 :
32966e63ce3Schristos             if ((entire_insn & 0xf0ff) == 0x5070)
33066e63ce3Schristos               { itype = M32RBF_INSN_MVTACHI; goto extract_sfmt_mvtachi; }
33166e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
33266e63ce3Schristos           case 1 :
33366e63ce3Schristos             if ((entire_insn & 0xf0ff) == 0x5071)
33466e63ce3Schristos               { itype = M32RBF_INSN_MVTACLO; goto extract_sfmt_mvtachi; }
33566e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
33666e63ce3Schristos           default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
33766e63ce3Schristos           }
33866e63ce3Schristos         }
33966e63ce3Schristos       case 88 :
34066e63ce3Schristos         if ((entire_insn & 0xffff) == 0x5080)
34166e63ce3Schristos           { itype = M32RBF_INSN_RACH; goto extract_sfmt_rac; }
34266e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
34366e63ce3Schristos       case 89 :
34466e63ce3Schristos         if ((entire_insn & 0xffff) == 0x5090)
34566e63ce3Schristos           { itype = M32RBF_INSN_RAC; goto extract_sfmt_rac; }
34666e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
34766e63ce3Schristos       case 95 :
34866e63ce3Schristos         {
34966e63ce3Schristos           unsigned int val = (((insn >> 0) & (3 << 0)));
35066e63ce3Schristos           switch (val)
35166e63ce3Schristos           {
35266e63ce3Schristos           case 0 :
35366e63ce3Schristos             if ((entire_insn & 0xf0ff) == 0x50f0)
35466e63ce3Schristos               { itype = M32RBF_INSN_MVFACHI; goto extract_sfmt_mvfachi; }
35566e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
35666e63ce3Schristos           case 1 :
35766e63ce3Schristos             if ((entire_insn & 0xf0ff) == 0x50f1)
35866e63ce3Schristos               { itype = M32RBF_INSN_MVFACLO; goto extract_sfmt_mvfachi; }
35966e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
36066e63ce3Schristos           case 2 :
36166e63ce3Schristos             if ((entire_insn & 0xf0ff) == 0x50f2)
36266e63ce3Schristos               { itype = M32RBF_INSN_MVFACMI; goto extract_sfmt_mvfachi; }
36366e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
36466e63ce3Schristos           default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
36566e63ce3Schristos           }
36666e63ce3Schristos         }
36766e63ce3Schristos       case 96 : /* fall through */
36866e63ce3Schristos       case 97 : /* fall through */
36966e63ce3Schristos       case 98 : /* fall through */
37066e63ce3Schristos       case 99 : /* fall through */
37166e63ce3Schristos       case 100 : /* fall through */
37266e63ce3Schristos       case 101 : /* fall through */
37366e63ce3Schristos       case 102 : /* fall through */
37466e63ce3Schristos       case 103 : /* fall through */
37566e63ce3Schristos       case 104 : /* fall through */
37666e63ce3Schristos       case 105 : /* fall through */
37766e63ce3Schristos       case 106 : /* fall through */
37866e63ce3Schristos       case 107 : /* fall through */
37966e63ce3Schristos       case 108 : /* fall through */
38066e63ce3Schristos       case 109 : /* fall through */
38166e63ce3Schristos       case 110 : /* fall through */
38266e63ce3Schristos       case 111 : itype = M32RBF_INSN_LDI8; goto extract_sfmt_ldi8;
38366e63ce3Schristos       case 112 :
38466e63ce3Schristos         {
38566e63ce3Schristos           unsigned int val = (((insn >> 8) & (15 << 0)));
38666e63ce3Schristos           switch (val)
38766e63ce3Schristos           {
38866e63ce3Schristos           case 0 :
38966e63ce3Schristos             if ((entire_insn & 0xffff) == 0x7000)
39066e63ce3Schristos               { itype = M32RBF_INSN_NOP; goto extract_sfmt_nop; }
39166e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
39266e63ce3Schristos           case 1 : itype = M32RBF_INSN_SETPSW; goto extract_sfmt_setpsw;
39366e63ce3Schristos           case 2 : itype = M32RBF_INSN_CLRPSW; goto extract_sfmt_clrpsw;
39466e63ce3Schristos           case 12 : itype = M32RBF_INSN_BC8; goto extract_sfmt_bc8;
39566e63ce3Schristos           case 13 : itype = M32RBF_INSN_BNC8; goto extract_sfmt_bc8;
39666e63ce3Schristos           case 14 : itype = M32RBF_INSN_BL8; goto extract_sfmt_bl8;
39766e63ce3Schristos           case 15 : itype = M32RBF_INSN_BRA8; goto extract_sfmt_bra8;
39866e63ce3Schristos           default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
39966e63ce3Schristos           }
40066e63ce3Schristos         }
40166e63ce3Schristos       case 113 : /* fall through */
40266e63ce3Schristos       case 114 : /* fall through */
40366e63ce3Schristos       case 115 : /* fall through */
40466e63ce3Schristos       case 116 : /* fall through */
40566e63ce3Schristos       case 117 : /* fall through */
40666e63ce3Schristos       case 118 : /* fall through */
40766e63ce3Schristos       case 119 : /* fall through */
40866e63ce3Schristos       case 120 : /* fall through */
40966e63ce3Schristos       case 121 : /* fall through */
41066e63ce3Schristos       case 122 : /* fall through */
41166e63ce3Schristos       case 123 : /* fall through */
41266e63ce3Schristos       case 124 : /* fall through */
41366e63ce3Schristos       case 125 : /* fall through */
41466e63ce3Schristos       case 126 : /* fall through */
41566e63ce3Schristos       case 127 :
41666e63ce3Schristos         {
41766e63ce3Schristos           unsigned int val = (((insn >> 8) & (15 << 0)));
41866e63ce3Schristos           switch (val)
41966e63ce3Schristos           {
42066e63ce3Schristos           case 1 : itype = M32RBF_INSN_SETPSW; goto extract_sfmt_setpsw;
42166e63ce3Schristos           case 2 : itype = M32RBF_INSN_CLRPSW; goto extract_sfmt_clrpsw;
42266e63ce3Schristos           case 12 : itype = M32RBF_INSN_BC8; goto extract_sfmt_bc8;
42366e63ce3Schristos           case 13 : itype = M32RBF_INSN_BNC8; goto extract_sfmt_bc8;
42466e63ce3Schristos           case 14 : itype = M32RBF_INSN_BL8; goto extract_sfmt_bl8;
42566e63ce3Schristos           case 15 : itype = M32RBF_INSN_BRA8; goto extract_sfmt_bra8;
42666e63ce3Schristos           default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
42766e63ce3Schristos           }
42866e63ce3Schristos         }
42966e63ce3Schristos       case 132 :
43066e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0x80400000)
43166e63ce3Schristos           { itype = M32RBF_INSN_CMPI; goto extract_sfmt_cmpi; }
43266e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
43366e63ce3Schristos       case 133 :
43466e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0x80500000)
43566e63ce3Schristos           { itype = M32RBF_INSN_CMPUI; goto extract_sfmt_cmpi; }
43666e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
43766e63ce3Schristos       case 136 : itype = M32RBF_INSN_ADDV3; goto extract_sfmt_addv3;
43866e63ce3Schristos       case 138 : itype = M32RBF_INSN_ADD3; goto extract_sfmt_add3;
43966e63ce3Schristos       case 140 : itype = M32RBF_INSN_AND3; goto extract_sfmt_and3;
44066e63ce3Schristos       case 141 : itype = M32RBF_INSN_XOR3; goto extract_sfmt_and3;
44166e63ce3Schristos       case 142 : itype = M32RBF_INSN_OR3; goto extract_sfmt_or3;
44266e63ce3Schristos       case 144 :
44366e63ce3Schristos         if ((entire_insn & 0xf0f0ffff) == 0x90000000)
44466e63ce3Schristos           { itype = M32RBF_INSN_DIV; goto extract_sfmt_div; }
44566e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
44666e63ce3Schristos       case 145 :
44766e63ce3Schristos         if ((entire_insn & 0xf0f0ffff) == 0x90100000)
44866e63ce3Schristos           { itype = M32RBF_INSN_DIVU; goto extract_sfmt_div; }
44966e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
45066e63ce3Schristos       case 146 :
45166e63ce3Schristos         if ((entire_insn & 0xf0f0ffff) == 0x90200000)
45266e63ce3Schristos           { itype = M32RBF_INSN_REM; goto extract_sfmt_div; }
45366e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
45466e63ce3Schristos       case 147 :
45566e63ce3Schristos         if ((entire_insn & 0xf0f0ffff) == 0x90300000)
45666e63ce3Schristos           { itype = M32RBF_INSN_REMU; goto extract_sfmt_div; }
45766e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
45866e63ce3Schristos       case 152 : itype = M32RBF_INSN_SRL3; goto extract_sfmt_sll3;
45966e63ce3Schristos       case 154 : itype = M32RBF_INSN_SRA3; goto extract_sfmt_sll3;
46066e63ce3Schristos       case 156 : itype = M32RBF_INSN_SLL3; goto extract_sfmt_sll3;
46166e63ce3Schristos       case 159 :
46266e63ce3Schristos         if ((entire_insn & 0xf0ff0000) == 0x90f00000)
46366e63ce3Schristos           { itype = M32RBF_INSN_LDI16; goto extract_sfmt_ldi16; }
46466e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
46566e63ce3Schristos       case 160 : itype = M32RBF_INSN_STB_D; goto extract_sfmt_stb_d;
46666e63ce3Schristos       case 162 : itype = M32RBF_INSN_STH_D; goto extract_sfmt_sth_d;
46766e63ce3Schristos       case 164 : itype = M32RBF_INSN_ST_D; goto extract_sfmt_st_d;
46866e63ce3Schristos       case 166 :
46966e63ce3Schristos         if ((entire_insn & 0xf8f00000) == 0xa0600000)
47066e63ce3Schristos           { itype = M32RBF_INSN_BSET; goto extract_sfmt_bset; }
47166e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
47266e63ce3Schristos       case 167 :
47366e63ce3Schristos         if ((entire_insn & 0xf8f00000) == 0xa0700000)
47466e63ce3Schristos           { itype = M32RBF_INSN_BCLR; goto extract_sfmt_bset; }
47566e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
47666e63ce3Schristos       case 168 : itype = M32RBF_INSN_LDB_D; goto extract_sfmt_ldb_d;
47766e63ce3Schristos       case 169 : itype = M32RBF_INSN_LDUB_D; goto extract_sfmt_ldb_d;
47866e63ce3Schristos       case 170 : itype = M32RBF_INSN_LDH_D; goto extract_sfmt_ldh_d;
47966e63ce3Schristos       case 171 : itype = M32RBF_INSN_LDUH_D; goto extract_sfmt_ldh_d;
48066e63ce3Schristos       case 172 : itype = M32RBF_INSN_LD_D; goto extract_sfmt_ld_d;
48166e63ce3Schristos       case 176 : itype = M32RBF_INSN_BEQ; goto extract_sfmt_beq;
48266e63ce3Schristos       case 177 : itype = M32RBF_INSN_BNE; goto extract_sfmt_beq;
48366e63ce3Schristos       case 184 :
48466e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0xb0800000)
48566e63ce3Schristos           { itype = M32RBF_INSN_BEQZ; goto extract_sfmt_beqz; }
48666e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
48766e63ce3Schristos       case 185 :
48866e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0xb0900000)
48966e63ce3Schristos           { itype = M32RBF_INSN_BNEZ; goto extract_sfmt_beqz; }
49066e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
49166e63ce3Schristos       case 186 :
49266e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0xb0a00000)
49366e63ce3Schristos           { itype = M32RBF_INSN_BLTZ; goto extract_sfmt_beqz; }
49466e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
49566e63ce3Schristos       case 187 :
49666e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0xb0b00000)
49766e63ce3Schristos           { itype = M32RBF_INSN_BGEZ; goto extract_sfmt_beqz; }
49866e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
49966e63ce3Schristos       case 188 :
50066e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0xb0c00000)
50166e63ce3Schristos           { itype = M32RBF_INSN_BLEZ; goto extract_sfmt_beqz; }
50266e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
50366e63ce3Schristos       case 189 :
50466e63ce3Schristos         if ((entire_insn & 0xfff00000) == 0xb0d00000)
50566e63ce3Schristos           { itype = M32RBF_INSN_BGTZ; goto extract_sfmt_beqz; }
50666e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
50766e63ce3Schristos       case 220 :
50866e63ce3Schristos         if ((entire_insn & 0xf0ff0000) == 0xd0c00000)
50966e63ce3Schristos           { itype = M32RBF_INSN_SETH; goto extract_sfmt_seth; }
51066e63ce3Schristos         itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
51166e63ce3Schristos       case 224 : /* fall through */
51266e63ce3Schristos       case 225 : /* fall through */
51366e63ce3Schristos       case 226 : /* fall through */
51466e63ce3Schristos       case 227 : /* fall through */
51566e63ce3Schristos       case 228 : /* fall through */
51666e63ce3Schristos       case 229 : /* fall through */
51766e63ce3Schristos       case 230 : /* fall through */
51866e63ce3Schristos       case 231 : /* fall through */
51966e63ce3Schristos       case 232 : /* fall through */
52066e63ce3Schristos       case 233 : /* fall through */
52166e63ce3Schristos       case 234 : /* fall through */
52266e63ce3Schristos       case 235 : /* fall through */
52366e63ce3Schristos       case 236 : /* fall through */
52466e63ce3Schristos       case 237 : /* fall through */
52566e63ce3Schristos       case 238 : /* fall through */
52666e63ce3Schristos       case 239 : itype = M32RBF_INSN_LD24; goto extract_sfmt_ld24;
52766e63ce3Schristos       case 240 : /* fall through */
52866e63ce3Schristos       case 241 : /* fall through */
52966e63ce3Schristos       case 242 : /* fall through */
53066e63ce3Schristos       case 243 : /* fall through */
53166e63ce3Schristos       case 244 : /* fall through */
53266e63ce3Schristos       case 245 : /* fall through */
53366e63ce3Schristos       case 246 : /* fall through */
53466e63ce3Schristos       case 247 : /* fall through */
53566e63ce3Schristos       case 248 : /* fall through */
53666e63ce3Schristos       case 249 : /* fall through */
53766e63ce3Schristos       case 250 : /* fall through */
53866e63ce3Schristos       case 251 : /* fall through */
53966e63ce3Schristos       case 252 : /* fall through */
54066e63ce3Schristos       case 253 : /* fall through */
54166e63ce3Schristos       case 254 : /* fall through */
54266e63ce3Schristos       case 255 :
54366e63ce3Schristos         {
54466e63ce3Schristos           unsigned int val = (((insn >> 8) & (3 << 0)));
54566e63ce3Schristos           switch (val)
54666e63ce3Schristos           {
54766e63ce3Schristos           case 0 :
54866e63ce3Schristos             if ((entire_insn & 0xff000000) == 0xfc000000)
54966e63ce3Schristos               { itype = M32RBF_INSN_BC24; goto extract_sfmt_bc24; }
55066e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
55166e63ce3Schristos           case 1 :
55266e63ce3Schristos             if ((entire_insn & 0xff000000) == 0xfd000000)
55366e63ce3Schristos               { itype = M32RBF_INSN_BNC24; goto extract_sfmt_bc24; }
55466e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
55566e63ce3Schristos           case 2 :
55666e63ce3Schristos             if ((entire_insn & 0xff000000) == 0xfe000000)
55766e63ce3Schristos               { itype = M32RBF_INSN_BL24; goto extract_sfmt_bl24; }
55866e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
55966e63ce3Schristos           case 3 :
56066e63ce3Schristos             if ((entire_insn & 0xff000000) == 0xff000000)
56166e63ce3Schristos               { itype = M32RBF_INSN_BRA24; goto extract_sfmt_bra24; }
56266e63ce3Schristos             itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
56366e63ce3Schristos           default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
56466e63ce3Schristos           }
56566e63ce3Schristos         }
56666e63ce3Schristos       default : itype = M32RBF_INSN_X_INVALID; goto extract_sfmt_empty;
56766e63ce3Schristos       }
56866e63ce3Schristos     }
56966e63ce3Schristos   }
57066e63ce3Schristos 
57166e63ce3Schristos   /* The instruction has been decoded, now extract the fields.  */
57266e63ce3Schristos 
57366e63ce3Schristos  extract_sfmt_empty:
57466e63ce3Schristos   {
57566e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
57666e63ce3Schristos #define FLD(f) abuf->fields.sfmt_empty.f
57766e63ce3Schristos 
57866e63ce3Schristos 
57966e63ce3Schristos   /* Record the fields for the semantic handler.  */
580ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_empty", (char *) 0));
58166e63ce3Schristos 
58266e63ce3Schristos #undef FLD
58366e63ce3Schristos     return idesc;
58466e63ce3Schristos   }
58566e63ce3Schristos 
58666e63ce3Schristos  extract_sfmt_add:
58766e63ce3Schristos   {
58866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
58966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
59066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add.f
59166e63ce3Schristos     UINT f_r1;
59266e63ce3Schristos     UINT f_r2;
59366e63ce3Schristos 
59466e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
59566e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
59666e63ce3Schristos 
59766e63ce3Schristos   /* Record the fields for the semantic handler.  */
59866e63ce3Schristos   FLD (f_r1) = f_r1;
59966e63ce3Schristos   FLD (f_r2) = f_r2;
60066e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
60166e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
602ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, (char *) 0));
60366e63ce3Schristos 
60466e63ce3Schristos #if WITH_PROFILE_MODEL_P
60566e63ce3Schristos   /* Record the fields for profiling.  */
60666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
60766e63ce3Schristos     {
60866e63ce3Schristos       FLD (in_dr) = f_r1;
60966e63ce3Schristos       FLD (in_sr) = f_r2;
61066e63ce3Schristos       FLD (out_dr) = f_r1;
61166e63ce3Schristos     }
61266e63ce3Schristos #endif
61366e63ce3Schristos #undef FLD
61466e63ce3Schristos     return idesc;
61566e63ce3Schristos   }
61666e63ce3Schristos 
61766e63ce3Schristos  extract_sfmt_add3:
61866e63ce3Schristos   {
61966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
62066e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
62166e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
62266e63ce3Schristos     UINT f_r1;
62366e63ce3Schristos     UINT f_r2;
62466e63ce3Schristos     INT f_simm16;
62566e63ce3Schristos 
62666e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
62766e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
62866e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
62966e63ce3Schristos 
63066e63ce3Schristos   /* Record the fields for the semantic handler.  */
63166e63ce3Schristos   FLD (f_simm16) = f_simm16;
63266e63ce3Schristos   FLD (f_r2) = f_r2;
63366e63ce3Schristos   FLD (f_r1) = f_r1;
63466e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
63566e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
636ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_add3", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
63766e63ce3Schristos 
63866e63ce3Schristos #if WITH_PROFILE_MODEL_P
63966e63ce3Schristos   /* Record the fields for profiling.  */
64066e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
64166e63ce3Schristos     {
64266e63ce3Schristos       FLD (in_sr) = f_r2;
64366e63ce3Schristos       FLD (out_dr) = f_r1;
64466e63ce3Schristos     }
64566e63ce3Schristos #endif
64666e63ce3Schristos #undef FLD
64766e63ce3Schristos     return idesc;
64866e63ce3Schristos   }
64966e63ce3Schristos 
65066e63ce3Schristos  extract_sfmt_and3:
65166e63ce3Schristos   {
65266e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
65366e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
65466e63ce3Schristos #define FLD(f) abuf->fields.sfmt_and3.f
65566e63ce3Schristos     UINT f_r1;
65666e63ce3Schristos     UINT f_r2;
65766e63ce3Schristos     UINT f_uimm16;
65866e63ce3Schristos 
65966e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
66066e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
66166e63ce3Schristos     f_uimm16 = EXTRACT_MSB0_UINT (insn, 32, 16, 16);
66266e63ce3Schristos 
66366e63ce3Schristos   /* Record the fields for the semantic handler.  */
66466e63ce3Schristos   FLD (f_r2) = f_r2;
66566e63ce3Schristos   FLD (f_uimm16) = f_uimm16;
66666e63ce3Schristos   FLD (f_r1) = f_r1;
66766e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
66866e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
669ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_and3", "f_r2 0x%x", 'x', f_r2, "f_uimm16 0x%x", 'x', f_uimm16, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
67066e63ce3Schristos 
67166e63ce3Schristos #if WITH_PROFILE_MODEL_P
67266e63ce3Schristos   /* Record the fields for profiling.  */
67366e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
67466e63ce3Schristos     {
67566e63ce3Schristos       FLD (in_sr) = f_r2;
67666e63ce3Schristos       FLD (out_dr) = f_r1;
67766e63ce3Schristos     }
67866e63ce3Schristos #endif
67966e63ce3Schristos #undef FLD
68066e63ce3Schristos     return idesc;
68166e63ce3Schristos   }
68266e63ce3Schristos 
68366e63ce3Schristos  extract_sfmt_or3:
68466e63ce3Schristos   {
68566e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
68666e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
68766e63ce3Schristos #define FLD(f) abuf->fields.sfmt_and3.f
68866e63ce3Schristos     UINT f_r1;
68966e63ce3Schristos     UINT f_r2;
69066e63ce3Schristos     UINT f_uimm16;
69166e63ce3Schristos 
69266e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
69366e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
69466e63ce3Schristos     f_uimm16 = EXTRACT_MSB0_UINT (insn, 32, 16, 16);
69566e63ce3Schristos 
69666e63ce3Schristos   /* Record the fields for the semantic handler.  */
69766e63ce3Schristos   FLD (f_r2) = f_r2;
69866e63ce3Schristos   FLD (f_uimm16) = f_uimm16;
69966e63ce3Schristos   FLD (f_r1) = f_r1;
70066e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
70166e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
702ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_or3", "f_r2 0x%x", 'x', f_r2, "f_uimm16 0x%x", 'x', f_uimm16, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
70366e63ce3Schristos 
70466e63ce3Schristos #if WITH_PROFILE_MODEL_P
70566e63ce3Schristos   /* Record the fields for profiling.  */
70666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
70766e63ce3Schristos     {
70866e63ce3Schristos       FLD (in_sr) = f_r2;
70966e63ce3Schristos       FLD (out_dr) = f_r1;
71066e63ce3Schristos     }
71166e63ce3Schristos #endif
71266e63ce3Schristos #undef FLD
71366e63ce3Schristos     return idesc;
71466e63ce3Schristos   }
71566e63ce3Schristos 
71666e63ce3Schristos  extract_sfmt_addi:
71766e63ce3Schristos   {
71866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
71966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
72066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_addi.f
72166e63ce3Schristos     UINT f_r1;
72266e63ce3Schristos     INT f_simm8;
72366e63ce3Schristos 
72466e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
72566e63ce3Schristos     f_simm8 = EXTRACT_MSB0_SINT (insn, 16, 8, 8);
72666e63ce3Schristos 
72766e63ce3Schristos   /* Record the fields for the semantic handler.  */
72866e63ce3Schristos   FLD (f_r1) = f_r1;
72966e63ce3Schristos   FLD (f_simm8) = f_simm8;
73066e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
731ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addi", "f_r1 0x%x", 'x', f_r1, "f_simm8 0x%x", 'x', f_simm8, "dr 0x%x", 'x', f_r1, (char *) 0));
73266e63ce3Schristos 
73366e63ce3Schristos #if WITH_PROFILE_MODEL_P
73466e63ce3Schristos   /* Record the fields for profiling.  */
73566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
73666e63ce3Schristos     {
73766e63ce3Schristos       FLD (in_dr) = f_r1;
73866e63ce3Schristos       FLD (out_dr) = f_r1;
73966e63ce3Schristos     }
74066e63ce3Schristos #endif
74166e63ce3Schristos #undef FLD
74266e63ce3Schristos     return idesc;
74366e63ce3Schristos   }
74466e63ce3Schristos 
74566e63ce3Schristos  extract_sfmt_addv:
74666e63ce3Schristos   {
74766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
74866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
74966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add.f
75066e63ce3Schristos     UINT f_r1;
75166e63ce3Schristos     UINT f_r2;
75266e63ce3Schristos 
75366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
75466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
75566e63ce3Schristos 
75666e63ce3Schristos   /* Record the fields for the semantic handler.  */
75766e63ce3Schristos   FLD (f_r1) = f_r1;
75866e63ce3Schristos   FLD (f_r2) = f_r2;
75966e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
76066e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
761ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addv", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, (char *) 0));
76266e63ce3Schristos 
76366e63ce3Schristos #if WITH_PROFILE_MODEL_P
76466e63ce3Schristos   /* Record the fields for profiling.  */
76566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
76666e63ce3Schristos     {
76766e63ce3Schristos       FLD (in_dr) = f_r1;
76866e63ce3Schristos       FLD (in_sr) = f_r2;
76966e63ce3Schristos       FLD (out_dr) = f_r1;
77066e63ce3Schristos     }
77166e63ce3Schristos #endif
77266e63ce3Schristos #undef FLD
77366e63ce3Schristos     return idesc;
77466e63ce3Schristos   }
77566e63ce3Schristos 
77666e63ce3Schristos  extract_sfmt_addv3:
77766e63ce3Schristos   {
77866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
77966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
78066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
78166e63ce3Schristos     UINT f_r1;
78266e63ce3Schristos     UINT f_r2;
78366e63ce3Schristos     INT f_simm16;
78466e63ce3Schristos 
78566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
78666e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
78766e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
78866e63ce3Schristos 
78966e63ce3Schristos   /* Record the fields for the semantic handler.  */
79066e63ce3Schristos   FLD (f_simm16) = f_simm16;
79166e63ce3Schristos   FLD (f_r2) = f_r2;
79266e63ce3Schristos   FLD (f_r1) = f_r1;
79366e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
79466e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
795ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addv3", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
79666e63ce3Schristos 
79766e63ce3Schristos #if WITH_PROFILE_MODEL_P
79866e63ce3Schristos   /* Record the fields for profiling.  */
79966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
80066e63ce3Schristos     {
80166e63ce3Schristos       FLD (in_sr) = f_r2;
80266e63ce3Schristos       FLD (out_dr) = f_r1;
80366e63ce3Schristos     }
80466e63ce3Schristos #endif
80566e63ce3Schristos #undef FLD
80666e63ce3Schristos     return idesc;
80766e63ce3Schristos   }
80866e63ce3Schristos 
80966e63ce3Schristos  extract_sfmt_addx:
81066e63ce3Schristos   {
81166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
81266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
81366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add.f
81466e63ce3Schristos     UINT f_r1;
81566e63ce3Schristos     UINT f_r2;
81666e63ce3Schristos 
81766e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
81866e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
81966e63ce3Schristos 
82066e63ce3Schristos   /* Record the fields for the semantic handler.  */
82166e63ce3Schristos   FLD (f_r1) = f_r1;
82266e63ce3Schristos   FLD (f_r2) = f_r2;
82366e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
82466e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
825ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_addx", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, (char *) 0));
82666e63ce3Schristos 
82766e63ce3Schristos #if WITH_PROFILE_MODEL_P
82866e63ce3Schristos   /* Record the fields for profiling.  */
82966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
83066e63ce3Schristos     {
83166e63ce3Schristos       FLD (in_dr) = f_r1;
83266e63ce3Schristos       FLD (in_sr) = f_r2;
83366e63ce3Schristos       FLD (out_dr) = f_r1;
83466e63ce3Schristos     }
83566e63ce3Schristos #endif
83666e63ce3Schristos #undef FLD
83766e63ce3Schristos     return idesc;
83866e63ce3Schristos   }
83966e63ce3Schristos 
84066e63ce3Schristos  extract_sfmt_bc8:
84166e63ce3Schristos   {
84266e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
84366e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
84466e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bl8.f
84566e63ce3Schristos     SI f_disp8;
84666e63ce3Schristos 
84766e63ce3Schristos     f_disp8 = ((((EXTRACT_MSB0_SINT (insn, 16, 8, 8)) << (2))) + (((pc) & (-4))));
84866e63ce3Schristos 
84966e63ce3Schristos   /* Record the fields for the semantic handler.  */
85066e63ce3Schristos   FLD (i_disp8) = f_disp8;
851ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bc8", "disp8 0x%x", 'x', f_disp8, (char *) 0));
85266e63ce3Schristos 
85366e63ce3Schristos #if WITH_PROFILE_MODEL_P
85466e63ce3Schristos   /* Record the fields for profiling.  */
85566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
85666e63ce3Schristos     {
85766e63ce3Schristos     }
85866e63ce3Schristos #endif
85966e63ce3Schristos #undef FLD
86066e63ce3Schristos     return idesc;
86166e63ce3Schristos   }
86266e63ce3Schristos 
86366e63ce3Schristos  extract_sfmt_bc24:
86466e63ce3Schristos   {
86566e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
86666e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
86766e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bl24.f
86866e63ce3Schristos     SI f_disp24;
86966e63ce3Schristos 
87066e63ce3Schristos     f_disp24 = ((((EXTRACT_MSB0_SINT (insn, 32, 8, 24)) << (2))) + (pc));
87166e63ce3Schristos 
87266e63ce3Schristos   /* Record the fields for the semantic handler.  */
87366e63ce3Schristos   FLD (i_disp24) = f_disp24;
874ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bc24", "disp24 0x%x", 'x', f_disp24, (char *) 0));
87566e63ce3Schristos 
87666e63ce3Schristos #if WITH_PROFILE_MODEL_P
87766e63ce3Schristos   /* Record the fields for profiling.  */
87866e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
87966e63ce3Schristos     {
88066e63ce3Schristos     }
88166e63ce3Schristos #endif
88266e63ce3Schristos #undef FLD
88366e63ce3Schristos     return idesc;
88466e63ce3Schristos   }
88566e63ce3Schristos 
88666e63ce3Schristos  extract_sfmt_beq:
88766e63ce3Schristos   {
88866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
88966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
89066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_beq.f
89166e63ce3Schristos     UINT f_r1;
89266e63ce3Schristos     UINT f_r2;
89366e63ce3Schristos     SI f_disp16;
89466e63ce3Schristos 
89566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
89666e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
89766e63ce3Schristos     f_disp16 = ((((EXTRACT_MSB0_SINT (insn, 32, 16, 16)) << (2))) + (pc));
89866e63ce3Schristos 
89966e63ce3Schristos   /* Record the fields for the semantic handler.  */
90066e63ce3Schristos   FLD (f_r1) = f_r1;
90166e63ce3Schristos   FLD (f_r2) = f_r2;
90266e63ce3Schristos   FLD (i_disp16) = f_disp16;
90366e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
90466e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
905ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_beq", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "disp16 0x%x", 'x', f_disp16, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
90666e63ce3Schristos 
90766e63ce3Schristos #if WITH_PROFILE_MODEL_P
90866e63ce3Schristos   /* Record the fields for profiling.  */
90966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
91066e63ce3Schristos     {
91166e63ce3Schristos       FLD (in_src1) = f_r1;
91266e63ce3Schristos       FLD (in_src2) = f_r2;
91366e63ce3Schristos     }
91466e63ce3Schristos #endif
91566e63ce3Schristos #undef FLD
91666e63ce3Schristos     return idesc;
91766e63ce3Schristos   }
91866e63ce3Schristos 
91966e63ce3Schristos  extract_sfmt_beqz:
92066e63ce3Schristos   {
92166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
92266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
92366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_beq.f
92466e63ce3Schristos     UINT f_r2;
92566e63ce3Schristos     SI f_disp16;
92666e63ce3Schristos 
92766e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
92866e63ce3Schristos     f_disp16 = ((((EXTRACT_MSB0_SINT (insn, 32, 16, 16)) << (2))) + (pc));
92966e63ce3Schristos 
93066e63ce3Schristos   /* Record the fields for the semantic handler.  */
93166e63ce3Schristos   FLD (f_r2) = f_r2;
93266e63ce3Schristos   FLD (i_disp16) = f_disp16;
93366e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
934ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_beqz", "f_r2 0x%x", 'x', f_r2, "disp16 0x%x", 'x', f_disp16, "src2 0x%x", 'x', f_r2, (char *) 0));
93566e63ce3Schristos 
93666e63ce3Schristos #if WITH_PROFILE_MODEL_P
93766e63ce3Schristos   /* Record the fields for profiling.  */
93866e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
93966e63ce3Schristos     {
94066e63ce3Schristos       FLD (in_src2) = f_r2;
94166e63ce3Schristos     }
94266e63ce3Schristos #endif
94366e63ce3Schristos #undef FLD
94466e63ce3Schristos     return idesc;
94566e63ce3Schristos   }
94666e63ce3Schristos 
94766e63ce3Schristos  extract_sfmt_bl8:
94866e63ce3Schristos   {
94966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
95066e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
95166e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bl8.f
95266e63ce3Schristos     SI f_disp8;
95366e63ce3Schristos 
95466e63ce3Schristos     f_disp8 = ((((EXTRACT_MSB0_SINT (insn, 16, 8, 8)) << (2))) + (((pc) & (-4))));
95566e63ce3Schristos 
95666e63ce3Schristos   /* Record the fields for the semantic handler.  */
95766e63ce3Schristos   FLD (i_disp8) = f_disp8;
958ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bl8", "disp8 0x%x", 'x', f_disp8, (char *) 0));
95966e63ce3Schristos 
96066e63ce3Schristos #if WITH_PROFILE_MODEL_P
96166e63ce3Schristos   /* Record the fields for profiling.  */
96266e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
96366e63ce3Schristos     {
96466e63ce3Schristos       FLD (out_h_gr_SI_14) = 14;
96566e63ce3Schristos     }
96666e63ce3Schristos #endif
96766e63ce3Schristos #undef FLD
96866e63ce3Schristos     return idesc;
96966e63ce3Schristos   }
97066e63ce3Schristos 
97166e63ce3Schristos  extract_sfmt_bl24:
97266e63ce3Schristos   {
97366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
97466e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
97566e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bl24.f
97666e63ce3Schristos     SI f_disp24;
97766e63ce3Schristos 
97866e63ce3Schristos     f_disp24 = ((((EXTRACT_MSB0_SINT (insn, 32, 8, 24)) << (2))) + (pc));
97966e63ce3Schristos 
98066e63ce3Schristos   /* Record the fields for the semantic handler.  */
98166e63ce3Schristos   FLD (i_disp24) = f_disp24;
982ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bl24", "disp24 0x%x", 'x', f_disp24, (char *) 0));
98366e63ce3Schristos 
98466e63ce3Schristos #if WITH_PROFILE_MODEL_P
98566e63ce3Schristos   /* Record the fields for profiling.  */
98666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
98766e63ce3Schristos     {
98866e63ce3Schristos       FLD (out_h_gr_SI_14) = 14;
98966e63ce3Schristos     }
99066e63ce3Schristos #endif
99166e63ce3Schristos #undef FLD
99266e63ce3Schristos     return idesc;
99366e63ce3Schristos   }
99466e63ce3Schristos 
99566e63ce3Schristos  extract_sfmt_bra8:
99666e63ce3Schristos   {
99766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
99866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
99966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bl8.f
100066e63ce3Schristos     SI f_disp8;
100166e63ce3Schristos 
100266e63ce3Schristos     f_disp8 = ((((EXTRACT_MSB0_SINT (insn, 16, 8, 8)) << (2))) + (((pc) & (-4))));
100366e63ce3Schristos 
100466e63ce3Schristos   /* Record the fields for the semantic handler.  */
100566e63ce3Schristos   FLD (i_disp8) = f_disp8;
1006ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bra8", "disp8 0x%x", 'x', f_disp8, (char *) 0));
100766e63ce3Schristos 
100866e63ce3Schristos #if WITH_PROFILE_MODEL_P
100966e63ce3Schristos   /* Record the fields for profiling.  */
101066e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
101166e63ce3Schristos     {
101266e63ce3Schristos     }
101366e63ce3Schristos #endif
101466e63ce3Schristos #undef FLD
101566e63ce3Schristos     return idesc;
101666e63ce3Schristos   }
101766e63ce3Schristos 
101866e63ce3Schristos  extract_sfmt_bra24:
101966e63ce3Schristos   {
102066e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
102166e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
102266e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bl24.f
102366e63ce3Schristos     SI f_disp24;
102466e63ce3Schristos 
102566e63ce3Schristos     f_disp24 = ((((EXTRACT_MSB0_SINT (insn, 32, 8, 24)) << (2))) + (pc));
102666e63ce3Schristos 
102766e63ce3Schristos   /* Record the fields for the semantic handler.  */
102866e63ce3Schristos   FLD (i_disp24) = f_disp24;
1029ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bra24", "disp24 0x%x", 'x', f_disp24, (char *) 0));
103066e63ce3Schristos 
103166e63ce3Schristos #if WITH_PROFILE_MODEL_P
103266e63ce3Schristos   /* Record the fields for profiling.  */
103366e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
103466e63ce3Schristos     {
103566e63ce3Schristos     }
103666e63ce3Schristos #endif
103766e63ce3Schristos #undef FLD
103866e63ce3Schristos     return idesc;
103966e63ce3Schristos   }
104066e63ce3Schristos 
104166e63ce3Schristos  extract_sfmt_cmp:
104266e63ce3Schristos   {
104366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
104466e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
104566e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
104666e63ce3Schristos     UINT f_r1;
104766e63ce3Schristos     UINT f_r2;
104866e63ce3Schristos 
104966e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
105066e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
105166e63ce3Schristos 
105266e63ce3Schristos   /* Record the fields for the semantic handler.  */
105366e63ce3Schristos   FLD (f_r1) = f_r1;
105466e63ce3Schristos   FLD (f_r2) = f_r2;
105566e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
105666e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1057ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmp", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
105866e63ce3Schristos 
105966e63ce3Schristos #if WITH_PROFILE_MODEL_P
106066e63ce3Schristos   /* Record the fields for profiling.  */
106166e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
106266e63ce3Schristos     {
106366e63ce3Schristos       FLD (in_src1) = f_r1;
106466e63ce3Schristos       FLD (in_src2) = f_r2;
106566e63ce3Schristos     }
106666e63ce3Schristos #endif
106766e63ce3Schristos #undef FLD
106866e63ce3Schristos     return idesc;
106966e63ce3Schristos   }
107066e63ce3Schristos 
107166e63ce3Schristos  extract_sfmt_cmpi:
107266e63ce3Schristos   {
107366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
107466e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
107566e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_d.f
107666e63ce3Schristos     UINT f_r2;
107766e63ce3Schristos     INT f_simm16;
107866e63ce3Schristos 
107966e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
108066e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
108166e63ce3Schristos 
108266e63ce3Schristos   /* Record the fields for the semantic handler.  */
108366e63ce3Schristos   FLD (f_simm16) = f_simm16;
108466e63ce3Schristos   FLD (f_r2) = f_r2;
108566e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1086ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_cmpi", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "src2 0x%x", 'x', f_r2, (char *) 0));
108766e63ce3Schristos 
108866e63ce3Schristos #if WITH_PROFILE_MODEL_P
108966e63ce3Schristos   /* Record the fields for profiling.  */
109066e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
109166e63ce3Schristos     {
109266e63ce3Schristos       FLD (in_src2) = f_r2;
109366e63ce3Schristos     }
109466e63ce3Schristos #endif
109566e63ce3Schristos #undef FLD
109666e63ce3Schristos     return idesc;
109766e63ce3Schristos   }
109866e63ce3Schristos 
109966e63ce3Schristos  extract_sfmt_div:
110066e63ce3Schristos   {
110166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
110266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
110366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add.f
110466e63ce3Schristos     UINT f_r1;
110566e63ce3Schristos     UINT f_r2;
110666e63ce3Schristos 
110766e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
110866e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
110966e63ce3Schristos 
111066e63ce3Schristos   /* Record the fields for the semantic handler.  */
111166e63ce3Schristos   FLD (f_r1) = f_r1;
111266e63ce3Schristos   FLD (f_r2) = f_r2;
111366e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
111466e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
1115ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_div", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, (char *) 0));
111666e63ce3Schristos 
111766e63ce3Schristos #if WITH_PROFILE_MODEL_P
111866e63ce3Schristos   /* Record the fields for profiling.  */
111966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
112066e63ce3Schristos     {
112166e63ce3Schristos       FLD (in_dr) = f_r1;
112266e63ce3Schristos       FLD (in_sr) = f_r2;
112366e63ce3Schristos       FLD (out_dr) = f_r1;
112466e63ce3Schristos     }
112566e63ce3Schristos #endif
112666e63ce3Schristos #undef FLD
112766e63ce3Schristos     return idesc;
112866e63ce3Schristos   }
112966e63ce3Schristos 
113066e63ce3Schristos  extract_sfmt_jl:
113166e63ce3Schristos   {
113266e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
113366e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
113466e63ce3Schristos #define FLD(f) abuf->fields.sfmt_jl.f
113566e63ce3Schristos     UINT f_r2;
113666e63ce3Schristos 
113766e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
113866e63ce3Schristos 
113966e63ce3Schristos   /* Record the fields for the semantic handler.  */
114066e63ce3Schristos   FLD (f_r2) = f_r2;
114166e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
1142ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jl", "f_r2 0x%x", 'x', f_r2, "sr 0x%x", 'x', f_r2, (char *) 0));
114366e63ce3Schristos 
114466e63ce3Schristos #if WITH_PROFILE_MODEL_P
114566e63ce3Schristos   /* Record the fields for profiling.  */
114666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
114766e63ce3Schristos     {
114866e63ce3Schristos       FLD (in_sr) = f_r2;
114966e63ce3Schristos       FLD (out_h_gr_SI_14) = 14;
115066e63ce3Schristos     }
115166e63ce3Schristos #endif
115266e63ce3Schristos #undef FLD
115366e63ce3Schristos     return idesc;
115466e63ce3Schristos   }
115566e63ce3Schristos 
115666e63ce3Schristos  extract_sfmt_jmp:
115766e63ce3Schristos   {
115866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
115966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
116066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_jl.f
116166e63ce3Schristos     UINT f_r2;
116266e63ce3Schristos 
116366e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
116466e63ce3Schristos 
116566e63ce3Schristos   /* Record the fields for the semantic handler.  */
116666e63ce3Schristos   FLD (f_r2) = f_r2;
116766e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
1168ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_jmp", "f_r2 0x%x", 'x', f_r2, "sr 0x%x", 'x', f_r2, (char *) 0));
116966e63ce3Schristos 
117066e63ce3Schristos #if WITH_PROFILE_MODEL_P
117166e63ce3Schristos   /* Record the fields for profiling.  */
117266e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
117366e63ce3Schristos     {
117466e63ce3Schristos       FLD (in_sr) = f_r2;
117566e63ce3Schristos     }
117666e63ce3Schristos #endif
117766e63ce3Schristos #undef FLD
117866e63ce3Schristos     return idesc;
117966e63ce3Schristos   }
118066e63ce3Schristos 
118166e63ce3Schristos  extract_sfmt_ld:
118266e63ce3Schristos   {
118366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
118466e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
118566e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
118666e63ce3Schristos     UINT f_r1;
118766e63ce3Schristos     UINT f_r2;
118866e63ce3Schristos 
118966e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
119066e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
119166e63ce3Schristos 
119266e63ce3Schristos   /* Record the fields for the semantic handler.  */
119366e63ce3Schristos   FLD (f_r2) = f_r2;
119466e63ce3Schristos   FLD (f_r1) = f_r1;
119566e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
119666e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1197ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ld", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
119866e63ce3Schristos 
119966e63ce3Schristos #if WITH_PROFILE_MODEL_P
120066e63ce3Schristos   /* Record the fields for profiling.  */
120166e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
120266e63ce3Schristos     {
120366e63ce3Schristos       FLD (in_sr) = f_r2;
120466e63ce3Schristos       FLD (out_dr) = f_r1;
120566e63ce3Schristos     }
120666e63ce3Schristos #endif
120766e63ce3Schristos #undef FLD
120866e63ce3Schristos     return idesc;
120966e63ce3Schristos   }
121066e63ce3Schristos 
121166e63ce3Schristos  extract_sfmt_ld_d:
121266e63ce3Schristos   {
121366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
121466e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
121566e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
121666e63ce3Schristos     UINT f_r1;
121766e63ce3Schristos     UINT f_r2;
121866e63ce3Schristos     INT f_simm16;
121966e63ce3Schristos 
122066e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
122166e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
122266e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
122366e63ce3Schristos 
122466e63ce3Schristos   /* Record the fields for the semantic handler.  */
122566e63ce3Schristos   FLD (f_simm16) = f_simm16;
122666e63ce3Schristos   FLD (f_r2) = f_r2;
122766e63ce3Schristos   FLD (f_r1) = f_r1;
122866e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
122966e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1230ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ld_d", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
123166e63ce3Schristos 
123266e63ce3Schristos #if WITH_PROFILE_MODEL_P
123366e63ce3Schristos   /* Record the fields for profiling.  */
123466e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
123566e63ce3Schristos     {
123666e63ce3Schristos       FLD (in_sr) = f_r2;
123766e63ce3Schristos       FLD (out_dr) = f_r1;
123866e63ce3Schristos     }
123966e63ce3Schristos #endif
124066e63ce3Schristos #undef FLD
124166e63ce3Schristos     return idesc;
124266e63ce3Schristos   }
124366e63ce3Schristos 
124466e63ce3Schristos  extract_sfmt_ldb:
124566e63ce3Schristos   {
124666e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
124766e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
124866e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
124966e63ce3Schristos     UINT f_r1;
125066e63ce3Schristos     UINT f_r2;
125166e63ce3Schristos 
125266e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
125366e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
125466e63ce3Schristos 
125566e63ce3Schristos   /* Record the fields for the semantic handler.  */
125666e63ce3Schristos   FLD (f_r2) = f_r2;
125766e63ce3Schristos   FLD (f_r1) = f_r1;
125866e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
125966e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1260ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldb", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
126166e63ce3Schristos 
126266e63ce3Schristos #if WITH_PROFILE_MODEL_P
126366e63ce3Schristos   /* Record the fields for profiling.  */
126466e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
126566e63ce3Schristos     {
126666e63ce3Schristos       FLD (in_sr) = f_r2;
126766e63ce3Schristos       FLD (out_dr) = f_r1;
126866e63ce3Schristos     }
126966e63ce3Schristos #endif
127066e63ce3Schristos #undef FLD
127166e63ce3Schristos     return idesc;
127266e63ce3Schristos   }
127366e63ce3Schristos 
127466e63ce3Schristos  extract_sfmt_ldb_d:
127566e63ce3Schristos   {
127666e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
127766e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
127866e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
127966e63ce3Schristos     UINT f_r1;
128066e63ce3Schristos     UINT f_r2;
128166e63ce3Schristos     INT f_simm16;
128266e63ce3Schristos 
128366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
128466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
128566e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
128666e63ce3Schristos 
128766e63ce3Schristos   /* Record the fields for the semantic handler.  */
128866e63ce3Schristos   FLD (f_simm16) = f_simm16;
128966e63ce3Schristos   FLD (f_r2) = f_r2;
129066e63ce3Schristos   FLD (f_r1) = f_r1;
129166e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
129266e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1293ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldb_d", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
129466e63ce3Schristos 
129566e63ce3Schristos #if WITH_PROFILE_MODEL_P
129666e63ce3Schristos   /* Record the fields for profiling.  */
129766e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
129866e63ce3Schristos     {
129966e63ce3Schristos       FLD (in_sr) = f_r2;
130066e63ce3Schristos       FLD (out_dr) = f_r1;
130166e63ce3Schristos     }
130266e63ce3Schristos #endif
130366e63ce3Schristos #undef FLD
130466e63ce3Schristos     return idesc;
130566e63ce3Schristos   }
130666e63ce3Schristos 
130766e63ce3Schristos  extract_sfmt_ldh:
130866e63ce3Schristos   {
130966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
131066e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
131166e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
131266e63ce3Schristos     UINT f_r1;
131366e63ce3Schristos     UINT f_r2;
131466e63ce3Schristos 
131566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
131666e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
131766e63ce3Schristos 
131866e63ce3Schristos   /* Record the fields for the semantic handler.  */
131966e63ce3Schristos   FLD (f_r2) = f_r2;
132066e63ce3Schristos   FLD (f_r1) = f_r1;
132166e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
132266e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1323ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldh", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
132466e63ce3Schristos 
132566e63ce3Schristos #if WITH_PROFILE_MODEL_P
132666e63ce3Schristos   /* Record the fields for profiling.  */
132766e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
132866e63ce3Schristos     {
132966e63ce3Schristos       FLD (in_sr) = f_r2;
133066e63ce3Schristos       FLD (out_dr) = f_r1;
133166e63ce3Schristos     }
133266e63ce3Schristos #endif
133366e63ce3Schristos #undef FLD
133466e63ce3Schristos     return idesc;
133566e63ce3Schristos   }
133666e63ce3Schristos 
133766e63ce3Schristos  extract_sfmt_ldh_d:
133866e63ce3Schristos   {
133966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
134066e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
134166e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
134266e63ce3Schristos     UINT f_r1;
134366e63ce3Schristos     UINT f_r2;
134466e63ce3Schristos     INT f_simm16;
134566e63ce3Schristos 
134666e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
134766e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
134866e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
134966e63ce3Schristos 
135066e63ce3Schristos   /* Record the fields for the semantic handler.  */
135166e63ce3Schristos   FLD (f_simm16) = f_simm16;
135266e63ce3Schristos   FLD (f_r2) = f_r2;
135366e63ce3Schristos   FLD (f_r1) = f_r1;
135466e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
135566e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1356ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldh_d", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
135766e63ce3Schristos 
135866e63ce3Schristos #if WITH_PROFILE_MODEL_P
135966e63ce3Schristos   /* Record the fields for profiling.  */
136066e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
136166e63ce3Schristos     {
136266e63ce3Schristos       FLD (in_sr) = f_r2;
136366e63ce3Schristos       FLD (out_dr) = f_r1;
136466e63ce3Schristos     }
136566e63ce3Schristos #endif
136666e63ce3Schristos #undef FLD
136766e63ce3Schristos     return idesc;
136866e63ce3Schristos   }
136966e63ce3Schristos 
137066e63ce3Schristos  extract_sfmt_ld_plus:
137166e63ce3Schristos   {
137266e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
137366e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
137466e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
137566e63ce3Schristos     UINT f_r1;
137666e63ce3Schristos     UINT f_r2;
137766e63ce3Schristos 
137866e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
137966e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
138066e63ce3Schristos 
138166e63ce3Schristos   /* Record the fields for the semantic handler.  */
138266e63ce3Schristos   FLD (f_r2) = f_r2;
138366e63ce3Schristos   FLD (f_r1) = f_r1;
138466e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
138566e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1386ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ld_plus", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
138766e63ce3Schristos 
138866e63ce3Schristos #if WITH_PROFILE_MODEL_P
138966e63ce3Schristos   /* Record the fields for profiling.  */
139066e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
139166e63ce3Schristos     {
139266e63ce3Schristos       FLD (in_sr) = f_r2;
139366e63ce3Schristos       FLD (out_dr) = f_r1;
139466e63ce3Schristos       FLD (out_sr) = f_r2;
139566e63ce3Schristos     }
139666e63ce3Schristos #endif
139766e63ce3Schristos #undef FLD
139866e63ce3Schristos     return idesc;
139966e63ce3Schristos   }
140066e63ce3Schristos 
140166e63ce3Schristos  extract_sfmt_ld24:
140266e63ce3Schristos   {
140366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
140466e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
140566e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld24.f
140666e63ce3Schristos     UINT f_r1;
140766e63ce3Schristos     UINT f_uimm24;
140866e63ce3Schristos 
140966e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
141066e63ce3Schristos     f_uimm24 = EXTRACT_MSB0_UINT (insn, 32, 8, 24);
141166e63ce3Schristos 
141266e63ce3Schristos   /* Record the fields for the semantic handler.  */
141366e63ce3Schristos   FLD (f_r1) = f_r1;
141466e63ce3Schristos   FLD (i_uimm24) = f_uimm24;
141566e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1416ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ld24", "f_r1 0x%x", 'x', f_r1, "uimm24 0x%x", 'x', f_uimm24, "dr 0x%x", 'x', f_r1, (char *) 0));
141766e63ce3Schristos 
141866e63ce3Schristos #if WITH_PROFILE_MODEL_P
141966e63ce3Schristos   /* Record the fields for profiling.  */
142066e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
142166e63ce3Schristos     {
142266e63ce3Schristos       FLD (out_dr) = f_r1;
142366e63ce3Schristos     }
142466e63ce3Schristos #endif
142566e63ce3Schristos #undef FLD
142666e63ce3Schristos     return idesc;
142766e63ce3Schristos   }
142866e63ce3Schristos 
142966e63ce3Schristos  extract_sfmt_ldi8:
143066e63ce3Schristos   {
143166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
143266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
143366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_addi.f
143466e63ce3Schristos     UINT f_r1;
143566e63ce3Schristos     INT f_simm8;
143666e63ce3Schristos 
143766e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
143866e63ce3Schristos     f_simm8 = EXTRACT_MSB0_SINT (insn, 16, 8, 8);
143966e63ce3Schristos 
144066e63ce3Schristos   /* Record the fields for the semantic handler.  */
144166e63ce3Schristos   FLD (f_simm8) = f_simm8;
144266e63ce3Schristos   FLD (f_r1) = f_r1;
144366e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1444ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi8", "f_simm8 0x%x", 'x', f_simm8, "f_r1 0x%x", 'x', f_r1, "dr 0x%x", 'x', f_r1, (char *) 0));
144566e63ce3Schristos 
144666e63ce3Schristos #if WITH_PROFILE_MODEL_P
144766e63ce3Schristos   /* Record the fields for profiling.  */
144866e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
144966e63ce3Schristos     {
145066e63ce3Schristos       FLD (out_dr) = f_r1;
145166e63ce3Schristos     }
145266e63ce3Schristos #endif
145366e63ce3Schristos #undef FLD
145466e63ce3Schristos     return idesc;
145566e63ce3Schristos   }
145666e63ce3Schristos 
145766e63ce3Schristos  extract_sfmt_ldi16:
145866e63ce3Schristos   {
145966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
146066e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
146166e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
146266e63ce3Schristos     UINT f_r1;
146366e63ce3Schristos     INT f_simm16;
146466e63ce3Schristos 
146566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
146666e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
146766e63ce3Schristos 
146866e63ce3Schristos   /* Record the fields for the semantic handler.  */
146966e63ce3Schristos   FLD (f_simm16) = f_simm16;
147066e63ce3Schristos   FLD (f_r1) = f_r1;
147166e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1472ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_ldi16", "f_simm16 0x%x", 'x', f_simm16, "f_r1 0x%x", 'x', f_r1, "dr 0x%x", 'x', f_r1, (char *) 0));
147366e63ce3Schristos 
147466e63ce3Schristos #if WITH_PROFILE_MODEL_P
147566e63ce3Schristos   /* Record the fields for profiling.  */
147666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
147766e63ce3Schristos     {
147866e63ce3Schristos       FLD (out_dr) = f_r1;
147966e63ce3Schristos     }
148066e63ce3Schristos #endif
148166e63ce3Schristos #undef FLD
148266e63ce3Schristos     return idesc;
148366e63ce3Schristos   }
148466e63ce3Schristos 
148566e63ce3Schristos  extract_sfmt_lock:
148666e63ce3Schristos   {
148766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
148866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
148966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
149066e63ce3Schristos     UINT f_r1;
149166e63ce3Schristos     UINT f_r2;
149266e63ce3Schristos 
149366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
149466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
149566e63ce3Schristos 
149666e63ce3Schristos   /* Record the fields for the semantic handler.  */
149766e63ce3Schristos   FLD (f_r2) = f_r2;
149866e63ce3Schristos   FLD (f_r1) = f_r1;
149966e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
150066e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1501ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_lock", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
150266e63ce3Schristos 
150366e63ce3Schristos #if WITH_PROFILE_MODEL_P
150466e63ce3Schristos   /* Record the fields for profiling.  */
150566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
150666e63ce3Schristos     {
150766e63ce3Schristos       FLD (in_sr) = f_r2;
150866e63ce3Schristos       FLD (out_dr) = f_r1;
150966e63ce3Schristos     }
151066e63ce3Schristos #endif
151166e63ce3Schristos #undef FLD
151266e63ce3Schristos     return idesc;
151366e63ce3Schristos   }
151466e63ce3Schristos 
151566e63ce3Schristos  extract_sfmt_machi:
151666e63ce3Schristos   {
151766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
151866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
151966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
152066e63ce3Schristos     UINT f_r1;
152166e63ce3Schristos     UINT f_r2;
152266e63ce3Schristos 
152366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
152466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
152566e63ce3Schristos 
152666e63ce3Schristos   /* Record the fields for the semantic handler.  */
152766e63ce3Schristos   FLD (f_r1) = f_r1;
152866e63ce3Schristos   FLD (f_r2) = f_r2;
152966e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
153066e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1531ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_machi", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
153266e63ce3Schristos 
153366e63ce3Schristos #if WITH_PROFILE_MODEL_P
153466e63ce3Schristos   /* Record the fields for profiling.  */
153566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
153666e63ce3Schristos     {
153766e63ce3Schristos       FLD (in_src1) = f_r1;
153866e63ce3Schristos       FLD (in_src2) = f_r2;
153966e63ce3Schristos     }
154066e63ce3Schristos #endif
154166e63ce3Schristos #undef FLD
154266e63ce3Schristos     return idesc;
154366e63ce3Schristos   }
154466e63ce3Schristos 
154566e63ce3Schristos  extract_sfmt_mulhi:
154666e63ce3Schristos   {
154766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
154866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
154966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
155066e63ce3Schristos     UINT f_r1;
155166e63ce3Schristos     UINT f_r2;
155266e63ce3Schristos 
155366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
155466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
155566e63ce3Schristos 
155666e63ce3Schristos   /* Record the fields for the semantic handler.  */
155766e63ce3Schristos   FLD (f_r1) = f_r1;
155866e63ce3Schristos   FLD (f_r2) = f_r2;
155966e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
156066e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1561ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mulhi", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
156266e63ce3Schristos 
156366e63ce3Schristos #if WITH_PROFILE_MODEL_P
156466e63ce3Schristos   /* Record the fields for profiling.  */
156566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
156666e63ce3Schristos     {
156766e63ce3Schristos       FLD (in_src1) = f_r1;
156866e63ce3Schristos       FLD (in_src2) = f_r2;
156966e63ce3Schristos     }
157066e63ce3Schristos #endif
157166e63ce3Schristos #undef FLD
157266e63ce3Schristos     return idesc;
157366e63ce3Schristos   }
157466e63ce3Schristos 
157566e63ce3Schristos  extract_sfmt_mv:
157666e63ce3Schristos   {
157766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
157866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
157966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
158066e63ce3Schristos     UINT f_r1;
158166e63ce3Schristos     UINT f_r2;
158266e63ce3Schristos 
158366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
158466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
158566e63ce3Schristos 
158666e63ce3Schristos   /* Record the fields for the semantic handler.  */
158766e63ce3Schristos   FLD (f_r2) = f_r2;
158866e63ce3Schristos   FLD (f_r1) = f_r1;
158966e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
159066e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1591ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mv", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
159266e63ce3Schristos 
159366e63ce3Schristos #if WITH_PROFILE_MODEL_P
159466e63ce3Schristos   /* Record the fields for profiling.  */
159566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
159666e63ce3Schristos     {
159766e63ce3Schristos       FLD (in_sr) = f_r2;
159866e63ce3Schristos       FLD (out_dr) = f_r1;
159966e63ce3Schristos     }
160066e63ce3Schristos #endif
160166e63ce3Schristos #undef FLD
160266e63ce3Schristos     return idesc;
160366e63ce3Schristos   }
160466e63ce3Schristos 
160566e63ce3Schristos  extract_sfmt_mvfachi:
160666e63ce3Schristos   {
160766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
160866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
160966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_seth.f
161066e63ce3Schristos     UINT f_r1;
161166e63ce3Schristos 
161266e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
161366e63ce3Schristos 
161466e63ce3Schristos   /* Record the fields for the semantic handler.  */
161566e63ce3Schristos   FLD (f_r1) = f_r1;
161666e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1617ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mvfachi", "f_r1 0x%x", 'x', f_r1, "dr 0x%x", 'x', f_r1, (char *) 0));
161866e63ce3Schristos 
161966e63ce3Schristos #if WITH_PROFILE_MODEL_P
162066e63ce3Schristos   /* Record the fields for profiling.  */
162166e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
162266e63ce3Schristos     {
162366e63ce3Schristos       FLD (out_dr) = f_r1;
162466e63ce3Schristos     }
162566e63ce3Schristos #endif
162666e63ce3Schristos #undef FLD
162766e63ce3Schristos     return idesc;
162866e63ce3Schristos   }
162966e63ce3Schristos 
163066e63ce3Schristos  extract_sfmt_mvfc:
163166e63ce3Schristos   {
163266e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
163366e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
163466e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
163566e63ce3Schristos     UINT f_r1;
163666e63ce3Schristos     UINT f_r2;
163766e63ce3Schristos 
163866e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
163966e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
164066e63ce3Schristos 
164166e63ce3Schristos   /* Record the fields for the semantic handler.  */
164266e63ce3Schristos   FLD (f_r2) = f_r2;
164366e63ce3Schristos   FLD (f_r1) = f_r1;
164466e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1645ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mvfc", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "dr 0x%x", 'x', f_r1, (char *) 0));
164666e63ce3Schristos 
164766e63ce3Schristos #if WITH_PROFILE_MODEL_P
164866e63ce3Schristos   /* Record the fields for profiling.  */
164966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
165066e63ce3Schristos     {
165166e63ce3Schristos       FLD (out_dr) = f_r1;
165266e63ce3Schristos     }
165366e63ce3Schristos #endif
165466e63ce3Schristos #undef FLD
165566e63ce3Schristos     return idesc;
165666e63ce3Schristos   }
165766e63ce3Schristos 
165866e63ce3Schristos  extract_sfmt_mvtachi:
165966e63ce3Schristos   {
166066e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
166166e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
166266e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
166366e63ce3Schristos     UINT f_r1;
166466e63ce3Schristos 
166566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
166666e63ce3Schristos 
166766e63ce3Schristos   /* Record the fields for the semantic handler.  */
166866e63ce3Schristos   FLD (f_r1) = f_r1;
166966e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
1670ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mvtachi", "f_r1 0x%x", 'x', f_r1, "src1 0x%x", 'x', f_r1, (char *) 0));
167166e63ce3Schristos 
167266e63ce3Schristos #if WITH_PROFILE_MODEL_P
167366e63ce3Schristos   /* Record the fields for profiling.  */
167466e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
167566e63ce3Schristos     {
167666e63ce3Schristos       FLD (in_src1) = f_r1;
167766e63ce3Schristos     }
167866e63ce3Schristos #endif
167966e63ce3Schristos #undef FLD
168066e63ce3Schristos     return idesc;
168166e63ce3Schristos   }
168266e63ce3Schristos 
168366e63ce3Schristos  extract_sfmt_mvtc:
168466e63ce3Schristos   {
168566e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
168666e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
168766e63ce3Schristos #define FLD(f) abuf->fields.sfmt_ld_plus.f
168866e63ce3Schristos     UINT f_r1;
168966e63ce3Schristos     UINT f_r2;
169066e63ce3Schristos 
169166e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
169266e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
169366e63ce3Schristos 
169466e63ce3Schristos   /* Record the fields for the semantic handler.  */
169566e63ce3Schristos   FLD (f_r2) = f_r2;
169666e63ce3Schristos   FLD (f_r1) = f_r1;
169766e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
1698ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_mvtc", "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, (char *) 0));
169966e63ce3Schristos 
170066e63ce3Schristos #if WITH_PROFILE_MODEL_P
170166e63ce3Schristos   /* Record the fields for profiling.  */
170266e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
170366e63ce3Schristos     {
170466e63ce3Schristos       FLD (in_sr) = f_r2;
170566e63ce3Schristos     }
170666e63ce3Schristos #endif
170766e63ce3Schristos #undef FLD
170866e63ce3Schristos     return idesc;
170966e63ce3Schristos   }
171066e63ce3Schristos 
171166e63ce3Schristos  extract_sfmt_nop:
171266e63ce3Schristos   {
171366e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
171466e63ce3Schristos #define FLD(f) abuf->fields.sfmt_empty.f
171566e63ce3Schristos 
171666e63ce3Schristos 
171766e63ce3Schristos   /* Record the fields for the semantic handler.  */
1718ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_nop", (char *) 0));
171966e63ce3Schristos 
172066e63ce3Schristos #undef FLD
172166e63ce3Schristos     return idesc;
172266e63ce3Schristos   }
172366e63ce3Schristos 
172466e63ce3Schristos  extract_sfmt_rac:
172566e63ce3Schristos   {
172666e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
172766e63ce3Schristos #define FLD(f) abuf->fields.sfmt_empty.f
172866e63ce3Schristos 
172966e63ce3Schristos 
173066e63ce3Schristos   /* Record the fields for the semantic handler.  */
1731ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_rac", (char *) 0));
173266e63ce3Schristos 
173366e63ce3Schristos #undef FLD
173466e63ce3Schristos     return idesc;
173566e63ce3Schristos   }
173666e63ce3Schristos 
173766e63ce3Schristos  extract_sfmt_rte:
173866e63ce3Schristos   {
173966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
174066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_empty.f
174166e63ce3Schristos 
174266e63ce3Schristos 
174366e63ce3Schristos   /* Record the fields for the semantic handler.  */
1744ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_rte", (char *) 0));
174566e63ce3Schristos 
174666e63ce3Schristos #if WITH_PROFILE_MODEL_P
174766e63ce3Schristos   /* Record the fields for profiling.  */
174866e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
174966e63ce3Schristos     {
175066e63ce3Schristos     }
175166e63ce3Schristos #endif
175266e63ce3Schristos #undef FLD
175366e63ce3Schristos     return idesc;
175466e63ce3Schristos   }
175566e63ce3Schristos 
175666e63ce3Schristos  extract_sfmt_seth:
175766e63ce3Schristos   {
175866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
175966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
176066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_seth.f
176166e63ce3Schristos     UINT f_r1;
176266e63ce3Schristos     UINT f_hi16;
176366e63ce3Schristos 
176466e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
176566e63ce3Schristos     f_hi16 = EXTRACT_MSB0_UINT (insn, 32, 16, 16);
176666e63ce3Schristos 
176766e63ce3Schristos   /* Record the fields for the semantic handler.  */
176866e63ce3Schristos   FLD (f_hi16) = f_hi16;
176966e63ce3Schristos   FLD (f_r1) = f_r1;
177066e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1771ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_seth", "f_hi16 0x%x", 'x', f_hi16, "f_r1 0x%x", 'x', f_r1, "dr 0x%x", 'x', f_r1, (char *) 0));
177266e63ce3Schristos 
177366e63ce3Schristos #if WITH_PROFILE_MODEL_P
177466e63ce3Schristos   /* Record the fields for profiling.  */
177566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
177666e63ce3Schristos     {
177766e63ce3Schristos       FLD (out_dr) = f_r1;
177866e63ce3Schristos     }
177966e63ce3Schristos #endif
178066e63ce3Schristos #undef FLD
178166e63ce3Schristos     return idesc;
178266e63ce3Schristos   }
178366e63ce3Schristos 
178466e63ce3Schristos  extract_sfmt_sll3:
178566e63ce3Schristos   {
178666e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
178766e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
178866e63ce3Schristos #define FLD(f) abuf->fields.sfmt_add3.f
178966e63ce3Schristos     UINT f_r1;
179066e63ce3Schristos     UINT f_r2;
179166e63ce3Schristos     INT f_simm16;
179266e63ce3Schristos 
179366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
179466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
179566e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
179666e63ce3Schristos 
179766e63ce3Schristos   /* Record the fields for the semantic handler.  */
179866e63ce3Schristos   FLD (f_simm16) = f_simm16;
179966e63ce3Schristos   FLD (f_r2) = f_r2;
180066e63ce3Schristos   FLD (f_r1) = f_r1;
180166e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
180266e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1803ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_sll3", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_r1 0x%x", 'x', f_r1, "sr 0x%x", 'x', f_r2, "dr 0x%x", 'x', f_r1, (char *) 0));
180466e63ce3Schristos 
180566e63ce3Schristos #if WITH_PROFILE_MODEL_P
180666e63ce3Schristos   /* Record the fields for profiling.  */
180766e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
180866e63ce3Schristos     {
180966e63ce3Schristos       FLD (in_sr) = f_r2;
181066e63ce3Schristos       FLD (out_dr) = f_r1;
181166e63ce3Schristos     }
181266e63ce3Schristos #endif
181366e63ce3Schristos #undef FLD
181466e63ce3Schristos     return idesc;
181566e63ce3Schristos   }
181666e63ce3Schristos 
181766e63ce3Schristos  extract_sfmt_slli:
181866e63ce3Schristos   {
181966e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
182066e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
182166e63ce3Schristos #define FLD(f) abuf->fields.sfmt_slli.f
182266e63ce3Schristos     UINT f_r1;
182366e63ce3Schristos     UINT f_uimm5;
182466e63ce3Schristos 
182566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
182666e63ce3Schristos     f_uimm5 = EXTRACT_MSB0_UINT (insn, 16, 11, 5);
182766e63ce3Schristos 
182866e63ce3Schristos   /* Record the fields for the semantic handler.  */
182966e63ce3Schristos   FLD (f_r1) = f_r1;
183066e63ce3Schristos   FLD (f_uimm5) = f_uimm5;
183166e63ce3Schristos   FLD (i_dr) = & CPU (h_gr)[f_r1];
1832ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_slli", "f_r1 0x%x", 'x', f_r1, "f_uimm5 0x%x", 'x', f_uimm5, "dr 0x%x", 'x', f_r1, (char *) 0));
183366e63ce3Schristos 
183466e63ce3Schristos #if WITH_PROFILE_MODEL_P
183566e63ce3Schristos   /* Record the fields for profiling.  */
183666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
183766e63ce3Schristos     {
183866e63ce3Schristos       FLD (in_dr) = f_r1;
183966e63ce3Schristos       FLD (out_dr) = f_r1;
184066e63ce3Schristos     }
184166e63ce3Schristos #endif
184266e63ce3Schristos #undef FLD
184366e63ce3Schristos     return idesc;
184466e63ce3Schristos   }
184566e63ce3Schristos 
184666e63ce3Schristos  extract_sfmt_st:
184766e63ce3Schristos   {
184866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
184966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
185066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
185166e63ce3Schristos     UINT f_r1;
185266e63ce3Schristos     UINT f_r2;
185366e63ce3Schristos 
185466e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
185566e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
185666e63ce3Schristos 
185766e63ce3Schristos   /* Record the fields for the semantic handler.  */
185866e63ce3Schristos   FLD (f_r1) = f_r1;
185966e63ce3Schristos   FLD (f_r2) = f_r2;
186066e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
186166e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1862ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_st", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
186366e63ce3Schristos 
186466e63ce3Schristos #if WITH_PROFILE_MODEL_P
186566e63ce3Schristos   /* Record the fields for profiling.  */
186666e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
186766e63ce3Schristos     {
186866e63ce3Schristos       FLD (in_src1) = f_r1;
186966e63ce3Schristos       FLD (in_src2) = f_r2;
187066e63ce3Schristos     }
187166e63ce3Schristos #endif
187266e63ce3Schristos #undef FLD
187366e63ce3Schristos     return idesc;
187466e63ce3Schristos   }
187566e63ce3Schristos 
187666e63ce3Schristos  extract_sfmt_st_d:
187766e63ce3Schristos   {
187866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
187966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
188066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_d.f
188166e63ce3Schristos     UINT f_r1;
188266e63ce3Schristos     UINT f_r2;
188366e63ce3Schristos     INT f_simm16;
188466e63ce3Schristos 
188566e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
188666e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
188766e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
188866e63ce3Schristos 
188966e63ce3Schristos   /* Record the fields for the semantic handler.  */
189066e63ce3Schristos   FLD (f_simm16) = f_simm16;
189166e63ce3Schristos   FLD (f_r1) = f_r1;
189266e63ce3Schristos   FLD (f_r2) = f_r2;
189366e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
189466e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1895ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_st_d", "f_simm16 0x%x", 'x', f_simm16, "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
189666e63ce3Schristos 
189766e63ce3Schristos #if WITH_PROFILE_MODEL_P
189866e63ce3Schristos   /* Record the fields for profiling.  */
189966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
190066e63ce3Schristos     {
190166e63ce3Schristos       FLD (in_src1) = f_r1;
190266e63ce3Schristos       FLD (in_src2) = f_r2;
190366e63ce3Schristos     }
190466e63ce3Schristos #endif
190566e63ce3Schristos #undef FLD
190666e63ce3Schristos     return idesc;
190766e63ce3Schristos   }
190866e63ce3Schristos 
190966e63ce3Schristos  extract_sfmt_stb:
191066e63ce3Schristos   {
191166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
191266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
191366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
191466e63ce3Schristos     UINT f_r1;
191566e63ce3Schristos     UINT f_r2;
191666e63ce3Schristos 
191766e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
191866e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
191966e63ce3Schristos 
192066e63ce3Schristos   /* Record the fields for the semantic handler.  */
192166e63ce3Schristos   FLD (f_r1) = f_r1;
192266e63ce3Schristos   FLD (f_r2) = f_r2;
192366e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
192466e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1925ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stb", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
192666e63ce3Schristos 
192766e63ce3Schristos #if WITH_PROFILE_MODEL_P
192866e63ce3Schristos   /* Record the fields for profiling.  */
192966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
193066e63ce3Schristos     {
193166e63ce3Schristos       FLD (in_src1) = f_r1;
193266e63ce3Schristos       FLD (in_src2) = f_r2;
193366e63ce3Schristos     }
193466e63ce3Schristos #endif
193566e63ce3Schristos #undef FLD
193666e63ce3Schristos     return idesc;
193766e63ce3Schristos   }
193866e63ce3Schristos 
193966e63ce3Schristos  extract_sfmt_stb_d:
194066e63ce3Schristos   {
194166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
194266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
194366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_d.f
194466e63ce3Schristos     UINT f_r1;
194566e63ce3Schristos     UINT f_r2;
194666e63ce3Schristos     INT f_simm16;
194766e63ce3Schristos 
194866e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
194966e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
195066e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
195166e63ce3Schristos 
195266e63ce3Schristos   /* Record the fields for the semantic handler.  */
195366e63ce3Schristos   FLD (f_simm16) = f_simm16;
195466e63ce3Schristos   FLD (f_r1) = f_r1;
195566e63ce3Schristos   FLD (f_r2) = f_r2;
195666e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
195766e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1958ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_stb_d", "f_simm16 0x%x", 'x', f_simm16, "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
195966e63ce3Schristos 
196066e63ce3Schristos #if WITH_PROFILE_MODEL_P
196166e63ce3Schristos   /* Record the fields for profiling.  */
196266e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
196366e63ce3Schristos     {
196466e63ce3Schristos       FLD (in_src1) = f_r1;
196566e63ce3Schristos       FLD (in_src2) = f_r2;
196666e63ce3Schristos     }
196766e63ce3Schristos #endif
196866e63ce3Schristos #undef FLD
196966e63ce3Schristos     return idesc;
197066e63ce3Schristos   }
197166e63ce3Schristos 
197266e63ce3Schristos  extract_sfmt_sth:
197366e63ce3Schristos   {
197466e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
197566e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
197666e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
197766e63ce3Schristos     UINT f_r1;
197866e63ce3Schristos     UINT f_r2;
197966e63ce3Schristos 
198066e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
198166e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
198266e63ce3Schristos 
198366e63ce3Schristos   /* Record the fields for the semantic handler.  */
198466e63ce3Schristos   FLD (f_r1) = f_r1;
198566e63ce3Schristos   FLD (f_r2) = f_r2;
198666e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
198766e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
1988ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_sth", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
198966e63ce3Schristos 
199066e63ce3Schristos #if WITH_PROFILE_MODEL_P
199166e63ce3Schristos   /* Record the fields for profiling.  */
199266e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
199366e63ce3Schristos     {
199466e63ce3Schristos       FLD (in_src1) = f_r1;
199566e63ce3Schristos       FLD (in_src2) = f_r2;
199666e63ce3Schristos     }
199766e63ce3Schristos #endif
199866e63ce3Schristos #undef FLD
199966e63ce3Schristos     return idesc;
200066e63ce3Schristos   }
200166e63ce3Schristos 
200266e63ce3Schristos  extract_sfmt_sth_d:
200366e63ce3Schristos   {
200466e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
200566e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
200666e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_d.f
200766e63ce3Schristos     UINT f_r1;
200866e63ce3Schristos     UINT f_r2;
200966e63ce3Schristos     INT f_simm16;
201066e63ce3Schristos 
201166e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 32, 4, 4);
201266e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
201366e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
201466e63ce3Schristos 
201566e63ce3Schristos   /* Record the fields for the semantic handler.  */
201666e63ce3Schristos   FLD (f_simm16) = f_simm16;
201766e63ce3Schristos   FLD (f_r1) = f_r1;
201866e63ce3Schristos   FLD (f_r2) = f_r2;
201966e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
202066e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
2021ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_sth_d", "f_simm16 0x%x", 'x', f_simm16, "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
202266e63ce3Schristos 
202366e63ce3Schristos #if WITH_PROFILE_MODEL_P
202466e63ce3Schristos   /* Record the fields for profiling.  */
202566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
202666e63ce3Schristos     {
202766e63ce3Schristos       FLD (in_src1) = f_r1;
202866e63ce3Schristos       FLD (in_src2) = f_r2;
202966e63ce3Schristos     }
203066e63ce3Schristos #endif
203166e63ce3Schristos #undef FLD
203266e63ce3Schristos     return idesc;
203366e63ce3Schristos   }
203466e63ce3Schristos 
203566e63ce3Schristos  extract_sfmt_st_plus:
203666e63ce3Schristos   {
203766e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
203866e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
203966e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
204066e63ce3Schristos     UINT f_r1;
204166e63ce3Schristos     UINT f_r2;
204266e63ce3Schristos 
204366e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
204466e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
204566e63ce3Schristos 
204666e63ce3Schristos   /* Record the fields for the semantic handler.  */
204766e63ce3Schristos   FLD (f_r1) = f_r1;
204866e63ce3Schristos   FLD (f_r2) = f_r2;
204966e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
205066e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
2051ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_st_plus", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
205266e63ce3Schristos 
205366e63ce3Schristos #if WITH_PROFILE_MODEL_P
205466e63ce3Schristos   /* Record the fields for profiling.  */
205566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
205666e63ce3Schristos     {
205766e63ce3Schristos       FLD (in_src1) = f_r1;
205866e63ce3Schristos       FLD (in_src2) = f_r2;
205966e63ce3Schristos       FLD (out_src2) = f_r2;
206066e63ce3Schristos     }
206166e63ce3Schristos #endif
206266e63ce3Schristos #undef FLD
206366e63ce3Schristos     return idesc;
206466e63ce3Schristos   }
206566e63ce3Schristos 
206666e63ce3Schristos  extract_sfmt_trap:
206766e63ce3Schristos   {
206866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
206966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
207066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_trap.f
207166e63ce3Schristos     UINT f_uimm4;
207266e63ce3Schristos 
207366e63ce3Schristos     f_uimm4 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
207466e63ce3Schristos 
207566e63ce3Schristos   /* Record the fields for the semantic handler.  */
207666e63ce3Schristos   FLD (f_uimm4) = f_uimm4;
2077ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_trap", "f_uimm4 0x%x", 'x', f_uimm4, (char *) 0));
207866e63ce3Schristos 
207966e63ce3Schristos #if WITH_PROFILE_MODEL_P
208066e63ce3Schristos   /* Record the fields for profiling.  */
208166e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
208266e63ce3Schristos     {
208366e63ce3Schristos     }
208466e63ce3Schristos #endif
208566e63ce3Schristos #undef FLD
208666e63ce3Schristos     return idesc;
208766e63ce3Schristos   }
208866e63ce3Schristos 
208966e63ce3Schristos  extract_sfmt_unlock:
209066e63ce3Schristos   {
209166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
209266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
209366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_st_plus.f
209466e63ce3Schristos     UINT f_r1;
209566e63ce3Schristos     UINT f_r2;
209666e63ce3Schristos 
209766e63ce3Schristos     f_r1 = EXTRACT_MSB0_UINT (insn, 16, 4, 4);
209866e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
209966e63ce3Schristos 
210066e63ce3Schristos   /* Record the fields for the semantic handler.  */
210166e63ce3Schristos   FLD (f_r1) = f_r1;
210266e63ce3Schristos   FLD (f_r2) = f_r2;
210366e63ce3Schristos   FLD (i_src1) = & CPU (h_gr)[f_r1];
210466e63ce3Schristos   FLD (i_src2) = & CPU (h_gr)[f_r2];
2105ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_unlock", "f_r1 0x%x", 'x', f_r1, "f_r2 0x%x", 'x', f_r2, "src1 0x%x", 'x', f_r1, "src2 0x%x", 'x', f_r2, (char *) 0));
210666e63ce3Schristos 
210766e63ce3Schristos #if WITH_PROFILE_MODEL_P
210866e63ce3Schristos   /* Record the fields for profiling.  */
210966e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
211066e63ce3Schristos     {
211166e63ce3Schristos       FLD (in_src1) = f_r1;
211266e63ce3Schristos       FLD (in_src2) = f_r2;
211366e63ce3Schristos     }
211466e63ce3Schristos #endif
211566e63ce3Schristos #undef FLD
211666e63ce3Schristos     return idesc;
211766e63ce3Schristos   }
211866e63ce3Schristos 
211966e63ce3Schristos  extract_sfmt_clrpsw:
212066e63ce3Schristos   {
212166e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
212266e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
212366e63ce3Schristos #define FLD(f) abuf->fields.sfmt_clrpsw.f
212466e63ce3Schristos     UINT f_uimm8;
212566e63ce3Schristos 
212666e63ce3Schristos     f_uimm8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
212766e63ce3Schristos 
212866e63ce3Schristos   /* Record the fields for the semantic handler.  */
212966e63ce3Schristos   FLD (f_uimm8) = f_uimm8;
2130ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_clrpsw", "f_uimm8 0x%x", 'x', f_uimm8, (char *) 0));
213166e63ce3Schristos 
213266e63ce3Schristos #undef FLD
213366e63ce3Schristos     return idesc;
213466e63ce3Schristos   }
213566e63ce3Schristos 
213666e63ce3Schristos  extract_sfmt_setpsw:
213766e63ce3Schristos   {
213866e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
213966e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
214066e63ce3Schristos #define FLD(f) abuf->fields.sfmt_clrpsw.f
214166e63ce3Schristos     UINT f_uimm8;
214266e63ce3Schristos 
214366e63ce3Schristos     f_uimm8 = EXTRACT_MSB0_UINT (insn, 16, 8, 8);
214466e63ce3Schristos 
214566e63ce3Schristos   /* Record the fields for the semantic handler.  */
214666e63ce3Schristos   FLD (f_uimm8) = f_uimm8;
2147ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_setpsw", "f_uimm8 0x%x", 'x', f_uimm8, (char *) 0));
214866e63ce3Schristos 
214966e63ce3Schristos #undef FLD
215066e63ce3Schristos     return idesc;
215166e63ce3Schristos   }
215266e63ce3Schristos 
215366e63ce3Schristos  extract_sfmt_bset:
215466e63ce3Schristos   {
215566e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
215666e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
215766e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bset.f
215866e63ce3Schristos     UINT f_uimm3;
215966e63ce3Schristos     UINT f_r2;
216066e63ce3Schristos     INT f_simm16;
216166e63ce3Schristos 
216266e63ce3Schristos     f_uimm3 = EXTRACT_MSB0_UINT (insn, 32, 5, 3);
216366e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 32, 12, 4);
216466e63ce3Schristos     f_simm16 = EXTRACT_MSB0_SINT (insn, 32, 16, 16);
216566e63ce3Schristos 
216666e63ce3Schristos   /* Record the fields for the semantic handler.  */
216766e63ce3Schristos   FLD (f_simm16) = f_simm16;
216866e63ce3Schristos   FLD (f_r2) = f_r2;
216966e63ce3Schristos   FLD (f_uimm3) = f_uimm3;
217066e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
2171ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_bset", "f_simm16 0x%x", 'x', f_simm16, "f_r2 0x%x", 'x', f_r2, "f_uimm3 0x%x", 'x', f_uimm3, "sr 0x%x", 'x', f_r2, (char *) 0));
217266e63ce3Schristos 
217366e63ce3Schristos #if WITH_PROFILE_MODEL_P
217466e63ce3Schristos   /* Record the fields for profiling.  */
217566e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
217666e63ce3Schristos     {
217766e63ce3Schristos       FLD (in_sr) = f_r2;
217866e63ce3Schristos     }
217966e63ce3Schristos #endif
218066e63ce3Schristos #undef FLD
218166e63ce3Schristos     return idesc;
218266e63ce3Schristos   }
218366e63ce3Schristos 
218466e63ce3Schristos  extract_sfmt_btst:
218566e63ce3Schristos   {
218666e63ce3Schristos     const IDESC *idesc = &m32rbf_insn_data[itype];
218766e63ce3Schristos     CGEN_INSN_WORD insn = entire_insn;
218866e63ce3Schristos #define FLD(f) abuf->fields.sfmt_bset.f
218966e63ce3Schristos     UINT f_uimm3;
219066e63ce3Schristos     UINT f_r2;
219166e63ce3Schristos 
219266e63ce3Schristos     f_uimm3 = EXTRACT_MSB0_UINT (insn, 16, 5, 3);
219366e63ce3Schristos     f_r2 = EXTRACT_MSB0_UINT (insn, 16, 12, 4);
219466e63ce3Schristos 
219566e63ce3Schristos   /* Record the fields for the semantic handler.  */
219666e63ce3Schristos   FLD (f_r2) = f_r2;
219766e63ce3Schristos   FLD (f_uimm3) = f_uimm3;
219866e63ce3Schristos   FLD (i_sr) = & CPU (h_gr)[f_r2];
2199ed6a76a9Schristos   CGEN_TRACE_EXTRACT (current_cpu, abuf, (current_cpu, pc, "sfmt_btst", "f_r2 0x%x", 'x', f_r2, "f_uimm3 0x%x", 'x', f_uimm3, "sr 0x%x", 'x', f_r2, (char *) 0));
220066e63ce3Schristos 
220166e63ce3Schristos #if WITH_PROFILE_MODEL_P
220266e63ce3Schristos   /* Record the fields for profiling.  */
220366e63ce3Schristos   if (PROFILE_MODEL_P (current_cpu))
220466e63ce3Schristos     {
220566e63ce3Schristos       FLD (in_sr) = f_r2;
220666e63ce3Schristos     }
220766e63ce3Schristos #endif
220866e63ce3Schristos #undef FLD
220966e63ce3Schristos     return idesc;
221066e63ce3Schristos   }
221166e63ce3Schristos 
221266e63ce3Schristos }
2213