From patchwork Fri Apr 26 23:03:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Pinski X-Patchwork-Id: 89068 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 9A324384AB78 for ; Fri, 26 Apr 2024 23:04:49 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by sourceware.org (Postfix) with ESMTPS id 66DCD3858C42 for ; Fri, 26 Apr 2024 23:04:09 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 66DCD3858C42 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=quicinc.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 66DCD3858C42 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=205.220.180.131 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1714172657; cv=none; b=ffJSkzKevLNGsknINWWLJLYs2ZVbk+kFM2LzI/xAb/H4nIiLDsO+uZKLGzi4va6NA57Y4X/++YjW+bbdlRloJgBR5HVHGBSsnfx+/YCvPhoGRL2lFCgd3mIu7swqMQTPijN9VuuzV6b/PzXMhevHb/9jazSTxrUyZF85UL/8JGc= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1714172657; c=relaxed/simple; bh=dZQjA1crgS+z475KwWzzgvbkhMdZu6fer9Ght8hBCIU=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=qQiSgjap22xAwtpIcKBasoCWdhFFlqbDnyG39q14pSNsApAm3e4IhBi10fGQFMn3oBYZ1lKBU6tGHrEcuMqcq+HxvJ9xbUVPQpqNLERGxBQHw3WSoG1wFQ+yVFVc5cq1JKwXY27ibJirncr7xTGEIef5J7dD2Mi/HxTtYEI6gRo= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 43QMG87G020875 for ; Fri, 26 Apr 2024 23:04:09 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s= qcppdkim1; bh=gr3nh5ga55Jy7ZmdVi+8Jbs/XJ7CemOeKUw2JVabpTI=; b=A8 3lT7riBMdVj+HFNvkm5iGiyMF64uLjw05Uczd5gPnYD9cuw5lzA56nsqKCxIIwmb JNHRxNJZ7CRFMnwd01BJc2hjpzEIVOQj4Q39CKCZdOMUJ5UrNRq4RZ/dSny3Hyuj 97pQNO00nEEeJqCk5Stbcd3XY2I3Sx8AvjqRHH4n7eHf/A2jYNbXw1014Ee2mhMy 1gwkDKUAqjabwo+6RxQl0wY+ekqg3c3xPLoIAm5TeESVnc1QmK2iIVs63rjR53pm 245RkEmGQiEqVmNEmb6aqt0HnyTCFjRSBeWHMHmC0qwUDZOGFS+ffBwHfXNNy2oP EwaZ/uW3FWMz0uq9IrYA== Received: from nasanppmta02.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3xr3593204-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 26 Apr 2024 23:04:08 +0000 (GMT) Received: from nasanex01c.na.qualcomm.com (nasanex01c.na.qualcomm.com [10.45.79.139]) by NASANPPMTA02.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 43QN47ks016731 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 26 Apr 2024 23:04:07 GMT Received: from hu-apinski-lv.qualcomm.com (10.49.16.6) by nasanex01c.na.qualcomm.com (10.45.79.139) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Fri, 26 Apr 2024 16:04:07 -0700 From: Andrew Pinski To: CC: Andrew Pinski Subject: [PATCH 2/2] Remove support for nontemporal stores with ssa_names on lhs [PR112976] Date: Fri, 26 Apr 2024 16:03:53 -0700 Message-ID: <20240426230353.3131438-2-quic_apinski@quicinc.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240426230353.3131438-1-quic_apinski@quicinc.com> References: <20240426230353.3131438-1-quic_apinski@quicinc.com> MIME-Version: 1.0 X-Originating-IP: [10.49.16.6] X-ClientProxiedBy: nalasex01a.na.qualcomm.com (10.47.209.196) To nasanex01c.na.qualcomm.com (10.45.79.139) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-GUID: GaGA5rW2MtjEX9268-OVQ_yWYwgj0fsm X-Proofpoint-ORIG-GUID: GaGA5rW2MtjEX9268-OVQ_yWYwgj0fsm X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1011,Hydra:6.0.650,FMLib:17.11.176.26 definitions=2024-04-26_19,2024-04-26_02,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 malwarescore=0 spamscore=0 impostorscore=0 lowpriorityscore=0 priorityscore=1501 adultscore=0 clxscore=1015 mlxscore=0 suspectscore=0 phishscore=0 mlxlogscore=765 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2404010003 definitions=main-2404260161 X-Spam-Status: No, score=-13.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, SPF_HELO_NONE, SPF_PASS, 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+patchwork=sourceware.org@gcc.gnu.org When cfgexpand was changed to support expanding from tuple gimple (r0-95521-g28ed065ef9f345), the code was added to support doing nontemporal stores with LHS of a SSA_NAME but that will never be a nontemporal store. This patch removes that and asserts that expanding with a LHS of a SSA_NAME is not a nontemporal store. Bootstrapped and tested on x86_64-linux-gnu. gcc/ChangeLog: PR middle-end/112976 * cfgexpand.cc (expand_gimple_stmt_1): Remove support for expanding nontemporal "moves" with ssa names on the LHS. Signed-off-by: Andrew Pinski --- gcc/cfgexpand.cc | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/gcc/cfgexpand.cc b/gcc/cfgexpand.cc index eef565eddb5..cfc5291aa0c 100644 --- a/gcc/cfgexpand.cc +++ b/gcc/cfgexpand.cc @@ -4002,17 +4002,16 @@ expand_gimple_stmt_1 (gimple *stmt) else { rtx target, temp; - bool nontemporal = gimple_assign_nontemporal_move_p (assign_stmt); + gcc_assert (!gimple_assign_nontemporal_move_p (assign_stmt)); bool promoted = false; target = expand_expr (lhs, NULL_RTX, VOIDmode, EXPAND_WRITE); if (GET_CODE (target) == SUBREG && SUBREG_PROMOTED_VAR_P (target)) promoted = true; - /* If we want to use a nontemporal store, force the value to - register first. If we store into a promoted register, - don't directly expand to target. */ - temp = nontemporal || promoted ? NULL_RTX : target; + /* If we store into a promoted register, don't directly + expand to target. */ + temp = promoted ? NULL_RTX : target; temp = expand_expr_real_gassign (assign_stmt, temp, GET_MODE (target), EXPAND_NORMAL); @@ -4034,8 +4033,6 @@ expand_gimple_stmt_1 (gimple *stmt) convert_move (SUBREG_REG (target), temp, unsignedp); } - else if (nontemporal && emit_storent_insn (target, temp)) - ; else { temp = force_operand (temp, target);