From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S937281AbdCJNHK (ORCPT ); Fri, 10 Mar 2017 08:07:10 -0500 Received: from gate.crashing.org ([63.228.1.57]:43237 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934284AbdCJNHI (ORCPT ); Fri, 10 Mar 2017 08:07:08 -0500 Date: Fri, 10 Mar 2017 07:02:22 -0600 From: Segher Boessenkool To: Michael Ellerman Cc: Christophe Leroy , Benjamin Herrenschmidt , Paul Mackerras , Scott Wood , linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] powerpc: sysdev: cpm1: Optimise gpio bit calculation Message-ID: <20170310130222.GG31469@gate.crashing.org> References: <20170309094206.A832167992@localhost.localdomain> <87a88tle0y.fsf@concordia.ellerman.id.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87a88tle0y.fsf@concordia.ellerman.id.au> User-Agent: Mutt/1.4.2.3i Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 10, 2017 at 07:41:33PM +1100, Michael Ellerman wrote: > Well yeah, it saves one instruction, but is it worth it? Are these gpio > routines in some hot path I don't know about? If there was a GCC PR for this we probably would make GCC optimise this; there are many similar things that are optimised already, just not this one. Segher