Oliver Kowalke
4dc5aaab59
add example of work-sharing
2015-09-07 11:53:13 +02:00
Oliver Kowalke
7233f617d7
remove class scheduler - fiber_context has static TLS
...
- detail:.scheduler was removed
- fiber_context has a static thread-local pointer to the active
fiber_context
- fiber_context has member to pointer of fiber_manager
- functions of fiber_manager are accessed only via fiber_context
- if fiber f is resumed, the fiber_manager of the current active fiber
f' is assigned to f
-> that is necessary if f was stolen form another thread
2015-09-07 11:50:01 +02:00
Oliver Kowalke
bc044fbed2
stuff
2015-09-06 21:36:06 +02:00
Oliver Kowalke
26ea3aa41c
fix performace footnote issue
2015-09-05 15:29:42 +02:00
Oliver Kowalke
c4cfef7148
fix documentation issue related to footnote in table
2015-09-05 15:24:30 +02:00
Oliver Kowalke
2dbdd73e6e
fix performance tests for std::thread
2015-09-05 15:21:43 +02:00
Oliver Kowalke
68cc0915b9
use passed overhead duration in performance tests
2015-09-05 14:00:58 +02:00
Oliver Kowalke
f8c97ffa16
initialize duration with zero
2015-09-05 13:49:29 +02:00
Oliver Kowalke
2e26806bb3
update performance tests and correct values in performance docu
2015-09-05 13:41:03 +02:00
Oliver Kowalke
ddf2115347
do not measure fiber creation together with join/yield/detach
2015-09-05 12:19:31 +02:00
Oliver Kowalke
66e7b59424
fix usage of std::chrono
2015-09-05 11:57:36 +02:00
Oliver Kowalke
0a296315f7
use steady_clock isntead of high_resolution_clock
2015-09-05 10:57:50 +02:00
Oliver Kowalke
4187c68f4e
release mutex before signal condition-variable
2015-09-05 10:37:27 +02:00
Oliver Kowalke
983f2efb43
replace decltype(auto) -> void in lambda expression
2015-09-05 08:00:26 +02:00
Oliver Kowalke
af6eeb3380
fix header issue
2015-09-05 04:48:59 +02:00
Oliver Kowalke
0e8af4a29f
fix future<>::wait_until() - use time_point< Clock, Duration >
2015-09-05 04:03:55 +02:00
Oliver Kowalke
c24c73dc11
documentation: hint for stack allocation in performance tests
2015-09-03 20:28:08 +02:00
Oliver Kowalke
4de24d4eec
Merge pull request #64 from nat-goodspeed/develop
...
Finish proofreading pass.
2015-09-03 16:02:36 +02:00
Nat Goodspeed
d653cbdcc6
Finish proofreading pass.
...
Add a note to the condition_variable::wait_for(..., pred) overload.
fiber_specific_ptr::reset() has no default argument.
Remove mention of launch policy deferred, since no API accepts a launch
policy argument.
Copy construction or copy assignment of a shared_future leaves other.valid()
unchanged. It won't be 'true' unless it was 'true' before.
Mention that [shared_]future::get_exception_ptr() does not invalidate.
Note that 'blocks' and 'suspends' are used interchangeably.
Add some cross-references; add link to std::allocator_arg_t. Clarify the
cross-reference to the paragraph describing BOOST_FIBERS_NO_ATOMICS.
Reformat some overly-long source lines.
2015-09-03 09:16:09 -04:00
Nat Goodspeed
bcdb555821
Use std::shared_ptr and std::make_shared for promise_handler.
...
Publish promise_handler::promise_ptr and use it in asio_handler_invoke() for
consistency.
2015-09-03 08:47:25 -04:00
Nat Goodspeed
64b56e2200
Merge branch 'develop' of github.com:nat-goodspeed/boost-fiber into develop
2015-09-03 08:30:27 -04:00
Oliver Kowalke
b5f0a7e713
Merge pull request #63 from nat-goodspeed/develop
...
Reconcile condition_variable::wait_for(..., pred) with wait_until(..., pred).
2015-09-03 13:42:49 +02:00
Nat Goodspeed
c724ef65a3
Merge branch 'develop' of github.com:olk/boost-fiber into develop
2015-09-03 07:13:52 -04:00
Nat Goodspeed
f5cfa24f02
Merge branch 'develop' of http://github.com/olk/boost-fiber into develop
2015-09-03 07:13:10 -04:00
Nat Goodspeed
bd2eb2fe72
Reconcile condition_variable::wait_for(pred) with wait_until(pred).
2015-09-03 07:13:01 -04:00
Oliver Kowalke
07ac7b8f12
Merge pull request #62 from nat-goodspeed/develop
...
More proofreading tweaks
2015-09-03 07:58:36 +02:00
Nat Goodspeed
b465af2c39
Merge branch 'develop' of github.com:olk/boost-fiber into develop
2015-09-02 16:59:44 -04:00
Nat Goodspeed
abc1aa610e
Proofreading pass continues through stack allocation.
2015-09-02 16:59:06 -04:00
Oliver Kowalke
be3d67a109
add end marker to example priority
2015-09-02 20:29:09 +02:00
Oliver Kowalke
86d9f20458
update performance tests
2015-09-02 20:09:22 +02:00
Oliver Kowalke
52c03cb5fd
fix merge error
2015-09-02 19:56:26 +02:00
Oliver Kowalke
ba35ac6de2
update documentation
2015-09-02 19:43:33 +02:00
Oliver Kowalke
a173c047a6
update documentation
2015-09-02 19:41:08 +02:00
Oliver Kowalke
c2c397e4fe
Merge pull request #61 from nat-goodspeed/develop
...
Add note about this_fiber::properties<>() possibly yielding.
2015-09-02 19:33:42 +02:00
Nat Goodspeed
2119ead28d
Add note about this_fiber::properties<>() possibly yielding.
2015-09-02 12:07:57 -04:00
Oliver Kowalke
440f003df6
Merge pull request #60 from nat-goodspeed/develop
...
Correct mistaken advice about properties for newly-launched fiber.
2015-09-02 08:08:53 +02:00
Nat Goodspeed
227b621e43
Continuing proofreading pass
2015-09-01 21:07:53 -04:00
Nat Goodspeed
37a0490bbd
Fix bug in this_fiber::properties<>().
...
When the running thread's main fiber calls this_fiber::properties<>() without
yet having passed through sched_algorithm_with_properties::awakened(), which
is what actually instantiates the fiber_properties subclass, you could end up
without a properties instance. Fortunately there's an easy workaround: call
yield().
Remove that workaround from examples/priority.cpp.
2015-09-01 20:21:13 -04:00
Nat Goodspeed
aeaef6510f
Reverse advice about when to set the properties for a new fiber.
...
Change which example code we show for this_fiber::properties<>() and
fiber::properties<>().
2015-09-01 19:55:33 -04:00
Nat Goodspeed
1007d7db6d
Remove fiber::properties<>() requirement to have been scheduled once.
...
Since instantiating a fiber object immediately passes it to the scheduler,
it should be impossible to violate that precondition.
2015-09-01 19:54:55 -04:00
Nat Goodspeed
11b06c25dd
Fix bug in priority_scheduler::property_change().
...
The complex logic to make a single pass through the ready queue to find the
old location and also the new insertion point was unfortunately error-prone.
Recast it as two separate passes: a simple search loop to find and unlink the
fiber_context*, then a call to awakened() to reinsert it in the correct place.
2015-09-01 19:16:47 -04:00
Oliver Kowalke
847d84e50e
Merge pull request #59 from nat-goodspeed/develop
...
Notes about fiber launch and barrier awakening.
2015-09-01 17:41:26 +02:00
Oliver Kowalke
82143be5aa
update documentation + formating
2015-09-01 17:32:07 +02:00
Nat Goodspeed
518709249b
Merge branch 'develop' of github.com:olk/boost-fiber into develop
2015-09-01 11:26:36 -04:00
Nat Goodspeed
90d8e059f0
Notes about fiber launch and barrier awakening.
2015-09-01 11:25:36 -04:00
Oliver Kowalke
fefffd37eb
update documentation
2015-09-01 17:17:38 +02:00
Oliver Kowalke
d15ea79bfa
Merge pull request #58 from nat-goodspeed/develop
...
Start of proofreading pass
2015-09-01 07:59:02 +02:00
Oliver Kowalke
e91bbf1274
doucmentation: fix references to files in performance.qbk
2015-09-01 06:39:50 +02:00
Nat Goodspeed
c6ccbbc112
Add footnote about yield() being insufficient to interrupt a detached fiber.
2015-08-31 20:30:57 -04:00
Nat Goodspeed
f5c153bf2c
Merge branch 'develop' of github.com:olk/boost-fiber into develop
2015-08-31 20:12:13 -04:00