• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
3<title>oscl_socket_tuneables.h File Reference</title>
4<link href="doxygen.css" rel="stylesheet" type="text/css">
5</head><body>
6<!-- Generated by Doxygen 1.2.18 -->
7<center>
8<a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="modules.html">Modules</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="annotated.html">Data Structures</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Data Fields</a> &nbsp; <a class="qindex" href="globals.html">Globals</a> &nbsp; </center>
9<hr><h1>oscl_socket_tuneables.h File Reference</h1><code>#include "<a class="el" href="osclconfig__io_8h-source.html">osclconfig_io.h</a>"</code><br>
10<code>#include "<a class="el" href="osclconfig__proc_8h-source.html">osclconfig_proc.h</a>"</code><br>
11
12<p>
13<a href="oscl__socket__tuneables_8h-source.html">Go to the source code of this file.</a><table border=0 cellpadding=0 cellspacing=0>
14<tr><td></td></tr>
15<tr><td colspan=2><br><h2>Defines</h2></td></tr>
16<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a0">PV_SOCKET_REQUEST_AO_PRIORITY</a>&nbsp;&nbsp;&nbsp;OsclActiveObject::EPriorityNominal</td></tr>
17<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a1">PV_OSCL_SOCKET_STATS_LOGGING</a>&nbsp;&nbsp;&nbsp;0</td></tr>
18<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a2">PV_SOCKET_SERVER</a>&nbsp;&nbsp;&nbsp;1</td></tr>
19<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a3">PV_SOCKET_SERVER_IS_THREAD</a>&nbsp;&nbsp;&nbsp;OSCL_HAS_THREAD_SUPPORT</td></tr>
20<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a4">PV_SOCKET_SERVER_SELECT</a>&nbsp;&nbsp;&nbsp;0</td></tr>
21<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a5">PV_SOCKET_SERVER_THREAD_PRIORITY</a>&nbsp;&nbsp;&nbsp;ThreadPriorityAboveNormal</td></tr>
22<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a6">PV_SOCKET_SERVER_SELECT_TIMEOUT_MSEC</a>&nbsp;&nbsp;&nbsp;(-1)</td></tr>
23<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a7">PV_SOCKET_SERVER_SELECT_LOOPBACK_SOCKET</a>&nbsp;&nbsp;&nbsp;0</td></tr>
24<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a8">PV_SOCKET_SERVER_AO_PRIORITY</a>&nbsp;&nbsp;&nbsp;(OsclActiveObject::EPriorityNominal)</td></tr>
25<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a9">PV_SOCKET_SERVER_AO_INTERVAL_MSEC</a>&nbsp;&nbsp;&nbsp;5</td></tr>
26<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a10">PV_OSCL_SOCKET_SERVER_LOGGER_OUTPUT</a>&nbsp;&nbsp;&nbsp;0</td></tr>
27<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a11">PV_OSCL_SOCKET_1MB_RECV_BUF</a>&nbsp;&nbsp;&nbsp;0</td></tr>
28<tr><td nowrap align=right valign=top>#define&nbsp;</td><td valign=bottom><a class="el" href="oscl__socket__tuneables_8h.html#a12">PV_SOCKET_SERVI_STATS</a>&nbsp;&nbsp;&nbsp;0</td></tr>
29</table>
30<hr><h2>Define Documentation</h2>
31<a name="a11" doxytag="oscl_socket_tuneables.h::PV_OSCL_SOCKET_1MB_RECV_BUF"></a><p>
32<table width="100%" cellpadding="2" cellspacing="0" border="0">
33  <tr>
34    <td class="md">
35      <table cellpadding="0" cellspacing="0" border="0">
36        <tr>
37          <td class="md" nowrap valign="top"> #define PV_OSCL_SOCKET_1MB_RECV_BUF&nbsp;&nbsp;&nbsp;0
38      </table>
39    </td>
40  </tr>
41</table>
42<table cellspacing=5 cellpadding=0 border=0>
43  <tr>
44    <td>
45      &nbsp;
46    </td>
47    <td>
48
49<p>
50Set this to 0 or 1 to enable/disable setting the socket receive buffer size to 1 MB in the Bind call. This setting only affects PV socket server implementations.
51<p>
52When set to 1, the code will use the OsclSetRecvBufferSize macro to set the buffer size in the Bind call.
53<p>
54This setting was found to improve streaming performance on WinMobile devices, but should not generally be used.     </td>
55  </tr>
56</table>
57<a name="a10" doxytag="oscl_socket_tuneables.h::PV_OSCL_SOCKET_SERVER_LOGGER_OUTPUT"></a><p>
58<table width="100%" cellpadding="2" cellspacing="0" border="0">
59  <tr>
60    <td class="md">
61      <table cellpadding="0" cellspacing="0" border="0">
62        <tr>
63          <td class="md" nowrap valign="top"> #define PV_OSCL_SOCKET_SERVER_LOGGER_OUTPUT&nbsp;&nbsp;&nbsp;0
64      </table>
65    </td>
66  </tr>
67</table>
68<table cellspacing=5 cellpadding=0 border=0>
69  <tr>
70    <td>
71      &nbsp;
72    </td>
73    <td>
74
75<p>
76Set this to 0 or 1 to enable/disable <a class="el" href="classPVLogger.html">PVLogger</a> output from PV socket server. Note that socket server logging will appear in a different file when running threaded mode of socket server. This is quite a bit of logging, so it should generally be disabled.     </td>
77  </tr>
78</table>
79<a name="a1" doxytag="oscl_socket_tuneables.h::PV_OSCL_SOCKET_STATS_LOGGING"></a><p>
80<table width="100%" cellpadding="2" cellspacing="0" border="0">
81  <tr>
82    <td class="md">
83      <table cellpadding="0" cellspacing="0" border="0">
84        <tr>
85          <td class="md" nowrap valign="top"> #define PV_OSCL_SOCKET_STATS_LOGGING&nbsp;&nbsp;&nbsp;0
86      </table>
87    </td>
88  </tr>
89</table>
90<table cellspacing=5 cellpadding=0 border=0>
91  <tr>
92    <td>
93      &nbsp;
94    </td>
95    <td>
96
97<p>
98Set this to 0 or 1 to enable/disable socket stats logging with "OsclSocketStats" node. This feature is fairly costly so should be off in production code.     </td>
99  </tr>
100</table>
101<a name="a0" doxytag="oscl_socket_tuneables.h::PV_SOCKET_REQUEST_AO_PRIORITY"></a><p>
102<table width="100%" cellpadding="2" cellspacing="0" border="0">
103  <tr>
104    <td class="md">
105      <table cellpadding="0" cellspacing="0" border="0">
106        <tr>
107          <td class="md" nowrap valign="top"> #define PV_SOCKET_REQUEST_AO_PRIORITY&nbsp;&nbsp;&nbsp;OsclActiveObject::EPriorityNominal
108      </table>
109    </td>
110  </tr>
111</table>
112<table cellspacing=5 cellpadding=0 border=0>
113  <tr>
114    <td>
115      &nbsp;
116    </td>
117    <td>
118
119<p>
120PV_SOCKET_REQUEST_AO_PRIORITY sets the priority of the socket request completion AOs.     </td>
121  </tr>
122</table>
123<a name="a2" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER"></a><p>
124<table width="100%" cellpadding="2" cellspacing="0" border="0">
125  <tr>
126    <td class="md">
127      <table cellpadding="0" cellspacing="0" border="0">
128        <tr>
129          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER&nbsp;&nbsp;&nbsp;1
130      </table>
131    </td>
132  </tr>
133</table>
134<table cellspacing=5 cellpadding=0 border=0>
135  <tr>
136    <td>
137      &nbsp;
138    </td>
139    <td>
140
141<p>
142Enable/disable the PV socket server here.     </td>
143  </tr>
144</table>
145<a name="a9" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_AO_INTERVAL_MSEC"></a><p>
146<table width="100%" cellpadding="2" cellspacing="0" border="0">
147  <tr>
148    <td class="md">
149      <table cellpadding="0" cellspacing="0" border="0">
150        <tr>
151          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_AO_INTERVAL_MSEC&nbsp;&nbsp;&nbsp;5
152      </table>
153    </td>
154  </tr>
155</table>
156<table cellspacing=5 cellpadding=0 border=0>
157  <tr>
158    <td>
159      &nbsp;
160    </td>
161    <td>
162
163<p>
164PV_SOCKET_SERVER_AO_INTERVAL_MSEC sets the AO scheduling interval of the PV socket server AO for non-threaded implementations.     </td>
165  </tr>
166</table>
167<a name="a8" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_AO_PRIORITY"></a><p>
168<table width="100%" cellpadding="2" cellspacing="0" border="0">
169  <tr>
170    <td class="md">
171      <table cellpadding="0" cellspacing="0" border="0">
172        <tr>
173          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_AO_PRIORITY&nbsp;&nbsp;&nbsp;(OsclActiveObject::EPriorityNominal)
174      </table>
175    </td>
176  </tr>
177</table>
178<table cellspacing=5 cellpadding=0 border=0>
179  <tr>
180    <td>
181      &nbsp;
182    </td>
183    <td>
184
185<p>
186PV_SOCKET_SERVER_AO_PRIORITY sets priority of the PV socket server AO for non-threaded implementations.     </td>
187  </tr>
188</table>
189<a name="a3" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_IS_THREAD"></a><p>
190<table width="100%" cellpadding="2" cellspacing="0" border="0">
191  <tr>
192    <td class="md">
193      <table cellpadding="0" cellspacing="0" border="0">
194        <tr>
195          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_IS_THREAD&nbsp;&nbsp;&nbsp;OSCL_HAS_THREAD_SUPPORT
196      </table>
197    </td>
198  </tr>
199</table>
200<table cellspacing=5 cellpadding=0 border=0>
201  <tr>
202    <td>
203      &nbsp;
204    </td>
205    <td>
206
207<p>
208PV_SOCKET_SERVER_IS_THREAD chooses either the threaded or AO-based implementation of the PV socket server     </td>
209  </tr>
210</table>
211<a name="a4" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_SELECT"></a><p>
212<table width="100%" cellpadding="2" cellspacing="0" border="0">
213  <tr>
214    <td class="md">
215      <table cellpadding="0" cellspacing="0" border="0">
216        <tr>
217          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_SELECT&nbsp;&nbsp;&nbsp;0
218      </table>
219    </td>
220  </tr>
221</table>
222<table cellspacing=5 cellpadding=0 border=0>
223  <tr>
224    <td>
225      &nbsp;
226    </td>
227    <td>
228
229<p>
230PV_SOCKET_SERVER_SELECT chooses whether to use "select" call or not. In threaded mode, select call is required and is forced to "1". In AO mode, "select" call is an option that defaults to "0". Avoiding any "select" call was found to greatly reduce CPU usage on WinMobile devices.     </td>
231  </tr>
232</table>
233<a name="a7" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_SELECT_LOOPBACK_SOCKET"></a><p>
234<table width="100%" cellpadding="2" cellspacing="0" border="0">
235  <tr>
236    <td class="md">
237      <table cellpadding="0" cellspacing="0" border="0">
238        <tr>
239          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_SELECT_LOOPBACK_SOCKET&nbsp;&nbsp;&nbsp;0
240      </table>
241    </td>
242  </tr>
243</table>
244<table cellspacing=5 cellpadding=0 border=0>
245  <tr>
246    <td>
247      &nbsp;
248    </td>
249    <td>
250
251<p>
252PV_SOCKET_SERVER_SELECT_LOOPBACK_SOCKET enables the feature to wakeup the select call by writing to a loopback socket each time a new request comes in. This option is required to support the blocking select loop option of threaded server mode. This option is forced to "0" in AO mode.     </td>
253  </tr>
254</table>
255<a name="a6" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_SELECT_TIMEOUT_MSEC"></a><p>
256<table width="100%" cellpadding="2" cellspacing="0" border="0">
257  <tr>
258    <td class="md">
259      <table cellpadding="0" cellspacing="0" border="0">
260        <tr>
261          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_SELECT_TIMEOUT_MSEC&nbsp;&nbsp;&nbsp;(-1)
262      </table>
263    </td>
264  </tr>
265</table>
266<table cellspacing=5 cellpadding=0 border=0>
267  <tr>
268    <td>
269      &nbsp;
270    </td>
271    <td>
272
273<p>
274PV_SOCKET_SERVER_SELECT_TIMEOUT_MSEC sets duration of the select call in the PV socket server thread for the polling select loop implementation. When the timeout is -1, the select call will block forever waiting on a new request and will use a loopback socket to signal a new request. Note: if infinite wait is selected, but loopback socket is not available, the implementation will poll at 10 msec intervals.     </td>
275  </tr>
276</table>
277<a name="a5" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_THREAD_PRIORITY"></a><p>
278<table width="100%" cellpadding="2" cellspacing="0" border="0">
279  <tr>
280    <td class="md">
281      <table cellpadding="0" cellspacing="0" border="0">
282        <tr>
283          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_THREAD_PRIORITY&nbsp;&nbsp;&nbsp;ThreadPriorityAboveNormal
284      </table>
285    </td>
286  </tr>
287</table>
288<table cellspacing=5 cellpadding=0 border=0>
289  <tr>
290    <td>
291      &nbsp;
292    </td>
293    <td>
294
295<p>
296PV_SOCKET_SERVER_THREAD_PRIORITY sets the priority of the PV socket server thread.     </td>
297  </tr>
298</table>
299<a name="a12" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVI_STATS"></a><p>
300<table width="100%" cellpadding="2" cellspacing="0" border="0">
301  <tr>
302    <td class="md">
303      <table cellpadding="0" cellspacing="0" border="0">
304        <tr>
305          <td class="md" nowrap valign="top"> #define PV_SOCKET_SERVI_STATS&nbsp;&nbsp;&nbsp;0
306      </table>
307    </td>
308  </tr>
309</table>
310<table cellspacing=5 cellpadding=0 border=0>
311  <tr>
312    <td>
313      &nbsp;
314    </td>
315    <td>
316
317<p>
318For detailed performance breakdown of time spend in <a class="el" href="classOsclSocketServI.html">OsclSocketServI</a> AO. Output is logged under "OsclSchedulerPerfStats" node. Should be off in production code. This option is forced to "0" in threaded mode.     </td>
319  </tr>
320</table>
321<hr size="1"><img src="pvlogo_small.jpg"><address style="align: right;"><small>OSCL API</small>
322<address style="align: left;"><small>Posting Version: OPENCORE_20090310 </small>
323</small></address>
324</body>
325</html>
326