66f Subj : Re: Function pointers in shm shared memory ? To : comp.programming.threads From : CM Date : Fri Apr 29 2005 03:23 pm "Joe Seigh" wrote in message news:opspztgmmmqm36vk@grunion... > On Fri, 29 Apr 2005 13:01:25 +0200, CM wrote: > > > Hello all, > > > > In the process of seekeing the most > > effective clientserver communication > > for a personal project i stumble about > > an idea. > > > > under linux 2.6 > > > > Is it possible to share a memory segment > > which would contain a block of function > > that call inside the server process. > > > > the client after obtaining the shared memory > > segment would just have to call a function in > > shared segment to actually call a function of > > the server > > > [...] > > Any thought about this mechanism ? > > > > Thanks > > > > > > I don't think you can get there from here. It's not code > that you're trying to move between server and client, it's > data. So it is not possible to call my brigde functions from the clients ? Can you explain why ? > If you want shared code, why not use the shared > library mechanism? > because my server process cannot exist in multiple instances, as in fact it is a process using OpenGl to draw things.. I seek a way to call function to my server without pipes, messages queues or sockets. The best solution so far would be a shared mem variable that would be scrutinized by my main loop in server. but I wanted to avoid this sort of round robbin with much syscalls for the mutex handling. thanks . 0