Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions Include/object.h
Original file line number Diff line number Diff line change
Expand Up @@ -279,13 +279,9 @@ _Py_ThreadId(void)
__asm__ ("" : "=r" (tp));
tid = tp;
#endif
#elif defined(__s390__)
#if defined(__clang__) && _Py__has_builtin(__builtin_thread_pointer)
#elif defined(__s390__) && _Py__has_builtin(__builtin_thread_pointer)
Comment thread
corona10 marked this conversation as resolved.
Outdated
// Both GCC and Clang have supported __builtin_thread_pointer for s390
tid = (uintptr_t)__builtin_thread_pointer();
Comment thread
corona10 marked this conversation as resolved.
#else
// Access register 0 is used as the thread pointer.
__asm__ ("ear %0,%%a0" : "=d"(tid));
#endif
#else
# error "define _Py_ThreadId for this platform"
#endif
Expand Down