Until we can figure out how to reimpliment our custom format warnings
since the FSF developers totally revamped them, and took away the hooks
we were using to accomplish our desires.
threads race for a file slot.
dup2(2) incorrectly assumes that if it needs to grow the ofiles
array that it will get what it wants. This assertion was valid
before we allowed shared filedescriptor tables but is now incorrect.
The assertion can trigger superfolous panics if the thread doing a
dup2 looses a race with another thread while possibly blocked in
the MALLOC call in fdalloc. Another thread may grab the slot we
are requesting which makes fdalloc return something other than what
we asked for, this will triggering the bogus assertion.
MFC after: 2 weeks
Reviewed by: phk
Note that the "NO_PROFILE_DATA"/"NO_PROFILE_COUNTERS" bits were added
to the stock FSF GCC 2.97 (and thus 3.1) source as i386 Linux needed them
also. (amazing what can get committed to the FSF GCC when needed by Linux...)
signal trampoline for old signals. The arches that support old signals
currently abuse sigreturn(2) instead. This mainly complicates things
and slightly breaks the the new sigreturn(2).
COMPAT is too limited to support the correct configuration of osigreturn,
and this commit doesn't attempt to fix it; it just moves the bogusness:
osigreturn() must now be provided unconditionally even on arches that
don't really need it; previously it had to be provided under the bogus
condition defined(COMPAT_43).
some arches and the syscall table is machine-independent. It was
(bogusly) conditional on COMPAT_43, so this usually makes no difference.
ia64: in addition:
- replace the bogus cloned comment before osigreturn() by a correct one.
osigreturn() is just a stub fo ia64's.
- fix the formatting of cloned comment before sigreturn().
- fix the return code. use nosys() instead of returning ENOSYS to get
the same semantics as if the syscall is not in the syscall table.
Generating SIGSYS is actually correct here.
- fix style bugs.
powerpc: copy the cleaned up ia64 stub. This mainly fixes a bogus comment.
sparc64: copy the cleaned up the ia64 stub, since there was no stub before.
'struct ng_ksocket_sockopt') like to peek into the ng_mesg header for
information. Make sure when generating default values that we provide
a valid header to peek into.
MFC after: 1 week
Remove our definition for FUNCTION_PROFILER as it is wrong.
Note that "jsr $28,_mcount" is a macro for
ldq $27, _mcount($29) !literal!1
jsr $28, ($27), _mcount !lituse_jsr!1
1. The call to _mcount is added by alpha_expand_prologue after we load the gp.
Our _mcount uses $27 for the incoming address, unlike OSF/1 and Linux,
which use $28. This probably doesn't matter since we probably don't use $27
within _mcount itself.
2. You can't use this insn with _mcount because it uses the PLT, which clobbers
the return address in $28. Note that the prologue_mcount pattern carefully
avoids adding the lituse_jsr relocation so that we call through the GOT
directly.
Submitted by: Richard Henderson <rth@redhat.com>
for SMP in the plain profiling case. It seems to work too.
This error was not detected by LINT because LINT only compiles the
GUPROF profiling case, which is is a superset of the plain profiling
case for !SMP but which is so broken for SMP that the buggy code is
not compiled.