From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0b-001b2d01.pphosted.com (mx0b-001b2d01.pphosted.com [148.163.158.5]) by sourceware.org (Postfix) with ESMTPS id 974573858D20 for ; Mon, 22 May 2023 05:37:00 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 974573858D20 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=linux.ibm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linux.ibm.com Received: from pps.filterd (m0353722.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 34M4B2wt020529; Mon, 22 May 2023 05:36:57 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=message-id : date : mime-version : subject : to : cc : references : from : in-reply-to : content-type : content-transfer-encoding; s=pp1; bh=4xOjJySW4NF6KFRBeKEaG2LJ5Qw45eV71gP3klE7ZvU=; b=hZedfi0prNQjPuPimn2RR+IihzIlVfO8HKgzl0rU1FemHSWZHFJZmt981J40odaTUtmU 4Y123OP0+v/zNrMVQm1SIxiofDdGtIFoh9bRxQojgP9rPtxBRTYb0c6+dgM5lZVYzPU3 PzJmgt2ESAUJ8FPSED1Y0N/ztLD5Rn0v1cPNwwCXMop4unoNVNmE0LMbGowEsGC+LYGs PDvxy04P2TrLuVviIXVlPoG3egRIHTZVWtK2Eo3KdXMWCUTpndYjbq9c7qovUeV6c+Ue nqRcI7WiQx4z6ZrLHbkgW+T0V640EiN9ffg8ypRcTazyctobltnopnBlid7EaBz4Gzd0 bw== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3qqgbq1a39-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 22 May 2023 05:36:56 +0000 Received: from m0353722.ppops.net (m0353722.ppops.net [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 34M5QLr7018512; Mon, 22 May 2023 05:36:56 GMT Received: from ppma03ams.nl.ibm.com (62.31.33a9.ip4.static.sl-reverse.com [169.51.49.98]) by mx0a-001b2d01.pphosted.com (PPS) with ESMTPS id 3qqgbq1a2n-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 22 May 2023 05:36:56 +0000 Received: from pps.filterd (ppma03ams.nl.ibm.com [127.0.0.1]) by ppma03ams.nl.ibm.com (8.17.1.19/8.17.1.19) with ESMTP id 34M4qkp2021874; Mon, 22 May 2023 05:36:54 GMT Received: from smtprelay04.fra02v.mail.ibm.com ([9.218.2.228]) by ppma03ams.nl.ibm.com (PPS) with ESMTPS id 3qppcu8s75-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 22 May 2023 05:36:54 +0000 Received: from smtpav06.fra02v.mail.ibm.com (smtpav06.fra02v.mail.ibm.com [10.20.54.105]) by smtprelay04.fra02v.mail.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 34M5apTE27656748 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 22 May 2023 05:36:51 GMT Received: from smtpav06.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8DEE520043; Mon, 22 May 2023 05:36:51 +0000 (GMT) Received: from smtpav06.fra02v.mail.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 7C66820040; Mon, 22 May 2023 05:36:49 +0000 (GMT) Received: from [9.177.82.45] (unknown [9.177.82.45]) by smtpav06.fra02v.mail.ibm.com (Postfix) with ESMTP; Mon, 22 May 2023 05:36:49 +0000 (GMT) Message-ID: <70c9a661-d66d-eb90-d936-beba4bc5d579@linux.ibm.com> Date: Mon, 22 May 2023 13:36:47 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.6.1 Subject: Re: [PATCH] vect: Don't retry if the previous analysis fails Content-Language: en-US To: Richard Biener Cc: GCC Patches , Richard Sandiford , Segher Boessenkool , Peter Bergner References: From: "Kewen.Lin" In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 X-Proofpoint-GUID: PV2tU6o3561XImIddVTqZRS1zELVupLL X-Proofpoint-ORIG-GUID: SUuvJju7jk18hjNC7VrN3dWj9M5Ko5fl X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.254,Aquarius:18.0.957,Hydra:6.0.573,FMLib:17.11.170.22 definitions=2023-05-22_02,2023-05-17_02,2023-02-09_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 bulkscore=0 spamscore=0 phishscore=0 clxscore=1015 impostorscore=0 adultscore=0 mlxlogscore=999 lowpriorityscore=0 mlxscore=0 malwarescore=0 suspectscore=0 priorityscore=1501 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2304280000 definitions=main-2305220046 X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: on 2023/5/17 14:32, Richard Biener wrote: > On Wed, May 17, 2023 at 8:06 AM Kewen.Lin wrote: >> >> Hi, >> >> When working on a cost tweaking patch, I found that a newly >> added test case has different dumpings with stage-1 and >> bootstrapped gcc. By looking into it, the apparent reason >> is vect_analyze_loop_2 doesn't get slp_done_for_suggested_uf >> set expectedly, the following retrying will use the garbage >> slp_done_for_suggested_uf instead. In fact, the setting of >> slp_done_for_suggested_uf only happens when the previous >> analysis succeeds, for the mentioned test case, its previous >> analysis does fail, it's unexpected to use the value of >> slp_done_for_suggested_uf any more. >> >> In function vect_analyze_loop_1, we only return success when >> res is true, which is the result of 1st analysis. It means >> we never try to vectorize with unroll_vinfo if the previous >> analysis fails. So this patch shouldn't break anything, and >> just stop some useless analysis early. >> >> Bootstrapped and regtested on x86_64-redhat-linux, >> aarch64-linux-gnu and powerpc64{,le}-linux-gnu. >> >> Is it ok for trunk? > > OK for trunk and affected branches. Pushed as r14-926 and backported in r13-7364 & r12-9633. Thanks! BR, Kewen