1 /* Interface to: Stub functions to interface to the GNU disassembler library 2 (libopcodes). 3 Copyright 2003 Brian R. Gaeke. 4 5 This file is part of VMIPS. 6 7 VMIPS is free software; you can redistribute it and/or modify it 8 under the terms of the GNU General Public License as published by the 9 Free Software Foundation; either version 2 of the License, or (at your 10 option) any later version. 11 12 VMIPS is distributed in the hope that it will be useful, but 13 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 14 or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 15 for more details. 16 17 You should have received a copy of the GNU General Public License along 18 with VMIPS; if not, write to the Free Software Foundation, Inc., 19 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ 20 21 #ifndef _STUB_DIS_H_ 22 #define _STUB_DIS_H_ 23 24 #include "types.h" 25 #include <cstdio> 26 extern "C" { 27 #include "bfd.h" 28 #include "dis-asm.h" 29 } 30 31 class Disassembler { 32 struct disassemble_info disasm_info; 33 int (*insn_printer_func) (unsigned long, struct disassemble_info *); 34 public: 35 Disassembler (bool host_is_bigendian, FILE *stream); ~Disassembler()36 ~Disassembler () { } 37 void disassemble (uint32 pc, uint32 instr); 38 }; 39 40 #endif /* _STUB_DIS_H_ */ 41