Currently, the return type of a work_item variant execute function supports the following return types:
hpx::future<T>
allscale::treeture<T>
hpx::unused_type
The last return type is important for performance optimizations. The process variants seldomly spawn other work items asynchronously, as such, it is beneficial for performance reasons, to avoid the allscale::make_ready_treeture(...) return in such cases. Even a ready treeture is associated with some overheads.
It should be possible, to support arbitrary, non treeture return types, like void instead of hpx::util::unused_type or int.
Currently, the return type of a work_item variant
executefunction supports the following return types:hpx::future<T>allscale::treeture<T>hpx::unused_typeThe last return type is important for performance optimizations. The process variants seldomly spawn other work items asynchronously, as such, it is beneficial for performance reasons, to avoid the
allscale::make_ready_treeture(...)return in such cases. Even a ready treeture is associated with some overheads.It should be possible, to support arbitrary, non treeture return types, like
voidinstead ofhpx::util::unused_typeor int.