void
future_join_all(qthread_t *me, aligned_t *fta, int ftc);
The first argument is a pointer to the qthread executing the join. The second argument, fta, is an array of the return locations of the futures the calling thread will join. The final argument, ftc, indicates the number of futures in the array.
When a thread attempts to join with future computations, the action may block, as futures are waiting for the number of active threads to drop. Deadlock may result if threads are holding resources while attempting to join to futures which are waiting for resources. Therefore, when a thread attempts to join, it must explicitly declare itself inactive using the future_yield() function, then reactivate itself using the future_acquire() function.
The typical sequence for creating futures is:
1) yield
2) loop creating futures
3) [optional: join with futures]
4) acquire