Function current_tid
pub fn current_tid() -> u32Available on crate feature
dial9 and (Android or Linux) only.Expand description
OS thread ID (tid) of the calling thread.
gettid() on Linux/Android, pthread_getthreadid_np() on FreeBSD, and a
stable per-thread counter elsewhere. Allocation-free, so it is safe to call
from the allocator hook. On hot paths prefer [cached_tid], which pays the
syscall once per thread.