PIPS
|
#include <stdlib.h>
#include <stdio.h>
#include <stdarg.h>
#include <ctype.h>
#include "genC.h"
#include "misc.h"
#include "linear.h"
#include <unistd.h>
Go to the source code of this file.
Macros | |
#define | LOG_FILE "Logfile" |
#define | PIPS_THANKS_STRING(arch) |
The # "stringificator" only works in a macro expansion... More... | |
#define | WARNING_FILE_NAME "Warnings" |
USER_WARNING issues a warning and don't stop the program (cf. More... | |
Functions | |
bool | properties_initialized_p (void) |
FC 2015-07-20: yuk, moved out to prevent an include cycle dependency include "properties.h". More... | |
bool | get_bool_property (const string) |
FC 2015-07-20: yuk, moved out to prevent an include cycle dependency include "properties.h". More... | |
char * | get_string_property (const char *) |
int | get_int_property (const string) |
bool | too_many_property_errors_pending_p (void) |
void | set_pips_current_computation (const char *rname, const char *oname) |
message.c More... | |
string | get_pips_current_pass_name (void) |
Export this piece of information to customize warning functions in passes. More... | |
string | get_pips_current_module (void) |
void | reset_pips_current_computation (void) |
void | set_pips_meta_informations (const char *revs, const char *date, const char *comp) |
string | default_user_request (const char *fmt, va_list *args) |
USER_REQUEST is a function that should be called to request some data from the user. More... | |
void | close_log_file (void) |
void | open_log_file (const string dir) |
void | log_on_file (const char *desc) |
static void | pips_user_log_alist (const char *format, va_list *args) |
void | pips_user_log_func (const char *format,...) |
void | user_log (const char *format,...) |
void | pips_thanks (string name, string path) |
display pips thanks on startup, if it on a tty. More... | |
void | open_warning_file (const char *dir) |
void | close_warning_file (void) |
void | append_to_warning_file (const char *calling_function_name, const char *format, va_list *args) |
To be used in error handling functions. More... | |
void | pips_user_warning_alist (const char *function_name, const char *funcfile, const int funcline, const char *format, va_list *args) |
void | pips_user_warning_func (const char *calling_function_name, const char *funcfile, const int funcline, const char *format,...) |
void | pips_user_warning_func2 (const char *format,...) |
fallback version without a calling function name More... | |
static void _NORETURN_ | pips_internal_error_alist (const char *funcname, const char *funcfile, const int funcline, const char *format, va_list *args) |
void _NORETURN_ | pips_internal_error_func (const char *funcname, const char *funcfile, const int funcline, const char *fmt,...) |
void _NORETURN_ | pips_internal_error_func2 (const char *format,...) |
static void _NORETURN_ | pips_user_error_alist (const char *calling_function_name, const char *funcfile, const int funcline, const char *format, va_list *args) |
void _NORETURN_ | pips_user_error_func (const char *func_name, const char *funcfile, const int funcline, const char *format,...) |
void _NORETURN_ | pips_user_error_func2 (const char *format,...) |
void _NORETURN_ | pips_user_irrecoverable_error_alist (const char *func_name, const char *funcfile, const int funcline, const char *format, va_list *args) |
void _NORETURN_ | pips_user_irrecoverable_error_func (const char *func_name, const char *funcfile, const int funcline, const char *format,...) |
void _NORETURN_ | pips_user_irrecoverable_error_func2 (const char *format,...) |
bool | function_same_string_p (const char *s1, const char *s2) |
static void | append_xml_attribute (string_buffer sb, const string attribute, const string value) |
generate xml: attribute="escaped-stuff" More... | |
void | open_xml_logfile (const char *filename) |
void | close_xml_logfile (void) |
static void | append_xml_line_numbers (string_buffer sb, const string attribute, int val1, int val2) |
static string | pips_log_xml_tag (pips_log_t tag) |
static void | pips_log_xml_pips_level (string_buffer sb, const string pips_pass, const string pips_owner, const string pips_func, const string pips_file, const int pips_line) |
append pips-level stuff (function, file, line) to xml file More... | |
static void | pips_log_xml (const pips_log_t tag, const string pips_pass, const string pips_owner, const string pips_func, const string pips_file, const int pips_line, const string user_func, const string user_file, const int user_line, const int user_line2, const string stmt, const string suggestion, const string description) |
add a full log entry to the xml log file More... | |
static string | code2status (int code) |
static void | pips_stop_xml (pips_log_t tag, int code, const string pips_func, const string pips_file, const int pips_line, const string description) |
static void | pips_stop_file (FILE *out, pips_log_t tag, int code, const char *pips_func, const char *pips_file, const int pips_line, const string description) |
static void _NORETURN_ | pips_stop_desc (pips_log_t tag, int code, const string pips_func, const string pips_file, const int pips_line, const string desc) |
static void _NORETURN_ | pips_stop_alist (pips_log_t tag, int code, const string pips_func, const string pips_file, const int pips_line, const string format, va_list *args) |
void _NORETURN_ | pips_stop_func (const char *pips_func, const char *pips_file, const int pips_line, pips_log_t tag, int code, const string format,...) |
expecititely declare "noreturn" functions... More... | |
void _NORETURN_ | pips_stop_func2 (pips_log_t tag, int code, const string format,...) |
string | pips_log_tag_name (pips_log_t tag) |
static void | pips_log_file (FILE *out, const pips_log_t tag, const string pips_pass, const string pips_owner, const string pips_func, const string pips_file, const int pips_line, const string user_func, const string user_file, const int user_line, const int user_line2, const string stmt, const string suggestion, const string description) |
static void | pips_log_display (const pips_log_t tag, const string pips_pass, const string pips_owner, const string pips_func, const string pips_file, const int pips_line, const string user_func, const string user_file, const int user_line, const int user_line2, const string stmt, const string suggestion, const string desc) |
manage "displaying" a log entry, on stderr, in files... More... | |
static void | pips_log_in_progress (const char *pips_func, const char *pips_file, const int pips_line) |
static void | pips_log_done (void) |
static void | pips_log_end (pips_log_t tag) |
end of log entry (nothing, exception, abort, exit...) More... | |
void | pips_log_desc (const pips_log_t tag, const string pips_pass, const string pips_owner, const string pips_func, const string pips_file, const int pips_line, const string user_func, const string user_file, const int user_line, const int user_line2, const string stmt, const string suggestion, const string description) |
log entry with preprocessed format/arguments More... | |
void | pips_log_alist (const pips_log_t tag, const string pips_pass, const string pips_owner, const string pips_func, const string pips_file, const int pips_line, const string user_func, const string user_file, const int user_line, const int user_line2, const string stmt, const string suggestion, const string format, va_list *args) |
log entry with unprocessed format/alist arguments More... | |
void | pips_log_func (const string pips_func, const string pips_file, const int pips_line, const pips_log_t tag, const string pips_pass, const string pips_owner, const string user_func, const string user_file, const int user_line, const int user_line2, const string stmt, const string suggestion, const string format,...) |
direct pips_log call with format and free arguments ("...") More... | |
void | pips_log_stop (const char *function, const char *file, const int lineno, const pips_log_t tag, const int code, const string format,...) |
quick log and stop, called on timeout this must not invoke malloc as it may still held locks if interrupted this implementation is missing XML escapes... More... | |
int | safe_vasprintf (char **strp, const char *fmt, va_list args) |
int | safe_asprintf (char **strp, const char *fmt,...) |
Variables | |
static string | current_phase = NULL |
CATCH/TRY/UNCATCH/THROW stuff is here. More... | |
static string | current_module = NULL |
static string | pips_revisions = NULL |
static string | pips_date = NULL |
static string | pips_cc = NULL |
string(* | pips_request_handler )(const char *, va_list *) |
default assignment of pips_request_handler is default_user_request. More... | |
static FILE * | log_file = NULL |
The log file is closed by default. More... | |
void(* | pips_log_handler )(const char *fmt, va_list *args) = NULL |
USER_LOG is a function that should be called to log the current PIPS request, as soon as it is relevant. More... | |
static FILE * | warning_file = NULL |
static string | warning_file_name = NULL |
void(* | pips_warning_handler )(const char *, const char *, va_list *) = NULL |
default assignment of pips_warning_handler is default_user_warning. More... | |
void(* | pips_error_handler )(const char *, const char *, va_list *) = NULL |
PROMPT_USER schould be implemented. More... | |
void(* | pips_internal_error_handler )(const char *, const char *,...) = NULL |
PIPS_ERROR is a function that should be called to terminate PIPS execution when data structures are corrupted. More... | |
static FILE * | xml_logfile = NULL |
static string | xml_logfile_name = NULL |
static int | pips_log_recursion_count = 0 |
#define PIPS_THANKS_STRING | ( | arch | ) |
The # "stringificator" only works in a macro expansion...
#define WARNING_FILE_NAME "Warnings" |
void append_to_warning_file | ( | const char * | calling_function_name, |
const char * | format, | ||
va_list * | args | ||
) |
To be used in error handling functions.
calling_function_name | alling_function_name |
format | ormat |
args | rgs |
Definition at line 306 of file message.c.
References get_bool_property(), get_pips_current_module(), get_pips_current_pass_name(), pips_log_alist(), properties_initialized_p(), and warning_log.
|
static |
generate xml: attribute="escaped-stuff"
Definition at line 595 of file message.c.
References string_buffer_append(), and string_buffer_append_xml_text().
Referenced by open_xml_logfile(), pips_log_xml(), pips_log_xml_pips_level(), and pips_stop_xml().
|
static |
Definition at line 641 of file message.c.
References string_buffer_printf().
Referenced by pips_log_xml(), and pips_log_xml_pips_level().
void close_log_file | ( | void | ) |
Definition at line 162 of file message.c.
References get_bool_property(), log_file, and pips_internal_error.
Referenced by check_delete_workspace(), close_workspace(), create_workspace(), gpips_main(), open_log_file(), and wpips_main().
void close_warning_file | ( | void | ) |
Definition at line 293 of file message.c.
References free(), safe_fclose(), warning_file, and warning_file_name.
Referenced by check_delete_workspace(), close_workspace(), and create_workspace().
void close_xml_logfile | ( | void | ) |
Definition at line 631 of file message.c.
References safe_fclose(), xml_logfile, and xml_logfile_name.
Definition at line 759 of file message.c.
References TIMEOUT_CODE.
Referenced by pips_log_stop(), pips_stop_file(), and pips_stop_xml().
string default_user_request | ( | const char * | fmt, |
va_list * | args | ||
) |
USER_REQUEST is a function that should be called to request some data from the user.
It returns the string typed by the user until the return key is typed. USER_REQUEST should be called as:
USER_REQUEST(format [, arg] ... )
where format and arg-list are passed as arguments to vprintf.
fmt | mt |
args | rgs |
Definition at line 124 of file message.c.
References fprintf(), and safe_readline().
bool function_same_string_p | ( | const char * | s1, |
const char * | s2 | ||
) |
bool get_bool_property | ( | const | string | ) |
FC 2015-07-20: yuk, moved out to prevent an include cycle dependency include "properties.h".
Definition at line 173 of file gfc2pips-stubs.c.
Referenced by append_to_warning_file(), close_log_file(), open_log_file(), pips_log_end(), and pips_user_warning_alist().
int get_int_property | ( | const | string | ) |
Definition at line 191 of file gfc2pips-stubs.c.
References fprintf(), and STUB_ERROR.
Referenced by any_loop_to_points_to(), apply_a_rule(), copy_write_statement(), copy_write_statement_with_cumulated_regions(), create_common_parameters_h(), create_k_limited_stub_points_to(), do_kernelize(), do_solve_hardware_constraints_on_nb_proc(), do_solve_hardware_constraints_on_volume(), do_terapix_remove_divide(), freia_spoc_pipeline(), freia_terapix_call(), freia_unroll_while(), generate_opcode(), get_free_slot(), get_optimal_opcode(), get_output_slot(), hbdsc_parallelization(), if_conv_init_statement(), init_computation_intensity_param(), initialization(), internal_print_icfg(), loop_chunk_size_and_strip_mine(), make_eliminate_original_variables(), make_mpi_conversion(), match_expression(), maybe_unroll_while_rwt(), mppa_compile_dag(), mppa_dag_maybe_split_instrs_cmd(), mppa_dag_split(), new_any_loop_to_points_to(), normalize_points_to_graph(), offset_array_reference(), offset_points_to_cell(), pips_log_end(), pragma_build_if_condition(), reductions_rewrite(), reference_add_field_dimension(), replicate_declaration(), sc_delimiter(), simple_simd_unroll_rate(), spire_distributed_unstructured_to_structured(), spire_shared_unstructured_to_structured(), statement_to_postcondition(), statement_to_transformer(), statement_to_transformer_list(), terapix_gram_allocate(), terapix_gram_init(), text_complexity(), unroll(), unstructured_to_flow_sensitive_postconditions(), unstructured_to_transformer(), and whileloop_to_postcondition().
string get_pips_current_module | ( | void | ) |
Definition at line 82 of file message.c.
References current_module.
Referenced by append_to_warning_file(), c_parser_user_warning_alist(), csplit_parser_warning_alist(), pips_internal_error_alist(), pips_log_stop(), pips_stop_file(), pips_stop_xml(), pips_user_error_alist(), pips_user_irrecoverable_error_alist(), pips_user_warning_alist(), semantics_user_warning_alist(), and spear_log_alist().
string get_pips_current_pass_name | ( | void | ) |
Export this piece of information to customize warning functions in passes.
Passes are also called "phases" in PIPS jargon.
Definition at line 77 of file message.c.
References current_phase.
Referenced by append_to_warning_file(), c_parser_user_warning_alist(), csplit_parser_warning_alist(), pips_internal_error_alist(), pips_log_stop(), pips_stop_file(), pips_stop_xml(), pips_user_error_alist(), pips_user_irrecoverable_error_alist(), pips_user_warning_alist(), semantics_user_warning_alist(), and spear_log_alist().
char* get_string_property | ( | const char * | ) |
void log_on_file | ( | const char * | desc | ) |
desc | esc |
Definition at line 190 of file message.c.
References info_log, and pips_log_desc().
Referenced by gpips_user_error_message(), gpips_user_log(), gpips_user_warning_message(), wpips_user_error_message(), wpips_user_log(), and wpips_user_warning_message().
void open_log_file | ( | const string | dir | ) |
dir | ir |
Definition at line 171 of file message.c.
References close_log_file(), concatenate(), free(), get_bool_property(), LOG_FILE, log_file, pips_user_error, and strdup().
Referenced by create_workspace(), and open_workspace().
void open_warning_file | ( | const char * | dir | ) |
dir | ir |
Definition at line 286 of file message.c.
References assert, concatenate(), safe_fopen(), strdup(), warning_file, WARNING_FILE_NAME, and warning_file_name.
Referenced by create_workspace(), and open_workspace().
void open_xml_logfile | ( | const char * | filename | ) |
filename | ilename |
Definition at line 607 of file message.c.
References append_xml_attribute(), pips_cc, pips_date, pips_revisions, safe_fopen(), string_buffer_append(), string_buffer_free(), string_buffer_make(), string_buffer_to_file(), STRINGIFY, xml_logfile, and xml_logfile_name.
Referenced by parse_arguments().
|
static |
Definition at line 375 of file message.c.
References abort, get_pips_current_module(), get_pips_current_pass_name(), internal_error_log, and pips_log_alist().
Referenced by pips_internal_error_func(), and pips_internal_error_func2().
void pips_internal_error_func | ( | const char * | funcname, |
const char * | funcfile, | ||
const int | funcline, | ||
const char * | fmt, | ||
... | |||
) |
funcname | uncname |
funcfile | uncfile |
funcline | uncline |
fmt | mt |
Definition at line 394 of file message.c.
References pips_internal_error_alist().
void pips_internal_error_func2 | ( | const char * | format, |
... | |||
) |
format | ormat |
Definition at line 408 of file message.c.
References pips_internal_error_alist(), and pips_unknown_function.
void pips_log_alist | ( | const pips_log_t | tag, |
const string | pips_pass, | ||
const string | pips_owner, | ||
const string | pips_func, | ||
const string | pips_file, | ||
const int | pips_line, | ||
const string | user_func, | ||
const string | user_file, | ||
const int | user_line, | ||
const int | user_line2, | ||
const string | stmt, | ||
const string | suggestion, | ||
const string | format, | ||
va_list * | args | ||
) |
log entry with unprocessed format/alist arguments
pips_pass | ips_pass |
pips_owner | ips_owner |
pips_func | ips_func |
pips_file | ips_file |
pips_line | ips_line |
user_func | ser_func |
user_file | ser_file |
user_line | ser_line |
user_line2 | ser_line2 |
stmt | tmt |
suggestion | uggestion |
format | ormat |
args | rgs |
Definition at line 1200 of file message.c.
References free(), info_log, internal_error_log, pips_error_handler, pips_internal_error_handler, pips_log_display(), pips_log_end(), pips_log_handler, pips_log_in_progress(), pips_warning_handler, spear_warning_log, user_error_log, user_file, vasprintf(), and warning_log.
Referenced by append_to_warning_file(), c_parser_user_warning_alist(), csplit_parser_warning_alist(), pips_internal_error_alist(), pips_log_func(), pips_user_error_alist(), pips_user_irrecoverable_error_alist(), pips_user_log_alist(), pips_user_warning_alist(), semantics_user_warning_alist(), and spear_log_alist().
void pips_log_desc | ( | const pips_log_t | tag, |
const string | pips_pass, | ||
const string | pips_owner, | ||
const string | pips_func, | ||
const string | pips_file, | ||
const int | pips_line, | ||
const string | user_func, | ||
const string | user_file, | ||
const int | user_line, | ||
const int | user_line2, | ||
const string | stmt, | ||
const string | suggestion, | ||
const string | description | ||
) |
log entry with preprocessed format/arguments
pips_pass | ips_pass |
pips_owner | ips_owner |
pips_func | ips_func |
pips_file | ips_file |
pips_line | ips_line |
user_func | ser_func |
user_file | ser_file |
user_line | ser_line |
user_line2 | ser_line2 |
stmt | tmt |
suggestion | uggestion |
description | escription |
Definition at line 1173 of file message.c.
References pips_log_display(), pips_log_end(), pips_log_in_progress(), and user_file.
Referenced by log_on_file().
|
static |
manage "displaying" a log entry, on stderr, in files...
Definition at line 1040 of file message.c.
References info_log, log_file, pips_log_file(), pips_log_xml(), user_file, warning_file, warning_log, and xml_logfile.
Referenced by pips_log_alist(), and pips_log_desc().
|
static |
Definition at line 1109 of file message.c.
References pips_log_recursion_count.
Referenced by pips_log_end().
|
static |
end of log entry (nothing, exception, abort, exit...)
Definition at line 1116 of file message.c.
References get_bool_property(), get_int_property(), internal_error_log, irrecoverable_error_log, log_file, pips_log_done(), pips_stop, properties_initialized_p(), spear_error_log, spear_warning_log, THROW, too_many_property_errors_pending_p(), user_error_log, user_exception_error, warning_file, and xml_logfile.
Referenced by pips_log_alist(), and pips_log_desc().
|
static |
Definition at line 954 of file message.c.
References fprintf(), internal_error_log, out, pips_log_tag_name(), user_error_log, user_file, and warning_log.
Referenced by pips_log_display().
void pips_log_func | ( | const string | pips_func, |
const string | pips_file, | ||
const int | pips_line, | ||
const pips_log_t | tag, | ||
const string | pips_pass, | ||
const string | pips_owner, | ||
const string | user_func, | ||
const string | user_file, | ||
const int | user_line, | ||
const int | user_line2, | ||
const string | stmt, | ||
const string | suggestion, | ||
const string | format, | ||
... | |||
) |
direct pips_log call with format and free arguments ("...")
pips_func | ips_func |
pips_file | ips_file |
pips_line | ips_line |
pips_pass | ips_pass |
pips_owner | ips_owner |
user_func | ser_func |
user_file | ser_file |
user_line | ser_line |
user_line2 | ser_line2 |
stmt | tmt |
suggestion | uggestion |
format | ormat |
Definition at line 1286 of file message.c.
References pips_log_alist(), and user_file.
|
static |
Definition at line 1089 of file message.c.
References fprintf(), internal_error_log, pips_log_recursion_count, and pips_stop_func().
Referenced by pips_log_alist(), and pips_log_desc().
void pips_log_stop | ( | const char * | function, |
const char * | file, | ||
const int | lineno, | ||
const pips_log_t | tag, | ||
const int | code, | ||
const string | format, | ||
... | |||
) |
quick log and stop, called on timeout this must not invoke malloc as it may still held locks if interrupted this implementation is missing XML escapes...
function | unction |
file | ile |
lineno | ineno |
code | ode |
format | ormat |
Definition at line 1323 of file message.c.
References code2status(), exit, fprintf(), get_pips_current_module(), get_pips_current_pass_name(), module, pips_log_tag_name(), and xml_logfile.
Referenced by pips_timeout_callback().
string pips_log_tag_name | ( | pips_log_t | tag | ) |
Definition at line 938 of file message.c.
References info_log, internal_error_log, irrecoverable_error_log, none_log, spear_error_log, spear_warning_log, user_error_log, and warning_log.
Referenced by pips_log_file(), pips_log_stop(), pips_stop_file(), and pips_stop_xml().
|
static |
add a full log entry to the xml log file
Definition at line 701 of file message.c.
References append_xml_attribute(), append_xml_line_numbers(), assert, info_log, pips_log_xml_pips_level(), pips_log_xml_tag(), string_buffer_cat(), string_buffer_free(), string_buffer_make(), string_buffer_to_file(), user_file, and xml_logfile.
Referenced by pips_log_display().
|
static |
append pips-level stuff (function, file, line) to xml file
Definition at line 673 of file message.c.
References append_xml_attribute(), and append_xml_line_numbers().
Referenced by pips_log_xml(), and pips_stop_xml().
|
static |
Definition at line 657 of file message.c.
References abort, info_log, internal_error_log, irrecoverable_error_log, spear_error_log, spear_warning_log, user_error_log, and warning_log.
Referenced by pips_log_xml().
|
static |
Definition at line 883 of file message.c.
References free(), pips_stop_desc(), and vasprintf().
Referenced by pips_stop_func(), and pips_stop_func2().
|
static |
Definition at line 845 of file message.c.
References abort, exit, info_log, log_file, pips_stop_file(), pips_stop_xml(), warning_file, warning_log, and xml_logfile.
Referenced by pips_stop_alist().
|
static |
Definition at line 801 of file message.c.
References code2status(), fprintf(), get_pips_current_module(), get_pips_current_pass_name(), out, and pips_log_tag_name().
Referenced by pips_stop_desc().
void pips_stop_func | ( | const char * | pips_func, |
const char * | pips_file, | ||
const int | pips_line, | ||
pips_log_t | tag, | ||
int | code, | ||
const | string, | ||
... | |||
) |
expecititely declare "noreturn" functions...
because cproto generated headers seem to ignore attributes
pips_func | ips_func |
pips_file | ips_file |
pips_line | ips_line |
code | ode |
format | ormat |
Definition at line 904 of file message.c.
References pips_stop_alist().
Referenced by pips_log_in_progress().
void pips_stop_func2 | ( | pips_log_t | tag, |
int | code, | ||
const string | format, | ||
... | |||
) |
code | ode |
format | ormat |
Definition at line 924 of file message.c.
References pips_stop_alist().
|
static |
Definition at line 771 of file message.c.
References append_xml_attribute(), assert, code2status(), get_pips_current_module(), get_pips_current_pass_name(), pips_log_tag_name(), pips_log_xml_pips_level(), string_buffer_append(), string_buffer_free(), string_buffer_make(), string_buffer_printf(), string_buffer_to_file(), and xml_logfile.
Referenced by pips_stop_desc().
display pips thanks on startup, if it on a tty.
This file contains the main for wpips.
This file contains the main for tpips.
This file contains the main for pips.
This file contains the main for fpips.
name | ame |
path | ath |
Definition at line 265 of file message.c.
References fprintf(), PIPS_THANKS_STRING, and STRINGIFY.
Referenced by main().
|
static |
Definition at line 458 of file message.c.
References abort, get_pips_current_module(), get_pips_current_pass_name(), pips_log_alist(), and user_error_log.
Referenced by pips_user_error_func(), and pips_user_error_func2().
void pips_user_error_func | ( | const char * | func_name, |
const char * | funcfile, | ||
const int | funcline, | ||
const char * | format, | ||
... | |||
) |
func_name | unc_name |
funcfile | uncfile |
funcline | uncline |
format | ormat |
Definition at line 478 of file message.c.
References pips_user_error_alist().
void pips_user_error_func2 | ( | const char * | format, |
... | |||
) |
format | ormat |
Definition at line 492 of file message.c.
References pips_unknown_function, and pips_user_error_alist().
void pips_user_irrecoverable_error_alist | ( | const char * | func_name, |
const char * | funcfile, | ||
const int | funcline, | ||
const char * | format, | ||
va_list * | args | ||
) |
func_name | unc_name |
funcfile | uncfile |
funcline | uncline |
format | ormat |
args | rgs |
Definition at line 516 of file message.c.
References exit, get_pips_current_module(), get_pips_current_pass_name(), irrecoverable_error_log, and pips_log_alist().
Referenced by pips_user_irrecoverable_error_func(), and pips_user_irrecoverable_error_func2().
void pips_user_irrecoverable_error_func | ( | const char * | func_name, |
const char * | funcfile, | ||
const int | funcline, | ||
const char * | format, | ||
... | |||
) |
func_name | unc_name |
funcfile | uncfile |
funcline | uncline |
format | ormat |
Definition at line 535 of file message.c.
References pips_user_irrecoverable_error_alist().
void pips_user_irrecoverable_error_func2 | ( | const char * | format, |
... | |||
) |
format | ormat |
Definition at line 550 of file message.c.
References pips_user_irrecoverable_error_alist().
|
static |
Definition at line 218 of file message.c.
References info_log, and pips_log_alist().
Referenced by pips_user_log_func(), and user_log().
void pips_user_log_func | ( | const char * | format, |
... | |||
) |
format | ormat |
Definition at line 225 of file message.c.
References pips_user_log_alist().
void pips_user_warning_alist | ( | const char * | function_name, |
const char * | funcfile, | ||
const int | funcline, | ||
const char * | format, | ||
va_list * | args | ||
) |
function_name | unction_name |
funcfile | uncfile |
funcline | uncline |
format | ormat |
args | rgs |
Definition at line 328 of file message.c.
References get_bool_property(), get_pips_current_module(), get_pips_current_pass_name(), pips_log_alist(), properties_initialized_p(), and warning_log.
Referenced by pips_user_warning_func(), and pips_user_warning_func2().
void pips_user_warning_func | ( | const char * | calling_function_name, |
const char * | funcfile, | ||
const int | funcline, | ||
const char * | format, | ||
... | |||
) |
calling_function_name | alling_function_name |
funcfile | uncfile |
funcline | uncline |
format | ormat |
Definition at line 346 of file message.c.
References pips_user_warning_alist().
void pips_user_warning_func2 | ( | const char * | format, |
... | |||
) |
fallback version without a calling function name
format | ormat |
Definition at line 362 of file message.c.
References pips_unknown_function, and pips_user_warning_alist().
bool properties_initialized_p | ( | void | ) |
FC 2015-07-20: yuk, moved out to prevent an include cycle dependency include "properties.h".
Definition at line 206 of file gfc2pips-stubs.c.
References STUB_WARNING_MSG.
Referenced by append_to_warning_file(), pips_log_end(), pips_user_warning_alist(), and tpips_user_error().
void reset_pips_current_computation | ( | void | ) |
Definition at line 87 of file message.c.
References current_module, current_phase, free(), and pips_assert.
Referenced by create_workspace(), and reset_current_phase_context().
int safe_asprintf | ( | char ** | strp, |
const char * | fmt, | ||
... | |||
) |
strp | trp |
fmt | mt |
Definition at line 1408 of file message.c.
References safe_vasprintf().
int safe_vasprintf | ( | char ** | strp, |
const char * | fmt, | ||
va_list | args | ||
) |
strp | trp |
fmt | mt |
args | rgs |
Definition at line 1398 of file message.c.
References pips_assert, ret, and vasprintf().
Referenced by safe_asprintf().
void set_pips_current_computation | ( | const char * | rname, |
const char * | oname | ||
) |
message.c
rname | name |
oname | name |
Definition at line 65 of file message.c.
References current_module, current_phase, pips_assert, and strdup().
Referenced by create_workspace(), and set_current_phase_context().
void set_pips_meta_informations | ( | const char * | revs, |
const char * | date, | ||
const char * | comp | ||
) |
revs | evs |
date | ate |
comp | omp |
Definition at line 102 of file message.c.
References pips_cc, pips_date, and pips_revisions.
Referenced by atinit(), gpips_main(), pips_init(), pips_main(), tpips_main(), and wpips_main().
bool too_many_property_errors_pending_p | ( | void | ) |
Definition at line 203 of file gfc2pips-stubs.c.
References STUB_WARNING_MSG.
Referenced by pips_log_end().
void user_log | ( | const char * | format, |
... | |||
) |
format | ormat |
Definition at line 234 of file message.c.
References pips_user_log_alist().
Referenced by abc_with_allocation_size(), add_new_compilation_unit(), add_new_module_from_text(), alias_check(), apply_a_rule(), array_bound_check_instrumentation(), array_bound_check_interprocedural(), array_dfg(), atomizer(), bottom_up_abc_base_reference_implied_do(), bottom_up_abc_call(), bottom_up_abc_reference(), check_input_file_syntax(), checkpoint_workspace(), clean_up_sequences_rewrite(), continue_create_workspace_notify(), create_workspace(), db_close_module(), db_save_workspace(), delete_some_resources(), display_alias_check_statistics(), display_alias_propagation_statistics(), display_bottom_up_abc_statistics(), display_clean_up_sequences_statistics(), display_impact_alias_statistics(), display_interprocedural_abc_statistics(), display_top_down_abc_statistics(), display_unspaghettify_statistics(), display_used_before_set_statistics(), do_resource_usage_check(), end_directory_notify(), find_statements_interactively_walker(), formal_array_resizing_bottom_up(), full_unroll(), full_unroll_pragma(), get_view_file(), gpips_display_graph_file_display(), gpips_user_request(), impact_check(), initialize_and_verify_common_variable(), initialize_and_verify_local_variable(), interactive_hyperplane_direction(), interactive_partitioning_matrix(), interprocedural_abc_arrays(), interprocedural_abc_statement_rwt(), lazy_open_module(), LinkInstToCurrentBlock(), logs_off(), loop_chunk_size_and_strip_mine(), main(), make_close_workspace(), make_special_value(), NewStmt(), notify_hpfc_file_view(), open_module(), open_workspace(), open_workspace_notify(), options_select(), parse_arguments(), pips_main(), pips_signal_handler(), print_array_dfg(), print_bdt(), print_code_static_control(), print_plc(), process_user_file(), put_summary(), referencenodeclfilter(), reindexing(), safe_concurrent_apply(), safe_do_something(), safe_set_property(), select_a_module_by_default(), select_rule(), set_env_log_and_free(), single_assign(), static_controlize(), stmt_flt(), strip_mine(), SubstituteAlternateReturns(), text_comp_region(), text_region_no_action(), top_down_abc_array(), tp_system(), unroll(), update_options(), UpdateEntity(), wpips_display_graph_file_display(), wpips_interrupt_pipsmake(), and wpips_user_request().
|
static |
Definition at line 63 of file message.c.
Referenced by get_pips_current_module(), init_host_and_node_entities(), make_sensitivity_information(), reset_pips_current_computation(), and set_pips_current_computation().
|
static |
CATCH/TRY/UNCATCH/THROW stuff is here.
pips meta information from pipsmake are made available here... (current phase and module...)
Definition at line 62 of file message.c.
Referenced by get_pips_current_pass_name(), reset_pips_current_computation(), and set_pips_current_computation().
|
static |
The log file is closed by default.
Definition at line 159 of file message.c.
Referenced by close_log_file(), open_log_file(), pips_log_display(), pips_log_end(), and pips_stop_desc().
|
static |
Definition at line 100 of file message.c.
Referenced by open_xml_logfile(), and set_pips_meta_informations().
|
static |
Definition at line 99 of file message.c.
Referenced by open_xml_logfile(), and set_pips_meta_informations().
void(* pips_error_handler) (const char *, const char *, va_list *) | ( | const char * | , |
const char * | , | ||
va_list * | |||
) | = NULL |
PROMPT_USER schould be implemented.
(its a warning with consent of the user) The question is: how schould it be called? USER_ERROR is a function that should be called to terminate the current PIPS request execution or to restore the previous saved stack environment when an error in a Fortran file or elsewhere is detected. USER_ERROR first prints on stderr a description of the error, then tests the property ABORT_ON_USER_ERROR and aborts case true. Else it will restore the last saved stack environment (ie. come back to the last executed setjmp(pips_top_level) ), except for eventuality it has already been called. In this case, it terminates execution with exit. USER_ERROR should be called as:
USER_ERROR(fonction, format [, arg] ... )
where function is a string containing the name of the function calling USER_ERROR, and where format and arg-list are passed as arguments to vprintf.
Modifications:
Definition at line 455 of file message.c.
Referenced by atinit(), gpips_main(), pips_log_alist(), tpips_init(), and wpips_main().
void(* pips_internal_error_handler) (const char *, const char *,...) | ( | const char * | , |
const char * | , | ||
... | |||
) | = NULL |
PIPS_ERROR is a function that should be called to terminate PIPS execution when data structures are corrupted.
PIPS_ERROR should be called as: PIPS_ERROR(fonction, format [, arg] ... ) where function is a string containing the name of the function calling PIPS_ERROR, and where format and arg-list are passed as arguments to vprintf. PIPS_ERROR terminates execution with abort.
Definition at line 511 of file message.c.
Referenced by pips_log_alist(), and tpips_init().
void(* pips_log_handler) (const char *fmt, va_list *args) | ( | const char * | fmt, |
va_list * | args | ||
) | = NULL |
USER_LOG is a function that should be called to log the current PIPS request, as soon as it is relevant.
loging will occure if property USER_LOG_P is TRUE. USER_LOG should be called as:
USER_LOG(format [, arg] ... )
where format and arg-list are passed as arguments to vprintf. default assignment of pips_log_handler is default_user_log. Some top-level (eg. wpips) may need a special user_log proceedure; they should let pips_log_handler point toward it.
Every procedure pointed to by pips_log_handler must test the property USER_LOG_P; this is necessary because (* pips_log_handler) may be called anywhere (because VARARGS), whithout verifying it.
Definition at line 216 of file message.c.
Referenced by atinit(), gpips_main(), pips_log_alist(), and wpips_main().
|
static |
Definition at line 1087 of file message.c.
Referenced by pips_log_done(), and pips_log_in_progress().
|
default |
default assignment of pips_request_handler is default_user_request.
Some top-level (eg. wpips) may need a special user_request proceedure; they should let pips_request_handler point toward it.
Definition at line 139 of file message.c.
Referenced by gpips_main(), tpips_init(), and wpips_main().
|
static |
Definition at line 98 of file message.c.
Referenced by open_xml_logfile(), and set_pips_meta_informations().
void(* pips_warning_handler) (const char *, const char *, va_list *) | ( | const char * | , |
const char * | , | ||
va_list * | |||
) | = NULL |
default assignment of pips_warning_handler is default_user_warning.
Some top-level (eg. wpips) may need a special user_warning proceedure; they should let pips_warning_handler point toward it.
Definition at line 325 of file message.c.
Referenced by gpips_main(), pips_log_alist(), and wpips_main().
|
static |
Definition at line 283 of file message.c.
Referenced by close_warning_file(), open_warning_file(), pips_log_display(), pips_log_end(), and pips_stop_desc().
|
static |
Definition at line 284 of file message.c.
Referenced by close_warning_file(), and open_warning_file().
|
static |
Definition at line 567 of file message.c.
Referenced by close_xml_logfile(), open_xml_logfile(), pips_log_display(), pips_log_end(), pips_log_stop(), pips_log_xml(), pips_stop_desc(), and pips_stop_xml().
|
static |
Definition at line 568 of file message.c.
Referenced by close_xml_logfile(), and open_xml_logfile().