GCC Middle and Back End API Reference
toplev.h
Go to the documentation of this file.
1/* toplev.h - Various declarations for functions found in toplev.cc
2 Copyright (C) 1998-2024 Free Software Foundation, Inc.
3
4This file is part of GCC.
5
6GCC is free software; you can redistribute it and/or modify it under
7the terms of the GNU General Public License as published by the Free
8Software Foundation; either version 3, or (at your option) any later
9version.
10
11GCC is distributed in the hope that it will be useful, but WITHOUT ANY
12WARRANTY; without even the implied warranty of MERCHANTABILITY or
13FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14for more details.
15
16You should have received a copy of the GNU General Public License
17along with GCC; see the file COPYING3. If not see
18<http://www.gnu.org/licenses/>. */
19
20#ifndef GCC_TOPLEV_H
21#define GCC_TOPLEV_H
22
23/* Decoded options, and number of such options. */
25extern unsigned int save_decoded_options_count;
27
28class timer;
29
30/* Invoking the compiler. */
31class toplev
32{
33public:
34 toplev (timer *external_timer,
35 bool init_signals);
36 ~toplev ();
37
38 int main (int argc, char **argv);
39
40 void finalize ();
41
42private:
43
44 void start_timevars ();
45
46 void run_self_tests ();
47
50};
51
52extern void rest_of_decl_compilation (tree, int, int);
53extern void rest_of_type_compilation (tree, int);
54extern void init_optimization_passes (void);
55extern bool enable_rtl_dump_file (void);
56
57/* In except.cc. Initialize exception handling. This is used by the Ada
58 and LTO front ends to initialize EH "on demand". See lto-streamer-in.cc
59 and ada/gcc-interface/misc.cc. */
60extern void init_eh (void);
61
62extern void announce_function (tree);
63
66extern bool wrapup_global_declarations (tree *, int);
67
68extern void global_decl_processing (void);
69
70extern void
71dump_memory_report (const char *);
72extern void dump_profile_report (void);
73
74extern void target_reinit (void);
75
76/* A unique local time stamp, might be zero if none is available. */
77extern unsigned local_tick;
78
79/* See toplev.cc. */
81
82extern void print_version (FILE *, const char *, bool);
83
84/* The hashtables, so that the C front ends can pass them to cpplib. */
85extern struct ht *ident_hash;
86extern struct ht *ident_hash_extra;
87
88/* Functions used to get and set GCC's notion of in what directory
89 compilation was started. */
90
91extern const char *get_src_pwd (void);
92extern bool set_src_pwd (const char *);
93
94/* Functions used to manipulate the random seed. */
95
96extern HOST_WIDE_INT get_random_seed (bool);
97extern void set_random_seed (const char *);
98
99extern void parse_alignment_opts (void);
100
101extern void initialize_rtl (void);
102
103#endif /* ! GCC_TOPLEV_H */
Definition timevar.h:107
Definition toplev.h:32
void finalize()
Definition toplev.cc:2359
bool m_use_TV_TOTAL
Definition toplev.h:48
void start_timevars()
Definition toplev.cc:2201
~toplev()
Definition toplev.cc:2186
toplev(timer *external_timer, bool init_signals)
Definition toplev.cc:2177
void run_self_tests()
Definition toplev.cc:2212
bool m_init_signals
Definition toplev.h:49
union tree_node * tree
Definition coretypes.h:97
int main(void)
Definition fp-test.cc:85
static int print_version
Definition gcc.cc:228
Definition opts.h:250
Definition vec.h:450
HOST_WIDE_INT get_random_seed(bool)
Definition toplev.cc:267
struct ht * ident_hash
Definition stringpool.cc:34
const char * get_src_pwd(void)
Definition toplev.cc:204
bool wrapup_global_declarations(tree *, int)
Definition toplev.cc:415
void initialize_rtl(void)
Definition toplev.cc:1808
void init_optimization_passes(void)
void global_decl_processing(void)
Definition langhooks.cc:302
void init_eh(void)
Definition except.cc:229
void parse_alignment_opts(void)
Definition toplev.cc:1224
void dump_profile_report(void)
Definition passes.cc:1923
void dump_memory_report(const char *)
Definition toplev.cc:1973
void target_reinit(void)
Definition toplev.cc:1905
struct cl_decoded_option * save_decoded_options
Definition toplev.cc:112
void rest_of_type_compilation(tree, int)
Definition passes.cc:331
void rest_of_decl_compilation(tree, int, int)
Definition passes.cc:170
vec< cl_decoded_option > * save_opt_decoded_options
Definition toplev.cc:116
unsigned local_tick
Definition toplev.cc:136
bool enable_rtl_dump_file(void)
Definition dumpfile.cc:2075
bool wrapup_global_declaration_2(tree)
Definition toplev.cc:343
unsigned int save_decoded_options_count
Definition toplev.cc:113
void wrapup_global_declaration_1(tree)
Definition toplev.cc:327
void set_random_seed(const char *)
Definition toplev.cc:288
bool set_src_pwd(const char *)
Definition toplev.cc:185
void announce_function(tree)
Definition toplev.cc:219
int flag_rerun_cse_after_global_opts
Definition gcse.cc:249
struct ht * ident_hash_extra
Definition stringpool.cc:35