Browse Source

shorten one statement in the waitoncompletion nsd to make it slimmer and therefore easier to read

master
Constantin Fürst 11 months ago
parent
commit
b8ce6b3add
  1. 41
      thesis/images/structo-benchmark-compact.nsd.bak
  2. 32
      thesis/images/structo-cachedata-waitoncompletion.nsd
  3. BIN
      thesis/images/structo-cachedata-waitoncompletion.png

41
thesis/images/structo-benchmark-compact.nsd.bak

@ -1,41 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<root xmlns:nsd="https://structorizer.fisch.lu" version="3.32-15" preRepeat="until " postFor="to" preReturn="return" postForIn="in" preWhile="while " output="OUTPUT" input="INPUT" preFor="for" preExit="exit" preLeave="leave" ignoreCase="true" preThrow="throw" preForIn="foreach" stepFor="by" author="user" created="2024-01-18" changedby="user" changed="2024-01-21" origin="Structorizer 3.32-15" text="&#34;Benchmark(node, node_dst, node_src, size, mode)&#34;" comment="" color="ffffff" type="program" style="nice">
<children>
<instruction text="&#34;numa_run_on_node(node)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;src &#60;- numa_alloc_onnode(size, node_src)&#34;,&#34;dst &#60;- numa_alloc_onnode(size, node_dst)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;memset(src, 0x0, size)&#34;,&#34;memset(dst, 0x0, size)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;begin time total&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<for text="&#34;for amount of repetitions&#34;" comment="" counterVar="dummy_counter" startValue="amount of repetitions" stepConst="1" style="FREETEXT" color="ffffff" disabled="0">
<qFor>
<instruction text="&#34;synchronize with other threads&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<case text="&#34;mode&#34;,&#34;single submit&#34;,&#34;batch submit&#34;,&#34;%&#34;" comment="&#34;&#34;" color="ffffff" disabled="0">
<qCase>
<instruction text="&#34;begin time submit&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<instruction text="&#34;handler &#60;- dml::submit(dml::memcopy, src, dst, size)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;end time submit, begin time complete&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<instruction text="&#34;result &#60;- handler.get()&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;end time complete&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<instruction text="&#34;assert result.status == dml::ok&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qCase>
<qCase>
<instruction text="&#34;begin time submit&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<instruction text="&#34;sequence &#60;- dml::sequence(batchsize)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<for text="&#34;for batchsize&#34;" comment="" counterVar="dummy_counter" startValue="batchsize" stepConst="1" style="FREETEXT" color="ffffff" disabled="0">
<qFor>
<instruction text="&#34;sequence.add(dml::memcopy, src, dst, size)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qFor>
</for>
<instruction text="&#34;handler &#60;- dml::submit(dml::batch, sequence)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;end time submit, begin time complete&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<instruction text="&#34;result &#60;- handler.get()&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;end time complete&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
<instruction text="&#34;assert result.status == dml::ok&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qCase>
<qCase color="ffffff">
</qCase>
</case>
</qFor>
</for>
<instruction text="&#34;end time total&#34;" comment="" color="ffff80" rotated="0" disabled="0"></instruction>
</children>
</root>

32
thesis/images/structo-cachedata-waitoncompletion.nsd

@ -1,39 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<root xmlns:nsd="https://structorizer.fisch.lu" version="3.32-15" preRepeat="until " postFor="to" preReturn="return" postForIn="in" preWhile="while " output="OUTPUT" input="INPUT" preFor="for" preExit="exit" preLeave="leave" ignoreCase="true" preThrow="throw" preForIn="foreach" stepFor="by" namespace="" author="user" created="2024-01-18" changedby="user" changed="2024-01-18" origin="Structorizer 3.32-15" text="&#34;void CacheData::WaitOnCompletion()&#34;" comment="&#34;&#34;" color="ffffff" type="program" style="nice">
<root xmlns:nsd="https://structorizer.fisch.lu" version="3.32-15" preRepeat="until " postFor="to" preReturn="return" postForIn="in" preWhile="while " output="OUTPUT" input="INPUT" preFor="for" preExit="exit" preLeave="leave" ignoreCase="true" preThrow="throw" preForIn="foreach" stepFor="by" author="user" created="2024-01-18" changedby="user" changed="2024-01-22" origin="Structorizer 3.32-15" text="&#34;void CacheData::WaitOnCompletion()&#34;" comment="" color="ffffff" type="program" style="nice">
<children>
<alternative text="&#34;is cache valid (not nullptr)&#34;" comment="&#34;&#34;" color="ffffff" disabled="0">
<alternative text="&#34;is cache valid (not nullptr)&#34;" comment="" color="ffffff" disabled="0">
<qTrue>
<instruction text="&#34;return immediately&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;return&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
</qTrue>
<qFalse>
<while text="&#34;while handlers is not valid (equals nullptr)&#34;" comment="&#34;&#34;" color="ffffff" disabled="0">
<while text="&#34;while handlers is not valid (equals nullptr)&#34;" comment="" color="ffffff" disabled="0">
<qWhile>
<instruction text="&#34;handlers.wait()&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;handlers.wait()&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qWhile>
</while>
<instruction text="&#34;local_handlers &#60;- handlers.exchange(uint64::max)&#34;,&#34;handlers &#60;- uint64::max&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<alternative text="&#34;is local_handlers valid (not nullptr and not uint64::max)&#34;" comment="&#34;&#34;" color="ffffff" disabled="0">
<instruction text="&#34;local_handlers &#60;- handlers.exchange(uint64::max)&#34;,&#34;handlers &#60;- uint64::max&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<alternative text="&#34;is local_handlers valid (not nullptr and not uint64::max)&#34;" comment="" color="ffffff" disabled="0">
<qTrue>
<for text="&#34;foreach handler in local_handlers&#34;" comment="&#34;&#34;" counterVar="handler" startValue="" stepConst="" style="TRAVERSAL" insep="in" color="ffffff" disabled="0">
<for text="&#34;foreach handler in local_handlers&#34;" comment="" counterVar="handler" startValue="" stepConst="" style="TRAVERSAL" insep="in" color="ffffff" disabled="0">
<qFor>
<instruction text="&#34;status &#60;- handler.wait()&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;status &#60;- handler.wait()&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qFor>
</for>
<alternative text="&#34;status contains error&#34;" comment="&#34;&#34;" color="ffffff" disabled="0">
<alternative text="&#34;status contains error&#34;" comment="" color="ffffff" disabled="0">
<qTrue>
<instruction text="&#34;cache &#60;- source pointer&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;free(destination pointer)&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;cache &#60;- source pointer&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;free(destination pointer)&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qTrue>
<qFalse>
<instruction text="&#34;cache &#60;- destination pointer&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;cache &#60;- destination pointer&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qFalse>
</alternative>
<instruction text="&#34;signal threads waiting on cache or handlers&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;signal threads waiting on cache or handlers&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qTrue>
<qFalse>
<while text="&#34;while cache is not valid (equals nullptr)&#34;" comment="&#34;&#34;" color="ffffff" disabled="0">
<while text="&#34;while cache is not valid (equals nullptr)&#34;" comment="" color="ffffff" disabled="0">
<qWhile>
<instruction text="&#34;cache.wait()&#34;" comment="&#34;&#34;" color="ffffff" rotated="0" disabled="0"></instruction>
<instruction text="&#34;cache.wait()&#34;" comment="" color="ffffff" rotated="0" disabled="0"></instruction>
</qWhile>
</while>
</qFalse>

BIN
thesis/images/structo-cachedata-waitoncompletion.png

Before

Width: 739  |  Height: 511  |  Size: 46 KiB

After

Width: 667  |  Height: 511  |  Size: 45 KiB

Loading…
Cancel
Save