summaryrefslogtreecommitdiffstats
path: root/include/llvm/Support/Compiler.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/llvm/Support/Compiler.h')
-rw-r--r--include/llvm/Support/Compiler.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/llvm/Support/Compiler.h b/include/llvm/Support/Compiler.h
index 90292df..342a97d 100644
--- a/include/llvm/Support/Compiler.h
+++ b/include/llvm/Support/Compiler.h
@@ -23,7 +23,7 @@
#define VISIBILITY_HIDDEN
#endif
-#if (__GNUC__ >= 4)
+#if (__GNUC__ >= 4 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1))
#define ATTRIBUTE_USED __attribute__((__used__))
#else
#define ATTRIBUTE_USED
@@ -56,4 +56,10 @@
#define DISABLE_INLINE
#endif
+#ifdef __GNUC__
+#define NORETURN __attribute__((noreturn))
+#else
+#define NORETURN
+#endif
+
#endif
OpenPOWER on IntegriCloud