views:

71

answers:

1

Hello everyone,

I am using VSTS 2008 + Native C++ to develop RPC programs (both client and server). I am reading MSDN document for marshalling multi-dimensional array

http://msdn.microsoft.com/en-us/library/aa374185%28VS.85%29.aspx

I am confused about the following statement, and I am confused about what means offline and online, and why offline/online is related to size of stub/performance? Could anyone help to clarify please?

The fully-interpreted method marshals data completely offline. This reduces the size of the stub code considerably, but it also results in decreased performance. In mixed-mode marshaling, the stubs marshals some parameters online. While this results in a larger stub size, it also offers increased performance.

thanks in advance, George

+1  A: 

For a long while it was a poorly documented part as they extended the RPC into 'object' space and what not and docs are probably still out of date. Besides, you do realise it is a multi-decade old tech extending the old DPC RPC ? :-)

Whilst MS historically had some of the most optimal marshalling code for that age (wars on Corba-on-the-Cob and ACE-style-blasphemy-code), most likely the difference of online/offline is in being partially-interpreted (and optimised when it can) or fully interpreted (ie. all data driven).

I can't access MSDN or any microsoft site, because I either pissed them off or I have one of those popular viruses that block all their sites ( and I don't mind the former or the latter, it makes me use my time more effectively without managed noise).

If that link is not for /Oic or similar switch for the MIDL compiler. it should give you an idea what it is all about. I wouldn't be bothered too much by it, try both and see the perf/size if you have to.

rama-jka toti
"Besides, you do realise it is a multi-decade old tech extending the old DPC RPC ? :-)" -- Yes. I am maintaining a legacy system developed by RPC, many pains. :-(
George2
Majkara, I have tried to look for MSDN links for /Oic, but find almost the same information. i.e. it mentions terms like offline/online stub size/performance, but not explained what is online/offline and why it matters stub size/performance. Appreciate if you could recommend me some links which describe such topics.
George2
Than you're just out of luck. Seriously, I think you are over-worried with the terms 'offline' and 'online'. Don't let them scare you, as they were probably the terminology MS used while they were still under an impression Windows NT3.x and 95 don't need TCP/IP or Internet :) They did that job properly and you won't see much of a difference especially on modern CPUs and it is unlikely to be your primary bottleneck ever. Run a profiler and see the culprits, in protocol chatiness/roundtrips, in code, etc. You can optimise somewhere else and by a huge margin in comparison to this micro-worry.
rama-jka toti
Thanks Majk-a-Ra Tito! My concern is not about the performance differences between online/offline, but what means (the concept of) online and offline, any ideas?
George2
as mentioned, I'd imagine it is: offline = all-data-driven ie. by a form of 'bytecode'. online = opening space for optimisations but could still end up using offline methods as fallback.
rama-jka toti