From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755055AbdERIMZ (ORCPT ); Thu, 18 May 2017 04:12:25 -0400 Received: from foss.arm.com ([217.140.101.70]:55940 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754696AbdERIMW (ORCPT ); Thu, 18 May 2017 04:12:22 -0400 Date: Thu, 18 May 2017 09:12:13 +0100 From: Juri Lelli To: Byungchul Park Cc: peterz@infradead.org, linux-kernel@vger.kernel.org, kernel-team@lge.com, rostedt@goodmis.org, bristot@redhat.com Subject: Re: [RESEND PATCH v3] sched/deadline: Remove unnecessary condition in push_dl_task() Message-ID: <20170518081213.3phqkffs6cvjurlt@e106622-lin> References: <1494551159-22367-1-git-send-email-byungchul.park@lge.com> <20170518020004.GB28017@X58A-UD3R> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170518020004.GB28017@X58A-UD3R> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 18/05/17 11:00, Byungchul Park wrote: > On Fri, May 12, 2017 at 10:05:59AM +0900, Byungchul Park wrote: > > pick_next_pushable_dl_task(rq) has BUG_ON(rq->cpu != task_cpu(task)) > > when it returns a task other than NULL, which means that task_cpu(task) > > must be rq->cpu. So if task == next_task, then task_cpu(next_task) must > > be rq->cpu as well. Remove the redundant condition and make code simpler. > > > > By this patch, unnecessary one branch and two LOAD operations in 'if' > > statement can be avoided. > > +cc rostedt@goodmis.org > +cc juri.lelli@arm.com > +cc bristot@redhat.com > > > > > Signed-off-by: Byungchul Park > > Reviewed-by: Steven Rostedt (VMware) > > Reviewed-by: Juri Lelli It looked, and still looks, good to me. :) Thanks, - Juri