A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
improve doc to avoid mixture between Comm::set_src_data_size() and Activity::set_rema...
[simgrid.git]
/
include
/
simgrid
/
s4u
/
Storage.hpp
diff --git
a/include/simgrid/s4u/Storage.hpp
b/include/simgrid/s4u/Storage.hpp
index
1b1bb5d
..
2f5f89d
100644
(file)
--- a/
include/simgrid/s4u/Storage.hpp
+++ b/
include/simgrid/s4u/Storage.hpp
@@
-7,6
+7,7
@@
#define INCLUDE_SIMGRID_S4U_STORAGE_HPP_
#include <simgrid/forward.h>
#define INCLUDE_SIMGRID_S4U_STORAGE_HPP_
#include <simgrid/forward.h>
+#include <simgrid/s4u/Io.hpp>
#include <xbt/Extendable.hpp>
#include <xbt/base.h>
#include <xbt/signal.hpp>
#include <xbt/Extendable.hpp>
#include <xbt/base.h>
#include <xbt/signal.hpp>
@@
-16,17
+17,22
@@
#include <unordered_map>
namespace simgrid {
#include <unordered_map>
namespace simgrid {
-namespace xbt {
-extern template class XBT_PUBLIC Extendable<simgrid::s4u::Storage>;
-}
namespace s4u {
namespace s4u {
+#ifndef DOXYGEN
/** @deprecated Engine::get_all_storages() */
XBT_ATTRIB_DEPRECATED_v322("Please use Engine::get_all_storages()") XBT_PUBLIC void getStorageList(std::map<std::string, Storage*>* whereTo);
/** @deprecated Engine::get_all_storages() */
XBT_ATTRIB_DEPRECATED_v322("Please use Engine::get_all_storages()") XBT_PUBLIC void getStorageList(std::map<std::string, Storage*>* whereTo);
+#endif
+
+/** Storage represent the disk resources, usually associated to a given host
+ *
+ * By default, SimGrid does not keep track of the actual data being written but
+ * only computes the time taken by the corresponding data movement.
+ */
class XBT_PUBLIC Storage : public simgrid::xbt::Extendable<Storage> {
class XBT_PUBLIC Storage : public simgrid::xbt::Extendable<Storage> {
- friend s4u::Engine;
- friend s4u::Io;
+ friend s
imgrid::s
4u::Engine;
+ friend s
imgrid::s
4u::Io;
friend simgrid::surf::StorageImpl;
public:
friend simgrid::surf::StorageImpl;
public:
@@
-62,9
+68,12
@@
public:
void set_data(void* data) { userdata_ = data; }
void* get_data() { return userdata_; }
void set_data(void* data) { userdata_ = data; }
void* get_data() { return userdata_; }
- IoPtr io_init(sg_size_t size);
+ IoPtr io_init(sg_size_t size
, s4u::Io::OpType type
);
+ IoPtr read_async(sg_size_t size);
sg_size_t read(sg_size_t size);
sg_size_t read(sg_size_t size);
+
+ IoPtr write_async(sg_size_t size);
sg_size_t write(sg_size_t size);
surf::StorageImpl* get_impl() { return pimpl_; }
sg_size_t write(sg_size_t size);
surf::StorageImpl* get_impl() { return pimpl_; }