Skip to content

Commit d5545b3

Browse files
authored
Merge pull request #47 from schweitzpgi/release_70
Change for SLES 11 support. We don't want to include
2 parents 8dfb4b1 + d8da326 commit d5545b3

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/Support/Unix/Threading.inc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ void llvm::set_thread_name(const Twine &Name) {
142142
if (get_max_thread_name_length() > 0)
143143
NameStr = NameStr.take_back(get_max_thread_name_length() - 1);
144144
(void)NameStr;
145+
#if 0
145146
#if defined(__linux__)
146147
#if (defined(__GLIBC__) && defined(_GNU_SOURCE)) || defined(__ANDROID__)
147148
#if HAVE_PTHREAD_SETNAME_NP
@@ -156,6 +157,7 @@ void llvm::set_thread_name(const Twine &Name) {
156157
#elif defined(__APPLE__)
157158
::pthread_setname_np(NameStr.data());
158159
#endif
160+
#endif
159161
}
160162

161163
void llvm::get_thread_name(SmallVectorImpl<char> &Name) {
@@ -204,11 +206,13 @@ void llvm::get_thread_name(SmallVectorImpl<char> &Name) {
204206

205207
Name.append(buf, buf + strlen(buf));
206208
#elif defined(__linux__)
209+
#if 0
207210
#if HAVE_PTHREAD_GETNAME_NP
208211
constexpr uint32_t len = get_max_thread_name_length_impl();
209212
char Buffer[len] = {'\0'}; // FIXME: working around MSan false positive.
210213
if (0 == ::pthread_getname_np(::pthread_self(), Buffer, len))
211214
Name.append(Buffer, Buffer + strlen(Buffer));
212215
#endif
213216
#endif
217+
#endif
214218
}

0 commit comments

Comments
 (0)