Rizin
unix-like reverse engineering framework and cli tools
mips-opc.c File Reference
#include <stdio.h>
#include "sysdep.h"
#include "opcode/mips.h"

Go to the source code of this file.

Macros

#define LDD   INSN_LOAD_MEMORY_DELAY
 
#define LCD   INSN_LOAD_COPROC_DELAY
 
#define UBD   INSN_UNCOND_BRANCH_DELAY
 
#define CBD   INSN_COND_BRANCH_DELAY
 
#define COD   INSN_COPROC_MOVE_DELAY
 
#define CLD   INSN_COPROC_MEMORY_DELAY
 
#define CBL   INSN_COND_BRANCH_LIKELY
 
#define TRAP   INSN_TRAP
 
#define SM   INSN_STORE_MEMORY
 
#define WR_d   INSN_WRITE_GPR_D
 
#define WR_t   INSN_WRITE_GPR_T
 
#define WR_31   INSN_WRITE_GPR_31
 
#define WR_D   INSN_WRITE_FPR_D
 
#define WR_T   INSN_WRITE_FPR_T
 
#define WR_S   INSN_WRITE_FPR_S
 
#define RD_s   INSN_READ_GPR_S
 
#define RD_b   INSN_READ_GPR_S
 
#define RD_t   INSN_READ_GPR_T
 
#define RD_S   INSN_READ_FPR_S
 
#define RD_T   INSN_READ_FPR_T
 
#define RD_R   INSN_READ_FPR_R
 
#define WR_CC   INSN_WRITE_COND_CODE
 
#define RD_CC   INSN_READ_COND_CODE
 
#define RD_C0   INSN_COP
 
#define RD_C1   INSN_COP
 
#define RD_C2   INSN_COP
 
#define RD_C3   INSN_COP
 
#define WR_C0   INSN_COP
 
#define WR_C1   INSN_COP
 
#define WR_C2   INSN_COP
 
#define WR_C3   INSN_COP
 
#define WR_HI   INSN_WRITE_HI
 
#define RD_HI   INSN_READ_HI
 
#define MOD_HI   (WR_HI|RD_HI)
 
#define WR_LO   INSN_WRITE_LO
 
#define RD_LO   INSN_READ_LO
 
#define MOD_LO   (WR_LO|RD_LO)
 
#define WR_HILO   (WR_HI|WR_LO)
 
#define RD_HILO   (RD_HI|RD_LO)
 
#define MOD_HILO   (WR_HILO|RD_HILO)
 
#define IS_M   INSN_MULT
 
#define WR_MACC   INSN2_WRITE_MDMX_ACC
 
#define RD_MACC   INSN2_READ_MDMX_ACC
 
#define I1   INSN_ISA1
 
#define I2   INSN_ISA2
 
#define I3   INSN_ISA3
 
#define I4   INSN_ISA4
 
#define I5   INSN_ISA5
 
#define I32   INSN_ISA32
 
#define I64   INSN_ISA64
 
#define I33   INSN_ISA32R2
 
#define I65   INSN_ISA64R2
 
#define I3_32   INSN_ISA3_32
 
#define I3_33   INSN_ISA3_32R2
 
#define I4_32   INSN_ISA4_32
 
#define I4_33   INSN_ISA4_32R2
 
#define I5_33   INSN_ISA5_32R2
 
#define I16   INSN_MIPS16
 
#define M3D   INSN_MIPS3D
 
#define SMT   INSN_SMARTMIPS
 
#define MX   INSN_MDMX
 
#define IL2E   (INSN_LOONGSON_2E)
 
#define IL2F   (INSN_LOONGSON_2F)
 
#define P3   INSN_4650
 
#define L1   INSN_4010
 
#define V1   (INSN_4100 | INSN_4111 | INSN_4120)
 
#define T3   INSN_3900
 
#define M1   INSN_10000
 
#define SB1   INSN_SB1
 
#define N411   INSN_4111
 
#define N412   INSN_4120
 
#define N5   (INSN_5400 | INSN_5500)
 
