From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19635 invoked by alias); 6 Nov 2012 22:15:02 -0000 Received: (qmail 19593 invoked by uid 22791); 6 Nov 2012 22:15:00 -0000 X-SWARE-Spam-Status: No, hits=-2.9 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from ainaz.pair.com (HELO ainaz.pair.com) (209.68.2.66) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 06 Nov 2012 22:14:57 +0000 Received: from [149.44.171.145] (nat.nue.novell.com [195.135.221.2]) by ainaz.pair.com (Postfix) with ESMTPSA id 6374B3F412; Tue, 6 Nov 2012 17:14:55 -0500 (EST) Date: Tue, 06 Nov 2012 22:15:00 -0000 From: Gerald Pfeifer To: Sriraman Tallam cc: Jason Merrill , David Li , "H.J. Lu" , gcc-patches List , Jan Hubicka , Diego Novillo Subject: Re: User directed Function Multiversioning via Function Overloading (issue5752064) In-Reply-To: Message-ID: References: <5008708E.1030109@redhat.com> <506F27AF.3070805@redhat.com> <50816D63.3020908@google.com> <20121026155447.GA4348@atrey.karlin.mff.cuni.cz> <50902624.3020705@redhat.com> <50912F66.3030707@redhat.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-IsSubscribed: yes 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 X-SW-Source: 2012-11/txt/msg00582.txt.bz2 On Mon, 5 Nov 2012, Sriraman Tallam wrote: > I have now committed the attached patch. ...and broke bootstrap on *-unknown-freebsd* and other targets that way: /scratch2/tmp/gerald/gcc-HEAD/gcc/config/i386/i386.c:28820:1: error: 'tree_node* make_dispatcher_decl(tree)' defined but not used [-Werror=unused-function] make_dispatcher_decl (const tree decl) ^ cc1plus: all warnings being treated as errors To restore bootstrap, I applied the patch below after testing on i386-unknown-freebsd10.0. Gerald 2012-11-06 Gerald Pfeifer * config/i386/i386.c (make_dispatcher_decl): Guard with ASM_OUTPUT_TYPE_DIRECTIVE and HAVE_GNU_INDIRECT_FUNCTION. Index: config/i386/i386.c =================================================================== --- config/i386/i386.c (revision 193259) +++ config/i386/i386.c (working copy) @@ -28813,6 +28813,8 @@ return global_var_name; } +#if defined (ASM_OUTPUT_TYPE_DIRECTIVE) && HAVE_GNU_INDIRECT_FUNCTION + /* Make a dispatcher declaration for the multi-versioned function DECL. Calls to DECL function will be replaced with calls to the dispatcher by the front-end. Return the decl created. */ @@ -28850,6 +28852,8 @@ return func_decl; } +#endif + /* Returns true if decl is multi-versioned and DECL is the default function, that is it is not tagged with target specific optimization. */