summaryrefslogtreecommitdiffstats
path: root/lib/libc/arm/gen
Commit message (Collapse)AuthorAgeFilesLines
* Make armv6 hard float abi by default. Kill armv6hf.imp2016-05-181-1/+1
| | | | | | | Allow CPUTYPE=soft to build the current soft-float abi libraries. Add UPDATING entry to announce this. Approved by: re@ (gjb)
* Annotate arm userspace assembler sources stating their tolerance tokib2015-09-297-0/+13
| | | | | | | the non-executable stack. Reviewed by: andrew Sponsored by: The FreeBSD Foundation
* Add include for declaration of _set_tp(). Eliminates -Wmissing-prototypes ↵rodrigc2015-09-201-0/+1
| | | | warnings.
* Remove __ARM_EABI__ from more places in libc as this is the only ARM ABIandrew2015-05-312-15/+7
| | | | we support.
* Teach bits of libc about Thumb. This adds the if-then instructions neededandrew2015-05-122-2/+32
| | | | | | | | | to handle the ARM conditional execution. While here fix a bug found by this in the hard-float code, cc is the opposite of cs. The former is used for 'less than' in floating-point code and is executed when the C (carry) bit is clear, the latter is used when greater than, equal, or unordered, and is executed when the C bit is set.
* Remove duplicate copies of trivial getcontextx.cemaste2015-01-122-78/+3
| | | | | | | | | | Only i386 and amd64 provide a non-trivial __getcontextx(). Use a common trivial implementation in gen/ for other architectures, rather than copying the file to each MD subdirectory. Reviewed by: kib Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D1472
* Remove MK_ARM_EABI, the armeb issues have been fixed. The code to supportandrew2014-10-011-4/+0
| | | | | | | | | | | | the oabi is still in the tree, but it is expected this will be removed as developers work on surrounding code. With this commit the ARM EABI is the only supported supported ABI by FreeBSD on ARMa 32-bit processors. X-MFC after: never Relnotes: yes Differential Revision: https://reviews.freebsd.org/D876
* In ARM asm code, ensure that every ENTRY(foo) has a matching END(foo).ian2014-08-317-1/+13
| | | | | | | | | The EABI unwind info requires a .fnend for every .fnstart, and newer binutils will complain about seeing two .fnstart in a row. This change allows newer tools to compile our code. Reported by: bapt Reviewed by: imp
* Set the new floating point exception mask correctlyandrew2014-04-281-1/+1
| | | | Submitted by: Keith White <kwhite@site.uottawa.ca>
* Rename the fp{get,set}* files so they no longer conflict with the softfloatandrew2014-04-217-2/+2
| | | | | version of these files. Keep them within this directory so they can be used to implement the armv6 version of these functions.
* Add the deprecated fp{get,set}* functions, a few ports use them.andrew2014-04-207-0/+304
|
* Implement __flt_rounds for ARMv6 hard-float. The fpscr register stores theandrew2014-03-221-10/+14
| | | | current rounding mode used by the VFP unit.
* Teach siglongjmp about the VFP version of the setjmp buffer.andrew2013-07-211-3/+5
| | | | | This fixes a bug where a call to sigsetjmp followed by siglongjmp may fail when run on a machine with VFP enabled.
* Finish pulling in the NetBSD setjmp/longjmp updates on ARM.andrew2013-06-074-4/+162
| | | | | | | | Store/restore the VFP registers in setjmp/longjmp on ARM EABI if VFP is enabled in the kernel. It checks the hw.floatingpoint sysctl to see if floating-point is available and uses this to determine if it should store them. If it does it uses a different magic value so longjmp is able to know if it should load them.
* Include machine/setjmp.h to get the definition of _JB_MAGIC__SETJMP. Thisandrew2013-06-071-1/+3
| | | | allows us to remove it from the ARM copy of machine/asm.h.
* Remove part of the NetBSD longjmp code that was not ready to be merged.andrew2013-06-051-2/+1
|
* Start to merge the updated ARM NetBSD setjump/longjmp functions. To beginandrew2013-06-042-75/+52
| | | | | | | | | | with merge the functions but leave out the code to save/load the VFP registers as that requires other changes to ensure the VFP is enabled first. This removes storing the old fpa registers. These were never fully supported, and the only user of this code I can find have moved to newer CPUs which use a VFP.
* The getcontext() from the __fillcontextx() call in thekib2013-05-281-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | check_deferred_signal() returns twice, since handle_signal() emulates the return from the normal signal handler by sigreturn(2)ing the passed context. Second return is performed on the destroyed stack frame, because __fillcontextx() has already returned. This causes undefined and bad behaviour, usually the victim thread gets SIGSEGV. Avoid nested frame and the need to return from it by doing direct call to getcontext() in the check_deferred_signal() and using a new private libc helper __fillcontextx2() to complement the context with the extended CPU state if the deferred signal is still present. The __fillcontextx() is now unused, but is kept to allow older libthr.so to be used with the new libc. Mark __fillcontextx() as returning twice [1]. Reported by: pgj Pointy hat to: kib Discussed with: dim Tested by: pgj, dim Suggested by: jilles [1] MFC after: 1 week
* Use the compiler-rt version __{u,}divsi3 and __{u,}modsi3 on ARM EABIandrew2013-01-191-1/+5
|
* Merging of projects/armv6, part 2gonzo2012-08-152-0/+10
| | | | Handle TLS for ARMv6 and ARMv7
* Replace the C implementation of __aeabi_read_tp with an assembly version.andrew2012-04-162-14/+9
| | | | | | This ensures we follow the ABI by preserving registers r1-r3. Reviewed by: jmallett, imp
* Unlike other functions __aeabi_read_tp function must preserve r1-r3. Theandrew2012-04-081-2/+5
| | | | | | | currently generated code clobbers r3. Fix this by loading ARM_TP_ADDRESS using inline assembly. Approved by: imp (mentor)
* - Revert part of r234005, which I did not intend to commit.stas2012-04-071-1/+1
| | | | Sorry! :(
* - Add kernel config file for QEMU-emulated gumstix board.stas2012-04-071-1/+1
|
* Unbreak trhe build by including proper headergonzo2012-03-181-1/+1
|
* Fix TLS for statically linked binariesgonzo2012-03-181-0/+4
| | | | Approved by: cognet
* Add __aeabi_read_tp function required for thread-local storagegonzo2012-02-142-1/+43
| | | | Reviewed by: cognet
* Make the sys/ucontext.h self-contained by changing the return typekib2012-02-011-1/+1
| | | | | | | of __getcontextx_size(3) from size_t to int. PR: ports/164654 MFC after: 1 month
* Add API for obtaining extended machine context states that cannot bekib2012-01-212-1/+70
| | | | | | | | | | | fit into existing mcontext_t. On i386 and amd64 do return the extended FPU states using getcontextx(3). For other architectures, getcontextx(3) returns the same information as getcontext(2). Tested by: pho MFC after: 1 month
* Don't inline fenv.h functions on arm for now. Inlining makes sense:das2012-01-201-0/+2
| | | | | | | | the function bodies require only 2 to 10 instructions. However, it leads to application binaries that refer to a private ABI, namely, the softfloat innards in libc. This could complicate future changes in the implementation of the floating-point emulation layer, so it seems best to have programs refer to the official fe* entry points in libm.
* Implement FLT_ROUNDS for arm. Some (all?) arm FPUs lack support fordas2012-01-162-1/+64
| | | | | | | | dynamic rounding modes, but FPUless chips that use softfloat can support it because everything is emulated anyway. (We presently have incomplete support for hardware FPUs.) Submitted by: Ian Lepore
* Replace a proliferation of buggy MD implementations of modf() with adas2011-10-212-108/+1
| | | | | | | working MI one. The MI one only needs to be overridden on machines with non-IEEE754 arithmetic. (The last supported one was the VAX.) It can also be overridden if someone comes up with a faster one that actually passes the regression tests -- but this is harder than it sounds.
* Fix typos - remove duplicate "the".brucec2011-02-211-1/+1
| | | | | | PR: bin/154928 Submitted by: Eitan Adler <lists at eitanadler.com> MFC after: 3 days
* The NetBSD Foundation has granted permission to remove clause 3 and 4 fromjoel2010-03-021-7/+0
| | | | | | their software. Obtained from: NetBSD
* Use GCC's __SOFTFP__ to test whether we're being compiledmarcel2009-05-312-8/+8
| | | | | with softfloat or not. Now -msoft-float can be overridden more easily.
* Let libstand(3) build on ARM.raj2008-10-141-0/+4
| | | | This is a pre-requisite for loader(8) + U-Boot support library on this arch.
* Replace the ldexp() implementation in libc with a renamed copy of thedas2005-01-221-155/+0
| | | | | | | | | | | | | | | | scalbn() implementation from libm. (The two functions are defined to be identical, but ldexp() lives in libc for backwards compatibility.) The old ldexp() implementation... - was more complicated than this one - set errno instead of raising FP exceptions - got some corner cases wrong (e.g. ldexp(1.0, 2000) in round-to-zero mode) The new implementation lives in libc/gen instead of libc/$MACHINE_ARCH/gen, since we don't need N copies of a machine-independent file. The amd64 and i386 platforms retain their fast and correct MD implementations and override this one.
* Use the RET macro.cognet2004-11-094-13/+12
| | | | | For setjmp() and longjmp(), put the signal mask where it's supposed to be, instead of in the space reserved for fp regs.
* Add a week alias __siglongjmp => siglongjmp.cognet2004-11-091-0/+1
|
* Don't define SOFTFLOAT directly in source files, it's now done in the Makefile.cognet2004-11-052-2/+1
|
* Fix signalcontext and makecontext.cognet2004-11-053-14/+17
|
* Make setjmp()/longjmp() use sigprocmask.cognet2004-09-231-9/+9
|
* Add a dummy set_tp().cognet2004-09-232-1/+36
|
* Replace seven nominally MD implementations of frexp() that are brokendas2004-07-182-68/+1
| | | | for subnormals with one implementation that works.
* Implement the classification macros isfinite(), isinf(), isnan(), anddas2004-07-092-71/+1
| | | | | | | | | | | | | | | | | | | | | isnormal() the hard way, rather than relying on fpclassify(). This is a lose in the sense that we need a total of 12 functions, but it is necessary for binary compatibility because we have never bumped libm's major version number. In particular, isinf(), isnan(), and isnanf() were BSD libc functions before they were C99 macros, so we can't reimplement them in terms of fpclassify() without adding a dependency on libc.so.5. I have tried to arrange things so that programs that could be compiled in FreeBSD 4.X will generate the same external references when compiled in 5.X. At the same time, the new macros should remain C99-compliant. The isinf() and isnan() functions remain in libc for historical reasons; however, I have moved the functions that implement the macros isfinite() and isnormal() to libm where they belong. Moreover, half a dozen MD versions of isinf() and isnan() have been replaced with MI versions that work equally well. Prodded by: kris
* Import the FreeBSD/arm libc bits.cognet2004-05-1415-0/+1387
Obtained from: NetBSD
OpenPOWER on IntegriCloud