]> AND Public Git Repository - simgrid.git/blobdiff - include/simgrid/s4u/Disk.hpp
Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Reorganize VM code
[simgrid.git] / include / simgrid / s4u / Disk.hpp
index 6d8e00dcae6106f8171e2f628d47f0bb0411a71c..736476367ef8901c5602ef2e381031df68477739 100644 (file)
@@ -84,9 +84,11 @@ public:
 
   IoPtr read_async(sg_size_t size) const;
   sg_size_t read(sg_size_t size) const;
+  sg_size_t read(sg_size_t size, double priority) const;
 
   IoPtr write_async(sg_size_t size) const;
   sg_size_t write(sg_size_t size) const;
+  sg_size_t write(sg_size_t size, double priority) const;
 
   /** @brief Policy for sharing the disk among activities */
   enum class SharingPolicy { NONLINEAR = 1, LINEAR = 0 };
@@ -95,12 +97,13 @@ public:
   /**
    * @brief Describes how the disk is shared between activities for each operation
    *
-   * Disks have different bandwidths for read and write operations. This method
-   * allows you to set different sharing policies for each operation:
+   * Disks have different bandwidths for read and write operations, that can have different policies:
    * - Read: resource sharing for read operation
    * - Write: resource sharing for write
    * - ReadWrite: global sharing for read and write operations
    *
+   * Note that the NONLINEAR callback is in the critical path of the solver, so it should be fast.
+   *
    * @param op Operation type
    * @param policy Sharing policy
    * @param cb Callback for NONLINEAR policies