-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8a46450
commit ec335f0
Showing
348 changed files
with
21,448 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,288 @@ | ||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> | ||
<html xmlns="http://www.w3.org/1999/xhtml"> | ||
<head> | ||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> | ||
<meta http-equiv="X-UA-Compatible" content="IE=9"/> | ||
<meta name="generator" content="Doxygen 1.9.1"/> | ||
<meta name="viewport" content="width=device-width, initial-scale=1"/> | ||
<title>CRing: lib/Common.h File Reference</title> | ||
<link href="tabs.css" rel="stylesheet" type="text/css"/> | ||
<script type="text/javascript" src="jquery.js"></script> | ||
<script type="text/javascript" src="dynsections.js"></script> | ||
<link href="search/search.css" rel="stylesheet" type="text/css"/> | ||
<script type="text/javascript" src="search/searchdata.js"></script> | ||
<script type="text/javascript" src="search/search.js"></script> | ||
<link href="doxygen.css" rel="stylesheet" type="text/css" /> | ||
</head> | ||
<body> | ||
<div id="top"><!-- do not remove this div, it is closed by doxygen! --> | ||
<div id="titlearea"> | ||
<table cellspacing="0" cellpadding="0"> | ||
<tbody> | ||
<tr style="height: 56px;"> | ||
<td id="projectalign" style="padding-left: 0.5em;"> | ||
<div id="projectname">CRing | ||
</div> | ||
<div id="projectbrief">Cring is a lightweight and efficient event loop library written in pure C utilizing io-uring</div> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
<!-- end header part --> | ||
<!-- Generated by Doxygen 1.9.1 --> | ||
<script type="text/javascript"> | ||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ | ||
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html'); | ||
/* @license-end */ | ||
</script> | ||
<script type="text/javascript" src="menudata.js"></script> | ||
<script type="text/javascript" src="menu.js"></script> | ||
<script type="text/javascript"> | ||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */ | ||
$(function() { | ||
initMenu('',true,false,'search.php','Search'); | ||
$(document).ready(function() { init_search(); }); | ||
}); | ||
/* @license-end */</script> | ||
<div id="main-nav"></div> | ||
<!-- window showing the filter options --> | ||
<div id="MSearchSelectWindow" | ||
onmouseover="return searchBox.OnSearchSelectShow()" | ||
onmouseout="return searchBox.OnSearchSelectHide()" | ||
onkeydown="return searchBox.OnSearchSelectKey(event)"> | ||
</div> | ||
|
||
<!-- iframe showing the search results (closed by default) --> | ||
<div id="MSearchResultsWindow"> | ||
<iframe src="javascript:void(0)" frameborder="0" | ||
name="MSearchResults" id="MSearchResults"> | ||
</iframe> | ||
</div> | ||
|
||
<div id="nav-path" class="navpath"> | ||
<ul> | ||
<li class="navelem"><a class="el" href="dir_97aefd0d527b934f1d99a682da8fe6a9.html">lib</a></li> </ul> | ||
</div> | ||
</div><!-- top --> | ||
<div class="header"> | ||
<div class="summary"> | ||
<a href="#define-members">Macros</a> | | ||
<a href="#func-members">Functions</a> </div> | ||
<div class="headertitle"> | ||
<div class="title">Common.h File Reference</div> </div> | ||
</div><!--header--> | ||
<div class="contents"> | ||
<div class="textblock"><code>#include <stdint.h></code><br /> | ||
<code>#include <stdio.h></code><br /> | ||
</div><div class="textblock"><div class="dynheader"> | ||
Include dependency graph for Common.h:</div> | ||
<div class="dyncontent"> | ||
<div class="center"><img src="Common_8h__incl.png" border="0" usemap="#alib_2Common_8h" alt=""/></div> | ||
<map name="alib_2Common_8h" id="alib_2Common_8h"> | ||
<area shape="rect" title=" " alt="" coords="31,5,144,32"/> | ||
<area shape="rect" title=" " alt="" coords="5,80,76,107"/> | ||
<area shape="rect" title=" " alt="" coords="101,80,167,107"/> | ||
</map> | ||
</div> | ||
</div><div class="textblock"><div class="dynheader"> | ||
This graph shows which files directly or indirectly include this file:</div> | ||
<div class="dyncontent"> | ||
<div class="center"><img src="Common_8h__dep__incl.png" border="0" usemap="#alib_2Common_8hdep" alt=""/></div> | ||
<map name="alib_2Common_8hdep" id="alib_2Common_8hdep"> | ||
<area shape="rect" title=" " alt="" coords="1053,5,1167,32"/> | ||
<area shape="rect" href="IOContext_8h.html" title=" " alt="" coords="1051,80,1169,107"/> | ||
<area shape="rect" href="Executor_8h.html" title=" " alt="" coords="506,155,615,181"/> | ||
<area shape="rect" href="Executor_8c.html" title=" " alt="" coords="961,237,1072,263"/> | ||
<area shape="rect" href="io-context-integration-test_8c.html" title=" " alt="" coords="666,319,866,360"/> | ||
<area shape="rect" href="io-context-test_8c.html" title=" " alt="" coords="983,326,1149,353"/> | ||
<area shape="rect" href="IOContext_8c.html" title=" " alt="" coords="1199,155,1320,181"/> | ||
<area shape="rect" href="pingpong-client_8c.html" title=" " alt="" coords="381,229,548,271"/> | ||
<area shape="rect" href="pingpong-server_8c.html" title=" " alt="" coords="572,229,739,271"/> | ||
<area shape="rect" href="echo-client_8c.html" title=" " alt="" coords="763,237,937,263"/> | ||
<area shape="rect" href="echo-server_8c.html" title=" " alt="" coords="5,237,183,263"/> | ||
<area shape="rect" href="executor-test_8c.html" title=" " alt="" coords="143,326,298,353"/> | ||
<area shape="rect" href="tests_2utils_8h.html" title=" " alt="" coords="258,237,357,263"/> | ||
<area shape="rect" href="main-test_8c.html" title=" " alt="" coords="323,326,455,353"/> | ||
</map> | ||
</div> | ||
</div> | ||
<p><a href="Common_8h_source.html">Go to the source code of this file.</a></p> | ||
<table class="memberdecls"> | ||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a> | ||
Macros</h2></td></tr> | ||
<tr class="memitem:abd0b0523397fb05f0ed46fc217fb630f"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="Common_8h.html#abd0b0523397fb05f0ed46fc217fb630f">LOG_DEBUG</a>(format, ...)</td></tr> | ||
<tr class="separator:abd0b0523397fb05f0ed46fc217fb630f"><td class="memSeparator" colspan="2"> </td></tr> | ||
<tr class="memitem:abffaf9cecb61026cac6db71a16ace9c5"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="Common_8h.html#abffaf9cecb61026cac6db71a16ace9c5">LOG_ERROR</a>(format, ...)</td></tr> | ||
<tr class="separator:abffaf9cecb61026cac6db71a16ace9c5"><td class="memSeparator" colspan="2"> </td></tr> | ||
<tr class="memitem:ac6c45889010c1bd68631771b64f18101"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="Common_8h.html#ac6c45889010c1bd68631771b64f18101">unlikely</a>(x)   __builtin_expect(!!(x), 0)</td></tr> | ||
<tr class="separator:ac6c45889010c1bd68631771b64f18101"><td class="memSeparator" colspan="2"> </td></tr> | ||
<tr class="memitem:a217a0bd562b98ae8c2ffce44935351e1"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="Common_8h.html#a217a0bd562b98ae8c2ffce44935351e1">likely</a>(x)   __builtin_expect(!!(x), 1)</td></tr> | ||
<tr class="separator:a217a0bd562b98ae8c2ffce44935351e1"><td class="memSeparator" colspan="2"> </td></tr> | ||
</table><table class="memberdecls"> | ||
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a> | ||
Functions</h2></td></tr> | ||
<tr class="memitem:a22f9ba4d0b088a4f0ae03e1e10c75e78"><td class="memItemLeft" align="right" valign="top">static uint64_t </td><td class="memItemRight" valign="bottom"><a class="el" href="Common_8h.html#a22f9ba4d0b088a4f0ae03e1e10c75e78">align64pow2</a> (uint64_t v)</td></tr> | ||
<tr class="separator:a22f9ba4d0b088a4f0ae03e1e10c75e78"><td class="memSeparator" colspan="2"> </td></tr> | ||
<tr class="memitem:a3919466116f3e3201ee4d982cde797c1"><td class="memItemLeft" align="right" valign="top">static uint32_t </td><td class="memItemRight" valign="bottom"><a class="el" href="Common_8h.html#a3919466116f3e3201ee4d982cde797c1">align32pow2</a> (uint32_t x)</td></tr> | ||
<tr class="separator:a3919466116f3e3201ee4d982cde797c1"><td class="memSeparator" colspan="2"> </td></tr> | ||
</table> | ||
<h2 class="groupheader">Macro Definition Documentation</h2> | ||
<a id="a217a0bd562b98ae8c2ffce44935351e1"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a217a0bd562b98ae8c2ffce44935351e1">◆ </a></span>likely</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">#define likely</td> | ||
<td>(</td> | ||
<td class="paramtype"> </td> | ||
<td class="paramname">x</td><td>)</td> | ||
<td>   __builtin_expect(!!(x), 1)</td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
</div> | ||
</div> | ||
<a id="abd0b0523397fb05f0ed46fc217fb630f"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#abd0b0523397fb05f0ed46fc217fb630f">◆ </a></span>LOG_DEBUG</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">#define LOG_DEBUG</td> | ||
<td>(</td> | ||
<td class="paramtype"> </td> | ||
<td class="paramname">format, </td> | ||
</tr> | ||
<tr> | ||
<td class="paramkey"></td> | ||
<td></td> | ||
<td class="paramtype"> </td> | ||
<td class="paramname"><em>...</em> </td> | ||
</tr> | ||
<tr> | ||
<td></td> | ||
<td>)</td> | ||
<td></td><td></td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
<b>Value:</b><div class="fragment"><div class="line"> <span class="keywordflow">do</span> { \</div> | ||
<div class="line"> fprintf(stdout, <span class="stringliteral">"[DEBUG %s] "</span> format, __func__, ##__VA_ARGS__); \</div> | ||
<div class="line"> } <span class="keywordflow">while</span> (0)</div> | ||
</div><!-- fragment --> | ||
</div> | ||
</div> | ||
<a id="abffaf9cecb61026cac6db71a16ace9c5"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#abffaf9cecb61026cac6db71a16ace9c5">◆ </a></span>LOG_ERROR</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">#define LOG_ERROR</td> | ||
<td>(</td> | ||
<td class="paramtype"> </td> | ||
<td class="paramname">format, </td> | ||
</tr> | ||
<tr> | ||
<td class="paramkey"></td> | ||
<td></td> | ||
<td class="paramtype"> </td> | ||
<td class="paramname"><em>...</em> </td> | ||
</tr> | ||
<tr> | ||
<td></td> | ||
<td>)</td> | ||
<td></td><td></td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
<b>Value:</b><div class="fragment"><div class="line"> <span class="keywordflow">do</span> { \</div> | ||
<div class="line"> (void)fprintf(stderr, <span class="stringliteral">"[ERROR %s] "</span> format, __func__, ##__VA_ARGS__); \</div> | ||
<div class="line"> } <span class="keywordflow">while</span> (0)</div> | ||
</div><!-- fragment --> | ||
</div> | ||
</div> | ||
<a id="ac6c45889010c1bd68631771b64f18101"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#ac6c45889010c1bd68631771b64f18101">◆ </a></span>unlikely</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">#define unlikely</td> | ||
<td>(</td> | ||
<td class="paramtype"> </td> | ||
<td class="paramname">x</td><td>)</td> | ||
<td>   __builtin_expect(!!(x), 0)</td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
</div> | ||
</div> | ||
<h2 class="groupheader">Function Documentation</h2> | ||
<a id="a3919466116f3e3201ee4d982cde797c1"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a3919466116f3e3201ee4d982cde797c1">◆ </a></span>align32pow2()</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="mlabels"> | ||
<tr> | ||
<td class="mlabels-left"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">static uint32_t align32pow2 </td> | ||
<td>(</td> | ||
<td class="paramtype">uint32_t </td> | ||
<td class="paramname"><em>x</em></td><td>)</td> | ||
<td></td> | ||
</tr> | ||
</table> | ||
</td> | ||
<td class="mlabels-right"> | ||
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span> </td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
</div> | ||
</div> | ||
<a id="a22f9ba4d0b088a4f0ae03e1e10c75e78"></a> | ||
<h2 class="memtitle"><span class="permalink"><a href="#a22f9ba4d0b088a4f0ae03e1e10c75e78">◆ </a></span>align64pow2()</h2> | ||
|
||
<div class="memitem"> | ||
<div class="memproto"> | ||
<table class="mlabels"> | ||
<tr> | ||
<td class="mlabels-left"> | ||
<table class="memname"> | ||
<tr> | ||
<td class="memname">static uint64_t align64pow2 </td> | ||
<td>(</td> | ||
<td class="paramtype">uint64_t </td> | ||
<td class="paramname"><em>v</em></td><td>)</td> | ||
<td></td> | ||
</tr> | ||
</table> | ||
</td> | ||
<td class="mlabels-right"> | ||
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span></span> </td> | ||
</tr> | ||
</table> | ||
</div><div class="memdoc"> | ||
|
||
</div> | ||
</div> | ||
</div><!-- contents --> | ||
<!-- start footer part --> | ||
<hr class="footer"/><address class="footer"><small> | ||
Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1 | ||
</small></address> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<map id="lib/Common.h" name="lib/Common.h"> | ||
<area shape="rect" id="node1" title=" " alt="" coords="1053,5,1167,32"/> | ||
<area shape="rect" id="node2" href="$IOContext_8h.html" title=" " alt="" coords="1051,80,1169,107"/> | ||
<area shape="rect" id="node3" href="$Executor_8h.html" title=" " alt="" coords="506,155,615,181"/> | ||
<area shape="rect" id="node8" href="$Executor_8c.html" title=" " alt="" coords="961,237,1072,263"/> | ||
<area shape="rect" id="node11" href="$io-context-integration-test_8c.html" title=" " alt="" coords="666,319,866,360"/> | ||
<area shape="rect" id="node12" href="$io-context-test_8c.html" title=" " alt="" coords="983,326,1149,353"/> | ||
<area shape="rect" id="node14" href="$IOContext_8c.html" title=" " alt="" coords="1199,155,1320,181"/> | ||
<area shape="rect" id="node4" href="$pingpong-client_8c.html" title=" " alt="" coords="381,229,548,271"/> | ||
<area shape="rect" id="node5" href="$pingpong-server_8c.html" title=" " alt="" coords="572,229,739,271"/> | ||
<area shape="rect" id="node6" href="$echo-client_8c.html" title=" " alt="" coords="763,237,937,263"/> | ||
<area shape="rect" id="node7" href="$echo-server_8c.html" title=" " alt="" coords="5,237,183,263"/> | ||
<area shape="rect" id="node9" href="$executor-test_8c.html" title=" " alt="" coords="143,326,298,353"/> | ||
<area shape="rect" id="node10" href="$tests_2utils_8h.html" title=" " alt="" coords="258,237,357,263"/> | ||
<area shape="rect" id="node13" href="$main-test_8c.html" title=" " alt="" coords="323,326,455,353"/> | ||
</map> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
5f9c875e253b9f26fbb5c60e8e1273cf |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<map id="lib/Common.h" name="lib/Common.h"> | ||
<area shape="rect" id="node1" title=" " alt="" coords="31,5,144,32"/> | ||
<area shape="rect" id="node2" title=" " alt="" coords="5,80,76,107"/> | ||
<area shape="rect" id="node3" title=" " alt="" coords="101,80,167,107"/> | ||
</map> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
72396f870d15af4beec0ce895faa771f |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.