Remove support for the (deprecated) openrisc and or32 configurations and replace
[platform/upstream/binutils.git] / opcodes / or1k-opc.h
1 /* Instruction opcode header for or1k.
2
3 THIS FILE IS MACHINE GENERATED WITH CGEN.
4
5 Copyright 1996-2010 Free Software Foundation, Inc.
6
7 This file is part of the GNU Binutils and/or GDB, the GNU debugger.
8
9    This file is free software; you can redistribute it and/or modify
10    it under the terms of the GNU General Public License as published by
11    the Free Software Foundation; either version 3, or (at your option)
12    any later version.
13
14    It is distributed in the hope that it will be useful, but WITHOUT
15    ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
16    or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
17    License for more details.
18
19    You should have received a copy of the GNU General Public License along
20    with this program; if not, write to the Free Software Foundation, Inc.,
21    51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
22
23 */
24
25 #ifndef OR1K_OPC_H
26 #define OR1K_OPC_H
27
28 /* -- opc.h */
29
30 #undef  CGEN_DIS_HASH_SIZE
31 #define CGEN_DIS_HASH_SIZE 256
32 #undef  CGEN_DIS_HASH
33 #define CGEN_DIS_HASH(buffer, value) (((unsigned char *) (buffer))[0] >> 2)
34
35 /* -- */
36 /* Enum declaration for or1k instruction types.  */
37 typedef enum cgen_insn_type {
38   OR1K_INSN_INVALID, OR1K_INSN_L_J, OR1K_INSN_L_JAL, OR1K_INSN_L_JR
39  , OR1K_INSN_L_JALR, OR1K_INSN_L_BNF, OR1K_INSN_L_BF, OR1K_INSN_L_TRAP
40  , OR1K_INSN_L_SYS, OR1K_INSN_L_RFE, OR1K_INSN_L_NOP_IMM, OR1K_INSN_L_NOP
41  , OR1K_INSN_L_MOVHI, OR1K_INSN_L_MACRC, OR1K_INSN_L_MFSPR, OR1K_INSN_L_MTSPR
42  , OR1K_INSN_L_LWZ, OR1K_INSN_L_LWS, OR1K_INSN_L_LBZ, OR1K_INSN_L_LBS
43  , OR1K_INSN_L_LHZ, OR1K_INSN_L_LHS, OR1K_INSN_L_SW, OR1K_INSN_L_SB
44  , OR1K_INSN_L_SH, OR1K_INSN_L_SLL, OR1K_INSN_L_SLLI, OR1K_INSN_L_SRL
45  , OR1K_INSN_L_SRLI, OR1K_INSN_L_SRA, OR1K_INSN_L_SRAI, OR1K_INSN_L_ROR
46  , OR1K_INSN_L_RORI, OR1K_INSN_L_AND, OR1K_INSN_L_OR, OR1K_INSN_L_XOR
47  , OR1K_INSN_L_ADD, OR1K_INSN_L_SUB, OR1K_INSN_L_ADDC, OR1K_INSN_L_MUL
48  , OR1K_INSN_L_MULU, OR1K_INSN_L_DIV, OR1K_INSN_L_DIVU, OR1K_INSN_L_FF1
49  , OR1K_INSN_L_FL1, OR1K_INSN_L_ANDI, OR1K_INSN_L_ORI, OR1K_INSN_L_XORI
50  , OR1K_INSN_L_ADDI, OR1K_INSN_L_ADDIC, OR1K_INSN_L_MULI, OR1K_INSN_L_EXTHS
51  , OR1K_INSN_L_EXTBS, OR1K_INSN_L_EXTHZ, OR1K_INSN_L_EXTBZ, OR1K_INSN_L_EXTWS
52  , OR1K_INSN_L_EXTWZ, OR1K_INSN_L_CMOV, OR1K_INSN_L_SFGTS, OR1K_INSN_L_SFGTSI
53  , OR1K_INSN_L_SFGTU, OR1K_INSN_L_SFGTUI, OR1K_INSN_L_SFGES, OR1K_INSN_L_SFGESI
54  , OR1K_INSN_L_SFGEU, OR1K_INSN_L_SFGEUI, OR1K_INSN_L_SFLTS, OR1K_INSN_L_SFLTSI
55  , OR1K_INSN_L_SFLTU, OR1K_INSN_L_SFLTUI, OR1K_INSN_L_SFLES, OR1K_INSN_L_SFLESI
56  , OR1K_INSN_L_SFLEU, OR1K_INSN_L_SFLEUI, OR1K_INSN_L_SFEQ, OR1K_INSN_L_SFEQI
57  , OR1K_INSN_L_SFNE, OR1K_INSN_L_SFNEI, OR1K_INSN_L_MAC, OR1K_INSN_L_MSB
58  , OR1K_INSN_L_MACI, OR1K_INSN_L_CUST1, OR1K_INSN_L_CUST2, OR1K_INSN_L_CUST3
59  , OR1K_INSN_L_CUST4, OR1K_INSN_L_CUST5, OR1K_INSN_L_CUST6, OR1K_INSN_L_CUST7
60  , OR1K_INSN_L_CUST8, OR1K_INSN_LF_ADD_S, OR1K_INSN_LF_ADD_D, OR1K_INSN_LF_SUB_S
61  , OR1K_INSN_LF_SUB_D, OR1K_INSN_LF_MUL_S, OR1K_INSN_LF_MUL_D, OR1K_INSN_LF_DIV_S
62  , OR1K_INSN_LF_DIV_D, OR1K_INSN_LF_REM_S, OR1K_INSN_LF_REM_D, OR1K_INSN_LF_ITOF_S
63  , OR1K_INSN_LF_ITOF_D, OR1K_INSN_LF_FTOI_S, OR1K_INSN_LF_FTOI_D, OR1K_INSN_LF_EQ_S
64  , OR1K_INSN_LF_EQ_D, OR1K_INSN_LF_NE_S, OR1K_INSN_LF_NE_D, OR1K_INSN_LF_GE_S
65  , OR1K_INSN_LF_GE_D, OR1K_INSN_LF_GT_S, OR1K_INSN_LF_GT_D, OR1K_INSN_LF_LT_S
66  , OR1K_INSN_LF_LT_D, OR1K_INSN_LF_LE_S, OR1K_INSN_LF_LE_D, OR1K_INSN_LF_MADD_S
67  , OR1K_INSN_LF_MADD_D, OR1K_INSN_LF_CUST1_S, OR1K_INSN_LF_CUST1_D
68 } CGEN_INSN_TYPE;
69
70 /* Index of `invalid' insn place holder.  */
71 #define CGEN_INSN_INVALID OR1K_INSN_INVALID
72
73 /* Total number of insns in table.  */
74 #define MAX_INSNS ((int) OR1K_INSN_LF_CUST1_D + 1)
75
76 /* This struct records data prior to insertion or after extraction.  */
77 struct cgen_fields
78 {
79   int length;
80   long f_nil;
81   long f_anyof;
82   long f_opcode;
83   long f_r1;
84   long f_r2;
85   long f_r3;
86   long f_op_25_2;
87   long f_op_25_5;
88   long f_op_16_1;
89   long f_op_7_4;
90   long f_op_3_4;
91   long f_op_9_2;
92   long f_op_9_4;
93   long f_op_7_8;
94   long f_op_7_2;
95   long f_resv_25_26;
96   long f_resv_25_10;
97   long f_resv_25_5;
98   long f_resv_23_8;
99   long f_resv_20_5;
100   long f_resv_20_4;
101   long f_resv_15_8;
102   long f_resv_15_6;
103   long f_resv_10_11;
104   long f_resv_10_7;
105   long f_resv_10_3;
106   long f_resv_10_1;
107   long f_resv_7_4;
108   long f_resv_5_2;
109   long f_imm16_25_5;
110   long f_imm16_10_11;
111   long f_disp26;
112   long f_uimm16;
113   long f_simm16;
114   long f_uimm6;
115   long f_uimm16_split;
116   long f_simm16_split;
117 };
118
119 #define CGEN_INIT_PARSE(od) \
120 {\
121 }
122 #define CGEN_INIT_INSERT(od) \
123 {\
124 }
125 #define CGEN_INIT_EXTRACT(od) \
126 {\
127 }
128 #define CGEN_INIT_PRINT(od) \
129 {\
130 }
131
132
133 #endif /* OR1K_OPC_H */