FreeBSD src
Go to file
David E. O'Brien 2bae1ab6a5 Remove s_strl*(). I am not sure what was thought they accomplished.
When reading the code I had to stop, say "ok, what does *these*
modifications of strl*() do?  Pull out grep.  Oh, not in add/, maybe above
in ../lib/?  Yep.  So what do they do?  Comments above them are misleading,
guess I'll have to read the code.  Oh, they just test strl* against the
size and return the result of the test.  Now I can continue to read the
code I was.

The uses of s_strl*() then test that result and errx()'s.
Lets think about the "optimized" code I am removing:

In general the compiler pushes the three args to strl* onto the stack and calls
s_strl*.  s_strl* has to indirectly access 3 args from the stack.  Then push
them on the stack a 2nd time for the real strl* call.  s_strl* then pops the
return from strl* off the stack; or moves it from the register it was returned
in, to the register where tests can happen.  s_strl* then pops the three
arguments to strl*.  Perform the test, push the result of the test, or move it
from the result register to the return value register.  The caller to s_strl*
now has to either pop the return value of s_strl* or move it from the return
value register to the test register.  The caller then pops the three args to
s_strl* off the stack (the same args that s_strl* itself had to pop off after
the real call to strl*).  The s_strl* caller then performs a simular test to
what has already been done, and conditionally jumps.  By doing things this way, we've given the compiler optimizer less to work with.

Also, please don't forget the that call to s_strl* has possibly jumped to code
not in the cache due to being far away from the calling code, thus causing a
pipeline stall.

So where is the "optimization" from s_strl*?
It isn't code clarity.
It isn't code execution speed.  It isn't code size either.
2001-07-28 01:59:58 +00:00
bin Use STD{ERR,IN,OUT}_FILENO instead of their numeric values. The 2001-07-26 11:02:39 +00:00
contrib This commit was generated by cvs2svn to compensate for changes in r80260, 2001-07-24 09:05:00 +00:00
crypto output_data(), output_datalen() and netflush() didn't actually guarantee 2001-07-23 21:52:26 +00:00
etc Take -Wconversion out of BDECFLAGS. It is not particularly useful for 2001-07-27 16:23:53 +00:00
games Remove whitespace at EOL. 2001-07-15 07:53:42 +00:00
gnu Properly update cursor position when the list is scrolled. 2001-07-26 05:35:19 +00:00
include Remove namespace pollution. 2001-07-22 18:10:08 +00:00
kerberos5 add dependency for lex.o on roken.h (from "Alexander N. Kabaev" 2001-07-12 08:36:01 +00:00
kerberosIV generate ksrvtgt 2001-06-16 06:51:35 +00:00
lib Add cross-references for the new kldsym(2) man page. 2001-07-27 03:03:36 +00:00
libexec Use STD{ERR,IN,OUT}_FILENO instead of their numeric values. The 2001-07-26 11:02:39 +00:00
release Move route(8) entries out of Contributed Software section; they were 2001-07-27 17:20:33 +00:00
sbin ifconfig if0 netmask xxx.xxx.xxx.0 didn't change the netmask. 2001-07-26 16:44:19 +00:00
secure Added missing DPADD and CLEANFILES. 2001-07-12 09:17:51 +00:00
share Take -Wconversion out of BDECFLAGS. It is not particularly useful for 2001-07-27 16:23:53 +00:00
sys Pacify users who get all bent out of shape when they see the "xl%d: command 2001-07-27 20:55:45 +00:00
tools ISO_ -> ISO 2001-06-11 01:29:40 +00:00
usr.bin Prevent chpass(1) from writing -1 in the UID or GID fields 2001-07-26 23:27:10 +00:00
usr.sbin Remove s_strl*(). I am not sure what was thought they accomplished. 2001-07-28 01:59:58 +00:00
COPYRIGHT Update to add the July 22, 1999 addendum. 1999-09-05 21:33:47 +00:00
Makefile Make it possible to build manpages for the entire source tree. 2001-03-27 08:43:28 +00:00
Makefile.inc1 Axe S/Key. OPIE is the true and faithful successor. 2001-07-09 17:49:34 +00:00
Makefile.upgrade $Id$ -> $FreeBSD$ 1999-08-28 01:35:59 +00:00
README Slightly improve the description of "crypto". "DES" is a subset of 2000-08-31 17:59:01 +00:00
UPDATING Add, belated, entry for ed driver needing mii 2001-07-25 22:53:11 +00:00

This is the top level of the FreeBSD source directory.  This file
was last revised on:
$FreeBSD$

For copyright information, please see the file COPYRIGHT in this
directory (additional copyright information also exists for some
sources in this tree - please see the specific source directories for
more information).

The Makefile in this directory supports a number of targets for
building components (or all) of the FreeBSD source tree, the most
commonly used one being ``world'', which rebuilds and installs
everything in the FreeBSD system from the source tree except the
kernel, the kernel-modules and the contents of /etc.  The
``buildkernel'' and ``installkernel'' targets build and install
the kernel and the modules (see below).  Please see the top of
the Makefile in this directory for more information on the
standard build targets and compile-time flags.

Building a kernel is a somewhat more involved process, documentation
for which can be found at:
   http://www.freebsd.org/handbook/kernelconfig.html
And in the config(8) man page.
Note: If you want to build and install the kernel with the
``buildkernel'' and ``installkernel'' targets, you have to build
world before.  More information is available in the handbook.

The sample kernel configuration files reside in the sys/i386/conf
sub-directory (assuming that you've installed the kernel sources), the
file named GENERIC being the one used to build your initial installation
kernel.  The file NOTES contains entries and documentation for all possible
devices, not just those commonly used.  It is the successor of the ancient
LINT file, but in contrast to LINT, it is not buildable as a kernel but a
pure reference and documentation file.


Source Roadmap:
---------------
bin		System/User commands.

contrib		Packages contributed by 3rd parties.

crypto		Cryptography stuff (see crypto/README).

etc		Template files for /etc

games		Amusements.

gnu		Various commands and libraries under the GNU Public License.
		Please see gnu/COPYING* for more information.

include		System include files.

kerberosIV	Kerberos package.

lib		System libraries.

libexec		System daemons.

release		Release building Makefile & associated tools.

sbin		System commands.

secure		Cryptographic libraries and commands.

share		Shared resources.

sys		Kernel sources.

tools		Utilities for regression testing and miscellaneous tasks.

usr.bin		User commands.

usr.sbin	System administration commands.


For information on synchronizing your source tree with one or more of
the FreeBSD Project's development branches, please see:

  http://www.freebsd.org/handbook/synching.html