From patchwork Tue Dec 17 13:12:23 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Stubbs X-Patchwork-Id: 1211399 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-516113-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="YbXOFAzn"; 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 47cdqD3m4Pz9sSp for ; Wed, 18 Dec 2019 00:12:56 +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:to :from:subject:message-id:date:mime-version:content-type; q=dns; s=default; b=tQfcApOL2cYtTMeyWjpWw6mmlOY+v7ARyVrEC1ficUswxy00v8 PyFTtqU+8bRdEUX7lczjTDUOp4L635uK4JGnVhYlG24CD/U19UwDwtiWtKy3+gjX mYEeLOh0PmlenQQlwNKkpuYbv70VB4G89WOLE4Q2Jvs3jx4Sqtzsq4lKo= 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:to :from:subject:message-id:date:mime-version:content-type; s= default; bh=F7a9aZtM5NrE7aq8vunSefNWi10=; b=YbXOFAzng5CACzx3PLC9 mnPOQQx7s621R6p4oxhoZiHGOFwxX+9oImx6bk/dht6H/peuBFtEN6qASI50Qk+X dSzVslaad7YlOi+aH9Q2xHWKuaj9Fc6zr3BN6Vkyf5Zre5EDxbS7ztkGMPF+Cri9 G3fGKvR7Hh9upZixtaBiyq4= Received: (qmail 46364 invoked by alias); 17 Dec 2019 13:12:46 -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 46249 invoked by uid 89); 17 Dec 2019 13:12:45 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.7 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3 autolearn=ham version=3.3.1 spammy=Mention X-HELO: esa4.mentor.iphmx.com Received: from esa4.mentor.iphmx.com (HELO esa4.mentor.iphmx.com) (68.232.137.252) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 17 Dec 2019 13:12:43 +0000 IronPort-SDR: dY88QrTkKFkeBiy7B8GS9tCSK65qhiBTVVf3jYDpzv1uT0fCClGL90Deq4TDyMyMYuXKNdS5Ig 6jHs2Oxxz8m0Ziia0X68b2futFCE6RXtjQTwJJ18Ofy7D/SZ7igfdtGO2+Dh/Avt+ssgPZ0Iay 7Ptuc9SMtbZXc3fsEgxwUys2DkoA3Nf+IOAoSl3v7nnoo74t/6ovOHjv7ZdMafvqCDqMNAFlzs m0R8FI4w3i5qV07VpLpZK1/EJzqIFLNlIl29FhSgsCDwkolZhOu6LJZE4j+33cxnSQFuCNt4ej NTI= Received: from orw-gwy-02-in.mentorg.com ([192.94.38.167]) by esa4.mentor.iphmx.com with ESMTP; 17 Dec 2019 05:12:30 -0800 IronPort-SDR: D5oeqN28pLi5woXfpW1yUj5lqSdQM+q6crV1mhli0AkY+mGGdy3Ejx7nr/npFCSgx0XFqzoBYl 50IbZXhcP6vcBOdBNNngOn66JvEgRgDcGIRbRC0gy51fpRqfNCO3gvpEDmDPcog+oZBh1Cx2zw kS6j6umusca5phZQmDM8uMv8gAX1fKO1zeaXxFibsLbUeb0apBAhP6YXbQ9kXhuY9ZHjGyxzmi xVggGLZMtmyEhLnmT6xjtMzjB0qMfOrr6d11p+KMCPX+pd3lR81nH4/G/Hp1KVI/oV0OetYsWE 2Cw= To: "gcc-patches@gcc.gnu.org" From: Andrew Stubbs Subject: [committed, pr92772] Mention bug in comment Message-ID: <4109c0a5-6f5f-9fbe-e31d-acf24515b13e@codesourcery.com> Date: Tue, 17 Dec 2019 13:12:23 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.2.2 MIME-Version: 1.0 This patch only changes a comment, so I'm committing it as "obvious". The point is that I don't intend to spend the time to fix the bug because implementing the fold_extract_last is both a work around and an optimization, but future ports might encounter the same problem and hopefully the pointer will save future readers some confusion. Andrew Add pointer to PR92772 2019-12-17 Andrew Stubbs * tree-vect-loop.c (vect_create_epilog_for_reduction): Mention pr92772 in the comments. diff --git a/gcc/tree-vect-loop.c b/gcc/tree-vect-loop.c index 353a5ff06e1..68699f2d814 100644 --- a/gcc/tree-vect-loop.c +++ b/gcc/tree-vect-loop.c @@ -4534,7 +4534,10 @@ vect_create_epilog_for_reduction (stmt_vec_info stmt_info, containing the last time the condition passed for that vector lane. The first match will be a 1 to allow 0 to be used for non-matching indexes. If there are no matches at all then the vector will be all - zeroes. */ + zeroes. + + PR92772: This algorithm is broken for architectures that support + masked vectors, but do not provide fold_extract_last. */ if (STMT_VINFO_REDUC_TYPE (reduc_info) == COND_REDUCTION) { auto_vec, 2> ccompares;