- Changed sampling buffer switching frequency (which is the frequency of tprof_worker()
calls and also the maximum block time of read(2) of /dev/tprof) from 1sec to 125ms.
This improve tprof top responsiveness.
- The maximum number of sampling buffers is now adjusted according to the number of CPUs.
Previously it was fixed at 100 and was insufficient if ncpu was greater than this.
The maximum number of samples per second per CPU is calculated by
"TPROF_MAX_SAMPLES_PER_BUF * (HZ of tprof_worker)".
Therefore, currently, 10000 * (1000/125) = 80000 maximum samplings per CPU.
The actual value will vary slightly from this due to tprof_worker and read(2) timing.
This value may need to be adjusted more in the future.
they do not specify "long" options (ever). The --preserve and --foreground
options in this utility had no short form, so they "invented" -p and -f
so only standard form one char options needed to be specified.
Change the opt processing here so -p == --preserve and -f == --foreground
so we support the options POSIX will specify.
No other changes here, just adding those alternates for the options.
commit 9dda00df7e8f9279a43d92758df6a7e10a9aed95
Author: Chuck Silvers <chs@FreeBSD.org>
Date: Mon Dec 12 08:14:17 2022 -0800
restore: fix restore of NFS4 ACLs
Changing the mode bits on a file with an NFS4 ACL results in the
NFS4 ACL being replaced by one matching the new mode bits being set,
so when restoring a file with an NFS4 ACL, set the owner/group/mode first
and then set the NFS4 ACL, so that setting the mode does not throw away
the ACL that we just set.
Reviewed by: mckusick
Differential Revision: https://reviews.freebsd.org/D37618
Although tzcode still works with C89, bugs found in recent routine
maintenance indicate that bitrot has set in and that in practice
C89 is no longer used to build tzcode. As it is a maintenance
burden, support for C89 is planned to be removed soon. Instead,
please use compilers compatible with C99, C11, C17, or C23.
timegm, which tzcode implemented in 1989, will finally be
standardized 34 years later as part of C23, so timegm is now
supported even if STD_INSPIRED is not defined.
Fix bug in zdump's tzalloc emulation on hosts that lack tm_zone.
(Problem reported by Đoàn Trần Công Danh.)
Fix bug in zic on hosts where malloc(0) yields NULL on success.
(Problem reported by Tim McBrayer for AIX 6.1.)
Fix zic configuration to avoid linkage failures on some platforms.
(Problems reported by Gilmore Davidson and Igor Ivanov.)
Work around MS-Windows nmake incompatibility with POSIX.
(Problem reported by Manuela Friedrich.)
Port mktime and strftime to debugging platforms where accessing
uninitialized data has undefined behavior (strftime problem
reported by Robert Elz).
Check more carefully for unlikely integer overflows, preferring
C23 <stdckdint.h> to overflow checking by hand, as the latter has
had obscure bugs.