Nat Goodspeed
3128334364
Initial cut at supporting arbitrary user-coded scheduler properties.
...
Introduce fiber_properties class from which to derive a specific properties
class for a particular user-coded sched_algorithm subclass.
Add sched_algorithm::property_change(worker_fiber*, fiber_properties*) method
to allow a fiber_properties subclass method to notify the sched_algorithm
subclass of a change in a relevant property. This generalizes the present
priority() method.
Introduce sched_algorithm_with_properties<PROPS> template class from which to
derive a user-coded scheduler that uses fiber_properties subclass PROPS. Give
it ref-returning properties(fiber::id) and properties(worker_fiber*) methods.
Introduce fiber_properties* field in worker_fiber, and initialize it to 0.
Delete it when the worker_fiber is destroyed. Give it pointer-flavored access
methods. Normally this field will remain 0; but the first time the
worker_fiber is passed to a sched_algorithm_with_properties<PROPS> subclass,
its awakened() method will instantiate the relevant PROPS subclass.
Add ref-returning fiber::properties<PROPS>() method. Calling this method
presumes that the current thread's sched_algorithm is derived from
sched_algorithm_with_properties<PROPS>.
Also add this_fiber::properties<PROPS>() with the same restriction.
Add ref-returning fm_properties<PROPS>() functions to implement
fiber::properties<PROPS>() and this_fiber::properties<PROPS>().
Allow sched_algorithm_with_properties to extract the worker_fiber* from a
fiber::id (aka worker_fiber::id) so it can present public-facing
properties(id) method as well as properties(worker_fiber*) method.
(cherry picked from commit 18c7f2c13b9642826b42aa3f6fa0a6642fce9cbc)
Conflicts:
include/boost/fiber/detail/worker_fiber.hpp
include/boost/fiber/fiber_manager.hpp
2014-11-08 11:03:51 -05:00
Oliver Kowalke
1c3b447716
some fixes
2014-09-26 17:57:53 +02:00
Oliver Kowalke
7483a729aa
some fixes
2014-09-25 18:52:04 +02:00
Oliver Kowalke
7fb469cd10
some fixes
2014-09-24 19:18:44 +02:00
Oliver Kowalke
ae1ebd7b01
Revert "optimize the example for asio loop"
...
This reverts commit 61a8a8ea89
.
2014-09-18 19:25:58 +02:00
Vincent Lee
61a8a8ea89
optimize the example for asio loop
2014-09-15 18:14:15 +08:00
Oliver Kowalke
c005bb2c8f
doc update
2014-09-09 20:40:26 +02:00
Oliver Kowalke
0948d577dc
fix examples
2014-08-23 14:09:21 +02:00
Oliver Kowalke
4b604ff93a
test for multiple definitions
2014-08-21 17:28:28 +02:00
Oliver Kowalke
e24f27c75c
fix publish-subscriber example
2014-08-21 17:27:53 +02:00
Oliver Kowalke
ef6c16e934
optimized server app in publish-subscribe example
2014-08-17 20:41:31 +02:00
Oliver Kowalke
22850775ca
variadric tempalte args
2014-07-15 20:33:14 +02:00
Oliver Kowalke
7ef6302f86
arbitrary clock::time_point conforming to chrono clock concept allowed
2014-07-08 17:41:59 +02:00
Oliver Kowalke
5cf28979a5
queues should support value_pop()
2014-07-07 17:40:53 +02:00
Oliver Kowalke
b936512136
remove mutex::scoped_lock by unique_lock< mutex >
2014-06-29 13:31:01 +02:00
Oliver Kowalke
7116c7ff03
use fm_<xyz> functions in asio intregration files
2014-06-29 13:30:40 +02:00
Oliver Kowalke
e72e388843
enable other examples
2014-06-29 13:24:52 +02:00
Oliver Kowalke
d2eea37b53
use mutex + deque as ready-queue in example work-stealing
2014-06-23 18:05:06 +02:00
Oliver Kowalke
026003bb65
use the free fm_<xyz> - functions
2014-06-17 11:51:14 +02:00
Oliver Kowalke
f4defed2b5
workstealing example
2014-03-25 17:45:56 +01:00
Oliver Kowalke
b5b22ff606
workstealing example
2014-03-24 20:05:14 +01:00
Oliver Kowalke
e031ba4762
move asio-stuff to example section
2014-03-24 19:14:38 +01:00
Oliver Kowalke
ab91ab52b8
changes for boost.asio
2014-03-23 18:20:15 +01:00
Oliver Kowalke
9f7f74f662
use symmetric_coroutine<>::yield_type::operator()()
2014-03-15 19:16:13 +01:00
Oliver Kowalke
a1e3c1d081
merge from branch feature/tls
2014-03-08 10:16:22 +01:00
Oliver Kowalke
5b6d77b6b5
renaming of fiber classes
2014-03-05 17:30:11 +01:00
Oliver Kowalke
67111d3e58
workstealing round-robin scheduler moved to examples
2014-03-04 18:01:42 +01:00
Oliver Kowalke
2b37b33011
use asymmetric_coroutine<> from (coroutine branch develop)
2014-02-22 21:26:28 +01:00
olk
552c175be1
add some comments to publish-subscibe example
2014-01-07 08:46:26 +01:00
olk
a2611f032a
change copy right in example/future_mt.cpp
2014-01-07 07:48:53 +01:00
Oliver Kowalke
8de7066392
fix library name in Jamfile
2013-12-30 15:33:13 +01:00
Oliver Kowalke
3cc7d06482
additional example for transfering future between threads
2013-12-29 22:21:44 +01:00
Mario Lang
d471d7133d
Fix some typos.
2013-12-29 14:00:36 +01:00
Oliver Kowalke
7594f74568
add required compiler flags for segmentad-stacks
2013-12-08 15:02:49 +01:00
Oliver Kowalke
511b740ec2
default-scheduler allocated
2013-12-02 19:45:48 +01:00
Oliver Kowalke
64529df3b4
changed interface of (un)bounded_queue
2013-11-17 18:55:32 +01:00
Oliver Kowalke
393797a94e
fix queues related to closed queue and poping values
2013-11-02 14:49:25 +01:00
Oliver Kowalke
bac5c197c0
remove queue::close() from ping_pong example
2013-11-02 14:21:32 +01:00
Oliver Kowalke
6bb976b4d3
fix queues
2013-11-02 14:15:05 +01:00
Oliver Kowalke
f04b484a21
fix test coein example simple.cpp
2013-10-28 13:38:22 +01:00
Oliver Kowalke
436883ca33
add workstealing round_robin
2013-10-25 18:01:56 +02:00
Oliver Kowalke
98f54ad0e4
rename fibers::asio::io_service -> fibers::asio::round_robin
2013-10-24 18:42:07 +02:00
Oliver Kowalke
ec8a11e60c
atomic fiber::state_
2013-10-17 19:21:26 +02:00
Oliver Kowalke
147d41833a
remove exception example
2013-10-01 19:43:29 +02:00
Oliver Kowalke
500c1e605b
example regarding to exceptions
2013-09-29 11:05:57 +02:00
Oliver Kowalke
4465d50c0c
example interrupting fiber
2013-09-29 10:42:11 +02:00
Oliver Kowalke
2a6ea310a1
fix linkingissue
2013-09-28 16:53:04 +02:00
Oliver Kowalke
84d2a50491
fix Jamfiles and multithreading
2013-09-28 10:24:47 +02:00
Oliver Kowalke
32405f7a99
add asio example demonstaratiing sync. of fibers
2013-09-11 09:27:27 +02:00
Oliver Kowalke
e996d2e28f
use coroutines inside fiber
2013-09-09 08:52:26 +02:00
Oliver Kowalke
00ec9d32a3
update
2013-08-28 21:57:14 +02:00
Oliver Kowalke
d91578120f
fix libname
2013-08-18 22:14:10 +02:00
Oliver Kowalke
9d67164839
adapt io_service to wait-op requirements
2013-08-18 10:52:36 +02:00
Oliver Kowalke
3485f551aa
add async()
2013-08-18 10:30:15 +02:00
Oliver Kowalke
94482d25b6
add time-point to schedulable fiber
2013-08-13 18:23:53 +02:00
Oliver Kowalke
f06b6cf0d4
fix auto-link in config.hpp
2013-08-13 10:27:02 +02:00
Oliver Kowalke
11eb0c6082
add boost.asio spawn() for fibers
2013-06-19 18:03:48 +02:00
Oliver Kowalke
9d58afd3ec
add some examples using boost.asio async_result
2013-06-16 16:19:24 +02:00
Oliver Kowalke
de3bc64e4f
boost.asio related stuff (fiber-aware io_servic etc.)
2013-06-14 20:37:47 +02:00
Oliver Kowalke
31c764b7bc
some code clean-up
2013-06-14 16:53:46 +02:00
Oliver Kowalke
04ddde32f1
refactor of support of boost.asio async_result (use_future_t)
2013-06-13 17:39:03 +02:00
Oliver Kowalke
fc9938190e
add example using boost.asio async_result feature
2013-06-12 16:58:45 +02:00
Oliver Kowalke
61c3fd4589
some fixes
2013-06-10 20:11:52 +02:00
Oliver Kowalke
9dfeb585d6
remove code for fiber migration
2013-03-19 17:44:43 +01:00
Oliver Kowalke
5ff11b0df4
example fiber-steeling updatedd
2013-03-16 19:57:15 +01:00
Oliver Kowalke
7ab57b66f7
examples updated
2013-03-16 19:54:59 +01:00
Oliver Kowalke
b752574dfa
disable future tests and example
2013-02-27 20:16:03 +01:00
Oliver Kowalke
b4623a7e53
fix example join
2013-01-30 19:42:55 +01:00
Oliver Kowalke
9ad0ec1937
adapt examples
2013-01-30 19:16:19 +01:00
Oliver Kowalke
017039c3b5
addapt examples to new version
2013-01-12 21:16:46 +01:00
Oliver Kowalke
cfdcf1d16a
interface algorithm, round_robin
2012-12-19 19:37:05 +01:00
Oliver Kowalke
1e248b0216
require to set scheduler for each os-thread
2012-12-17 19:54:34 +01:00
Oliver Kowalke
81e62e8962
changed directory structure as required by modularized-boost
2012-12-09 15:22:59 +01:00