From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30873 invoked by alias); 22 Nov 2009 02:15:36 -0000 Received: (qmail 30865 invoked by uid 22791); 22 Nov 2009 02:15:36 -0000 X-SWARE-Spam-Status: No, hits=-2.6 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.33.17) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 22 Nov 2009 02:14:32 +0000 Received: from wpaz29.hot.corp.google.com (wpaz29.hot.corp.google.com [172.24.198.93]) by smtp-out.google.com with ESMTP id nAM2EShE010943 for ; Sun, 22 Nov 2009 02:14:29 GMT Received: from ywh15 (ywh15.prod.google.com [10.192.8.15]) by wpaz29.hot.corp.google.com with ESMTP id nAM2EQgp032529 for ; Sat, 21 Nov 2009 18:14:26 -0800 Received: by ywh15 with SMTP id 15so4352158ywh.5 for ; Sat, 21 Nov 2009 18:14:26 -0800 (PST) Received: by 10.90.217.3 with SMTP id p3mr4807843agg.22.1258856066313; Sat, 21 Nov 2009 18:14:26 -0800 (PST) Received: from coign.google.com (adsl-71-133-8-30.dsl.pltn13.pacbell.net [71.133.8.30]) by mx.google.com with ESMTPS id 22sm1348690yxe.39.2009.11.21.18.14.24 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sat, 21 Nov 2009 18:14:25 -0800 (PST) To: Andrew Hutchinson Cc: GCC Development Subject: Re: How does builtin_sqrt get used - or not References: <4B085C05.4030308@cox.net> From: Ian Lance Taylor Date: Sun, 22 Nov 2009 02:15:00 -0000 In-Reply-To: <4B085C05.4030308@cox.net> (Andrew Hutchinson's message of "Sat\, 21 Nov 2009 16\:30\:45 -0500") Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-System-Of-Record: true X-IsSubscribed: yes Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-11/txt/msg00601.txt.bz2 Andrew Hutchinson writes: > I am tracking test failure with avr target where function sqrtf is > undefined reference at link time. > > Here is command line: > > /media/verbatim/gcchead/obj-dir/gcc/xgcc > -B/media/verbatim/gcchead/obj-dir/gcc/ > /media/verbatim/gcchead/trunk/gcc/testsuite/gcc.dg/pr41963.c -O2 > -ffast-math -DSTACK_SIZE=2048 -DNO_TRAMPOLINES -DSIGNAL_SUPPRESS > -mmcu=atmega128 /home/andy/winavrfiles/avrtest/dejagnuboards/exit.c > -Wl,-u,vfprintf -lprintf_flt > -Wl,-Tbss=0x802000,--defsym=__heap_end=0x80ffff -lm -o pr41963.exe > > I am lead to believe that gcc might use builtin_sqrtf rather than > sqrtf(). I am successfully using fabsf() - with no link errors. > > Is their any target configuration needed for builtin_sqrtf that I > should know about ? If your target does not define a sqrtsf2 insn, then using builtin_sqrtf won't make any difference; gcc will still call the libc's sqrtf function. Ian