Patrick Pelissier
c174b368e8
Fix issue with atomic variables needing writable variable even for reading only.
2018-03-16 23:27:08 +01:00
Patrick Pelissier
f2b2335080
Fix issue with C++ not supporting passing an int constant value to an unsigned atomic type...
...
I definitely find this disturbing.
2018-03-16 22:59:51 +01:00
Patrick Pelissier
f8e75761ef
Change SNAPSHOT_SRSW to SNAPSHOT_SPSC to be uniform with queue definition
...
(Replace Reader / Writer term by Consummer / Producer term)
2018-03-10 17:46:02 +01:00
Patrick Pelissier
aea816dcaf
Fix data race
2018-02-24 07:44:16 +01:00
Patrick Pelissier
b442d72ef7
Add forgotten free + check for memory allocation
2018-02-19 23:14:16 +01:00
Patrick Pelissier
b32b93340c
Improve tests & fix bugs.
...
Still one bug remain.
2018-02-18 17:01:41 +01:00
Patrick Pelissier
6de4c4092f
Add MRMW snapshot
2018-02-18 08:27:10 +01:00
Patrick Pelissier
3f2a641cdf
Add contract
2018-02-17 20:25:40 +01:00
Patrick Pelissier
20be2d8850
Externalized currentWrite
2018-02-17 20:21:53 +01:00
Patrick Pelissier
b37cd7dba7
Rewrite / simplify code
2018-02-17 20:08:00 +01:00
Patrick Pelissier
e274a49ffd
Fix bug as we can't fail spuriously here.
2018-02-17 19:28:09 +01:00
Patrick Pelissier
cba37abfae
Reword
2018-02-17 19:24:16 +01:00
Patrick Pelissier
be198a7040
Add MRSW snapshots.
2018-02-17 19:19:51 +01:00
Patrick Pelissier
a4753be5ae
Add test for int snapshot MRSW
2018-02-17 18:20:25 +01:00
Patrick Pelissier
3bda360196
Add first step of MRSW snapshot
2018-02-17 17:35:18 +01:00
Patrick Pelissier
80c7cdbdd2
Rename snapshot_def as snapshot_srsw_def
2018-02-17 12:00:45 +01:00
Patrick Pelissier
0afad9a825
Update comments.
2018-02-15 22:34:36 +01:00
Patrick Pelissier
c99b3de902
Fix double minus which transformed into + !
2018-02-15 22:31:50 +01:00
Patrick Pelissier
67856a98af
Avoid false sharing for snapshot by aligning properly the
...
data of the triple buffer to a cache boundary.
2018-02-10 08:29:34 +01:00
Patrick Pelissier
c71de15cb0
Update comment
2018-02-10 08:22:37 +01:00
Patrick Pelissier
73f15c1980
Update comment
2018-02-10 08:22:12 +01:00
Patrick Pelissier
210e05f7fc
Update copyright to 2018
2018-01-29 20:28:30 +01:00
Patrick Pelissier
2c695526dd
Fix issue with stricter C++ compiler with atomic definition.
...
(It still feels strange to not be able to store 0 in an atomic unsigned long).
2017-12-30 12:17:55 +01:00
Patrick Pelissier
229f99585d
Rename _look ==> _read and _take ==> _write
2017-10-15 22:49:59 +02:00
Patrick Pelissier
2700ccba1a
[SNAPSHOT]:
...
* Rename functions get_produced / get_consummed into get_write_buffer and get_read_buffer
* Add function _updated_p
* Add comments.
2017-10-11 22:16:39 +02:00
Patrick Pelissier
9cea3cf74d
Fix issue with definition of oplist of a snapshot
2017-10-10 23:06:33 +02:00
Patrick Pelissier
2e564088b0
Simplify the inclusion of headers.
2017-09-16 10:14:45 +02:00
Patrick Pelissier
1930bdeac1
_DEF macros checks if a global oplist is register if there is no one
...
given in the macro call. If it founds one, it will be it instead
of M_DEFAULT_OPLIST.
2017-09-16 08:31:22 +02:00
Patrick Pelissier
82b159e097
Add TODO
2017-08-19 12:19:30 +02:00
Patrick Pelissier
8a716cd4f4
Remove prefix snapshot from snapshot.
...
See previous commit on shared pointer.
2017-07-25 22:44:17 +02:00
Patrick Pelissier
62e2024658
Rename type into name for oplist definition.
2017-07-25 22:37:51 +02:00
Patrick Pelissier
ba7c772ae2
Use of M_CONST_CAST.
2017-05-26 15:49:23 +02:00
Patrick Pelissier
72c5c3f371
Replace stdatomic.h (C11 standard compliant header) by a custom one
...
to increase C++ compatibility as stdatomic.h doesn't work in C++!
(I would like to thanks the one(s) who thought it was a good idea
***not*** to include stdatomic.h -and thread.h- in the C++ standard!)
2017-04-13 21:50:16 +02:00
Patrick Pelissier
3db02c64fa
Fix issue with even stricter atomic implementation
...
(without even the set operator for atomics).
2017-04-10 23:04:34 +02:00
Patrick Pelissier
06b3f49855
Add missing const cast
2017-04-08 12:03:12 +02:00
Patrick Pelissier
4c75569a20
Fix issue with stricter compiler with stdatomic.
2017-04-08 11:51:18 +02:00
Patrick Pelissier
7d6f1861c9
Remove use of atomic_uint_fast8_t:
...
this type may not be available on all targets.
Use plain atomic_uchar instead.
Use of atomic_load to read an atomic_uchar.
Remove const from prototype since atomic_load
doesn't support const pointers.
2017-04-08 11:21:30 +02:00
Patrick Pelissier
4e8e716c5a
Fix potential issue in MT.
2017-03-24 18:02:34 +01:00
Patrick Pelissier
74113de0b2
Fix issue with clang 4 for incorrect usage of atomic + gcc 6 for incorrect implicit cast.
2017-03-18 14:33:56 +01:00
Patrick Pelissier
ebe1b06813
FIXME: Does method SWAP is needed for SNAPHOT ?
2017-03-14 21:44:02 +01:00
Patrick Pelissier
0c584420d7
Add sub OPLIST for OPLIST
...
Add missing contracts
2017-03-06 22:25:08 +01:00
Patrick Pelissier
d6ee3c6329
Add comments
2017-03-05 22:37:00 +01:00
Patrick Pelissier
4d019ca1f2
Update library name in headers.
2017-02-20 21:29:21 +01:00
Patrick Pelissier
cb433aa2a8
Rename macros:
...
* CAT* --> M_C*
2017-02-19 00:36:42 +01:00
Patrick Pelissier
8e9d20ba1a
Add initial stuff
2017-02-18 18:51:04 +01:00