From patchwork Tue Oct 22 13:09:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jakub Jelinek X-Patchwork-Id: 2000478 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=SsjfJeg3; 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 4XXswR5jCzz1xtp for ; Wed, 23 Oct 2024 00:09:59 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 417273858C5F for ; Tue, 22 Oct 2024 13:09:57 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id F41413858D20 for ; Tue, 22 Oct 2024 13:09:26 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org F41413858D20 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org F41413858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1729602577; cv=none; b=eKvx9ZwSu1Snu8YdfjLCwr4C95TI6Wui/qDrSaDHJqSpxxE6FQYe9GmnIYoSWzg5dI2m+4WWpDMG/gdixFbZNi3vj6mnSpTOVdheAze+fG4CKiF+xBDqM2AS2/Q25QD/VTzAVLsHF3SBLy/0ll454bLzh+jUpcQNo3RmeyWVJUw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1729602577; c=relaxed/simple; bh=Tgjm7ahCTFt5lhnMiDxLqsTqhHm619zrgE1jPrlJVh8=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:MIME-Version; b=B6+z6a2w4DTKck32iibwIwjkIz+tLggIMBlefE0JeqtJaGKduLT+gqWYDh12h0Fc30Sp2oiZ2jIa8+4BYOa7DyrJtzG1Y2yEbmgg0M1SJldfge6BhQ/Ajgy3btAq7S4sX1BpbpK0V69MyH0unT5yRcZCqtslP69r9Av95bddN8s= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1729602566; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references; bh=G84AfFTBMUIE+BqwyHbVYEiDz+/9H3O8LB2NnAhZRss=; b=SsjfJeg3REgd1MnD11/tKIIyYNPexvXj1RTG8wGeJbEd7GNcZHrofnL8OA4IwuVMWkixSi pDnE0spJiKqqFhhxM3Oq/G+0yeL1MtEefFXCv5q/AD7+Mo4qU3pv9dKyPOHJhnLaaC8RtT 5XPif5LWu/MjNoCARHneljKoFHf+Spw= Received: from mx-prod-mc-04.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-160-InvLhsm7OnqI_8xGAPlZ9Q-1; Tue, 22 Oct 2024 09:09:24 -0400 X-MC-Unique: InvLhsm7OnqI_8xGAPlZ9Q-1 Received: from mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.15]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-04.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 72B6319560B7; Tue, 22 Oct 2024 13:09:23 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.45.224.16]) by mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id C7A2D1956088; Tue, 22 Oct 2024 13:09:21 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.17.1/8.17.1) with ESMTPS id 49MD9I9X613266 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Tue, 22 Oct 2024 15:09:18 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 49MD9Iw2613265; Tue, 22 Oct 2024 15:09:18 +0200 Date: Tue, 22 Oct 2024 15:09:18 +0200 From: Jakub Jelinek To: Jeff Law Cc: "gcc-patches@gcc.gnu.org" Subject: testsuite: Fix up pr116488.c and pr117226.c tests [PR116488] Message-ID: References: <134e1b99-f186-442b-aade-8aa1aa6599e2@gmail.com> MIME-Version: 1.0 In-Reply-To: <134e1b99-f186-442b-aade-8aa1aa6599e2@gmail.com> X-Scanned-By: MIMEDefang 3.0 on 10.30.177.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline X-Spam-Status: No, score=-3.8 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, 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: , Reply-To: Jakub Jelinek Errors-To: gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org Hi! On Mon, Oct 21, 2024 at 01:39:52PM -0600, Jeff Law wrote: > * gcc.dg/torture/pr116488.c: New test. > * gcc.dg/torture/pr117226.c: New test. These two tests FAIL on powerpc64le-linux (and I assume on all other -funsigned-char defaulting targets). The following patch fixes that, tested on powerpc64le-linux and x86_64-linux (-m32/-m64); on x86_64 also tested before/after with -funsigned-char. Ok for trunk? 2024-10-22 Jakub Jelinek PR rtl-optimization/116488 PR rtl-optimization/117226 * gcc.dg/torture/pr116488.c (c, e): Change type from char to signed char. * gcc.dg/torture/pr117226.c (main): Change f type from char to signed char. Jakub --- gcc/testsuite/gcc.dg/torture/pr116488.c.jj 2024-10-22 09:21:05.503216018 +0000 +++ gcc/testsuite/gcc.dg/torture/pr116488.c 2024-10-22 12:57:45.030936225 +0000 @@ -1,7 +1,7 @@ /* { dg-do run } */ /* { dg-additional-options "-fno-forward-propagate" } */ int a, b; -char c, e; +signed char c, e; unsigned char d; __attribute__ ((noinline,noclone,noipa)) void f(int g, short h) { --- gcc/testsuite/gcc.dg/torture/pr117226.c.jj 2024-10-22 09:21:05.683220698 +0000 +++ gcc/testsuite/gcc.dg/torture/pr117226.c 2024-10-22 12:58:08.071530058 +0000 @@ -5,7 +5,7 @@ int a = 128, b, d; long e = -2, c; int main() { - char f = a; + signed char f = a; int g = f; c = (g < 0) - e; unsigned char h = g;