[PATCH] D31883: Don't assume PTHREAD_CREATE_JOINABLE is 0 on all systems
Aleksey Shlyapnikov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 11 12:03:37 PDT 2017
alekseyshl accepted this revision.
alekseyshl added inline comments.
This revision is now accepted and ready to land.
================
Comment at: lib/sanitizer_common/sanitizer_linux.h:59
+#define PTHREAD_CREATE_DETACHED 1
+
// This class reads thread IDs from /proc/<pid>/task using only syscalls.
----------------
I'd prefer them to be an anonymous enum:
enum {
PTHREAD_CREATE_JOINABLE = 0,
PTHREAD_CREATE_DETACHED = 1
}
Preprocessor is evil.
https://reviews.llvm.org/D31883
More information about the llvm-commits
mailing list