blob: e7dff7a1c51ecd1c59a0cf90e5ed5e101be8a476 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
// license:BSD-3-Clause
// copyright-holders:Juergen Buchmueller,Ernesto Corvi
/*****************************************************************************
*
* 8000dasm.c
* Portable Z8000(2) emulator
*
*****************************************************************************/
#ifndef MAME_CPU_Z8000_8000DASM_H
#define MAME_CPU_Z8000_8000DASM_H
#pragma once
class z8000_disassembler : public util::disasm_interface
{
public:
struct config {
virtual ~config() = default;
virtual bool get_segmented_mode() const = 0;
};
z8000_disassembler(config *conf);
virtual ~z8000_disassembler() = default;
virtual u32 opcode_alignment() const override;
virtual offs_t disassemble(std::ostream &stream, offs_t pc, const data_buffer &opcodes, const data_buffer ¶ms) override;
private:
struct opcode {
u16 beg, end, step;
u16 size;
const char *dasm;
offs_t dasmflags;
};
static const opcode table[];
static const char *const cc[16];
static const char *const flg[16];
static const char *const ints[4];
config *m_config;
u16 oplist[0x10000];
void get_op(const data_buffer &opcodes, int i, offs_t &new_pc, u16 *w, u8 *b, u8 *n);
};
#endif
|