blob: 36aa69491867c0f739b12e0655e9e4487b789bd3 (
plain)
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
-- Mcode back-end for ortho - Internal debugging.
-- Copyright (C) 2006 Tristan Gingold
--
-- GHDL is free software; you can redistribute it and/or modify it under
-- the terms of the GNU General Public License as published by the Free
-- Software Foundation; either version 2, or (at your option) any later
-- version.
--
-- GHDL is distributed in the hope that it will be useful, but WITHOUT ANY
-- WARRANTY; without even the implied warranty of MERCHANTABILITY or
-- FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
-- for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with GCC; see the file COPYING. If not, write to the Free
-- Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-- 02111-1307, USA.
with Ada.Text_IO;
package Ortho_Code.Debug is
package Int32_IO is new Ada.Text_IO.Integer_IO (Ortho_Code.Int32);
procedure Disp_Mode (M : Mode_Type);
-- Set a debug flag (--be-debug=X).
procedure Set_Debug_Be_Flag (C : Character);
-- any '--be-XXX=YY' option.
procedure Set_Be_Flag (Str : String);
-- --be-disp=c: tree created, before any back-end.
Flag_Disp_Code : Boolean := False;
-- --be-dump=c: tree created, before any back-end.
Flag_Dump_Code : Boolean := False;
-- a: disp assembly code.
Flag_Debug_Asm : Boolean := False;
-- A: do internal checks (assertions).
Flag_Debug_Assert : Boolean := True;
-- B: dump generated insns (at the end of insn generation).
Flag_Debug_Body : Boolean := False;
-- c: display generated insns (at the end of insn generation).
-- This is a log dump.
Flag_Debug_Code : Boolean := False;
-- C: display insns when generating code. Useful to debug code generation.
Flag_Debug_Code2 : Boolean := False;
-- h: disp bytes generated (in hexa).
Flag_Debug_Hex : Boolean := False;
-- H: generate high-level instructions.
Flag_Debug_Hli : Boolean := False;
-- d: raw dump, do not generate code.
Flag_Debug_Dump : Boolean := False;
-- i: disp insns, when generated.
-- The output may be misleading as a spill inserted later is not displayed.
-- Useful only when debugging insn generation. Use --be-debug=c to view
-- the correct output.
Flag_Debug_Insn : Boolean := False;
-- s: disp stats (number of nodes).
Flag_Debug_Stat : Boolean := False;
-- k: keep all nodes in memory (do not free).
Flag_Debug_Keep: Boolean := False;
end Ortho_Code.Debug;
|