* Makefile.am: Run "make dep-am".
[binutils.git] / opcodes / arc-dis.h
blobc1120d13d351e7fc133ba273f2e2e4eaff37ab23
1 /* Disassembler structures definitions for the ARC.
2 Copyright 1994, 1995, 1997, 1998, 2000, 2001
3 Free Software Foundation, Inc.
4 Contributed by Doug Evans (dje@cygnus.com).
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software Foundation,
18 Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
20 #ifndef ARCDIS_H
21 #define ARCDIS_H
23 enum
25 BR_exec_when_no_jump,
26 BR_exec_always,
27 BR_exec_when_jump
30 enum Flow
32 noflow,
33 direct_jump,
34 direct_call,
35 indirect_jump,
36 indirect_call,
37 invalid_instr
40 enum { no_reg = 99 };
41 enum { allOperandsSize = 256 };
43 struct arcDisState
45 void *_this;
46 int instructionLen;
47 void (*err)(void*, const char*);
48 const char *(*coreRegName)(void*, int);
49 const char *(*auxRegName)(void*, int);
50 const char *(*condCodeName)(void*, int);
51 const char *(*instName)(void*, int, int, int*);
53 unsigned char* instruction;
54 unsigned index;
55 const char *comm[6]; /* instr name, cond, NOP, 3 operands */
56 int opWidth;
57 int targets[4];
58 int addresses[4];
59 /* Set as a side-effect of calling the disassembler.
60 Used only by the debugger. */
61 enum Flow flow;
62 int register_for_indirect_jump;
63 int ea_reg1, ea_reg2, _offset;
64 int _cond, _opcode;
65 unsigned long words[2];
66 char *commentBuffer;
67 char instrBuffer[40];
68 char operandBuffer[allOperandsSize];
69 char _ea_present;
70 char _mem_load;
71 char _load_len;
72 char nullifyMode;
73 unsigned char commNum;
74 unsigned char isBranch;
75 unsigned char tcnt;
76 unsigned char acnt;
79 #define __TRANSLATION_REQUIRED(state) ((state).acnt != 0)
81 #endif