#define N54   INSN_5400
 
#define N55   INSN_5500
 
#define IOCT   INSN_OCTEON
 
#define G1
 
#define G2
 
#define G3
 
#define WR_a   WR_HILO /* Write dsp accumulators (reuse WR_HILO) */
 
#define RD_a   RD_HILO /* Read dsp accumulators (reuse RD_HILO) */
 
#define MOD_a   (WR_a|RD_a)
 
#define DSP_VOLA   INSN_TRAP
 
#define D32   INSN_DSP
 
#define D33   INSN_DSPR2
 
#define D64   INSN_DSP64
 
#define MT32   INSN_MT
 
#define MIPS_NUM_OPCODES    ((sizeof mips_builtin_opcodes) / (sizeof (mips_builtin_opcodes[0])))
 

Variables

const struct mips_opcode mips_builtin_opcodes []
 
const int bfd_mips_num_builtin_opcodes = MIPS_NUM_OPCODES
 
struct mips_opcodemips_opcodes
 
int bfd_mips_num_opcodes = MIPS_NUM_OPCODES
 

Macro Definition Documentation

◆ CBD

#define CBD   INSN_COND_BRANCH_DELAY

Definition at line 36 of file mips-opc.c.

◆ CBL

#define CBL   INSN_COND_BRANCH_LIKELY

Definition at line 39 of file mips-opc.c.

◆ CLD

#define CLD   INSN_COPROC_MEMORY_DELAY

Definition at line 38 of file mips-opc.c.

◆ COD

#define COD   INSN_COPROC_MOVE_DELAY

Definition at line 37 of file mips-opc.c.

◆ D32

#define D32   INSN_DSP

Definition at line 160 of file mips-opc.c.

◆ D33

#define D33   INSN_DSPR2

Definition at line 161 of file mips-opc.c.

◆ D64

#define D64   INSN_DSP64

Definition at line 162 of file mips-opc.c.

◆ DSP_VOLA

#define DSP_VOLA   INSN_TRAP

Definition at line 159 of file mips-opc.c.

◆ G1

#define G1
Value:
(T3 \
)
#define T3
Definition: mips-opc.c:116

Definition at line 126 of file mips-opc.c.

◆ G2

#define G2
Value:
(T3 \
)

Definition at line 129 of file mips-opc.c.

◆ G3

#define G3
Value:
(I4 \
)
#define I4
Definition: mips-opc.c:86

Definition at line 132 of file mips-opc.c.

◆ I1

#define I1   INSN_ISA1

Definition at line 83 of file mips-opc.c.

◆ I16

#define I16   INSN_MIPS16

Definition at line 99 of file mips-opc.c.

◆ I2

#define I2   INSN_ISA2

Definition at line 84 of file mips-opc.c.

◆ I3

#define I3   INSN_ISA3

Definition at line 85 of file mips-opc.c.

◆ I32

#define I32   INSN_ISA32

Definition at line 88 of file mips-opc.c.

◆ I33

#define I33   INSN_ISA32R2

Definition at line 90 of file mips-opc.c.

◆ I3_32

#define I3_32   INSN_ISA3_32

Definition at line 92 of file mips-opc.c.

◆ I3_33

#define I3_33   INSN_ISA3_32R2

Definition at line 93 of file mips-opc.c.

◆ I4

#define I4   INSN_ISA4

Definition at line 86 of file mips-opc.c.

◆ I4_32

#define I4_32   INSN_ISA4_32

Definition at line 94 of file mips-opc.c.

◆ I4_33

#define I4_33   INSN_ISA4_32R2

Definition at line 95 of file mips-opc.c.

◆ I5

#define I5   INSN_ISA5

Definition at line 87 of file mips-opc.c.

◆ I5_33

#define I5_33   INSN_ISA5_32R2

Definition at line 96 of file mips-opc.c.

◆ I64

#define I64   INSN_ISA64

Definition at line 89 of file mips-opc.c.

◆ I65

#define I65   INSN_ISA64R2

Definition at line 91 of file mips-opc.c.

◆ IL2E

