summary refs log tree commit diff
path: root/support/blob_repeat.h
diff options
context:
space:
mode:
Diffstat (limited to 'support/blob_repeat.h')
-rw-r--r--support/blob_repeat.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/support/blob_repeat.h b/support/blob_repeat.h
index 12f33bcd02..519458cf50 100644
--- a/support/blob_repeat.h
+++ b/support/blob_repeat.h
@@ -38,7 +38,17 @@ struct support_blob_repeat support_blob_repeat_allocate (const void *element,
                                                          size_t element_size,
                                                          size_t count);
 
-/* Deallocate the blob created by support_blob_repeat_allocate.  */
+/* Like support_blob_repeat_allocate, except that copy-on-write
+   semantics are disabled.  This means writing to one part of the blob
+   can affect other parts.  It is possible to map non-shared memory
+   over parts of the resulting blob using MAP_ANONYMOUS | MAP_FIXED
+   | MAP_PRIVATE, so that writes to these parts do not affect
+   others.  */
+struct support_blob_repeat support_blob_repeat_allocate_shared
+  (const void *element, size_t element_size, size_t count);
+
+/* Deallocate the blob created by support_blob_repeat_allocate or
+   support_blob_repeat_allocate_shared.  */
 void support_blob_repeat_free (struct support_blob_repeat *);
 
 #endif /* SUPPORT_BLOB_REPEAT_H */