From: mquinson Date: Thu, 6 Mar 2008 13:23:40 +0000 (+0000) Subject: Connect correctly the log channels manually for windows. I didn't try to compile... X-Git-Tag: v3.3~604 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/682eb8ce658cd1cafc772d2f62b6fb9430471b81 Connect correctly the log channels manually for windows. I didn't try to compile last commit, sorry for the noise git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@5272 48e7efb5-ca39-0410-a469-dd3cf9ba447f --- diff --git a/src/amok/base.c b/src/amok/base.c index 07fcc40230..5c80c5dc4e 100644 --- a/src/amok/base.c +++ b/src/amok/base.c @@ -11,6 +11,9 @@ #include "amok/base.h" XBT_LOG_NEW_SUBCATEGORY(amok,XBT_LOG_ROOT_CAT,"All AMOK categories"); +XBT_LOG_EXTERNAL_CATEGORY(amok_bw); +XBT_LOG_EXTERNAL_CATEGORY(amok_bw_sat); +XBT_LOG_EXTERNAL_CATEGORY(amok_pm); void amok_base_init(void) { gras_datadesc_type_t host_desc; diff --git a/src/gras/Virtu/sg_process.c b/src/gras/Virtu/sg_process.c index 36c5eadf62..b37d2baf75 100644 --- a/src/gras/Virtu/sg_process.c +++ b/src/gras/Virtu/sg_process.c @@ -190,16 +190,22 @@ xbt_dict_t gras_os_host_properties(void) { /* ************************************************************************** * Interface with SIMIX + * (these functions are called by the stuff generated by gras_stub_generator) * **************************************************************************/ +XBT_LOG_EXTERNAL_CATEGORY(gras_trp); +XBT_LOG_EXTERNAL_CATEGORY(gras_trp_sg); + void gras_global_init(int *argc,char **argv) { - SIMIX_global_init(argc,argv); + XBT_LOG_CONNECT(gras_trp_sg, gras_trp); + SIMIX_global_init(argc,argv); } + void gras_create_environment(const char *file) { - SIMIX_create_environment(file); + SIMIX_create_environment(file); } void gras_function_register(const char *name, xbt_main_func_t code) { - SIMIX_function_register(name, code); + SIMIX_function_register(name, code); } void gras_main() { diff --git a/src/gras/gras.c b/src/gras/gras.c index 7bf58273ca..d28fdc2ddb 100644 --- a/src/gras/gras.c +++ b/src/gras/gras.c @@ -46,6 +46,24 @@ static void gras_sigint_handler(int sig) { } #endif +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt); +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt_cbps); +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt_convert); +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt_create); +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt_exchange); +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt_lexer); +XBT_LOG_EXTERNAL_CATEGORY(gras_ddt_parse); +XBT_LOG_EXTERNAL_CATEGORY(gras_modules); +XBT_LOG_EXTERNAL_CATEGORY(gras_msg); +XBT_LOG_EXTERNAL_CATEGORY(gras_msg_read); +XBT_LOG_EXTERNAL_CATEGORY(gras_msg_rpc); +XBT_LOG_EXTERNAL_CATEGORY(gras_timer); +XBT_LOG_EXTERNAL_CATEGORY(gras_trp); +XBT_LOG_EXTERNAL_CATEGORY(gras_trp_meas); +XBT_LOG_EXTERNAL_CATEGORY(gras_virtu); +XBT_LOG_EXTERNAL_CATEGORY(gras_virtu_emul); +XBT_LOG_EXTERNAL_CATEGORY(gras_virtu_process); + void gras_init(int *argc,char **argv) { gras_procdata_t *pd; @@ -78,10 +96,7 @@ void gras_init(int *argc,char **argv) { XBT_LOG_CONNECT(gras_timer, gras); XBT_LOG_CONNECT(gras_trp, gras); - XBT_LOG_CONNECT(gras_trp_file, gras_trp); XBT_LOG_CONNECT(gras_trp_meas, gras_trp); - XBT_LOG_CONNECT(gras_trp_sg, gras_trp); - XBT_LOG_CONNECT(gras_trp_tcp, gras_trp); XBT_LOG_CONNECT(gras_virtu, gras); XBT_LOG_CONNECT(gras_virtu_emul, gras_virtu); diff --git a/src/gras/rl_stubs.c b/src/gras/rl_stubs.c index 526b8a9ac6..6123585100 100644 --- a/src/gras/rl_stubs.c +++ b/src/gras/rl_stubs.c @@ -11,6 +11,16 @@ #include "xbt_modinter.h" #include "xbt/sysdep.h" -void xbt_context_mod_init(void) {} +XBT_LOG_EXTERNAL_CATEGORY(xbt); +XBT_LOG_EXTERNAL_CATEGORY(xbt_sync_rl); +XBT_LOG_EXTERNAL_CATEGORY(gras_trp); +XBT_LOG_EXTERNAL_CATEGORY(gras_trp_file); +XBT_LOG_EXTERNAL_CATEGORY(gras_trp_tcp); + +void xbt_context_mod_init(void) { + XBT_LOG_CONNECT(xbt_sync_rl, xbt); + XBT_LOG_CONNECT(gras_trp_file, gras_trp); + XBT_LOG_CONNECT(gras_trp_tcp, gras_trp); +} void xbt_context_mod_exit(void) {} diff --git a/src/msg/global.c b/src/msg/global.c index 565788c91d..42dba8bfa2 100644 --- a/src/msg/global.c +++ b/src/msg/global.c @@ -39,6 +39,12 @@ void MSG_global_init_args(int *argc, char **argv) MSG_global_init(argc, argv); } + +XBT_LOG_EXTERNAL_CATEGORY(msg_gos); +XBT_LOG_EXTERNAL_CATEGORY(msg_kernel); +XBT_LOG_EXTERNAL_CATEGORY(msg_mailbox); +XBT_LOG_EXTERNAL_CATEGORY(msg_process); + /** \ingroup msg_simulation * \brief Initialize some MSG internal data. */ diff --git a/src/simdag/sd_global.c b/src/simdag/sd_global.c index 27e445f363..b6aaf1ebef 100644 --- a/src/simdag/sd_global.c +++ b/src/simdag/sd_global.c @@ -66,6 +66,10 @@ static void _sd_cfg_cb__network_model(const char *name, int pos) surf_network_model_description_size, val); } +XBT_LOG_EXTERNAL_CATEGORY(sd_kernel); +XBT_LOG_EXTERNAL_CATEGORY(sd_task); +XBT_LOG_EXTERNAL_CATEGORY(sd_workstation); + /* create the config set and register what should be */ static void sd_config_init(void) { diff --git a/src/simix/smx_config.c b/src/simix/smx_config.c index 77d690fb10..51837d126b 100644 --- a/src/simix/smx_config.c +++ b/src/simix/smx_config.c @@ -59,6 +59,15 @@ static void _simix_cfg_cb__network_model(const char *name, int pos) surf_network_model_description_size, val); } +XBT_LOG_EXTERNAL_CATEGORY(simix); +XBT_LOG_EXTERNAL_CATEGORY(simix_action); +XBT_LOG_EXTERNAL_CATEGORY(simix_deployment); +XBT_LOG_EXTERNAL_CATEGORY(simix_environment); +XBT_LOG_EXTERNAL_CATEGORY(simix_host); +XBT_LOG_EXTERNAL_CATEGORY(simix_kernel); +XBT_LOG_EXTERNAL_CATEGORY(simix_process); +XBT_LOG_EXTERNAL_CATEGORY(simix_synchro); + /* create the config set and register what should be */ void simix_config_init(void) { diff --git a/src/smpi/smpi_base.c b/src/smpi/smpi_base.c index c119790d33..006d60afb2 100644 --- a/src/smpi/smpi_base.c +++ b/src/smpi/smpi_base.c @@ -1,6 +1,13 @@ #include "private.h" XBT_LOG_NEW_DEFAULT_SUBCATEGORY(smpi_base, smpi, "Logging specific to SMPI (base)"); +XBT_LOG_EXTERNAL_CATEGORY(smpi_base); +XBT_LOG_EXTERNAL_CATEGORY(smpi_bench); +XBT_LOG_EXTERNAL_CATEGORY(smpi_kernel); +XBT_LOG_EXTERNAL_CATEGORY(smpi_mpi); +XBT_LOG_EXTERNAL_CATEGORY(smpi_receiver); +XBT_LOG_EXTERNAL_CATEGORY(smpi_sender); +XBT_LOG_EXTERNAL_CATEGORY(smpi_util); smpi_mpi_global_t smpi_mpi_global = NULL; diff --git a/src/surf/surf.c b/src/surf/surf.c index b46ade33ab..2f7957df2e 100644 --- a/src/surf/surf.c +++ b/src/surf/surf.c @@ -300,6 +300,24 @@ void surf_action_set_data(surf_action_t action, void *data) action->data = data; } +XBT_LOG_EXTERNAL_CATEGORY(surf_cpu); +XBT_LOG_EXTERNAL_CATEGORY(surf_kernel); +XBT_LOG_EXTERNAL_CATEGORY(surf_lagrange); +XBT_LOG_EXTERNAL_CATEGORY(surf_lagrange_dichotomy); +XBT_LOG_EXTERNAL_CATEGORY(surf_maxmin); +XBT_LOG_EXTERNAL_CATEGORY(surf_network); +XBT_LOG_EXTERNAL_CATEGORY(surf_parse); +XBT_LOG_EXTERNAL_CATEGORY(surf_timer); +XBT_LOG_EXTERNAL_CATEGORY(surf_workstation); + +#ifdef HAVE_SDP + XBT_LOG_EXTERNAL_CATEGORY(surf_sdp_out); + XBT_LOG_EXTERNAL_CATEGORY(surf_sdp); +#endif +#ifdef HAVE_GTNETS + XBT_LOG_EXTERNAL_CATEGORY(surf_network_gtnets); +#endif + void surf_init(int *argc, char **argv) { int i, j; @@ -310,16 +328,21 @@ void surf_init(int *argc, char **argv) /* Connect our log channels: that must be done manually under windows */ XBT_LOG_CONNECT(surf_cpu, surf); XBT_LOG_CONNECT(surf_kernel, surf); - XBT_LOG_CONNECT(surf_lagrange_dichotomy, surf_lagrange); XBT_LOG_CONNECT(surf_lagrange, surf); + XBT_LOG_CONNECT(surf_lagrange_dichotomy, surf_lagrange); XBT_LOG_CONNECT(surf_maxmin, surf); - XBT_LOG_CONNECT(surf_network_gtnets, surf); XBT_LOG_CONNECT(surf_network, surf); XBT_LOG_CONNECT(surf_parse, surf); - XBT_LOG_CONNECT(surf_sdp_out, surf); - XBT_LOG_CONNECT(surf_sdp, surf); XBT_LOG_CONNECT(surf_timer, surf); XBT_LOG_CONNECT(surf_workstation, surf); + +#ifdef HAVE_SDP + XBT_LOG_CONNECT(surf_sdp_out, surf); + XBT_LOG_CONNECT(surf_sdp, surf); +#endif +#ifdef HAVE_GTNETS + XBT_LOG_CONNECT(surf_network_gtnets, surf); +#endif xbt_init(argc, argv); if (!surf_path) { diff --git a/src/xbt/xbt_main.c b/src/xbt/xbt_main.c index 00de65f09e..4d3c1d6604 100644 --- a/src/xbt/xbt_main.c +++ b/src/xbt/xbt_main.c @@ -23,6 +23,29 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY(module,xbt, "module handling"); char *xbt_binary_name=NULL; /* Mandatory to retrieve neat backtraces */ int xbt_initialized=0; +XBT_LOG_EXTERNAL_CATEGORY(graphxml_parse); +XBT_LOG_EXTERNAL_CATEGORY(log); +XBT_LOG_EXTERNAL_CATEGORY(module); +XBT_LOG_EXTERNAL_CATEGORY(peer); +XBT_LOG_EXTERNAL_CATEGORY(strbuff); +XBT_LOG_EXTERNAL_CATEGORY(xbt_cfg); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_add); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_collapse); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_cursor); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_elm); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_multi); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_remove); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dict_search); +XBT_LOG_EXTERNAL_CATEGORY(xbt_dyn); +XBT_LOG_EXTERNAL_CATEGORY(xbt_ex); +XBT_LOG_EXTERNAL_CATEGORY(xbt_fifo); +XBT_LOG_EXTERNAL_CATEGORY(xbt_graph); +XBT_LOG_EXTERNAL_CATEGORY(xbt_matrix); +XBT_LOG_EXTERNAL_CATEGORY(xbt_queue); +XBT_LOG_EXTERNAL_CATEGORY(xbt_set); +XBT_LOG_EXTERNAL_CATEGORY(xbt_sync_os); + /** @brief Initialize the xbt mechanisms. */ void xbt_init(int *argc, char **argv) { @@ -38,14 +61,14 @@ xbt_init(int *argc, char **argv) { XBT_LOG_CONNECT(peer, xbt); XBT_LOG_CONNECT(strbuff, xbt); XBT_LOG_CONNECT(xbt_cfg, xbt); - XBT_LOG_CONNECT(xbt_dict_add, xbt_dict); - XBT_LOG_CONNECT(xbt_dict_collapse, xbt_dict); - XBT_LOG_CONNECT(xbt_dict_cursor, xbt_dict); - XBT_LOG_CONNECT(xbt_dict_elm, xbt_dict); - XBT_LOG_CONNECT(xbt_dict_multi, xbt_dict); - XBT_LOG_CONNECT(xbt_dict_remove, xbt_dict); - XBT_LOG_CONNECT(xbt_dict_search, xbt_dict); XBT_LOG_CONNECT(xbt_dict, xbt); + XBT_LOG_CONNECT(xbt_dict_add, xbt_dict); + XBT_LOG_CONNECT(xbt_dict_collapse, xbt_dict); + XBT_LOG_CONNECT(xbt_dict_cursor, xbt_dict); + XBT_LOG_CONNECT(xbt_dict_elm, xbt_dict); + XBT_LOG_CONNECT(xbt_dict_multi, xbt_dict); + XBT_LOG_CONNECT(xbt_dict_remove, xbt_dict); + XBT_LOG_CONNECT(xbt_dict_search, xbt_dict); XBT_LOG_CONNECT(xbt_dyn, xbt); XBT_LOG_CONNECT(xbt_ex, xbt); XBT_LOG_CONNECT(xbt_fifo, xbt); @@ -54,7 +77,6 @@ xbt_init(int *argc, char **argv) { XBT_LOG_CONNECT(xbt_queue, xbt); XBT_LOG_CONNECT(xbt_set, xbt); XBT_LOG_CONNECT(xbt_sync_os, xbt); - XBT_LOG_CONNECT(xbt_sync_rl, xbt); xbt_binary_name = xbt_strdup(argv[0]); srand((unsigned int)time(NULL));