- Feb 26, 2021
-
-
Florian Fischer authored
Available implementations configurations through the meson option 'locked_unbounded_queue_implementation' are: mutex - our current LockedUnboundedQueue implementation using std::mutex rwlock - An implementation with pthread_rwlock. The implementations tries to upgrade its rdlock and drops and acquires a wrlock on failure shared_mutex - An implementation using std::shared_mutex. dequeue() acquires a shared lock at first, drops it and acquires a unique lock boost_shared_mutex - An implementation using boost::shared_mutex. dequeue() acquires an upgradable lock and upgrade it to a unique lock if necessary
-
Florian Fischer authored
The emper header LockedUnboundedQueue.hpp could depend on different libraries according to the implementation. To link those dependencies with everything including LockedUnboundedQueue.hpp we propagate all emper_dependencies through emper_dep. And using emper_dep as a dependency seems anyway better than essentially writing down emper_dep manually each time. emper_dep essentially is: (link_with:emper, include_directories: emper_all_include)
-
Florian Schmaus authored
add a batch optimization for the global completer See merge request !110
-
Florian Schmaus authored
Minor improvements See merge request !112
-
Florian Fischer authored
This change introduces new scheduleFromAnywhere methods which take a range of Fibers to schedule. Blockable gets a new method returning the fiber used to start the unblocked context, which is used by Future/PartialCompletableFuture to provide a way of completion and returning the continuation Fiber to the caller so they may schedule the continuation how they want. If the meson option io_batch_anywhere_completions is set the global completer will collect all callback and continuation fibers before scheduling them at once when it is done reaping the completions. The idea is that taking the AnywhereQueue write lock and calling onNewWork must only be done once. TODO: investigate if onNewWork should be extended by an amountOfWork argument which determines how many worker can be awoken and have work to do. This should be trivially since our WorkerWakeupSemaphore implementations already support notify_many(), which may be implemented in terms of notify_all though.
-
Florian Schmaus authored
-
Florian Schmaus authored
-
- Feb 25, 2021
-
-
Florian Schmaus authored
[Runtime] add env options to define workerCount and pinningOffset See merge request !109
-
Florian Fischer authored
Introduced environment variables: * EMPER_WORKER_COUNT: specifies how many worker the Runtime default constructor starts. * EMPER_PINNING_OFFSET: specifies the cpu id where the workers should be pinned round robin. Both variables allow multiple emper processes to run on the same system by splitting the available cores. EMPER_WORKER_COUNT=1 build/apps/echoserver && EMPER_WORKER_COUNT=1 EMPER_PINNING_OFFSET=1 build/apps/echoclient Starts a single threaded echoserver on core 0 and a single threaded echo client on core 1.
-
Florian Schmaus authored
Minor fixes See merge request !108
-
Florian Schmaus authored
-
Florian Schmaus authored
-
- Feb 24, 2021
-
-
Florian Schmaus authored
add three semaphore implementations and make wakeupSem configurable See merge request !107
-
- Feb 23, 2021
-
-
Florian Fischer authored
LockedSemaphore is the already existening Semaphore using a mutex and a condition variable. PosixMutex is a thin wrapper around a POSIX semaphore. SpuriousFutexSemaphore is a atomic/futex based implementation prune to spurious wakeups which is fine for the worker wakeup usecase.
-
Florian Schmaus authored
[Runtime] Fix skipWakeupThreshold value See merge request !106
-
- Feb 22, 2021
-
-
Florian Schmaus authored
Adjust to sem_getvalue() being allowed to return 0 if there are waiting workers.
-
Florian Schmaus authored
[Runtime] use a semaphore to suspend/wakeup workers See merge request i4/manycore/emper!99
-
Florian Fischer authored
To prevent deadlocks where all workers are going to sleep and new work arrives from without emper we always increment the wakeup semaphore unless we observe its value as > worker count. If the semaphore value is bigger than worker count it is guarantied that at least on worker will not block and will iterate a second time in its dispatchLoop observing the new work.
-
Florian Schmaus authored
Fix build for systems with incomplete C++ standard library See merge request !105
-
Florian Fischer authored
-
Florian Fischer authored
-
- Feb 20, 2021
-
-
Florian Schmaus authored
Fix Actor::waitUntilIdle See merge request !103
-
Florian Schmaus authored
[Makefile] fix smoke-test/static-analysis target See merge request !104
-
Florian Fischer authored
-
Florian Schmaus authored
This adds yet another target "smoke-test-suite", which just runs all tests in the 'smoke' test suite. The static-analysis target was changed to include *all* static analysis thingies we have, even 'doc' as Doxygen does also do some checks that the documentation is "correct". The smoke-test target is also kept, as it allows developers to simply run all smoke tests. Furthermore, this adds some missing PHONY declarations in the Makefile. The gitlab-ci now runs the smoke-test-suite and static-analysis targets in two different jobs. Previously the smoke-test would also run the static-analysis target, which was not intended.
-
- Feb 19, 2021
-
-
Florian Fischer authored
Using an AlarmFuture blocks the Fiber executing Actor::waitUntilIdle, freeing its current worker and thus preventing life-locks. Where all workers are sleeping except one. Which executes the Actor::waitUntilIdle Fiber causing a starvation of the actual Actor.
-
Florian Fischer authored
-
- Feb 18, 2021
-
-
Florian Schmaus authored
[meson] fix version header custom target for meson >= 0.57 See merge request !96
-
Florian Fischer authored
Apparently custom_target no longer supports the @CURRENT_SOURCE_DIR@ and @SOURCE_DIR@ substitutions. We now locate the script using find_program(). Since meson.project_source_dir() is not available in older meson version there is a version check.
-
- Feb 17, 2021
-
-
Florian Schmaus authored
[IO] replace the std::mutex.try_lock with our own std::atomic based implementation See merge request !95
-
- Feb 16, 2021
-
-
Florian Fischer authored
-
- Feb 10, 2021
-
-
Florian Schmaus authored
[IO] add option to use a common async backend for all io_urings See merge request !94
-
Florian Fischer authored
-
- Feb 08, 2021
-
-
Florian Schmaus authored
[EchoServerCallback] report error value passed to callback not errno See merge request !93
-
Florian Fischer authored
-
- Feb 07, 2021
-
-
Florian Schmaus authored
[IO/Stats] make sure only Future's with a buffer have a completion expectation See merge request !92
-
Florian Schmaus authored
[IO] add FutureError and throw it when wait is called on a Future with callback See merge request !91
-
Florian Schmaus authored
[IO] add output file support to echoclient See merge request !90
-
Florian Fischer authored
Currently future.len if set is used as completion expectation. This does not make any sense for Futures using the len field for different values than a buffer length. For example the OpenatFuture uses future.len for the flags passed to openat. Those flags should not be interpreted as an expectation about the completion value (a file descriptor).
-
- Feb 06, 2021
-
-
Florian Fischer authored
The wait() call on a Future with callback currently will never return therefore calling wait() is disallowed.
-