From fec117039ece46cf7b163f4ec26e3fba6c2baa7b Mon Sep 17 00:00:00 2001 From: Ichthyostega Date: Fri, 29 Dec 2023 23:45:12 +0100 Subject: [PATCH] Scheduler-test: need this group aggregation as pipeline rather Yesterday I've written a simple loop-based implementation of a grouping aggregation to count the node weights per level. Unfortunately it turns out we'll use several flavours of this and we'd have to chain up postprocessing -- thus from a usage perspective it would be better to have the same functionality packaged as interator pipeline. This turns out to be surprisingly tricky and there is no suitable library function available, which means I'll have to write one myself. This changeset is the first step into this direction: reformulate the simple for-loop into a demand-driven grouping iterator --- tests/vault/gear/scheduler-stress-test.cpp | 18 +++-- tests/vault/gear/test-chain-load.hpp | 77 ++++++++++++++++++---- wiki/thinkPad.ichthyo.mm | 46 ++++++++++++- 3 files changed, 120 insertions(+), 21 deletions(-) diff --git a/tests/vault/gear/scheduler-stress-test.cpp b/tests/vault/gear/scheduler-stress-test.cpp index e0faf6a09..00119394f 100644 --- a/tests/vault/gear/scheduler-stress-test.cpp +++ b/tests/vault/gear/scheduler-stress-test.cpp @@ -161,10 +161,13 @@ SHOW_EXPR(micros); CHECK (micros < 550); CHECK (micros > 450); - auto levelWeights = testLoad.allLevelWeights(); + std::vector::Agg> levelWeights = testLoad.allNodes().processingLayer::WeightAggregator>().effuse(); SHOW_EXPR(levelWeights.size()) for (auto& w : levelWeights) - cout<<"level:"< - + @@ -107487,6 +107487,50 @@ Date:   Thu Apr 20 18:53:17 2023 +0200
+ + + + + + + + + + + + + + + + + + + +

+ weil die Invariante eben auch erfüllt ist, wenn man hinter dem Ende steht; insofern ist die Auswertung ja tatsächlich »schleppend«, d.h. man gibt immer die vorhergehende Gruppe aus +

+ + +
+
+
+ + + +
+ + + + + + + + + + + + +