Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add new entry in Release_Notes.
[simgrid.git] / src / kernel / resource / profile / Event.hpp
1 /* Copyright (c) 2004-2023. The SimGrid Team. All rights reserved.          */
2
3 /* This program is free software; you can redistribute it and/or modify it
4  * under the terms of the license (GNU LGPL) which comes with this package. */
5
6 #ifndef SIMGRID_KERNEL_PROFILE_EVENT_HPP
7 #define SIMGRID_KERNEL_PROFILE_EVENT_HPP
8
9 #include "simgrid/forward.h"
10
11 namespace simgrid::kernel::profile {
12
13 class Event {
14 public:
15   Profile* profile;
16   unsigned int idx;
17   resource::Resource* resource;
18   bool free_me;
19 };
20 } // namespace simgrid::kernel::profile
21 /**
22  * @brief Free a trace event structure
23  *
24  * This function frees a trace_event if it can be freed, ie, if it has the free_me flag set to 1.
25  * This flag indicates whether the structure is still used somewhere or not.
26  * When the structure is freed, the argument is set to nullptr
27  */
28 XBT_PUBLIC void tmgr_trace_event_unref(simgrid::kernel::profile::Event** trace_event);
29
30 #endif // SIMGRID_KERNEL_PROFILE_EVENT_HPP