Commit Graph

938 Commits

Author SHA1 Message Date
scw 3617381164 Sign-extend the return value, as required by the ABI. 2003-03-26 11:59:36 +00:00
scw 825e47398e Much rototilling to add PIC support. 2003-03-24 14:29:34 +00:00
hannken 94a50cb223 Make it work on cpus with cachelinesize < 32.
Tested on macppc by Markus W Kilbinger.
2003-03-15 14:10:21 +00:00
fvdl e4189529ce No need to use movq for the small immediate values here, they'll be
zero-extended with movl.
2003-03-15 12:34:33 +00:00
nathanw 4fb740b8de Implement pthread_atfork() (in libc, because the required threadlib
stub behavior is exactly the same as the usual behavior).
2003-02-13 02:50:48 +00:00
simonb e32d091ca8 Fix a tyop in a comment. 2003-02-08 04:01:53 +00:00
cgd 57daa57e46 * fix handling of invalid arguments (was jumping to wrong label!)
(found by... running the regress test!)
* clean up punctuation.
* create a proper frame for the child fn that follows the o32 calling
  conventions.  In particular, leave 4 stack slots that the child
  fn can write on, put the GP above them, and invoke .cprestore
  properly in light of the child fn arg area.  (realized it was a
  problem upon inspection, verified using the regress test compiled
  -O0.)
2003-02-08 00:28:25 +00:00
cgd 351f7a02f1 looks like nobody ever seriously tried the _REENTRANT version of this
code (which, uh, seems the default for a fresh build)...  it wasn't
setting up v1 properly (the instruction to set up v1 was after the
return jump, in "reorder" code...  i.e.  after the end of the function).
That would break error returns from 64-bit syscalls (e.g. checks
in dd and who knows what else) to see if input or output are pipes.
It looks like the non-_REENTRANT version was broken (on the nathanw-sa
branch) in rev 1.9.2.1 and fixed in 1.9.2.2, but the _REENTRANT version
was never fixed, and the broken bits were merged back on to the trunk.
2003-02-07 20:35:05 +00:00
petrov 12784e54c3 Correct unsigned to float conversions, add license, adjust style. 2003-02-06 20:23:35 +00:00
martin 912ab5ad59 Check how the compiler expects the return value of this function
by testing SOFTFLOATSPARC64_FOR_GCC.

