From patchwork Thu Aug 7 07:47:08 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tom de Vries X-Patchwork-Id: 377770 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 9691D140092 for ; Thu, 7 Aug 2014 17:48:42 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:references :in-reply-to:content-type; q=dns; s=default; b=m/y56nwPpSRTBeycu QEZbFng0rLwmCRRR4KOXISBkWb0/8Pt6hfGZo03ee1RFLQMqa/BuDd/gnCNsg9fD R4sTBAKHL2xjk9zk133q37f15B4V3OtiaO+Mej+HMmuOlci7ZSrlIcE9Vmt69GEC 6fnpCTZwilqtnRUJwj0wITMn4I= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:references :in-reply-to:content-type; s=default; bh=QYkfusOs7qnJ83pZ1tv3w0I LC9g=; b=E+LuiWgdudp6wE4+gbOn+KNugu8CASwCvw3EFK/7jF0H68pyKyOmEf6 1AYLgf1sIbuiBbsuTfZIA6d3R1Izmy08PLtsUeK4uNUAOjie7oiJ0Wvq69sddBvH Z62N7jOWd377tJg7j7b1Kd+j/z4sFy64daRDBmwPxqWnkMeX5u5s= Received: (qmail 4824 invoked by alias); 7 Aug 2014 07:47:22 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 4754 invoked by uid 89); 7 Aug 2014 07:47:21 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL, BAYES_00 autolearn=ham version=3.3.2 X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 07 Aug 2014 07:47:17 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1XFIPo-0002cj-Sw from Tom_deVries@mentor.com ; Thu, 07 Aug 2014 00:47:12 -0700 Received: from SVR-IES-FEM-02.mgc.mentorg.com ([137.202.0.106]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Thu, 7 Aug 2014 00:47:12 -0700 Received: from [127.0.0.1] (137.202.0.76) by SVR-IES-FEM-02.mgc.mentorg.com (137.202.0.106) with Microsoft SMTP Server id 14.2.247.3; Thu, 7 Aug 2014 08:47:11 +0100 Message-ID: <53E32EFC.2060102@mentor.com> Date: Thu, 7 Aug 2014 09:47:08 +0200 From: Tom de Vries User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Rainer Orth , Mike Stump CC: GCC Patches Subject: Re: [PATCH][testsuite] Don't run cproj-fails-with-broken-glibc.c for broken glibc References: <53DA9714.5070707@mentor.com> <53DD1143.2030001@mentor.com> In-Reply-To: On 05-08-14 13:51, Rainer Orth wrote: > Hi Mike, > >>> Or do we go with the removal suggestion of Mike? >> >> I’ll let others weigh in. I’m fine either way. Original author likely >> prefers the xfail, so I’m fine with the above. > > the test now XPASSes on Solaris, adding testsuite noise in the other > direction on completely innocent systems. FWIW, I would be interested in understanding the details there. > Given that we're not actually > testing gcc behaviour or a workaround for a glibc bug here, but just > alerting users to changed cproj semantics on old and newer glibc systems > > https://gcc.gnu.org/ml/gcc-patches/2010-04/msg01285.html > > I'd strongly suggest just removing the test and the supporting > effective-target keywords. > Done. Committed as attached. Thanks, - Tom 2014-08-07 Tom de Vries * gcc.dg/cproj-fails-with-broken-glibc.c: Remove test. * lib/target-supports.exp (check_effective_target_glibc) (check_effective_target_glibc_2_12_or_later) (check_effective_target_glibc_2_11_or_earlier): Remove proc. * doc/sourcebuild.texi (glibc, glibc_2_12_or_later) (glibc_2_11_or_earlier): Remove effective-target keywords. diff --git a/gcc/doc/sourcebuild.texi b/gcc/doc/sourcebuild.texi index 0793f80..39152df 100644 --- a/gcc/doc/sourcebuild.texi +++ b/gcc/doc/sourcebuild.texi @@ -1804,15 +1804,6 @@ Target is a VxWorks RTP. @item wchar Target supports wide characters. - -@item glibc -Target supports glibc - -@item glibc_2_12_or_later -Target supports glibc 2.12 or later - -@item glibc_2_11_or_earlier -Target supports glibc 2.11 or earlier @end table @subsubsection Other attributes diff --git a/gcc/testsuite/gcc.dg/cproj-fails-with-broken-glibc.c b/gcc/testsuite/gcc.dg/cproj-fails-with-broken-glibc.c deleted file mode 100644 index fc37fac..0000000 --- a/gcc/testsuite/gcc.dg/cproj-fails-with-broken-glibc.c +++ /dev/null @@ -1,25 +0,0 @@ -/* Copyright (C) 2010 Free Software Foundation. - - Check the runtime behavior of the C library's cproj() function and - whether it follows the standard. Versions of GLIBC through 2.11.1 - had an incorrect implementation which will conflict with GCC's - builtin cproj(). GLIBC 2.12+ should be okay. - - Origin: Kaveh R. Ghazi, April 20, 2010. */ - -/* { dg-do run { xfail glibc_2_11_or_earlier } } */ -/* { dg-options "-fno-builtin-cproj" } */ -/* { dg-add-options c99_runtime } */ -/* { dg-require-effective-target c99_runtime } */ - -extern void abort(void); -extern void exit(int); -double _Complex cproj(double _Complex); - -int main (void) -{ - if (cproj (2+3i) != 2+3i) - abort(); - - exit(0); -} diff --git a/gcc/testsuite/lib/target-supports.exp b/gcc/testsuite/lib/target-supports.exp index 7157d2a..fa5137e 100644 --- a/gcc/testsuite/lib/target-supports.exp +++ b/gcc/testsuite/lib/target-supports.exp @@ -5038,44 +5038,6 @@ proc check_effective_target_newlib {} { }] } -# Return true if this is a glibc target. - -proc check_effective_target_glibc {} { - return [check_no_compiler_messages glibc object { - #include - #if !(defined (__GLIBC__) && defined (__GLIBC_MINOR__)) - #error FOO - #endif - }] -} - -# Return true if this is a glibc 2.12 or later target. - -proc check_effective_target_glibc_2_12_or_later {} { - return [check_no_compiler_messages glibc_2_12_or_later object { - #include - #if !(defined (__GLIBC__) && defined (__GLIBC_MINOR__) \ - && __GLIBC_PREREQ(2,12)) - #error FOO - #endif - }] -} - -# Return true if this is a glibc 2.11 or earlier target. - -proc check_effective_target_glibc_2_11_or_earlier {} { - - if { ![check_effective_target_glibc] } { - return 1 - } - - if { [check_effective_target_glibc_2_12_or_later] } { - return 0 - } - - return 1 -} - # Return true if this is NOT a Bionic target. proc check_effective_target_non_bionic {} { -- 1.9.1