Note that I can conduct the research inside the boost source code, and may do this to answer my own curiosity if there isn't anyone out there with an answer.
I do ask however because maybe someone has already done this comparison and can answer authoritatively?
It would seem that creating a shared memory mapped file between processes, and through construction with InterlockedIncrement()
one could create a largely usermode mutex akin to a CRITICAL_SECTION
, which would be considerably more performant than the Win32 Mutex for interprocess synchronisation.
So my expectation is that it may be probably for the implementation on Win32 of boost::interprocess_mutex
to have been implemented in this manner, and for it to be substantially quicker than the native API offering.
I only however have a supposition, I don't know through field testing what the performance of the boost::interprocess_mutex
is for interprocess synchronisation, or deeply investigated its implementation.
Does anyone have experience in using it or profiling its relative performance, or can they comment on using the safety of using InterlockedIncrement() across processes using shared memory?