Threads must be joined on scheduler termination and tasks must be pushed onto the stack to allow better memory management.