annotate gcc/tree-chkp.h @ 136:4627f235cf2a

fix c-next example
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Thu, 08 Nov 2018 14:11:56 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 /* Declaration of interface functions of Pointer Bounds Checker.
kono
parents:
diff changeset
2 Copyright (C) 2014-2017 Free Software Foundation, Inc.
kono
parents:
diff changeset
3
kono
parents:
diff changeset
4 This file is part of GCC.
kono
parents:
diff changeset
5
kono
parents:
diff changeset
6 GCC is free software; you can redistribute it and/or modify it under
kono
parents:
diff changeset
7 the terms of the GNU General Public License as published by the Free
kono
parents:
diff changeset
8 Software Foundation; either version 3, or (at your option) any later
kono
parents:
diff changeset
9 version.
kono
parents:
diff changeset
10
kono
parents:
diff changeset
11 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
kono
parents:
diff changeset
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
kono
parents:
diff changeset
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
kono
parents:
diff changeset
14 for more details.
kono
parents:
diff changeset
15
kono
parents:
diff changeset
16 You should have received a copy of the GNU General Public License
kono
parents:
diff changeset
17 along with GCC; see the file COPYING3. If not see
kono
parents:
diff changeset
18 <http://www.gnu.org/licenses/>. */
kono
parents:
diff changeset
19
kono
parents:
diff changeset
20 #ifndef GCC_TREE_CHKP_H
kono
parents:
diff changeset
21 #define GCC_TREE_CHKP_H
kono
parents:
diff changeset
22
kono
parents:
diff changeset
23 #define DECL_BOUNDS(NODE) (chkp_get_bounds (DECL_WRTL_CHECK (NODE)))
kono
parents:
diff changeset
24
kono
parents:
diff changeset
25 #define SET_DECL_BOUNDS(NODE, VAL) \
kono
parents:
diff changeset
26 (chkp_set_bounds (DECL_WRTL_CHECK (NODE), VAL))
kono
parents:
diff changeset
27
kono
parents:
diff changeset
28 extern tree chkp_get_bounds (tree node);
kono
parents:
diff changeset
29 extern void chkp_set_bounds (tree node, tree val);
kono
parents:
diff changeset
30 extern bool chkp_register_var_initializer (tree var);
kono
parents:
diff changeset
31 extern void chkp_finish_file (void);
kono
parents:
diff changeset
32 extern bool chkp_type_has_pointer (const_tree type);
kono
parents:
diff changeset
33 extern unsigned chkp_type_bounds_count (const_tree type);
kono
parents:
diff changeset
34 extern tree chkp_make_bounds_for_struct_addr (tree ptr);
kono
parents:
diff changeset
35 extern tree chkp_get_zero_bounds_var (void);
kono
parents:
diff changeset
36 extern tree chkp_get_none_bounds_var (void);
kono
parents:
diff changeset
37 extern void chkp_check_mem_access (tree first, tree last, tree bounds,
kono
parents:
diff changeset
38 gimple_stmt_iterator iter,
kono
parents:
diff changeset
39 location_t location,
kono
parents:
diff changeset
40 tree dirflag);
kono
parents:
diff changeset
41 extern void chkp_fix_cfg (void);
kono
parents:
diff changeset
42 extern bool chkp_variable_size_type (tree type);
kono
parents:
diff changeset
43 extern tree chkp_build_make_bounds_call (tree lb, tree size);
kono
parents:
diff changeset
44 extern tree chkp_build_bndldx_call (tree addr, tree ptr);
kono
parents:
diff changeset
45 extern tree chkp_build_bndstx_call (tree addr, tree ptr, tree bounds);
kono
parents:
diff changeset
46 extern void chkp_find_bound_slots (const_tree type, bitmap res);
kono
parents:
diff changeset
47 extern void chkp_build_bndstx (tree addr, tree ptr, tree bounds,
kono
parents:
diff changeset
48 gimple_stmt_iterator *gsi);
kono
parents:
diff changeset
49 extern gcall *chkp_retbnd_call_by_val (tree val);
kono
parents:
diff changeset
50 extern bool chkp_function_instrumented_p (tree fndecl);
kono
parents:
diff changeset
51 extern void chkp_function_mark_instrumented (tree fndecl);
kono
parents:
diff changeset
52 extern void chkp_copy_bounds_for_assign (gimple *assign,
kono
parents:
diff changeset
53 struct cgraph_edge *edge);
kono
parents:
diff changeset
54 extern bool chkp_gimple_call_builtin_p (gimple *call,
kono
parents:
diff changeset
55 enum built_in_function code);
kono
parents:
diff changeset
56 extern rtx chkp_expand_zero_bounds (void);
kono
parents:
diff changeset
57 extern void chkp_expand_bounds_reset_for_mem (tree mem, tree ptr);
kono
parents:
diff changeset
58 extern tree chkp_insert_retbnd_call (tree bndval, tree retval,
kono
parents:
diff changeset
59 gimple_stmt_iterator *gsi);
kono
parents:
diff changeset
60 extern gcall *chkp_copy_call_skip_bounds (gcall *call);
kono
parents:
diff changeset
61 extern bool chkp_redirect_edge (cgraph_edge *e);
kono
parents:
diff changeset
62 extern void chkp_fixup_inlined_call (tree lhs, tree rhs);
kono
parents:
diff changeset
63
kono
parents:
diff changeset
64 #endif /* GCC_TREE_CHKP_H */