summaryrefslogtreecommitdiffstats
path: root/lib/libc/arch/sh/gen (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Add support for timeconting in userland.pirofti2020-07-062-2/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | This diff exposes parts of clock_gettime(2) and gettimeofday(2) to userland via libc eliberating processes from the need for a context switch everytime they want to count the passage of time. If a timecounter clock can be exposed to userland than it needs to set its tc_user member to a non-zero value. Tested with one or multiple counters per architecture. The timing data is shared through a pointer found in the new ELF auxiliary vector AUX_openbsd_timekeep containing timehands information that is frequently updated by the kernel. Timing differences between the last kernel update and the current time are adjusted in userland by the tc_get_timecount() function inside the MD usertc.c file. This permits a much more responsive environment, quite visible in browsers, office programs and gaming (apparently one is are able to fly in Minecraft now). Tested by robert@, sthen@, naddy@, kmos@, phessler@, and many others! OK from at least kettenis@, cheloha@, naddy@, sthen@
* Copy files from ../librthread in preparation for moving functionalityguenther2017-08-151-0/+46
| | | | | | | from libpthread to libc. No changes to the build yet, just making it easier to review the substantive diffs. ok beck@ kettenis@ tedu@
* Wrap fpgetround() so internal calls to it (seen on arm, powerpc, and sh)guenther2016-07-262-4/+5
| | | | | | go direct instead of through the PLT. ok millert@ kettenis@
* Invoke the _HIDDEN() sigprocmask label rather than the public one.miod2015-10-312-8/+10
|
* Wrap the remaining math functions in libc: __fpclassify*(), __flt_rounds(),guenther2015-10-271-1/+2
| | | | | | and ldexp(). ok millert@
* Switch from <sys/endian.h> or <machine/endian.h> to the new,guenther2014-07-212-5/+5
| | | | | | being-standardized <endian.h> ok deraadt@ millert@ beck@
* It's been a quarter century: we can assume volatile is present with that name.guenther2014-04-188-19/+19
|
* Switch libc and libm to use strong aliases rather than weak aliasesmartynas2013-03-281-2/+2
| | | | | | | | | | | 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@.
* Remove excessive sys/cdefs.h inclusionderaadt2012-12-051-2/+1
| | | | ok guenther millert kettenis
* Do not use <machine/float.h>, that is an deformed BSD-ism.deraadt2012-06-251-2/+2
| | | | | It turns out <float.h> is the right file to pull in. ok millert
* Revert (leaving the complex math part alone). Some stuff is dependingmartynas2011-07-082-3/+43
| | | | | on this historical behavior; so we're stuck in this stupid situation. No cookie for me.
* Move fabs(3), frexp(3), and modf(3) to libm--nothing has been usingmartynas2011-07-082-43/+3
| | | | them in libc for a very long time. OK guenther@.
* remove from gen so that lint doesn't check gen if assembly versionsmartynas2009-04-211-2/+3
| | | | are available. spotted by theo
* - ldexp implementation has issues. switch to the one from libmmartynas2009-04-193-452/+2
| | | | | | - remove frexp in hppa64, cloned from hppa - move generic ieee754 implementations of modf and ldexp to gen ok kettenis@, "looks good" millert@
* this is not a write-only register. might have caused to optimizemartynas2009-04-051-2/+2
| | | | it away. ok miod@
* use sys/cdefs.h; pointed out by theomartynas2008-12-102-4/+4
|
* ditto frexpl and ldexplmartynas2008-12-091-1/+4
|
* alias fabsl to fabs on these archsmartynas2008-12-091-1/+4
|
* - move isinf, isnan dups to gen, since most is ieee 754martynas2008-07-244-96/+17
| | | | | | | | | | | | | | | | - is{inf,nan} should be macros for real-floating, so rename to __is{inf,nan}, per C99 - implement C99 __fpclassify(), __fpclassifyf(), __isfinite(), __isfinitef(), __isnormal(), __isnormalf(), __signbit(), __signbitf() - long functions added, but not yet enabled, till ieee.h is fixed - implement vax equivalents of the functions - reimplement isinff, isnanf in a better way, and move to libc - add qnan bytes for all archs - bump major man pages will follow ok millert@. arm bits looked over by drahn@ discussed w/ theo, who showed the right direction, to put these functions in libc
* clear sign bit, instead of comparing to zero and setting x=-x.martynas2008-07-231-6/+12
| | | | | | | fixes special cases, such as neg. zero, and makes C99 conformant ok miod@, millert@ since there's nothing else in arm's fabs.c, replace 4-clause license w/ the one at /usr/share/misc/license.template
* Move landisk to hardware floating point. At the moment the FPU context ismiod2007-03-028-130/+264
| | | | | | | | | | | | | | | always saved upon context switches, as FPU registers are heavily used for long long computations (don't ask). Gcc default to -m4. Credits to drahn@ otto@ and deraadt@ for feedback and help testing. Upgrade procedure if you don't want to use the damn snapshots: - build and install new kernel, reboot off it - build new gcc, do not install it yet - make includes - install new gcc - build and install lib/csu and lib/libc - make build
* Do not use fpu in the softfloat case. Fixes lib/libc/ieeefp/roundotto2006-11-141-1/+5
| | | | regress test; ok miod@
* missing ;otto2006-11-131-2/+2
|
* fix infinity, taking into account endianess. ok drahn@ miod@otto2006-11-121-2/+6
|
* Move (back) to softfloat on sh for now.drahn2006-11-062-5/+13
|
* and I forgot ldexp.cdrahn2006-10-111-2/+2
|
* build modf.cdrahn2006-10-111-2/+2
|
* Preliminary userland bits for OpenBSD/landisk, many things coming frommiod2006-10-1017-0/+1140
NetBSD.