This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Control dependence vs. builtin_unreachable
- From: Steven Bosscher <stevenb dot gcc at gmail dot com>
- To: Jeff Law <law at redhat dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Cc: Richard Biener <richard dot guenther at gmail dot com>, Michael Matz <matz at suse dot de>
- Date: Sun, 6 Jan 2013 01:12:26 +0100
- Subject: Re: Control dependence vs. builtin_unreachable
- References: <CABu31nP9wYa86C1fFR=5EiK5kVCqUj2S+1BzWCeSgq10Kvmn5g@mail.gmail.com> <50E5EF58.4020807@redhat.com> <CABu31nNHjWr92Pm8HrX_fO7_VFj2W=8XkrLiWgWbuN5aoUZZVg@mail.gmail.com>
On Sat, Jan 5, 2013 at 9:10 PM, Steven Bosscher wrote:
> Bootstrapped&tested on powerpc64-unknown-linux-gnu.
And to be clear, bootstrapped with this patch on top:
Index: system.h
===================================================================
--- system.h (revision 194924)
+++ system.h (working copy)
@@ -698,7 +698,7 @@
/* Use gcc_unreachable() to mark unreachable locations (like an
unreachable default case of a switch. Do not use gcc_assert(0). */
-#if (GCC_VERSION >= 4005) && !ENABLE_ASSERT_CHECKING
+#if (GCC_VERSION >= 4005) //&& !ENABLE_ASSERT_CHECKING
#define gcc_unreachable() __builtin_unreachable()
#else
#define gcc_unreachable() (fancy_abort (__FILE__, __LINE__, __FUNCTION__))
Otherwise, __builtin_unreachable would be almost unused and
bootstrap+test wouldn't prove much :-)
Ciao!
Steven