From patchwork Thu Oct 3 11:29:27 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Georg-Johann Lay X-Patchwork-Id: 1992310 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gjlay.de header.i=@gjlay.de header.a=rsa-sha256 header.s=strato-dkim-0002 header.b=PuOdPg6V; dkim=pass header.d=gjlay.de header.i=@gjlay.de header.a=ed25519-sha256 header.s=strato-dkim-0003 header.b=OIDCnTne; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4XK8bp1vlcz1xt1 for ; Thu, 3 Oct 2024 21:29:58 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id E0AD1384DD3E for ; Thu, 3 Oct 2024 11:29:55 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mo4-p00-ob.smtp.rzone.de (mo4-p00-ob.smtp.rzone.de [85.215.255.20]) by sourceware.org (Postfix) with ESMTPS id 99FAA3858CDB for ; Thu, 3 Oct 2024 11:29:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 99FAA3858CDB Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=gjlay.de Authentication-Results: sourceware.org; spf=none smtp.mailfrom=gjlay.de ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 99FAA3858CDB Authentication-Results: server2.sourceware.org; arc=pass smtp.remote-ip=85.215.255.20 ARC-Seal: i=2; a=rsa-sha256; d=sourceware.org; s=key; t=1727954976; cv=pass; b=bCUN904vN0a7/mfyGAGbZxl8bFj7lw8yd9VocJNkqBE06pwIYDmG24pUPfbpAJ3hRE/x9tNdyjt+kMbef7LHBi6J6dBMIMSf/aPdka532CNTEJx02sRbY+L7o7UwjduH7BblsoTT8PPrtEXqFx/0PSzuCh8orpO574zEeznxT78= ARC-Message-Signature: i=2; a=rsa-sha256; d=sourceware.org; s=key; t=1727954976; c=relaxed/simple; bh=FqQbUIpsipbaTlxzx1WHuz/kLVRmW6FJCoCZFnKxEuI=; h=DKIM-Signature:DKIM-Signature:Message-ID:Date:MIME-Version:From: To:Subject; b=oGFk899IDLXttL032d+D4WgRF8R1/rVprM49LNPmUYC7cD9ZyUrO/dcLClw1kzDiQ5ktpmdimg9L1kJTRC0o/UggGYzeo5e1kOaCE+uT0XxboopvRX13L3DISNyxcw1p+SFC4JVShUdbVQhgjNKx7giKKN9/GRNkbNn9CvmDvik= ARC-Authentication-Results: i=2; server2.sourceware.org ARC-Seal: i=1; a=rsa-sha256; t=1727954969; cv=none; d=strato.com; s=strato-dkim-0002; b=BqlyxAg7mDoRdzWTakRffqt4wELVt7po9tyPYnk2dqCCTxV8G8q18Lm+Rowu739fm3 DiTNenGqhW2Jf3Hwe+cz3iqBIFIHhnfLDqT/C1alTq71bM5gmOOTnWUws+kww4IU/3ok 7vVZL3BoX0WY3mQVM4EC64iU3ve1Sytq07Uh8hjeXOCKz4VK1iFMCcxDrvK+CxI4BLyg orLb6eNb7WWy5r5ihbc5tLIc+rB1vApXn+3jdkSmPNRRuGCqW5g+B/u3tNQJ7nZuVxgb 4/+YKSJyI13FfBjudi0rvms4SUE5uVxqlkewJQV6zSAh3QmuNaEIlqrK7g5axgJaS4dA iFEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; t=1727954969; s=strato-dkim-0002; d=strato.com; h=Subject:To:From:Date:Message-ID:Cc:Date:From:Subject:Sender; bh=k52vGZ7d6FUEPWt/wsNUUlmTw9QK3D7DMbUeBSNPvH8=; b=eGXN8F/B5PI+I1LS3I8icrtDxKhxwMZD9BhVCqXnPTc1Zr8sgpf0QOG6Gra681fPMv ZX5LVHwb2cxMc/dXcbdHNTQ0wUYvAw6+EzKL7Q0AOkHp7kzGa3V/8fAlT3hqbeSuH5yL h+4lhz1MqRe0Qmyj+8XbQbkVZilcwMrmdMV1thxT3JbKRQ0ClF3+TIze5/qh/sBl0dz1 9azJ09gzxAigOZ+PFOAIMxhBUrCbG68V+Dm6PdbwN18vlcEsC99XjHeA/Ac5piMQ4Rvj FOHF3qSftmfUFy0XpSNVpKtF84+fwY5zMViUZlAWis4z7ZfRJj7Lx+n3XT1U6cfn5r+Z WUVQ== ARC-Authentication-Results: i=1; strato.com; arc=none; dkim=none X-RZG-CLASS-ID: mo00 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1727954969; s=strato-dkim-0002; d=gjlay.de; h=Subject:To:From:Date:Message-ID:Cc:Date:From:Subject:Sender; bh=k52vGZ7d6FUEPWt/wsNUUlmTw9QK3D7DMbUeBSNPvH8=; b=PuOdPg6V8IRT9RaSY2D9hqNSY6/h/Vut+jSeQM6pBKSEpLZQ7S4ihaRC9Z2KtQgeWQ m8RHd5vMNb5n5rvrTZ6d9+44fRd4IkTHQ35OJl6O5mP7VF77k1xFfIvJ4Ssffdn0kmS7 S3Tfupra4B9zYHNYn6rHLzM21+KRyzBF54r/4XIPTl4j6rcVFfkITduXPgpi5aBbsOdz wcACotHfFm4GfjmHx5gNKNLdCXL5tNvpnjIshKCUjsMJaR59/qtLlOyJWwOGza7BLaoB lVqeztZRk17c3RA//PsyTZWofQvopUydcPMTyisv+C8btLMjEoB2EFfdr8Qx5gTXpB9y tFdw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; t=1727954969; s=strato-dkim-0003; d=gjlay.de; h=Subject:To:From:Date:Message-ID:Cc:Date:From:Subject:Sender; bh=k52vGZ7d6FUEPWt/wsNUUlmTw9QK3D7DMbUeBSNPvH8=; b=OIDCnTneAkeJA92loHgA73y/6ctFEPzfstSUqZCfRBnXabRCkA9bURgFxU21EVy1vv ElVH2Rzkb7pXmkSDGdAQ== X-RZG-AUTH: ":LXoWVUeid/7A29J/hMvvT3koxZnKXKoq0dKoR0vVqyQb0R7G22gRW+Qr5Q==" Received: from [192.168.2.102] by smtp.strato.de (RZmta 51.2.8 AUTH) with ESMTPSA id x2e25d093BTSyff (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Thu, 3 Oct 2024 13:29:28 +0200 (CEST) Message-ID: <05e075ad-f6ff-4760-887c-a50abd557608@gjlay.de> Date: Thu, 3 Oct 2024 13:29:27 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Georg-Johann Lay Content-Language: en-US To: "gcc-patches@gcc.gnu.org" , Mike Stump Subject: [patch,testsuite] Fix gcc.c-torture/execute/ieee/pr108540-1.c X-Spam-Status: No, score=-11.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_PASS, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org gcc.c-torture/execute/ieee/pr108540-1.c obviously requires that double is a 64-bit type, hence add pr108540-1.x as an according filter. Ok for trunk? And is there a reason for why we are still putting test cases in these old parts of the testsuite that don't support dg-magic-comments like /* { dg-require-effective-target double64 } */ ? Johann --- testsuite - Fix gcc.c-torture/execute/ieee/pr108540-1.c PR testsuite/108540 gcc/testsuite/ * gcc.c-torture/execute/ieee/pr108540-1.c: Un-preprocess __SIZE_TYPE__ and __INT64_TYPE__. * gcc.c-torture/execute/ieee/pr108540-1.x: New file, requires double64. testsuite - Fix gcc.c-torture/execute/ieee/pr108540-1.c PR testsuite/108540 gcc/testsuite/ * gcc.c-torture/execute/ieee/pr108540-1.c: Un-preprocess __SIZE_TYPE__ and __INT64_TYPE__. * gcc.c-torture/execute/ieee/pr108540-1.x: New file, requires double64. diff --git a/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.c b/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.c index ebd4c502ee5..db094418a79 100644 --- a/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.c +++ b/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.c @@ -1,7 +1,7 @@ /* PR tree-optimization/108540 */ __attribute__((noipa)) void -bar (const char *cp, unsigned long size, char sign, int dsgn) +bar (const char *cp, __SIZE_TYPE__ size, char sign, int dsgn) { if (__builtin_strcmp (cp, "ZERO") != 0 || size != 4 || sign != '-' || dsgn != 1) __builtin_abort (); @@ -11,7 +11,7 @@ __attribute__((noipa)) void foo (int x, int ch, double d) { const char *cp = ""; - unsigned long size = 0; + __SIZE_TYPE__ size = 0; char sign = '\0'; switch (x) { @@ -41,7 +41,7 @@ foo (int x, int ch, double d) sign = '\0'; if (ch == 'a' || ch == 'A') { - union U { long long l; double d; } u; + union U { __INT64_TYPE__ l; double d; } u; int dsgn; u.d = d; if (u.l < 0) diff --git a/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.x b/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.x new file mode 100644 index 00000000000..06d93efeb99 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/execute/ieee/pr108540-1.x @@ -0,0 +1,7 @@ +load_lib target-supports.exp + +if { ! [check_effective_target_double64] } { + return 1 +} + +return 0