From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ot1-x32a.google.com (mail-ot1-x32a.google.com [IPv6:2607:f8b0:4864:20::32a]) by sourceware.org (Postfix) with ESMTPS id 7FFA63858403 for ; Mon, 25 Mar 2024 03:05:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7FFA63858403 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 7FFA63858403 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::32a ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1711335936; cv=none; b=Eeq2bJKVBBG/OQ0XJRg/uyDqq/SuKeR/XOi4jyxRvkBDrWY7l5C5XhotuSw+v95gaxOZBBRP8ZuCHtxDKGxXnWhv4gRrdJ6JpQ8d2h1WJtvR6jP4rhSPoKrc8WPQqgDs3B3rLsh/n9xRfWz2ksrDJ2zcz61KWd54/IWts89b1XU= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1711335936; c=relaxed/simple; bh=Cf9MPH/X2ScbXsVgUcy2TLjCClZNDpGvbpxUV7Kjf94=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=guTaTxEwswQ8YhmPkLyXvAn/jmg4gDbVQNy8wn3SdWcGYU/VixvWr3JV0F9BuybtkR70WJQNPygwYX4lSQns8lNdHg4P439tPkRvcHBGF5UgheMM3sn8np/mzXgkd06IhwnPvmiaZNed5y4xPERj8gb8atPnT6ZOy72tsHOyWDI= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-ot1-x32a.google.com with SMTP id 46e09a7af769-6e6a00de24aso1908029a34.3 for ; Sun, 24 Mar 2024 20:05:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1711335934; x=1711940734; darn=gcc.gnu.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=9nc4AY0A7Vzrj+oahSOT+VIrapIvnUjY8qvOU5vBoMk=; b=fId8o1615ge7HaP/05ROWrXI3yf/mQ/teHvX3fK4UvW35MEExMaiTAvdFX0NEx1eMk +PVRdAk55IpRzIkB5VckEEDr8O2hoyrt8+vwBZO1JB23spouRLTG3agIzbk5OPs0CVRl 3zprqhR/HfCsIY98AHvgLrkH0/YBtmU6NKASs1Wldulf3TlBXT8PYe7JyQ7zIiFkcu6o CUzDCau2L4RRx5M8R9JqTsAZKogyLmQVhGtfhfHSnZtR3FKGv1aYKthPrBc7CRun2+9N fHdlIYsAZVQq9AT+q7/CfqcNfKOX26ZzsaJJUwCi7djjqlWDPo1bePXQHQsRN2uG2Ibh ERuA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711335934; x=1711940734; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=9nc4AY0A7Vzrj+oahSOT+VIrapIvnUjY8qvOU5vBoMk=; b=O4d3lm3T0p1q+q5QrzhWbg1tLbLfaBmsvYig1qyEYAkJp0UMEZcdAreICDtf6rsVaI ne2Dqo0aSp/npZi7FUfb6hHIhpcSn7qapb7DHy6IbtyKRs6k9Pr9JMjytbW4X/L00u37 8/Kfwwi1AWXWq/+zfbJRX80zFoGkfPumz1HmVKftB4fvDggKU96MU1d0as5PycznLQGz IOZw/D/2kAP9m4GaOfxzP8TisfIgPhqEYOlggqyLKl4iOCaUpGt8FtAeMDFdcwT1ULet 9Y16AA2brGEdVorlrmox1ekt8gzrc+iVwLEQsW4BZHxSVRZPTDyNzFPLOwKuUW9Imm8b sf+w== X-Forwarded-Encrypted: i=1; AJvYcCWYnUYTNShmbL+D9cYLXlQToWVHcdOJ4vYzmQ9VlY0amgNbL2dbp/cZBlb7o8WUnX0J6kOeOUfCU2w4U6qDh++Xf2j+ie9ooQ== X-Gm-Message-State: AOJu0YxtPuD+Zg1lbKHx/dJabnTVmPKu93vXWY57oXU7K+giQNyeiURy Qli1HD9opVrbvQwOTqXAMmDIq/k56rccxDMNA4FK/31HvxKgZx9l X-Google-Smtp-Source: AGHT+IEael5fWf7eU1Ir2EdqpnaPmm5Dh0vS0b8yHmnpnMqx7SLcvZFrSlY77BuN63w7jGaAQ7g1/g== X-Received: by 2002:a9d:65d5:0:b0:6e6:c6f8:7c5f with SMTP id z21-20020a9d65d5000000b006e6c6f87c5fmr5498263oth.35.1711335933586; Sun, 24 Mar 2024 20:05:33 -0700 (PDT) Received: from [172.31.0.109] ([136.36.72.243]) by smtp.gmail.com with ESMTPSA id x9-20020a9d6289000000b006e6870ebcbasm975023otk.18.2024.03.24.20.05.32 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 24 Mar 2024 20:05:33 -0700 (PDT) Message-ID: Date: Sun, 24 Mar 2024 21:05:31 -0600 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Beta Subject: Re: scheduler queue flush (was Re: [gcc-15 0/3] RISC-V improve stack/array access by constant mat tweak) To: Vineet Gupta , gcc-patches@gcc.gnu.org Cc: kito.cheng@gmail.com, Palmer Dabbelt , gnu-toolchain@rivosinc.com, Robin Dapp References: <20240316173524.1147760-1-vineetg@rivosinc.com> <2acab452-4dc0-4782-aedf-8495d84d7374@rivosinc.com> <3faf0264-7b82-4574-bb45-df66d77421be@gmail.com> Content-Language: en-US From: Jeff Law In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,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 3/21/24 11:19 AM, Vineet Gupta wrote: > > > Oh yeah ! Robin hinted to this in Tues patchworks meeting too > > default : 2,565,319,368,591 > 128 : 2,509,741,035,068 > 256 : 2,527,817,813,612 > no-sched{,2}: 1,295,520,567,376 So one more nugget here. I happened to be doing some historical data mining and I can see the huge instruction jump in our internal runs. We jump from 1.4T instructions to 2.1T. But more importantly we see the cycle counts *improve* across that span, roughly 17%. Unfortunately the data points are way far apart in time, so I don't think they help us narrow down the root cause. Mostly it highlights that while instruction counts are generally correlated to cycle counts, they can deviate and in this case they do so wildly. Whatever fix we end up making we'll likely need to run it on a design to evaluate its actual performance impact. jeff