]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - include/linux/compiler-gcc4.h
Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
[karo-tx-linux.git] / include / linux / compiler-gcc4.h
index e6ef279ca20c4147f4cc8918c7c20ef9964d0ffa..94dea3ffbfa19576e2cd8bb59b56658465101b49 100644 (file)
    the kernel context */
 #define __cold                 __attribute__((__cold__))
 
+
+#if __GNUC_MINOR__ >= 5
+/*
+ * Mark a position in code as unreachable.  This can be used to
+ * suppress control flow warnings after asm blocks that transfer
+ * control elsewhere.
+ *
+ * Early snapshots of gcc 4.5 don't support this and we can't detect
+ * this in the preprocessor, but we can live with this because they're
+ * unreleased.  Really, we need to have autoconf for the kernel.
+ */
+#define unreachable() __builtin_unreachable()
+#endif
+
 #endif
 
 #if __GNUC_MINOR__ > 0