Difference between Mutex, Semaphore & Spin Locks

First, remember the goal of these ‘synchronizing objects’ : These objects were designed to provide an efficient and coherent use of ‘shared data’ between more than 1 thread among 1 process or from different processes. These objects can be ‘acquired’ or ‘released’. That is it!!! End of story!!! Now, if it helps to you, let … Read more

Best way to do interprocess communication on Mac OS X

I am currently looking into the same questions. For me the possibility of adding Windows clients later makes the situation more complicated; in your case the answer seems to be simpler. About the options you have considered: Control files: While it is possible to communicate via control files, you have to keep in mind that … Read more

Fastest IPC method on Windows 7

ReadProcessMemory shouldn’t even be listed as an IPC method; yes, it can be used as such, but it exists mainly for debugging purposes (if you check its reference, it’s under the category “Debugging functions”), and it’s surely slower than “real” shared memory because it copies the memory of a process into the specified buffer, while … Read more

How to communicate with a windows service?

I could successfully handle the (almost) same issue as yours doing the following: In your Class : ServiceBase, that represents your Service class, you might have: public Class () //constructor, to create your log repository { InitializeComponent(); if (!System.Diagnostics.EventLog.SourceExists(“YOURSource”)) { System.Diagnostics.EventLog.CreateEventSource( “YOURSource”, “YOURLog”); } eventLog1.Source = “YOURSource”; eventLog1.Log = “YOURLog”; } Now, implement: protected override … Read more

Socketpair() in C/Unix

You can use socketpair only where you create both processes, like so: call socketpair – now you have two socket file descriptors (two ends of a single pipe) nominate one end to be the parent and one to be the child end. It doesn’t matter which, just make a choice and stick to it later … Read more