Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-11-18Bump newlib release to 4.0.0newlib-4.0.0Jeff Johnston
2020-09-23Port of C-SKY for newlibJojo R
Contributor list:   - Lifang Xia <lifang_xia@c-sky.com>   - Jojo R <jiejie_rong@c-sky.com>   - Xianmiao Qu <xianmiao_qu@c-sky.com>   - Yunhai Shang <yunhai_shang@c-sky.com>
2020-07-29arm: Fix fenv supportEshan dhawan
The previous fenv support for ARM used the soft-float implementation of FreeBSD. Newlib uses the one from libgcc by default. They are not compatible. Having an GCC incompatible soft-float fenv support in Newlib makes no sense. A long-term solution could be to provide a libgcc compatible soft-float support. This likely requires changes in the GCC configuration. For now, provide a stub implementation for soft-float multilibs similar to RISC-V. Move implementation to one file and delete now unused files. Hide implementation details. Remove function parameter names from header file to avoid name conflicts. Provide VFP support if __SOFTFP__ is not defined like glibc. Reviewed-by: Sebastian Huber <sebastian.huber@embedded-brains.de> Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-07-27riscv: fix integer wraparound in memcpyPkmX via Newlib
This patch fixes a bug in RISC-V's memcpy implementation where an integer wraparound occurs when src + size < 8 * sizeof(long), causing the word-sized copy loop to be incorrectly entered. Signed-off-by: Chih-Mao Chen <cmchen@andestech.com>
2020-07-06Removed #ifndef _ARM_PCS_VFP_ from sys/fenv.h for armEshan dhawan via Newlib
Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-07-03mips fenv supportEshan dhawan via Newlib
Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-07-03SPARC fenv supportEshan dhawan via Newlib
Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-07-02fenv aarch64 supportEshan dhawan via Newlib
Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-06-10fenv support armEshan dhawan via Newlib
Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-06-03hard float support for PowerPC taken from FreeBSDEshan dhawan via Newlib
Signed-off-by: Eshan dhawan <eshandhawan51@gmail.com>
2020-03-02arm: Finish moving newlib to unified syntax for Thumb1Richard Earnshaw
Most code in newlib already uses unified syntax, but just a couple of laggards remain. This patch removes these and means the the entire code base has now been converted.
2020-01-29Use remove-advertising-clause script to edit BSD licensesKeith Packard
This edits licenses held by Berkeley and NetBSD, both of which have removed the advertising requirement from their licenses. Signed-off-by: Keith Packard <keithp@keithp.com>
2020-01-21Bump up newlib release to 3.3.0Jeff Johnston
2020-01-21riscv: Map between ieeefp.h exception bits and RISC-V FCSR bitsKeith Packard
If we had architecture-specific exception bits, we could just set them to match the processor, but instead ieeefp.h is shared by all targets so we need to map between the public values and the register contents. Signed-off-by: Keith Packard <keithp@keithp.com>
2020-01-21riscv: Add 'break' statements to fpsetround switchKeith Packard
This makes the fpsetround function actually do something rather than just return -1 due to the default 'fall-through' behavior of the switch statement. Signed-off-by: Keith Packard <keithp@keithp.com>
2020-01-21riscv: Use current pseudo-instructions to access the FCSR registerKeith Packard
Use fscsr and frcsr to store and read the FCSR register instead of fssr and frsr. Signed-off-by: Keith Packard <keithp@keithp.com>
2020-01-02Bump up release to 3.2.0 for yearly snapshotnewlib-snapshot-20200102newlib-3.2.0Jeff Johnston
2019-12-20Optimize setjmp/longjmp for moxie.Anthony Green
We don't need to save/restore every register -- just those we don't expect to be trashed by function calls.
2019-12-13Fix setjmp/longjmp for the moxie port.Anthony Green
These functions needs to save and restore the stack frame, because that's where the return address is stored.
2019-11-08Stash reent marker in upper bits of s1 on AMD GCNKwok Cheung Yeung
s[0:3] contain a descriptor used to set up the initial value of the stack, but only the lower 48 bits of s[0:1] are currently used. The reent marker is currently set in s3, but by stashing it in the upper 16 bits of s[0:1] instead, s3 can be freed up for other purposes.
2019-10-31Initial PRU port for libgloss and newlibDimitar Dimitrov
Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
2019-10-09riscv/sys/fenv.h: Add missing extern for fe_dfl_env_pJoel Sherrill
2019-10-08Add patch from Joel Sherrill for i386 and x86_64 fenv supportJeff Johnston
2019-10-07Optimize epilogue sequence for architectures with POP interworking.Christos Gentsos
ARMv5 and above supports arm/thumb interworking using POP, so we can improve the exit sequence in this case.
2019-09-03riscv/include/fenv.h: Use shared fenv.h.Joel Sherrill
libc/include/fenv.h was a direct copy of this file.
2019-08-09Miscellaneous Makefile.in regeneratedJoel Sherrill
2019-08-02RISC-V: Fix header guard for sys/fenv.hKito Cheng
2019-06-27or1k: Avoid write outside setjmp buf & shrink bufMartin Erik Werner
Update the offsets used to save registers into the stejmp jmp_buf structure in order to: * Avoid writing the supervision register outside the buffer and thus clobbering something on the stack. Previously the supervision register was written at offset 124 while the buffer was of length 124. * Shrink the jmp_buf down to the size actually needed, by avoiding holes at the locations of omitted registers.
2019-06-27or1k: Correct longjmp return valueMartin Erik Werner
Invert equality check instruction to correct the return value handling in longjmp. The return value should be the value of the second argument to longjmp, unless the argument value was 0 in which case it should be 1. Previously, longjmp would set return value 1 if the second argument was non-zero, and 0 if it was 0, which was incorrect.
2019-06-07Fix __getreent stack calculations for AMD GCNJeff Johnston
From: Andrew Stubbs <ams@codesourcery.com> Fix a bug in which the high-part of 64-bit values are being corrupted, leading to erroneous stack overflow errors. The problem was only that the mixed-size calculations are being treated as signed when they should be unsigned.
2019-05-23RISC-V: Add size optimized memcpy, memmove, memset and strcmp.Jim Wilson
This patch adds implementations of memcpy, memmove, memset and strcmp optimized for size. The changes have been tested in riscv/riscv-gnu-toolchain by riscv-dejagnu with riscv-sim.exp/riscv-sim-nano.exp.
2019-04-15Implement reduced code size "tiny" printf and putsJozef Lawrynowicz
"tiny" printf is derived from _vfprintf_r in libc/stdio/nano-vfprintf.c. "tiny" puts has been implemented so that it just calls write, without any other processing. Support for buffering, reentrancy and streams has been removed from these functions to achieve reduced code size. This reduced code size implementation of printf and puts can be enabled in an application by passing "--wrap printf" and "--wrap puts" to the GNU linker. This will replace references to "printf" and "puts" in user code with "__wrap_printf" and "__wrap_puts" respectively. If there is no implementation of these __wrap* functions in user code, these "tiny" printf and puts implementations will be linked into the final executable. The wrapping mechanism is supposed to be invisible to the user: - A GCC wrapper option such as "-mtiny-printf" will be added to alias these wrap commands. - If the user is unaware of the "tiny" implementation, and chooses to implement their own __wrap_printf and __wrap_puts, their own implementation will be automatically chosen over the "tiny" printf and puts from the library. Newlib must be configured with --enable-newlib-nano-formatted-io for the "tiny" printf and puts functions to be built into the library. Code size reduction examples: printf("Hello World\n") baseline - msp430-elf-gcc gcc-8_3_0-release text data bss 5638 214 26 "tiny" puts enabled text data bss 714 90 20 printf("Hello %d\n", a) baseline - msp430-elf-gcc gcc-8_3_0-release text data bss 10916 614 28 "tiny" printf enabled text data bss 4632 280 20
2019-04-15Copy prerequisite file for "tiny" printf implementationJozef Lawrynowicz
Use newlib/libc/stdio/nano-vfprintf.c as baseline for tiny-printf.c
2019-03-25Add missing includes.Andrew Stubbs
These missing includes were causing build warnings, but also a real bug in which the "size" parameter to "write" was being passed in 32-bit, whereas it ought to be 64-bit. This led to intermittent bad behaviour.
2019-01-23Remove matherr, and SVID and X/Open math library configurationsJozef Lawrynowicz
Default math library configuration is now IEEE
2019-01-15AMD GCN Port contributed by Andrew Stubbs <ams@codesourcery.com>Jeff Johnston
Add support for the AMD GCN GPU architecture. This is primarily intended for use with OpenMP and OpenACC offloading. It can also be used for stand-alone programs, but this is intended mostly for testing the compiler and is not expected to be useful in general. The GPU architecture is highly parallel, and therefore Newlib must be configured to use dynamic re-entrancy, and thread-safe malloc. The only I/O available is a via a shared-memory interface provided by libgomp and the gcn-run tool included with GCC. At this time this is limited to stdout, argc/argv, and the return code.
2019-01-01Bump release to 3.1.0 for yearly snapshotnewlib-snapshot-20181231newlib-3.1.0Jeff Johnston
2018-11-08Fix issue with dst bias in memsetWilco Dijkstra
This patch fixes an issue in the previous memset loop change. If the zva size is >= 256 and there are more than 64 bytes left in the tail, we could enter the loop and thus need to rebias dst by 32 as well. Since no known CPUs use this size this can't be tested natively, so I've tested it on a simulator initialized with a large zva size. --
2018-11-06Adjust writeback in non-zero memsetWilco Dijkstra
This fixes an ineffiency in the non-zero memset. Delaying the writeback until the end of the loop is slightly faster on some cores - this shows ~5% performance gain on Cortex-A53 when doing large non-zero memsets. Tested against the GLIBC testsuite.
2018-10-11Move common <sys/dirent.h> content to <dirent.h>Sebastian Huber
Move common content of the various <sys/dirent.h> and the latest FreeBSD <dirent.h> to <dirent.h>. Signed-off-by: Sebastian Huber <sebastian.huber@embedded-brains.de>
2018-08-31Add --disable-newlib-fno-builtin to allow compilation without -fno-builtin ↵newlib-snapshot-20180831Jon Beniston
for smaller and faster code.
2018-08-29Use __inhibit_loop_to_libcall in all memset/memcpy implementationsKeith Packard
This macro selects a compiler option that disables recognition of common memset/memcpy patterns and converting those to direct memset/memcpy calls. Signed-off-by: Keith Packard <keithp@keithp.com>
2018-07-13strcmp.S: Improve performance for misaligned stringsSiddhesh Poyarekar
Replace the simple byte-wise compare in the misaligned case with a dword compare with page boundary checks in place. For simplicity I've chosen a 4K page boundary so that we don't have to query the actual page size on the system. This results in up to 3x improvement in performance in the unaligned case on falkor and about 2.5x improvement on mustang as measured using bench-strcmp in glibc.
2018-07-13memcmp.S: optimize for medium to large sizesSiddhesh Poyarekar
This improved memcmp provides a fast path for compares up to 16 bytes and then compares 16 bytes at a time, thus optimizing loads from both sources. The glibc memcmp microbenchmark retains performance (with an error of ~1ns) for smaller compare sizes and reduces up to 31% of execution time for compares up to 4K on the APM Mustang. On Qualcomm Falkor this improves to almost 48%, i.e. it is almost 2x improvement for sizes of 2K and above.
2018-07-13Improve strncmp for mutually misaligned inputsSiddhesh Poyarekar
The mutually misaligned inputs on aarch64 are compared with a simple byte copy, which is not very efficient. Enhance the comparison similar to strcmp by loading a double-word at a time. The peak performance improvement (i.e. 4k maxlen comparisons) due to this on the strncmp microbenchmark in glibc is as follows: falkor: 3.5x (up to 72% time reduction) cortex-a73: 3.5x (up to 71% time reduction) cortex-a53: 3.5x (up to 71% time reduction) All mutually misaligned inputs from 16 bytes maxlen onwards show upwards of 15% improvement and there is no measurable effect on the performance of aligned/mutually aligned inputs.
2018-04-13Add nvptx port.Jeff Johnston
- From: Cesar Philippidis <cesar@codesourcery.com> Date: Tue, 10 Apr 2018 14:43:42 -0700 Subject: [PATCH] nvptx port This port adds support for Nvidia GPU's, which are primarily used as offload accelerators in OpenACC and OpenMP.
2018-01-31epiphany: Additional setjmp() and longjmp() symsSebastian Huber
At least with Binutils 2.30 and GCC 7.3 we need symbol definitions without the leading underscore. Signed-off-by: Sebastian Huber <sebastian.huber@embedded-brains.de>
2018-01-18Bump release to 3.0.0 for yearly snapshotnewlib-snapshot-20180118newlib-3.0.0Jeff Johnston
- major release required due to removal of K&R support
2018-01-17ansification: remove _HAVE_STDCYaakov Selkowitz
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
2018-01-17ansification: remove _EXFUN, _EXFUN_NOTHROWYaakov Selkowitz
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>