diff options
author | Jim Flynn <jim.flynn@arm.com> | 2020-03-20 12:25:56 +0000 |
---|---|---|
committer | Jim Flynn <jim.flynn@arm.com> | 2020-03-20 12:25:56 +0000 |
commit | 6940dd720ebb6b3d1df8ca203ab696daefe58189 (patch) | |
tree | 453b6bf09531c92efe5c7abb0926bae104042fd7 /Documentation/_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml | |
parent | 4e2e213d1f22ccd8021bf654e46397434ee50390 (diff) | |
download | armnn-6940dd720ebb6b3d1df8ca203ab696daefe58189.tar.gz |
renamed Documentation folder 20.02 and added .nojekyll file
Signed-off-by: Jim Flynn <jim.flynn@arm.com>
Diffstat (limited to 'Documentation/_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml')
-rw-r--r-- | Documentation/_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml | 291 |
1 files changed, 0 insertions, 291 deletions
diff --git a/Documentation/_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml b/Documentation/_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml deleted file mode 100644 index 9a3c449275..0000000000 --- a/Documentation/_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml +++ /dev/null @@ -1,291 +0,0 @@ -<!-- Copyright (c) 2020 ARM Limited. --> -<!-- --> -<!-- SPDX-License-Identifier: MIT --> -<!-- --> -<!-- HTML header for doxygen 1.8.13--> -<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://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.8.13"/> -<meta name="robots" content="NOINDEX, NOFOLLOW" /> -<meta name="viewport" content="width=device-width, initial-scale=1"/> -<title>ArmNN: src/profiling/test/ProfilingConnectionDumpToFileDecoratorTests.cpp 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="navtree.css" rel="stylesheet" type="text/css"/> -<script type="text/javascript" src="resize.js"></script> -<script type="text/javascript" src="navtreedata.js"></script> -<script type="text/javascript" src="navtree.js"></script> -<script type="text/javascript"> - $(document).ready(initResizable); -</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> -<script type="text/x-mathjax-config"> - MathJax.Hub.Config({ - extensions: ["tex2jax.js"], - jax: ["input/TeX","output/HTML-CSS"], -}); -</script><script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script> -<link href="doxygen.css" rel="stylesheet" type="text/css" /> -<link href="stylesheet.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;"> - <img alt="ArmNN" src="Arm_NN_horizontal_blue.png" style="max-width: 10rem; margin-top: .5rem; margin-left 10px"/> - <td style="padding-left: 0.5em;"> - <div id="projectname"> -  <span id="projectnumber">20.02</span> - </div> - </td> - </tr> - </tbody> -</table> -</div> -<!-- end header part --> -<!-- Generated by Doxygen 1.8.13 --> -<script type="text/javascript"> -var searchBox = new SearchBox("searchBox", "search",false,'Search'); -</script> -<script type="text/javascript" src="menudata.js"></script> -<script type="text/javascript" src="menu.js"></script> -<script type="text/javascript"> -$(function() { - initMenu('',true,false,'search.php','Search'); - $(document).ready(function() { init_search(); }); -}); -</script> -<div id="main-nav"></div> -</div><!-- top --> -<div id="side-nav" class="ui-resizable side-nav-resizable"> - <div id="nav-tree"> - <div id="nav-tree-contents"> - <div id="nav-sync" class="sync"></div> - </div> - </div> - <div id="splitbar" style="-moz-user-select:none;" - class="ui-resizable-handle"> - </div> -</div> -<script type="text/javascript"> -$(document).ready(function(){initNavTree('_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml','');}); -</script> -<div id="doc-content"> -<!-- 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 class="header"> - <div class="summary"> -<a href="#func-members">Functions</a> </div> - <div class="headertitle"> -<div class="title">ProfilingConnectionDumpToFileDecoratorTests.cpp File Reference</div> </div> -</div><!--header--> -<div class="contents"> -<div class="textblock"><code>#include "<a class="el" href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml">../ProfilingConnectionDumpToFileDecorator.hpp</a>"</code><br /> -<code>#include <<a class="el" href="_runtime_8hpp_source.xhtml">Runtime.hpp</a>></code><br /> -<code>#include <<a class="el" href="_ignore_unused_8hpp_source.xhtml">armnn/utility/IgnoreUnused.hpp</a>></code><br /> -<code>#include <fstream></code><br /> -<code>#include <sstream></code><br /> -<code>#include <boost/filesystem.hpp></code><br /> -<code>#include <boost/numeric/conversion/cast.hpp></code><br /> -<code>#include <boost/test/unit_test.hpp></code><br /> -</div> -<p><a href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">Go to the source code of this file.</a></p> -<table class="memberdecls"> -<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a> -Functions</h2></td></tr> -<tr class="memitem:a10edc4fab8af7994633dfc7b401244b2"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml#a10edc4fab8af7994633dfc7b401244b2">BOOST_AUTO_TEST_CASE</a> (DumpIncomingInvalidFile)</td></tr> -<tr class="separator:a10edc4fab8af7994633dfc7b401244b2"><td class="memSeparator" colspan="2"> </td></tr> -<tr class="memitem:a8bf609e71434b827d7e70e162e3eb479"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml#a8bf609e71434b827d7e70e162e3eb479">BOOST_AUTO_TEST_CASE</a> (DumpIncomingInvalidFileIgnoreErrors)</td></tr> -<tr class="separator:a8bf609e71434b827d7e70e162e3eb479"><td class="memSeparator" colspan="2"> </td></tr> -<tr class="memitem:a9aea32b5076eb204516d8e08e4dbabe5"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml#a9aea32b5076eb204516d8e08e4dbabe5">BOOST_AUTO_TEST_CASE</a> (DumpIncomingValidFile)</td></tr> -<tr class="separator:a9aea32b5076eb204516d8e08e4dbabe5"><td class="memSeparator" colspan="2"> </td></tr> -<tr class="memitem:a0f63813c62d808da0da829f013d20c20"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml#a0f63813c62d808da0da829f013d20c20">BOOST_AUTO_TEST_CASE</a> (DumpOutgoingInvalidFile)</td></tr> -<tr class="separator:a0f63813c62d808da0da829f013d20c20"><td class="memSeparator" colspan="2"> </td></tr> -<tr class="memitem:a0d64f99889b7ca80ab0f924c31a658c1"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml#a0d64f99889b7ca80ab0f924c31a658c1">BOOST_AUTO_TEST_CASE</a> (DumpOutgoingInvalidFileIgnoreErrors)</td></tr> -<tr class="separator:a0d64f99889b7ca80ab0f924c31a658c1"><td class="memSeparator" colspan="2"> </td></tr> -<tr class="memitem:a6f0568d8e45cdbebfb96482e4141e591"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml#a6f0568d8e45cdbebfb96482e4141e591">BOOST_AUTO_TEST_CASE</a> (DumpOutgoingValidFile)</td></tr> -<tr class="separator:a6f0568d8e45cdbebfb96482e4141e591"><td class="memSeparator" colspan="2"> </td></tr> -</table> -<h2 class="groupheader">Function Documentation</h2> -<a id="a10edc4fab8af7994633dfc7b401244b2"></a> -<h2 class="memtitle"><span class="permalink"><a href="#a10edc4fab8af7994633dfc7b401244b2">◆ </a></span>BOOST_AUTO_TEST_CASE() <span class="overload">[1/6]</span></h2> - -<div class="memitem"> -<div class="memproto"> - <table class="memname"> - <tr> - <td class="memname">BOOST_AUTO_TEST_CASE </td> - <td>(</td> - <td class="paramtype">DumpIncomingInvalidFile </td> - <td class="paramname"></td><td>)</td> - <td></td> - </tr> - </table> -</div><div class="memdoc"> - -<p class="definition">Definition at line <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml#l00079">79</a> of file <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a>.</p> - -<p class="reference">References <a class="el" href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">options</a>, and <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00064">ProfilingConnectionDumpToFileDecorator::ReadPacket()</a>.</p> -<div class="fragment"><div class="line"><a name="l00080"></a><span class="lineno"> 80</span> {</div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  armnn::Runtime::CreationOptions::ExternalProfilingOptions <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a>;</div><div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  options.m_IncomingCaptureFile = <span class="stringliteral">"/"</span>;</div><div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  options.m_OutgoingCaptureFile = <span class="stringliteral">""</span>;</div><div class="line"><a name="l00084"></a><span class="lineno"> 84</span>  <a class="code" href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">ProfilingConnectionDumpToFileDecorator</a> decorator(std::make_unique<DummyProfilingConnection>(), options, <span class="keyword">false</span>);</div><div class="line"><a name="l00085"></a><span class="lineno"> 85</span>  BOOST_CHECK_THROW(decorator.ReadPacket(0), <a class="code" href="classarmnn_1_1_runtime_exception.xhtml">armnn::RuntimeException</a>);</div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span> }</div><div class="ttc" id="classarmnn_1_1_runtime_exception_xhtml"><div class="ttname"><a href="classarmnn_1_1_runtime_exception.xhtml">armnn::RuntimeException</a></div><div class="ttdef"><b>Definition:</b> <a href="_exceptions_8hpp_source.xhtml#l00120">Exceptions.hpp:120</a></div></div> -<div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a6560146509197f3e197d8d36f76c1347"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a></div><div class="ttdeci">armnn::Runtime::CreationOptions::ExternalProfilingOptions options</div><div class="ttdef"><b>Definition:</b> <a href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">FileOnlyProfilingDecoratorTests.cpp:45</a></div></div> -<div class="ttc" id="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator_xhtml"><div class="ttname"><a href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">armnn::profiling::ProfilingConnectionDumpToFileDecorator</a></div><div class="ttdef"><b>Definition:</b> <a href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml#l00025">ProfilingConnectionDumpToFileDecorator.hpp:25</a></div></div> -</div><!-- fragment --> -</div> -</div> -<a id="a8bf609e71434b827d7e70e162e3eb479"></a> -<h2 class="memtitle"><span class="permalink"><a href="#a8bf609e71434b827d7e70e162e3eb479">◆ </a></span>BOOST_AUTO_TEST_CASE() <span class="overload">[2/6]</span></h2> - -<div class="memitem"> -<div class="memproto"> - <table class="memname"> - <tr> - <td class="memname">BOOST_AUTO_TEST_CASE </td> - <td>(</td> - <td class="paramtype">DumpIncomingInvalidFileIgnoreErrors </td> - <td class="paramname"></td><td>)</td> - <td></td> - </tr> - </table> -</div><div class="memdoc"> - -<p class="definition">Definition at line <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml#l00088">88</a> of file <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a>.</p> - -<p class="reference">References <a class="el" href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">options</a>, and <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00064">ProfilingConnectionDumpToFileDecorator::ReadPacket()</a>.</p> -<div class="fragment"><div class="line"><a name="l00089"></a><span class="lineno"> 89</span> {</div><div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  armnn::Runtime::CreationOptions::ExternalProfilingOptions <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a>;</div><div class="line"><a name="l00091"></a><span class="lineno"> 91</span>  options.m_IncomingCaptureFile = <span class="stringliteral">"/"</span>;</div><div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  options.m_OutgoingCaptureFile = <span class="stringliteral">""</span>;</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  <a class="code" href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">ProfilingConnectionDumpToFileDecorator</a> decorator(std::make_unique<DummyProfilingConnection>(), options, <span class="keyword">true</span>);</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  BOOST_CHECK_NO_THROW(decorator.ReadPacket(0));</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span> }</div><div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a6560146509197f3e197d8d36f76c1347"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a></div><div class="ttdeci">armnn::Runtime::CreationOptions::ExternalProfilingOptions options</div><div class="ttdef"><b>Definition:</b> <a href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">FileOnlyProfilingDecoratorTests.cpp:45</a></div></div> -<div class="ttc" id="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator_xhtml"><div class="ttname"><a href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">armnn::profiling::ProfilingConnectionDumpToFileDecorator</a></div><div class="ttdef"><b>Definition:</b> <a href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml#l00025">ProfilingConnectionDumpToFileDecorator.hpp:25</a></div></div> -</div><!-- fragment --> -</div> -</div> -<a id="a9aea32b5076eb204516d8e08e4dbabe5"></a> -<h2 class="memtitle"><span class="permalink"><a href="#a9aea32b5076eb204516d8e08e4dbabe5">◆ </a></span>BOOST_AUTO_TEST_CASE() <span class="overload">[3/6]</span></h2> - -<div class="memitem"> -<div class="memproto"> - <table class="memname"> - <tr> - <td class="memname">BOOST_AUTO_TEST_CASE </td> - <td>(</td> - <td class="paramtype">DumpIncomingValidFile </td> - <td class="paramname"></td><td>)</td> - <td></td> - </tr> - </table> -</div><div class="memdoc"> - -<p class="definition">Definition at line <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml#l00097">97</a> of file <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a>.</p> - -<p class="reference">References <a class="el" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK()</a>, <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00044">ProfilingConnectionDumpToFileDecorator::Close()</a>, <a class="el" href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">options</a>, and <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00064">ProfilingConnectionDumpToFileDecorator::ReadPacket()</a>.</p> -<div class="fragment"><div class="line"><a name="l00098"></a><span class="lineno"> 98</span> {</div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span>  boost::filesystem::path fileName =</div><div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  boost::filesystem::temp_directory_path() / boost::filesystem::unique_path();</div><div class="line"><a name="l00101"></a><span class="lineno"> 101</span> </div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span>  armnn::Runtime::CreationOptions::ExternalProfilingOptions <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a>;</div><div class="line"><a name="l00103"></a><span class="lineno"> 103</span>  options.m_IncomingCaptureFile = fileName.string();</div><div class="line"><a name="l00104"></a><span class="lineno"> 104</span>  options.m_OutgoingCaptureFile = <span class="stringliteral">""</span>;</div><div class="line"><a name="l00105"></a><span class="lineno"> 105</span> </div><div class="line"><a name="l00106"></a><span class="lineno"> 106</span>  <a class="code" href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">ProfilingConnectionDumpToFileDecorator</a> decorator(std::make_unique<DummyProfilingConnection>(), options, <span class="keyword">false</span>);</div><div class="line"><a name="l00107"></a><span class="lineno"> 107</span> </div><div class="line"><a name="l00108"></a><span class="lineno"> 108</span>  <span class="comment">// NOTE: unique_ptr is needed here because operator=() is deleted for Packet</span></div><div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  std::unique_ptr<Packet> packet;</div><div class="line"><a name="l00110"></a><span class="lineno"> 110</span>  BOOST_CHECK_NO_THROW(packet = std::make_unique<Packet>(decorator.ReadPacket(0)));</div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span> </div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  decorator.Close();</div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span> </div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  std::vector<char> data = ReadDumpFile(options.m_IncomingCaptureFile);</div><div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  <span class="keyword">const</span> <span class="keywordtype">char</span>* packetData = <span class="keyword">reinterpret_cast<</span><span class="keyword">const </span><span class="keywordtype">char</span>*<span class="keyword">></span>(packet->GetData());</div><div class="line"><a name="l00116"></a><span class="lineno"> 116</span> </div><div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="comment">// check if the data read back from the dump file matches the original</span></div><div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  constexpr <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> bytesToSkip = 2u * <span class="keyword">sizeof</span>(uint32_t); <span class="comment">// skip header and packet length</span></div><div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  <span class="keywordtype">int</span> diff = std::strncmp(data.data() + bytesToSkip, packetData, g_DataLength);</div><div class="line"><a name="l00120"></a><span class="lineno"> 120</span>  <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a>(diff == 0);</div><div class="line"><a name="l00121"></a><span class="lineno"> 121</span> }</div><div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a0c262ba6f6c189a2d092d127c1b7627b"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a></div><div class="ttdeci">BOOST_CHECK(profilingService.GetCurrentState()==ProfilingState::WaitingForAck)</div></div> -<div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a6560146509197f3e197d8d36f76c1347"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a></div><div class="ttdeci">armnn::Runtime::CreationOptions::ExternalProfilingOptions options</div><div class="ttdef"><b>Definition:</b> <a href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">FileOnlyProfilingDecoratorTests.cpp:45</a></div></div> -<div class="ttc" id="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator_xhtml"><div class="ttname"><a href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">armnn::profiling::ProfilingConnectionDumpToFileDecorator</a></div><div class="ttdef"><b>Definition:</b> <a href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml#l00025">ProfilingConnectionDumpToFileDecorator.hpp:25</a></div></div> -</div><!-- fragment --> -</div> -</div> -<a id="a0f63813c62d808da0da829f013d20c20"></a> -<h2 class="memtitle"><span class="permalink"><a href="#a0f63813c62d808da0da829f013d20c20">◆ </a></span>BOOST_AUTO_TEST_CASE() <span class="overload">[4/6]</span></h2> - -<div class="memitem"> -<div class="memproto"> - <table class="memname"> - <tr> - <td class="memname">BOOST_AUTO_TEST_CASE </td> - <td>(</td> - <td class="paramtype">DumpOutgoingInvalidFile </td> - <td class="paramname"></td><td>)</td> - <td></td> - </tr> - </table> -</div><div class="memdoc"> - -<p class="definition">Definition at line <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml#l00123">123</a> of file <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a>.</p> - -<p class="reference">References <a class="el" href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">options</a>, and <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00053">ProfilingConnectionDumpToFileDecorator::WritePacket()</a>.</p> -<div class="fragment"><div class="line"><a name="l00124"></a><span class="lineno"> 124</span> {</div><div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  armnn::Runtime::CreationOptions::ExternalProfilingOptions <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a>;</div><div class="line"><a name="l00126"></a><span class="lineno"> 126</span>  options.m_IncomingCaptureFile = <span class="stringliteral">""</span>;</div><div class="line"><a name="l00127"></a><span class="lineno"> 127</span>  options.m_OutgoingCaptureFile = <span class="stringliteral">"/"</span>;</div><div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  <a class="code" href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">ProfilingConnectionDumpToFileDecorator</a> decorator(std::make_unique<DummyProfilingConnection>(), options, <span class="keyword">false</span>);</div><div class="line"><a name="l00129"></a><span class="lineno"> 129</span>  BOOST_CHECK_THROW(decorator.WritePacket(g_DataPtr, g_DataLength), <a class="code" href="classarmnn_1_1_runtime_exception.xhtml">armnn::RuntimeException</a>);</div><div class="line"><a name="l00130"></a><span class="lineno"> 130</span> }</div><div class="ttc" id="classarmnn_1_1_runtime_exception_xhtml"><div class="ttname"><a href="classarmnn_1_1_runtime_exception.xhtml">armnn::RuntimeException</a></div><div class="ttdef"><b>Definition:</b> <a href="_exceptions_8hpp_source.xhtml#l00120">Exceptions.hpp:120</a></div></div> -<div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a6560146509197f3e197d8d36f76c1347"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a></div><div class="ttdeci">armnn::Runtime::CreationOptions::ExternalProfilingOptions options</div><div class="ttdef"><b>Definition:</b> <a href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">FileOnlyProfilingDecoratorTests.cpp:45</a></div></div> -<div class="ttc" id="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator_xhtml"><div class="ttname"><a href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">armnn::profiling::ProfilingConnectionDumpToFileDecorator</a></div><div class="ttdef"><b>Definition:</b> <a href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml#l00025">ProfilingConnectionDumpToFileDecorator.hpp:25</a></div></div> -</div><!-- fragment --> -</div> -</div> -<a id="a0d64f99889b7ca80ab0f924c31a658c1"></a> -<h2 class="memtitle"><span class="permalink"><a href="#a0d64f99889b7ca80ab0f924c31a658c1">◆ </a></span>BOOST_AUTO_TEST_CASE() <span class="overload">[5/6]</span></h2> - -<div class="memitem"> -<div class="memproto"> - <table class="memname"> - <tr> - <td class="memname">BOOST_AUTO_TEST_CASE </td> - <td>(</td> - <td class="paramtype">DumpOutgoingInvalidFileIgnoreErrors </td> - <td class="paramname"></td><td>)</td> - <td></td> - </tr> - </table> -</div><div class="memdoc"> - -<p class="definition">Definition at line <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml#l00132">132</a> of file <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a>.</p> - -<p class="reference">References <a class="el" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK()</a>, <a class="el" href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">options</a>, and <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00053">ProfilingConnectionDumpToFileDecorator::WritePacket()</a>.</p> -<div class="fragment"><div class="line"><a name="l00133"></a><span class="lineno"> 133</span> {</div><div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  armnn::Runtime::CreationOptions::ExternalProfilingOptions <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a>;</div><div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  options.m_IncomingCaptureFile = <span class="stringliteral">""</span>;</div><div class="line"><a name="l00136"></a><span class="lineno"> 136</span>  options.m_OutgoingCaptureFile = <span class="stringliteral">"/"</span>;</div><div class="line"><a name="l00137"></a><span class="lineno"> 137</span> </div><div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  <a class="code" href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">ProfilingConnectionDumpToFileDecorator</a> decorator(std::make_unique<DummyProfilingConnection>(), options, <span class="keyword">true</span>);</div><div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  BOOST_CHECK_NO_THROW(decorator.WritePacket(g_DataPtr, g_DataLength));</div><div class="line"><a name="l00140"></a><span class="lineno"> 140</span> </div><div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  <span class="keywordtype">bool</span> success = decorator.WritePacket(g_DataPtr, g_DataLength);</div><div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a>(!success);</div><div class="line"><a name="l00143"></a><span class="lineno"> 143</span> }</div><div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a0c262ba6f6c189a2d092d127c1b7627b"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a></div><div class="ttdeci">BOOST_CHECK(profilingService.GetCurrentState()==ProfilingState::WaitingForAck)</div></div> -<div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a6560146509197f3e197d8d36f76c1347"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a></div><div class="ttdeci">armnn::Runtime::CreationOptions::ExternalProfilingOptions options</div><div class="ttdef"><b>Definition:</b> <a href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">FileOnlyProfilingDecoratorTests.cpp:45</a></div></div> -<div class="ttc" id="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator_xhtml"><div class="ttname"><a href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">armnn::profiling::ProfilingConnectionDumpToFileDecorator</a></div><div class="ttdef"><b>Definition:</b> <a href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml#l00025">ProfilingConnectionDumpToFileDecorator.hpp:25</a></div></div> -</div><!-- fragment --> -</div> -</div> -<a id="a6f0568d8e45cdbebfb96482e4141e591"></a> -<h2 class="memtitle"><span class="permalink"><a href="#a6f0568d8e45cdbebfb96482e4141e591">◆ </a></span>BOOST_AUTO_TEST_CASE() <span class="overload">[6/6]</span></h2> - -<div class="memitem"> -<div class="memproto"> - <table class="memname"> - <tr> - <td class="memname">BOOST_AUTO_TEST_CASE </td> - <td>(</td> - <td class="paramtype">DumpOutgoingValidFile </td> - <td class="paramname"></td><td>)</td> - <td></td> - </tr> - </table> -</div><div class="memdoc"> - -<p class="definition">Definition at line <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml#l00145">145</a> of file <a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp_source.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a>.</p> - -<p class="reference">References <a class="el" href="_profiler_tests_8cpp.xhtml#af7f71af5c6c124222dd1c42c5df892f4">BOOST_AUTO_TEST_SUITE_END()</a>, <a class="el" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK()</a>, <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00044">ProfilingConnectionDumpToFileDecorator::Close()</a>, <a class="el" href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">options</a>, and <a class="el" href="_profiling_connection_dump_to_file_decorator_8cpp_source.xhtml#l00053">ProfilingConnectionDumpToFileDecorator::WritePacket()</a>.</p> -<div class="fragment"><div class="line"><a name="l00146"></a><span class="lineno"> 146</span> {</div><div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  boost::filesystem::path fileName =</div><div class="line"><a name="l00148"></a><span class="lineno"> 148</span>  boost::filesystem::temp_directory_path() / boost::filesystem::unique_path();</div><div class="line"><a name="l00149"></a><span class="lineno"> 149</span> </div><div class="line"><a name="l00150"></a><span class="lineno"> 150</span>  armnn::Runtime::CreationOptions::ExternalProfilingOptions <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a>;</div><div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  options.m_IncomingCaptureFile = <span class="stringliteral">""</span>;</div><div class="line"><a name="l00152"></a><span class="lineno"> 152</span>  options.m_OutgoingCaptureFile = fileName.string();</div><div class="line"><a name="l00153"></a><span class="lineno"> 153</span> </div><div class="line"><a name="l00154"></a><span class="lineno"> 154</span>  <a class="code" href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">ProfilingConnectionDumpToFileDecorator</a> decorator(std::make_unique<DummyProfilingConnection>(), options, <span class="keyword">false</span>);</div><div class="line"><a name="l00155"></a><span class="lineno"> 155</span> </div><div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  <span class="keywordtype">bool</span> success = <span class="keyword">false</span>;</div><div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  BOOST_CHECK_NO_THROW(success = decorator.WritePacket(g_DataPtr, g_DataLength));</div><div class="line"><a name="l00158"></a><span class="lineno"> 158</span>  <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a>(success);</div><div class="line"><a name="l00159"></a><span class="lineno"> 159</span> </div><div class="line"><a name="l00160"></a><span class="lineno"> 160</span>  decorator.Close();</div><div class="line"><a name="l00161"></a><span class="lineno"> 161</span> </div><div class="line"><a name="l00162"></a><span class="lineno"> 162</span>  std::vector<char> data = ReadDumpFile(options.m_OutgoingCaptureFile);</div><div class="line"><a name="l00163"></a><span class="lineno"> 163</span> </div><div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  <span class="comment">// check if the data read back from the dump file matches the original</span></div><div class="line"><a name="l00165"></a><span class="lineno"> 165</span>  <span class="keywordtype">int</span> diff = std::strncmp(data.data(), g_Data.data(), g_DataLength);</div><div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  <a class="code" href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a>(diff == 0);</div><div class="line"><a name="l00167"></a><span class="lineno"> 167</span> }</div><div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a0c262ba6f6c189a2d092d127c1b7627b"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a0c262ba6f6c189a2d092d127c1b7627b">BOOST_CHECK</a></div><div class="ttdeci">BOOST_CHECK(profilingService.GetCurrentState()==ProfilingState::WaitingForAck)</div></div> -<div class="ttc" id="_file_only_profiling_decorator_tests_8cpp_xhtml_a6560146509197f3e197d8d36f76c1347"><div class="ttname"><a href="_file_only_profiling_decorator_tests_8cpp.xhtml#a6560146509197f3e197d8d36f76c1347">options</a></div><div class="ttdeci">armnn::Runtime::CreationOptions::ExternalProfilingOptions options</div><div class="ttdef"><b>Definition:</b> <a href="_file_only_profiling_decorator_tests_8cpp_source.xhtml#l00045">FileOnlyProfilingDecoratorTests.cpp:45</a></div></div> -<div class="ttc" id="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator_xhtml"><div class="ttname"><a href="classarmnn_1_1profiling_1_1_profiling_connection_dump_to_file_decorator.xhtml">armnn::profiling::ProfilingConnectionDumpToFileDecorator</a></div><div class="ttdef"><b>Definition:</b> <a href="_profiling_connection_dump_to_file_decorator_8hpp_source.xhtml#l00025">ProfilingConnectionDumpToFileDecorator.hpp:25</a></div></div> -</div><!-- fragment --> -</div> -</div> -</div><!-- contents --> -</div><!-- doc-content --> -<!-- start footer part --> -<div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> - <ul> - <li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.xhtml">src</a></li><li class="navelem"><a class="el" href="dir_637c692f14729569dd2eac0c18e2a54a.xhtml">profiling</a></li><li class="navelem"><a class="el" href="dir_6b1198f6e738611120ec65b09506d2f8.xhtml">test</a></li><li class="navelem"><a class="el" href="_profiling_connection_dump_to_file_decorator_tests_8cpp.xhtml">ProfilingConnectionDumpToFileDecoratorTests.cpp</a></li> - <li class="footer">Generated on Fri Mar 13 2020 16:09:15 for ArmNN by - <a href="http://www.doxygen.org/index.html"> - <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.13 </li> - </ul> -</div> -</body> -</html> |