From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20731 invoked by alias); 28 Jan 2014 14:52:38 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 20718 invoked by uid 89); 28 Jan 2014 14:52:38 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-oa0-f42.google.com Received: from mail-oa0-f42.google.com (HELO mail-oa0-f42.google.com) (209.85.219.42) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Tue, 28 Jan 2014 14:52:32 +0000 Received: by mail-oa0-f42.google.com with SMTP id i7so506023oag.15 for ; Tue, 28 Jan 2014 06:52:31 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=EHxcs9X+/7KTwwNxWbDdsmFMhhuTrURz74OdEZaG/kE=; b=IfaUxMxg3C/XrSKGhfZTy4Ux2ac3xal7wvwmyev8iw0UxifikGcOJ50tkLVUbw3so2 CG5cff5BLxBKVodf3Z73K6VuC8NkbKE1hE9/6jxdW1yihd+rjOkEek56JIIaMC8zYq89 AzI8go3DyS2BhTY7NStB6CZsVmTspjSItR6cSbeKK7hyeDxs+r2N+8r7GMbaJm75Obd/ u682CXvzTd5EgWxBCUCeIslqjpYGu3W+rG5x6Ai8A7VIzjOOazTZzz/VI/iiHcpq05rD RZQblBmT1hVflaifoAWnP1ZbQ72Fl6iCOfFW/hXQlXhNxPtFtCdaOl9t3GVUHC+Npg8+ Ua+Q== X-Gm-Message-State: ALoCoQnlAsbe7aZOV8TEfTBWJM3IOxuarlnSkdz9yjGP9+Hx0Zk+Jcf7I9Q/iyBVoy+fv9Rat46gT6GwpMLuAyVtRmxtHYi1OoHSoSbd4ObrXMFkmnkMf1BhuMee6JfLFF76/UAlzNbWCHAkGfKBTOwe/U/9ZrIgYJDIoFUvhcXBN41zBCi3Jj3RRWVZ3YJklUPrqxIW1rmkm7feaLsoufngLL56IYcmmA== MIME-Version: 1.0 X-Received: by 10.182.22.135 with SMTP id d7mr1398645obf.1.1390920750934; Tue, 28 Jan 2014 06:52:30 -0800 (PST) Received: by 10.60.39.170 with HTTP; Tue, 28 Jan 2014 06:52:30 -0800 (PST) In-Reply-To: <87bnyw41hf.fsf@kepler.schwinge.homeip.net> References: <20131206075033.GE892@tucnak.redhat.com> <20131206082507.GF892@tucnak.redhat.com> <20131206095337.GH892@tucnak.redhat.com> <20131210113834.GQ892@tucnak.redhat.com> <87bnyw41hf.fsf@kepler.schwinge.homeip.net> Date: Tue, 28 Jan 2014 14:52:00 -0000 Message-ID: Subject: Re: -Og bug? (was: [PATCH] libsanitizer demangling using cp-demangle.c) From: Ian Lance Taylor To: Thomas Schwinge Cc: gcc-patches , Dmitry Vyukov , Alexey Samsonov , Konstantin Serebryany , Jakub Jelinek Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2014-01/txt/msg01790.txt.bz2 On Tue, Jan 28, 2014 at 6:36 AM, Thomas Schwinge wrote: > Avoid "'dc' may be uninitialized" warning. > > libiberty/ > * cp-demangle.c (d_demangle_callback): Put __builtin_unreachable > in place, to help the compiler. > > --- libiberty/cp-demangle.c > +++ libiberty/cp-demangle.c > @@ -5824,6 +5824,8 @@ d_demangle_callback (const char *mangled, int options, > NULL); > d_advance (&di, strlen (d_str (&di))); > break; > + default: > + __builtin_unreachable (); You can't call __builtin_unreachable in this code, because libiberty in stage 1 will be compiled by the host compiler and __builtin_unreachable is specific to GCC. This patch is OK if you call abort instead of __builtin_unreachable. Thanks. Ian