From patchwork Sat Oct 14 07:26:59 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ingo Molnar X-Patchwork-Id: 10006277 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 7AB1560230 for ; Sat, 14 Oct 2017 07:27:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 68339290F6 for ; Sat, 14 Oct 2017 07:27:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5C883291B8; Sat, 14 Oct 2017 07:27:45 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id B38E9290F6 for ; Sat, 14 Oct 2017 07:27:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=7283H9p5kGUXNNPkfZwHKsohvFkY0GN1u9ZIgdZaAmQ=; b=OsNifh4eIKbMyH H7LevU9zMH8gF3pHp0PSafFEsKRa1MCqplAVNVGBKfQ1GX5lxiwEGxpsqYYiHMti5T+3fFXny6+RM S8bDP0swc6+gYE3HzgqYnVeRfaEX9Nd2XXmvdl1ulW2tZp74vLIFHznHsxfE/+lxuwuz46mPMNkYZ aDbRKePpYBlYaUNvrYlITBviuZWovWe5k09f1ZdQ8Ve63NyMPNZtylXcLLliTlWuSwvbJuMBjXyHb wrzcPc6aKlC67/LGGDjDITsGG1VWHk9obDyeapBCc4mSAiEqFoAVkjGEHLn5IapG++0N1POQajr9C lAQP0rTamD9o2JKhwM/w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1e3Gr3-0003HY-Pm; Sat, 14 Oct 2017 07:27:29 +0000 Received: from mail-wr0-x244.google.com ([2a00:1450:400c:c0c::244]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1e3Gqz-0003FT-Rb for linux-arm-kernel@lists.infradead.org; Sat, 14 Oct 2017 07:27:27 +0000 Received: by mail-wr0-x244.google.com with SMTP id v91so1028056wrc.5 for ; Sat, 14 Oct 2017 00:27:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=ZDUXm830bwik+hDfm0EbT5r6cnBputUMnrAnVKdpr+c=; b=EqY+3ZhQCqNleqMLBMXI46F1cRYouRtTcxrutZM5QTYz0muIz0sr8jJEX5y5MHkPoq aeH/B0OeTDXM55GPw+8kSR/F9G9TxdY4s8+pABbhSRnXs5yMQsuH92+9PZRSeO4S6WA9 LDiKHuNMZ58n7DrSUkWAc9J6GmneiZPxJarP70BcraU+YoM0Wt9wBl2WAe3bwrDXPpnd H4MJSwlSXlGZv3HxEqCZ0TrArZURuOBJqHLkW7Ge+y5tU9/c+WcGJhQxtMvUnx7QC613 JZeVS1Mjq1jk7B57E7m+yImtZDrvWwzugQETrWJ01JxcUy6zcmosL7YFpjeGlpC9MjpQ Bztw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to:user-agent; bh=ZDUXm830bwik+hDfm0EbT5r6cnBputUMnrAnVKdpr+c=; b=Fvv/KfzlvwBLUNxujEvHzWzpnz1R7IdrH7ciZnS/L3OqUe0jUc6Ie9qpDf5lZka5L9 2AmlOKbb5UZWaQT79YVXDw0Pa2k5K4Nv+uAIZUOnMaJcpvsT8cxf81+Ye2klyi8n9zc9 1A7xz5sp/h9WBQhkt6YOVUp6GRbbjUFTbHNYhYKbWQtJBGHlE3JjfFuaVdq9zlOETSTo G20Bni13jMd27smrj0xlMg3mccGdNJUXO6afAbLkgW5naQ2P5vJNA2w8zUqUQJ3VJ27+ wRTc5JjhMhST8godCvzrM4vrdxwgbuP9YdC47ZLn2FA1mRpUF7SVqCJZR3duGd/BDLX6 2amQ== X-Gm-Message-State: AMCzsaXHO0ZIULPZQWmv+b73WFX2iSdQjEKlTl9i2bA2HW43nyxqFv9s cPaBq7Rp/h1nnzAMF6B6tB4= X-Google-Smtp-Source: AOwi7QBzc/lnB/wzKmerzbCgHCdLb+sUhli89tc4WaBLB4+EjBQDtir6HOPvyxNkWmK+ukpKQp+RlQ== X-Received: by 10.223.164.206 with SMTP id h14mr3041053wrb.25.1507966022973; Sat, 14 Oct 2017 00:27:02 -0700 (PDT) Received: from gmail.com (2E8B0CD5.catv.pool.telekom.hu. [46.139.12.213]) by smtp.gmail.com with ESMTPSA id 9sm3297919wml.24.2017.10.14.00.27.01 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 14 Oct 2017 00:27:01 -0700 (PDT) Date: Sat, 14 Oct 2017 09:26:59 +0200 From: Ingo Molnar To: Johan Hovold Subject: Re: Dramatic lockdep slowdown in 4.14 Message-ID: <20171014072659.f2yr6mhm5ha3eou7@gmail.com> References: <20171013090333.GA17356@localhost> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20171013090333.GA17356@localhost> User-Agent: NeoMutt/20170113 (1.7.2) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171014_002726_049245_8DC41D14 X-CRM114-Status: GOOD ( 18.49 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Arnd Bergmann , linux-mm@kvack.org, Peter Zijlstra , linux-kernel@vger.kernel.org, Byungchul Park , kernel-team@lge.com, Tony Lindgren , tglx@linutronix.de, linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP * Johan Hovold wrote: > Hi, > > I had noticed that the BeagleBone Black boot time appeared to have > increased significantly with 4.14 and yesterday I finally had time to > investigate it. > > Boot time (from "Linux version" to login prompt) had in fact doubled > since 4.13 where it took 17 seconds (with my current config) compared to > the 35 seconds I now see with 4.14-rc4. > > I quick bisect pointed to lockdep and specifically the following commit: > > 28a903f63ec0 ("locking/lockdep: Handle non(or multi)-acquisition > of a crosslock") > > which I've verified is the commit which doubled the boot time (compared > to 28a903f63ec0^) (added by lockdep crossrelease series [1]). > > I also verified that simply disabling CONFIG_PROVE_LOCKING on 4.14-rc4 > brought boot time down to about 14 seconds. > > Now since it's lockdep I guess this can't really be considered a > regression if these changes did improve lockdep correctness, but still, > this dramatic slow down essentially forces me to disable PROVE_LOCKING > by default on this system. > > Is this lockdep slowdown expected and desirable? It's not desirable at all. Does the patch below fix the regression for you - or does the introduction and handling of ->nr_acquire hurt as well? Thanks, Ingo ====================> lib/Kconfig.debug | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index c6401d325b0e..f5b40c1668ea 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -1138,8 +1138,8 @@ config PROVE_LOCKING select DEBUG_MUTEXES select DEBUG_RT_MUTEXES if RT_MUTEXES select DEBUG_LOCK_ALLOC - select LOCKDEP_CROSSRELEASE - select LOCKDEP_COMPLETIONS +# select LOCKDEP_CROSSRELEASE +# select LOCKDEP_COMPLETIONS select TRACE_IRQFLAGS default n help