1use crate::backend; 2use crate::process::Pid; 3 4/// `gettid()`—Returns the thread ID. 5/// 6/// This returns the OS thread ID, which is not necessarily the same as the 7/// `rust::thread::Thread::id` or the pthread ID. 8/// 9/// # References 10/// - [Linux] 11/// 12/// [Linux]: https://man7.org/linux/man-pages/man2/gettid.2.html 13#[inline] 14#[must_use] 15pub fn gettid() -> Pid { 16 backend::thread::syscalls::gettid() 17} 18