Received: by 2002:a05:6a10:7420:0:0:0:0 with SMTP id hk32csp792163pxb; Thu, 17 Feb 2022 15:04:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJyVWEH9d38VROQxQobaPnFgCR+Zj1XjLZNjinUNN49ZojNhsu1PEszFEojtbA++WphSXiix X-Received: by 2002:a05:6a00:2285:b0:4e0:617e:dcee with SMTP id f5-20020a056a00228500b004e0617edceemr5180040pfe.66.1645139069872; Thu, 17 Feb 2022 15:04:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645139069; cv=none; d=google.com; s=arc-20160816; b=QyTny3aplsrsMyAZpwml2FMVufcxkY+vreMTLhjZuQxspRshBxUMAB8TcRq6wHDPvx 2BGgtOcmFWG3tC1roG+bk4j4gy5YXe1ErAWpz9WbfHuG/c/33Cq6GphFkA2mApI/AK8R 9l+mPtDW0YfS4nfw//opmNeKJAwwAdiRmragRlLcWt3yYAvUs/9b/gEvEjLaqGHf7ePA X/xj8pqCl0v5diEGaXBuIuA5W7rXg/t5cQtU/JaVToFlFuVW7q5joLtGyO8g7U26Cv3A 88p7/sgWKMMtN53pTNf4hqKhmEfycPuLkOiY4aft1HBl4hgmZoAquc8q+3hnVLB2FsZ2 iDfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=MQP46pb+DPsuzuoL3BGGcclWodDFs0G/3Es7HjdxUCo=; b=DTj4TJrs1v3h2C3T/G47ruC/KaWW7W1LdigRBF94uoyBdxETLKBAQk3d6PPgdEpQQA GclRQ3UnSIwjSv/wKjebFX/4CYX5N/6m1hSxNK7pILrMYPHo0R2phZ1Ffmn4PvVFGTho kqqudLcSseDyFHl6qGCgpqPV/MlBTA8uWp5E466oeaeIvaNjWjP9bsaCqtQgi7LMqBMI +/bxbfadHz+reEO8fMb16qG/wshRb4tp85IndEB5zerJLZ8r+YxSvHMcb0onOgHGjFOw BAt209FeWEu4xZHy/UmBMtAcapomvhxow2aaSwhAReOgVo3cmLDw0dKEDVuMTogQb9y4 k/yA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=cMfVnVTp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id u34si9444287pgl.830.2022.02.17.15.04.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Feb 2022 15:04:29 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=cMfVnVTp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 2347728A10C; Thu, 17 Feb 2022 15:00:08 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230490AbiBQPZj (ORCPT + 99 others); Thu, 17 Feb 2022 10:25:39 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:56988 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232108AbiBQPZi (ORCPT ); Thu, 17 Feb 2022 10:25:38 -0500 Received: from mail-yb1-xb2d.google.com (mail-yb1-xb2d.google.com [IPv6:2607:f8b0:4864:20::b2d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A11E62B048B for ; Thu, 17 Feb 2022 07:25:24 -0800 (PST) Received: by mail-yb1-xb2d.google.com with SMTP id bt13so13809510ybb.2 for ; Thu, 17 Feb 2022 07:25:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=MQP46pb+DPsuzuoL3BGGcclWodDFs0G/3Es7HjdxUCo=; b=cMfVnVTpouxlUm+jaYnytrgpG4TUi9DLUb+yI8qFyskWkAnXv+M6au1/maKPGNtmO8 GcaWRklihf6L8yh393NfKIPLun4OQl9mYY1jRZzl8G0dxaxR37h911mKIPqAbIPKz/v+ 6NHpGj21rf8gWajcLnxmDL3+gi1yzfX/0r5GsyQNm0G3ZDxFDCyEhP0ciU9iVcvUP+7O O/wtUSIJGcfT+Ts4VAKp3Aryl+D1ZEsXMiVhErXbkzytbGDcWRcL5hG4Z9uexhoyPRc9 FH+/+Hlyt8N+opqaLI0HBwUBgEOZ3cX4lZaeTqsxqLys+lkPUrmtmR1F+dIq1tL4rZGb Yk0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=MQP46pb+DPsuzuoL3BGGcclWodDFs0G/3Es7HjdxUCo=; b=xKoZ7uQz2WNeDgQFlZ9NRwZKvTVjSiOER4EEGgRYB6Rry7BazRQJc0egt+iDmkH2Hr 7zAA8VTGiN8XjwArmaOn1QTW7QwkcW9W9A4ZyhSWH39W6EMc+g2B3MpqB2WH68cqmd5j PfaciHh5bJEMb612oFpB6KBtM/89EnhQWASABe5PwXFcdh9qOcl6vg7KiX7yE0MLx4N7 pVPmVi3ZFB/ngn97EDkNNYgMh2agfwABQW63xeIEpia1oDas3SWIAEqbFjqYF6EgWOXH YDhnhvuyCO2kyaYgxR0VCzxoXODaPkqdk97knDGPyFOgL7P5MIbs58tmutP+r/P5G/fK M2KQ== X-Gm-Message-State: AOAM530tGCRowsAQ0EANLLDBnI1+4y9qTUMJ5vjamkSFPl8gTO2Ra1fq /q2f6wlvU3XH4YUTTNcfqfI0JlgYcLtJxl+g95HJaA== X-Received: by 2002:a5b:7c6:0:b0:60b:a0ce:19b with SMTP id t6-20020a5b07c6000000b0060ba0ce019bmr2751275ybq.407.1645111523530; Thu, 17 Feb 2022 07:25:23 -0800 (PST) MIME-Version: 1.0 References: <20220217140441.1218045-1-andrzej.hajda@intel.com> <20220217140441.1218045-3-andrzej.hajda@intel.com> In-Reply-To: From: Eric Dumazet Date: Thu, 17 Feb 2022 07:25:12 -0800 Message-ID: Subject: Re: [PATCH 2/9] lib/ref_tracker: compact stacktraces before printing To: Andrzej Hajda Cc: LKML , intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, netdev , Jani Nikula , Daniel Vetter , Lucas De Marchi , Chris Wilson , Dmitry Vyukov , Jakub Kicinski Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-9.5 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE, USER_IN_DEF_DKIM_WL 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 Thu, Feb 17, 2022 at 7:23 AM Eric Dumazet wrote: > Then, iterating the list and update the array (that you can keep > sorted by ->stack_handle) The 'sorted' part might be unnecessary, if all callers keep @display_limits small enough.