It's not as immediate as say a function return would be immediate, but the main thread is going to be marked ready pretty soon after the waited for thread exits.
It kinda depends on what else is going on in the system. It lots of processes and threads are already running at 100%, then an idler waiting for a thread to exit might be in for what seems like a long wait.