NetBSD/bin
mrg fcc023545e - add new RLIMIT_AS (aka RLIMIT_VMEM) resource that limits the total
address space available to processes.  this limit exists in most other
modern unix variants, and like most of them, our defaults are unlimited.
remove the old mmap / rlimit.datasize hack.

- adds the VMCMD_STACK flag to all the stack-creation vmcmd callers.
it is currently unused, but was added a few years ago.

- add a pair of new process size values to kinfo_proc2{}. one is the
total size of the process memory map, and the other is the total size
adjusted for unused stack space (since most processes have a lot of
this...)

- patch sh, and csh to notice RLIMIT_AS.  (in some cases, the alias
RLIMIT_VMEM was already present and used if availble.)

- patch ps, top and systat to notice the new k_vm_vsize member of
kinfo_proc2{}.

- update irix, svr4, svr4_32, linux and osf1 emulations to support
this information.  (freebsd could be done, but that it's best left
as part of the full-update of compat/freebsd.)


this addresses PR 7897.  it also gives correct memory usage values,
which have never been entirely correct (since mmap), and have been
very incorrect since jemalloc() was enabled.

tested on i386 and sparc64, build tested on several other platforms.

thanks to many folks for feedback and testing but most espcially
chuq and yamt for critical suggestions that lead to this patch not
having a special ugliness i wasn't happy with anyway :-)
2009-03-29 01:02:48 +00:00
..
cat Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
chio Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
chmod Remove physical markup. 2009-03-24 00:10:58 +00:00
cp Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
csh - add new RLIMIT_AS (aka RLIMIT_VMEM) resource that limits the total 2009-03-29 01:02:48 +00:00
date Show that "seconds" is the expected argument for -r. 2009-01-30 13:16:16 +00:00
dd Don't workaround macro argument limit in ancient troff. 2009-03-11 12:43:58 +00:00
df Default to WARNS=4 (except for rcp & ksh) 2009-02-14 08:31:13 +00:00
domainname Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
echo Check ferror(stdout) and exit(1) if there's been a problem. 2008-09-18 05:42:08 +00:00
ed Avoid .Xo/.Xc. Fix quoting of commands to give the intended effect. 2009-03-26 21:34:11 +00:00
expr Revert for now, pending discussion of how expr should behave in the case 2009-01-20 14:22:37 +00:00
hostname Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
kill Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
ksh Default to WARNS=4 (except for rcp & ksh) 2009-02-14 08:31:13 +00:00
ln Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
ls fix -Wsign-compare issues 2009-02-14 08:02:04 +00:00
mkdir Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
mt Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
mv Remove redundant tabs 2009-03-11 12:44:19 +00:00
pax fix -Wsign-compare issues 2009-02-14 08:02:04 +00:00
ps - add new RLIMIT_AS (aka RLIMIT_VMEM) resource that limits the total 2009-03-29 01:02:48 +00:00
pwd Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
rcmd convert the rest of my licenses to 2-clause, extracting myself out 2008-05-30 02:29:37 +00:00
rcp Default to WARNS=4 (except for rcp & ksh) 2009-02-14 08:31:13 +00:00
rm fix -Wsign-compare issues 2009-02-14 08:02:04 +00:00
rmdir Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
sh - add new RLIMIT_AS (aka RLIMIT_VMEM) resource that limits the total 2009-03-29 01:02:48 +00:00
sleep Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
stty Fix markup. 2009-03-15 12:01:24 +00:00
sync Remove the \n and tabs from the __COPYRIGHT() strings. 2008-07-20 00:52:39 +00:00
test bin/39446: Aleksey Cheusov: always produce errors on empty numbers. 2008-09-10 19:00:51 +00:00
Makefile Remove systrace. Ok core@. 2007-12-31 15:31:24 +00:00
Makefile.inc Default to WARNS=4 (except for rcp & ksh) 2009-02-14 08:31:13 +00:00