From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mout.web.de ([212.227.15.3]:56578 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751760AbcACMOU (ORCPT ); Sun, 3 Jan 2016 07:14:20 -0500 Subject: Re: net-libertas: Better exception handling in if_spi_host_to_card_worker() To: Arend van Spriel References: <566ABCD9.1060404@users.sourceforge.net> <5686F0B2.5000000@users.sourceforge.net> <56870866.7020000@cogentembedded.com> <568785B3.5000905@users.sourceforge.net> <5687939E.7010701@users.sourceforge.net> <5687A2C7.3000704@gmail.com> <5687B2BC.8090901@users.sourceforge.net> <5688EBAC.5000701@gmail.com> Cc: Julia Lawall , Sergei Shtylyov , libertas-dev@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, Kalle Valo , LKML , kernel-janitors@vger.kernel.org From: SF Markus Elfring Message-ID: <5689105B.50005@users.sourceforge.net> (sfid-20160103_131442_403599_27398F0B) Date: Sun, 3 Jan 2016 13:13:15 +0100 MIME-Version: 1.0 In-Reply-To: <5688EBAC.5000701@gmail.com> Content-Type: text/plain; charset=windows-1252 Sender: linux-wireless-owner@vger.kernel.org List-ID: >>> What the patch tries to do is avoid the extra 'if (err)'. >> >> Yes. - I propose to look at related consequences together with the usage >> of a popular short jump label once more. > > When I read a subject saying "Better exception handling" it sounds like > a functional improvement. Your change does not change anything > functionally and may or may not save a bit of execution time depending > on how smart the compiler is. Can it eventually matter to skip another condition check in three cases? > What you change does is confuse people reading the code. A few software developers might find this proposal unusual. > So please explain why your update improves exception handling here. > I don't see it. How does this feedback fit to the mentioned check avoidance? > The code is not making the driver more robust against failures That's true for this update suggestion. > in this function, which is what I think of reading "better exception handling". Other implementation details are affected by the shown fine-tuning. Regards, Markus From mboxrd@z Thu Jan 1 00:00:00 1970 From: SF Markus Elfring Subject: Re: net-libertas: Better exception handling in if_spi_host_to_card_worker() Date: Sun, 3 Jan 2016 13:13:15 +0100 Message-ID: <5689105B.50005@users.sourceforge.net> References: <566ABCD9.1060404@users.sourceforge.net> <5686F0B2.5000000@users.sourceforge.net> <56870866.7020000@cogentembedded.com> <568785B3.5000905@users.sourceforge.net> <5687939E.7010701@users.sourceforge.net> <5687A2C7.3000704@gmail.com> <5687B2BC.8090901@users.sourceforge.net> <5688EBAC.5000701@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Cc: Julia Lawall , Sergei Shtylyov , libertas-dev-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Kalle Valo , LKML , kernel-janitors-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Arend van Spriel Return-path: In-Reply-To: <5688EBAC.5000701-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> Sender: linux-wireless-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: netdev.vger.kernel.org >>> What the patch tries to do is avoid the extra 'if (err)'. >> >> Yes. - I propose to look at related consequences together with the usage >> of a popular short jump label once more. > > When I read a subject saying "Better exception handling" it sounds like > a functional improvement. Your change does not change anything > functionally and may or may not save a bit of execution time depending > on how smart the compiler is. Can it eventually matter to skip another condition check in three cases? > What you change does is confuse people reading the code. A few software developers might find this proposal unusual. > So please explain why your update improves exception handling here. > I don't see it. How does this feedback fit to the mentioned check avoidance? > The code is not making the driver more robust against failures That's true for this update suggestion. > in this function, which is what I think of reading "better exception handling". Other implementation details are affected by the shown fine-tuning. Regards, Markus -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html From mboxrd@z Thu Jan 1 00:00:00 1970 From: SF Markus Elfring Date: Sun, 03 Jan 2016 12:13:15 +0000 Subject: Re: net-libertas: Better exception handling in if_spi_host_to_card_worker() Message-Id: <5689105B.50005@users.sourceforge.net> List-Id: References: <566ABCD9.1060404@users.sourceforge.net> <5686F0B2.5000000@users.sourceforge.net> <56870866.7020000@cogentembedded.com> <568785B3.5000905@users.sourceforge.net> <5687939E.7010701@users.sourceforge.net> <5687A2C7.3000704@gmail.com> <5687B2BC.8090901@users.sourceforge.net> <5688EBAC.5000701@gmail.com> In-Reply-To: <5688EBAC.5000701@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Arend van Spriel Cc: Julia Lawall , Sergei Shtylyov , libertas-dev@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, Kalle Valo , LKML , kernel-janitors@vger.kernel.org >>> What the patch tries to do is avoid the extra 'if (err)'. >> >> Yes. - I propose to look at related consequences together with the usage >> of a popular short jump label once more. > > When I read a subject saying "Better exception handling" it sounds like > a functional improvement. Your change does not change anything > functionally and may or may not save a bit of execution time depending > on how smart the compiler is. Can it eventually matter to skip another condition check in three cases? > What you change does is confuse people reading the code. A few software developers might find this proposal unusual. > So please explain why your update improves exception handling here. > I don't see it. How does this feedback fit to the mentioned check avoidance? > The code is not making the driver more robust against failures That's true for this update suggestion. > in this function, which is what I think of reading "better exception handling". Other implementation details are affected by the shown fine-tuning. Regards, Markus