How to exit from message loop dispatch_block () ?

I start thread (or thread_pool)
with message loop in it
consist of dispatch_block () - dispatch_handler ();

How to terminate the thread ?
/calling pthread_abort () works like brutal force kill ?

The bast way to terminate thread
is to exit from (forever) message loop (which terminates thread) ?
/can I do that by attaching a pulse
that terminates my message loop ?

And how to know that the thread is terimnated/desrtroyed ?
/is there, in posix, sth like ‘WatiForThreadTerminate()’ ?