From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl1-x634.google.com (mail-pl1-x634.google.com [IPv6:2607:f8b0:4864:20::634]) by sourceware.org (Postfix) with ESMTPS id ADD4D3858D28 for ; Tue, 1 Aug 2023 23:13:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org ADD4D3858D28 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-pl1-x634.google.com with SMTP id d9443c01a7336-1b9c368f4b5so2267415ad.0 for ; Tue, 01 Aug 2023 16:13:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20221208.gappssmtp.com; s=20221208; t=1690931627; x=1691536427; 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:message-id:reply-to; bh=bXlSpLQVnOO77ViSJ8gWPqijb8ZU5Qi79fe9wDxrdW0=; b=rRaX/BD9qNuqPvmUK6j+UjjRpLlUQ8BhFTHjLWgUrWhu2ZhqgWT8poscMGy4vDawGw XQ0RDsno1dPquLEg08jaC9LxYTCUVMl2p6RubMgISzdDMOsZdfnqK4FxvwEbl3HU6Vn7 gBvmCXF9HlEw+nlFW9V7mi3ENrTDpzFcr95w+yQU9vDaP8FLnbUIeLf9whE4osrlYLM3 PGViz2Ut7CPmNheNW6T0sZ5egckeOG2m2YBB83DQUbRouEUu3GklBdCxySB7oM7DF4WL KeD8/CskxFcaLRvSd9w3Fq8kICaYB2lfcuZ8m9HTozGQlriN9wBEJ5OBmIrcyb4N+l8q t0HA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690931627; x=1691536427; 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:message-id:reply-to; bh=bXlSpLQVnOO77ViSJ8gWPqijb8ZU5Qi79fe9wDxrdW0=; b=TYmF7f/xEx+O1C7hwoEv5qh/OmCArzx9h0/rUqdUGjtCW704egNlTSc7zJb8uicnUe iijpzZrvMl9ukvJU37oYLE3N0CobAjaEUmKW1xjaH/87lFx9ie57VNfd/+5JIpll2AHO kRfLtZNGooQbUEHuBoQQL1vpjaYI6Z2U7a91b4qhsHAB99UAYzhqLiMD0YntPiPJ9LO4 6NO7lhbLXzI9+ldNjGuwG5PHRmTq7MqbzXmP1ZP60P16pwPYcOEC3NVUQHzqX58eTqal igKkZYvujoTElfLHE9Yf/dyA7oLL+dbMIPEC18Lg9OZc+AUxeXfxWqtMlHC+vreEUwc4 SzNg== X-Gm-Message-State: ABy/qLaV33yA4wpgp0SzCeUESoVhtMw9uQp4ybZQgPSwjuvbQRWWjBu7 roRNOKF1cQxM/YhcNX8YJhRhuA== X-Google-Smtp-Source: APBJJlHPyB0PYUVk1ITKEQt/wNpyCrY50ZVgTqfFIO+9WM6NHMlmj2Z+FrmeDGzNUtVfLp4Q4XbeMA== X-Received: by 2002:a17:902:f546:b0:1bb:c7bc:ceb8 with SMTP id h6-20020a170902f54600b001bbc7bcceb8mr19129776plf.22.1690931626660; Tue, 01 Aug 2023 16:13:46 -0700 (PDT) Received: from [10.0.16.165] ([50.221.140.188]) by smtp.gmail.com with ESMTPSA id w5-20020a1709029a8500b001b8a3e2c241sm10956739plp.14.2023.08.01.16.13.45 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 01 Aug 2023 16:13:46 -0700 (PDT) Message-ID: Date: Tue, 1 Aug 2023 16:13:45 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 Subject: Re: RISC-V: Folding memory for FP + constant case Content-Language: en-US To: Philipp Tomsich Cc: Jeff Law , Manolis Tsamis , Jivan Hakobyan , gcc-patches@gcc.gnu.org References: <3c1f0f8a-34ed-abb2-8a49-3083a2cc55d2@gmail.com> <61c9b9c2-f52e-2b4e-6d02-62c991603c39@gmail.com> <64233838-fe5e-458d-1eaf-3025b5448d85@rivosinc.com> <91c12503-c288-5b81-8941-cc62bab2ee98@gmail.com> <73dc8b97-7a7b-d9a0-2e8e-b4a5aaa3ee93@rivosinc.com> From: Vineet Gupta In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,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 8/1/23 16:06, Philipp Tomsich wrote: > Very helpful! Looks as if regprop for stack_pointer is now either too > conservative — or one of our patches is missing in everyone's test > setup; we'll take a closer look. FWIW, all 5 of them involve a SH2ADD have SP as source in the fold FP case which f-m-o seems to be generating a MV for. > > On Wed, 2 Aug 2023 at 01:03, Vineet Gupta wrote: >> >> >> On 8/1/23 15:07, Philipp Tomsich wrote: >>> +Manolis Tsamis >>> >>> On Tue, 1 Aug 2023 at 23:56, Jeff Law via Gcc-patches >>> wrote: >>>> >>>> On 8/1/23 13:14, Vineet Gupta wrote: >>>> >>>>> I have some numbers for f-m-o v3 vs this. Attached here (vs. inline to >>>>> avoid the Thunderbird mangling the test formatting) >>>> Thanks. Of particular importance is the leela change. My recollection >>>> was that the f-m-o work also picked up that case. But if my memory is >>>> faulty (always a possibility), then that shows a clear case where >>>> Jivan's work picks up a case not handled by Manolis's work. >>> f-m-o originally targeted (and benefited) the leela-case. I wonder if >>> other optimizations/changes over the last year interfere with this and >>> what needs to be changed to accomodate this... looks like we need to >>> revisit against trunk. >>> >>> Philipp. >>> >>>> And on the other direction we can see that deepsjeng isn't helped by >>>> Jivan's work, but is helped by Manolis's new pass. >>>> >>>> I'd always hoped/expected we'd have cases where one patch clearly helped >>>> over the other. While the .25% to .37% improvements for the three most >>>> impacted benchmarks doesn't move the needle much across the whole suite >>>> they do add up over time. >>>> >>>> Jeff >> I took a quick look at Leela, the significant difference is from >> additional insns with SP not getting propagated. >> >> e.g. >> >> 231b6: mv a4,sp >> 231b8: sh2add a5,a5,a4 >> >> vs. >> >> 1e824: sh2add a5,a5,sp >> >> There are 5 such instances which more or less make up for the delta. >> >> -Vineet >>