Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Finally my great updated C++ synchronization objects library is here...

14 views
Skip to first unread message

amin...@gmail.com

unread,
May 10, 2016, 8:04:43 PM5/10/16
to
Why this is marked as abuse? It has been marked as abuse.
Report not abuse
Hello,

Finally my great updated C++ synchronization objects library is here...

I have corrected the bug with my scalable Asymmetric Distributed Reader-Writer mutex , and now i have modified some logic inside it, and now
it uses the windows FlushProcessWriteBuffers() on the writer side of my algorithm that executes a Full memory barrier on the other processors so that the variables that are needed by the writer side of my algorithm are visible. So you have to understand that declaring a variable volatile in C++ is not a sufficient condition to make the variable visible across cores, you need to execute a Full memory barrier, and this is what is doing the windows function FlushProcessWriteBuffers() on the writer side of my algorithm.


Now i need to make my new scalable Asymmetric Distributed Reader-Writer Mutex algorithm more clear, the Dmitry Vyukov scalable Asymmetric rw_mutex here:

https://groups.google.com/forum/#!topic/lock-free/Hv3GUlccYTc

This algorithm when it makes "writer_pending = true", it will block
all the readers the time needed for the following loop to execute:

for (int i = 0; i != max_reader_count; ++i)
{
// wait for all readers to complete
while (reader_inside[i])
SwitchToThread();
}


An this is expensive and not efficient, but my new algorithm that
is my scalable Asymmetric Distributed Reader-Writer Mutex algorithm,
doesn't block like that the reader threads, since in my new algorithm even if you enter like this loop above, the reader-side can still execute in parallel when the loop is not yet finished,
and this what makes my scalable Asymmetric Distributed Reader-Writer Mutex algorithm efficient, it has more parallelism than the Dmitry Vyukov scalable Asymmetric rw_mutex.


If you need to take a look at my new algorithm, just download the
source code , just look at version 2 of my algorithm
inside DRWLOCK.pas source code, you can download the source code
from here:

https://sites.google.com/site/aminer68/scalable-distributed-reader-writer-mutex

So hope that you will be happy with my great C++ synchronization objects library !


You can download my new and updated C++ synchronization objects library
from:

https://sites.google.com/site/aminer68/c-synchronization-objects-library



Thank you,
Amine Moulay Ramdane.





0 new messages