Received: by 2002:a05:6a10:413:0:0:0:0 with SMTP id 19csp966341pxp; Wed, 16 Mar 2022 22:54:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwXy45WiS6YVj0MH9yvQymHwhbCLjyrmYEMPzWoWZNGnoDbEHpeGnymVJd8NvfRhgsfpH6U X-Received: by 2002:a17:90b:1bc1:b0:1bf:7dc6:bc78 with SMTP id oa1-20020a17090b1bc100b001bf7dc6bc78mr3479052pjb.122.1647496463019; Wed, 16 Mar 2022 22:54:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1647496463; cv=none; d=google.com; s=arc-20160816; b=bS5lro9Tuk5oWqHiC1BZQKyWMdq7anvWZkaWCCStEJepA0CTsNMKuNS6flAj+QehKM ZKlcaMQignonJjkA4BvKK6RPinHu0XOIIcWUaNEYQI5j04mzhw8Io0GOCKGhGNcjRuam 7h8YooqODtaGQMpeah7NBLMxY/9TLxzWG2ENyEOzaXHvrNQ/nYPkY2S3c639Jr/Px9+u tMo7pnLehEKuW7WnwLhCGq8KlSvQH5w9ZCYv54xQcZ/twMQRROY+ljSr0j5WsYoSlYl3 vgugfYUx/z753pv5nBW5pZLHh4ZNdt0ClwcZjDUBLAkPAcKzjfLjRu6HQpZ2yeASAgdk o3cA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=c2EdQq8TYkNxnHKY80QxNf+A2xGQIKpT9IWZ5b+3ymo=; b=bOaxi80T5YFMAtYxrFOF6LYq06jr3qDnA6Pc5KcR2ek6ngTxUmzL+rUQzx7+Gi5lwN 7d7EMd2TxFR61G5Drsd0pJ+hCvVgQvq01DlQRsPYVapv8mfBOVimdq2CQvvZMCXgP+q8 n3/v641woO1NJGxJaLbU4vJ+bTxxIRFbtBeJzCl3txYbTuVE4CpVVzq0sL5npBOjIzJr alwdwMi8AFE6mqHBktFgul03cekjEUCDBVXYflKHDdyDQG8FDtadPYRzVPUM8/G8+BKk gVjROIV6aF+3MXZGqVfevZGyFB84jEOwn7MdWfAkSDZk5HfYPoIx1urqiYElbcI0pKxR 401g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=KHGJ8LGC; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id y16-20020a17090322d000b00151ebecf258si4077810plg.138.2022.03.16.22.54.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Mar 2022 22:54:23 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=KHGJ8LGC; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id BCE2617AD84; Wed, 16 Mar 2022 21:49:30 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243439AbiCPQY7 (ORCPT + 99 others); Wed, 16 Mar 2022 12:24:59 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40220 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231935AbiCPQY6 (ORCPT ); Wed, 16 Mar 2022 12:24:58 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0F66B21E11 for ; Wed, 16 Mar 2022 09:23:41 -0700 (PDT) Received: from zn.tnic (p2e55dff8.dip0.t-ipconnect.de [46.85.223.248]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 336931EC0295; Wed, 16 Mar 2022 17:23:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1647447816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=c2EdQq8TYkNxnHKY80QxNf+A2xGQIKpT9IWZ5b+3ymo=; b=KHGJ8LGCxaeuPrv7yHyQOriggRm2PN1ht87H4D6fQXH08DLAeVU08xfRLMTyLmswLTxgV9 w6S8Uq4b11nA13MXVoCmSf/rfkdkmUTYtrd1C1cYW/AIL/Igj385bCeiV1gWqTYel0sQlT F6kCZpE5tb+mOcUh7zFrhB5KS2w91NY= Date: Wed, 16 Mar 2022 17:23:31 +0100 From: Borislav Petkov To: Noah Goldstein Cc: tglx@linutronix.de, mingo@redhat.com, x86@kernel.org, hpa@zytor.com, luto@kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4] arch/x86: Improve 'rep movs{b|q}' usage in memmove_64.S Message-ID: References: <20211101044955.2295495-1-goldstein.w.n@gmail.com> <20211117210245.843374-1-goldstein.w.n@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20211117210245.843374-1-goldstein.w.n@gmail.com> X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 17, 2021 at 03:02:45PM -0600, Noah Goldstein wrote: > Add check for "short distance movsb" for forwards FSRM usage and > entirely remove backwards 'rep movsq'. Both of these usages hit "slow > modes" that are an order of magnitude slower than usual. > > 'rep movsb' has some noticeable VERY slow modes that the current > implementation is either 1) not checking for or 2) intentionally > using. > > All times are in cycles and measuring the throughput of copying 1024 > bytes. All these claims need to be proven by - real benchmarks - not a microbenchmark - where it shows that modifications like that are not "in the noise". Others should be able to verify those results too. - on a bunch of CPUs from different vendors to verify that they don't cause performance regressions on any. HTH. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette