summaryrefslogtreecommitdiff
path: root/lib/libc/arch
AgeCommit message (Collapse)Author
2014-04-18It's been a quarter century: we can assume volatile is present with that name.Philip Guenther
2006-10-10Preliminary userland bits for OpenBSD/landisk, many things coming fromMiod Vallat
NetBSD.
2014-04-17It's been a quarter century: we can assume volatile is present with that name.Philip Guenther
2014-03-18Retire hp300, mvme68k and mvme88k ports. These ports have no users, keepingMiod Vallat
this hardware alive is becoming increasingly difficult, and I should heed the message sent by the three disks which have died on me over the last few days. Noone sane will mourn these ports anyway. So long, and thanks for the fish.
2014-01-10match what hppa is doing now (not tested, but should be right)Theo de Raadt
ok miod jsing
2014-01-10correct argument handling; this has been broken since to beginningTheo de Raadt
and was writing to wrong memory. ok jsing miod guenther
2013-12-31Remove #ifdef _REENTRANT code that isn't used here. These days, the codeMark Kettenis
handling per-thread errno lives in librthread. ok miod@, espie@
2013-12-24yup, we do ELFTheo de Raadt
2013-11-261 << 31 cleanup. Eitan Adler pointed out that there has been aTheo de Raadt
resurrection of the bad idiom in the tree. sufficient review by miod, kettenis, tedu
2013-11-13bring in math.h to provide prototypesTheo de Raadt
2013-11-12add proto for amd64 case; unify otherwiseTheo de Raadt
2013-09-08Remove the `let's zero %r2 if %r3 is nonzero' dance. It's been more than 10Miod Vallat
years that fork() returns through child_return(), which takes care of zeroing %r2.
2013-07-05VAX ELF userland bits. Consists mostly of register prefix additions.Miod Vallat
2013-06-11bcopy (and family) can check for 0 length, but negative lengths shouldTheo de Raadt
proceed through to crash and show the bug. ok miod
2013-06-05On second thought, do not use a tcnd instruction to test for divide-by-zero,Miod Vallat
as it forces a pipeline synchronization; replace it with a bcnd + unconditional trap, to only synchronize when the trap is needed.
2013-06-05...also add __modsi3 and __umodsi3, and make these symbols weak by default.Miod Vallat
2013-06-05Add __divsi3 and __udivsi3 gcc-compatible routines. Not used by anything yetMiod Vallat
(as gcc does not emit code calling them), but will be shortly; belatedly riding the libc minor bump.
2013-04-23Do a PC-relative relocation for _map rather than going throughMartynas Venckus
GOTPCREL. Uncovered after the binutils patch where it isn't optimized away at assembly and is forced to go through GOTPCREL. But _map is effectively a local variable. Found with cephes by guenther@. OK guenther@, kettenis@, deraadt@.
2013-04-11Fix obviously stupid bug in the PIC_{LOAD,STORE} macros when compiling withMiod Vallat
-fPIC. Harmless since we build libc -fpic so far.
2013-03-28Switch libc and libm to use strong aliases rather than weak aliasesMartynas Venckus
where appropriate. Among other things makes the symbols consistent across all architectures (notably where ldbl mantissa is 53 bits). While at it, kill unused LINTLIBRARY/PROTOLIB1 cruft which was there to trick lint into recording the right prototypes for aliased functions. Most of the work done at the awesome n2k13 hackathon. Agreed by kettenis@, guenther@, matthew@.
2013-02-02Userland bits for m68k/ELF. Mostly addition of register prefixes to theMiod Vallat
assembler instructions, and cope with the few changes in return values location.
2013-01-24Oops, due to the way return from system calls work, we can not use a delayMiod Vallat
slot in the branch to cerror, for the delay slot instruction would also run as part of a successful return. Doh. Fortunately almost nothing in the tree uses brk() or sbrk() anymore... but binaries linked against libiberty.
2013-01-23The kernel sources mention that the system call entry point is trap #450; theMiod Vallat
fact that #128 and #129 may also be used for this purpose was never documented, so there is no reason to have libc use #128. Switch to #450 for consistency.
2013-01-20Fix PIC_LOAD and PIC_STORE macros to really access the variable, instead ofMiod Vallat
the GOT pointer. Oops.
2013-01-20PIC-related code should follow the #ifdef __PIC__ line, not the #else line.Miod Vallat
Doh!
2013-01-13Remove machine-dependent glue for strtorQ, since hppa64 quad-precisionMartynas Venckus
support has been removed from our compiler a year ago.
2013-01-11Add END() directives to the various functions.Miod Vallat
Make the code PIC-aware when necessary (i.e. invoke other functions through the PLT, and access global data through the GOT). No change for non-PIC compilation.
2013-01-11Add a bunch of macros to help writing PIC code for libc .S routines. HandlesMiod Vallat
both -fpic and -fPIC.
2013-01-08fix __cerror non-weak symbol nameMiod Vallat
2013-01-05Switch m88k ports to ELF.Miod Vallat
2012-12-26Actually invoke the system call in libc's sigreturn() wrapper; went unnoticedMiod Vallat
for 15 years or so (sigcode, of course, was correct).
2012-12-22Make sure the stack is 16-byte aligned otherwise the use of certain SSEMark Kettenis
instructions will fail. ok guenther@
2012-12-05Remove excessive sys/cdefs.h inclusionTheo de Raadt
ok guenther millert kettenis
2012-12-03Add two missing quad-precision emulation functions: _Qp_cmp and _Qp_cmpe. AtMark Kettenis
least the former is emitted by modern versions of GCC.
2012-09-15Adapt ieee.h, gdtoa and libc to the fact that we don't have 80-bitMartynas Venckus
floats on m88k. Agreed by miod@.
2012-09-04Add support for -fPICTheo de Raadt
ok kettenis
2012-09-04remove lint leftovers; ok guenther@Okan Demirmen
2012-09-04these are no longer used; ok guentherTheo de Raadt
2012-09-01Make this __STDC__ aware.Miod Vallat
2012-08-22Fix missing PIC -> __PIC__ conversions; ok pascalTheo de Raadt
2012-08-22Convert cpp | as rules in bsd.lib.mk and lib/libc/sys/Makefile.inc to pure ccPascal Stumpf
invocations. This allows us to use the compiler builtin define __PIC__ to check for PIC/PIEness rather than passing -DPIC. Simplifies PIE work a lot. ok matthew@, conceptually ok kurt@
2012-08-12Fix almost ten-years old bug in siglongjmp(), which would not restore a signalMiod Vallat
mask of zero (because of flawed logic assuming finding zero in the sigjmp_buf signal mask means sigsetjmp was invoked with a zero `savemask' argument). While there, clean comments of all *{set,long}jmp routines, and shave a few instructions by using bcnd insead of cmp + bb to test for zero values. Passes the regress tests, and now devel/libsigsegv configure siglongjmp test will not spin (this test is however flawed as it expects a signal handler declared as running on the sigaltstack and `returning' through siglongjmp to be invoked on the signal stack the next time the signal is raised).
2012-07-03adapt the NetBSD code to make sigpending work on shJonathan Gray
ok miod@ kettenis@
2012-07-01The kernel returns the pending set; this stub has to save it throughPhilip Guenthe
the pointer ok miod@ kettenis@
2012-07-01make this actually workMark Kettenis
ok miod@
2012-06-25Do not use <machine/float.h>, that is an deformed BSD-ism.Theo de Raadt
It turns out <float.h> is the right file to pull in. ok millert
2012-06-21__tfork() needs to set the stack address of the new thread in the kernel,Philip Guenthe
so that it can't get a signal while still running on the parent thread's stack. Also, pass in sizeof(struct __tfork) to provide forward compat when more members are added. This is an ABI change, so switch syscall numbers and bump lib majors this time. ok deraadt@ matthew@
2012-04-19rely on the compiler giving us a built-in alloca. any new architectureTheo de Raadt
or compiler we use will. ok millert
2012-04-12alloca.c cannot be usedTheo de Raadt
2012-04-12remove rfork(); ok guenther miodTheo de Raadt