~ForcefulKillException();
const char* what() const noexcept { return msg_.c_str(); }
- static void do_throw();
+ XBT_ATTRIB_NORETURN static void do_throw();
static bool try_n_catch(const std::function<void()>& try_block);
private:
void handle_events(int fd, short events);
void wait_for_requests();
void handle_simcall(Transition const& transition);
- void exit(int status);
+ XBT_ATTRIB_NORETURN void exit(int status);
bool checkDeadlock();
public:
Channel const& getChannel() const { return channel_; }
Channel& getChannel() { return channel_; }
- void mainLoop();
+ XBT_ATTRIB_NORETURN void mainLoop();
void reportAssertionFailure();
void ignoreMemory(void* addr, std::size_t size);
void ignoreHeap(void* addr, std::size_t size);
void (*SMPI_switch_data_segment)(simgrid::s4u::ActorPtr) = nullptr;
bool _sg_do_verbose_exit = true;
-static void inthandler(int)
+XBT_ATTRIB_NORETURN static void inthandler(int)
{
if ( _sg_do_verbose_exit ) {
XBT_INFO("CTRL-C pressed. The current status will be displayed before exit (disable that behavior with option 'verbose-exit').");
#include "mc/mc.h"
#include "simgrid/s4u/Engine.hpp"
#include "simgrid/sg_config.hpp"
-#include "src/internal_config.h"
#include "src/simgrid/version.h"
#include "src/surf/HostImpl.hpp"
#include "src/surf/xml/platf.hpp"
#ifndef SURF_MODEL_H_
#define SURF_MODEL_H_
+#include "src/internal_config.h"
#include "src/surf/surf_private.hpp"
#include <cmath>
*
* @see surf_host_model_init_SMPI()
*/
+#if !HAVE_SMPI
+XBT_ATTRIB_NORETURN
+#endif
XBT_PUBLIC void surf_network_model_init_SMPI();
/** @ingroup SURF_models
*
* @see surf_host_model_init_IB()
*/
+#if !HAVE_SMPI
+XBT_ATTRIB_NORETURN
+#endif
XBT_PUBLIC void surf_network_model_init_IB();
/** @ingroup SURF_models
*
* @see surf_host_model_init_NS3()
*/
+#if !SIMGRID_HAVE_NS3
+XBT_ATTRIB_NORETURN
+#endif
XBT_PUBLIC void surf_network_model_init_NS3();
/** @ingroup SURF_models
XBT_PUBLIC void ETag_surfxml_host(void);
XBT_PUBLIC void STag_surfxml_host___link(void);
XBT_PUBLIC void ETag_surfxml_host___link(void);
-XBT_PUBLIC void STag_surfxml_include(void);
+XBT_ATTRIB_NORETURN XBT_PUBLIC void STag_surfxml_include(void);
XBT_PUBLIC void ETag_surfxml_include(void);
XBT_PUBLIC void STag_surfxml_link(void);
XBT_PUBLIC void ETag_surfxml_link(void);
XBT_LOG_NEW_DEFAULT_CATEGORY(s4u_test, "Messages specific for this s4u example");
-static void usage(const char* binaryName, const char* defaultSend, const char* defaultRecv)
+XBT_ATTRIB_NORETURN static void usage(const char* binaryName, const char* defaultSend, const char* defaultRecv)
{
std::fprintf(stderr, "Usage: %s examples/platforms/cluster_backbone.xml <send_spec> <recv_spec>\n"
"where spec is a list of letters giving the kind of tests you want to see.\n"
set(string1 "'s/extern /XBT_PUBLIC_DATA /'")
set(string2 "'s/XBT_PUBLIC_DATA \\([^(]*\\)(/XBT_PUBLIC \\1(/'")
+ set(string3 "'s/XBT_PUBLIC void STag_surfxml_include/XBT_ATTRIB_NORETURN &/'") # remove with v5 of the dtd
set(string5 "'s/SET(DOCTYPE)/SET(ROOT_dax__adag)/'")
set(string9 "'s/#include <unistd.h>/#if defined(_WIN32)\\n# ifndef __STRICT_ANSI__\\n# include <io.h>\\n# include <process.h>\\n# endif\\n#else\\n# include <unistd.h>\\n#endif/g'")
set(string14 "'\\!^ \\* Generated [0-9/]\\{10\\} [0-9:]\\{8\\}\\.$$!d'")
COMMAND ${FLEXML_EXE} --root-tags platform -P surfxml --sysid=https://simgrid.org/simgrid.dtd -H src/surf/xml/simgrid_dtd.h -L src/surf/xml/simgrid.dtd
COMMAND ${SED_EXE} -i ${string1} src/surf/xml/simgrid_dtd.h
COMMAND ${SED_EXE} -i ${string2} src/surf/xml/simgrid_dtd.h
+ COMMAND ${SED_EXE} -i ${string3} src/surf/xml/simgrid_dtd.h
COMMAND ${SED_EXE} -i ${string14} src/surf/xml/simgrid_dtd.h
COMMAND ${CMAKE_COMMAND} -E echo " Generated src/surf/xml/simgrid_dtd.h"