|
From: Christian S. <chr...@ep...> - 2004-03-05 23:08:22
|
Es geschah am Freitag, 5. M=E4rz 2004 22:35 als Rui Nuno Capela schrieb: > Hi, > > > - I'm a bit disappointed about it's runtime efficiency > > In terms of code-path and resource efficiency, I humbly think that my raw > approach, based on strtok can't be beaten ;) I suggest we'll wait until we have a GUI so we can really test how it acts.= If=20 it performs really bad than we'll replace the parser by another solution, b= ut=20 I would still then use another parser generator instead of a hand crafted=20 parser implementation. Keep in mind that the current protocol (as defined i= n=20 the current, 4th draft) has only about perhaps 10% or less of the complexit= y=20 it will have in one or two years (e.g. think about the planned recompilatio= n=20 feature, all the modularity features...). And finally compare e.g. a Pascal= =20 compiler written in BNF with a hand crafted Pascal compiler. > > - Implemented LSCP network server (only single threaded so far, > > thus is only capable to handle one connection at one time), > > My liblscp code (http://www.rncbc.org/ls) has all this put together; is > multi-client and multi-threaded. Remember that you shall only code the > server-side callback function? > > OK. Now that some server code is already on linuxsampler I can dig it and > probably reimplement it using "my" liblscp approach :) The actual problem is not the server itself, but synchronization issues wit= hin=20 the engine and modifications that have to be done to the scanner when it=20 comes to more than one nework connections. Not a big deal either, but it=20 means work and I would rather spend the time in other things at the moment. Regarding efficiency of a multi threaded server I was thinking if a 0..n=20 threads solution would be good idea at all. It might be better to use a fix= ed=20 amount of threads (e.g. 10 for max. 10 fronteds simultaniously) _ALL_ start= ed=20 when LS is launched, then sending them all to sleep and just wake up one of= =20 them in case of a connection. This avoids memory allocation on runtime and= =20 avoids that our realtime thread might get in trouble. If you like to work on the multi-threaded extension of the server Rui, I wo= uld=20 appreciate that (less work for me ;) but I would definitely prefer you to= =20 work on a basic GUI first. We really lack some screenshots. ;) And one last thing: I would prefer to keep the server implemented in C++. Rui, if you like to checkin a new module to CVS (e.g. liblscp or your GUI),= =20 please let me know before you do it, because I have to set up a script on t= he=20 CVS server before. > > P.S. It's time for a frontend... :) > > Yes it is ;) That's what I wanted to hear! Now it's your turn! :) CU Christian |