Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp311620yba; Thu, 25 Apr 2019 23:58:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqzMAdPid+hwS7idNnslXXPH7ezWRYUDtoWQUALHPauPs6DKRExGm1YsmFfeowKEIFLGekdR X-Received: by 2002:a17:902:e183:: with SMTP id cd3mr4080605plb.233.1556261939884; Thu, 25 Apr 2019 23:58:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556261939; cv=none; d=google.com; s=arc-20160816; b=Cde/J3Bm1/aH1KSUSmgs+3GGv0uuhGHmuCeOhRjCbnQx2F1H9RlGG5MRquvC/uax01 0yUrsZ5DJQFMc0FNTE5LIUyX8WVmHmNPxfGNbvgn1kGTogL6DljaSeWuuGEFvMaTVBQa SU/NSldu6XQEzYCMiHnb8+7yuQAAdqZu+KmLErT986znmlrd3dFHapQdNDOnSrtOEtBd unWHyN51MH3+KkjaWYbsxxXefTGDLfeBZ2B/CDlveyxNky4QF+EgfSyIzFwJT6OPP6/l JK/lQHyFKIiViRO8GHeQttEu0ov9CWaKszAgo8MGfRlsv5S7NfmSAvQiFPkb20bTY5In pqHA== 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=QyqYEKvDUNhL9MMnFlKvINv444Yhz0Ms3qn2L+mBiN8=; b=dVl/lkuMMjJydCLS/XeB4kJMq6SyKq7oKTGGUNJUX+qQ4Le2m7SwZVd324XjAa1QWp +ViLpQF7MVvhNAZtqx4HhvfIjU9mFf3yYE3VfHTD3QQNz4WH/IjLaUh8afjwCcRWQeok rRr2k/iRHthpiuyQou32RQgZCzV9AgSBYgJ0VJ1Ey1kWwgfj07n3lFGYrQjzRzKAAqw2 QOpq1MXUVp/r8tTUpyTJj5zDq1CNQ+pSowYvVRuzEMaZ/nQ4WbGlxu/KGEgQm7CXsREd EjEh0uUCwtBADgPo8sAmslJhv/M7/z/6gfJwZFtCCNQ1kwf4utsTRpVuxUiykGiQzW+x x8ng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=tzWzi45G; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id h11si26691224plk.270.2019.04.25.23.58.44; Thu, 25 Apr 2019 23:58:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=tzWzi45G; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1725971AbfDZG5t (ORCPT + 99 others); Fri, 26 Apr 2019 02:57:49 -0400 Received: from mail-qt1-f195.google.com ([209.85.160.195]:39800 "EHLO mail-qt1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725899AbfDZG5t (ORCPT ); Fri, 26 Apr 2019 02:57:49 -0400 Received: by mail-qt1-f195.google.com with SMTP id h16so2987261qtk.6 for ; Thu, 25 Apr 2019 23:57:49 -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=QyqYEKvDUNhL9MMnFlKvINv444Yhz0Ms3qn2L+mBiN8=; b=tzWzi45G75cdiVNcT0Ii0HjMC5NjBKU6lUEQDSJSU8qs3hvbWcyNkHa12/PmMFWtm6 BN+Gg0JTbAnWQkJDOfjhD/q9XP16jYv0VVE5UsJ+en6PkichE83m+PmwK0KQAEXdzuUV pC/sxdb7Rsgm5EYEV18PUtaes3BnOZHhBiF/wz/Ky9Z3wvPYhDGUslP7x+soFceVwtDm VZkCWVd7p4mIXxx1eAGEEw6Ji6mQsWXYw4wYSRjD5nasO9Md1USXQLjyrNpbK//FxYjp Ms6zZ93q2QWoWqJe5O5gCXna11+tHrD9daGsWAPeLlIVM4NhWueva7Q3ZO9iE0R/dXNY JR9Q== 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=QyqYEKvDUNhL9MMnFlKvINv444Yhz0Ms3qn2L+mBiN8=; b=i5DicNnmLedHqpuRAwzQRWmyxkS754vbrkUCW1MCNiDAuGwCFFXA5uQI1xyu2AIwKu pmAaS5ava5/+Dugvoz27mSrJMG9fhg0GjTHlgM4sqv+1r7Bc3jfr4hh6E9MKs45zIuwD xIwYJwAyUmX4qtkm9AwN7teUg6js0xeYKP82+V4mZX7021w8b7lJiW8iOqr2KC9ahJNu 2NU2optpxD9CueAqD+ugpZ398GiQcNdPl+eJ3h9y3qqsAbGeNZ4C5IIz29BEqkDEls1E czMo13Qsq4RIVKLL9Q+wnWxe8LseEaQZGbSUM0x9U3VGpVBzHADVH+Y1qk8IBRwgnXoQ J7Qw== X-Gm-Message-State: APjAAAXX8e2w6jJjmRnJRh09oULnVZSpIIsAEsSbOvyWL3BcDwaLwiR/ RFbtMtGHvXj2Yyr9mvRuQ2R0PywdJLwlBDqTev0= X-Received: by 2002:ac8:27a6:: with SMTP id w35mr35010736qtw.157.1556261868816; Thu, 25 Apr 2019 23:57:48 -0700 (PDT) MIME-Version: 1.0 References: <20190424101934.51535-1-duyuyang@gmail.com> <20190424101934.51535-20-duyuyang@gmail.com> <20190425193247.GU12232@hirez.programming.kicks-ass.net> In-Reply-To: <20190425193247.GU12232@hirez.programming.kicks-ass.net> From: Yuyang Du Date: Fri, 26 Apr 2019 14:57:37 +0800 Message-ID: Subject: Re: [PATCH 19/28] locking/lockdep: Optimize irq usage check when marking lock usage bit To: Peter Zijlstra Cc: will.deacon@arm.com, Ingo Molnar , Bart Van Assche , ming.lei@redhat.com, Frederic Weisbecker , tglx@linutronix.de, LKML 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 Thanks for review. On Fri, 26 Apr 2019 at 03:32, Peter Zijlstra wrote: > > On Wed, Apr 24, 2019 at 06:19:25PM +0800, Yuyang Du wrote: > > After only a quick read of these next patches; this is the one that > worries me most. > > You did mention Frederic's patches, but I'm not entirely sure you're > aware why he's doing them. He's preparing to split the softirq state > into one state per softirq vector. > > See here: > > https://lkml.kernel.org/r/20190228171242.32144-14-frederic@kernel.org > https://lkml.kernel.org/r/20190228171242.32144-15-frederic@kernel.org > > IOW he's going to massively explode this storage. If I understand correctly, he is not going to. First of all, we can divide the whole usage thing into tracking and checking. Frederic's fine-grained soft vector state is applied to usage tracking, i.e., which specific vectors a lock is used or enabled. But for usage checking, which vectors are does not really matter. So, the current size of the arrays and bitmaps are good enough. Right?