From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl1-x630.google.com (mail-pl1-x630.google.com [IPv6:2607:f8b0:4864:20::630]) by sourceware.org (Postfix) with ESMTPS id 035AA3858D35 for ; Wed, 8 Dec 2021 23:54:26 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 035AA3858D35 Received: by mail-pl1-x630.google.com with SMTP id b13so2647095plg.2 for ; Wed, 08 Dec 2021 15:54:25 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:references:from:in-reply-to :content-transfer-encoding; bh=ySASZeOIZiDGmFYHLLHhwFtsqrIfpjJ/GAEiZnxOgCw=; b=r2pRCEBo3e3thg10k546497TsBdnZDvMTo7w8Q68KKPYlv0v1f8faV8K++gGOj87iJ pHsP2FuSeXPdsUjM+2D28ujSkd9/7RhTmTeF37CRJSfylOrWvidWSMZZe19Wg5G8IyLp +QWbhcnbsy9L22p6UfWwf1//qdgoNfZALNvItaJL/hcED1+bUbMJ7GFG8AtizApTnZCd l5x42z1k3LILoB2jjIJas/h/lmZZWI08En76Z62bDz+0jeTQDNSSM/izVh8J98JzIK1B S2qe6OF+BDnRAE+2I6A0fiPTcCSOdw1yGV3BiEeJ2hn4MvF5Lt2EOhBRgNOCJh+FN6X8 ke1A== X-Gm-Message-State: AOAM530Q8ybJxMamkUDnNhq3RMIzDL51kJw+3HbOrob0xVZwkbUQWYXE OnEKSenS0HZFOgfTwoYlIAs= X-Google-Smtp-Source: ABdhPJzBA/I5/SWv8o3b9agU+EuQSHeYBNreg1dIMs5bLZmYaNcIthMIiIZZ9XVnseg03ZhwM9lK6A== X-Received: by 2002:a17:90a:e395:: with SMTP id b21mr10768279pjz.103.1639007665089; Wed, 08 Dec 2021 15:54:25 -0800 (PST) Received: from [192.168.1.15] (65-130-80-28.slkc.qwest.net. [65.130.80.28]) by smtp.gmail.com with ESMTPSA id m15sm7083267pjc.35.2021.12.08.15.54.24 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 08 Dec 2021 15:54:24 -0800 (PST) Message-ID: <356920ac-a6dd-11c0-1ca4-fe6f04de8ca3@gmail.com> Date: Wed, 8 Dec 2021 16:54:23 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.3.2 Subject: Re: [PATCH v3 3/7] ifcvt: Improve costs handling for noce_convert_multiple. Content-Language: en-US To: Robin Dapp , gcc-patches@gcc.gnu.org, richard.sandiford@arm.com References: <20211206184352.42264-1-rdapp@linux.ibm.com> <20211206184352.42264-4-rdapp@linux.ibm.com> From: Jeff Law In-Reply-To: <20211206184352.42264-4-rdapp@linux.ibm.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, NICE_REPLY_A, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Dec 2021 23:54:27 -0000 On 12/6/2021 11:43 AM, Robin Dapp via Gcc-patches wrote: > When noce_convert_multiple is called the original costs are not yet > initialized. Therefore, up to now, costs were only ever unfairly > compared against COSTS_N_INSNS (2). This would lead to > default_noce_conversion_profitable_p () rejecting all but the most > contrived of sequences. > > This patch temporarily initializes the original costs by counting > adding costs for all sets inside the then_bb. > --- > gcc/ifcvt.c | 31 +++++++++++++++++++++++++++---- > 1 file changed, 27 insertions(+), 4 deletions(-) OK with a ChangeLog once the prereqs are approved. jeff