#define IL2E   (INSN_LOONGSON_2E)

Definition at line 110 of file mips-opc.c.

◆ IL2F

#define IL2F   (INSN_LOONGSON_2F)

Definition at line 111 of file mips-opc.c.

◆ IOCT

#define IOCT   INSN_OCTEON

Definition at line 124 of file mips-opc.c.

◆ IS_M

#define IS_M   INSN_MULT

Definition at line 78 of file mips-opc.c.

◆ L1

#define L1   INSN_4010

Definition at line 114 of file mips-opc.c.

◆ LCD

#define LCD   INSN_LOAD_COPROC_DELAY

Definition at line 34 of file mips-opc.c.

◆ LDD

#define LDD   INSN_LOAD_MEMORY_DELAY

Definition at line 33 of file mips-opc.c.

◆ M1

#define M1   INSN_10000

Definition at line 117 of file mips-opc.c.

◆ M3D

#define M3D   INSN_MIPS3D

Definition at line 102 of file mips-opc.c.

◆ MIPS_NUM_OPCODES

#define MIPS_NUM_OPCODES    ((sizeof mips_builtin_opcodes) / (sizeof (mips_builtin_opcodes[0])))

Definition at line 2009 of file mips-opc.c.

◆ MOD_a

#define MOD_a   (WR_a|RD_a)

Definition at line 158 of file mips-opc.c.

◆ MOD_HI

#define MOD_HI   (WR_HI|RD_HI)

Definition at line 68 of file mips-opc.c.

◆ MOD_HILO

#define MOD_HILO   (WR_HILO|RD_HILO)

Definition at line 76 of file mips-opc.c.

◆ MOD_LO

#define MOD_LO   (WR_LO|RD_LO)

Definition at line 72 of file mips-opc.c.

◆ MT32

#define MT32   INSN_MT

Definition at line 165 of file mips-opc.c.

◆ MX

#define MX   INSN_MDMX

Definition at line 108 of file mips-opc.c.

◆ N411

#define N411   INSN_4111

Definition at line 119 of file mips-opc.c.

◆ N412

#define N412   INSN_4120

Definition at line 120 of file mips-opc.c.

◆ N5

#define N5   (INSN_5400 | INSN_5500)

Definition at line 121 of file mips-opc.c.

◆ N54

#define N54   INSN_5400

Definition at line 122 of file mips-opc.c.

◆ N55

#define N55   INSN_5500

Definition at line 123 of file mips-opc.c.

◆ P3

#define P3   INSN_4650

Definition at line 113 of file mips-opc.c.

◆ RD_a

#define RD_a   RD_HILO /* Read dsp accumulators (reuse RD_HILO) */

Definition at line 157 of file mips-opc.c.

◆ RD_b

#define RD_b   INSN_READ_GPR_S

Definition at line 50 of file mips-opc.c.

◆ RD_C0

#define RD_C0   INSN_COP

Definition at line 57 of file mips-opc.c.

◆ RD_C1

#define RD_C1   INSN_COP

Definition at line 58 of file mips-opc.c.

◆ RD_C2

#define RD_C2   INSN_COP

Definition at line 59 of file mips-opc.c.

◆ RD_C3

#define RD_C3   INSN_COP

Definition at line 60 of file mips-opc.c.

◆ RD_CC

#define RD_CC   INSN_READ_COND_CODE

Definition at line 56 of file mips-opc.c.

◆ RD_HI

#define RD_HI   INSN_READ_HI

Definition at line 67 of file mips-opc.c.

◆ RD_HILO

#define RD_HILO   (RD_HI|RD_LO)

Definition at line 75 of file mips-opc.c.

◆ RD_LO

#define RD_LO   INSN_READ_LO

Definition at line 71 of file mips-opc.c.

◆ RD_MACC

#define RD_MACC   INSN2_READ_MDMX_ACC

Definition at line 81 of file mips-opc.c.

◆ RD_R

#define RD_R   INSN_READ_FPR_R

Definition at line 54 of file mips-opc.c.

◆ RD_s

