Received: by 2002:a25:ef43:0:0:0:0:0 with SMTP id w3csp2165944ybm; Sun, 31 May 2020 10:45:14 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyv0KQwU8dRHLU482lP8P0i56/Ym01XmqArreiGgz033rYlogttdtzUYQJ6S0F8x9P6+SGX X-Received: by 2002:a17:906:6890:: with SMTP id n16mr6639621ejr.553.1590947113804; Sun, 31 May 2020 10:45:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590947113; cv=none; d=google.com; s=arc-20160816; b=tIi5PAdjUU9zNo2KgPiS5vBPql3B3emMjviVBflO3L8JtiOHuh+4q4q+XIZwZgff9/ D8k3X9sCpM4nG6DXSJtxvGepvFO3szVMIXDNVyZLPUif6usWiJPLLjVYtgD96h3hdNou cGtWbmI6o0LPVBE0KuNHWQr/6FntZu7LQEAsEaS6wf7R25frLBP3g/8XPrwYvdNROwUT iVT+lskJuKp4TUhmb3sULfjrS2rR14qLiDslf/OMl1iZOVPKXyw+TeCEQUkQFXh8SWGX V81z0cj0jXZf5e1LUW7rDB7fEeN2fxAc69Rwqgn4MUg3JSpeZv7oH9hSkHQy7rsWzF5e zs+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=6Xa/p3RaMPdMpv3FkdDhw9giyhla/nXQ8S7VUYfYelU=; b=iiydWpyYQNVfV+obHSC/+l/klQvcLFVLFmiiegTXK88FCC7PmrTRMTSctr+hvEm1oI WWhpXgqHRMYDMFB7F/6EBc8g4M0DKJ2A+Lx+Daz0c5CnMXW+qyR4gtO/0duSV06TQW/N nws6sHf4D0D56Tmkpnw/3aYoBFoackXDNAY2oBAI5XNXGtn8MFqRbBEIKAhita/uxhBT 8DFEMWJlqPwex6hmTDsOLnHlw3V3IRTeSTvKF40xsjK/CfQMBZc1EqrYTRCFSnBWcCcF gmsk5lZ76zs6pdL+K6UrFfDiRhcN5GMyjgEVKBv1eDYb13BB8/iFuMMP452Nkb0FoOqY gjOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=N1blGyMG; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bc15si230360edb.281.2020.05.31.10.44.50; Sun, 31 May 2020 10:45:13 -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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=N1blGyMG; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728206AbgEaRV1 (ORCPT + 99 others); Sun, 31 May 2020 13:21:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33504 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726193AbgEaRV1 (ORCPT ); Sun, 31 May 2020 13:21:27 -0400 Received: from mail-vs1-xe43.google.com (mail-vs1-xe43.google.com [IPv6:2607:f8b0:4864:20::e43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E3386C061A0E for ; Sun, 31 May 2020 10:21:26 -0700 (PDT) Received: by mail-vs1-xe43.google.com with SMTP id y123so4328019vsb.6 for ; Sun, 31 May 2020 10:21:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=6Xa/p3RaMPdMpv3FkdDhw9giyhla/nXQ8S7VUYfYelU=; b=N1blGyMGEesI/w0cTCqn1JLZRsPhzLgmL8b7poUytOtcMfxrv/8BRxLI1gEHwW/pHL 8/JVLy6/khC/1Bd5a6ZtT5+Gt30EBuMTkd4O69hEM/NEtQq99hnfzH7iR+UzQBewM8IC w/p4fCwGcgni6uNWXT4gvaT6iSskORVqXmtsbKdl9k4XRmdBy/7AxZYRK2QUl+kBthQ8 Hp4fLxTq2wkWx6mzf31ZitMBhJ+Yufov4Olvdq2pYcUh9dFlsWFYl76RlywiqptG8tx+ orBNgugCjNNHIM/oihj8oPAzwfoN9QV9sm9X6DW4jp1cYvm7jFhCxA+L0LaaIkIcPL3p TTeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=6Xa/p3RaMPdMpv3FkdDhw9giyhla/nXQ8S7VUYfYelU=; b=g+2kL2Flx4EVSyrVLwge9/BNZsNXGrmwl2hC1UUai1Xtdb15f3U/1WD8bymyLo0nCW 922sFmxvOoqb/Omj7HTo8f+GnS7TjyDuqYDYJtXVahqgL8SZ+eYKMaWQPA5a8ANrYdRB U04jk8tpCXawNZnyfVNbaRo66Mv4TO8dugbKsGB95NH/4p0HeryBlA0QMsbcV7YLoCgT vmSmeeB9bvz/qa/fb+V/hK5Q9XxVdtch31b1NQCqumX06bc1lguTEeedpYs42E31R6Hn w2DybD4Bjydn3xWt2Eg4kow8UEC6/frUa/VM1RUyHSnIyALc0g+WAsvKTuGG1cs3cGBs FdQg== X-Gm-Message-State: AOAM530B0bSiFNlwFiv9pNCyD/Vw4OE9r6ua70osDIWcI5gzuGx2ZEnR tjehuZHo2blMaVIlgKqwlji7pMHDt41Mem44mzrUfLSr X-Received: by 2002:a67:c18a:: with SMTP id h10mr156735vsj.186.1590945686020; Sun, 31 May 2020 10:21:26 -0700 (PDT) MIME-Version: 1.0 References: <20200531131237.24781-1-realwakka@gmail.com> In-Reply-To: <20200531131237.24781-1-realwakka@gmail.com> From: Emil Velikov Date: Sun, 31 May 2020 18:18:12 +0100 Message-ID: Subject: Re: [PATCH] drm/vkms: Optimize compute_crc(), blend() To: Sidong Yang Cc: Daniel Vetter , Haneen Mohammed , Rodrigo Siqueira , David Airlie , "Linux-Kernel@Vger. Kernel. Org" , ML dri-devel Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 31 May 2020 at 14:12, Sidong Yang wrote: > > Optimize looping pixels in compute_crc() and blend(). Calculate > src_offset in start of looping horizontally and increase it. > It's better than calculating in every pixels. > When you say "optimize" have you observed any actual benefits of the patch - be that smaller binary, faster execution time, etc? If there are - mentioned them in the commit message. Otherwise, it doesn't optimise anything. A while back, I've suggested something similar [1] mostly for cosmetic purposes - doubt there's much benefits beyond that. HTH -Emil [1] https://patchwork.freedesktop.org/patch/365177/#comment_674314