Mixed-input Level Manager by Virtualization - #744
Conversation
0f76eec to
ef86c89
Compare
🟡 Regression Test (QBF 'hex/hein_08_5x5-11_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -0.75% (stdev: 0.48%).
Number of samples: 3 |
🟡 Regression Test (12-Queens)'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -1.16% (stdev: 0.92%).
Number of samples: 3 |
🟡 Regression Test (QBF 'breakthrough/3x4_19_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of 1.07% (stdev: 2.65%).
Number of samples: 3 |
🔴 Regression Test (Picotrav 'adder')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -2.77% (stdev: 0.53%).
Number of samples: 3 |
🟡 Regression Test (QBF 'ep_dual/8x8_6_e-8-1_p-2-3_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -0.22% (stdev: 0.36%).
Number of samples: 3 |
🟡 Regression Test (QBF 'breakthrough_dual/3x6_10_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of 0.92% (stdev: 0.76%).
Number of samples: 3 |
🟡 Regression Test (QBF 'connect4/6x6_11_connect4_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of 0.64% (stdev: 1.07%).
Number of samples: 3 |
🟡 Regression Test (QBF 'httt/4x4_9_tippy_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of 0.40% (stdev: 0.35%).
Number of samples: 3 |
🟡 Regression Test (QBF 'domineering/5x5_13_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -0.37% (stdev: 0.23%).
Number of samples: 3 |
🟡 Regression Test (QBF 'ep/8x8_7_e-8-1_p-3-4_bwnib')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of 0.36% (stdev: 0.61%).
Number of samples: 3 |
🟡 Regression Test (14-Queens)'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -0.02% (stdev: 1.01%).
Number of samples: 3 |
🟡 Regression Test (Picotrav 'mem_ctrl')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of 1.37% (stdev: 0.78%).
Number of samples: 3 |
🟡 Regression Test (Picotrav 'arbiter')'ssoelvsten/adiar/internal/virtual-level_merger' is a change in performance of -3.83% (stdev: 44.40%).
Number of samples: 9 |
ef86c89 to
f6e31ba
Compare
|
There are two things going on right now.
I'll proceed with reaping the benefits of this approach (see #727) and then take a look at parameter packs and |
e09be44 to
6d1c929
Compare
This was only used with the 'narc_ifstream' which is currently not used for anything (and neither planned for anything). Keeping this feature is (1) maintenance and (2) complicated with the virtualization of the 'level_merger'
It wasn't really used at all in any of the other places; it only made things more complicated for no discernable benefit.
Which is the only type of argument it is given.
There is no reason to repeat it at the higher levels (except possibly for documentation). Having it only at the basic streams still propagates the information without additional maintenance requirements.
6d1c929 to
b1a350b
Compare
|
There we go, #727 hacks in Intercut fully resolved. Now, only onto removing the virtual functions or fix the CI breaking with them. P.S. Also, thanks to Mathias Rav's hammer; the more I use it, the more I appreciate it. |
This new level merger provides us with the ability to use inputs of different types, e.g. a `levelized_file` and a `generator`. This will allow us to skip redundant (and expensive) temporary files in the Intercut operation that were only created to make the types match.
b1a350b to
8e1da29
Compare
This allows us to deal with sequential/random-access data that is stored in internal memory. For example, this could be a small list of levels (at most 2MiB) from a generator which needs to be read more than once, e.g. Intercut.
…nternal, T>' The 'tpie::internal_vector<T>' has a few pecularities and missing features. Most importantly, it does not support the ability to iterate through it in reverse. So, we'll just use the 'tpie::array<T>' directly.
8e1da29 to
b99bbde
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #744 +/- ##
=============================================
+ Coverage 97.089% 97.106% +0.017%
=============================================
Files 98 99 +1
Lines 7215 7257 +42
=============================================
+ Hits 7005 7047 +42
Misses 210 210 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Resolves #727 by making the input handlers for the
level_mergervirtual. Doing so provides us with the ability to have mixed inputs (files and/or generators). This is needed for #733 .In practice, we always know the type of each input handler at compile time, so we should be able to remove the use of virtual. Yet, this is a quick solution to unblock #733 . Assuming the CI benchmarking does not indicate this is too much of an issue, I'll defer the fully templated solution for later. Especially, if a student or group of students would like to take a look at #444 and #733 .
Otherwise, I'll postpone merging this until another refactor to include typename Inputs... in the templated
level_mergerto derive the individual handlers within it (probably via astd::tuple). For more details, see cppreference on parameter packing.