From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752094AbbJECEZ (ORCPT ); Sun, 4 Oct 2015 22:04:25 -0400 Received: from mx2.suse.de ([195.135.220.15]:53219 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751994AbbJECEW (ORCPT ); Sun, 4 Oct 2015 22:04:22 -0400 Date: Sun, 4 Oct 2015 19:04:06 -0700 From: Davidlohr Bueso To: Leon Romanovsky Cc: Geliang Tang , Andrew Morton , "Kirill A. Shutemov" , Hugh Dickins , "Peter Zijlstra (Intel)" , Andrea Arcangeli , Joonsoo Kim , Arnd Bergmann , Paul Gortmaker , Oleg Nesterov , Linux-MM , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Message-ID: <20151005020406.GB8831@linux-uzut.site> Mail-Followup-To: Leon Romanovsky , Geliang Tang , Andrew Morton , "Kirill A. Shutemov" , Hugh Dickins , "Peter Zijlstra (Intel)" , Andrea Arcangeli , Joonsoo Kim , Arnd Bergmann , Paul Gortmaker , Oleg Nesterov , Linux-MM , "linux-kernel@vger.kernel.org" References: <45bf632d263280847a2a894017c62b7f2a71eda1.1443937856.git.geliangtang@163.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 04 Oct 2015, Leon Romanovsky wrote: >On Sun, Oct 4, 2015 at 9:18 AM, Geliang Tang wrote: >> BUG_ON() already contain an unlikely compiler flag. Drop it. >It is not the case if CONFIG_BUG and HAVE_ARCH_BUG_ON are not set. Yeah, but that's like the 1% of the cases -- and those probably don't even care about the branch prediction (I could be wrong). So overall I like getting rid of explicit BUG_ON(unlikely(... calls. In fact there's a _reason_ why there are so few of them in the kernel. Thanks, Davidlohr