Skip to content

Commit d8b3008

Browse files
authored
Merge pull request #44 from flang-compiler/sles11
Change for SLES 11 support.
2 parents 3984416 + d49bbf4 commit d8b3008

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/Support/Unix/Threading.inc

+4
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ void llvm::set_thread_name(const Twine &Name) {
141141
if (get_max_thread_name_length() > 0)
142142
NameStr = NameStr.take_back(get_max_thread_name_length());
143143
(void)NameStr;
144+
#if 0
144145
#if defined(__linux__)
145146
#if (defined(__GLIBC__) && defined(_GNU_SOURCE)) || defined(__ANDROID__)
146147
#if HAVE_PTHREAD_SETNAME_NP
@@ -155,6 +156,7 @@ void llvm::set_thread_name(const Twine &Name) {
155156
#elif defined(__APPLE__)
156157
::pthread_setname_np(NameStr.data());
157158
#endif
159+
#endif
158160
}
159161

160162
void llvm::get_thread_name(SmallVectorImpl<char> &Name) {
@@ -203,6 +205,7 @@ void llvm::get_thread_name(SmallVectorImpl<char> &Name) {
203205

204206
Name.append(buf, buf + strlen(buf));
205207
#elif defined(__linux__)
208+
#if 0
206209
#if (defined(__GLIBC__) && defined(_GNU_SOURCE)) || defined(__ANDROID__)
207210
#if HAVE_PTHREAD_GETNAME_NP
208211
constexpr uint32_t len = get_max_thread_name_length_impl();
@@ -212,4 +215,5 @@ void llvm::get_thread_name(SmallVectorImpl<char> &Name) {
212215
#endif
213216
#endif
214217
#endif
218+
#endif
215219
}

0 commit comments

Comments
 (0)