include src/xbt/xbt_log_layout_format.cpp
include src/xbt/xbt_log_layout_simple.cpp
include src/xbt/xbt_main.cpp
-include src/xbt/xbt_modinter.h
include src/xbt/xbt_os_file.cpp
include src/xbt/xbt_os_time.c
include src/xbt/xbt_parse_units.cpp
#include "src/simgrid/math_utils.h"
#include "src/simgrid/sg_config.hpp"
#include "src/smpi/include/smpi_actor.hpp"
-#include "src/xbt/xbt_modinter.h" /* whether initialization was already done */
#include "xbt/log.hpp"
static simgrid::config::Flag<bool> cfg_dbg_clean_atexit{
"debug/clean-atexit", "Whether to cleanup SimGrid at exit. Disable it if your code segfaults after its end.", true};
-static void xbt_postexit()
-{
- if (not cfg_dbg_clean_atexit)
- return;
- xbt_log_postexit();
-}
namespace simgrid::kernel {
static bool inited = false;
if (not inited) {
inited = true;
- atexit(xbt_postexit);
xbt_log_init(argc, argv);
simgrid::xbt::install_exception_handler();
#include "simgrid/Exception.hpp"
#include "src/internal_config.h" /* loads context system definitions */
#include "src/kernel/EngineImpl.hpp"
-#include "src/xbt/xbt_modinter.h" /* prototype of os thread module's init/exit in XBT */
#include "xbt/function_types.h"
#include <boost/core/demangle.hpp>
#include "xbt/dict.h"
#include "dict_private.h"
#include "simgrid/Exception.hpp"
-#include "src/xbt/xbt_modinter.h"
#include "xbt/ex.h"
#include "xbt/log.h"
#include "xbt/mallocator.h"
* under the terms of the license (GNU LGPL) which comes with this package. */
#include "src/xbt/log_private.hpp"
-#include "src/xbt/xbt_modinter.h"
#include "xbt/string.hpp"
#include "xbt/sysdep.h"
static void xbt_log_help();
static void xbt_log_help_categories();
+static void xbt_log_postexit();
void xbt_log_init(int *argc, char **argv)
{
int parse_args = 1; // Stop parsing the parameters once we found '--'
xbt_log_control_set("xbt_help.app:stdout xbt_help.threshold:VERBOSE xbt_help.fmt:%m%n");
+ atexit(xbt_log_postexit);
/* Set logs and init log submodule */
for (int i = 1; i < *argc; i++) {
log_cat_exit(child);
}
-void xbt_log_postexit(void)
+static void xbt_log_postexit(void)
{
XBT_VERB("Exiting log");
log_cat_exit(&_XBT_LOGV(XBT_LOG_ROOT_CAT));
#include "src/simgrid/sg_config.hpp"
#include "src/sthread/sthread.h" // sthread_inside_simgrid
#include "src/xbt/coverage.h"
-#include "src/xbt/xbt_modinter.h" /* prototype of other module's init/exit in XBT */
#include "xbt/config.hpp"
#include "xbt/dynar.h"
#include "xbt/log.h"
+++ /dev/null
-/* xbt_modinter - How to init/exit the XBT modules */
-
-/* Copyright (c) 2004-2023. The SimGrid Team. All rights reserved. */
-
-/* This program is free software; you can redistribute it and/or modify it
- * under the terms of the license (GNU LGPL) which comes with this package. */
-
-#ifndef XBT_MODINTER_H
-#define XBT_MODINTER_H
-#include "xbt/misc.h"
-
-SG_BEGIN_DECL
-
-/* Modules definitions */
-
-void xbt_log_postexit(void);
-
-SG_END_DECL
-
-#endif
src/xbt/log_private.hpp
src/xbt/mallocator_private.h
src/xbt/parmap.hpp
- src/xbt/xbt_modinter.h
src/xbt/mmalloc/mmalloc.h
src/xbt/mmalloc/mfree.c