Home | History | Annotate | Line # | Download | only in iq2000
      1       1.1  christos /* Simulator model support for iq2000bf.
      2       1.1  christos 
      3       1.1  christos THIS FILE IS MACHINE GENERATED WITH CGEN.
      4       1.1  christos 
      5  1.1.1.11  christos Copyright (C) 1996-2025 Free Software Foundation, Inc.
      6       1.1  christos 
      7       1.1  christos This file is part of the GNU simulators.
      8       1.1  christos 
      9       1.1  christos    This file is free software; you can redistribute it and/or modify
     10       1.1  christos    it under the terms of the GNU General Public License as published by
     11       1.1  christos    the Free Software Foundation; either version 3, or (at your option)
     12       1.1  christos    any later version.
     13       1.1  christos 
     14       1.1  christos    It is distributed in the hope that it will be useful, but WITHOUT
     15       1.1  christos    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
     16       1.1  christos    or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
     17       1.1  christos    License for more details.
     18       1.1  christos 
     19       1.1  christos    You should have received a copy of the GNU General Public License along
     20  1.1.1.10  christos    with this program; if not, write to the Free Software Foundation, Inc.,
     21  1.1.1.10  christos    51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
     22       1.1  christos 
     23       1.1  christos */
     24       1.1  christos 
     25       1.1  christos #define WANT_CPU iq2000bf
     26       1.1  christos #define WANT_CPU_IQ2000BF
     27       1.1  christos 
     28       1.1  christos #include "sim-main.h"
     29       1.1  christos 
     30       1.1  christos /* The profiling data is recorded here, but is accessed via the profiling
     31       1.1  christos    mechanism.  After all, this is information for profiling.  */
     32       1.1  christos 
     33       1.1  christos #if WITH_PROFILE_MODEL_P
     34       1.1  christos 
     35       1.1  christos /* Model handlers for each insn.  */
     36       1.1  christos 
     37       1.1  christos static int
     38       1.1  christos model_iq2000_add (SIM_CPU *current_cpu, void *sem_arg)
     39       1.1  christos {
     40       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
     41       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
     42       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
     43       1.1  christos   int cycles = 0;
     44       1.1  christos   {
     45       1.1  christos     int referenced = 0;
     46       1.1  christos     int UNUSED insn_referenced = abuf->written;
     47       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
     48       1.1  christos   }
     49       1.1  christos   return cycles;
     50       1.1  christos #undef FLD
     51       1.1  christos }
     52       1.1  christos 
     53       1.1  christos static int
     54       1.1  christos model_iq2000_addi (SIM_CPU *current_cpu, void *sem_arg)
     55       1.1  christos {
     56       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
     57       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
     58       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
     59       1.1  christos   int cycles = 0;
     60       1.1  christos   {
     61       1.1  christos     int referenced = 0;
     62       1.1  christos     int UNUSED insn_referenced = abuf->written;
     63       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
     64       1.1  christos   }
     65       1.1  christos   return cycles;
     66       1.1  christos #undef FLD
     67       1.1  christos }
     68       1.1  christos 
     69       1.1  christos static int
     70       1.1  christos model_iq2000_addiu (SIM_CPU *current_cpu, void *sem_arg)
     71       1.1  christos {
     72       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
     73       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
     74       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
     75       1.1  christos   int cycles = 0;
     76       1.1  christos   {
     77       1.1  christos     int referenced = 0;
     78       1.1  christos     int UNUSED insn_referenced = abuf->written;
     79       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
     80       1.1  christos   }
     81       1.1  christos   return cycles;
     82       1.1  christos #undef FLD
     83       1.1  christos }
     84       1.1  christos 
     85       1.1  christos static int
     86       1.1  christos model_iq2000_addu (SIM_CPU *current_cpu, void *sem_arg)
     87       1.1  christos {
     88       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
     89       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
     90       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
     91       1.1  christos   int cycles = 0;
     92       1.1  christos   {
     93       1.1  christos     int referenced = 0;
     94       1.1  christos     int UNUSED insn_referenced = abuf->written;
     95       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
     96       1.1  christos   }
     97       1.1  christos   return cycles;
     98       1.1  christos #undef FLD
     99       1.1  christos }
    100       1.1  christos 
    101       1.1  christos static int
    102       1.1  christos model_iq2000_ado16 (SIM_CPU *current_cpu, void *sem_arg)
    103       1.1  christos {
    104       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    105       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    106       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    107       1.1  christos   int cycles = 0;
    108       1.1  christos   {
    109       1.1  christos     int referenced = 0;
    110       1.1  christos     int UNUSED insn_referenced = abuf->written;
    111       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    112       1.1  christos   }
    113       1.1  christos   return cycles;
    114       1.1  christos #undef FLD
    115       1.1  christos }
    116       1.1  christos 
    117       1.1  christos static int
    118       1.1  christos model_iq2000_and (SIM_CPU *current_cpu, void *sem_arg)
    119       1.1  christos {
    120       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    121       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    122       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    123       1.1  christos   int cycles = 0;
    124       1.1  christos   {
    125       1.1  christos     int referenced = 0;
    126       1.1  christos     int UNUSED insn_referenced = abuf->written;
    127       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    128       1.1  christos   }
    129       1.1  christos   return cycles;
    130       1.1  christos #undef FLD
    131       1.1  christos }
    132       1.1  christos 
    133       1.1  christos static int
    134       1.1  christos model_iq2000_andi (SIM_CPU *current_cpu, void *sem_arg)
    135       1.1  christos {
    136       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    137       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    138       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    139       1.1  christos   int cycles = 0;
    140       1.1  christos   {
    141       1.1  christos     int referenced = 0;
    142       1.1  christos     int UNUSED insn_referenced = abuf->written;
    143       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    144       1.1  christos   }
    145       1.1  christos   return cycles;
    146       1.1  christos #undef FLD
    147       1.1  christos }
    148       1.1  christos 
    149       1.1  christos static int
    150       1.1  christos model_iq2000_andoi (SIM_CPU *current_cpu, void *sem_arg)
    151       1.1  christos {
    152       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    153       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    154       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    155       1.1  christos   int cycles = 0;
    156       1.1  christos   {
    157       1.1  christos     int referenced = 0;
    158       1.1  christos     int UNUSED insn_referenced = abuf->written;
    159       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    160       1.1  christos   }
    161       1.1  christos   return cycles;
    162       1.1  christos #undef FLD
    163       1.1  christos }
    164       1.1  christos 
    165       1.1  christos static int
    166       1.1  christos model_iq2000_nor (SIM_CPU *current_cpu, void *sem_arg)
    167       1.1  christos {
    168       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    169       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    170       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    171       1.1  christos   int cycles = 0;
    172       1.1  christos   {
    173       1.1  christos     int referenced = 0;
    174       1.1  christos     int UNUSED insn_referenced = abuf->written;
    175       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    176       1.1  christos   }
    177       1.1  christos   return cycles;
    178       1.1  christos #undef FLD
    179       1.1  christos }
    180       1.1  christos 
    181       1.1  christos static int
    182       1.1  christos model_iq2000_or (SIM_CPU *current_cpu, void *sem_arg)
    183       1.1  christos {
    184       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    185       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    186       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    187       1.1  christos   int cycles = 0;
    188       1.1  christos   {
    189       1.1  christos     int referenced = 0;
    190       1.1  christos     int UNUSED insn_referenced = abuf->written;
    191       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    192       1.1  christos   }
    193       1.1  christos   return cycles;
    194       1.1  christos #undef FLD
    195       1.1  christos }
    196       1.1  christos 
    197       1.1  christos static int
    198       1.1  christos model_iq2000_ori (SIM_CPU *current_cpu, void *sem_arg)
    199       1.1  christos {
    200       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    201       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    202       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    203       1.1  christos   int cycles = 0;
    204       1.1  christos   {
    205       1.1  christos     int referenced = 0;
    206       1.1  christos     int UNUSED insn_referenced = abuf->written;
    207       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    208       1.1  christos   }
    209       1.1  christos   return cycles;
    210       1.1  christos #undef FLD
    211       1.1  christos }
    212       1.1  christos 
    213       1.1  christos static int
    214       1.1  christos model_iq2000_ram (SIM_CPU *current_cpu, void *sem_arg)
    215       1.1  christos {
    216       1.1  christos #define FLD(f) abuf->fields.sfmt_ram.f
    217       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    218       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    219       1.1  christos   int cycles = 0;
    220       1.1  christos   {
    221       1.1  christos     int referenced = 0;
    222       1.1  christos     int UNUSED insn_referenced = abuf->written;
    223       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    224       1.1  christos   }
    225       1.1  christos   return cycles;
    226       1.1  christos #undef FLD
    227       1.1  christos }
    228       1.1  christos 
    229       1.1  christos static int
    230       1.1  christos model_iq2000_sll (SIM_CPU *current_cpu, void *sem_arg)
    231       1.1  christos {
    232       1.1  christos #define FLD(f) abuf->fields.sfmt_ram.f
    233       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    234       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    235       1.1  christos   int cycles = 0;
    236       1.1  christos   {
    237       1.1  christos     int referenced = 0;
    238       1.1  christos     int UNUSED insn_referenced = abuf->written;
    239       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    240       1.1  christos   }
    241       1.1  christos   return cycles;
    242       1.1  christos #undef FLD
    243       1.1  christos }
    244       1.1  christos 
    245       1.1  christos static int
    246       1.1  christos model_iq2000_sllv (SIM_CPU *current_cpu, void *sem_arg)
    247       1.1  christos {
    248       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    249       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    250       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    251       1.1  christos   int cycles = 0;
    252       1.1  christos   {
    253       1.1  christos     int referenced = 0;
    254       1.1  christos     int UNUSED insn_referenced = abuf->written;
    255       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    256       1.1  christos   }
    257       1.1  christos   return cycles;
    258       1.1  christos #undef FLD
    259       1.1  christos }
    260       1.1  christos 
    261       1.1  christos static int
    262       1.1  christos model_iq2000_slmv (SIM_CPU *current_cpu, void *sem_arg)
    263       1.1  christos {
    264       1.1  christos #define FLD(f) abuf->fields.sfmt_ram.f
    265       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    266       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    267       1.1  christos   int cycles = 0;
    268       1.1  christos   {
    269       1.1  christos     int referenced = 0;
    270       1.1  christos     int UNUSED insn_referenced = abuf->written;
    271       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    272       1.1  christos   }
    273       1.1  christos   return cycles;
    274       1.1  christos #undef FLD
    275       1.1  christos }
    276       1.1  christos 
    277       1.1  christos static int
    278       1.1  christos model_iq2000_slt (SIM_CPU *current_cpu, void *sem_arg)
    279       1.1  christos {
    280       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    281       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    282       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    283       1.1  christos   int cycles = 0;
    284       1.1  christos   {
    285       1.1  christos     int referenced = 0;
    286       1.1  christos     int UNUSED insn_referenced = abuf->written;
    287       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    288       1.1  christos   }
    289       1.1  christos   return cycles;
    290       1.1  christos #undef FLD
    291       1.1  christos }
    292       1.1  christos 
    293       1.1  christos static int
    294       1.1  christos model_iq2000_slti (SIM_CPU *current_cpu, void *sem_arg)
    295       1.1  christos {
    296       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    297       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    298       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    299       1.1  christos   int cycles = 0;
    300       1.1  christos   {
    301       1.1  christos     int referenced = 0;
    302       1.1  christos     int UNUSED insn_referenced = abuf->written;
    303       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    304       1.1  christos   }
    305       1.1  christos   return cycles;
    306       1.1  christos #undef FLD
    307       1.1  christos }
    308       1.1  christos 
    309       1.1  christos static int
    310       1.1  christos model_iq2000_sltiu (SIM_CPU *current_cpu, void *sem_arg)
    311       1.1  christos {
    312       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    313       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    314       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    315       1.1  christos   int cycles = 0;
    316       1.1  christos   {
    317       1.1  christos     int referenced = 0;
    318       1.1  christos     int UNUSED insn_referenced = abuf->written;
    319       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    320       1.1  christos   }
    321       1.1  christos   return cycles;
    322       1.1  christos #undef FLD
    323       1.1  christos }
    324       1.1  christos 
    325       1.1  christos static int
    326       1.1  christos model_iq2000_sltu (SIM_CPU *current_cpu, void *sem_arg)
    327       1.1  christos {
    328       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    329       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    330       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    331       1.1  christos   int cycles = 0;
    332       1.1  christos   {
    333       1.1  christos     int referenced = 0;
    334       1.1  christos     int UNUSED insn_referenced = abuf->written;
    335       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    336       1.1  christos   }
    337       1.1  christos   return cycles;
    338       1.1  christos #undef FLD
    339       1.1  christos }
    340       1.1  christos 
    341       1.1  christos static int
    342       1.1  christos model_iq2000_sra (SIM_CPU *current_cpu, void *sem_arg)
    343       1.1  christos {
    344       1.1  christos #define FLD(f) abuf->fields.sfmt_ram.f
    345       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    346       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    347       1.1  christos   int cycles = 0;
    348       1.1  christos   {
    349       1.1  christos     int referenced = 0;
    350       1.1  christos     int UNUSED insn_referenced = abuf->written;
    351       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    352       1.1  christos   }
    353       1.1  christos   return cycles;
    354       1.1  christos #undef FLD
    355       1.1  christos }
    356       1.1  christos 
    357       1.1  christos static int
    358       1.1  christos model_iq2000_srav (SIM_CPU *current_cpu, void *sem_arg)
    359       1.1  christos {
    360       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    361       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    362       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    363       1.1  christos   int cycles = 0;
    364       1.1  christos   {
    365       1.1  christos     int referenced = 0;
    366       1.1  christos     int UNUSED insn_referenced = abuf->written;
    367       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    368       1.1  christos   }
    369       1.1  christos   return cycles;
    370       1.1  christos #undef FLD
    371       1.1  christos }
    372       1.1  christos 
    373       1.1  christos static int
    374       1.1  christos model_iq2000_srl (SIM_CPU *current_cpu, void *sem_arg)
    375       1.1  christos {
    376       1.1  christos #define FLD(f) abuf->fields.sfmt_ram.f
    377       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    378       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    379       1.1  christos   int cycles = 0;
    380       1.1  christos   {
    381       1.1  christos     int referenced = 0;
    382       1.1  christos     int UNUSED insn_referenced = abuf->written;
    383       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    384       1.1  christos   }
    385       1.1  christos   return cycles;
    386       1.1  christos #undef FLD
    387       1.1  christos }
    388       1.1  christos 
    389       1.1  christos static int
    390       1.1  christos model_iq2000_srlv (SIM_CPU *current_cpu, void *sem_arg)
    391       1.1  christos {
    392       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    393       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    394       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    395       1.1  christos   int cycles = 0;
    396       1.1  christos   {
    397       1.1  christos     int referenced = 0;
    398       1.1  christos     int UNUSED insn_referenced = abuf->written;
    399       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    400       1.1  christos   }
    401       1.1  christos   return cycles;
    402       1.1  christos #undef FLD
    403       1.1  christos }
    404       1.1  christos 
    405       1.1  christos static int
    406       1.1  christos model_iq2000_srmv (SIM_CPU *current_cpu, void *sem_arg)
    407       1.1  christos {
    408       1.1  christos #define FLD(f) abuf->fields.sfmt_ram.f
    409       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    410       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    411       1.1  christos   int cycles = 0;
    412       1.1  christos   {
    413       1.1  christos     int referenced = 0;
    414       1.1  christos     int UNUSED insn_referenced = abuf->written;
    415       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    416       1.1  christos   }
    417       1.1  christos   return cycles;
    418       1.1  christos #undef FLD
    419       1.1  christos }
    420       1.1  christos 
    421       1.1  christos static int
    422       1.1  christos model_iq2000_sub (SIM_CPU *current_cpu, void *sem_arg)
    423       1.1  christos {
    424       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    425       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    426       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    427       1.1  christos   int cycles = 0;
    428       1.1  christos   {
    429       1.1  christos     int referenced = 0;
    430       1.1  christos     int UNUSED insn_referenced = abuf->written;
    431       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    432       1.1  christos   }
    433       1.1  christos   return cycles;
    434       1.1  christos #undef FLD
    435       1.1  christos }
    436       1.1  christos 
    437       1.1  christos static int
    438       1.1  christos model_iq2000_subu (SIM_CPU *current_cpu, void *sem_arg)
    439       1.1  christos {
    440       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    441       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    442       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    443       1.1  christos   int cycles = 0;
    444       1.1  christos   {
    445       1.1  christos     int referenced = 0;
    446       1.1  christos     int UNUSED insn_referenced = abuf->written;
    447       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    448       1.1  christos   }
    449       1.1  christos   return cycles;
    450       1.1  christos #undef FLD
    451       1.1  christos }
    452       1.1  christos 
    453       1.1  christos static int
    454       1.1  christos model_iq2000_xor (SIM_CPU *current_cpu, void *sem_arg)
    455       1.1  christos {
    456       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    457       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    458       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    459       1.1  christos   int cycles = 0;
    460       1.1  christos   {
    461       1.1  christos     int referenced = 0;
    462       1.1  christos     int UNUSED insn_referenced = abuf->written;
    463       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    464       1.1  christos   }
    465       1.1  christos   return cycles;
    466       1.1  christos #undef FLD
    467       1.1  christos }
    468       1.1  christos 
    469       1.1  christos static int
    470       1.1  christos model_iq2000_xori (SIM_CPU *current_cpu, void *sem_arg)
    471       1.1  christos {
    472       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    473       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    474       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    475       1.1  christos   int cycles = 0;
    476       1.1  christos   {
    477       1.1  christos     int referenced = 0;
    478       1.1  christos     int UNUSED insn_referenced = abuf->written;
    479       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    480       1.1  christos   }
    481       1.1  christos   return cycles;
    482       1.1  christos #undef FLD
    483       1.1  christos }
    484       1.1  christos 
    485       1.1  christos static int
    486       1.1  christos model_iq2000_bbi (SIM_CPU *current_cpu, void *sem_arg)
    487       1.1  christos {
    488       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    489       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    490       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    491       1.1  christos   int cycles = 0;
    492       1.1  christos   {
    493       1.1  christos     int referenced = 0;
    494       1.1  christos     int UNUSED insn_referenced = abuf->written;
    495       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    496       1.1  christos   }
    497       1.1  christos   return cycles;
    498       1.1  christos #undef FLD
    499       1.1  christos }
    500       1.1  christos 
    501       1.1  christos static int
    502       1.1  christos model_iq2000_bbin (SIM_CPU *current_cpu, void *sem_arg)
    503       1.1  christos {
    504       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    505       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    506       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    507       1.1  christos   int cycles = 0;
    508       1.1  christos   {
    509       1.1  christos     int referenced = 0;
    510       1.1  christos     int UNUSED insn_referenced = abuf->written;
    511       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    512       1.1  christos   }
    513       1.1  christos   return cycles;
    514       1.1  christos #undef FLD
    515       1.1  christos }
    516       1.1  christos 
    517       1.1  christos static int
    518       1.1  christos model_iq2000_bbv (SIM_CPU *current_cpu, void *sem_arg)
    519       1.1  christos {
    520       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    521       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    522       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    523       1.1  christos   int cycles = 0;
    524       1.1  christos   {
    525       1.1  christos     int referenced = 0;
    526       1.1  christos     int UNUSED insn_referenced = abuf->written;
    527       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    528       1.1  christos   }
    529       1.1  christos   return cycles;
    530       1.1  christos #undef FLD
    531       1.1  christos }
    532       1.1  christos 
    533       1.1  christos static int
    534       1.1  christos model_iq2000_bbvn (SIM_CPU *current_cpu, void *sem_arg)
    535       1.1  christos {
    536       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    537       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    538       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    539       1.1  christos   int cycles = 0;
    540       1.1  christos   {
    541       1.1  christos     int referenced = 0;
    542       1.1  christos     int UNUSED insn_referenced = abuf->written;
    543       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    544       1.1  christos   }
    545       1.1  christos   return cycles;
    546       1.1  christos #undef FLD
    547       1.1  christos }
    548       1.1  christos 
    549       1.1  christos static int
    550       1.1  christos model_iq2000_beq (SIM_CPU *current_cpu, void *sem_arg)
    551       1.1  christos {
    552       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    553       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    554       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    555       1.1  christos   int cycles = 0;
    556       1.1  christos   {
    557       1.1  christos     int referenced = 0;
    558       1.1  christos     int UNUSED insn_referenced = abuf->written;
    559       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    560       1.1  christos   }
    561       1.1  christos   return cycles;
    562       1.1  christos #undef FLD
    563       1.1  christos }
    564       1.1  christos 
    565       1.1  christos static int
    566       1.1  christos model_iq2000_beql (SIM_CPU *current_cpu, void *sem_arg)
    567       1.1  christos {
    568       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    569       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    570       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    571       1.1  christos   int cycles = 0;
    572       1.1  christos   {
    573       1.1  christos     int referenced = 0;
    574       1.1  christos     int UNUSED insn_referenced = abuf->written;
    575       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    576       1.1  christos   }
    577       1.1  christos   return cycles;
    578       1.1  christos #undef FLD
    579       1.1  christos }
    580       1.1  christos 
    581       1.1  christos static int
    582       1.1  christos model_iq2000_bgez (SIM_CPU *current_cpu, void *sem_arg)
    583       1.1  christos {
    584       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    585       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    586       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    587       1.1  christos   int cycles = 0;
    588       1.1  christos   {
    589       1.1  christos     int referenced = 0;
    590       1.1  christos     int UNUSED insn_referenced = abuf->written;
    591       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    592       1.1  christos   }
    593       1.1  christos   return cycles;
    594       1.1  christos #undef FLD
    595       1.1  christos }
    596       1.1  christos 
    597       1.1  christos static int
    598       1.1  christos model_iq2000_bgezal (SIM_CPU *current_cpu, void *sem_arg)
    599       1.1  christos {
    600       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    601       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    602       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    603       1.1  christos   int cycles = 0;
    604       1.1  christos   {
    605       1.1  christos     int referenced = 0;
    606       1.1  christos     int UNUSED insn_referenced = abuf->written;
    607       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    608       1.1  christos   }
    609       1.1  christos   return cycles;
    610       1.1  christos #undef FLD
    611       1.1  christos }
    612       1.1  christos 
    613       1.1  christos static int
    614       1.1  christos model_iq2000_bgezall (SIM_CPU *current_cpu, void *sem_arg)
    615       1.1  christos {
    616       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    617       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    618       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    619       1.1  christos   int cycles = 0;
    620       1.1  christos   {
    621       1.1  christos     int referenced = 0;
    622       1.1  christos     int UNUSED insn_referenced = abuf->written;
    623       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    624       1.1  christos   }
    625       1.1  christos   return cycles;
    626       1.1  christos #undef FLD
    627       1.1  christos }
    628       1.1  christos 
    629       1.1  christos static int
    630       1.1  christos model_iq2000_bgezl (SIM_CPU *current_cpu, void *sem_arg)
    631       1.1  christos {
    632       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    633       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    634       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    635       1.1  christos   int cycles = 0;
    636       1.1  christos   {
    637       1.1  christos     int referenced = 0;
    638       1.1  christos     int UNUSED insn_referenced = abuf->written;
    639       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    640       1.1  christos   }
    641       1.1  christos   return cycles;
    642       1.1  christos #undef FLD
    643       1.1  christos }
    644       1.1  christos 
    645       1.1  christos static int
    646       1.1  christos model_iq2000_bltz (SIM_CPU *current_cpu, void *sem_arg)
    647       1.1  christos {
    648       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    649       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    650       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    651       1.1  christos   int cycles = 0;
    652       1.1  christos   {
    653       1.1  christos     int referenced = 0;
    654       1.1  christos     int UNUSED insn_referenced = abuf->written;
    655       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    656       1.1  christos   }
    657       1.1  christos   return cycles;
    658       1.1  christos #undef FLD
    659       1.1  christos }
    660       1.1  christos 
    661       1.1  christos static int
    662       1.1  christos model_iq2000_bltzl (SIM_CPU *current_cpu, void *sem_arg)
    663       1.1  christos {
    664       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    665       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    666       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    667       1.1  christos   int cycles = 0;
    668       1.1  christos   {
    669       1.1  christos     int referenced = 0;
    670       1.1  christos     int UNUSED insn_referenced = abuf->written;
    671       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    672       1.1  christos   }
    673       1.1  christos   return cycles;
    674       1.1  christos #undef FLD
    675       1.1  christos }
    676       1.1  christos 
    677       1.1  christos static int
    678       1.1  christos model_iq2000_bltzal (SIM_CPU *current_cpu, void *sem_arg)
    679       1.1  christos {
    680       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    681       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    682       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    683       1.1  christos   int cycles = 0;
    684       1.1  christos   {
    685       1.1  christos     int referenced = 0;
    686       1.1  christos     int UNUSED insn_referenced = abuf->written;
    687       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    688       1.1  christos   }
    689       1.1  christos   return cycles;
    690       1.1  christos #undef FLD
    691       1.1  christos }
    692       1.1  christos 
    693       1.1  christos static int
    694       1.1  christos model_iq2000_bltzall (SIM_CPU *current_cpu, void *sem_arg)
    695       1.1  christos {
    696       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    697       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    698       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    699       1.1  christos   int cycles = 0;
    700       1.1  christos   {
    701       1.1  christos     int referenced = 0;
    702       1.1  christos     int UNUSED insn_referenced = abuf->written;
    703       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    704       1.1  christos   }
    705       1.1  christos   return cycles;
    706       1.1  christos #undef FLD
    707       1.1  christos }
    708       1.1  christos 
    709       1.1  christos static int
    710       1.1  christos model_iq2000_bmb0 (SIM_CPU *current_cpu, void *sem_arg)
    711       1.1  christos {
    712       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    713       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    714       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    715       1.1  christos   int cycles = 0;
    716       1.1  christos   {
    717       1.1  christos     int referenced = 0;
    718       1.1  christos     int UNUSED insn_referenced = abuf->written;
    719       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    720       1.1  christos   }
    721       1.1  christos   return cycles;
    722       1.1  christos #undef FLD
    723       1.1  christos }
    724       1.1  christos 
    725       1.1  christos static int
    726       1.1  christos model_iq2000_bmb1 (SIM_CPU *current_cpu, void *sem_arg)
    727       1.1  christos {
    728       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    729       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    730       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    731       1.1  christos   int cycles = 0;
    732       1.1  christos   {
    733       1.1  christos     int referenced = 0;
    734       1.1  christos     int UNUSED insn_referenced = abuf->written;
    735       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    736       1.1  christos   }
    737       1.1  christos   return cycles;
    738       1.1  christos #undef FLD
    739       1.1  christos }
    740       1.1  christos 
    741       1.1  christos static int
    742       1.1  christos model_iq2000_bmb2 (SIM_CPU *current_cpu, void *sem_arg)
    743       1.1  christos {
    744       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    745       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    746       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    747       1.1  christos   int cycles = 0;
    748       1.1  christos   {
    749       1.1  christos     int referenced = 0;
    750       1.1  christos     int UNUSED insn_referenced = abuf->written;
    751       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    752       1.1  christos   }
    753       1.1  christos   return cycles;
    754       1.1  christos #undef FLD
    755       1.1  christos }
    756       1.1  christos 
    757       1.1  christos static int
    758       1.1  christos model_iq2000_bmb3 (SIM_CPU *current_cpu, void *sem_arg)
    759       1.1  christos {
    760       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    761       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    762       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    763       1.1  christos   int cycles = 0;
    764       1.1  christos   {
    765       1.1  christos     int referenced = 0;
    766       1.1  christos     int UNUSED insn_referenced = abuf->written;
    767       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    768       1.1  christos   }
    769       1.1  christos   return cycles;
    770       1.1  christos #undef FLD
    771       1.1  christos }
    772       1.1  christos 
    773       1.1  christos static int
    774       1.1  christos model_iq2000_bne (SIM_CPU *current_cpu, void *sem_arg)
    775       1.1  christos {
    776       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    777       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    778       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    779       1.1  christos   int cycles = 0;
    780       1.1  christos   {
    781       1.1  christos     int referenced = 0;
    782       1.1  christos     int UNUSED insn_referenced = abuf->written;
    783       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    784       1.1  christos   }
    785       1.1  christos   return cycles;
    786       1.1  christos #undef FLD
    787       1.1  christos }
    788       1.1  christos 
    789       1.1  christos static int
    790       1.1  christos model_iq2000_bnel (SIM_CPU *current_cpu, void *sem_arg)
    791       1.1  christos {
    792       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    793       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    794       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    795       1.1  christos   int cycles = 0;
    796       1.1  christos   {
    797       1.1  christos     int referenced = 0;
    798       1.1  christos     int UNUSED insn_referenced = abuf->written;
    799       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    800       1.1  christos   }
    801       1.1  christos   return cycles;
    802       1.1  christos #undef FLD
    803       1.1  christos }
    804       1.1  christos 
    805       1.1  christos static int
    806       1.1  christos model_iq2000_jalr (SIM_CPU *current_cpu, void *sem_arg)
    807       1.1  christos {
    808       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
    809       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    810       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    811       1.1  christos   int cycles = 0;
    812       1.1  christos   {
    813       1.1  christos     int referenced = 0;
    814       1.1  christos     int UNUSED insn_referenced = abuf->written;
    815       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    816       1.1  christos   }
    817       1.1  christos   return cycles;
    818       1.1  christos #undef FLD
    819       1.1  christos }
    820       1.1  christos 
    821       1.1  christos static int
    822       1.1  christos model_iq2000_jr (SIM_CPU *current_cpu, void *sem_arg)
    823       1.1  christos {
    824       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
    825       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    826       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    827       1.1  christos   int cycles = 0;
    828       1.1  christos   {
    829       1.1  christos     int referenced = 0;
    830       1.1  christos     int UNUSED insn_referenced = abuf->written;
    831       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    832       1.1  christos   }
    833       1.1  christos   return cycles;
    834       1.1  christos #undef FLD
    835       1.1  christos }
    836       1.1  christos 
    837       1.1  christos static int
    838       1.1  christos model_iq2000_lb (SIM_CPU *current_cpu, void *sem_arg)
    839       1.1  christos {
    840       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    841       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    842       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    843       1.1  christos   int cycles = 0;
    844       1.1  christos   {
    845       1.1  christos     int referenced = 0;
    846       1.1  christos     int UNUSED insn_referenced = abuf->written;
    847       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    848       1.1  christos   }
    849       1.1  christos   return cycles;
    850       1.1  christos #undef FLD
    851       1.1  christos }
    852       1.1  christos 
    853       1.1  christos static int
    854       1.1  christos model_iq2000_lbu (SIM_CPU *current_cpu, void *sem_arg)
    855       1.1  christos {
    856       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    857       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    858       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    859       1.1  christos   int cycles = 0;
    860       1.1  christos   {
    861       1.1  christos     int referenced = 0;
    862       1.1  christos     int UNUSED insn_referenced = abuf->written;
    863       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    864       1.1  christos   }
    865       1.1  christos   return cycles;
    866       1.1  christos #undef FLD
    867       1.1  christos }
    868       1.1  christos 
    869       1.1  christos static int
    870       1.1  christos model_iq2000_lh (SIM_CPU *current_cpu, void *sem_arg)
    871       1.1  christos {
    872       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    873       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    874       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    875       1.1  christos   int cycles = 0;
    876       1.1  christos   {
    877       1.1  christos     int referenced = 0;
    878       1.1  christos     int UNUSED insn_referenced = abuf->written;
    879       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    880       1.1  christos   }
    881       1.1  christos   return cycles;
    882       1.1  christos #undef FLD
    883       1.1  christos }
    884       1.1  christos 
    885       1.1  christos static int
    886       1.1  christos model_iq2000_lhu (SIM_CPU *current_cpu, void *sem_arg)
    887       1.1  christos {
    888       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    889       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    890       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    891       1.1  christos   int cycles = 0;
    892       1.1  christos   {
    893       1.1  christos     int referenced = 0;
    894       1.1  christos     int UNUSED insn_referenced = abuf->written;
    895       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    896       1.1  christos   }
    897       1.1  christos   return cycles;
    898       1.1  christos #undef FLD
    899       1.1  christos }
    900       1.1  christos 
    901       1.1  christos static int
    902       1.1  christos model_iq2000_lui (SIM_CPU *current_cpu, void *sem_arg)
    903       1.1  christos {
    904       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    905       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    906       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    907       1.1  christos   int cycles = 0;
    908       1.1  christos   {
    909       1.1  christos     int referenced = 0;
    910       1.1  christos     int UNUSED insn_referenced = abuf->written;
    911       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    912       1.1  christos   }
    913       1.1  christos   return cycles;
    914       1.1  christos #undef FLD
    915       1.1  christos }
    916       1.1  christos 
    917       1.1  christos static int
    918       1.1  christos model_iq2000_lw (SIM_CPU *current_cpu, void *sem_arg)
    919       1.1  christos {
    920       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    921       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    922       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    923       1.1  christos   int cycles = 0;
    924       1.1  christos   {
    925       1.1  christos     int referenced = 0;
    926       1.1  christos     int UNUSED insn_referenced = abuf->written;
    927       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    928       1.1  christos   }
    929       1.1  christos   return cycles;
    930       1.1  christos #undef FLD
    931       1.1  christos }
    932       1.1  christos 
    933       1.1  christos static int
    934       1.1  christos model_iq2000_sb (SIM_CPU *current_cpu, void *sem_arg)
    935       1.1  christos {
    936       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    937       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    938       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    939       1.1  christos   int cycles = 0;
    940       1.1  christos   {
    941       1.1  christos     int referenced = 0;
    942       1.1  christos     int UNUSED insn_referenced = abuf->written;
    943       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    944       1.1  christos   }
    945       1.1  christos   return cycles;
    946       1.1  christos #undef FLD
    947       1.1  christos }
    948       1.1  christos 
    949       1.1  christos static int
    950       1.1  christos model_iq2000_sh (SIM_CPU *current_cpu, void *sem_arg)
    951       1.1  christos {
    952       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    953       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    954       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    955       1.1  christos   int cycles = 0;
    956       1.1  christos   {
    957       1.1  christos     int referenced = 0;
    958       1.1  christos     int UNUSED insn_referenced = abuf->written;
    959       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    960       1.1  christos   }
    961       1.1  christos   return cycles;
    962       1.1  christos #undef FLD
    963       1.1  christos }
    964       1.1  christos 
    965       1.1  christos static int
    966       1.1  christos model_iq2000_sw (SIM_CPU *current_cpu, void *sem_arg)
    967       1.1  christos {
    968       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
    969       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    970       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    971       1.1  christos   int cycles = 0;
    972       1.1  christos   {
    973       1.1  christos     int referenced = 0;
    974       1.1  christos     int UNUSED insn_referenced = abuf->written;
    975       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    976       1.1  christos   }
    977       1.1  christos   return cycles;
    978       1.1  christos #undef FLD
    979       1.1  christos }
    980       1.1  christos 
    981       1.1  christos static int
    982       1.1  christos model_iq2000_break (SIM_CPU *current_cpu, void *sem_arg)
    983       1.1  christos {
    984       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
    985       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
    986       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
    987       1.1  christos   int cycles = 0;
    988       1.1  christos   {
    989       1.1  christos     int referenced = 0;
    990       1.1  christos     int UNUSED insn_referenced = abuf->written;
    991       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
    992       1.1  christos   }
    993       1.1  christos   return cycles;
    994       1.1  christos #undef FLD
    995       1.1  christos }
    996       1.1  christos 
    997       1.1  christos static int
    998       1.1  christos model_iq2000_syscall (SIM_CPU *current_cpu, void *sem_arg)
    999       1.1  christos {
   1000       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1001       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1002       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1003       1.1  christos   int cycles = 0;
   1004       1.1  christos   {
   1005       1.1  christos     int referenced = 0;
   1006       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1007       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1008       1.1  christos   }
   1009       1.1  christos   return cycles;
   1010       1.1  christos #undef FLD
   1011       1.1  christos }
   1012       1.1  christos 
   1013       1.1  christos static int
   1014       1.1  christos model_iq2000_andoui (SIM_CPU *current_cpu, void *sem_arg)
   1015       1.1  christos {
   1016       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
   1017       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1018       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1019       1.1  christos   int cycles = 0;
   1020       1.1  christos   {
   1021       1.1  christos     int referenced = 0;
   1022       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1023       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1024       1.1  christos   }
   1025       1.1  christos   return cycles;
   1026       1.1  christos #undef FLD
   1027       1.1  christos }
   1028       1.1  christos 
   1029       1.1  christos static int
   1030       1.1  christos model_iq2000_orui (SIM_CPU *current_cpu, void *sem_arg)
   1031       1.1  christos {
   1032       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
   1033       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1034       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1035       1.1  christos   int cycles = 0;
   1036       1.1  christos   {
   1037       1.1  christos     int referenced = 0;
   1038       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1039       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1040       1.1  christos   }
   1041       1.1  christos   return cycles;
   1042       1.1  christos #undef FLD
   1043       1.1  christos }
   1044       1.1  christos 
   1045       1.1  christos static int
   1046       1.1  christos model_iq2000_bgtz (SIM_CPU *current_cpu, void *sem_arg)
   1047       1.1  christos {
   1048       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
   1049       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1050       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1051       1.1  christos   int cycles = 0;
   1052       1.1  christos   {
   1053       1.1  christos     int referenced = 0;
   1054       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1055       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1056       1.1  christos   }
   1057       1.1  christos   return cycles;
   1058       1.1  christos #undef FLD
   1059       1.1  christos }
   1060       1.1  christos 
   1061       1.1  christos static int
   1062       1.1  christos model_iq2000_bgtzl (SIM_CPU *current_cpu, void *sem_arg)
   1063       1.1  christos {
   1064       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
   1065       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1066       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1067       1.1  christos   int cycles = 0;
   1068       1.1  christos   {
   1069       1.1  christos     int referenced = 0;
   1070       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1071       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1072       1.1  christos   }
   1073       1.1  christos   return cycles;
   1074       1.1  christos #undef FLD
   1075       1.1  christos }
   1076       1.1  christos 
   1077       1.1  christos static int
   1078       1.1  christos model_iq2000_blez (SIM_CPU *current_cpu, void *sem_arg)
   1079       1.1  christos {
   1080       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
   1081       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1082       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1083       1.1  christos   int cycles = 0;
   1084       1.1  christos   {
   1085       1.1  christos     int referenced = 0;
   1086       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1087       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1088       1.1  christos   }
   1089       1.1  christos   return cycles;
   1090       1.1  christos #undef FLD
   1091       1.1  christos }
   1092       1.1  christos 
   1093       1.1  christos static int
   1094       1.1  christos model_iq2000_blezl (SIM_CPU *current_cpu, void *sem_arg)
   1095       1.1  christos {
   1096       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
   1097       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1098       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1099       1.1  christos   int cycles = 0;
   1100       1.1  christos   {
   1101       1.1  christos     int referenced = 0;
   1102       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1103       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1104       1.1  christos   }
   1105       1.1  christos   return cycles;
   1106       1.1  christos #undef FLD
   1107       1.1  christos }
   1108       1.1  christos 
   1109       1.1  christos static int
   1110       1.1  christos model_iq2000_mrgb (SIM_CPU *current_cpu, void *sem_arg)
   1111       1.1  christos {
   1112       1.1  christos #define FLD(f) abuf->fields.sfmt_mrgb.f
   1113       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1114       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1115       1.1  christos   int cycles = 0;
   1116       1.1  christos   {
   1117       1.1  christos     int referenced = 0;
   1118       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1119       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1120       1.1  christos   }
   1121       1.1  christos   return cycles;
   1122       1.1  christos #undef FLD
   1123       1.1  christos }
   1124       1.1  christos 
   1125       1.1  christos static int
   1126       1.1  christos model_iq2000_bctxt (SIM_CPU *current_cpu, void *sem_arg)
   1127       1.1  christos {
   1128       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1129       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1130       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1131       1.1  christos   int cycles = 0;
   1132       1.1  christos   {
   1133       1.1  christos     int referenced = 0;
   1134       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1135       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1136       1.1  christos   }
   1137       1.1  christos   return cycles;
   1138       1.1  christos #undef FLD
   1139       1.1  christos }
   1140       1.1  christos 
   1141       1.1  christos static int
   1142       1.1  christos model_iq2000_bc0f (SIM_CPU *current_cpu, void *sem_arg)
   1143       1.1  christos {
   1144       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1145       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1146       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1147       1.1  christos   int cycles = 0;
   1148       1.1  christos   {
   1149       1.1  christos     int referenced = 0;
   1150       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1151       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1152       1.1  christos   }
   1153       1.1  christos   return cycles;
   1154       1.1  christos #undef FLD
   1155       1.1  christos }
   1156       1.1  christos 
   1157       1.1  christos static int
   1158       1.1  christos model_iq2000_bc0fl (SIM_CPU *current_cpu, void *sem_arg)
   1159       1.1  christos {
   1160       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1161       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1162       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1163       1.1  christos   int cycles = 0;
   1164       1.1  christos   {
   1165       1.1  christos     int referenced = 0;
   1166       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1167       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1168       1.1  christos   }
   1169       1.1  christos   return cycles;
   1170       1.1  christos #undef FLD
   1171       1.1  christos }
   1172       1.1  christos 
   1173       1.1  christos static int
   1174       1.1  christos model_iq2000_bc3f (SIM_CPU *current_cpu, void *sem_arg)
   1175       1.1  christos {
   1176       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1177       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1178       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1179       1.1  christos   int cycles = 0;
   1180       1.1  christos   {
   1181       1.1  christos     int referenced = 0;
   1182       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1183       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1184       1.1  christos   }
   1185       1.1  christos   return cycles;
   1186       1.1  christos #undef FLD
   1187       1.1  christos }
   1188       1.1  christos 
   1189       1.1  christos static int
   1190       1.1  christos model_iq2000_bc3fl (SIM_CPU *current_cpu, void *sem_arg)
   1191       1.1  christos {
   1192       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1193       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1194       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1195       1.1  christos   int cycles = 0;
   1196       1.1  christos   {
   1197       1.1  christos     int referenced = 0;
   1198       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1199       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1200       1.1  christos   }
   1201       1.1  christos   return cycles;
   1202       1.1  christos #undef FLD
   1203       1.1  christos }
   1204       1.1  christos 
   1205       1.1  christos static int
   1206       1.1  christos model_iq2000_bc0t (SIM_CPU *current_cpu, void *sem_arg)
   1207       1.1  christos {
   1208       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1209       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1210       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1211       1.1  christos   int cycles = 0;
   1212       1.1  christos   {
   1213       1.1  christos     int referenced = 0;
   1214       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1215       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1216       1.1  christos   }
   1217       1.1  christos   return cycles;
   1218       1.1  christos #undef FLD
   1219       1.1  christos }
   1220       1.1  christos 
   1221       1.1  christos static int
   1222       1.1  christos model_iq2000_bc0tl (SIM_CPU *current_cpu, void *sem_arg)
   1223       1.1  christos {
   1224       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1225       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1226       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1227       1.1  christos   int cycles = 0;
   1228       1.1  christos   {
   1229       1.1  christos     int referenced = 0;
   1230       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1231       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1232       1.1  christos   }
   1233       1.1  christos   return cycles;
   1234       1.1  christos #undef FLD
   1235       1.1  christos }
   1236       1.1  christos 
   1237       1.1  christos static int
   1238       1.1  christos model_iq2000_bc3t (SIM_CPU *current_cpu, void *sem_arg)
   1239       1.1  christos {
   1240       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1241       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1242       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1243       1.1  christos   int cycles = 0;
   1244       1.1  christos   {
   1245       1.1  christos     int referenced = 0;
   1246       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1247       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1248       1.1  christos   }
   1249       1.1  christos   return cycles;
   1250       1.1  christos #undef FLD
   1251       1.1  christos }
   1252       1.1  christos 
   1253       1.1  christos static int
   1254       1.1  christos model_iq2000_bc3tl (SIM_CPU *current_cpu, void *sem_arg)
   1255       1.1  christos {
   1256       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1257       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1258       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1259       1.1  christos   int cycles = 0;
   1260       1.1  christos   {
   1261       1.1  christos     int referenced = 0;
   1262       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1263       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1264       1.1  christos   }
   1265       1.1  christos   return cycles;
   1266       1.1  christos #undef FLD
   1267       1.1  christos }
   1268       1.1  christos 
   1269       1.1  christos static int
   1270       1.1  christos model_iq2000_cfc0 (SIM_CPU *current_cpu, void *sem_arg)
   1271       1.1  christos {
   1272       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1273       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1274       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1275       1.1  christos   int cycles = 0;
   1276       1.1  christos   {
   1277       1.1  christos     int referenced = 0;
   1278       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1279       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1280       1.1  christos   }
   1281       1.1  christos   return cycles;
   1282       1.1  christos #undef FLD
   1283       1.1  christos }
   1284       1.1  christos 
   1285       1.1  christos static int
   1286       1.1  christos model_iq2000_cfc1 (SIM_CPU *current_cpu, void *sem_arg)
   1287       1.1  christos {
   1288       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1289       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1290       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1291       1.1  christos   int cycles = 0;
   1292       1.1  christos   {
   1293       1.1  christos     int referenced = 0;
   1294       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1295       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1296       1.1  christos   }
   1297       1.1  christos   return cycles;
   1298       1.1  christos #undef FLD
   1299       1.1  christos }
   1300       1.1  christos 
   1301       1.1  christos static int
   1302       1.1  christos model_iq2000_cfc2 (SIM_CPU *current_cpu, void *sem_arg)
   1303       1.1  christos {
   1304       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1305       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1306       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1307       1.1  christos   int cycles = 0;
   1308       1.1  christos   {
   1309       1.1  christos     int referenced = 0;
   1310       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1311       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1312       1.1  christos   }
   1313       1.1  christos   return cycles;
   1314       1.1  christos #undef FLD
   1315       1.1  christos }
   1316       1.1  christos 
   1317       1.1  christos static int
   1318       1.1  christos model_iq2000_cfc3 (SIM_CPU *current_cpu, void *sem_arg)
   1319       1.1  christos {
   1320       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1321       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1322       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1323       1.1  christos   int cycles = 0;
   1324       1.1  christos   {
   1325       1.1  christos     int referenced = 0;
   1326       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1327       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1328       1.1  christos   }
   1329       1.1  christos   return cycles;
   1330       1.1  christos #undef FLD
   1331       1.1  christos }
   1332       1.1  christos 
   1333       1.1  christos static int
   1334       1.1  christos model_iq2000_chkhdr (SIM_CPU *current_cpu, void *sem_arg)
   1335       1.1  christos {
   1336       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1337       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1338       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1339       1.1  christos   int cycles = 0;
   1340       1.1  christos   {
   1341       1.1  christos     int referenced = 0;
   1342       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1343       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1344       1.1  christos   }
   1345       1.1  christos   return cycles;
   1346       1.1  christos #undef FLD
   1347       1.1  christos }
   1348       1.1  christos 
   1349       1.1  christos static int
   1350       1.1  christos model_iq2000_ctc0 (SIM_CPU *current_cpu, void *sem_arg)
   1351       1.1  christos {
   1352       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1353       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1354       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1355       1.1  christos   int cycles = 0;
   1356       1.1  christos   {
   1357       1.1  christos     int referenced = 0;
   1358       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1359       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1360       1.1  christos   }
   1361       1.1  christos   return cycles;
   1362       1.1  christos #undef FLD
   1363       1.1  christos }
   1364       1.1  christos 
   1365       1.1  christos static int
   1366       1.1  christos model_iq2000_ctc1 (SIM_CPU *current_cpu, void *sem_arg)
   1367       1.1  christos {
   1368       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1369       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1370       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1371       1.1  christos   int cycles = 0;
   1372       1.1  christos   {
   1373       1.1  christos     int referenced = 0;
   1374       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1375       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1376       1.1  christos   }
   1377       1.1  christos   return cycles;
   1378       1.1  christos #undef FLD
   1379       1.1  christos }
   1380       1.1  christos 
   1381       1.1  christos static int
   1382       1.1  christos model_iq2000_ctc2 (SIM_CPU *current_cpu, void *sem_arg)
   1383       1.1  christos {
   1384       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1385       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1386       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1387       1.1  christos   int cycles = 0;
   1388       1.1  christos   {
   1389       1.1  christos     int referenced = 0;
   1390       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1391       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1392       1.1  christos   }
   1393       1.1  christos   return cycles;
   1394       1.1  christos #undef FLD
   1395       1.1  christos }
   1396       1.1  christos 
   1397       1.1  christos static int
   1398       1.1  christos model_iq2000_ctc3 (SIM_CPU *current_cpu, void *sem_arg)
   1399       1.1  christos {
   1400       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1401       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1402       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1403       1.1  christos   int cycles = 0;
   1404       1.1  christos   {
   1405       1.1  christos     int referenced = 0;
   1406       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1407       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1408       1.1  christos   }
   1409       1.1  christos   return cycles;
   1410       1.1  christos #undef FLD
   1411       1.1  christos }
   1412       1.1  christos 
   1413       1.1  christos static int
   1414       1.1  christos model_iq2000_jcr (SIM_CPU *current_cpu, void *sem_arg)
   1415       1.1  christos {
   1416       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1417       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1418       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1419       1.1  christos   int cycles = 0;
   1420       1.1  christos   {
   1421       1.1  christos     int referenced = 0;
   1422       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1423       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1424       1.1  christos   }
   1425       1.1  christos   return cycles;
   1426       1.1  christos #undef FLD
   1427       1.1  christos }
   1428       1.1  christos 
   1429       1.1  christos static int
   1430       1.1  christos model_iq2000_luc32 (SIM_CPU *current_cpu, void *sem_arg)
   1431       1.1  christos {
   1432       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1433       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1434       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1435       1.1  christos   int cycles = 0;
   1436       1.1  christos   {
   1437       1.1  christos     int referenced = 0;
   1438       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1439       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1440       1.1  christos   }
   1441       1.1  christos   return cycles;
   1442       1.1  christos #undef FLD
   1443       1.1  christos }
   1444       1.1  christos 
   1445       1.1  christos static int
   1446       1.1  christos model_iq2000_luc32l (SIM_CPU *current_cpu, void *sem_arg)
   1447       1.1  christos {
   1448       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1449       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1450       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1451       1.1  christos   int cycles = 0;
   1452       1.1  christos   {
   1453       1.1  christos     int referenced = 0;
   1454       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1455       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1456       1.1  christos   }
   1457       1.1  christos   return cycles;
   1458       1.1  christos #undef FLD
   1459       1.1  christos }
   1460       1.1  christos 
   1461       1.1  christos static int
   1462       1.1  christos model_iq2000_luc64 (SIM_CPU *current_cpu, void *sem_arg)
   1463       1.1  christos {
   1464       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1465       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1466       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1467       1.1  christos   int cycles = 0;
   1468       1.1  christos   {
   1469       1.1  christos     int referenced = 0;
   1470       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1471       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1472       1.1  christos   }
   1473       1.1  christos   return cycles;
   1474       1.1  christos #undef FLD
   1475       1.1  christos }
   1476       1.1  christos 
   1477       1.1  christos static int
   1478       1.1  christos model_iq2000_luc64l (SIM_CPU *current_cpu, void *sem_arg)
   1479       1.1  christos {
   1480       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1481       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1482       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1483       1.1  christos   int cycles = 0;
   1484       1.1  christos   {
   1485       1.1  christos     int referenced = 0;
   1486       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1487       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1488       1.1  christos   }
   1489       1.1  christos   return cycles;
   1490       1.1  christos #undef FLD
   1491       1.1  christos }
   1492       1.1  christos 
   1493       1.1  christos static int
   1494       1.1  christos model_iq2000_luk (SIM_CPU *current_cpu, void *sem_arg)
   1495       1.1  christos {
   1496       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1497       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1498       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1499       1.1  christos   int cycles = 0;
   1500       1.1  christos   {
   1501       1.1  christos     int referenced = 0;
   1502       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1503       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1504       1.1  christos   }
   1505       1.1  christos   return cycles;
   1506       1.1  christos #undef FLD
   1507       1.1  christos }
   1508       1.1  christos 
   1509       1.1  christos static int
   1510       1.1  christos model_iq2000_lulck (SIM_CPU *current_cpu, void *sem_arg)
   1511       1.1  christos {
   1512       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1513       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1514       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1515       1.1  christos   int cycles = 0;
   1516       1.1  christos   {
   1517       1.1  christos     int referenced = 0;
   1518       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1519       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1520       1.1  christos   }
   1521       1.1  christos   return cycles;
   1522       1.1  christos #undef FLD
   1523       1.1  christos }
   1524       1.1  christos 
   1525       1.1  christos static int
   1526       1.1  christos model_iq2000_lum32 (SIM_CPU *current_cpu, void *sem_arg)
   1527       1.1  christos {
   1528       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1529       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1530       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1531       1.1  christos   int cycles = 0;
   1532       1.1  christos   {
   1533       1.1  christos     int referenced = 0;
   1534       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1535       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1536       1.1  christos   }
   1537       1.1  christos   return cycles;
   1538       1.1  christos #undef FLD
   1539       1.1  christos }
   1540       1.1  christos 
   1541       1.1  christos static int
   1542       1.1  christos model_iq2000_lum32l (SIM_CPU *current_cpu, void *sem_arg)
   1543       1.1  christos {
   1544       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1545       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1546       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1547       1.1  christos   int cycles = 0;
   1548       1.1  christos   {
   1549       1.1  christos     int referenced = 0;
   1550       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1551       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1552       1.1  christos   }
   1553       1.1  christos   return cycles;
   1554       1.1  christos #undef FLD
   1555       1.1  christos }
   1556       1.1  christos 
   1557       1.1  christos static int
   1558       1.1  christos model_iq2000_lum64 (SIM_CPU *current_cpu, void *sem_arg)
   1559       1.1  christos {
   1560       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1561       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1562       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1563       1.1  christos   int cycles = 0;
   1564       1.1  christos   {
   1565       1.1  christos     int referenced = 0;
   1566       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1567       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1568       1.1  christos   }
   1569       1.1  christos   return cycles;
   1570       1.1  christos #undef FLD
   1571       1.1  christos }
   1572       1.1  christos 
   1573       1.1  christos static int
   1574       1.1  christos model_iq2000_lum64l (SIM_CPU *current_cpu, void *sem_arg)
   1575       1.1  christos {
   1576       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1577       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1578       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1579       1.1  christos   int cycles = 0;
   1580       1.1  christos   {
   1581       1.1  christos     int referenced = 0;
   1582       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1583       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1584       1.1  christos   }
   1585       1.1  christos   return cycles;
   1586       1.1  christos #undef FLD
   1587       1.1  christos }
   1588       1.1  christos 
   1589       1.1  christos static int
   1590       1.1  christos model_iq2000_lur (SIM_CPU *current_cpu, void *sem_arg)
   1591       1.1  christos {
   1592       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1593       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1594       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1595       1.1  christos   int cycles = 0;
   1596       1.1  christos   {
   1597       1.1  christos     int referenced = 0;
   1598       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1599       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1600       1.1  christos   }
   1601       1.1  christos   return cycles;
   1602       1.1  christos #undef FLD
   1603       1.1  christos }
   1604       1.1  christos 
   1605       1.1  christos static int
   1606       1.1  christos model_iq2000_lurl (SIM_CPU *current_cpu, void *sem_arg)
   1607       1.1  christos {
   1608       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1609       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1610       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1611       1.1  christos   int cycles = 0;
   1612       1.1  christos   {
   1613       1.1  christos     int referenced = 0;
   1614       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1615       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1616       1.1  christos   }
   1617       1.1  christos   return cycles;
   1618       1.1  christos #undef FLD
   1619       1.1  christos }
   1620       1.1  christos 
   1621       1.1  christos static int
   1622       1.1  christos model_iq2000_luulck (SIM_CPU *current_cpu, void *sem_arg)
   1623       1.1  christos {
   1624       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1625       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1626       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1627       1.1  christos   int cycles = 0;
   1628       1.1  christos   {
   1629       1.1  christos     int referenced = 0;
   1630       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1631       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1632       1.1  christos   }
   1633       1.1  christos   return cycles;
   1634       1.1  christos #undef FLD
   1635       1.1  christos }
   1636       1.1  christos 
   1637       1.1  christos static int
   1638       1.1  christos model_iq2000_mfc0 (SIM_CPU *current_cpu, void *sem_arg)
   1639       1.1  christos {
   1640       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1641       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1642       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1643       1.1  christos   int cycles = 0;
   1644       1.1  christos   {
   1645       1.1  christos     int referenced = 0;
   1646       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1647       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1648       1.1  christos   }
   1649       1.1  christos   return cycles;
   1650       1.1  christos #undef FLD
   1651       1.1  christos }
   1652       1.1  christos 
   1653       1.1  christos static int
   1654       1.1  christos model_iq2000_mfc1 (SIM_CPU *current_cpu, void *sem_arg)
   1655       1.1  christos {
   1656       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1657       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1658       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1659       1.1  christos   int cycles = 0;
   1660       1.1  christos   {
   1661       1.1  christos     int referenced = 0;
   1662       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1663       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1664       1.1  christos   }
   1665       1.1  christos   return cycles;
   1666       1.1  christos #undef FLD
   1667       1.1  christos }
   1668       1.1  christos 
   1669       1.1  christos static int
   1670       1.1  christos model_iq2000_mfc2 (SIM_CPU *current_cpu, void *sem_arg)
   1671       1.1  christos {
   1672       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1673       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1674       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1675       1.1  christos   int cycles = 0;
   1676       1.1  christos   {
   1677       1.1  christos     int referenced = 0;
   1678       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1679       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1680       1.1  christos   }
   1681       1.1  christos   return cycles;
   1682       1.1  christos #undef FLD
   1683       1.1  christos }
   1684       1.1  christos 
   1685       1.1  christos static int
   1686       1.1  christos model_iq2000_mfc3 (SIM_CPU *current_cpu, void *sem_arg)
   1687       1.1  christos {
   1688       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1689       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1690       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1691       1.1  christos   int cycles = 0;
   1692       1.1  christos   {
   1693       1.1  christos     int referenced = 0;
   1694       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1695       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1696       1.1  christos   }
   1697       1.1  christos   return cycles;
   1698       1.1  christos #undef FLD
   1699       1.1  christos }
   1700       1.1  christos 
   1701       1.1  christos static int
   1702       1.1  christos model_iq2000_mtc0 (SIM_CPU *current_cpu, void *sem_arg)
   1703       1.1  christos {
   1704       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1705       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1706       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1707       1.1  christos   int cycles = 0;
   1708       1.1  christos   {
   1709       1.1  christos     int referenced = 0;
   1710       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1711       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1712       1.1  christos   }
   1713       1.1  christos   return cycles;
   1714       1.1  christos #undef FLD
   1715       1.1  christos }
   1716       1.1  christos 
   1717       1.1  christos static int
   1718       1.1  christos model_iq2000_mtc1 (SIM_CPU *current_cpu, void *sem_arg)
   1719       1.1  christos {
   1720       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1721       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1722       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1723       1.1  christos   int cycles = 0;
   1724       1.1  christos   {
   1725       1.1  christos     int referenced = 0;
   1726       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1727       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1728       1.1  christos   }
   1729       1.1  christos   return cycles;
   1730       1.1  christos #undef FLD
   1731       1.1  christos }
   1732       1.1  christos 
   1733       1.1  christos static int
   1734       1.1  christos model_iq2000_mtc2 (SIM_CPU *current_cpu, void *sem_arg)
   1735       1.1  christos {
   1736       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1737       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1738       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1739       1.1  christos   int cycles = 0;
   1740       1.1  christos   {
   1741       1.1  christos     int referenced = 0;
   1742       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1743       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1744       1.1  christos   }
   1745       1.1  christos   return cycles;
   1746       1.1  christos #undef FLD
   1747       1.1  christos }
   1748       1.1  christos 
   1749       1.1  christos static int
   1750       1.1  christos model_iq2000_mtc3 (SIM_CPU *current_cpu, void *sem_arg)
   1751       1.1  christos {
   1752       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1753       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1754       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1755       1.1  christos   int cycles = 0;
   1756       1.1  christos   {
   1757       1.1  christos     int referenced = 0;
   1758       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1759       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1760       1.1  christos   }
   1761       1.1  christos   return cycles;
   1762       1.1  christos #undef FLD
   1763       1.1  christos }
   1764       1.1  christos 
   1765       1.1  christos static int
   1766       1.1  christos model_iq2000_pkrl (SIM_CPU *current_cpu, void *sem_arg)
   1767       1.1  christos {
   1768       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1769       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1770       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1771       1.1  christos   int cycles = 0;
   1772       1.1  christos   {
   1773       1.1  christos     int referenced = 0;
   1774       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1775       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1776       1.1  christos   }
   1777       1.1  christos   return cycles;
   1778       1.1  christos #undef FLD
   1779       1.1  christos }
   1780       1.1  christos 
   1781       1.1  christos static int
   1782       1.1  christos model_iq2000_pkrlr1 (SIM_CPU *current_cpu, void *sem_arg)
   1783       1.1  christos {
   1784       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1785       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1786       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1787       1.1  christos   int cycles = 0;
   1788       1.1  christos   {
   1789       1.1  christos     int referenced = 0;
   1790       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1791       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1792       1.1  christos   }
   1793       1.1  christos   return cycles;
   1794       1.1  christos #undef FLD
   1795       1.1  christos }
   1796       1.1  christos 
   1797       1.1  christos static int
   1798       1.1  christos model_iq2000_pkrlr30 (SIM_CPU *current_cpu, void *sem_arg)
   1799       1.1  christos {
   1800       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1801       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1802       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1803       1.1  christos   int cycles = 0;
   1804       1.1  christos   {
   1805       1.1  christos     int referenced = 0;
   1806       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1807       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1808       1.1  christos   }
   1809       1.1  christos   return cycles;
   1810       1.1  christos #undef FLD
   1811       1.1  christos }
   1812       1.1  christos 
   1813       1.1  christos static int
   1814       1.1  christos model_iq2000_rb (SIM_CPU *current_cpu, void *sem_arg)
   1815       1.1  christos {
   1816       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1817       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1818       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1819       1.1  christos   int cycles = 0;
   1820       1.1  christos   {
   1821       1.1  christos     int referenced = 0;
   1822       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1823       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1824       1.1  christos   }
   1825       1.1  christos   return cycles;
   1826       1.1  christos #undef FLD
   1827       1.1  christos }
   1828       1.1  christos 
   1829       1.1  christos static int
   1830       1.1  christos model_iq2000_rbr1 (SIM_CPU *current_cpu, void *sem_arg)
   1831       1.1  christos {
   1832       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1833       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1834       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1835       1.1  christos   int cycles = 0;
   1836       1.1  christos   {
   1837       1.1  christos     int referenced = 0;
   1838       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1839       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1840       1.1  christos   }
   1841       1.1  christos   return cycles;
   1842       1.1  christos #undef FLD
   1843       1.1  christos }
   1844       1.1  christos 
   1845       1.1  christos static int
   1846       1.1  christos model_iq2000_rbr30 (SIM_CPU *current_cpu, void *sem_arg)
   1847       1.1  christos {
   1848       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1849       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1850       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1851       1.1  christos   int cycles = 0;
   1852       1.1  christos   {
   1853       1.1  christos     int referenced = 0;
   1854       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1855       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1856       1.1  christos   }
   1857       1.1  christos   return cycles;
   1858       1.1  christos #undef FLD
   1859       1.1  christos }
   1860       1.1  christos 
   1861       1.1  christos static int
   1862       1.1  christos model_iq2000_rfe (SIM_CPU *current_cpu, void *sem_arg)
   1863       1.1  christos {
   1864       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1865       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1866       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1867       1.1  christos   int cycles = 0;
   1868       1.1  christos   {
   1869       1.1  christos     int referenced = 0;
   1870       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1871       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1872       1.1  christos   }
   1873       1.1  christos   return cycles;
   1874       1.1  christos #undef FLD
   1875       1.1  christos }
   1876       1.1  christos 
   1877       1.1  christos static int
   1878       1.1  christos model_iq2000_rx (SIM_CPU *current_cpu, void *sem_arg)
   1879       1.1  christos {
   1880       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1881       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1882       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1883       1.1  christos   int cycles = 0;
   1884       1.1  christos   {
   1885       1.1  christos     int referenced = 0;
   1886       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1887       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1888       1.1  christos   }
   1889       1.1  christos   return cycles;
   1890       1.1  christos #undef FLD
   1891       1.1  christos }
   1892       1.1  christos 
   1893       1.1  christos static int
   1894       1.1  christos model_iq2000_rxr1 (SIM_CPU *current_cpu, void *sem_arg)
   1895       1.1  christos {
   1896       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1897       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1898       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1899       1.1  christos   int cycles = 0;
   1900       1.1  christos   {
   1901       1.1  christos     int referenced = 0;
   1902       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1903       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1904       1.1  christos   }
   1905       1.1  christos   return cycles;
   1906       1.1  christos #undef FLD
   1907       1.1  christos }
   1908       1.1  christos 
   1909       1.1  christos static int
   1910       1.1  christos model_iq2000_rxr30 (SIM_CPU *current_cpu, void *sem_arg)
   1911       1.1  christos {
   1912       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1913       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1914       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1915       1.1  christos   int cycles = 0;
   1916       1.1  christos   {
   1917       1.1  christos     int referenced = 0;
   1918       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1919       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1920       1.1  christos   }
   1921       1.1  christos   return cycles;
   1922       1.1  christos #undef FLD
   1923       1.1  christos }
   1924       1.1  christos 
   1925       1.1  christos static int
   1926       1.1  christos model_iq2000_sleep (SIM_CPU *current_cpu, void *sem_arg)
   1927       1.1  christos {
   1928       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1929       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1930       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1931       1.1  christos   int cycles = 0;
   1932       1.1  christos   {
   1933       1.1  christos     int referenced = 0;
   1934       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1935       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1936       1.1  christos   }
   1937       1.1  christos   return cycles;
   1938       1.1  christos #undef FLD
   1939       1.1  christos }
   1940       1.1  christos 
   1941       1.1  christos static int
   1942       1.1  christos model_iq2000_srrd (SIM_CPU *current_cpu, void *sem_arg)
   1943       1.1  christos {
   1944       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1945       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1946       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1947       1.1  christos   int cycles = 0;
   1948       1.1  christos   {
   1949       1.1  christos     int referenced = 0;
   1950       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1951       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1952       1.1  christos   }
   1953       1.1  christos   return cycles;
   1954       1.1  christos #undef FLD
   1955       1.1  christos }
   1956       1.1  christos 
   1957       1.1  christos static int
   1958       1.1  christos model_iq2000_srrdl (SIM_CPU *current_cpu, void *sem_arg)
   1959       1.1  christos {
   1960       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1961       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1962       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1963       1.1  christos   int cycles = 0;
   1964       1.1  christos   {
   1965       1.1  christos     int referenced = 0;
   1966       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1967       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1968       1.1  christos   }
   1969       1.1  christos   return cycles;
   1970       1.1  christos #undef FLD
   1971       1.1  christos }
   1972       1.1  christos 
   1973       1.1  christos static int
   1974       1.1  christos model_iq2000_srulck (SIM_CPU *current_cpu, void *sem_arg)
   1975       1.1  christos {
   1976       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1977       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1978       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1979       1.1  christos   int cycles = 0;
   1980       1.1  christos   {
   1981       1.1  christos     int referenced = 0;
   1982       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1983       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   1984       1.1  christos   }
   1985       1.1  christos   return cycles;
   1986       1.1  christos #undef FLD
   1987       1.1  christos }
   1988       1.1  christos 
   1989       1.1  christos static int
   1990       1.1  christos model_iq2000_srwr (SIM_CPU *current_cpu, void *sem_arg)
   1991       1.1  christos {
   1992       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   1993       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   1994       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   1995       1.1  christos   int cycles = 0;
   1996       1.1  christos   {
   1997       1.1  christos     int referenced = 0;
   1998       1.1  christos     int UNUSED insn_referenced = abuf->written;
   1999       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2000       1.1  christos   }
   2001       1.1  christos   return cycles;
   2002       1.1  christos #undef FLD
   2003       1.1  christos }
   2004       1.1  christos 
   2005       1.1  christos static int
   2006       1.1  christos model_iq2000_srwru (SIM_CPU *current_cpu, void *sem_arg)
   2007       1.1  christos {
   2008       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2009       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2010       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2011       1.1  christos   int cycles = 0;
   2012       1.1  christos   {
   2013       1.1  christos     int referenced = 0;
   2014       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2015       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2016       1.1  christos   }
   2017       1.1  christos   return cycles;
   2018       1.1  christos #undef FLD
   2019       1.1  christos }
   2020       1.1  christos 
   2021       1.1  christos static int
   2022       1.1  christos model_iq2000_trapqfl (SIM_CPU *current_cpu, void *sem_arg)
   2023       1.1  christos {
   2024       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2025       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2026       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2027       1.1  christos   int cycles = 0;
   2028       1.1  christos   {
   2029       1.1  christos     int referenced = 0;
   2030       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2031       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2032       1.1  christos   }
   2033       1.1  christos   return cycles;
   2034       1.1  christos #undef FLD
   2035       1.1  christos }
   2036       1.1  christos 
   2037       1.1  christos static int
   2038       1.1  christos model_iq2000_trapqne (SIM_CPU *current_cpu, void *sem_arg)
   2039       1.1  christos {
   2040       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2041       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2042       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2043       1.1  christos   int cycles = 0;
   2044       1.1  christos   {
   2045       1.1  christos     int referenced = 0;
   2046       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2047       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2048       1.1  christos   }
   2049       1.1  christos   return cycles;
   2050       1.1  christos #undef FLD
   2051       1.1  christos }
   2052       1.1  christos 
   2053       1.1  christos static int
   2054       1.1  christos model_iq2000_traprel (SIM_CPU *current_cpu, void *sem_arg)
   2055       1.1  christos {
   2056       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2057       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2058       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2059       1.1  christos   int cycles = 0;
   2060       1.1  christos   {
   2061       1.1  christos     int referenced = 0;
   2062       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2063       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2064       1.1  christos   }
   2065       1.1  christos   return cycles;
   2066       1.1  christos #undef FLD
   2067       1.1  christos }
   2068       1.1  christos 
   2069       1.1  christos static int
   2070       1.1  christos model_iq2000_wb (SIM_CPU *current_cpu, void *sem_arg)
   2071       1.1  christos {
   2072       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2073       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2074       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2075       1.1  christos   int cycles = 0;
   2076       1.1  christos   {
   2077       1.1  christos     int referenced = 0;
   2078       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2079       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2080       1.1  christos   }
   2081       1.1  christos   return cycles;
   2082       1.1  christos #undef FLD
   2083       1.1  christos }
   2084       1.1  christos 
   2085       1.1  christos static int
   2086       1.1  christos model_iq2000_wbu (SIM_CPU *current_cpu, void *sem_arg)
   2087       1.1  christos {
   2088       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2089       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2090       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2091       1.1  christos   int cycles = 0;
   2092       1.1  christos   {
   2093       1.1  christos     int referenced = 0;
   2094       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2095       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2096       1.1  christos   }
   2097       1.1  christos   return cycles;
   2098       1.1  christos #undef FLD
   2099       1.1  christos }
   2100       1.1  christos 
   2101       1.1  christos static int
   2102       1.1  christos model_iq2000_wbr1 (SIM_CPU *current_cpu, void *sem_arg)
   2103       1.1  christos {
   2104       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2105       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2106       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2107       1.1  christos   int cycles = 0;
   2108       1.1  christos   {
   2109       1.1  christos     int referenced = 0;
   2110       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2111       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2112       1.1  christos   }
   2113       1.1  christos   return cycles;
   2114       1.1  christos #undef FLD
   2115       1.1  christos }
   2116       1.1  christos 
   2117       1.1  christos static int
   2118       1.1  christos model_iq2000_wbr1u (SIM_CPU *current_cpu, void *sem_arg)
   2119       1.1  christos {
   2120       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2121       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2122       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2123       1.1  christos   int cycles = 0;
   2124       1.1  christos   {
   2125       1.1  christos     int referenced = 0;
   2126       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2127       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2128       1.1  christos   }
   2129       1.1  christos   return cycles;
   2130       1.1  christos #undef FLD
   2131       1.1  christos }
   2132       1.1  christos 
   2133       1.1  christos static int
   2134       1.1  christos model_iq2000_wbr30 (SIM_CPU *current_cpu, void *sem_arg)
   2135       1.1  christos {
   2136       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2137       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2138       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2139       1.1  christos   int cycles = 0;
   2140       1.1  christos   {
   2141       1.1  christos     int referenced = 0;
   2142       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2143       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2144       1.1  christos   }
   2145       1.1  christos   return cycles;
   2146       1.1  christos #undef FLD
   2147       1.1  christos }
   2148       1.1  christos 
   2149       1.1  christos static int
   2150       1.1  christos model_iq2000_wbr30u (SIM_CPU *current_cpu, void *sem_arg)
   2151       1.1  christos {
   2152       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2153       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2154       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2155       1.1  christos   int cycles = 0;
   2156       1.1  christos   {
   2157       1.1  christos     int referenced = 0;
   2158       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2159       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2160       1.1  christos   }
   2161       1.1  christos   return cycles;
   2162       1.1  christos #undef FLD
   2163       1.1  christos }
   2164       1.1  christos 
   2165       1.1  christos static int
   2166       1.1  christos model_iq2000_wx (SIM_CPU *current_cpu, void *sem_arg)
   2167       1.1  christos {
   2168       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2169       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2170       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2171       1.1  christos   int cycles = 0;
   2172       1.1  christos   {
   2173       1.1  christos     int referenced = 0;
   2174       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2175       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2176       1.1  christos   }
   2177       1.1  christos   return cycles;
   2178       1.1  christos #undef FLD
   2179       1.1  christos }
   2180       1.1  christos 
   2181       1.1  christos static int
   2182       1.1  christos model_iq2000_wxu (SIM_CPU *current_cpu, void *sem_arg)
   2183       1.1  christos {
   2184       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2185       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2186       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2187       1.1  christos   int cycles = 0;
   2188       1.1  christos   {
   2189       1.1  christos     int referenced = 0;
   2190       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2191       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2192       1.1  christos   }
   2193       1.1  christos   return cycles;
   2194       1.1  christos #undef FLD
   2195       1.1  christos }
   2196       1.1  christos 
   2197       1.1  christos static int
   2198       1.1  christos model_iq2000_wxr1 (SIM_CPU *current_cpu, void *sem_arg)
   2199       1.1  christos {
   2200       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2201       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2202       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2203       1.1  christos   int cycles = 0;
   2204       1.1  christos   {
   2205       1.1  christos     int referenced = 0;
   2206       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2207       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2208       1.1  christos   }
   2209       1.1  christos   return cycles;
   2210       1.1  christos #undef FLD
   2211       1.1  christos }
   2212       1.1  christos 
   2213       1.1  christos static int
   2214       1.1  christos model_iq2000_wxr1u (SIM_CPU *current_cpu, void *sem_arg)
   2215       1.1  christos {
   2216       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2217       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2218       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2219       1.1  christos   int cycles = 0;
   2220       1.1  christos   {
   2221       1.1  christos     int referenced = 0;
   2222       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2223       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2224       1.1  christos   }
   2225       1.1  christos   return cycles;
   2226       1.1  christos #undef FLD
   2227       1.1  christos }
   2228       1.1  christos 
   2229       1.1  christos static int
   2230       1.1  christos model_iq2000_wxr30 (SIM_CPU *current_cpu, void *sem_arg)
   2231       1.1  christos {
   2232       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2233       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2234       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2235       1.1  christos   int cycles = 0;
   2236       1.1  christos   {
   2237       1.1  christos     int referenced = 0;
   2238       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2239       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2240       1.1  christos   }
   2241       1.1  christos   return cycles;
   2242       1.1  christos #undef FLD
   2243       1.1  christos }
   2244       1.1  christos 
   2245       1.1  christos static int
   2246       1.1  christos model_iq2000_wxr30u (SIM_CPU *current_cpu, void *sem_arg)
   2247       1.1  christos {
   2248       1.1  christos #define FLD(f) abuf->fields.sfmt_empty.f
   2249       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2250       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2251       1.1  christos   int cycles = 0;
   2252       1.1  christos   {
   2253       1.1  christos     int referenced = 0;
   2254       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2255       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2256       1.1  christos   }
   2257       1.1  christos   return cycles;
   2258       1.1  christos #undef FLD
   2259       1.1  christos }
   2260       1.1  christos 
   2261       1.1  christos static int
   2262       1.1  christos model_iq2000_ldw (SIM_CPU *current_cpu, void *sem_arg)
   2263       1.1  christos {
   2264       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
   2265       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2266       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2267       1.1  christos   int cycles = 0;
   2268       1.1  christos   {
   2269       1.1  christos     int referenced = 0;
   2270       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2271       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2272       1.1  christos   }
   2273       1.1  christos   return cycles;
   2274       1.1  christos #undef FLD
   2275       1.1  christos }
   2276       1.1  christos 
   2277       1.1  christos static int
   2278       1.1  christos model_iq2000_sdw (SIM_CPU *current_cpu, void *sem_arg)
   2279       1.1  christos {
   2280       1.1  christos #define FLD(f) abuf->fields.sfmt_addi.f
   2281       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2282       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2283       1.1  christos   int cycles = 0;
   2284       1.1  christos   {
   2285       1.1  christos     int referenced = 0;
   2286       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2287       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2288       1.1  christos   }
   2289       1.1  christos   return cycles;
   2290       1.1  christos #undef FLD
   2291       1.1  christos }
   2292       1.1  christos 
   2293       1.1  christos static int
   2294       1.1  christos model_iq2000_j (SIM_CPU *current_cpu, void *sem_arg)
   2295       1.1  christos {
   2296       1.1  christos #define FLD(f) abuf->fields.sfmt_j.f
   2297       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2298       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2299       1.1  christos   int cycles = 0;
   2300       1.1  christos   {
   2301       1.1  christos     int referenced = 0;
   2302       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2303       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2304       1.1  christos   }
   2305       1.1  christos   return cycles;
   2306       1.1  christos #undef FLD
   2307       1.1  christos }
   2308       1.1  christos 
   2309       1.1  christos static int
   2310       1.1  christos model_iq2000_jal (SIM_CPU *current_cpu, void *sem_arg)
   2311       1.1  christos {
   2312       1.1  christos #define FLD(f) abuf->fields.sfmt_j.f
   2313       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2314       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2315       1.1  christos   int cycles = 0;
   2316       1.1  christos   {
   2317       1.1  christos     int referenced = 0;
   2318       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2319       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2320       1.1  christos   }
   2321       1.1  christos   return cycles;
   2322       1.1  christos #undef FLD
   2323       1.1  christos }
   2324       1.1  christos 
   2325       1.1  christos static int
   2326       1.1  christos model_iq2000_bmb (SIM_CPU *current_cpu, void *sem_arg)
   2327       1.1  christos {
   2328       1.1  christos #define FLD(f) abuf->fields.sfmt_bbi.f
   2329       1.1  christos   const ARGBUF * UNUSED abuf = SEM_ARGBUF ((SEM_ARG) sem_arg);
   2330       1.1  christos   const IDESC * UNUSED idesc = abuf->idesc;
   2331       1.1  christos   int cycles = 0;
   2332       1.1  christos   {
   2333       1.1  christos     int referenced = 0;
   2334       1.1  christos     int UNUSED insn_referenced = abuf->written;
   2335       1.1  christos     cycles += iq2000bf_model_iq2000_u_exec (current_cpu, idesc, 0, referenced);
   2336       1.1  christos   }
   2337       1.1  christos   return cycles;
   2338       1.1  christos #undef FLD
   2339       1.1  christos }
   2340       1.1  christos 
   2341       1.1  christos /* We assume UNIT_NONE == 0 because the tables don't always terminate
   2342       1.1  christos    entries with it.  */
   2343       1.1  christos 
   2344       1.1  christos /* Model timing data for `iq2000'.  */
   2345       1.1  christos 
   2346       1.1  christos static const INSN_TIMING iq2000_timing[] = {
   2347       1.1  christos   { IQ2000BF_INSN_X_INVALID, 0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2348       1.1  christos   { IQ2000BF_INSN_X_AFTER, 0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2349       1.1  christos   { IQ2000BF_INSN_X_BEFORE, 0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2350       1.1  christos   { IQ2000BF_INSN_X_CTI_CHAIN, 0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2351       1.1  christos   { IQ2000BF_INSN_X_CHAIN, 0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2352       1.1  christos   { IQ2000BF_INSN_X_BEGIN, 0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2353       1.1  christos   { IQ2000BF_INSN_ADD, model_iq2000_add, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2354       1.1  christos   { IQ2000BF_INSN_ADDI, model_iq2000_addi, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2355       1.1  christos   { IQ2000BF_INSN_ADDIU, model_iq2000_addiu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2356       1.1  christos   { IQ2000BF_INSN_ADDU, model_iq2000_addu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2357       1.1  christos   { IQ2000BF_INSN_ADO16, model_iq2000_ado16, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2358       1.1  christos   { IQ2000BF_INSN_AND, model_iq2000_and, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2359       1.1  christos   { IQ2000BF_INSN_ANDI, model_iq2000_andi, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2360       1.1  christos   { IQ2000BF_INSN_ANDOI, model_iq2000_andoi, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2361       1.1  christos   { IQ2000BF_INSN_NOR, model_iq2000_nor, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2362       1.1  christos   { IQ2000BF_INSN_OR, model_iq2000_or, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2363       1.1  christos   { IQ2000BF_INSN_ORI, model_iq2000_ori, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2364       1.1  christos   { IQ2000BF_INSN_RAM, model_iq2000_ram, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2365       1.1  christos   { IQ2000BF_INSN_SLL, model_iq2000_sll, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2366       1.1  christos   { IQ2000BF_INSN_SLLV, model_iq2000_sllv, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2367       1.1  christos   { IQ2000BF_INSN_SLMV, model_iq2000_slmv, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2368       1.1  christos   { IQ2000BF_INSN_SLT, model_iq2000_slt, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2369       1.1  christos   { IQ2000BF_INSN_SLTI, model_iq2000_slti, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2370       1.1  christos   { IQ2000BF_INSN_SLTIU, model_iq2000_sltiu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2371       1.1  christos   { IQ2000BF_INSN_SLTU, model_iq2000_sltu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2372       1.1  christos   { IQ2000BF_INSN_SRA, model_iq2000_sra, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2373       1.1  christos   { IQ2000BF_INSN_SRAV, model_iq2000_srav, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2374       1.1  christos   { IQ2000BF_INSN_SRL, model_iq2000_srl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2375       1.1  christos   { IQ2000BF_INSN_SRLV, model_iq2000_srlv, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2376       1.1  christos   { IQ2000BF_INSN_SRMV, model_iq2000_srmv, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2377       1.1  christos   { IQ2000BF_INSN_SUB, model_iq2000_sub, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2378       1.1  christos   { IQ2000BF_INSN_SUBU, model_iq2000_subu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2379       1.1  christos   { IQ2000BF_INSN_XOR, model_iq2000_xor, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2380       1.1  christos   { IQ2000BF_INSN_XORI, model_iq2000_xori, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2381       1.1  christos   { IQ2000BF_INSN_BBI, model_iq2000_bbi, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2382       1.1  christos   { IQ2000BF_INSN_BBIN, model_iq2000_bbin, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2383       1.1  christos   { IQ2000BF_INSN_BBV, model_iq2000_bbv, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2384       1.1  christos   { IQ2000BF_INSN_BBVN, model_iq2000_bbvn, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2385       1.1  christos   { IQ2000BF_INSN_BEQ, model_iq2000_beq, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2386       1.1  christos   { IQ2000BF_INSN_BEQL, model_iq2000_beql, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2387       1.1  christos   { IQ2000BF_INSN_BGEZ, model_iq2000_bgez, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2388       1.1  christos   { IQ2000BF_INSN_BGEZAL, model_iq2000_bgezal, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2389       1.1  christos   { IQ2000BF_INSN_BGEZALL, model_iq2000_bgezall, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2390       1.1  christos   { IQ2000BF_INSN_BGEZL, model_iq2000_bgezl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2391       1.1  christos   { IQ2000BF_INSN_BLTZ, model_iq2000_bltz, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2392       1.1  christos   { IQ2000BF_INSN_BLTZL, model_iq2000_bltzl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2393       1.1  christos   { IQ2000BF_INSN_BLTZAL, model_iq2000_bltzal, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2394       1.1  christos   { IQ2000BF_INSN_BLTZALL, model_iq2000_bltzall, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2395       1.1  christos   { IQ2000BF_INSN_BMB0, model_iq2000_bmb0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2396       1.1  christos   { IQ2000BF_INSN_BMB1, model_iq2000_bmb1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2397       1.1  christos   { IQ2000BF_INSN_BMB2, model_iq2000_bmb2, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2398       1.1  christos   { IQ2000BF_INSN_BMB3, model_iq2000_bmb3, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2399       1.1  christos   { IQ2000BF_INSN_BNE, model_iq2000_bne, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2400       1.1  christos   { IQ2000BF_INSN_BNEL, model_iq2000_bnel, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2401       1.1  christos   { IQ2000BF_INSN_JALR, model_iq2000_jalr, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2402       1.1  christos   { IQ2000BF_INSN_JR, model_iq2000_jr, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2403       1.1  christos   { IQ2000BF_INSN_LB, model_iq2000_lb, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2404       1.1  christos   { IQ2000BF_INSN_LBU, model_iq2000_lbu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2405       1.1  christos   { IQ2000BF_INSN_LH, model_iq2000_lh, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2406       1.1  christos   { IQ2000BF_INSN_LHU, model_iq2000_lhu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2407       1.1  christos   { IQ2000BF_INSN_LUI, model_iq2000_lui, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2408       1.1  christos   { IQ2000BF_INSN_LW, model_iq2000_lw, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2409       1.1  christos   { IQ2000BF_INSN_SB, model_iq2000_sb, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2410       1.1  christos   { IQ2000BF_INSN_SH, model_iq2000_sh, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2411       1.1  christos   { IQ2000BF_INSN_SW, model_iq2000_sw, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2412       1.1  christos   { IQ2000BF_INSN_BREAK, model_iq2000_break, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2413       1.1  christos   { IQ2000BF_INSN_SYSCALL, model_iq2000_syscall, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2414       1.1  christos   { IQ2000BF_INSN_ANDOUI, model_iq2000_andoui, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2415       1.1  christos   { IQ2000BF_INSN_ORUI, model_iq2000_orui, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2416       1.1  christos   { IQ2000BF_INSN_BGTZ, model_iq2000_bgtz, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2417       1.1  christos   { IQ2000BF_INSN_BGTZL, model_iq2000_bgtzl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2418       1.1  christos   { IQ2000BF_INSN_BLEZ, model_iq2000_blez, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2419       1.1  christos   { IQ2000BF_INSN_BLEZL, model_iq2000_blezl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2420       1.1  christos   { IQ2000BF_INSN_MRGB, model_iq2000_mrgb, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2421       1.1  christos   { IQ2000BF_INSN_BCTXT, model_iq2000_bctxt, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2422       1.1  christos   { IQ2000BF_INSN_BC0F, model_iq2000_bc0f, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2423       1.1  christos   { IQ2000BF_INSN_BC0FL, model_iq2000_bc0fl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2424       1.1  christos   { IQ2000BF_INSN_BC3F, model_iq2000_bc3f, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2425       1.1  christos   { IQ2000BF_INSN_BC3FL, model_iq2000_bc3fl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2426       1.1  christos   { IQ2000BF_INSN_BC0T, model_iq2000_bc0t, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2427       1.1  christos   { IQ2000BF_INSN_BC0TL, model_iq2000_bc0tl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2428       1.1  christos   { IQ2000BF_INSN_BC3T, model_iq2000_bc3t, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2429       1.1  christos   { IQ2000BF_INSN_BC3TL, model_iq2000_bc3tl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2430       1.1  christos   { IQ2000BF_INSN_CFC0, model_iq2000_cfc0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2431       1.1  christos   { IQ2000BF_INSN_CFC1, model_iq2000_cfc1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2432       1.1  christos   { IQ2000BF_INSN_CFC2, model_iq2000_cfc2, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2433       1.1  christos   { IQ2000BF_INSN_CFC3, model_iq2000_cfc3, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2434       1.1  christos   { IQ2000BF_INSN_CHKHDR, model_iq2000_chkhdr, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2435       1.1  christos   { IQ2000BF_INSN_CTC0, model_iq2000_ctc0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2436       1.1  christos   { IQ2000BF_INSN_CTC1, model_iq2000_ctc1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2437       1.1  christos   { IQ2000BF_INSN_CTC2, model_iq2000_ctc2, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2438       1.1  christos   { IQ2000BF_INSN_CTC3, model_iq2000_ctc3, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2439       1.1  christos   { IQ2000BF_INSN_JCR, model_iq2000_jcr, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2440       1.1  christos   { IQ2000BF_INSN_LUC32, model_iq2000_luc32, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2441       1.1  christos   { IQ2000BF_INSN_LUC32L, model_iq2000_luc32l, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2442       1.1  christos   { IQ2000BF_INSN_LUC64, model_iq2000_luc64, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2443       1.1  christos   { IQ2000BF_INSN_LUC64L, model_iq2000_luc64l, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2444       1.1  christos   { IQ2000BF_INSN_LUK, model_iq2000_luk, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2445       1.1  christos   { IQ2000BF_INSN_LULCK, model_iq2000_lulck, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2446       1.1  christos   { IQ2000BF_INSN_LUM32, model_iq2000_lum32, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2447       1.1  christos   { IQ2000BF_INSN_LUM32L, model_iq2000_lum32l, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2448       1.1  christos   { IQ2000BF_INSN_LUM64, model_iq2000_lum64, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2449       1.1  christos   { IQ2000BF_INSN_LUM64L, model_iq2000_lum64l, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2450       1.1  christos   { IQ2000BF_INSN_LUR, model_iq2000_lur, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2451       1.1  christos   { IQ2000BF_INSN_LURL, model_iq2000_lurl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2452       1.1  christos   { IQ2000BF_INSN_LUULCK, model_iq2000_luulck, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2453       1.1  christos   { IQ2000BF_INSN_MFC0, model_iq2000_mfc0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2454       1.1  christos   { IQ2000BF_INSN_MFC1, model_iq2000_mfc1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2455       1.1  christos   { IQ2000BF_INSN_MFC2, model_iq2000_mfc2, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2456       1.1  christos   { IQ2000BF_INSN_MFC3, model_iq2000_mfc3, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2457       1.1  christos   { IQ2000BF_INSN_MTC0, model_iq2000_mtc0, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2458       1.1  christos   { IQ2000BF_INSN_MTC1, model_iq2000_mtc1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2459       1.1  christos   { IQ2000BF_INSN_MTC2, model_iq2000_mtc2, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2460       1.1  christos   { IQ2000BF_INSN_MTC3, model_iq2000_mtc3, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2461       1.1  christos   { IQ2000BF_INSN_PKRL, model_iq2000_pkrl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2462       1.1  christos   { IQ2000BF_INSN_PKRLR1, model_iq2000_pkrlr1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2463       1.1  christos   { IQ2000BF_INSN_PKRLR30, model_iq2000_pkrlr30, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2464       1.1  christos   { IQ2000BF_INSN_RB, model_iq2000_rb, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2465       1.1  christos   { IQ2000BF_INSN_RBR1, model_iq2000_rbr1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2466       1.1  christos   { IQ2000BF_INSN_RBR30, model_iq2000_rbr30, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2467       1.1  christos   { IQ2000BF_INSN_RFE, model_iq2000_rfe, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2468       1.1  christos   { IQ2000BF_INSN_RX, model_iq2000_rx, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2469       1.1  christos   { IQ2000BF_INSN_RXR1, model_iq2000_rxr1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2470       1.1  christos   { IQ2000BF_INSN_RXR30, model_iq2000_rxr30, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2471       1.1  christos   { IQ2000BF_INSN_SLEEP, model_iq2000_sleep, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2472       1.1  christos   { IQ2000BF_INSN_SRRD, model_iq2000_srrd, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2473       1.1  christos   { IQ2000BF_INSN_SRRDL, model_iq2000_srrdl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2474       1.1  christos   { IQ2000BF_INSN_SRULCK, model_iq2000_srulck, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2475       1.1  christos   { IQ2000BF_INSN_SRWR, model_iq2000_srwr, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2476       1.1  christos   { IQ2000BF_INSN_SRWRU, model_iq2000_srwru, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2477       1.1  christos   { IQ2000BF_INSN_TRAPQFL, model_iq2000_trapqfl, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2478       1.1  christos   { IQ2000BF_INSN_TRAPQNE, model_iq2000_trapqne, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2479       1.1  christos   { IQ2000BF_INSN_TRAPREL, model_iq2000_traprel, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2480       1.1  christos   { IQ2000BF_INSN_WB, model_iq2000_wb, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2481       1.1  christos   { IQ2000BF_INSN_WBU, model_iq2000_wbu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2482       1.1  christos   { IQ2000BF_INSN_WBR1, model_iq2000_wbr1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2483       1.1  christos   { IQ2000BF_INSN_WBR1U, model_iq2000_wbr1u, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2484       1.1  christos   { IQ2000BF_INSN_WBR30, model_iq2000_wbr30, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2485       1.1  christos   { IQ2000BF_INSN_WBR30U, model_iq2000_wbr30u, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2486       1.1  christos   { IQ2000BF_INSN_WX, model_iq2000_wx, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2487       1.1  christos   { IQ2000BF_INSN_WXU, model_iq2000_wxu, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2488       1.1  christos   { IQ2000BF_INSN_WXR1, model_iq2000_wxr1, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2489       1.1  christos   { IQ2000BF_INSN_WXR1U, model_iq2000_wxr1u, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2490       1.1  christos   { IQ2000BF_INSN_WXR30, model_iq2000_wxr30, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2491       1.1  christos   { IQ2000BF_INSN_WXR30U, model_iq2000_wxr30u, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2492       1.1  christos   { IQ2000BF_INSN_LDW, model_iq2000_ldw, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2493       1.1  christos   { IQ2000BF_INSN_SDW, model_iq2000_sdw, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2494       1.1  christos   { IQ2000BF_INSN_J, model_iq2000_j, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2495       1.1  christos   { IQ2000BF_INSN_JAL, model_iq2000_jal, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2496       1.1  christos   { IQ2000BF_INSN_BMB, model_iq2000_bmb, { { (int) UNIT_IQ2000_U_EXEC, 1, 1 } } },
   2497       1.1  christos };
   2498       1.1  christos 
   2499       1.1  christos #endif /* WITH_PROFILE_MODEL_P */
   2500       1.1  christos 
   2501       1.1  christos static void
   2502       1.1  christos iq2000_model_init (SIM_CPU *cpu)
   2503       1.1  christos {
   2504       1.1  christos   CPU_MODEL_DATA (cpu) = (void *) zalloc (sizeof (MODEL_IQ2000_DATA));
   2505       1.1  christos }
   2506       1.1  christos 
   2507       1.1  christos #if WITH_PROFILE_MODEL_P
   2508       1.1  christos #define TIMING_DATA(td) td
   2509       1.1  christos #else
   2510       1.1  christos #define TIMING_DATA(td) 0
   2511       1.1  christos #endif
   2512       1.1  christos 
   2513   1.1.1.5  christos static const SIM_MODEL iq2000_models[] =
   2514       1.1  christos {
   2515       1.1  christos   { "iq2000", & iq2000_mach, MODEL_IQ2000, TIMING_DATA (& iq2000_timing[0]), iq2000_model_init },
   2516       1.1  christos   { 0 }
   2517       1.1  christos };
   2518       1.1  christos 
   2519       1.1  christos /* The properties of this cpu's implementation.  */
   2520       1.1  christos 
   2521   1.1.1.5  christos static const SIM_MACH_IMP_PROPERTIES iq2000bf_imp_properties =
   2522       1.1  christos {
   2523       1.1  christos   sizeof (SIM_CPU),
   2524       1.1  christos #if WITH_SCACHE
   2525       1.1  christos   sizeof (SCACHE)
   2526       1.1  christos #else
   2527       1.1  christos   0
   2528       1.1  christos #endif
   2529       1.1  christos };
   2530       1.1  christos 
   2531       1.1  christos 
   2532       1.1  christos static void
   2533       1.1  christos iq2000bf_prepare_run (SIM_CPU *cpu)
   2534       1.1  christos {
   2535       1.1  christos   if (CPU_IDESC (cpu) == NULL)
   2536       1.1  christos     iq2000bf_init_idesc_table (cpu);
   2537       1.1  christos }
   2538       1.1  christos 
   2539       1.1  christos static const CGEN_INSN *
   2540       1.1  christos iq2000bf_get_idata (SIM_CPU *cpu, int inum)
   2541       1.1  christos {
   2542       1.1  christos   return CPU_IDESC (cpu) [inum].idata;
   2543       1.1  christos }
   2544       1.1  christos 
   2545       1.1  christos static void
   2546       1.1  christos iq2000_init_cpu (SIM_CPU *cpu)
   2547       1.1  christos {
   2548       1.1  christos   CPU_REG_FETCH (cpu) = iq2000bf_fetch_register;
   2549       1.1  christos   CPU_REG_STORE (cpu) = iq2000bf_store_register;
   2550       1.1  christos   CPU_PC_FETCH (cpu) = iq2000bf_h_pc_get;
   2551       1.1  christos   CPU_PC_STORE (cpu) = iq2000bf_h_pc_set;
   2552       1.1  christos   CPU_GET_IDATA (cpu) = iq2000bf_get_idata;
   2553       1.1  christos   CPU_MAX_INSNS (cpu) = IQ2000BF_INSN__MAX;
   2554       1.1  christos   CPU_INSN_NAME (cpu) = cgen_insn_name;
   2555       1.1  christos   CPU_FULL_ENGINE_FN (cpu) = iq2000bf_engine_run_full;
   2556       1.1  christos #if WITH_FAST
   2557       1.1  christos   CPU_FAST_ENGINE_FN (cpu) = iq2000bf_engine_run_fast;
   2558       1.1  christos #else
   2559       1.1  christos   CPU_FAST_ENGINE_FN (cpu) = iq2000bf_engine_run_full;
   2560       1.1  christos #endif
   2561       1.1  christos }
   2562       1.1  christos 
   2563   1.1.1.5  christos const SIM_MACH iq2000_mach =
   2564       1.1  christos {
   2565       1.1  christos   "iq2000", "iq2000", MACH_IQ2000,
   2566       1.1  christos   32, 32, & iq2000_models[0], & iq2000bf_imp_properties,
   2567       1.1  christos   iq2000_init_cpu,
   2568       1.1  christos   iq2000bf_prepare_run
   2569       1.1  christos };
   2570       1.1  christos 
   2571