From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752510AbcG2P2z (ORCPT ); Fri, 29 Jul 2016 11:28:55 -0400 Received: from mga03.intel.com ([134.134.136.65]:52256 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751329AbcG2P2x convert rfc822-to-8bit (ORCPT ); Fri, 29 Jul 2016 11:28:53 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,440,1464678000"; d="scan'208";a="147573490" Subject: Re: [lustre-devel] staging: lustre: One function call less in class_register_type() after error detection Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset=us-ascii From: Oleg Drokin In-Reply-To: Date: Fri, 29 Jul 2016 11:28:46 -0400 Cc: , Greg Kroah-Hartman , , LKML , Julia Lawall , "Bhumika Goyal" , Content-Transfer-Encoding: 8BIT Message-Id: References: <566ABCD9.1060404@users.sourceforge.net> <566D7733.1030102@users.sourceforge.net> <56784D83.7080108@users.sourceforge.net> <56784F0C.6040007@users.sourceforge.net> <20151221234857.GA27079@kroah.com> <59d94e70-7476-728e-5f63-013557ec2db9@users.sourceforge.net> <0f9ecc7c-f98a-0296-563b-6fcfab459c31@users.sourceforge.net> <2BFF8460-ECEA-470D-ACD6-A9D7E540FE33@intel.com> To: SF Markus Elfring X-Mailer: Apple Mail (2.1283) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Jul 28, 2016, at 1:53 AM, SF Markus Elfring wrote: >> This function is called several times during lustre module insert. >> Namely it's called 5 times for 5 types: >> osc, mdc, lov, lmv, mgc. > > Will any extra memory accesses matter for the successful execution > in this use case? I doubt it. In typical deployments outside of testing environment, this function is called 5 times every system boot and never again. >> It's not called any more than that, so it's not exactly a super hot-path function >> to overoptimize it, and the failure is presumed to never happen too >> (or the module would be non-functional). > > Did the assignment for the local variable "rc" with a well-known error code > influence the run-time characteristics in unwanted ways? > https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/tree/drivers/staging/lustre/lustre/obdclass/genops.c?id=6a5b99a46bedc2cfbba96dec6d255c4b90af9ff8#n140 I am not sure what do you mean here.