Commit | Line | Data |
---|---|---|
ef79bbde P |
1 | /*************************************************************************** |
2 | * Copyright (C) 2007 Ryan Schultz, PCSX-df Team, PCSX team * | |
3 | * * | |
4 | * This program is free software; you can redistribute it and/or modify * | |
5 | * it under the terms of the GNU General Public License as published by * | |
6 | * the Free Software Foundation; either version 2 of the License, or * | |
7 | * (at your option) any later version. * | |
8 | * * | |
9 | * This program is distributed in the hope that it will be useful, * | |
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * | |
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * | |
12 | * GNU General Public License for more details. * | |
13 | * * | |
14 | * You should have received a copy of the GNU General Public License * | |
15 | * along with this program; if not, write to the * | |
16 | * Free Software Foundation, Inc., * | |
17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02111-1307 USA. * | |
18 | ***************************************************************************/ | |
19 | ||
20 | #ifndef __DEBUG_H__ | |
21 | #define __DEBUG_H__ | |
22 | ||
23 | #ifdef __cplusplus | |
24 | extern "C" { | |
25 | #endif | |
26 | ||
27 | enum breakpoint_types { | |
28 | E, R1, R2, R4, W1, W2, W4 | |
29 | }; | |
30 | ||
31 | void StartDebugger(); | |
32 | void StopDebugger(); | |
33 | ||
34 | void DebugVSync(); | |
35 | void ProcessDebug(); | |
36 | ||
37 | void DebugCheckBP(u32 address, enum breakpoint_types type); | |
38 | ||
39 | void PauseDebugger(); | |
40 | void ResumeDebugger(); | |
41 | ||
42 | extern char *disRNameCP0[]; | |
43 | ||
44 | char* disR3000AF(u32 code, u32 pc); | |
45 | ||
46 | /* | |
47 | * Specficies which logs should be activated. | |
48 | */ | |
49 | ||
50 | //#define LOG_STDOUT | |
51 | ||
52 | //#define PAD_LOG __Log | |
53 | //#define GTE_LOG __Log | |
54 | //#define CDR_LOG __Log("%8.8lx %8.8lx: ", psxRegs.pc, psxRegs.cycle); __Log | |
55 | ||
56 | //#define PSXHW_LOG __Log("%8.8lx %8.8lx: ", psxRegs.pc, psxRegs.cycle); __Log | |
57 | //#define PSXBIOS_LOG __Log("%8.8lx %8.8lx: ", psxRegs.pc, psxRegs.cycle); __Log | |
58 | //#define PSXDMA_LOG __Log | |
59 | //#define PSXMEM_LOG __Log("%8.8lx %8.8lx: ", psxRegs.pc, psxRegs.cycle); __Log | |
60 | //#define PSXCPU_LOG __Log | |
61 | ||
62 | //#define CDRCMD_DEBUG | |
63 | ||
64 | #if defined (PSXCPU_LOG) || defined(PSXDMA_LOG) || defined(CDR_LOG) || defined(PSXHW_LOG) || \ | |
65 | defined(PSXBIOS_LOG) || defined(PSXMEM_LOG) || defined(GTE_LOG) || defined(PAD_LOG) | |
66 | #define EMU_LOG __Log | |
67 | #endif | |
68 | ||
69 | #ifdef __cplusplus | |
70 | } | |
71 | #endif | |
72 | #endif |