From patchwork Thu Oct 3 13:31:07 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rainer Orth X-Patchwork-Id: 1171211 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-510138-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=CeBiTec.Uni-Bielefeld.DE Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="L5oOIpbW"; dkim-atps=neutral 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 46kYn74YFjz9sN1 for ; Thu, 3 Oct 2019 23:31:23 +1000 (AEST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:mime-version:content-type; q=dns; s= default; b=Rfp+oZ6qm1nzsx4LIBLC2VS6uUQJ5qe8DBQpoJmVpTGHDgadEp9P0 faL3KvHmJ0JZhMiHhiT2UCk1I9HaC0c2xp8Si3eNWonqzGvj60gEt0i6DkSKKRsV cQZKvwJDS0N4EZlmxRRFebRxhhh5/7g1nAE7Mhon4fhWfWtQ1zhZGk= 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:from :to:subject:date:message-id:mime-version:content-type; s= default; bh=5+eW9Seevf82hLtJTao/Ihdy9PM=; b=L5oOIpbWdC3Fmm2ph/wx fdRuzYVNm/TgPDbImhjuasq/5HiA3u1KvroLFh3VMCqUaPJk8TBetDvZAx1L3PMX G1As8Hw+95Sx3hLvmcLAOJm0UZbUdQGijFgJDMfPN+ZDq5uPtJZIo9fx5mHZjz3K +MuGEIFIFfQAps7rvJo1kuY= Received: (qmail 117741 invoked by alias); 3 Oct 2019 13:31:16 -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 117733 invoked by uid 89); 3 Oct 2019 13:31:16 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.2 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_2, GIT_PATCH_3 autolearn=ham version=3.3.1 spammy=gcc-testresults, gcctestresults, cpp0x, Rainer X-HELO: smtp.CeBiTec.Uni-Bielefeld.DE Received: from smtp.CeBiTec.Uni-Bielefeld.DE (HELO smtp.CeBiTec.Uni-Bielefeld.DE) (129.70.160.84) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 03 Oct 2019 13:31:14 +0000 Received: from localhost (localhost.CeBiTec.Uni-Bielefeld.DE [127.0.0.1]) by smtp.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTP id 6BB311CC8 for ; Thu, 3 Oct 2019 15:31:10 +0200 (CEST) Received: from smtp.CeBiTec.Uni-Bielefeld.DE ([127.0.0.1]) by localhost (malfoy.CeBiTec.Uni-Bielefeld.DE [127.0.0.1]) (amavisd-new, port 10024) with LMTP id vWIgcYc6K2-a for ; Thu, 3 Oct 2019 15:31:08 +0200 (CEST) Received: from manam.CeBiTec.Uni-Bielefeld.DE (p5085478D.dip0.t-ipconnect.de [80.133.71.141]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.CeBiTec.Uni-Bielefeld.DE (Postfix) with ESMTPSA id 1F60D1CC7 for ; Thu, 3 Oct 2019 15:31:08 +0200 (CEST) From: Rainer Orth To: gcc-patches@gcc.gnu.org Subject: [testsuite] Check init_priority in g++.dg/cpp0x/gen-attrs-67.C Date: Thu, 03 Oct 2019 15:31:07 +0200 Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (usg-unix-v) MIME-Version: 1.0 X-IsSubscribed: yes I found g++.dg/cpp0x/gen-attrs-67.C to FAIL on Solaris 11 when configuring with --disable-initfini-array: +FAIL: g++.dg/cpp0x/gen-attrs-67.C -std=c++14 (test for excess errors) +FAIL: g++.dg/cpp0x/gen-attrs-67.C -std=c++17 (test for excess errors) Excess errors: /vol/gcc/src/hg/trunk/local/gcc/testsuite/g++.dg/cpp0x/gen-attrs-67.C:11:34: error: constructor priorities are not supported There's already been a patch to expect this error on Darwin, but it's bogus to do this based on target triplet. E.g. on Solaris 11.3 (*-*-solaris2.11) with the vendor ld, there's no support while with gld there is. On Solaris 11.4 OTOH (same triplet), there's always support. We already have an effective-target keyword to capture this support, which this patch now uses. This will also fix the failure seen on hppa2.0w-hp-hpux11.11 reported to gcc-testresults. Tested on i386-pc-solaris2.11 (Solaris 11.4 with support and 11.3 without) as well as x86_64-apple-darwin11.4.2 (the previous special case). Installed on mainline. Rainer # HG changeset patch # Parent 61230f42063e7211dcfba02caefa83bb9adf4d4f Check init_priority in g++.dg/cpp0x/gen-attrs-67.C diff --git a/gcc/testsuite/g++.dg/cpp0x/gen-attrs-67.C b/gcc/testsuite/g++.dg/cpp0x/gen-attrs-67.C --- a/gcc/testsuite/g++.dg/cpp0x/gen-attrs-67.C +++ b/gcc/testsuite/g++.dg/cpp0x/gen-attrs-67.C @@ -8,4 +8,4 @@ [[nodiscard()]] int f4(); // { dg-error ".nodiscard. attribute does not take any arguments" } [[gnu::noinline()]] int f5(); // { dg-error ".noinline. attribute does not take any arguments" } [[gnu::constructor]] int f6(); -[[gnu::constructor(101)]] int f7(); // { dg-error "constructor priorities are not supported" "" { target *-*-darwin* } } +[[gnu::constructor(101)]] int f7(); // { dg-error "constructor priorities are not supported" "" { target { ! init_priority } } }