blob: d905ffb763dba52843ee6686dce2f7c270e12e4b [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>oscl_socket_tuneables.h File Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.2.18 -->
<center>
<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>
<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>
<code>#include "<a class="el" href="osclconfig__proc_8h-source.html">osclconfig_proc.h</a>"</code><br>
<p>
<a href="oscl__socket__tuneables_8h-source.html">Go to the source code of this file.</a><table border=0 cellpadding=0 cellspacing=0>
<tr><td></td></tr>
<tr><td colspan=2><br><h2>Defines</h2></td></tr>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
<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>
</table>
<hr><h2>Define Documentation</h2>
<a name="a11" doxytag="oscl_socket_tuneables.h::PV_OSCL_SOCKET_1MB_RECV_BUF"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_OSCL_SOCKET_1MB_RECV_BUF&nbsp;&nbsp;&nbsp;0
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Set 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.
<p>
When set to 1, the code will use the OsclSetRecvBufferSize macro to set the buffer size in the Bind call.
<p>
This setting was found to improve streaming performance on WinMobile devices, but should not generally be used. </td>
</tr>
</table>
<a name="a10" doxytag="oscl_socket_tuneables.h::PV_OSCL_SOCKET_SERVER_LOGGER_OUTPUT"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_OSCL_SOCKET_SERVER_LOGGER_OUTPUT&nbsp;&nbsp;&nbsp;0
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Set 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>
</tr>
</table>
<a name="a1" doxytag="oscl_socket_tuneables.h::PV_OSCL_SOCKET_STATS_LOGGING"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_OSCL_SOCKET_STATS_LOGGING&nbsp;&nbsp;&nbsp;0
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Set 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>
</tr>
</table>
<a name="a0" doxytag="oscl_socket_tuneables.h::PV_SOCKET_REQUEST_AO_PRIORITY"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_REQUEST_AO_PRIORITY&nbsp;&nbsp;&nbsp;OsclActiveObject::EPriorityNominal
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_SOCKET_REQUEST_AO_PRIORITY sets the priority of the socket request completion AOs. </td>
</tr>
</table>
<a name="a2" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER&nbsp;&nbsp;&nbsp;1
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Enable/disable the PV socket server here. </td>
</tr>
</table>
<a name="a9" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_AO_INTERVAL_MSEC"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_AO_INTERVAL_MSEC&nbsp;&nbsp;&nbsp;5
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_SOCKET_SERVER_AO_INTERVAL_MSEC sets the AO scheduling interval of the PV socket server AO for non-threaded implementations. </td>
</tr>
</table>
<a name="a8" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_AO_PRIORITY"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_AO_PRIORITY&nbsp;&nbsp;&nbsp;(OsclActiveObject::EPriorityNominal)
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_SOCKET_SERVER_AO_PRIORITY sets priority of the PV socket server AO for non-threaded implementations. </td>
</tr>
</table>
<a name="a3" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_IS_THREAD"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_IS_THREAD&nbsp;&nbsp;&nbsp;OSCL_HAS_THREAD_SUPPORT
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_SOCKET_SERVER_IS_THREAD chooses either the threaded or AO-based implementation of the PV socket server </td>
</tr>
</table>
<a name="a4" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_SELECT"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_SELECT&nbsp;&nbsp;&nbsp;0
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_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>
</tr>
</table>
<a name="a7" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_SELECT_LOOPBACK_SOCKET"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_SELECT_LOOPBACK_SOCKET&nbsp;&nbsp;&nbsp;0
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_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>
</tr>
</table>
<a name="a6" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_SELECT_TIMEOUT_MSEC"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_SELECT_TIMEOUT_MSEC&nbsp;&nbsp;&nbsp;(-1)
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_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>
</tr>
</table>
<a name="a5" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVER_THREAD_PRIORITY"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVER_THREAD_PRIORITY&nbsp;&nbsp;&nbsp;ThreadPriorityAboveNormal
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
PV_SOCKET_SERVER_THREAD_PRIORITY sets the priority of the PV socket server thread. </td>
</tr>
</table>
<a name="a12" doxytag="oscl_socket_tuneables.h::PV_SOCKET_SERVI_STATS"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
<tr>
<td class="md">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> #define PV_SOCKET_SERVI_STATS&nbsp;&nbsp;&nbsp;0
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
For 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>
</tr>
</table>
<hr size="1"><img src="pvlogo_small.jpg"><address style="align: right;"><small>OSCL API</small>
<address style="align: left;"><small>Posting Version: OPENCORE_20090310 </small>
</small></address>
</body>
</html>