2 * Copyright (C) 2024 Mikulas Patocka
4 * This file is part of Ajla.
6 * Ajla is free software: you can redistribute it and/or modify it under the
7 * terms of the GNU General Public License as published by the Free Software
8 * Foundation, either version 3 of the License, or (at your option) any later
11 * Ajla is distributed in the hope that it will be useful, but WITHOUT ANY
12 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
13 * A PARTICULAR PURPOSE. See the GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License along with
16 * Ajla. If not, see <https://www.gnu.org/licenses/>.
25 #define save_prepare name(save_prepare)
26 #define save_start_function name(save_start_function)
27 #define save_cache_entry name(save_cache_entry)
28 #define save_finish_function name(save_finish_function)
29 #define save_find_function_descriptor name(save_find_function_descriptor)
30 #define save_register_dependence name(save_register_dependence)
32 extern bool save_disable
;
34 void save_prepare(void);
35 void save_start_function(struct data
*d
, bool new_cache
);
36 void save_cache_entry(struct data
*d
, struct cache_entry
*ce
);
37 void save_finish_function(struct data
*d
);
39 struct function_descriptor
{
40 struct data
*data_saved_cache
;
43 const struct local_variable_flags
*local_variables_flags
;
46 struct line_position
*lp
;
48 void *unoptimized_code_base
;
49 size_t unoptimized_code_size
;
52 struct trap_record
*trap_records
;
53 size_t trap_records_size
;
54 struct module_designator
*md
;
55 struct function_designator
*fd
;
58 struct function_descriptor
*save_find_function_descriptor(const struct module_designator
*md
, const struct function_designator
*fd
);
60 void save_register_dependence(const char *path_name
);