Scheduler: investigate modes of operation
- analysis of Activity usage - derive possible memory management schemes - research regarding asynchronous IO - decision regarding the memory management scheme
This commit is contained in:
parent
4176576db0
commit
23a6fbdf4f
22 changed files with 1301 additions and 45 deletions
|
|
@ -28,9 +28,9 @@
|
|||
** can be passed to the scheduler's messaging queue to cause the described
|
||||
** activities to be performed in the context of the Lumiera render engine.
|
||||
**
|
||||
** @note this is a wild fantasy
|
||||
** @see ////TODO_test usage example
|
||||
** @see scheduler.cpp implementation
|
||||
** @warning mostly this is planned functionality
|
||||
** @see SchedulerActivity_test
|
||||
** @see activity.hpp definition of verbs
|
||||
**
|
||||
** @todo WIP-WIP-WIP 6/2023 »Playback Vertical Slice«
|
||||
**
|
||||
|
|
@ -42,6 +42,7 @@
|
|||
|
||||
|
||||
#include "vault/gear/activity.hpp"
|
||||
#include "vault/gear/block-flow.hpp"
|
||||
//#include "lib/symbol.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
|
|
@ -56,19 +57,19 @@ namespace gear {
|
|||
|
||||
|
||||
/**
|
||||
* Basic (abstracted) view of...
|
||||
* TODO write type comment...
|
||||
*
|
||||
* @see SomeSystem
|
||||
* @see NA_test
|
||||
* @see Activity
|
||||
* @see SchedulerActivity_test
|
||||
*/
|
||||
class ActivityLang
|
||||
{
|
||||
string nothing_;
|
||||
BlockFlow& mem_;
|
||||
|
||||
public:
|
||||
// explicit
|
||||
ActivityLang ()
|
||||
: nothing_(b)
|
||||
ActivityLang (BlockFlow& memManager)
|
||||
: mem_{memManager}
|
||||
{ }
|
||||
|
||||
// using default copy/assignment
|
||||
|
|
|
|||
|
|
@ -38,8 +38,9 @@
|
|||
**
|
||||
** @note currently this rather marks the intended memory management pattern,
|
||||
** while the actual allocations are still performed on the heap.
|
||||
** @see ////TODO_test usage example
|
||||
** @see scheduler.cpp implementation
|
||||
** @see BlockFlow_test
|
||||
** @see SchedulerUsage_test
|
||||
** @see extent-family.hpp underlying allocation scheme
|
||||
**
|
||||
** @todo WIP-WIP-WIP 6/2023 »Playback Vertical Slice«
|
||||
**
|
||||
|
|
@ -68,8 +69,8 @@ namespace gear {
|
|||
/**
|
||||
* Basic (abstracted) view of...
|
||||
*
|
||||
* @see SomeSystem
|
||||
* @see NA_test
|
||||
* @see SchedulerCommutator
|
||||
* @see BlockFlow_test
|
||||
*/
|
||||
class BlockFlow
|
||||
: util::NonCopyable
|
||||
|
|
|
|||
|
|
@ -25,8 +25,8 @@
|
|||
** Layer-2 of the Scheduler: coordination and interaction of activities.
|
||||
** This is the upper layer of the implementation and provides high-level functionality.
|
||||
**
|
||||
** @see ////TODO_test usage example
|
||||
** @see scheduler.cpp implementation
|
||||
** @see SchedulerCommutator_test
|
||||
** @see scheduler.hpp usage
|
||||
**
|
||||
** @todo WIP-WIP-WIP 6/2023 »Playback Vertical Slice«
|
||||
**
|
||||
|
|
@ -56,8 +56,8 @@ namespace gear {
|
|||
/**
|
||||
* Scheduler Layer-2 : coordination.
|
||||
*
|
||||
* @see SomeSystem
|
||||
* @see NA_test
|
||||
* @see SchedulerInvocation (Layer-1)
|
||||
* @see SchedulerCommutator_test
|
||||
*/
|
||||
class SchedulerCommutator
|
||||
: util::NonCopyable
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@
|
|||
** Scheduler service access point for higher layers.
|
||||
** @todo WIP unfinished since 9/2013
|
||||
** @warning as of 4/2023 Render-Engine integration work is underway ////////////////////////////////////////TICKET #1280
|
||||
** @deprecated as of 7/2023 the scheduler API will likely draw upon the ActivityLang
|
||||
**
|
||||
*/
|
||||
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@
|
|||
** Layer-1 of the Scheduler: dispatch and invocation of activities.
|
||||
** This is the lower layer of the implementation and provides low-level functionality.
|
||||
**
|
||||
** @note as of X/2023 this is complete bs
|
||||
** @see ////TODO_test usage example
|
||||
** @see scheduler.cpp implementation
|
||||
** @see SchedulerInvocation_test
|
||||
** @see SchedulerUsage_test integrated usage
|
||||
** @see scheduler.cpp implementation details
|
||||
**
|
||||
** @todo WIP-WIP-WIP 6/2023 »Playback Vertical Slice«
|
||||
**
|
||||
|
|
|
|||
|
|
@ -28,8 +28,10 @@
|
|||
** - Layer-1 allows to enqueue and prioritise render activity records
|
||||
** - Layer-2 connects and coordinates activities to conduct complex calculations
|
||||
**
|
||||
** @see ////TODO_test usage example
|
||||
** @see scheduler.cpp implementation
|
||||
** @see SchedulerUsage_test Component integration test
|
||||
** @see scheduler.cpp implementation details
|
||||
** @see SchedulerInvocation Layer-1
|
||||
** @see SchedulerCommutator Layer-2
|
||||
**
|
||||
** @todo WIP-WIP-WIP 6/2023 »Playback Vertical Slice«
|
||||
**
|
||||
|
|
@ -61,8 +63,8 @@ namespace gear {
|
|||
/**
|
||||
* Schedule and coordinate render activities.
|
||||
* @todo WIP-WIP 6/2023
|
||||
* @see SomeSystem
|
||||
* @see NA_test
|
||||
* @see BlockFlow
|
||||
* @see SchedulerUsage_test
|
||||
*/
|
||||
class Scheduler
|
||||
{
|
||||
|
|
|
|||
80
src/vault/mem/extent-family.hpp
Normal file
80
src/vault/mem/extent-family.hpp
Normal file
|
|
@ -0,0 +1,80 @@
|
|||
/*
|
||||
EXTENT-FAMILY.hpp - maintain a sequence of memory extents used cyclically
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
*/
|
||||
|
||||
|
||||
/** @file extent-family.hpp
|
||||
** Memory management scheme for cyclically used memory extents.
|
||||
** In this context, _Extent_ denotes a larger block of memory to hold a
|
||||
** cluster of smaller records, which are closely interrelated and will be managed
|
||||
** and de-allocated together. The typical usage involves a constant demand for further
|
||||
** memory, with is satisfied by putting further unused extents into use; older extents
|
||||
** will fall out of use eventually, and can then be placed back into a buffer of free
|
||||
** extents. In accordance to overall demand, this reserve buffer can be scaled up
|
||||
** and down to avoid holding larger amounts of unused memory, while the availability
|
||||
** of a baseline amount of memory can be enforced.
|
||||
**
|
||||
** @see ////TODO_test usage example
|
||||
** @see gear::BlockFlow usage example
|
||||
**
|
||||
** @todo WIP-WIP-WIP 7/2023 »Playback Vertical Slice«
|
||||
**
|
||||
*/
|
||||
|
||||
|
||||
#ifndef SRC_VAULT_MEM_EXTENT_FAMILY_H_
|
||||
#define SRC_VAULT_MEM_EXTENT_FAMILY_H_
|
||||
|
||||
|
||||
#include "vault/common.hpp"
|
||||
//#include "lib/symbol.hpp"
|
||||
#include "lib/nocopy.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <string>
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
|
||||
// using util::isnil;
|
||||
// using std::string;
|
||||
|
||||
|
||||
/**
|
||||
* Memory manager to provide a sequence of Extents for cyclic usage.
|
||||
* @todo WIP-WIP 7/2023
|
||||
* @see NA_test
|
||||
*/
|
||||
class ExtentFamily
|
||||
: util::NonCopyable
|
||||
{
|
||||
|
||||
public:
|
||||
explicit
|
||||
ExtentFamily()
|
||||
{ }
|
||||
};
|
||||
|
||||
|
||||
|
||||
}} // namespace vault::mem
|
||||
#endif /*SRC_VAULT_MEM_EXTENT_FAMILY_H_*/
|
||||
7
tests/11vault-memory.tests
Normal file
7
tests/11vault-memory.tests
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
TESTING "Low-level Test Suite: Memory Management" ./test-suite --group=memory
|
||||
|
||||
|
||||
|
||||
PLANNED "Cyclic Extent Sequence" ExtentFamily_test <<END
|
||||
return: 0
|
||||
END
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
TESTING "Scheduler"
|
||||
|
||||
PLANNED "high pri ticks"
|
||||
PLANNED "high pri, time ran out"
|
||||
PLANNED "high pri, cancel task"
|
||||
|
||||
PLANNED "low pri ticks"
|
||||
PLANNED "low pri, time ran out"
|
||||
PLANNED "low pri, cancel task"
|
||||
|
||||
PLANNED "change priority low->high"
|
||||
|
||||
|
||||
31
tests/32scheduler.tests
Normal file
31
tests/32scheduler.tests
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
TESTING "Component Test Suite: Scheduler" ./test-suite --group=engine
|
||||
|
||||
|
||||
|
||||
PLANNED "BlockFlow memory management scheme" BlockFlow_test <<END
|
||||
return: 0
|
||||
END
|
||||
|
||||
|
||||
|
||||
PLANNED "Scheduler Activity Language" SchedulerActivity_test <<END
|
||||
return: 0
|
||||
END
|
||||
|
||||
|
||||
|
||||
PLANNED "Scheduler Layer-1" SchedulerInvocation_test <<END
|
||||
return: 0
|
||||
END
|
||||
|
||||
|
||||
|
||||
PLANNED "Scheduler Layer-2" SchedulerCommutator_test <<END
|
||||
return: 0
|
||||
END
|
||||
|
||||
|
||||
|
||||
PLANNED "Scheduler Integration" SchedulerUsage_test <<END
|
||||
return: 0
|
||||
END
|
||||
5
tests/core/vault/_WARNING_OBSOLETE_
Normal file
5
tests/core/vault/_WARNING_OBSOLETE_
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
WARNING: This directory is a left-over from the early stages of the Lumiera project.
|
||||
It holds a test, which logically belongs into the vault-layer, yet must be linked
|
||||
against the steam-layer to use a 'Testclip' from the session.
|
||||
|
||||
Once file and output handling is actually designed and settled, this should be sorted out
|
||||
|
|
@ -22,6 +22,10 @@
|
|||
|
||||
/** @file media-access-mock-test.cpp
|
||||
** unit test \ref MediaAccessMock_test
|
||||
**
|
||||
** @todo this test must be linked against the Core (including Steam),
|
||||
** yet conceptually it belongs into the Vault, indicating a design mismatch.
|
||||
** The test support facility drafted here was not used much since then.
|
||||
*/
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -26,6 +26,10 @@
|
|||
** or even to feed generated media content into the code to be tested.
|
||||
**
|
||||
** @todo this facility was occasionally used until 2011, yet never really completed
|
||||
** @todo the implementation is linked against steam-layer to use a constant definition
|
||||
** from 'steam/mobject/session/testclip.hpp' — which highlights an conceptual
|
||||
** ambiguity underlying this whole concept; at inception time, there was no
|
||||
** clear notion pertaining the kind of structures related to the vault.
|
||||
*/
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
backend testsuite
|
||||
vault-layer testsuite
|
||||
|
|
|
|||
102
tests/vault/gear/block-flow-test.cpp
Normal file
102
tests/vault/gear/block-flow-test.cpp
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
/*
|
||||
BlockFlow(Test) - verify scheduler memory management scheme
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
* *****************************************************/
|
||||
|
||||
/** @file block-flow-test.cpp
|
||||
** unit test \ref BlockFlow_test
|
||||
*/
|
||||
|
||||
|
||||
#include "lib/test/run.hpp"
|
||||
#include "vault/gear/block-flow.hpp"
|
||||
//#include "lib/time/timevalue.hpp"
|
||||
//#include "lib/format-cout.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <utility>
|
||||
|
||||
using test::Test;
|
||||
//using std::move;
|
||||
//using util::isSameObject;
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
namespace test {
|
||||
|
||||
// using lib::time::FrameRate;
|
||||
// using lib::time::Offset;
|
||||
// using lib::time::Time;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*****************************************************************//**
|
||||
* @test document the memory management scheme used by the Scheduler.
|
||||
* @see SchedulerActivity_test
|
||||
* @see SchedulerUsage_test
|
||||
*/
|
||||
class BlockFlow_test : public Test
|
||||
{
|
||||
|
||||
virtual void
|
||||
run (Arg)
|
||||
{
|
||||
simpleUsage();
|
||||
calculateDeadline();
|
||||
setupLalup();
|
||||
}
|
||||
|
||||
|
||||
/** @test TODO demonstrate a simple usage scenario
|
||||
*/
|
||||
void
|
||||
simpleUsage()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
calculateDeadline()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
setupLalup()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** Register this test class... */
|
||||
LAUNCHER (BlockFlow_test, "unit engine");
|
||||
|
||||
|
||||
|
||||
}}} // namespace vault::mem::test
|
||||
102
tests/vault/gear/scheduler-activity-test.cpp
Normal file
102
tests/vault/gear/scheduler-activity-test.cpp
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
/*
|
||||
SchedulerActivity(Test) - verify activities processed in the scheduler
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
* *****************************************************/
|
||||
|
||||
/** @file scheduler-activity-test.cpp
|
||||
** unit test \ref SchedulerActivity_test
|
||||
*/
|
||||
|
||||
|
||||
#include "lib/test/run.hpp"
|
||||
#include "vault/gear/activity-lang.hpp"
|
||||
//#include "lib/time/timevalue.hpp"
|
||||
//#include "lib/format-cout.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <utility>
|
||||
|
||||
using test::Test;
|
||||
//using std::move;
|
||||
//using util::isSameObject;
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
namespace test {
|
||||
|
||||
// using lib::time::FrameRate;
|
||||
// using lib::time::Offset;
|
||||
// using lib::time::Time;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*****************************************************************//**
|
||||
* @test verify behaviour of the Scheduler _Activity Language._
|
||||
* @see SchedulerCommutator_test
|
||||
* @see SchedulerUsage_test
|
||||
*/
|
||||
class SchedulerActivity_test : public Test
|
||||
{
|
||||
|
||||
virtual void
|
||||
run (Arg)
|
||||
{
|
||||
simpleUsage();
|
||||
walkingDeadline();
|
||||
setupLalup();
|
||||
}
|
||||
|
||||
|
||||
/** @test TODO demonstrate a simple usage scenario
|
||||
*/
|
||||
void
|
||||
simpleUsage()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
walkingDeadline()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
setupLalup()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** Register this test class... */
|
||||
LAUNCHER (SchedulerActivity_test, "unit engine");
|
||||
|
||||
|
||||
|
||||
}}} // namespace vault::mem::test
|
||||
102
tests/vault/gear/scheduler-commutator-test.cpp
Normal file
102
tests/vault/gear/scheduler-commutator-test.cpp
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
/*
|
||||
SchedulerCommutator(Test) - verify dependent activity processing in the scheduler
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
* *****************************************************/
|
||||
|
||||
/** @file scheduler-commutator-test.cpp
|
||||
** unit test \ref SchedulerCommutator_test
|
||||
*/
|
||||
|
||||
|
||||
#include "lib/test/run.hpp"
|
||||
#include "vault/gear/scheduler-commutator.hpp"
|
||||
//#include "lib/time/timevalue.hpp"
|
||||
//#include "lib/format-cout.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <utility>
|
||||
|
||||
using test::Test;
|
||||
//using std::move;
|
||||
//using util::isSameObject;
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
namespace test {
|
||||
|
||||
// using lib::time::FrameRate;
|
||||
// using lib::time::Offset;
|
||||
// using lib::time::Time;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/******************************************************************//**
|
||||
* @test Scheduler Layer-2: dependency notification and triggering.
|
||||
* @see SchedulerActivity_test
|
||||
* @see SchedulerUsage_test
|
||||
*/
|
||||
class SchedulerCommutator_test : public Test
|
||||
{
|
||||
|
||||
virtual void
|
||||
run (Arg)
|
||||
{
|
||||
simpleUsage();
|
||||
walkingDeadline();
|
||||
setupLalup();
|
||||
}
|
||||
|
||||
|
||||
/** @test TODO demonstrate a simple usage scenario
|
||||
*/
|
||||
void
|
||||
simpleUsage()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
walkingDeadline()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
setupLalup()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** Register this test class... */
|
||||
LAUNCHER (SchedulerCommutator_test, "unit engine");
|
||||
|
||||
|
||||
|
||||
}}} // namespace vault::mem::test
|
||||
102
tests/vault/gear/scheduler-invocation-test.cpp
Normal file
102
tests/vault/gear/scheduler-invocation-test.cpp
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
/*
|
||||
SchedulerInvocation(Test) - verify queue processing in the scheduler
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
* *****************************************************/
|
||||
|
||||
/** @file scheduler-invocation-test.cpp
|
||||
** unit test \ref SchedulerInvocation_test
|
||||
*/
|
||||
|
||||
|
||||
#include "lib/test/run.hpp"
|
||||
#include "vault/gear/scheduler-invocation.hpp"
|
||||
//#include "lib/time/timevalue.hpp"
|
||||
//#include "lib/format-cout.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <utility>
|
||||
|
||||
using test::Test;
|
||||
//using std::move;
|
||||
//using util::isSameObject;
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
namespace test {
|
||||
|
||||
// using lib::time::FrameRate;
|
||||
// using lib::time::Offset;
|
||||
// using lib::time::Time;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/********************************************************************//**
|
||||
* @test Scheduler Layer-1: queue processing and invocation by priority.
|
||||
* @see SchedulerCommutator_test
|
||||
* @see SchedulerUsage_test
|
||||
*/
|
||||
class SchedulerInvocation_test : public Test
|
||||
{
|
||||
|
||||
virtual void
|
||||
run (Arg)
|
||||
{
|
||||
simpleUsage();
|
||||
walkingDeadline();
|
||||
setupLalup();
|
||||
}
|
||||
|
||||
|
||||
/** @test TODO demonstrate a simple usage scenario
|
||||
*/
|
||||
void
|
||||
simpleUsage()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
walkingDeadline()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
setupLalup()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** Register this test class... */
|
||||
LAUNCHER (SchedulerInvocation_test, "unit engine");
|
||||
|
||||
|
||||
|
||||
}}} // namespace vault::mem::test
|
||||
103
tests/vault/gear/scheduler-usage-test.cpp
Normal file
103
tests/vault/gear/scheduler-usage-test.cpp
Normal file
|
|
@ -0,0 +1,103 @@
|
|||
/*
|
||||
SchedulerUsage(Test) - component integration test for the scheduler
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
* *****************************************************/
|
||||
|
||||
/** @file scheduler-usage-test.cpp
|
||||
** unit test \ref SchedulerUsage_test
|
||||
*/
|
||||
|
||||
|
||||
#include "lib/test/run.hpp"
|
||||
#include "vault/gear/scheduler.hpp"
|
||||
//#include "lib/time/timevalue.hpp"
|
||||
//#include "lib/format-cout.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <utility>
|
||||
|
||||
using test::Test;
|
||||
//using std::move;
|
||||
//using util::isSameObject;
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
namespace test {
|
||||
|
||||
// using lib::time::FrameRate;
|
||||
// using lib::time::Offset;
|
||||
// using lib::time::Time;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*************************************************************************//**
|
||||
* @test Scheduler component integration test: add and process dependent jobs.
|
||||
* @see SchedulerActivity_test
|
||||
* @see SchedulerInvocation_test
|
||||
* @see SchedulerCommutator_test
|
||||
*/
|
||||
class SchedulerUsage_test : public Test
|
||||
{
|
||||
|
||||
virtual void
|
||||
run (Arg)
|
||||
{
|
||||
simpleUsage();
|
||||
walkingDeadline();
|
||||
setupLalup();
|
||||
}
|
||||
|
||||
|
||||
/** @test TODO demonstrate a simple usage scenario
|
||||
*/
|
||||
void
|
||||
simpleUsage()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
walkingDeadline()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test TODO
|
||||
*/
|
||||
void
|
||||
setupLalup()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** Register this test class... */
|
||||
LAUNCHER (SchedulerUsage_test, "unit engine");
|
||||
|
||||
|
||||
|
||||
}}} // namespace vault::mem::test
|
||||
105
tests/vault/mem/extent-family-test.cpp
Normal file
105
tests/vault/mem/extent-family-test.cpp
Normal file
|
|
@ -0,0 +1,105 @@
|
|||
/*
|
||||
ExtentFamily(Test) - verify cyclic extents allocation scheme
|
||||
|
||||
Copyright (C) Lumiera.org
|
||||
2023, Hermann Vosseler <Ichthyostega@web.de>
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License as
|
||||
published by the Free Software Foundation; either version 2 of
|
||||
the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
|
||||
* *****************************************************/
|
||||
|
||||
/** @file extent-family-test.cpp
|
||||
** unit test \ref ExtentFamily_test
|
||||
*/
|
||||
|
||||
|
||||
#include "lib/test/run.hpp"
|
||||
#include "vault/mem/extent-family.hpp"
|
||||
//#include "lib/time/timevalue.hpp"
|
||||
//#include "lib/format-cout.hpp"
|
||||
//#include "lib/util.hpp"
|
||||
|
||||
//#include <utility>
|
||||
|
||||
using test::Test;
|
||||
//using std::move;
|
||||
//using util::isSameObject;
|
||||
|
||||
|
||||
namespace vault{
|
||||
namespace mem {
|
||||
namespace test {
|
||||
|
||||
// using lib::time::FrameRate;
|
||||
// using lib::time::Offset;
|
||||
// using lib::time::Time;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/***************************************************************//**
|
||||
* @test document and verify a memory management scheme to maintain
|
||||
* a flexible set of _»memory extents«_ for cyclic usage.
|
||||
* @see BlockFlow_test
|
||||
*/
|
||||
class ExtentFamily_test : public Test
|
||||
{
|
||||
|
||||
virtual void
|
||||
run (Arg)
|
||||
{
|
||||
simpleUsage();
|
||||
calculateDeadline();
|
||||
setupDependentJob();
|
||||
}
|
||||
|
||||
|
||||
/** @test demonstrate a simple usage scenario
|
||||
*/
|
||||
void
|
||||
simpleUsage()
|
||||
{
|
||||
ExtentFamily extents;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test verify the timing calculations to establish
|
||||
* the scheduling deadline of a simple render job
|
||||
*/
|
||||
void
|
||||
calculateDeadline()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
|
||||
/** @test verify the setup of a prerequisite job in relation
|
||||
* to the master job depending on this prerequisite
|
||||
*/
|
||||
void
|
||||
setupDependentJob()
|
||||
{
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
/** Register this test class... */
|
||||
LAUNCHER (ExtentFamily_test, "unit memory");
|
||||
|
||||
|
||||
|
||||
}}} // namespace vault::mem::test
|
||||
|
|
@ -6183,7 +6183,7 @@ This is the core service provided by the player subsystem. The purpose is to cre
|
|||
:any details of this processing remain opaque for the clients; even the player subsystem just accesses the EngineFaçade
|
||||
</pre>
|
||||
</div>
|
||||
<div title="PlaybackVerticalSlice" creator="Ichthyostega" modifier="Ichthyostega" created="202303272236" modified="202305260205" tags="overview impl discuss draft" changecount="27">
|
||||
<div title="PlaybackVerticalSlice" creator="Ichthyostega" modifier="Ichthyostega" created="202303272236" modified="202307031635" tags="overview impl discuss draft" changecount="29">
|
||||
<pre>//Integration effort to promote the development of rendering, playback and video display in the GUI//
|
||||
This IntegrationSlice was started in {{red{2023}}} as [[Ticket #1221|https://issues.lumiera.org/ticket/1221]] to coordinate the completion and integration of various implementation facilities, planned, drafted and built during the last years; this effort marks the return of development focus to the lower layers (after years of focussed UI development) and will implement the asynchronous and time-bound rendering coordinated by the [[Scheduler]] in the [[Vault|Vault-Layer]]
|
||||
|
||||
|
|
@ -6204,7 +6204,16 @@ __May.23__: taking a //prototyping approach// now, since further development was
|
|||
* ✔ build a {{{MockSegmentation}}} to hold onto ~JobTickets, which can be created as Mock
|
||||
* ✔define a simple specification language (based on the existing {{{GenNode}}}-DSL to define segments, tickets and prerequisite jobs
|
||||
* ✔ implement a »~Split-Splice« algorithm for &rarr; SegmentationChange, rigged accordingly to generate a mocked Segementation for now
|
||||
* 🗘 create a testbed to assemble a JobPlanningPipeline step by step (&rarr; [[#920|https://issues.lumiera.org/ticket/920]] and [[#1275|https://issues.lumiera.org/ticket/1275|]])
|
||||
* ✔ create a testbed to assemble a JobPlanningPipeline step by step (&rarr; [[#920|https://issues.lumiera.org/ticket/920]] and [[#1275|https://issues.lumiera.org/ticket/1275|]])
|
||||
|
||||
__June23__: building upon this prototyping approach, the dispatcher pipeline could be rearranged in the form of a pipeline builder, allowing to retract the originally used implementation scheme based on »Monads«. The implementation of the Dispatcher is complete, yet the build up of the [[»Render Drive« #1301|https://issues.lumiera.org/ticket/1301]] could not reasonably be completed, due to lack of a clear-shaped ''Scheduler interface''.
|
||||
|
||||
__July23__: this leads to a shift of work focus towards implementing the [[Scheduler]] itself.
|
||||
The Scheduler will be structured into two Layers, where the lower layer is implemented as //priority queue// (using the STL). So the most tricky part to solve is the representation of //dependencies// between jobs, with the possible extension to handling IO operations asynchronously. Analysis and planning of the implementation indicate that the [[scheduler memory managment|SchedulerMemory]] can be based on //Extents//, which are interpreted as »Epochs« with a deadline. These considerations imply the next steps for building up the Scheduler functionality
|
||||
* 🗘 build a first working draft for the {{{BlockFlow}}} allocation scheme [[#1311|https://issues.lumiera.org/ticket/1311]]
|
||||
* ⌛ define and cover the basic [[Activities|RenderActivity]] necessary to implement a plain-simple-Job (without dependencies)
|
||||
* ⌛ pass such an Activity through the two layers of the Scheduler
|
||||
* ⌛ adapt the [[job planning pipeline|JobPlanningPipeline]] implemented thus far to produce the appropriate {{{Activity}}} records for the scheduler
|
||||
|
||||
!Decisions
|
||||
;Scheduler
|
||||
|
|
@ -6212,6 +6221,7 @@ __May.23__: taking a //prototyping approach// now, since further development was
|
|||
:* shall support concerns of process- and memory management
|
||||
:* thus needs to //understand Job dependencies//
|
||||
:* will be decomposed into several implementation layers
|
||||
:SchedulerMemory will be managed by an //Extent scheme.//
|
||||
</pre>
|
||||
</div>
|
||||
<div title="Player" modifier="Ichthyostega" created="201012181700" modified="202304140114" tags="def overview" changecount="4">
|
||||
|
|
@ -7044,7 +7054,7 @@ Later on we expect a distinct __query subsystem__ to emerge, presumably embeddin
|
|||
|
||||
&rarr; QuantiserImpl</pre>
|
||||
</div>
|
||||
<div title="Scheduler" creator="Ichthyostega" modifier="Ichthyostega" created="202304140131" modified="202306222158" tags="Rendering spec draft" changecount="7">
|
||||
<div title="Scheduler" creator="Ichthyostega" modifier="Ichthyostega" created="202304140131" modified="202307031603" tags="Rendering spec draft" changecount="9">
|
||||
<pre>//Invoke and control the dependency and time based execution of [[render jobs|RenderJob]]//
|
||||
The Scheduler acts as the central hub in the implementation of the RenderEngine and coordinates the //processing resources// of the application. Regarding architecture, the Scheduler is located in the Vault-Layer and //running// the Scheduler is equivalent to activating the »Vault Subsystem«. An EngineFaçade acts as entrance point, providing high-level render services to other parts of the application: [[render jobs|RenderJob]] can be activated under various timing and dependency constraints. Internally, the implementation is segregated into two layers
|
||||
;Layer-2: Control
|
||||
|
|
@ -7059,6 +7069,29 @@ Time bound delivery of media data is an important aspect of editing and playback
|
|||
This leads to the observation that every render or playback process has to deal with rather incompatible processing patterns and trends: for one, processing has to start as soon as the event of an completed I/O-operation is published, yet on the other hand, limited computational resources must be distributed and prioritised in a way suitable to deliver the completed data as close as possible to a pre-established timing deadline, under the constraint of limited in-memory buffer capacity. The //control structure// of such a render engine is thus not only a time based computation plan -- first and foremost it should be conceived as an asynchronous messaging system, with the ability however to prioritise some messages based on urgency or approaching deadlines.
|
||||
|
||||
The time-based ordering and prioritisation of [[render activities|RenderActivity]] is thus used as a //generic medium and agent// to support and implement complex interwoven computational tasks. On the layer-1 mentioned above, a combination of a lock-free dispatch queue is used, feeding into a single threaded priority queue organised by temporal deadlines. Most render activities are lightweight and entail quick updates to some state flags, while certain activities are extremely long running -- and those are shifted into worker threads based on priority.
|
||||
|
||||
!Usage pattern
|
||||
The [[Language of render activities|RenderActivity]] forms the interface to the scheduler -- new activities are defined as //terms// and handed over to the scheduler. This happens as part of the ongoing job planning activities -- and thus will be performed //from within jobs managed by the scheduler.// Thus the access to the scheduler happens almost entirely from within the scheduler's realm itself, and is governed by the usage scheme of the [[Workers|SchedulerWorker]].
|
||||
|
||||
These ''Worker Threads'' will perform actual render activities most of the time (or be idle). However -- idle workers contend for new work, and for doing so, they //also perform the internal scheduler management activities.// As a consequence, all Scheduler coordination and [[memory management|SchedulerMemory]] is ''performed non-concurrent'': only a single Worker can acquire the {{{GroomingToken}}} and will then perform managment work until the next render activity is encountered.
|
||||
</pre>
|
||||
</div>
|
||||
<div title="SchedulerMemory" creator="Ichthyostega" modifier="Ichthyostega" created="202307031622" tags="Rendering operational draft" changecount="1">
|
||||
<pre>//The Scheduler uses an »Extent« based memory management scheme known as ''BlockFlow''.//
|
||||
The organisation of rendering happens in terms of [[Activities|RenderActivity]], which may bound by //dependencies// and limited by //deadlines.// For the operational point of view this implies that a sequence of allocations must be maintained to „flow through the Scheduler“ -- in fact, only references to these {{{Activity}}} records are passed, while the actual descriptors reside at fixed memory locations. This is essential to model dependencies and conditional execution structures efficiently. At some point however, any {{{Activity}}} record will either be //performed// or //obsoleted// -- and this leads to the idea of managing the allocations in memory extents termed as »Epochs«
|
||||
* a new Activity is planted into a suitable //Epoch,// based on its deadline
|
||||
* it is guaranteed to sit at a fixed memory location while it potentially can be activated
|
||||
* based on the deadlines, at some point a complete strike of activities can be reasoned to be //obsolete.//
|
||||
* this allows to discard a complete Extent without any further checks and processing (trivial destructors!)
|
||||
|
||||
!Safeguards
|
||||
This is a rather fragile composition and chosen here for performance reasons; while activities are interconnected, there memory locations are adjacent, improving cache coherence. Moreover, most of the dependency processing and managing of activities happens single-threaded, while some [[worker|SchedulerWorker]] holds the {{{GroomingToken}}}; so most of the processing is local and does not require memory barriers.
|
||||
|
||||
Unfortunately this also implies that most safety barriers of the C++ language are removed or circumvented. A strict processing regime must be established, with clear rules as to when activities may be accessed.
|
||||
* each »Epoch« gets an associated //deadline//
|
||||
* when the next [[job|RenderJob]] processed by a worker starts //after this Epoch's deadline//, the worker //has left the Epoch.//
|
||||
* when all workers have left an Epoch, only ''pending async IO tasks'' need to be considered, since such IO task can always be delayed for an extended period of time. For an IO task, buffers need to be prepared, and those buffers are indirectly tied to the job depending on them.
|
||||
* ⟹ thus a count of pending IO activities must be maintained //for each Epoch// -- implemented by the same mechanism also employed for dependencies between render jobs, namely a notification leading to decreasing a local counter
|
||||
</pre>
|
||||
</div>
|
||||
<div title="SchedulerRequirements" modifier="Ichthyostega" created="201107080145" modified="201112171835" tags="Rendering spec draft discuss">
|
||||
|
|
|
|||
|
|
@ -77839,7 +77839,29 @@ Date:   Thu Apr 20 18:53:17 2023 +0200<br/>
|
|||
</node>
|
||||
<node CREATED="1684980982361" ID="ID_1863198468" MODIFIED="1684980987321" TEXT="Themen">
|
||||
<node CREATED="1684980991406" ID="ID_1812192430" MODIFIED="1684981025601" TEXT="Timings nachführen">
|
||||
<arrowlink COLOR="#705783" DESTINATION="ID_1565158605" ENDARROW="Default" ENDINCLINATION="223;-15;" ID="Arrow_ID_516157232" STARTARROW="None" STARTINCLINATION="312;45;"/>
|
||||
<arrowlink COLOR="#705783" DESTINATION="ID_1565158605" ENDARROW="Default" ENDINCLINATION="223;-15;" ID="Arrow_ID_516157232" STARTARROW="None" STARTINCLINATION="338;47;"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687908222714" ID="ID_941383183" MODIFIED="1687908233939" TEXT="Darstellung">
|
||||
<node CREATED="1687908236975" ID="ID_692898121" MODIFIED="1687908476679" TEXT="eigentlich polymorph — aber in gemeinsamen Datenrecord encodiert">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Activity-Terme sind sowohl semantsich, als auch operational polymorph; das heißt es gibt einen gemeinsamen Kontrakt und eine flexible Ausdifferenzierung im Verhalten. ABER aus Performance-Gründen können wir uns im Scheduler keine unnötigen Indirektionen und variablen Allokationen leisten; stattdessen wird die gesamte Storage per Mehrfachbelegung auf einen einzigen Datenblock abgebildet, und das Verhalten wird in ein Switch-on-Selector-Field übersetzt
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eef0c5" COLOR="#990000" CREATED="1687908607797" ID="ID_989605795" MODIFIED="1687908674373" TEXT="Implementierung des Verhaltens">
|
||||
<arrowlink COLOR="#7f362f" DESTINATION="ID_1214627402" ENDARROW="Default" ENDINCLINATION="-265;-25;" ID="Arrow_ID_1834773150" STARTARROW="None" STARTINCLINATION="-686;57;"/>
|
||||
<icon BUILTIN="pencil"/>
|
||||
<node CREATED="1687908684071" ID="ID_814820281" MODIFIED="1687908690152" TEXT="im Scheduler Layer-2">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
|
|
@ -77960,7 +77982,7 @@ Date:   Thu Apr 20 18:53:17 2023 +0200<br/>
|
|||
<node CREATED="1687732193467" ID="ID_1465560345" MODIFIED="1687732229088" TEXT="Multi producer/consumer">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687732230868" ID="ID_1042469307" MODIFIED="1687732238086" TEXT="integrade custom allocator">
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687732230868" ID="ID_1042469307" MODIFIED="1687732238086" TEXT="integrate custom allocator">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
</node>
|
||||
|
|
@ -78108,6 +78130,23 @@ Date:   Thu Apr 20 18:53:17 2023 +0200<br/>
|
|||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687909561193" ID="ID_1235436372" MODIFIED="1688337610242" TEXT="GroomingToken">
|
||||
<node CREATED="1687909742256" ID="ID_768602373" MODIFIED="1687909749803" TEXT="implementiert per atomic CAS"/>
|
||||
<node CREATED="1687909758046" ID="ID_1061447302" MODIFIED="1687909764595" TEXT="nur ein Worker kann es jeweils besitzen"/>
|
||||
<node CREATED="1687909787970" ID="ID_1744353313" MODIFIED="1687909813720" TEXT="dieser bedient dann die Priority-Queue"/>
|
||||
<node CREATED="1687909860136" ID="ID_1257565620" MODIFIED="1687910043028" TEXT="...und gibt es kooperativ wieder frei">
|
||||
<linktarget COLOR="#af5678" DESTINATION="ID_1257565620" ENDARROW="Default" ENDINCLINATION="223;172;" ID="Arrow_ID_1390633196" SOURCE="ID_1887123630" STARTARROW="None" STARTINCLINATION="-430;56;"/>
|
||||
<node CREATED="1687909898834" ID="ID_688462252" MODIFIED="1687909905300" TEXT="Deadlock-Gefahr">
|
||||
<icon BUILTIN="messagebox_warning"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909906855" ID="ID_195997630" MODIFIED="1687909912310" TEXT="Watchdog notwendig">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1687909963201" ID="ID_369489190" MODIFIED="1687909968365" TEXT="realisiert per Tick"/>
|
||||
<node CREATED="1687909969073" ID="ID_1256883233" MODIFIED="1687909980556" TEXT="geprüft beim Zugriff auf den Scheduler"/>
|
||||
<node CREATED="1687909981295" ID="ID_360021579" MODIFIED="1687909991866" TEXT="Alarm wenn letzter Tick zu lange zurückliegt"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687788623248" ID="ID_1335631068" MODIFIED="1687788627335" TEXT="Ausführungs-Struktur">
|
||||
<node CREATED="1685029833448" ID="ID_1405359337" MODIFIED="1685029836621" TEXT="Verzweigungen">
|
||||
<node BACKGROUND_COLOR="#f0d5c5" COLOR="#990033" CREATED="1685029839057" ID="ID_1926570028" MODIFIED="1685029854988" TEXT="verzweigte Ausführungs-Strukur oder nur Entscheidungs-Struktur?">
|
||||
|
|
@ -78169,16 +78208,356 @@ Date:   Thu Apr 20 18:53:17 2023 +0200<br/>
|
|||
<node CREATED="1687788659433" ID="ID_1507624704" MODIFIED="1687788784350" TEXT="es werden Satz-artige Terme ausgewertet">
|
||||
<icon BUILTIN="yes"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687908576983" ID="ID_1214627402" MODIFIED="1687908674373" TEXT="operationale Semantik">
|
||||
<linktarget COLOR="#7f362f" DESTINATION="ID_1214627402" ENDARROW="Default" ENDINCLINATION="-265;-25;" ID="Arrow_ID_1834773150" SOURCE="ID_989605795" STARTARROW="None" STARTINCLINATION="-686;57;"/>
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1687908771624" ID="ID_389533415" MODIFIED="1687908782901" TEXT="Grundsätzlich: verkettete Terme werden nacheinander aktiviert"/>
|
||||
<node CREATED="1687908847686" ID="ID_1934270653" MODIFIED="1687908851049" TEXT="Job ausführen">
|
||||
<node CREATED="1687908853373" ID="ID_212238089" MODIFIED="1687994616711" TEXT="Gate-Check"/>
|
||||
<node CREATED="1687908993649" ID="ID_1350770179" MODIFIED="1687909004475" TEXT="timeStart">
|
||||
<node CREATED="1687909447304" ID="ID_724099439" MODIFIED="1687914560990" TEXT="Nachricht an TimingObservable">
|
||||
<arrowlink COLOR="#a1195c" DESTINATION="ID_225279364" ENDARROW="Default" ENDINCLINATION="279;0;" ID="Arrow_ID_802789276" STARTARROW="None" STARTINCLINATION="376;36;"/>
|
||||
</node>
|
||||
<node CREATED="1687909461134" ID="ID_1887123630" MODIFIED="1688337466996" TEXT="drop GroomingToken">
|
||||
<arrowlink COLOR="#af5678" DESTINATION="ID_1257565620" ENDARROW="Default" ENDINCLINATION="223;172;" ID="Arrow_ID_1390633196" STARTARROW="None" STARTINCLINATION="-430;56;"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687910219015" ID="ID_28786353" MODIFIED="1687910221323" TEXT="invoke">
|
||||
<node CREATED="1687910253555" ID="ID_373183597" MODIFIED="1687910259797" TEXT="Verweis auf einen JobFunctor"/>
|
||||
<node CREATED="1687910292410" ID="ID_1172966925" MODIFIED="1687910299032" TEXT="Job-Parameter-Record">
|
||||
<node BACKGROUND_COLOR="#f0d5c5" COLOR="#990033" CREATED="1687913896192" ID="ID_596101241" MODIFIED="1687913904630" TEXT="wo liegt der im Speicher?">
|
||||
<icon BUILTIN="help"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687913931473" ID="ID_1493272170" MODIFIED="1687913951849" TEXT="ruft JobFunctor mit Parametern auf"/>
|
||||
</node>
|
||||
<node CREATED="1687914466382" ID="ID_212913790" MODIFIED="1687914471505" TEXT="post-Hook">
|
||||
<node CREATED="1687914473677" ID="ID_1900995461" MODIFIED="1687914486927" TEXT="stellt seine Nachfollger in die Queue"/>
|
||||
<node CREATED="1687913985529" ID="ID_1403905180" MODIFIED="1687913989780" TEXT="timeStop">
|
||||
<node CREATED="1687909447304" ID="ID_243187423" MODIFIED="1687914554079" TEXT="an TimingObservable">
|
||||
<arrowlink COLOR="#a1195c" DESTINATION="ID_225279364" ENDARROW="Default" ENDINCLINATION="231;0;" ID="Arrow_ID_940532479" STARTARROW="None" STARTINCLINATION="71;9;"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687914113919" ID="ID_711237666" MODIFIED="1687914123035" TEXT="notification(s)">
|
||||
<node CREATED="1687914132850" ID="ID_474241176" MODIFIED="1687914135243" TEXT="optional"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1687994762046" ID="ID_1088341634" MODIFIED="1687994767082" TEXT="Gate-Check">
|
||||
<node CREATED="1687994769427" ID="ID_490498751" MODIFIED="1687994831595" TEXT="prüft ein countdown-Latch"/>
|
||||
<node CREATED="1687994866264" ID="ID_1786817486" MODIFIED="1687994891144" TEXT="falls > 0, re-schedule ⟶ future"/>
|
||||
<node CREATED="1687995197271" ID="ID_1651228511" MODIFIED="1687995814074" TEXT="falls ↷ Deadline ⟶ ��"/>
|
||||
</node>
|
||||
<node CREATED="1687996045519" ID="ID_230365460" MODIFIED="1687996181154" TEXT="notification">
|
||||
<node CREATED="1687996191436" ID="ID_1681650444" MODIFIED="1688337488476" TEXT="Ausführung stets synchron">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
d.h. wird stehts von einem Worker ausgeführt, der aktuell das GroomingToken hält
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1687996497163" ID="ID_4769641" MODIFIED="1687996508267" TEXT="dekrementiert ein angeschlossenes Gate"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#d2beaf" COLOR="#5c4d6e" CREATED="1688165968499" ID="ID_833860978" MODIFIED="1688165983122" TEXT="Thema: Async IO">
|
||||
<icon BUILTIN="hourglass"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688165984598" ID="ID_1228650948" MODIFIED="1688166003616" TEXT="zunächst: nur Möglichkeiten und Strukturen klären">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688166011172" ID="ID_671880878" MODIFIED="1688166143669" TEXT="Technologien">
|
||||
<arrowlink COLOR="#375880" DESTINATION="ID_1200591959" ENDARROW="Default" ENDINCLINATION="-1794;532;" ID="Arrow_ID_1852326782" STARTARROW="None" STARTINCLINATION="-1625;-156;"/>
|
||||
<node CREATED="1688258161312" ID="ID_1806519359" MODIFIED="1688258203414" TEXT="ASIO(portabel) unterstützt es für Files erst neuerdings (io_uring)"/>
|
||||
<node CREATED="1688258212089" ID="ID_288966469" MODIFIED="1688258228531" TEXT="sonst keine portable Lösung verfügbar"/>
|
||||
<node CREATED="1688258230375" ID="ID_1659248350" MODIFIED="1688258247491" TEXT="mmap und io_uring sind Linux-only"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#d2beaf" COLOR="#5c4d6e" CREATED="1684980732965" ID="ID_1914429002" MODIFIED="1684980742528" TEXT="Thema: Timing-Updates">
|
||||
<icon BUILTIN="hourglass"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1684980744406" ID="ID_1565158605" LINK="https://issues.lumiera.org/ticket/1302" MODIFIED="1684981025601" TEXT="#1302 maintain consistent job timings">
|
||||
<linktarget COLOR="#705783" DESTINATION="ID_1565158605" ENDARROW="Default" ENDINCLINATION="223;-15;" ID="Arrow_ID_516157232" SOURCE="ID_1812192430" STARTARROW="None" STARTINCLINATION="312;45;"/>
|
||||
<linktarget COLOR="#705783" DESTINATION="ID_1565158605" ENDARROW="Default" ENDINCLINATION="223;-15;" ID="Arrow_ID_516157232" SOURCE="ID_1812192430" STARTARROW="None" STARTINCLINATION="338;47;"/>
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eef0c5" COLOR="#990000" CREATED="1688336218233" HGAP="-55" ID="ID_323523273" MODIFIED="1688337255857" TEXT="testgetriebener Aufbau" VSHIFT="34">
|
||||
<linktarget COLOR="#fe3a58" DESTINATION="ID_323523273" ENDARROW="Default" ENDINCLINATION="-167;17;" ID="Arrow_ID_589297136" SOURCE="ID_1968961000" STARTARROW="None" STARTINCLINATION="-139;-149;"/>
|
||||
<icon BUILTIN="pencil"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688336601091" ID="ID_1454374119" MODIFIED="1688337246568" TEXT="BlockFlow_test">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688336974018" ID="ID_1806920884" MODIFIED="1688337018608" TEXT="»Epoch« based memory layout">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688394889309" ID="ID_1132827905" MODIFIED="1688398856923" TEXT="ExtentFamily_test">
|
||||
<linktarget COLOR="#eb4070" DESTINATION="ID_1132827905" ENDARROW="Default" ENDINCLINATION="-593;73;" ID="Arrow_ID_709934622" SOURCE="ID_504623704" STARTARROW="None" STARTINCLINATION="-214;-18;"/>
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688394900403" ID="ID_1380392473" MODIFIED="1688394919878" TEXT="underlying sequence-of-extents">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688336697451" ID="ID_360159435" MODIFIED="1688337246569" TEXT="SchedulerActivity_test">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688337038457" ID="ID_1859527374" MODIFIED="1688337060790" TEXT="»Activity Language« Functionality test">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688336761542" ID="ID_145928010" MODIFIED="1688337246571" TEXT="SchedulerInvocation_test">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688337123318" ID="ID_1686181795" MODIFIED="1688337233916" TEXT="»Layer-1« : Queue operation">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688336794355" ID="ID_1705923970" MODIFIED="1688337246572" TEXT="SchedulerCommutator_test">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688337141875" ID="ID_1442397948" MODIFIED="1688337233917" TEXT="»Layer-2« : dependent Activities">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688336835085" ID="ID_1753236898" MODIFIED="1688337246573" TEXT="SchedulerUsage_test">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node CREATED="1688337200875" ID="ID_1269476607" MODIFIED="1688337233917" TEXT="Scheduler Component End-to-End ">
|
||||
<icon BUILTIN="info"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688051068000" ID="ID_555375367" MODIFIED="1688336007132" TEXT="Thema: Arbeitsspeicher">
|
||||
<icon BUILTIN="bell"/>
|
||||
<node CREATED="1688051147135" ID="ID_1865550842" MODIFIED="1688051346737" TEXT="aktive Steuerung zwingend erforderlich">
|
||||
<icon BUILTIN="yes"/>
|
||||
<node CREATED="1688051648500" ID="ID_568573885" MODIFIED="1688051651877" TEXT="concurrent"/>
|
||||
<node CREATED="1688051250601" ID="ID_1958866301" MODIFIED="1688051258062" TEXT="Leerlauf begrenzen"/>
|
||||
<node CREATED="1688051259016" ID="ID_216246633" MODIFIED="1688051265338" TEXT="Fragmentierung verhindern"/>
|
||||
<node CREATED="1688051303633" ID="ID_837527400" MODIFIED="1688051334263" TEXT="Verweise ohne Prüfung ermöglichen"/>
|
||||
<node CREATED="1688051266167" ID="ID_237996247" MODIFIED="1688051279937" TEXT="Keine Einzelfall-Suche und -Verwaltung"/>
|
||||
</node>
|
||||
<node CREATED="1688051375174" ID="ID_1732350232" MODIFIED="1688051379092" TEXT="mögliche Modelle">
|
||||
<node COLOR="#5b280f" CREATED="1688051443983" ID="ID_1229960682" MODIFIED="1688051687690" TEXT="einfacher Kachel-Pool">
|
||||
<icon BUILTIN="button_cancel"/>
|
||||
<node CREATED="1688051454370" ID="ID_227724531" MODIFIED="1688051487509" TEXT="leistet schnelle Allokation"/>
|
||||
<node CREATED="1688051491134" ID="ID_977394615" MODIFIED="1688051514000" TEXT="nicht Cache-freundlich (Fragmentierung)"/>
|
||||
<node CREATED="1688051514595" ID="ID_1917862188" MODIFIED="1688051532345" TEXT="keine Unterstützung zur de-Allokation"/>
|
||||
</node>
|
||||
<node CREATED="1688051694894" ID="ID_1073939757" MODIFIED="1688051704131" TEXT="Cluster mit count-down">
|
||||
<node CREATED="1688052608171" ID="ID_1055878278" MODIFIED="1688053269207" TEXT="Eigenschaften um den Faktor der Cluster-Größe gedämpft">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Dieses Schema hat grundsätzlich die gleichen Charakteristiken wie ein flacher Kachel-Pool, aber die Cluster-Größe wirkt als <i>Hebel:</i>  zusammengehörige Elemente liegen im Cluster und sind damit cache-freundlicher. Fragementierung findet zwar statt, aber auf Cluster-Ebene; deshalb braucht man auch weiterhin eine Free-List, aber auch diese wird nur einmal pro Cluster aktualisiert.
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1688052644942" ID="ID_589962239" MODIFIED="1688053388040" TEXT="Pro Kette eine Notification auf ein Cluster-Gate">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Am Ende einer Kette von Activities muß eine Spezialbehandlung liegen, die die Länge der Kette weiß; zusätzlich kompliziert wird es, wenn diese Kette nicht in einen Cluster paßt (dann braucht es mehrere Notifications). Im Commutator ist spezielle Logik notwendig, die die Ausführung dieser Freigabe-Benachrichtigungen sicherstellt, damit diese dann ein gemeinsames Cluster-Gate dekrementieren, das in der ersten Allokation des Clusters liegt (und insofern Platz verschwendet)
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1688053388889" ID="ID_1778479709" MODIFIED="1688053515642" TEXT="Vorteil: gute Speicherauslastung und wenig contention-Probleme"/>
|
||||
</node>
|
||||
<node CREATED="1688053526333" ID="ID_617675303" MODIFIED="1688053637212" TEXT="Epochen-Pools">
|
||||
<node CREATED="1688053638890" ID="ID_276255064" MODIFIED="1688053999948" TEXT="alle Activities bis zu einer Deadline schöpfen aus einem Pool"/>
|
||||
<node CREATED="1688054012571" ID="ID_1965757784" MODIFIED="1688054041039" TEXT="Vorteil: keinerlei Einzelfallprüfung notwendig"/>
|
||||
<node CREATED="1688054042658" ID="ID_593771141" MODIFIED="1688054900987" TEXT="Nachteil: Speicher bleibt bis zur Deadline nutzlos geblockt">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Komplexe zeitliche Struktur, die auch zwingend zu einem gewissen Leerlauf führt, man braucht also reichlich Speicher. Außerdem ist nicht von Vornherein klar, wie viel Speicher bis zu einer Deadline noch gebraucht wird; man steht dadurch vor der Wahl, entweder Fragmentierungin Kauf zu nehmen, oder eben überschüssige Allokationen der nächsten Deadline zuzuschlagen, wodurch sie dann unnötig lange geblockt gehalten werden müssen
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1688054070707" ID="ID_1810534883" MODIFIED="1688054791596" TEXT="Achtung: kann nicht mit Activities ohne Deadline umgehen">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Das führt zu einer Komplikation, da es solche Activities geben wird (Render-to-File, background activities); es muß dann eine pseudo-Deadline eingeführt werde, bei deren Überschreitung ein re-Scheduling in einen neuen Pool erfolgt. Ebenso stellen Deadlines weit in der Zukunft ein Problem dar
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1688054956464" ID="ID_1119280437" MODIFIED="1688055235864" TEXT="Gefahr: hängende oder verzögerte Worker">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
man muß für jeden Worker mitverfolgen, ob er die Epoche verlassen hat; das ist so nicht ohne Weiteres möglich, da es Activities geben könnte, die später gestartet werden aber doch eine knappere Deadline haben (und damit noch in eine frühere Epoche fallen würden) — man müßte also warten, bis die Startzeitpunkte hinter der Deadline der Epoche liegen
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#fdfdcf" COLOR="#ff0000" CREATED="1688055236771" ID="ID_1880692941" MODIFIED="1688337296471" TEXT="Entscheidung für ein Schema">
|
||||
<icon BUILTIN="yes"/>
|
||||
<node CREATED="1688055361612" ID="ID_1809618499" MODIFIED="1688057881911" TEXT="Cluster/count-down ist „schön“ — aber leider nur auf den ersten Blick"/>
|
||||
<node CREATED="1688055245099" ID="ID_1913128751" MODIFIED="1688057920440" TEXT="das Epochen-Schema...">
|
||||
<icon BUILTIN="forward"/>
|
||||
<node CREATED="1688055314853" ID="ID_139103719" MODIFIED="1688055323011" TEXT="wäre sehr attraktiv"/>
|
||||
<node CREATED="1688055324316" ID="ID_1821002553" MODIFIED="1688055329362" TEXT="wirft aber ungeklärte Probleme auf"/>
|
||||
<node BACKGROUND_COLOR="#e0ceaa" COLOR="#690f14" CREATED="1688057886935" ID="ID_1953816732" MODIFIED="1688258403484" TEXT="Entscheidung: per Erweiterung lösen!">
|
||||
<arrowlink COLOR="#6f1a2f" DESTINATION="ID_1770745874" ENDARROW="Default" ENDINCLINATION="10;-56;" ID="Arrow_ID_207766086" STARTARROW="None" STARTINCLINATION="-118;8;"/>
|
||||
<icon BUILTIN="yes"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688057922146" ID="ID_1770745874" MODIFIED="1688258403484" TEXT="Erweiterungen">
|
||||
<linktarget COLOR="#6f1a2f" DESTINATION="ID_1770745874" ENDARROW="Default" ENDINCLINATION="10;-56;" ID="Arrow_ID_207766086" SOURCE="ID_1953816732" STARTARROW="None" STARTINCLINATION="-118;8;"/>
|
||||
<node CREATED="1688057954745" ID="ID_1000550033" MODIFIED="1688057976503" TEXT="die Schrittweite zu belegender Epochen ist dynamisch reguliert"/>
|
||||
<node CREATED="1688057988746" ID="ID_852809059" MODIFIED="1688058006097" TEXT="Epochen werden bis zu einem gewissen Limit bei Bedarf geöffnet"/>
|
||||
<node CREATED="1688058008286" ID="ID_1395550013" MODIFIED="1688058062859" TEXT="darüber hinausgehende Activities werden per »post« dargestellt"/>
|
||||
<node CREATED="1688058076006" ID="ID_47142249" MODIFIED="1688337534216">
|
||||
<richcontent TYPE="NODE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Allokationen erfolgen <b>single-threaded</b>, unter <b>GroomingToken</b>
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
<node CREATED="1688058168929" ID="ID_1643083423" MODIFIED="1688058185536" TEXT="die meisten Allokationen stammen aus Planungs-Jobs">
|
||||
<icon BUILTIN="idea"/>
|
||||
</node>
|
||||
<node CREATED="1688058144285" ID="ID_116746560" MODIFIED="1688058160770" TEXT="das vereinfacht die Aufgabe dramatisch">
|
||||
<icon BUILTIN="idea"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688058192795" ID="ID_761011342" MODIFIED="1688058211628" TEXT="extern eingestellte Activities kommen per »post«">
|
||||
<node CREATED="1688058229693" ID="ID_423749722" MODIFIED="1688058256265" TEXT="»post« bedeutet re-Allokation in eine Epoche gemäß Deadline"/>
|
||||
<node CREATED="1688058271259" ID="ID_1955580898" MODIFIED="1688058284477" TEXT="ein externer »post« wird Heap-alloziert"/>
|
||||
<node CREATED="1688058307358" ID="ID_1066116422" MODIFIED="1688058331601" TEXT="eine Spezial-Flag signalisiert, daß er nach Ausführung aktiv verworfen wird"/>
|
||||
<node CREATED="1688077690455" ID="ID_1592564258" MODIFIED="1688078101913" TEXT="Komplikation:zusätzlicher Epochen-Check bei externen Triggern notwendig">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
ein externer Trigger kann einen »post« auslösen; da ein solcher Trigger auch noch verspätet auftreten kann (nach Überschreiten der Deadline), muß nochmal explizit geprüft werden, ob die Epoche „noch lebt“, bevor man in ihr eine Activity auslöst. Das bedingt aber zumindest noch <i>einen beweglichen Parameter </i>für einen generischen Funktor, der irgendwo gespeichert werden muß (und nicht in der Storage der Epoche selber liegen kann).
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
<icon BUILTIN="messagebox_warning"/>
|
||||
<node BACKGROUND_COLOR="#e0ceaa" COLOR="#690f14" CREATED="1688163354228" ID="ID_763105814" MODIFIED="1688163732289" TEXT="es genügt nicht, ausgebliebene Callbacks nur zu erkennen">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
...vielmehr muß man den Callback <i>selber „erwischen“ und unschädlich machen, </i>bevor er bereits wiederverwendete Storage anspricht
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
<icon BUILTIN="stop-sign"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#e0ceaa" COLOR="#690f14" CREATED="1688163672758" ID="ID_1234286909" MODIFIED="1688163732290" TEXT="auch die für die Daten vorgehaltenen Buffer sind Teil des Problems">
|
||||
<icon BUILTIN="clanbomber"/>
|
||||
</node>
|
||||
<node CREATED="1688163467818" ID="ID_116134089" MODIFIED="1688163480661" TEXT="entweder der Callback bietet noch ein zusätzliches Argument"/>
|
||||
<node CREATED="1688163493526" ID="ID_10773626" MODIFIED="1688258346243" TEXT="oder man kann einen Timeout setzen">
|
||||
<icon BUILTIN="button_cancel"/>
|
||||
<node CREATED="1688258348550" ID="ID_1696061672" MODIFIED="1688258367827" TEXT="geht nicht">
|
||||
<icon BUILTIN="closed"/>
|
||||
</node>
|
||||
<node CREATED="1688258352630" ID="ID_1565684116" MODIFIED="1688258373752" TEXT="widerspricht der Idee von Async-IO">
|
||||
<icon BUILTIN="idea"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688058581274" ID="ID_479775577" MODIFIED="1688058598373" TEXT="Epochen sind untereinander verzeigert und bilden eine Ringstruktur"/>
|
||||
</node>
|
||||
<node CREATED="1688258518472" ID="ID_1814030410" MODIFIED="1688258528453" TEXT="Problem: verzögerte Jobs">
|
||||
<icon BUILTIN="messagebox_warning"/>
|
||||
<node CREATED="1688258581519" ID="ID_274521183" MODIFIED="1688258587020" TEXT="unvermeidbar">
|
||||
<icon BUILTIN="messagebox_warning"/>
|
||||
</node>
|
||||
<node CREATED="1688258543988" ID="ID_1398474376" MODIFIED="1688258589885" TEXT="muß dagegen eigens absichern">
|
||||
<icon BUILTIN="yes"/>
|
||||
<node CREATED="1688258594853" ID="ID_1346688484" MODIFIED="1688337515621" TEXT="CPU-bound Jobs kann man über einen »water-level« pro Worker absichern">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
da Jobs nach Zeit geordnet aktiviert werden, kann man für jeden Worker eine Markierung der aktuellen Epoche erzeugen; sie wäre jeweils zu aktualisieren, wenn ein Worker das GroomingToken abgibt... (und damit in einen Render-Job einsteigt) — mithin ließe sich feststellen, wenn alle Worker eine Epoche <i>verlassen haben.</i>
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1688258639519" ID="ID_253828146" MODIFIED="1688337591520" TEXT="Async-IO dagegen braucht zwingend einen aktiv-Zähler">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Es handelt sich hierbei um ein <b>grundsätzliches Problem</b>. Es liegt in der Natur von IO, daß eine solche Operation eine unbestimmte Zeit dauern kann; und diese Zeit kann ganz erheblich sein, wenn das IO-Subsystem überlastet wird. Es gibt keine Möglichkeit, eine IO-Operation abzubrechen; vielmehr kommen <i>die Daten irgendwann an, und landen dann in dem dafür vorgesehenen Buffer. </i>Und solange das nicht passiert ist, muß der Buffer und der Callback im Speicher bereitliegen. Ich sehe keine andere Möglichkeit, als für jede Epoche einen Zähler aller schwebenden IO-Operationen mitzuführen. Mithilfe der »post«, »notify« und »guard«-Activities ließe sich das jedoch single-threaded verwirklichen — Synchronisations-Effekte treten daher nur für Threads, die grade eine IO-Operation abgeschlossen haben, sowie den Thread, der das GroomingToken hält
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688337270626" ID="ID_1810148055" MODIFIED="1688337284937" TEXT="»BlockFlow« : Implementation">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688398675985" ID="ID_291772625" MODIFIED="1688398683406" TEXT="Basis: ExtentFamily">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688398685028" ID="ID_1348599303" MODIFIED="1688398807927" TEXT="Anforderungen">
|
||||
<icon BUILTIN="yes"/>
|
||||
<node CREATED="1688398688699" ID="ID_1432998672" MODIFIED="1688398701914" TEXT="stellt eine Sequenz von »Extents« bereit"/>
|
||||
<node CREATED="1688398703247" ID="ID_1790971931" MODIFIED="1688398726830" TEXT="die aktiven Extents sind geordnet und iterierbar"/>
|
||||
<node CREATED="1688398734470" ID="ID_1849160897" MODIFIED="1688398753155" TEXT="man kann „einen Weiteren“ belegen"/>
|
||||
<node CREATED="1688398760358" ID="ID_944914676" MODIFIED="1688398769143" TEXT="Extent kann freigegeben werden"/>
|
||||
<node CREATED="1688398775540" ID="ID_1082695472" MODIFIED="1688398783382" TEXT="freie Extents wandern in einen Pool"/>
|
||||
<node BACKGROUND_COLOR="#d2beaf" COLOR="#5c4d6e" CREATED="1688398784053" ID="ID_133566735" MODIFIED="1688398798074" TEXT="(geplant) diesen Pool dynamisch verwalten">
|
||||
<icon BUILTIN="hourglass"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688398813243" ID="ID_504623704" MODIFIED="1688398863035" TEXT="Aufbau testgetrieben...">
|
||||
<arrowlink COLOR="#eb4070" DESTINATION="ID_1132827905" ENDARROW="Default" ENDINCLINATION="-593;73;" ID="Arrow_ID_709934622" STARTARROW="None" STARTINCLINATION="-214;-18;"/>
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688398884005" ID="ID_1188543253" MODIFIED="1688398901314" TEXT="Basis-Struktur">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688398888563" ID="ID_1767596073" MODIFIED="1688398901315" TEXT="Iteration">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1688398893220" ID="ID_675575195" MODIFIED="1688398901316" TEXT="belegen / freigeben">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1681347244544" ID="ID_444443795" MODIFIED="1681347486789" TEXT="Basis: Operational Control">
|
||||
<linktarget COLOR="#9c738a" DESTINATION="ID_444443795" ENDARROW="Default" ENDINCLINATION="-1256;-1009;" ID="Arrow_ID_1047384894" SOURCE="ID_594073373" STARTARROW="None" STARTINCLINATION="-902;35;"/>
|
||||
|
|
@ -78189,9 +78568,29 @@ Date:   Thu Apr 20 18:53:17 2023 +0200<br/>
|
|||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1681347258814" ID="ID_1046752034" MODIFIED="1681347345729" TEXT="TimingObservable">
|
||||
<linktarget COLOR="#a54e77" DESTINATION="ID_1046752034" ENDARROW="Default" ENDINCLINATION="-1519;212;" ID="Arrow_ID_1830118942" SOURCE="ID_1139462793" STARTARROW="None" STARTINCLINATION="836;79;"/>
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1685034759152" ID="ID_1462535336" MODIFIED="1685034942586" TEXT="Zeitplanung ist über die Activity-Struktur verteilt">
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1685034759152" ID="ID_1462535336" MODIFIED="1687914505078" TEXT="Zeitplanung ist über die Activity-Struktur verteilt">
|
||||
<linktarget COLOR="#8f29b2" DESTINATION="ID_1462535336" ENDARROW="Default" ENDINCLINATION="885;-44;" ID="Arrow_ID_1037995856" SOURCE="ID_321040814" STARTARROW="None" STARTINCLINATION="503;38;"/>
|
||||
<icon BUILTIN="idea"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909270889" ID="ID_453814959" MODIFIED="1687909331969" TEXT="Meßpunkte">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909320050" ID="ID_1843968618" MODIFIED="1687909327679" TEXT="Speicher-Ort">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909334618" ID="ID_1357717086" MODIFIED="1687909339168" TEXT="Addressierung">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909421308" ID="ID_1195123503" MODIFIED="1687909428855" TEXT="Integration in die Activity-Struktur">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909353179" ID="ID_225279364" MODIFIED="1687914560990" TEXT="Aktualisierung">
|
||||
<linktarget COLOR="#a1195c" DESTINATION="ID_225279364" ENDARROW="Default" ENDINCLINATION="279;0;" ID="Arrow_ID_802789276" SOURCE="ID_724099439" STARTARROW="None" STARTINCLINATION="376;36;"/>
|
||||
<linktarget COLOR="#a1195c" DESTINATION="ID_225279364" ENDARROW="Default" ENDINCLINATION="231;0;" ID="Arrow_ID_940532479" SOURCE="ID_243187423" STARTARROW="None" STARTINCLINATION="71;9;"/>
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1687909361845" ID="ID_1177410843" MODIFIED="1687909381482" TEXT="aktueller Aggregatwert">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#eee5c3" COLOR="#990000" CREATED="1685034805714" ID="ID_601531168" MODIFIED="1685034823237" TEXT="gewichtete moving-Averages">
|
||||
<icon BUILTIN="flag-yellow"/>
|
||||
|
|
@ -78226,6 +78625,19 @@ Date:   Thu Apr 20 18:53:17 2023 +0200<br/>
|
|||
</node>
|
||||
<node BACKGROUND_COLOR="#d2beaf" COLOR="#5c4d6e" CREATED="1681396857183" ID="ID_1618297513" MODIFIED="1681396863069" TEXT="Test/Integration">
|
||||
<icon BUILTIN="hourglass"/>
|
||||
<node CREATED="1688336324305" ID="ID_1933146986" MODIFIED="1688336337035" TEXT="Aufbau">
|
||||
<node BACKGROUND_COLOR="#eef0c5" COLOR="#990000" CREATED="1688336311659" ID="ID_1968961000" MODIFIED="1688337255857" TEXT="Scheduler aufbauen">
|
||||
<arrowlink COLOR="#fe3a58" DESTINATION="ID_323523273" ENDARROW="Default" ENDINCLINATION="-167;17;" ID="Arrow_ID_589297136" STARTARROW="None" STARTINCLINATION="-139;-149;"/>
|
||||
<icon BUILTIN="pencil"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#d2beaf" COLOR="#5c4d6e" CREATED="1688336317130" ID="ID_1362196370" MODIFIED="1688336503785" TEXT="Scheduler+Dispatcher">
|
||||
<icon BUILTIN="hourglass"/>
|
||||
</node>
|
||||
<node BACKGROUND_COLOR="#d2beaf" COLOR="#5c4d6e" CREATED="1688336490682" ID="ID_1706839266" MODIFIED="1688336501746" TEXT="Node-Invocation">
|
||||
<icon BUILTIN="hourglass"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688336338313" ID="ID_1758461421" MODIFIED="1688336340923" TEXT="Integration"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1685399667668" ID="ID_463573092" MODIFIED="1685399687234" TEXT="Begriffe">
|
||||
|
|
@ -84304,6 +84716,78 @@ class Something
|
|||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688166034962" ID="ID_1200591959" MODIFIED="1688166143670" TEXT="Async IO">
|
||||
<linktarget COLOR="#375880" DESTINATION="ID_1200591959" ENDARROW="Default" ENDINCLINATION="-1794;532;" ID="Arrow_ID_1852326782" SOURCE="ID_671880878" STARTARROW="None" STARTINCLINATION="-1625;-156;"/>
|
||||
<node CREATED="1688166157380" ID="ID_1071906059" LINK="https://www.boost.org/doc/libs/1_67_0/doc/html/boost_asio/" MODIFIED="1688166275705" TEXT="Boost ASIO">
|
||||
<node CREATED="1688166215185" ID="ID_66502022" MODIFIED="1688166240475" TEXT="portable + weithin empfohlen und verwendet">
|
||||
<icon BUILTIN="idea"/>
|
||||
<node CREATED="1688166501411" ID="ID_924614417" MODIFIED="1688166519305" TEXT="generische IO-Library (network, terminal, file)"/>
|
||||
<node CREATED="1688166520176" ID="ID_1563680284" MODIFIED="1688166544792" TEXT="unterstützt synchron, asyncrhon, timer, thread-Handling"/>
|
||||
</node>
|
||||
<node CREATED="1688170226497" ID="ID_125244924" MODIFIED="1688170240618" TEXT="verwendet das »Proactor-Pattern«">
|
||||
<node CREATED="1688258008164" ID="ID_95955382" MODIFIED="1688258088027">
|
||||
<richcontent TYPE="NODE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
man ruft explizit eine Service-Loop-Funktion auf — <font face="Monospaced" color="#3c4bc8">io_context::run()</font>
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
<node CREATED="1688258090145" ID="ID_108030465" MODIFIED="1688258117010" TEXT="diese blockt, solange es schwebende Async-IO-Callbacks gibt"/>
|
||||
</node>
|
||||
<node CREATED="1688228541290" ID="ID_472716750" MODIFIED="1688228558262" TEXT="alternativ: »Reactor«-Interface">
|
||||
<node CREATED="1688248251719" ID="ID_1898012569" MODIFIED="1688248277713" TEXT="Callback wenn ein Socket oder Handle lesbar wird"/>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688166164576" ID="ID_808355578" MODIFIED="1688166174345" TEXT="C++20 : Coroutinen"/>
|
||||
<node CREATED="1688166175191" ID="ID_162341966" MODIFIED="1688166179554" TEXT="Memory Mapping">
|
||||
<node CREATED="1688166184079" ID="ID_522935066" MODIFIED="1688166193730" TEXT="nicht portabel / Linux only">
|
||||
<icon BUILTIN="messagebox_warning"/>
|
||||
</node>
|
||||
<node CREATED="1688166384467" ID="ID_427077514" MODIFIED="1688166400444">
|
||||
<richcontent TYPE="NODE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
Teil der Vision / <i>wir wollen das</i>
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
<node CREATED="1688166405176" ID="ID_222460964" MODIFIED="1688166457370" TEXT="es gibt bereits eine Lib-Implementierung von Christian">
|
||||
<richcontent TYPE="NOTE"><html>
|
||||
<head>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<p>
|
||||
<font face="Monospaced" size="2" color="#673b23">/** @file mmap.h </font>
|
||||
</p>
|
||||
<p>
|
||||
<font face="Monospaced" size="2" color="#673b23"> ** MMap objects cover a memory mapped range in a file. </font>
|
||||
</p>
|
||||
<p>
|
||||
<font face="Monospaced" size="2" color="#673b23"> ** They are managed through a global mmap registry/cache. </font>
|
||||
</p>
|
||||
<p>
|
||||
<font face="Monospaced" size="2" color="#673b23"> */ </font>
|
||||
</p>
|
||||
</body>
|
||||
</html></richcontent>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1688253673445" ID="ID_1628355171" MODIFIED="1688253682407" TEXT="Linux: io_uring">
|
||||
<node CREATED="1688253684275" ID="ID_1292759752" LINK="https://stackoverflow.com/a/57451551" MODIFIED="1688253712980" TEXT="war "neu" in 2020 (SO Answer)">
|
||||
<icon BUILTIN="idea"/>
|
||||
</node>
|
||||
</node>
|
||||
</node>
|
||||
<node CREATED="1491098340549" ID="ID_938211341" MODIFIED="1557498707240" TEXT="Toolchain">
|
||||
<node CREATED="1491098346053" ID="ID_1333373693" MODIFIED="1557498707240" TEXT="Doxygen">
|
||||
<node CREATED="1491098370281" ID="ID_1904535196" MODIFIED="1557498707240" TEXT="Konfig"/>
|
||||
|
|
|
|||
Loading…
Reference in a new issue