Open magiblot opened 4 years ago
It is not possible with how it works now. I can't guarantee that such thing will be supported (and when if yes), but it at least gave me some food for thoughts, thank you for this.
Hi Dennis, thanks for the quick response. I am also looking into other libraries such as HPX, so I suggest you not to spend time implementing this unless it is actually useful to you. Cheers.
Hi,
I am trying to parallelize a library with a synchronous interface, preserving backwards compatibility. Even if the interface doesn't use Futures, I could still do something like this:
The idea is: since the current task has to wait for a result but cannot be evicted from the thread, it can run pending tasks recursively until the result is ready.
This is obviously worse than having a fully asynchronous interface, but could make it possible to parallelize already existing code and binaries.
Is such a thing possible?
Thanks.