pub fn pin_thread_to_cpu(cpu: usize) -> Result<()>
Pin the current thread to a specific CPU.
Returns an error if thread pinning fails.