Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932525AbVLPWFZ (ORCPT ); Fri, 16 Dec 2005 17:05:25 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932537AbVLPWFZ (ORCPT ); Fri, 16 Dec 2005 17:05:25 -0500 Received: from linux01.gwdg.de ([134.76.13.21]:41688 "EHLO linux01.gwdg.de") by vger.kernel.org with ESMTP id S932525AbVLPWFZ (ORCPT ); Fri, 16 Dec 2005 17:05:25 -0500 Date: Fri, 16 Dec 2005 23:05:08 +0100 (MET) From: Jan Engelhardt To: Andy Isaacson cc: Jesper Juhl , Linux Kernel Mailing List , David Woodhouse , jffs-dev@axis.com, Andrew Morton Subject: Re: [PATCH] Reduce nr of ptr derefs in fs/jffs2/summary.c In-Reply-To: <20051216033435.GA21600@hexapodia.org> Message-ID: References: <20051216033435.GA21600@hexapodia.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 721 Lines: 22 >> >Benefits: >> > - micro speed optimization due to fewer pointer derefs >> > - generated code is slightly smaller >> >> Should not these two at best be done by the compiler? > >[...] >But a human *can* make the obvious leap and tell the compiler that the >value can be computed once and then saved. And besides, isn't the code >just *much* nicer to look at, above? The third point Jesper mentioned was about readability, but I never questioned that. Jan Engelhardt -- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/