Should fix PR port-sparc64/20140.
2003-02-01 09:19:58 +00:00
fvdl 894bd3ad9d Add ucontext glue for x86_64. 2003-01-30 02:07:30 +00:00
kleink 326194c69f Update stack frame allocation for XMM state having been added to
mcontext_t; spotted by Frank van der Linden.
While here, also align the on-stack ucontext as required.
2003-01-26 18:14:03 +00:00
kleink 9b24979426 Fix comment typo, and convert to C-style comments. 2003-01-26 17:58:55 +00:00
fvdl 75b44dbf11 Fix comment that wasn't closed because of a typo (but harmless, since followed
by another comment).
2003-01-26 16:22:01 +00:00
fvdl 3a79855417 Fix wrong %esp fixup. 2003-01-26 15:54:35 +00:00
matt 61687fc220 Add the *context.? sources to SRCS.
Make getcontext _getcontext and add a getcontext weak alias.
2003-01-23 23:56:13 +00:00
scw aa338c0862 Now make these actually work. 2003-01-22 13:44:36 +00:00
kleink 8b314175ec Add ns32k ucontext userland portions. Untested, but compiled in the
recent past and presumed working.
2003-01-21 21:03:25 +00:00
kleink 7a9f64971b Add swapcontext() lint stub. 2003-01-21 20:26:10 +00:00
kleink cd9f53e12c Add swapcontext() lint stub. 2003-01-21 20:14:07 +00:00
scw fd2dcace1f Make these compile. 2003-01-21 11:29:29 +00:00
scw 11e9fa3a9b Initialise the FPSCR to a sane value. 2003-01-20 20:09:59 +00:00
thorpej c7e237f26a Merge the nathanw_sa branch. 2003-01-20 00:26:39 +00:00
matt 21375ddf92 Make sure r0 in the saved context is 0. 2003-01-20 00:24:07 +00:00
matt 94face2f9c Use _ALIGN_TEXT.
Make sure R0 is 0 in the saved context.
2003-01-20 00:18:06 +00:00
kleink 13a5336c66 Move getcontext.S from gen to sys, where it belongs. 2003-01-19 23:49:12 +00:00
scw bcbbc4f87e SH5 libc ucontext/lwp support.
Untested for now, until I get the libpthread stuff done and
an SA userland built.
2003-01-19 23:05:01 +00:00
matt 95b5cce5c6 Add getcontext(2) stub. 2003-01-19 19:32:39 +00:00
matt 8c295614ea Add the VAX versions of these. 2003-01-19 19:07:30 +00:00
matt bdde89628b Cast with uintptr_t instead of u_long. 2003-01-19 08:53:36 +00:00
thorpej c7cb871964 These files are obsolete; setlogin() is now implemented in C with a
small syscall stub.
2003-01-18 18:28:44 +00:00
thorpej 3fdac2b8c5 Merge the nathanw_sa branch. 2003-01-18 10:52:16 +00:00
fvdl 50683c0ce9 The fast syscall path clobbers 2 registers. Which is fine for a plain
system call, as long as the stub knows about it. However, it's bad
for sigreturn. Hence, use the old entry point for sigreturn. XXX
2002-12-13 17:43:02 +00:00
scw 94932a0f44 SH5 asm versions of some low-level libc routines.
Most of these copied from libkern.
2002-12-08 09:48:36 +00:00
thorpej 06edae0ff4 Need <stdlib.h> for abort() prototype. 2002-11-26 21:14:04 +00:00
chris 0caaced5a9 Add arm asm version of memcmp, basically it's strncmp.S without the
check for *src != 0
2002-11-23 14:26:04 +00:00
chris 35c74e8cc5 Add an asm version of strncmp, based on strcmp.
Add RCSID to strcmp, also use numeric label, rather than named label for
loop.
2002-11-23 03:10:27 +00:00
itohy 6cde54195b Assembly version of string functions.
Originally from SHIMIZU Ryo.
2002-11-20 14:23:54 +00:00
rearnsha 6576c49b48 Add an assembler version of strcmp, based on example code from the ARM
ARM.  As an example of the performance difference that this provides
a Dhrystone score on my Shark goes from 213k to 261k.
2002-11-16 18:27:40 +00:00
thorpej 7f74df5ef3 ABICALLS -> __ABICALLS__ 2002-11-10 18:10:25 +00:00
thorpej 6596b29802 t4 -> ta0 2002-11-05 00:05:15 +00:00
junyoung 4c3981eea3 Save a jmp for memcpy(3). 2002-10-29 07:01:44 +00:00
junyoung 333f362341 memcpy(3) no longer deals with overlap case; it's now forward-only. 2002-10-29 06:53:18 +00:00
junyoung 7f21deb763 Get rid of pointer wraparound check. Ok'ed by TAMURA Kent. 2002-10-29 06:35:17 +00:00
chs cab484e445 move includes to the top so that this builds in libc context too. 2002-10-29 04:40:55 +00:00
petrov ade04d7707 Compile with an ISO C preprocessor. 2002-10-29 00:22:18 +00:00
chs c04f87a03e remove setjmp/longjmp from libkern, they're not used. 2002-10-27 18:45:11 +00:00
chs c5a350ef59 use %g5 instead of %g7 (since we want to use %g7 for the cpu_info pointer
in the kernel).  resync libc and libkern versions of this file.
2002-10-27 18:41:27 +00:00
thorpej a8151a52ca Split isnan() into its own file. 2002-10-26 06:51:32 +00:00
thorpej bc4821e36e * Use the common ieee754_* routines (and add ones we were missing).
* Note that several routines are still missing for hppa.
2002-10-26 06:44:54 +00:00