Skip to content

Commit c838097

Browse files
lengrongfunishith-fujitsu
authored andcommitted
[Bugfix] fix gettid method is not define (vllm-project#16084)
Signed-off-by: rongfu.leng <[email protected]>
1 parent 126f42e commit c838097

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

csrc/cpu/utils.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@
44
#include <string>
55
#include <sched.h>
66
#endif
7+
#if __GLIBC__ == 2 && __GLIBC_MINOR__ < 30
8+
#include <unistd.h>
9+
#include <sys/syscall.h>
10+
#define gettid() syscall(SYS_gettid)
11+
#endif
712

813
#include "cpu_types.hpp"
914

0 commit comments

Comments
 (0)