1/*****************************************************************************/
2/* */
3/* handler.h */
4/* */
5/* Opcode handler functions for the disassembler */
6/* */
7/* */
8/* */
9/* (C) 2000-2011, Ullrich von Bassewitz */
10/* Roemerstrasse 52 */
11/* D-70794 Filderstadt */
12/* EMail: uz@cc65.org */
13/* */
14/* */
15/* This software is provided 'as-is', without any expressed or implied */
16/* warranty. In no event will the authors be held liable for any damages */
17/* arising from the use of this software. */
18/* */
19/* Permission is granted to anyone to use this software for any purpose, */
20/* including commercial applications, and to alter it and redistribute it */
21/* freely, subject to the following restrictions: */
22/* */
23/* 1. The origin of this software must not be misrepresented; you must not */
24/* claim that you wrote the original software. If you use this software */
25/* in a product, an acknowledgment in the product documentation would be */
26/* appreciated but is not required. */
27/* 2. Altered source versions must be plainly marked as such, and must not */
28/* be misrepresented as being the original software. */
29/* 3. This notice may not be removed or altered from any source */
30/* distribution. */
31/* */
32/*****************************************************************************/
33
34
35
36#ifndef HANDLER_H
37#define HANDLER_H
38
39
40
41/* common */
42#include "attrib.h"
43
44/* da65 */
45#include "opctable.h"
46
47
48
49/*****************************************************************************/
50/* Code */
51/*****************************************************************************/
52
53
54
55/* Generic handlers */
56void OH_Illegal (const OpcDesc* D attribute ((unused)));
57void OH_Accumulator (const OpcDesc*);
58void OH_Implicit (const OpcDesc*);
59void OH_Immediate (const OpcDesc*);
60void OH_ImmediateWord (const OpcDesc*);
61void OH_Direct (const OpcDesc*);
62void OH_DirectX (const OpcDesc*);
63void OH_DirectY (const OpcDesc*);
64void OH_Absolute (const OpcDesc*);
65void OH_AbsoluteX (const OpcDesc*);
66void OH_AbsoluteY (const OpcDesc*);
67void OH_AbsoluteLong (const OpcDesc*);
68void OH_AbsoluteLongX (const OpcDesc*);
69void OH_Relative (const OpcDesc*);
70void OH_RelativeLong (const OpcDesc*);
71void OH_RelativeLong4510 (const OpcDesc*);
72void OH_DirectIndirect (const OpcDesc*);
73void OH_DirectIndirectY (const OpcDesc*);
74void OH_DirectIndirectZ (const OpcDesc*);
75void OH_DirectXIndirect (const OpcDesc*);
76void OH_AbsoluteIndirect (const OpcDesc*);
77
78void OH_BitBranch (const OpcDesc*);
79
80void OH_ImmediateDirect (const OpcDesc*);
81void OH_ImmediateDirectX (const OpcDesc*);
82void OH_ImmediateAbsolute (const OpcDesc*);
83void OH_ImmediateAbsoluteX (const OpcDesc*);
84
85void OH_StackRelative (const OpcDesc*);
86void OH_DirectIndirectLongX (const OpcDesc*);
87void OH_StackRelativeIndirectY (const OpcDesc*);
88void OH_StackRelativeIndirectY4510 (const OpcDesc*);
89void OH_DirectIndirectLong (const OpcDesc*);
90void OH_DirectIndirectLongY (const OpcDesc*);
91void OH_BlockMove (const OpcDesc*);
92void OH_AbsoluteXIndirect (const OpcDesc*);
93
94/* Mitsubishi 740 */
95void OH_DirectImmediate (const OpcDesc*);
96void OH_ZeroPageBit (const OpcDesc*);
97void OH_AccumulatorBit (const OpcDesc*);
98void OH_AccumulatorBitBranch (const OpcDesc*);
99void OH_JmpDirectIndirect (const OpcDesc* D);
100void OH_SpecialPage (const OpcDesc*);
101
102/* Handlers for special instructions */
103void OH_Rts (const OpcDesc*);
104void OH_JmpAbsolute (const OpcDesc*);
105void OH_JmpAbsoluteIndirect (const OpcDesc* D);
106void OH_JmpAbsoluteXIndirect (const OpcDesc* D);
107void OH_JsrAbsolute (const OpcDesc*);
108
109void SetSubroutineParamSize (unsigned Addr, unsigned Size);
110
111
112/* End of handler.h */
113
114#endif
115