PIPS
naming.h
Go to the documentation of this file.
1 /* Warning! Do not modify this file that is automatically generated! */
2 /* Modify src/Libs/naming/naming-local.h instead, to add your own modifications. */
3 
4 /* header file built by cproto */
5 
6 #ifndef naming_header_included
7 #define naming_header_included
8 /* naming-local.h */
9 /*
10 
11  $Id: naming.h$
12 
13  Copyright 1989-2016 MINES ParisTech
14 
15  This file is part of PIPS.
16 
17  PIPS is free software: you can redistribute it and/or modify it
18  under the terms of the GNU General Public License as published by
19  the Free Software Foundation, either version 3 of the License, or
20  any later version.
21 
22  PIPS is distributed in the hope that it will be useful, but WITHOUT ANY
23  WARRANTY; without even the implied warranty of MERCHANTABILITY or
24  FITNESS FOR A PARTICULAR PURPOSE.
25 
26  See the GNU General Public License for more details.
27 
28  You should have received a copy of the GNU General Public License
29  along with PIPS. If not, see <http://www.gnu.org/licenses/>.
30 
31 */
32 
33 /* special characters to build entity names of various kinds
34  */
35 #define MODULE_SEP ':'
36 #define MODULE_SEP_CHAR MODULE_SEP
37 
38 #define MODULE_SEP_STRING ":"
39 #define LABEL_PREFIX "@"
40 #define MAIN_PREFIX "%"
41 #define MAIN_PREFIX_CHAR '%'
42 #define COMMON_PREFIX "~"
43 #define BLOCKDATA_PREFIX "&"
44 #define F95MODULE_PREFIX "\xa4" // unicode character CURRENCY SIGN
45 
46 #define FILE_SEP_CHAR '!'
47 #define FILE_SEP FILE_SEP_CHAR
48 
49 #define FILE_SEP_STRING "!"
50 
51 #define MODULE_NAME_CHARS \
52  ( "ABCDEFGHIJKLMNOPQRSTUVWXYZ" \
53  "0123456789" \
54  "abcdefghijklmnopqrstuvwxyz" \
55  FILE_SEP_STRING MODULE_SEP_STRING "|_#-." )
56 
57 /* Scope separator */
58 #define BLOCK_SEP_STRING "`"
59 #define BLOCK_SEP_CHAR '`'
60 
61 #define MEMBER_SEP_STRING "^"
62 #define MEMBER_SEP_CHAR '^'
63 
64 #define STRUCT_PREFIX "#" // Conflict with value naming in transformer
65 #define STRUCT_PREFIX_CHAR '#'
66 #define UNION_PREFIX "'" /* Conflict with C character constants */
67 #define UNION_PREFIX_CHAR '\''
68 #define ENUM_PREFIX "?"
69 #define ENUM_PREFIX_CHAR '?'
70 #define TYPEDEF_PREFIX "$"
71 #define TYPEDEF_PREFIX_CHAR '$'
72 
73 /* constant names
74  */
75 #define F95_USE_LOCAL_NAME "*USE*"
76 #define BLANK_COMMON_LOCAL_NAME "*BLANK*"
77 #define DYNAMIC_AREA_LOCAL_NAME "*DYNAMIC*"
78 #define STATIC_AREA_LOCAL_NAME "*STATIC*"
79 #define HEAP_AREA_LOCAL_NAME "*HEAP*"
80 #define STACK_AREA_LOCAL_NAME "*STACK*"
81 #define ALLOCATABLE_AREA_LOCAL_NAME "*ALLOCATABLE*"
82 // The formal area could have been used for formal parameters
83 // It is used for the formal context of a function in points-to analysis
84 #define FORMAL_AREA_LOCAL_NAME "*FORMAL*"
85 #define POINTER_DUMMY_TARGETS_AREA_LOCAL_NAME "*POINTER_DUMMY_TARGETS*"
86 
87 /* The set of all memory areas. FI: this macro is now obsolete and
88  should be removed when a new version of alias-classes is
89  introduced. Too bad ri-util/effects.c is going to depend on
90  alias-classes*/
91 #define ALL_MEMORY_ENTITY_NAME "TOP-LEVEL:*MEMORY*"
92 
93 /* For enum and struct and union without names (see c_syntax/cyacc.y) */
94 #define DUMMY_ENUM_PREFIX "_PIPS_ENUM_"
95 #define DUMMY_STRUCT_PREFIX "_PIPS_STRUCT_"
96 #define DUMMY_UNION_PREFIX "_PIPS_UNION_"
97 #define DUMMY_ABSTRACT_PREFIX "_PIPS_ABSTRACT_"
98 #define DUMMY_MEMBER_PREFIX "_PIPS_MEMBER_" /* For bit fields */
99 
100 /* For dmmmy parameters in functions declarations */
101 #define DUMMY_PARAMETER_PREFIX "DUMMY-PARAMETER-"
102 
103 /* Its value is "@", the label prefix followed by nothing */
104 #define EMPTY_LABEL_NAME LABEL_PREFIX
105 #define LIST_DIRECTED_FORMAT_NAME "LIST-DIRECTED"
106 
107 
108 /* Module containing the global variables in Fortran and C */
109 #define TOP_LEVEL_MODULE_NAME "TOP-LEVEL"
110 /* Module containing stub variables used to initialize intraprocedural
111  points-to in C */
112 #define POINTS_TO_MODULE_NAME "*POINTS-TO-MODULE*"
113 
114 #define RETURN_LABEL_NAME "00000"
115 
116 /* In C, the module name may include file names, the compilation unit
117  * name and the user name of the function. It goes well beyond the 36
118  * of Fortan (check the standard).
119 */
120 #define MAXIMAL_MODULE_NAME_SIZE 100
121 
122 /* Constants for pragma management */
123 #define C_PRAGMA_HEADER_STRING "#pragma"
124 #define FORTRAN_PRAGMA_HEADER_STRING "!$"
125 #define FORTRAN_OMP_CONTINUATION_STRING "\n!$omp& "
126 /* cproto-generated files */
127 /* entity_names.c */
128 extern bool compilation_unit_p(const char */*module_name*/);
129 extern bool module_name_p(string /*name*/);
130 extern bool main_module_global_name_p(const char */*name*/);
131 extern bool main_module_name_p(const char */*name*/);
132 extern bool static_module_name_p(const char */*name*/);
133 extern const char *global_name_to_user_name(const char */*global_name*/);
134 extern const char *local_name(const char */*s*/);
135 extern string make_entity_fullname(const char */*module_name*/, const char */*local_name*/);
136 extern bool empty_string_p(const char */*s*/);
137 extern bool blank_string_p(const char */*s*/);
138 extern bool return_local_label_name_p(const char */*s*/);
139 extern bool empty_label_p(const char */*s*/);
140 extern bool empty_global_label_p(const char */*gln*/);
141 extern bool return_label_p(const char */*s*/);
142 extern const char *module_name(const char */*s*/);
143 /* file_names.c */
144 extern string string_codefilename(const char */*s*/);
145 extern string string_par_codefilename(const char */*s*/);
146 extern string string_fortranfilename(const char */*s*/);
147 extern bool string_fortran_filename_p(const char */*s*/);
148 extern string string_par_fortranfilename(const char */*s*/);
149 extern string string_pp_fortranfilename(const char */*s*/);
150 extern string string_predicat_fortranfilename(const char */*s*/);
151 extern string string_entitiesfilename(const char */*s*/);
152 extern void set_script_directory_name(string /*dn*/);
153 extern string get_script_directory_name(void);
154 #endif /* naming_header_included */
bool empty_global_label_p(const char *)
Definition: entity_names.c:264
bool empty_string_p(const char *)
Definition: entity_names.c:239
bool empty_label_p(const char *)
Definition: entity_names.c:256
string string_codefilename(const char *)
file_names.c
Definition: file_names.c:37
string get_script_directory_name(void)
Definition: file_names.c:110
bool module_name_p(string)
Check if the given name is the name of a plain module and not of a compilation unit.
Definition: entity_names.c:73
string string_predicat_fortranfilename(const char *)
Definition: file_names.c:81
bool main_module_name_p(const char *)
Argument "name" is a local name (not a user name)
Definition: entity_names.c:108
const char * global_name_to_user_name(const char *)
functions on strings for entity names
Definition: entity_names.c:136
bool return_local_label_name_p(const char *)
Definition: entity_names.c:251
string string_par_codefilename(const char *)
Definition: file_names.c:43
string string_fortranfilename(const char *)
Definition: file_names.c:49
bool string_fortran_filename_p(const char *)
Definition: file_names.c:55
bool return_label_p(const char *)
Definition: entity_names.c:272
bool blank_string_p(const char *)
Definition: entity_names.c:245
bool main_module_global_name_p(const char *)
Argument "name" is a global name.
Definition: entity_names.c:86
string string_pp_fortranfilename(const char *)
Definition: file_names.c:75
void set_script_directory_name(string)
Definition: file_names.c:105
bool static_module_name_p(const char *)
Check if the given name is a static module name.
Definition: entity_names.c:122
const char * module_name(const char *)
Return the module part of an entity name.
Definition: entity_names.c:296
string string_par_fortranfilename(const char *)
Definition: file_names.c:69
const char * local_name(const char *)
Does not take care of block scopes and returns a pointer.
Definition: entity_names.c:221
string make_entity_fullname(const char *, const char *)
END_EOLE.
Definition: entity_names.c:230
string string_entitiesfilename(const char *)
Definition: file_names.c:87
bool compilation_unit_p(const char *)
cproto-generated files
Definition: entity_names.c:56