Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp6343269ybi; Wed, 29 May 2019 06:33:00 -0700 (PDT) X-Google-Smtp-Source: APXvYqyaCM2uqGB7tvk2aonaNtrYiMhDS/8h8tL+fcS46fOMY+ONRnbCBGqy7knhT8G+EyCw7tP+ X-Received: by 2002:a17:902:a5c5:: with SMTP id t5mr21929570plq.288.1559136779986; Wed, 29 May 2019 06:32:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559136779; cv=none; d=google.com; s=arc-20160816; b=OAXVIkq/Q9c0nled0xmk/6vNL/oLXinVRiuk0VPK3OerM/MkCmMnFM9/FUUfVP9JKn Evw6e3ABRwuUg92ogYBsdkaP8s+LnCIKtFW5V3Lf+v2LefhP3wsYk/NgUxqTN82aXAig mNHkWgGGlNoeDQca0oVblYyF6PkT0T2Njdj/NbWAB/3s6eWPhrmyVMlqFYXRy3lXWoIL SeN7fUGK346vulp2fBhk3qhHV1IfkuNK2buf7QRvBmUtR00Sz0ZjceTA8YzLnoSLVFRu diietTR24pGAPcfyl/58G89LDUKPbVSERipHRqyEjzt2Hn2DD8KQcIq7xY7A2Nc/qo3X jBww== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=JhvQcxsDOAi99i8nAmNAWnYo8mb5wQBh82wJuM9KB6k=; b=rTuw8n8iLIZe2cGKpCuUJyK5UhvJGaBd0U72x28ubku817JAGySZuZr20+G3Fz0V6A ht7bX70jOYblkmxOJV6JdmLHwPIeiYr+MSkOOPDHOgLDsOkLVzEJ/xtiildk90FnAP+7 aoYqOD13fItluMSJkF/BXBiXvI0oXyBQBNqrS3KBXIepuX/lEUIJgtKiQ1i3XbGFYRcx H+SXIVuCFt8SIrxE7u1WkxHET3X9ntgW1bOzyBlsd0UhqrOOOUD6zDXZsFeO6MXQYg6F 1nWFZkvioaBIdmue3MNmcrCOIG4/S7Vnh1wyHXpLum6LwwLg8sIzpQH/lkOF6KijhsOM D92Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b=MYTZvabu; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 11si28222269pfn.80.2019.05.29.06.32.41; Wed, 29 May 2019 06:32: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=fail header.i=@infradead.org header.s=merlin.20170209 header.b=MYTZvabu; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727171AbfE2Nao (ORCPT + 99 others); Wed, 29 May 2019 09:30:44 -0400 Received: from merlin.infradead.org ([205.233.59.134]:35708 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726104AbfE2Nan (ORCPT ); Wed, 29 May 2019 09:30:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=JhvQcxsDOAi99i8nAmNAWnYo8mb5wQBh82wJuM9KB6k=; b=MYTZvabuIfIQiLPnTjcRrxTpg Fej6YenqPFI3Wa4z0+9Jo+9gIik1GxE8Jz34Eu3O3U/NBon3cr1ZAPWP5kn26P8pV9+BjP1Fgr9Y5 7s9eCeZkmEOwaeuwhSaGE7wZP/3euBRdIrAUW1seXpdTxueQCRCUxrOWuhYYAVJjK1AoBp5akjeGd 0OC6hhsaWuXMJbmYJpq7PnjIuE7Ad2+D9xTTd6oOjvRq97Uh8FXF0TYwH23mv3j8hJN7JsWKK+EWD JQNbGmlzYp99BmgRIFEOjvdEoCQD7KfLsX9gF5a0eNv4rQAlHzMbzmGLDd9n1fqFZEd+5xZB25VQR HL0GoZ2Bw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=hirez.programming.kicks-ass.net) by merlin.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1hVye0-0005Hi-2q; Wed, 29 May 2019 13:29:28 +0000 Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id D86EA201DA64E; Wed, 29 May 2019 15:29:26 +0200 (CEST) Date: Wed, 29 May 2019 15:29:26 +0200 From: Peter Zijlstra To: Steven Rostedt Cc: Daniel Bristot de Oliveira , linux-kernel@vger.kernel.org, williams@redhat.com, daniel@bristot.me, Ingo Molnar , Thomas Gleixner , "Paul E. McKenney" , Matthias Kaehlcke , "Joel Fernandes (Google)" , Frederic Weisbecker , Yangtao Li , Tommaso Cucinotta Subject: Re: [RFC 2/3] preempt_tracer: Disable IRQ while starting/stopping due to a preempt_counter change Message-ID: <20190529132926.GV2650@hirez.programming.kicks-ass.net> References: <20190529083357.GF2623@hirez.programming.kicks-ass.net> <20190529102038.GO2623@hirez.programming.kicks-ass.net> <20190529083930.5541130e@oasis.local.home> <20190529131957.GV2623@hirez.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190529131957.GV2623@hirez.programming.kicks-ass.net> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 29, 2019 at 03:19:57PM +0200, Peter Zijlstra wrote: > On Wed, May 29, 2019 at 08:39:30AM -0400, Steven Rostedt wrote: > > I believe I see what Daniel is talking about, but I hate the proposed > > solution ;-) > > > > First, if you care about real times that the CPU can't preempt > > (preempt_count != 0 or interrupts disabled), then you want the > > preempt_irqsoff tracer. The preempt_tracer is more academic where it > > just shows you when we disable preemption via the counter. But even > > with the preempt_irqsoff tracer you may not get the full length of time > > due to the above explained race. > > IOW, that tracer gives a completely 'make believe' number? What's the > point? Just delete the pure preempt tracer. Alternatively, fix the preempt tracer by having it completely disregard IRQs.