arm_compute v17.12
diff --git a/documentation/profiler_8hpp_source.xhtml b/documentation/profiler_8hpp_source.xhtml
index 0a7da75..536712d 100644
--- a/documentation/profiler_8hpp_source.xhtml
+++ b/documentation/profiler_8hpp_source.xhtml
@@ -4,7 +4,7 @@
<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.6"/>
+<meta name="generator" content="Doxygen 1.8.11"/>
<meta name="robots" content="NOINDEX, NOFOLLOW" /> <!-- Prevent indexing by search engines -->
<title>Compute Library: arm_compute/core/NEON/kernels/assembly/profiler.hpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
@@ -12,22 +12,24 @@
<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);
$(window).load(resizeHeight);
</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/javascript">
- $(document).ready(function() { searchBox.OnSelectItem(0); });
+ $(document).ready(function() { init_search(); });
</script>
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
extensions: ["tex2jax.js"],
jax: ["input/TeX","output/HTML-CSS"],
});
-</script><script src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
+</script><script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
@@ -38,7 +40,7 @@
<tr style="height: 56px;">
<td style="padding-left: 0.5em;">
<div id="projectname">Compute Library
-  <span id="projectnumber">17.10</span>
+  <span id="projectnumber">17.12</span>
</div>
</td>
</tr>
@@ -46,7 +48,7 @@
</table>
</div>
<!-- end header part -->
-<!-- Generated by Doxygen 1.8.6 -->
+<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
@@ -101,7 +103,7 @@
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
-<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark"> </span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark"> </span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark"> </span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark"> </span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark"> </span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(10)"><span class="SelectionMark"> </span>Macros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(11)"><span class="SelectionMark"> </span>Pages</a></div>
+</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
@@ -115,114 +117,17 @@
<div class="title">profiler.hpp</div> </div>
</div><!--header-->
<div class="contents">
-<a href="profiler_8hpp.xhtml">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">/*</span></div>
-<div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment"> * Copyright (c) 2017 ARM Limited.</span></div>
-<div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> *</span></div>
-<div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> * SPDX-License-Identifier: MIT</span></div>
-<div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"> *</span></div>
-<div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> * Permission is hereby granted, free of charge, to any person obtaining a copy</span></div>
-<div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> * of this software and associated documentation files (the "Software"), to</span></div>
-<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"> * deal in the Software without restriction, including without limitation the</span></div>
-<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"> * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or</span></div>
-<div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> * sell copies of the Software, and to permit persons to whom the Software is</span></div>
-<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment"> * furnished to do so, subject to the following conditions:</span></div>
-<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment"> *</span></div>
-<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="comment"> * The above copyright notice and this permission notice shall be included in all</span></div>
-<div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="comment"> * copies or substantial portions of the Software.</span></div>
-<div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="comment"> *</span></div>
-<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment"> * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR</span></div>
-<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment"> * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,</span></div>
-<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment"> * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE</span></div>
-<div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="comment"> * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER</span></div>
-<div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="comment"> * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,</span></div>
-<div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="comment"> * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE</span></div>
-<div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="comment"> * SOFTWARE.</span></div>
-<div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="comment"> */</span></div>
-<div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="preprocessor">#pragma once</span></div>
-<div class="line"><a name="l00025"></a><span class="lineno"> 25</span> <span class="preprocessor"></span></div>
-<div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="preprocessor">#ifdef CYCLE_PROFILING</span></div>
-<div class="line"><a name="l00027"></a><span class="lineno"> 27</span> <span class="preprocessor"></span></div>
-<div class="line"><a name="l00028"></a><span class="lineno"> 28</span> <span class="preprocessor">#include "../perf.h"</span></div>
-<div class="line"><a name="l00029"></a><span class="lineno"> 29</span> </div>
-<div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="keyword">class </span><a class="code" href="classprofiler.xhtml">profiler</a> {</div>
-<div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="keyword">private</span>:</div>
-<div class="line"><a name="l00032"></a><span class="lineno"> 32</span>  <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">int</span> maxevents = 10000;</div>
-<div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> times[maxevents];</div>
-<div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  <span class="keywordtype">int</span> events[maxevents];</div>
-<div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  <span class="keywordtype">int</span> currentevent;</div>
-<div class="line"><a name="l00036"></a><span class="lineno"> 36</span>  <span class="keywordtype">int</span> countfd;</div>
-<div class="line"><a name="l00037"></a><span class="lineno"> 37</span> </div>
-<div class="line"><a name="l00038"></a><span class="lineno"> 38</span> <span class="keyword">public</span>:</div>
-<div class="line"><a name="l00039"></a><span class="lineno"> 39</span>  <a class="code" href="classprofiler.xhtml">profiler</a>() {</div>
-<div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  currentevent=0;</div>
-<div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  countfd=open_cycle_counter();</div>
-<div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  }</div>
-<div class="line"><a name="l00043"></a><span class="lineno"> 43</span> </div>
-<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>  ~<a class="code" href="classprofiler.xhtml">profiler</a>() {</div>
-<div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  close(countfd);</div>
-<div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="keywordtype">int</span> tots[5];</div>
-<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> counts[5];</div>
-<div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  <span class="keyword">const</span> <span class="keywordtype">char</span> * descs[] = { <span class="stringliteral">"Prepare A"</span>, <span class="stringliteral">"Prepare B"</span>, <span class="stringliteral">"Kernel"</span>, <span class="stringliteral">"Merge"</span> };</div>
-<div class="line"><a name="l00049"></a><span class="lineno"> 49</span> </div>
-<div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=1; i<5; i++) {</div>
-<div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  tots[i] = 0;</div>
-<div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  counts[i] = 0;</div>
-<div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  }</div>
-<div class="line"><a name="l00054"></a><span class="lineno"> 54</span> </div>
-<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  printf(<span class="stringliteral">"Profiled events:\n"</span>);</div>
-<div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=0; i<currentevent; i++) {</div>
-<div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  printf(<span class="stringliteral">"%10s: %ld\n"</span>, descs[events[i]-1], times[i]);</div>
-<div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  tots[events[i]]++;</div>
-<div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  counts[events[i]] += times[i];</div>
-<div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  }</div>
-<div class="line"><a name="l00061"></a><span class="lineno"> 61</span> </div>
-<div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  printf(<span class="stringliteral">"%20s %9s %9s %9s\n"</span>, <span class="stringliteral">""</span>, <span class="stringliteral">"Events"</span>, <span class="stringliteral">"Total"</span>, <span class="stringliteral">"Average"</span>);</div>
-<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=1; i<5; i++) {</div>
-<div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  printf(<span class="stringliteral">"%20s: %9d %9ld %9ld\n"</span>,descs[i-1],tots[i],counts[i],counts[i]/tots[i]);</div>
-<div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  }</div>
-<div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  }</div>
-<div class="line"><a name="l00067"></a><span class="lineno"> 67</span> </div>
-<div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  <span class="keyword">template</span> <<span class="keyword">typename</span> T></div>
-<div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  <span class="keywordtype">void</span> <a class="code" href="classprofiler.xhtml#a3868e59275c661b8b9f792f2d4ba1b7e">operator() </a>(<span class="keywordtype">int</span> i, T func) {</div>
-<div class="line"><a name="l00070"></a><span class="lineno"> 70</span>  <span class="keywordflow">if</span> (currentevent==maxevents) {</div>
-<div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  func();</div>
-<div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  } <span class="keywordflow">else</span> {</div>
-<div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  start_counter(countfd);</div>
-<div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  func();</div>
-<div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  <span class="keywordtype">long</span> <span class="keywordtype">long</span> cycs = stop_counter(countfd);</div>
-<div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  events[currentevent] = i;</div>
-<div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  times[currentevent++] = cycs;</div>
-<div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  }</div>
-<div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  }</div>
-<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> </div>
-<div class="line"><a name="l00082"></a><span class="lineno"> 82</span> <span class="preprocessor">#else</span></div>
-<div class="line"><a name="l00083"></a><span class="lineno"> 83</span> <span class="preprocessor"></span></div>
-<div class="line"><a name="l00084"></a><span class="lineno"><a class="line" href="classprofiler.xhtml"> 84</a></span> <span class="keyword">class </span><a class="code" href="classprofiler.xhtml">profiler</a> {</div>
-<div class="line"><a name="l00085"></a><span class="lineno"> 85</span> <span class="keyword">public</span>:</div>
-<div class="line"><a name="l00086"></a><span class="lineno"> 86</span>  <span class="keyword">template</span> <<span class="keyword">typename</span> T></div>
-<div class="line"><a name="l00087"></a><span class="lineno"><a class="line" href="classprofiler.xhtml#a3868e59275c661b8b9f792f2d4ba1b7e"> 87</a></span>  <span class="keywordtype">void</span> <a class="code" href="classprofiler.xhtml#a3868e59275c661b8b9f792f2d4ba1b7e">operator() </a>(<span class="keywordtype">int</span> i, T func) {</div>
-<div class="line"><a name="l00088"></a><span class="lineno"> 88</span>  func();</div>
-<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> };</div>
-<div class="line"><a name="l00091"></a><span class="lineno"> 91</span> </div>
-<div class="line"><a name="l00092"></a><span class="lineno"> 92</span> <span class="preprocessor">#endif</span></div>
-<div class="line"><a name="l00093"></a><span class="lineno"> 93</span> <span class="preprocessor"></span></div>
-<div class="line"><a name="l00094"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#ac19bf2c5c388b9fb21cd0668475b2cf7"> 94</a></span> <span class="preprocessor">#define PROFILE_PREPA 1</span></div>
-<div class="line"><a name="l00095"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#af0477dfaa86fc08825cb3f31212f423c"> 95</a></span> <span class="preprocessor"></span><span class="preprocessor">#define PROFILE_PREPB 2</span></div>
-<div class="line"><a name="l00096"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#a97f4e398174b5e094f5262e5d785ac20"> 96</a></span> <span class="preprocessor"></span><span class="preprocessor">#define PROFILE_KERNEL 3</span></div>
-<div class="line"><a name="l00097"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#a2f7c3e65a9ccab509d7776832f562dd0"> 97</a></span> <span class="preprocessor"></span><span class="preprocessor">#define PROFILE_MERGE 4</span></div>
-<div class="ttc" id="classprofiler_xhtml_a3868e59275c661b8b9f792f2d4ba1b7e"><div class="ttname"><a href="classprofiler.xhtml#a3868e59275c661b8b9f792f2d4ba1b7e">profiler::operator()</a></div><div class="ttdeci">void operator()(int i, T func)</div><div class="ttdef"><b>Definition:</b> <a href="profiler_8hpp_source.xhtml#l00087">profiler.hpp:87</a></div></div>
-<div class="ttc" id="classprofiler_xhtml"><div class="ttname"><a href="classprofiler.xhtml">profiler</a></div><div class="ttdef"><b>Definition:</b> <a href="profiler_8hpp_source.xhtml#l00084">profiler.hpp:84</a></div></div>
+<a href="profiler_8hpp.xhtml">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">/*</span></div><div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment"> * Copyright (c) 2017 ARM Limited.</span></div><div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> *</span></div><div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> * SPDX-License-Identifier: MIT</span></div><div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"> *</span></div><div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> * Permission is hereby granted, free of charge, to any person obtaining a copy</span></div><div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> * of this software and associated documentation files (the "Software"), to</span></div><div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"> * deal in the Software without restriction, including without limitation the</span></div><div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"> * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or</span></div><div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> * sell copies of the Software, and to permit persons to whom the Software is</span></div><div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment"> * furnished to do so, subject to the following conditions:</span></div><div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment"> *</span></div><div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="comment"> * The above copyright notice and this permission notice shall be included in all</span></div><div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="comment"> * copies or substantial portions of the Software.</span></div><div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="comment"> *</span></div><div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment"> * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR</span></div><div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment"> * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,</span></div><div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment"> * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE</span></div><div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="comment"> * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER</span></div><div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="comment"> * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,</span></div><div class="line"><a name="l00021"></a><span class="lineno"> 21</span> <span class="comment"> * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE</span></div><div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="comment"> * SOFTWARE.</span></div><div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="comment"> */</span></div><div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="preprocessor">#pragma once</span></div><div class="line"><a name="l00025"></a><span class="lineno"> 25</span> </div><div class="line"><a name="l00026"></a><span class="lineno"> 26</span> <span class="preprocessor">#ifdef CYCLE_PROFILING</span></div><div class="line"><a name="l00027"></a><span class="lineno"> 27</span> </div><div class="line"><a name="l00028"></a><span class="lineno"> 28</span> <span class="preprocessor">#include "../perf.h"</span></div><div class="line"><a name="l00029"></a><span class="lineno"> 29</span> </div><div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="keyword">class </span><a class="code" href="classprofiler.xhtml">profiler</a> {</div><div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="keyword">private</span>:</div><div class="line"><a name="l00032"></a><span class="lineno"> 32</span>  <span class="keyword">static</span> <span class="keyword">const</span> <span class="keywordtype">int</span> maxevents = 10000;</div><div class="line"><a name="l00033"></a><span class="lineno"> 33</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> times[maxevents];</div><div class="line"><a name="l00034"></a><span class="lineno"> 34</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> units[maxevents];</div><div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  <span class="keywordtype">int</span> events[maxevents];</div><div class="line"><a name="l00036"></a><span class="lineno"> 36</span>  <span class="keywordtype">int</span> currentevent;</div><div class="line"><a name="l00037"></a><span class="lineno"> 37</span>  <span class="keywordtype">int</span> countfd;</div><div class="line"><a name="l00038"></a><span class="lineno"> 38</span> </div><div class="line"><a name="l00039"></a><span class="lineno"> 39</span> <span class="keyword">public</span>:</div><div class="line"><a name="l00040"></a><span class="lineno"> 40</span>  <a class="code" href="classprofiler.xhtml">profiler</a>() {</div><div class="line"><a name="l00041"></a><span class="lineno"> 41</span>  currentevent=0;</div><div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  countfd=open_cycle_counter();</div><div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  }</div><div class="line"><a name="l00044"></a><span class="lineno"> 44</span> </div><div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  ~<a class="code" href="classprofiler.xhtml">profiler</a>() {</div><div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  close(countfd);</div><div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  <span class="keywordtype">int</span> tots[5];</div><div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> counts[5];</div><div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> tunits[5];</div><div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  <span class="keyword">const</span> <span class="keywordtype">char</span> * descs[] = { <span class="stringliteral">"Prepare A"</span>, <span class="stringliteral">"Prepare B"</span>, <span class="stringliteral">"Kernel"</span>, <span class="stringliteral">"Merge"</span> };</div><div class="line"><a name="l00051"></a><span class="lineno"> 51</span> </div><div class="line"><a name="l00052"></a><span class="lineno"> 52</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=1; i<5; i++) {</div><div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  tots[i] = 0;</div><div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  counts[i] = 0;</div><div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  tunits[i] = 0;</div><div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  }</div><div class="line"><a name="l00057"></a><span class="lineno"> 57</span> </div><div class="line"><a name="l00058"></a><span class="lineno"> 58</span>  printf(<span class="stringliteral">"Profiled events:\n"</span>);</div><div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=0; i<currentevent; i++) {</div><div class="line"><a name="l00060"></a><span class="lineno"> 60</span>  tots[events[i]]++;</div><div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  counts[events[i]] += times[i];</div><div class="line"><a name="l00062"></a><span class="lineno"> 62</span>  tunits[events[i]] += units[i];</div><div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  }</div><div class="line"><a name="l00064"></a><span class="lineno"> 64</span> </div><div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  printf(<span class="stringliteral">"%20s %9s %9s %9s %12s %9s\n"</span>, <span class="stringliteral">""</span>, <span class="stringliteral">"Events"</span>, <span class="stringliteral">"Total"</span>, <span class="stringliteral">"Average"</span>, <span class="stringliteral">"Bytes/MACs"</span>, <span class="stringliteral">"Per cycle"</span>);</div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span>  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i=1; i<5; i++) {</div><div class="line"><a name="l00067"></a><span class="lineno"> 67</span>  printf(<span class="stringliteral">"%20s: %9d %9ld %9ld %12lu %9.2f\n"</span>,descs[i-1],tots[i],counts[i],counts[i]/tots[i],tunits[i],(<span class="keywordtype">float</span>)tunits[i]/counts[i]);</div><div class="line"><a name="l00068"></a><span class="lineno"> 68</span>  }</div><div class="line"><a name="l00069"></a><span class="lineno"> 69</span>  }</div><div class="line"><a name="l00070"></a><span class="lineno"> 70</span> </div><div class="line"><a name="l00071"></a><span class="lineno"> 71</span>  <span class="keyword">template</span> <<span class="keyword">typename</span> T></div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  <span class="keywordtype">void</span> <a class="code" href="classprofiler.xhtml#a476c76bd4727dddfd06bdd7e3c9b81c0">operator() </a>(<span class="keywordtype">int</span> i, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> u, T func) {</div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  <span class="keywordflow">if</span> (currentevent==maxevents) {</div><div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  func();</div><div class="line"><a name="l00075"></a><span class="lineno"> 75</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00076"></a><span class="lineno"> 76</span>  events[currentevent] = i;</div><div class="line"><a name="l00077"></a><span class="lineno"> 77</span>  units[currentevent] = u;</div><div class="line"><a name="l00078"></a><span class="lineno"> 78</span>  start_counter(countfd);</div><div class="line"><a name="l00079"></a><span class="lineno"> 79</span>  func();</div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  <span class="keywordtype">long</span> <span class="keywordtype">long</span> cycs = stop_counter(countfd);</div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  times[currentevent++] = cycs;</div><div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  }</div><div class="line"><a name="l00083"></a><span class="lineno"> 83</span>  }</div><div class="line"><a name="l00084"></a><span class="lineno"> 84</span> };</div><div class="line"><a name="l00085"></a><span class="lineno"> 85</span> </div><div class="line"><a name="l00086"></a><span class="lineno"> 86</span> <span class="preprocessor">#else</span></div><div class="line"><a name="l00087"></a><span class="lineno"> 87</span> </div><div class="line"><a name="l00088"></a><span class="lineno"><a class="line" href="classprofiler.xhtml"> 88</a></span> <span class="keyword">class </span><a class="code" href="classprofiler.xhtml">profiler</a> {</div><div class="line"><a name="l00089"></a><span class="lineno"> 89</span> <span class="keyword">public</span>:</div><div class="line"><a name="l00090"></a><span class="lineno"> 90</span>  <span class="keyword">template</span> <<span class="keyword">typename</span> T></div><div class="line"><a name="l00091"></a><span class="lineno"><a class="line" href="classprofiler.xhtml#a476c76bd4727dddfd06bdd7e3c9b81c0"> 91</a></span>  <span class="keywordtype">void</span> <a class="code" href="classprofiler.xhtml#a476c76bd4727dddfd06bdd7e3c9b81c0">operator() </a>(<span class="keywordtype">int</span> i, <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> u, T func) {</div><div class="line"><a name="l00092"></a><span class="lineno"> 92</span>  func();</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  }</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span> };</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span> </div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span> <span class="preprocessor">#endif</span></div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span> </div><div class="line"><a name="l00098"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#ac19bf2c5c388b9fb21cd0668475b2cf7"> 98</a></span> <span class="preprocessor">#define PROFILE_PREPA 1</span></div><div class="line"><a name="l00099"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#af0477dfaa86fc08825cb3f31212f423c"> 99</a></span> <span class="preprocessor">#define PROFILE_PREPB 2</span></div><div class="line"><a name="l00100"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#a97f4e398174b5e094f5262e5d785ac20"> 100</a></span> <span class="preprocessor">#define PROFILE_KERNEL 3</span></div><div class="line"><a name="l00101"></a><span class="lineno"><a class="line" href="profiler_8hpp.xhtml#a2f7c3e65a9ccab509d7776832f562dd0"> 101</a></span> <span class="preprocessor">#define PROFILE_MERGE 4</span></div><div class="line"><a name="l00102"></a><span class="lineno"> 102</span> </div><div class="line"><a name="l00103"></a><span class="lineno"> 103</span> </div><div class="ttc" id="classprofiler_xhtml_a476c76bd4727dddfd06bdd7e3c9b81c0"><div class="ttname"><a href="classprofiler.xhtml#a476c76bd4727dddfd06bdd7e3c9b81c0">profiler::operator()</a></div><div class="ttdeci">void operator()(int i, unsigned long u, T func)</div><div class="ttdef"><b>Definition:</b> <a href="profiler_8hpp_source.xhtml#l00091">profiler.hpp:91</a></div></div>
+<div class="ttc" id="classprofiler_xhtml"><div class="ttname"><a href="classprofiler.xhtml">profiler</a></div><div class="ttdef"><b>Definition:</b> <a href="profiler_8hpp_source.xhtml#l00088">profiler.hpp:88</a></div></div>
</div><!-- fragment --></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_d4d363c0979c7ffda4833df3f93b5668.xhtml">arm_compute</a></li><li class="navelem"><a class="el" href="dir_62e76289bb143101bef0ade0babfd908.xhtml">core</a></li><li class="navelem"><a class="el" href="dir_d8c3c94d7afca7dbbf0a57378fc2eb81.xhtml">NEON</a></li><li class="navelem"><a class="el" href="dir_fe359af270243e26066d9edb7147ece2.xhtml">kernels</a></li><li class="navelem"><a class="el" href="dir_de5c25a0a26af4ac1cdfe0fae1db6671.xhtml">assembly</a></li><li class="navelem"><a class="el" href="profiler_8hpp.xhtml">profiler.hpp</a></li>
- <li class="footer">Generated on Thu Oct 12 2017 14:26:32 for Compute Library by
+ <li class="navelem"><a class="el" href="dir_214608ef36d61442cb2b0c1c4e9a7def.xhtml">arm_compute</a></li><li class="navelem"><a class="el" href="dir_1fb090f0c6070330bfaccc4236d3ca0d.xhtml">core</a></li><li class="navelem"><a class="el" href="dir_315f6cf1ec0b2df3ae747ff8286a19f5.xhtml">NEON</a></li><li class="navelem"><a class="el" href="dir_2c3c4cb85e732569e2614ad40a451d53.xhtml">kernels</a></li><li class="navelem"><a class="el" href="dir_1528feb24a69b98c734f0fefcf3a82e1.xhtml">assembly</a></li><li class="navelem"><a class="el" href="profiler_8hpp.xhtml">profiler.hpp</a></li>
+ <li class="footer">Generated on Thu Dec 14 2017 23:48:30 for Compute Library by
<a href="http://www.doxygen.org/index.html">
- <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.6 </li>
+ <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.11 </li>
</ul>
</div>
</body>