1 /* tic80.h -- Header file for TI TMS320C80 (MV) opcode table
2 Copyright 1996 Free Software Foundation, Inc.
3 Written by Fred Fish (fnf@cygnus.com), Cygnus Support
4 using other opcode/*.h files as templates.
6 This file is part of GDB, GAS, and the GNU binutils.
8 GDB, GAS, and the GNU binutils are free software; you can redistribute
9 them and/or modify them under the terms of the GNU General Public
10 License as published by the Free Software Foundation; either version
11 1, or (at your option) any later version.
13 GDB, GAS, and the GNU binutils are distributed in the hope that they
14 will be useful, but WITHOUT ANY WARRANTY; without even the implied
15 warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
16 the GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this file; see the file COPYING. If not, write to the Free
20 Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
25 /* The opcode table is an array of struct TIc80_opcode. */
29 /* The opcode name. */
32 /* The opcode itself. Those bits which will be filled in with
33 operands are zeroes. */
36 /* The opcode mask. This is used by the disassembler. This is a
37 mask containing ones indicating those bits which must match the
38 opcode field, and zeroes indicating those bits which need not
39 match (and are presumably filled in by operands). */
42 /* The format of this opcode. */
45 /* An array of operand codes. Each code is an index into the
46 operand table. They appear in the order which the operands must
47 appear in assembly code, and are terminated by a zero. */
48 unsigned char operands
[8];
51 /* The table itself is sorted by major opcode number, and is otherwise
52 in the order in which the disassembler should consider
54 extern const struct tic80_opcode tic80_opcodes
[];
55 extern const int tic80_num_opcodes
;
58 /* The operands table is an array of struct tic80_operand. */
62 /* The number of bits in the operand. */
65 /* How far the operand is left shifted in the instruction. */
68 /* One bit syntax flags. */
72 /* Elements in the table are retrieved by indexing with values from
73 the operands field of the tic80_opcodes table. */
75 extern const struct tic80_operand tic80_operands
[];
77 /* Values defined for the flags field of a struct tic80_operand. */
78 #define TIC80_OPERAND_DREG 0x1
80 #define TIC80_OPERAND_AREG 0x2
82 #define TIC80_OPERAND_PSW 0x4
84 #define TIC80_OPERAND_MDR 0x8
86 #define TIC80_OPERAND_SIGNED 0x10
88 #define TIC80_OPERAND_PROMOTE 0x20
90 #define TIC80_OPERAND_PAREN 0x40
92 #define TIC80_OPERAND_REPEATED 0x80
94 #define TIC80_OPERAND_EXTENDED 0x100
96 #define TIC80_OPERAND_PCREL 0x400
98 #define TIC80_OPERAND_MEMADDR 0x800