Commit Graph

4810 Commits

Author SHA1 Message Date
wiz
3ec0478ba0 Whitespace, mdoc, and grammar nits. Fix an Xr. 2002-08-29 12:43:28 +00:00
itohy
fa5465079f Slightly improved version of ffs(3).
Partially from SHIMIZU Ryo <ryo@iij.ad.jp>.  Thanks.
Some cases are slower, but other most cases are faster.

Here's a benchmark on SH-4 200MHz.

return value	C version	previous vers	this version	speed ratio
of ffs()	(ns/call) *1	(ns/call)	(ns/call) *2	(*1/*2)
------------	------------	-------------	------------	-----------
 0		  86		 86		 81		1.06
 1		 110		 86		106 *(slower)	1.04
 2		 132		 86		106 *		1.25
 3		 165		105		117 *		1.41
 4		 201		104		116 *		1.73
 5		 237		111		107		2.21
 6		 271		111		106		2.56
 7		 307		126		116		2.65
 8		 342		125		116		2.95
 9		 376		122		126 *		2.98
10		 410		121		127 *		3.23
11		 446		139		136		3.28
12		 483		140		134		3.60
13		 518		146		125		4.14
14		 551		146		126		4.37
15		 587		161		135		4.35
16		 624		162		136		4.59
17		 658		141		139		4.73
18		 694		142		140		4.96
19		 727		160		148		4.91
20		 764		161		150		5.09
21		 799		167		141		5.67
22		 834		167		142		5.87
23		 868		181		152		5.71
24		 903		181		153		5.90
25		 939		146		140		6.71
26		 974		146		141		6.91
27		1009		166		152		6.64
28		1044		165		148		7.05
29		1080		171		141		7.66
30		1115		171		141		7.91
31		1151		185		151		7.62
32		1185		186		151		7.85
2002-08-28 15:34:35 +00:00
gmcgarry
7fd895f806 Bump minor: rasctl(2) 2002-08-28 09:33:36 +00:00
gmcgarry
c4efdd0999 rasctl(2) 2002-08-28 09:31:26 +00:00
onoe
a5fc25f65e Limit UDP payload size for EDNS0 to 0xffff, not use lower 16bit value. 2002-08-28 02:37:09 +00:00
itojun
006281a1e2 kill register decl 2002-08-27 23:47:07 +00:00
mycroft
bbaefa57eb Do the appropriate PIC magic for the jump to _exit(). 2002-08-27 21:38:20 +00:00
itojun
62f36ff8e2 allocate 64K recieve buffer for DNS responses. 2002-08-27 08:50:49 +00:00
itohy
6736303e13 Use assembly version of ffs(3). 2002-08-24 06:39:48 +00:00
itohy
85ce1de27f Oops, SYSLIBC_SCCS -> LIBC_SCCS 2002-08-24 06:37:24 +00:00
itohy
70b5675025 Assembly version of ffs(3).
Confirmed to return the same value as that of the C version.

The results of a simple benchmark on SH-4 200MHz, is shown below.
I think this shows acceptable performance.

return value	C version	this version	speed
of ffs()	(ns/call)	(ns/call)	ratio
------------	---------	------------	-----
 0		  86		 86		1.00
 1		 110		 86		1.27
 2		 132		 86		1.53
 3		 165		105		1.57
 4		 201		104		1.93
 5		 237		111		2.13
 6		 271		111		2.44
 7		 307		126		2.43
 8		 342		125		2.73
 9		 376		122		3.08
10		 410		121		3.38
11		 446		139		3.20
12		 483		140		3.45
13		 518		146		3.54
14		 551		146		3.77
15		 587		161		3.64
16		 624		162		3.85
17		 658		141		4.66
18		 694		142		4.88
19		 727		160		4.54
20		 764		161		4.74
21		 799		167		4.78
22		 834		167		4.99
23		 868		181		4.79
24		 903		181		4.98
25		 939		146		6.43
26		 974		146		6.67
27		1009		166		6.07
28		1044		165		6.32
29		1080		171		6.31
30		1115		171		6.52
31		1151		185		6.22
32		1185		186		6.37
2002-08-24 06:30:34 +00:00
itojun
36e473ebb2 off-by-one. PR 18049
correct snprintf() return value handling in another place.
2002-08-23 16:10:42 +00:00
abs
a086fb2909 Move humanize_number(3) from libutil to libc as per discussion on tech-misc
Revert minor number bump on libutil (with note to skip it next update), and
bump libc.
2002-08-22 17:24:08 +00:00
itojun
949583590f drop AAAA reply with IPv4 mapped address. sync w/kame
draft-itojun-v6ops-v4mapped-harmful-00.txt
2002-08-22 16:32:14 +00:00
wiz
f11f240ebb -1 -> \-1. 2002-08-20 16:42:35 +00:00
wiz
777c402952 Refer setpgid, not setpgrp, since the former is POSIX and the latter is
just there for compatibility.
2002-08-20 16:30:30 +00:00
wiz
38315eadd0 Use Dq instead of single quotes. 2002-08-20 16:22:44 +00:00
wiz
60bfa780a0 Mark up NULL and ENOMEM. 2002-08-20 16:15:38 +00:00
wiz
3f9c36b9de Drop superfluous Ns and fix a formatting glitch. 2002-08-20 16:10:01 +00:00
wiz
158398c921 Fix Ns abuse. 2002-08-20 15:32:12 +00:00
wiz
64f4287d6d Remove superfluous double quotes and a superfluous Ns. 2002-08-20 15:30:07 +00:00
lukem
ec5dbc56b8 Explicitly move setting of NOxxx and USE_SHLIBDIR to the top of the
Makefile (before including <bsd.own.mk>)
2002-08-19 14:55:14 +00:00
lukem
91d06a031b More use of ${NETBSDSRCDIR}/some/path instead of ${.CURDIR}/../../some/path 2002-08-19 13:35:05 +00:00
lukem
ebb6fc9eb8 Use ${NETBSDSRCDIR}/some/path instead of ${.CURDIR}/../../some/path (etc).
(Reduces make output by ~ 20%)
2002-08-19 09:41:27 +00:00
yamt
83b485596b note that month and weekday names are case-insensitive.
from OpenBSD.
2002-08-18 06:43:32 +00:00
yamt
7c3f1b1f60 note that the contents of the array are undefined in the error case. 2002-08-18 06:31:09 +00:00
yamt
e72273def3 - Mention leap seconds as the reason for (00-61)
- include blurb about ISO 8601 dates straight from strftime.c
from OpenBSD.
2002-08-18 06:27:49 +00:00
yamt
9c03214612 - write updates st_[cm]time.
- a minor fix
from openbsd.
2002-08-18 05:55:24 +00:00
yamt
8b91a33de9 add a portablility note. from openbsd. 2002-08-18 05:34:34 +00:00
thorpej
1b907e1877 Local label fixup. 2002-08-17 19:54:30 +00:00
yamt
b3b13795b1 bring in a note about portability from openbsd. 2002-08-17 18:41:36 +00:00
yamt
b77d0176be bring in HISTORY from openbsd. 2002-08-17 18:38:46 +00:00
yamt
514d4ffd02 note that setgid doesn't change supplementary groupids.
from openbsd.
2002-08-17 18:22:21 +00:00
yamt
572225a82f document RB_POWERDOWN.
from OpenBSD.
2002-08-17 17:52:54 +00:00
yamt
dbb4e0d985 - move return values info into RETURN VALUES section.
- note that O_SHLOCK and O_EXLOCK are not portable.
from OpenBSD.
2002-08-17 17:25:37 +00:00
chris
725f3ca1a7 correct comment, it's r0, not a0. 2002-08-17 01:23:36 +00:00
itojun
4005a5250f set h_errno properly if internal string manipulation fails. 2002-08-16 21:54:00 +00:00
itojun
44ca8f4da1 use sizeof, avoid duplicated use of MAXDNAME 2002-08-16 13:59:39 +00:00
itojun
1173373b45 be more picky about size arg 2002-08-16 12:23:20 +00:00
itojun
1e1a07972c lint clean 2002-08-16 12:20:19 +00:00
itojun
bb80ac654a avoid sprintf. use snprintf with picky error traps. 2002-08-16 12:18:06 +00:00
itojun
0de70db9cd check for pointer overwrap 2002-08-16 12:10:37 +00:00
itojun
b51bffa186 correct cases with zero in the middle
(0x00ff00ff should be "0.255.0.255", not "255.255")
2002-08-16 12:05:01 +00:00
itojun
0b6566bcda avoid sprintf. use snprintf. simplify cases where 1st arg is 0. 2002-08-16 12:03:41 +00:00
itojun
c6a3499c08 use snprintf. don't duplicate MAXDNAME (use sizeof). 2002-08-16 11:53:19 +00:00
itojun
90a8853f46 use strlcat 2002-08-16 11:49:57 +00:00
itojun
f425242dc9 fix weird indent for comment lines 2002-08-16 11:48:25 +00:00
itojun
c5a4255163 eliminate sprintf. use snprintf.
XXX loc_ntoa should be changed to take additional size_t as arg
2002-08-16 11:45:55 +00:00
itojun
5c323232e7 eliminate sprintf, use snprintf. check strlcat error. 2002-08-16 11:30:28 +00:00
itojun
3452fa16c4 be more picky about string buffer manipulation. hints from freebsd 2002-08-16 07:39:44 +00:00