Boost logo

Boost :

Subject: Re: [boost] [Coroutine] What happened to WINFIBERS?
From: Oliver Kowalke (oliver.kowalke_at_[hidden])
Date: 2016-04-11 07:41:07


2016-04-11 12:06 GMT+02:00 Mikhail Strelnikov <mikhail.strelnikov_at_[hidden]>
:

> 1) Calling functions like GetModuleFileName, GetTimeZoneInformation
> without BOOST_USE_WINFIBERS
> was leading to crash in the past (see
> https://svn.boost.org/trac/boost/ticket/10657 ). Looks like it is fixed
> now, but will this fix work in future Windows versions? Can they change
> something in Windows 11 so that old application using Boost.Context will
> crash?
>

Maybe - Windows is closed source and MS did not document all parts of the
TEB.
It is likely that some TEB-parts, that needs to be swapped during context
switch, aren't touched in boost.context.

> 2) I have an application that (knowing BOOST_USE_WINFIBERS is on) uses
> ::GetCurrentFiber().
> Could you please recommend on how to migrate it to upcoming
> Boost? execution_context::current looks promising, but it is only available
> in v1, not in v2 (which is default). Should I compile
> with BOOST_EXECUTION_CONTEXT=1? What is disadvantage of this?
>

v1 is slower (access to TLS) - v1 uses the same assembler code as v2
v1 is required to support segmented stacks


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk