From owner-cvs-all Fri Jul 27 21:45:32 2001 Delivered-To: cvs-all@freebsd.org Received: from dragon.nuxi.com (trang.nuxi.com [206.40.252.115]) by hub.freebsd.org (Postfix) with ESMTP id 112F137B401; Fri, 27 Jul 2001 21:45:15 -0700 (PDT) (envelope-from obrien@NUXI.com) Received: (from obrien@localhost) by dragon.nuxi.com (8.11.3/8.11.1) id f6S4isX97524; Fri, 27 Jul 2001 21:44:54 -0700 (PDT) (envelope-from obrien) Date: Fri, 27 Jul 2001 21:44:54 -0700 From: "David O'Brien" To: Kris Kennaway Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/usr.sbin/pkg_install/add main.c src/usr.sbin/pkg_install/lib str.c Message-ID: <20010727214454.A96927@dragon.nuxi.com> Reply-To: obrien@FreeBSD.org References: <200107280159.f6S1xw810069@freefall.freebsd.org> <20010727204037.A58795@xor.obsecurity.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010727204037.A58795@xor.obsecurity.org>; from kris@obsecurity.org on Fri, Jul 27, 2001 at 08:40:37PM -0700 X-Operating-System: FreeBSD 5.0-CURRENT Organization: The NUXI BSD group X-Pgp-Rsa-Fingerprint: B7 4D 3E E9 11 39 5F A3 90 76 5D 69 58 D9 98 7A X-Pgp-Rsa-Keyid: 1024/34F9F9D5 Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jul 27, 2001 at 08:40:37PM -0700, Kris Kennaway wrote: > > Modified files: > > usr.sbin/pkg_install/add main.c > > usr.sbin/pkg_install/lib str.c > > Log: > > Remove s_strl*(). I am not sure what was thought they accomplished. > > Grr. Thanks for discussing this with me (the person who added > s_strl*). > > I'm not happy with this commit: I don't like endless > amounts of inline code duplication when a simple function can do the > job. You have a weird definition of "endless amounts of code duplication". With your position, what do you call the errx() after every s_strl* call then? Why didn't you fold that into s_strl*? If s_strl* contained that then maybe you'd have an argument about code duplication. Do you understand how compilers generate code? Have you ever written a compiler? Do you know how optimizers work? Have you ever taken a graduate code optimization course? Do you have any code in a widely used compiler? Done any graduate work on processor architecture? before $ size add/pkg_add text data bss dec hex filename 36331 728 29488 66547 103f3 add/pkg_add (i386) 48380 4448 29080 81908 13ff4 add/pkg_add (alpha) after $ size add/pkg_add text data bss dec hex filename 36295 728 29488 66511 103cf add/pkg_add (i386) 48319 4432 29080 81831 13fa7 add/pkg_add (alpha) > Please back this out until we can come to an agreement. What part of my explanation for the commit do you disagree with? I also showed the code before my commit and after my commit to some coworkers. They agreed my version improved the clarity. -- -- David (obrien@FreeBSD.org) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message