#define RD_s   INSN_READ_GPR_S

Definition at line 49 of file mips-opc.c.

◆ RD_S

#define RD_S   INSN_READ_FPR_S

Definition at line 52 of file mips-opc.c.

◆ RD_t

#define RD_t   INSN_READ_GPR_T

Definition at line 51 of file mips-opc.c.

◆ RD_T

#define RD_T   INSN_READ_FPR_T

Definition at line 53 of file mips-opc.c.

◆ SB1

#define SB1   INSN_SB1

Definition at line 118 of file mips-opc.c.

◆ SM

#define SM   INSN_STORE_MEMORY

Definition at line 41 of file mips-opc.c.

◆ SMT

#define SMT   INSN_SMARTMIPS

Definition at line 105 of file mips-opc.c.

◆ T3

#define T3   INSN_3900

Definition at line 116 of file mips-opc.c.

◆ TRAP

#define TRAP   INSN_TRAP

Definition at line 40 of file mips-opc.c.

◆ UBD

#define UBD   INSN_UNCOND_BRANCH_DELAY

Definition at line 35 of file mips-opc.c.

◆ V1

#define V1   (INSN_4100 | INSN_4111 | INSN_4120)

Definition at line 115 of file mips-opc.c.

◆ WR_31

#define WR_31   INSN_WRITE_GPR_31

Definition at line 45 of file mips-opc.c.

◆ WR_a

#define WR_a   WR_HILO /* Write dsp accumulators (reuse WR_HILO) */

Definition at line 156 of file mips-opc.c.

◆ WR_C0

#define WR_C0   INSN_COP

Definition at line 61 of file mips-opc.c.

◆ WR_C1

#define WR_C1   INSN_COP

Definition at line 62 of file mips-opc.c.

◆ WR_C2

#define WR_C2   INSN_COP

Definition at line 63 of file mips-opc.c.

◆ WR_C3

#define WR_C3   INSN_COP

Definition at line 64 of file mips-opc.c.

◆ WR_CC

#define WR_CC   INSN_WRITE_COND_CODE

Definition at line 55 of file mips-opc.c.

◆ WR_d

#define WR_d   INSN_WRITE_GPR_D

Definition at line 43 of file mips-opc.c.

◆ WR_D

#define WR_D   INSN_WRITE_FPR_D

Definition at line 46 of file mips-opc.c.

◆ WR_HI

#define WR_HI   INSN_WRITE_HI

Definition at line 66 of file mips-opc.c.

◆ WR_HILO

#define WR_HILO   (WR_HI|WR_LO)

Definition at line 74 of file mips-opc.c.

◆ WR_LO

#define WR_LO   INSN_WRITE_LO

Definition at line 70 of file mips-opc.c.

◆ WR_MACC

#define WR_MACC   INSN2_WRITE_MDMX_ACC

Definition at line 80 of file mips-opc.c.

◆ WR_S

#define WR_S   INSN_WRITE_FPR_S

Definition at line 48 of file mips-opc.c.

◆ WR_t

#define WR_t   INSN_WRITE_GPR_T

Definition at line 44 of file mips-opc.c.

◆ WR_T

#define WR_T   INSN_WRITE_FPR_T

Definition at line 47 of file mips-opc.c.

Variable Documentation

◆ bfd_mips_num_builtin_opcodes

const int bfd_mips_num_builtin_opcodes = MIPS_NUM_OPCODES

Definition at line 2011 of file mips-opc.c.

◆ bfd_mips_num_opcodes

int bfd_mips_num_opcodes = MIPS_NUM_OPCODES

Definition at line 2017 of file mips-opc.c.

◆ mips_builtin_opcodes

const struct mips_opcode mips_builtin_opcodes[]

Definition at line 1 of file mips-opc.c.

◆ mips_opcodes

struct mips_opcode* mips_opcodes
Initial value:
=
const struct mips_opcode mips_builtin_opcodes[]
Definition: mips-opc.c:180

Definition at line 2015 of file mips-opc.c.

Referenced by print_insn_mips().