Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp637658pxu; Tue, 6 Oct 2020 15:25:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxRyGupYu7YYhEwZI0AVRequ3uI9LKvS5C1wZ3Savr+L6vpuNs/F6qRoQpgUD2JuTY/SlDd X-Received: by 2002:a17:906:4a03:: with SMTP id w3mr228354eju.15.1602023157754; Tue, 06 Oct 2020 15:25:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602023157; cv=none; d=google.com; s=arc-20160816; b=Gv7HVvoacyLO4PzBA6COZ5vFb4NWUcPTpYfPTEQ8h5iIfnefyIdE0dXIHmIWdVuGpT pTdAnDH1ywepPL4kNrXh8N49Cf9KwF71U9k7q8Ik8qaFi9O0+TkiGk/uOWrkIwm+pH7s IrFAOofqHptgPrtSHUMNxEr0oZG4UWD6gmV8U15LVMkdNdgPGGDeIQIaR8CXb62YTDKM v7XH74CJntfnrha2TSh2nDFjt3HYONxqCh8C/W9my4ae9Sl035VmVYLDfKDSBJKWmm1y MTS1d72FOvHFak0RgBxkzfds+zoEoNDoherIzCcEcpqSx84ic4foYNeel1gZIvJe8D+I CeoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=yQAG4Csx4U+1cs5VYBBTCd4zUGT++jJOydU2FfFIwUE=; b=LjlMWlNxCUxozPYqIEw74gJ3lI4mwLRMKuEWy3DGKCaVY5+SSkc8LIkp9NUv+MKq8z F6rb6HN9EzDopFokP5Yu1ftKt+qAVPKWqDVjpd8rwl2+AtJRVOv/P9MhqZqIT+T0Ozf5 xtA3aCyCrGPl6UAYVbsprBzm5U3H8kCSlr9Axv7ENUFVCflPt5329akfYMzS7xuebdlL jkncgx/ew3kbg0q52M2c6/i8N1m3i4CbS2H/wXDi6QfzP6k5NnntyANc3kPWdeDehen+ Vfbtt8fSbD6vmiRFpRhH4a5QrZxx89Zx9fB5pw47HEKwePNMntEDwC2Zmb1hzpTQR8BE sn0Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id os5si69100ejb.489.2020.10.06.15.25.27; Tue, 06 Oct 2020 15:25:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727161AbgJFTrs (ORCPT + 99 others); Tue, 6 Oct 2020 15:47:48 -0400 Received: from outbound-smtp27.blacknight.com ([81.17.249.195]:47372 "EHLO outbound-smtp27.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725943AbgJFTrs (ORCPT ); Tue, 6 Oct 2020 15:47:48 -0400 Received: from mail.blacknight.com (pemlinmail06.blacknight.ie [81.17.255.152]) by outbound-smtp27.blacknight.com (Postfix) with ESMTPS id EF8E81620A6 for ; Tue, 6 Oct 2020 20:47:46 +0100 (IST) Received: (qmail 11003 invoked from network); 6 Oct 2020 19:47:46 -0000 Received: from unknown (HELO techsingularity.net) (mgorman@techsingularity.net@[84.203.22.4]) by 81.17.254.9 with ESMTPSA (AES256-SHA encrypted, authenticated); 6 Oct 2020 19:47:46 -0000 Date: Tue, 6 Oct 2020 20:47:45 +0100 From: Mel Gorman To: "Rafael J. Wysocki" Cc: Takashi Iwai , linux-kernel@vger.kernel.org Subject: Re: ACPI _CST introduced performance regresions on Haswll Message-ID: <20201006194745.GM3227@techsingularity.net> References: <20201006083639.GJ3227@techsingularity.net> <20201006190322.GL3227@techsingularity.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <20201006190322.GL3227@techsingularity.net> User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 06, 2020 at 08:03:22PM +0100, Mel Gorman wrote: > On Tue, Oct 06, 2020 at 06:00:18PM +0200, Rafael J. Wysocki wrote: > > > server systems") and enable-cst is the commit. It was not fixed by 5.6 or > > > 5.9-rc8. A lot of bisections ended up here including kernel compilation, > > > tbench, syscall entry/exit microbenchmark, hackbench, Java workloads etc. > > > > > > What I don't understand is why. The latencies for c-state exit states > > > before and after the patch are both as follows > > > > > > /sys/devices/system/cpu/cpu0/cpuidle/state0/latency:0 > > > /sys/devices/system/cpu/cpu0/cpuidle/state1/latency:2 > > > /sys/devices/system/cpu/cpu0/cpuidle/state2/latency:10 > > > /sys/devices/system/cpu/cpu0/cpuidle/state3/latency:33 > > > /sys/devices/system/cpu/cpu0/cpuidle/state4/latency:133 > > > > > > Perf profiles did not show up anything interesting. A diff of > > > /sys/devices/system/cpu/cpu0/cpuidle/state0/ before and after the patch > > > showed up nothing interesting. Any idea why exactly this patch shows up > > > as being hazardous on Haswell in particular? > > > > > Presumably, some of the idle states are disabled by default on the affected > > machines. > > > > Can you check the disable and default_status attributes of each state before > > and after the commit in question? > > > > # grep . pre-cst/cpuidle/state*/disable Sorry, second attempt after thinking the results made no sense at all. Turns out I fat fingered setting up the enable-cst kernel the second time to collect what you asked for and the patch was not applied at all. # grep . pre-cst/cpuidle/state*/disable pre-cst/cpuidle/state0/disable:0 pre-cst/cpuidle/state1/disable:0 pre-cst/cpuidle/state2/disable:0 pre-cst/cpuidle/state3/disable:0 pre-cst/cpuidle/state4/disable:0 # grep . pre-cst/cpuidle/state*/default_status pre-cst/cpuidle/state0/default_status:enabled pre-cst/cpuidle/state1/default_status:enabled pre-cst/cpuidle/state2/default_status:enabled pre-cst/cpuidle/state3/default_status:enabled pre-cst/cpuidle/state4/default_status:enabled # grep . enable-cst/cpuidle/state*/disable enable-cst/cpuidle/state0/disable:0 enable-cst/cpuidle/state1/disable:0 enable-cst/cpuidle/state2/disable:0 enable-cst/cpuidle/state3/disable:1 enable-cst/cpuidle/state4/disable:1 # grep . enable-cst/cpuidle/state*/default_status enable-cst/cpuidle/state0/default_status:enabled enable-cst/cpuidle/state1/default_status:enabled enable-cst/cpuidle/state2/default_status:enabled enable-cst/cpuidle/state3/default_status:disabled enable-cst/cpuidle/state4/default_status:disabled That looks like C3 and C6 are disabled after the patch. # grep . enable-cst/cpuidle/state*/name enable-cst/cpuidle/state0/name:POLL enable-cst/cpuidle/state1/name:C1 enable-cst/cpuidle/state2/name:C1E enable-cst/cpuidle/state3/name:C3 enable-cst/cpuidle/state4/name:C6 -- Mel Gorman SUSE Labs