From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by sourceware.org (Postfix) with ESMTPS id 198DF3858D37 for ; Tue, 27 Sep 2022 01:40:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 198DF3858D37 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pj1-x1035.google.com with SMTP id p14so5287204pjd.3 for ; Mon, 26 Sep 2022 18:40:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date; bh=YAeqWuqjlcqQbwsY51VZTPpgZE2PxmdP1WmPciuUA6Q=; b=I4bSQuBLd2MNJtoc4SUinK9KWpPP4Bvd0FQZ3m/n0jWv4uG6g5Vi4iXDCmt4GF53hS RWbO14gfhi1F089urnmOmoHj55PLsvhkzwaKSJDH24UOGjheqTX07W0K/qNEpRSVt8Je n3+ErsJ5dnja3ryVCUEIH9s5p6YHep+4JihvUX1NDSNDlv8KqJV0KYPQlHmtlDP+RNYU YfDncnS0gDQPeWU/lhILT+WDt2wNxVIKx8bPNIqrQfC0KSAGcn+xti1TFsQUfas6aZFb zYeL6AkBJYcTN5FsKthw01exNBfElxKYd9EMpSX8aTIF2Vco2T7UqGYhsmSuPekBOOi/ u9ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date; bh=YAeqWuqjlcqQbwsY51VZTPpgZE2PxmdP1WmPciuUA6Q=; b=nhVkn8nS1ic6vTwjhjz/LMWw9GGzB8+xHhttQU84F+RQJDg/Tcletke674dGKgxPv7 RUlpTga0w4yVP/wodAixMmC7z1zbnNUrUD3vZHxLPmOqvrK/Wr0jwhmNASE02DkRqdMI gkHAZsxe4KsOYH0i6Y0ysHIVygkGH2ReDX3Hi+BQ6u/R0+CPOVMP728/YYbM2NuKT/xm Z2V/bqWXxy2f1W1ode8/IGRBFD3FPhuWxhvjH+Kj14uMQVMIW/g/iSDWC6fwp7/JVae+ gV/T5THhrf02w5MnwaIRvYzHR3I4th3DV7qWg6lfZOt/RRsI9TkCifpPL39BpA6/bnEQ /fsg== X-Gm-Message-State: ACrzQf31cqAWLklgUORHMCafLKG6kzAs95YAVv/ThAC4dn8ChfSZ+hIt kbt0FpB21v1eON+uDqWUC1A= X-Google-Smtp-Source: AMsMyM6RjOuLsnn4KQfwNLZMg9FTp2RtxfDpEwy51Xp6YQwAdpSvr7UJnE5DiyJz8O4sJjH1gI176g== X-Received: by 2002:a17:903:2005:b0:178:3a78:80f5 with SMTP id s5-20020a170903200500b001783a7880f5mr25192490pla.174.1664242825892; Mon, 26 Sep 2022 18:40:25 -0700 (PDT) Received: from ?IPV6:2601:681:8600:13d0::f0a? ([2601:681:8600:13d0::f0a]) by smtp.gmail.com with ESMTPSA id w3-20020a170902ca0300b00172751a2fa4sm115024pld.80.2022.09.26.18.40.24 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 26 Sep 2022 18:40:25 -0700 (PDT) Message-ID: <54413b00-89a6-4289-8f29-ea381750058e@gmail.com> Date: Mon, 26 Sep 2022 19:40:24 -0600 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.1 Subject: Re: [PATCH] Ignore debug insns with CONCAT and CONCATN for insn scheduling Content-Language: en-US To: Jakub Jelinek Cc: "H.J. Lu" , gcc-patches@gcc.gnu.org References: <20220902143639.2464892-1-hjl.tools@gmail.com> <93fb0c92-c6a4-450b-2d0a-eddd30543fae@gmail.com> From: Jeff Law In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.9 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.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 9/26/22 17:43, Jakub Jelinek wrote: > On Mon, Sep 26, 2022 at 05:23:45PM -0600, Jeff Law via Gcc-patches wrote: >> On 9/26/22 13:52, H.J. Lu wrote: >>> On Sat, Sep 24, 2022 at 1:37 PM Jeff Law wrote: >>>> On 9/21/22 16:11, H.J. Lu wrote: >>>>> On Wed, Sep 7, 2022 at 10:03 AM Jeff Law via Gcc-patches >>>>> wrote: >>>>>> On 9/2/2022 8:36 AM, H.J. Lu via Gcc-patches wrote: >>>>>>> CONCAT and CONCATN never appear in the insn chain. They are only used >>>>>>> in debug insn. Ignore debug insns with CONCAT and CONCATN for insn >>>>>>> scheduling to avoid different insn orders with and without debug insn. >>>>>>> >>>>>>> gcc/ >>>>>>> >>>>>>> PR rtl-optimization/106746 >>>>>>> * sched-deps.cc (sched_analyze_2): Ignore debug insns with CONCAT >>>>>>> and CONCATN. >>>>>> Shouldn't we be ignoring everything in a debug insn? I don't see why >>>>>> CONCAT/CONCATN are special here. >>>>> Debug insns are processed by insn scheduling. I think it is to improve debug >>>>> experiences. It is just that there are no matching usages of CONCAT/CONCATN >>>>> in non-debug insns. >>>> But from a dependency standpoint ISTM all debug insn can be ignored. I >>>> still don't see why concat/concatn should be special here. >>>> >>> I tried to ignore everything in a debug insn. It caused many regressions in >>> the GCC testsuite. >> Not terribly useful -- what failed and why? > I think the design for debug insns in the scheduler is that they do affect > scheduling decisions, but what is in debug insns should only affect actual > scheduling of the debug insns and not the rest. > So it wouldn't surprise me if ignoring everything in a debug insn broke a > lot. But I admit I never fully understood how it works, hopefully Alex or > Vlad do. But if we  look at debug insns in scheduling decisions, wouldn't that likely trigger a variety of compare-debug failures. Something here doesn't make sense. jeff