[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v6 6/7] x86: introduce "hot" and "cold" page clearing functions


  • To: Jan Beulich <jbeulich@xxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Jason Andryuk <jason.andryuk@xxxxxxx>
  • Date: Tue, 24 Jun 2025 17:01:17 -0400
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=suse.com smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0)
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=kO8bfoNMbPfdf3VI464ZG31w3hQoectP0oDqSm6OO2I=; b=B+C2G4pzZz5cd/mf4nXYPC3HFKmX8XxxZTFRlGjsq4eZJxsObHbTFLhDjdlZS1pizju8KY9fkIbdk6+8dP0ffdmzzZkuFDymtCth0O6Z8nzPGO6IPUNnMP+YQSrnmg1uBXE2L6w2tCSBxSEjbrh7feb1sh0lt4/rcnm/vZyCgNTCGktHfNUCs39BOZ7YdB1iLqVyqsr0PEnr2P551ujXoU/RWr9KNmzTVa729+4sGCt3IiOLTLbNel6Lsfefdc8h+1mIMxYb+9pXGfQSFBixjyJuibYG7RRAcMXsnB2e02toJcGj3DYyhv0RG9vfEYblnxv+J30R8reIHHaA0NM6jA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=DMggrWFMB/6yZ54zXbfVAP4EbVE9bFMK7P6dNtWuOT2Fp11hcA7uesmSO1pBWv1Ap3LrX7plCwizTd+IBZYdE4CAE3r1kNG+VTynL9fcnM3mchVSJr4KAHbGUwJO7VVkozuq9egqOdmBeD63e2PRLNKAZ6ICmtR/QGbFOlSCwVievIZ6UzmQ9n3qHM3yX21HxVnXQTddqK1MKhYYC3+WAbWanB+niTv52Q38tq7hFVHgJ4XKD2uATATzEAakFbfyfEarpMXRbBQNNZkFHlZLVui7FQ/dPe+9XhrfMcQ2uAM6WpbnxQZ+xSABnkTeSiJW3xpnbuxJJ/XZi0nsFhikKw==
  • Cc: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Delivery-date: Tue, 24 Jun 2025 21:01:27 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 2025-06-16 09:01, Jan Beulich wrote:
The present clear_page_sse2() is useful in case a page isn't going to
get touched again soon, or if we want to limit churn on the caches.
Amend it by alternatively using CLZERO, which has been found to be quite
a bit faster on Zen2 hardware at least. Note that to use CLZERO, we need
to know the cache line size, and hence a feature dependency on CLFLUSH
gets introduced.

For cases where latency is the most important aspect, or when it is
expected that sufficiently large parts of a page will get accessed again
soon after the clearing, introduce a "hot" alternative. Again use
alternatives patching to select between a "legacy" and an ERMS variant.

Don't switch any callers just yet - this will be the subject of
subsequent changes.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>

Reviewed-by: Jason Andryuk <jason.andryuk@xxxxxxx>



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.