From patchwork Wed Feb 5 17:02:03 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeff Law X-Patchwork-Id: 1234326 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-519039-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.a=rsa-sha1 header.s=default header.b=S/Ds+DQ2; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=IzTtEKDD; 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 48Cz9Y1sbBz9sRX for ; Fri, 7 Feb 2020 00:02:25 +1100 (AEDT) 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:subject:from:reply-to:to:mime-version:date :content-type; q=dns; s=default; b=eqHKfF9S8gH2zfVyOs3+nOcj3wpWe d9RlIRxOIcbZXMoPwC/2LaYKGLNvMQ0E7EDNMpQrWfJQLw/JY51iDmchHmPmfw8u WCGjG7ZoM/urZq/c4xQkNz/Gar40yfuN5PIgY015WjruBThqS7dlrcLro93mWI0g CSPGeMGX63oGKk= 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:subject:from:reply-to:to:mime-version:date :content-type; s=default; bh=2aSzyPaN+oNEWes/HBPw/sYwl4c=; b=S/D s+DQ2Jhby3uVRPZvJpHM5ftHLoCvyZhjYR3KrxwRGs502Fpe69mxHpXYGXqTDSAb yR/gUaPrcmiJjTmswk1E1yI4NDiw2WEeDmJHaVJma0beVtHF5PAbR/rvgs6mNd9g hg97V2omgk7TU55Ejq2ogPXW0BsS0o/OMuWkf2Ew= Received: (qmail 113700 invoked by alias); 6 Feb 2020 13:01:26 -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 113297 invoked by uid 89); 6 Feb 2020 13:01:03 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-14.1 required=5.0 tests=AWL, BAYES_00, DATE_IN_PAST_12_24, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=strategies X-HELO: us-smtp-1.mimecast.com Received: from us-smtp-1.mimecast.com (HELO us-smtp-1.mimecast.com) (207.211.31.81) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 06 Feb 2020 13:01:02 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1580994060; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type; bh=eSXuzEdaoEN7xVvbK5hSzRdWEF+UF6g0F7nal6XnS+c=; b=IzTtEKDD4VoTtHiqPHzGT67B5jOqWXEZyjqDSf6O8wumkBv4MVfM7IOHxcFlKb37FoFgnj MEYQ2iiHQmA2OBV0rp4zhY05h7CBDaY2lAtuLsya0r7ZOqfgJPeJTK7bBdHmeOB38hj9tr Kj9D5izExOde5IGjW/WmcOXbm3NmZgg= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-7-z2TRb3mFOGGuRK9A_TnjUA-1; Thu, 06 Feb 2020 08:00:58 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 766367A184 for ; Thu, 6 Feb 2020 13:00:57 +0000 (UTC) Received: from ovpn-116-216.phx2.redhat.com (ovpn-116-216.phx2.redhat.com [10.3.116.216]) by smtp.corp.redhat.com (Postfix) with ESMTP id 388055DA83 for ; Thu, 6 Feb 2020 13:00:57 +0000 (UTC) Message-ID: Subject: [committed] Fix minor hppa testsuite failure due to recent IRA changes From: Jeff Law Reply-To: law@redhat.com To: gcc-patches List MIME-Version: 1.0 Date: Wed, 05 Feb 2020 10:02:03 -0700 User-Agent: Evolution 3.34.3 (3.34.3-1.fc31) X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-IsSubscribed: yes The recent IRA changes twiddled register allocation. Not surprisingly there's a bit of fallout. On the PA we've started failing one of the shadd tests which was triggered by the IRA changes. In simplest terms the register allocations changed, which obviously changes the hard registers live at any given point. That in turn changes some of the decisions in the delay slot filling code. One of the delay slot filling strategies is to try to fill the delay slot of a branch with the insn at the target of the branch. If the target of the branch is reached from multiple points, then we actually make a copy of that candidate insn (for the delay slot) and change the branch to target the next insn. ie [ ... ] L: candidate_insn [ ... ] b L delay slot L can be reached either via the fallthru path or via the branch (and possibly other branches). To fill the slot we transform that into: [ ... ] L: candidate_insn L: [ ... ] b L copy of candidate_insn The test in question counts the number of shadd insns as a proxy for other behavior prior to delay slot filling. Obviously this kind of slot filling can change the number of shadd insns in the resulting assembly code which brings a undesirable degree of instability to the test. This change does two things. First, it disables delay slot filling for the test so improve the test's stability. Second, it adjusts the expected count of shadd insns. Committed to the trunk. Jeff commit f976fe0937c2b46880628c2e2749ca3a788c5db0 Author: Jeff Law Date: Wed Feb 5 10:00:48 2020 -0700 Fix testsuite "regression" on hppa after recent IRA changes. * gcc.target/hppa/shadd-3.c: Disable delay slot filling and adjust expected shadd insn count appropriately. diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index f6291df9795..0a6513e666b 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2020-02-05 Jeff Law + + * gcc.target/hppa/shadd-3.c: Disable delay slot filling and + adjust expected shadd insn count appropriately. + 2020-02-05 David Malcolm * gcc.dg/analyzer/data-model-1.c: Update for changed output to diff --git a/gcc/testsuite/gcc.target/hppa/shadd-3.c b/gcc/testsuite/gcc.target/hppa/shadd-3.c index f0443ea9977..2d0b648f384 100644 --- a/gcc/testsuite/gcc.target/hppa/shadd-3.c +++ b/gcc/testsuite/gcc.target/hppa/shadd-3.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-O2" } */ +/* { dg-options "-O2 -fno-delayed-branch" } */ /* In this test we want to verify that combine canonicalizes the MULT into an ASHIFT which in turn allows postreload-gcse to find the common subexpression. @@ -8,8 +8,9 @@ for parsing here, so we count the shadd insns. More is not necessarily better in this test. If this test is too fragile over time we'll have to revisit the combine and/or postreload - dumps. */ -/* { dg-final { scan-assembler-times "sh.add" 5 } } */ + dumps. Note we have disabled delay slot filling to improve + test stability. */ +/* { dg-final { scan-assembler-times "sh.add" 4 } } */ extern void oof (void); typedef struct simple_bitmap_def *sbitmap;