|
Revision tags: release/13.4.0-p5, release/13.5.0-p1, release/14.2.0-p3, release/13.5.0, release/14.2.0-p2, release/14.1.0-p8, release/13.4.0-p4, release/14.1.0-p7, release/14.2.0-p1, release/13.4.0-p3, release/14.2.0, release/13.4.0, release/14.1.0, release/13.3.0, release/14.0.0 |
|
| #
feaae6ba |
| 30-Jul-2023 |
Konstantin Belousov <[email protected]> |
rtld: switch from malloc_aligned() to __crt_aligned_alloc()
Use regular free(), since it works now.
Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision:
rtld: switch from malloc_aligned() to __crt_aligned_alloc()
Use regular free(), since it works now.
Reviewed by: markj Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D41150
show more ...
|
| #
b3e76948 |
| 16-Aug-2023 |
Warner Losh <[email protected]> |
Remove $FreeBSD$: two-line .h pattern
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
|
| #
4d846d26 |
| 10-May-2023 |
Warner Losh <[email protected]> |
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of
spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD
The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause.
Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
show more ...
|
|
Revision tags: release/13.2.0, release/12.4.0, release/13.1.0, release/12.3.0, release/13.0.0, release/12.2.0, release/11.4.0 |
|
| #
2f06c66a |
| 04-Apr-2020 |
Konstantin Belousov <[email protected]> |
Make p_vaddr % p_align == p_offset % p_align for (some) TLS segments.
See https://sourceware.org/bugzilla/show_bug.cgi?id=24606 for the test case. See https://reviews.llvm.org/D64930 for the backgro
Make p_vaddr % p_align == p_offset % p_align for (some) TLS segments.
See https://sourceware.org/bugzilla/show_bug.cgi?id=24606 for the test case. See https://reviews.llvm.org/D64930 for the background and more discussion.
Also this fixes another bug in malloc_aligned() where total size of the allocated memory might be not enough to fit the aligned requested block after the initial pointer is incremented by the pointer size.
Reviewed by: bdragon Tested by: antoine (exp-run PR 244866), bdragon, emaste Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D21163
show more ...
|
|
Revision tags: release/12.1.0, release/11.3.0 |
|
| #
b54a59f3 |
| 30-Jun-2019 |
Alex Richardson <[email protected]> |
Reduce size of rtld by 22% by pulling in less code from libc
Currently RTLD is linked against libc_nossp_pic which means that any libc symbol used in rtld can pull in a lot of depedencies. This was
Reduce size of rtld by 22% by pulling in less code from libc
Currently RTLD is linked against libc_nossp_pic which means that any libc symbol used in rtld can pull in a lot of depedencies. This was causing symbol such as __libc_interposing and all the pthread stubs to be included in RTLD even though they are not required. It turns out most of these dependencies can easily be avoided by providing overrides inside of rtld.
This change is motivated by CHERI, where we have an experimental ABI that requires additional relocation processing to allow the use of function pointers inside of rtld. Instead of adding this self-relocation code to RTLD I attempted to remove most function pointers from RTLD and discovered that most of them came from the libc dependencies instead of being actually used inside rtld.
A nice side-effect of this change is that rtld is now 22% smaller on amd64.
text data bss dec hex filename 0x21eb6 0xce0 0xe60 145910 239f6 /home/alr48/ld-elf-x86.before.so.1 0x1a6ed 0x728 0xdd8 113645 1bbed /home/alr48/ld-elf-x86.after.so.1
The number of R_X86_64_RELATIVE relocations that need to be processed on startup has also gone down from 368 to 187 (almost 50% less).
Reviewed By: kib Differential Revision: https://reviews.freebsd.org/D20663
show more ...
|
| #
1a3b2ebf |
| 29-Jan-2019 |
Konstantin Belousov <[email protected]> |
Adjust posix symbols from rtld-elf/malloc.c with the __crt_ prefix.
This allows to reuse the allocator in other environments that get malloc(3) and related functions from libc or interposer.
MFC af
Adjust posix symbols from rtld-elf/malloc.c with the __crt_ prefix.
This allows to reuse the allocator in other environments that get malloc(3) and related functions from libc or interposer.
MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential revision: https://reviews.freebsd.org/D18988
show more ...
|
|
Revision tags: release/12.0.0, release/11.2.0 |
|
| #
e6209940 |
| 27-Nov-2017 |
Pedro F. Giffuni <[email protected]> |
libexec: adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone -
libexec: adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task.
The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts.
No functional change intended.
show more ...
|
|
Revision tags: release/10.4.0, release/11.1.0, release/11.0.1, release/11.0.0, release/10.3.0, release/10.2.0, release/10.1.0, release/9.3.0 |
|
| #
eab68f79 |
| 22-Feb-2014 |
David Xu <[email protected]> |
Increase alignment to size of pointer if the alignment is too small. Some modules do not align data at least to size of pointer, they uses a smaller alignment, but our pointer should be aligned to it
Increase alignment to size of pointer if the alignment is too small. Some modules do not align data at least to size of pointer, they uses a smaller alignment, but our pointer should be aligned to its native boundary, otherwise on some platforms, hardware alignment checking will cause bus error.
show more ...
|
| #
209782e0 |
| 21-Feb-2014 |
David Xu <[email protected]> |
malloc_aligned() may not leave enough space for pointer to allocated memory, saving the pointer will overwrite bytes belongs to another memory block unexpectly, to fix the problem, use (allocated add
malloc_aligned() may not leave enough space for pointer to allocated memory, saving the pointer will overwrite bytes belongs to another memory block unexpectly, to fix the problem, use (allocated address + sizeof(void *)) as initial value, and slip to next aligned address, so maximum extra bytes is sizeof(void *) + align - 1.
Tested by: Andre Albsmeier < mail at ma17 dot ata dot myota dot orgndre >
show more ...
|
|
Revision tags: release/10.0.0 |
|
| #
dfe296c4 |
| 06-Dec-2013 |
Konstantin Belousov <[email protected]> |
Build an allocator for the aligned memory on top of the rtld-private malloc.
Reviewed by: kan Sponsored by: The FreeBSD Foundation MFC after: 1 week
|
|
Revision tags: release/9.2.0, release/8.4.0, release/9.1.0, release/8.3.0_cvs, release/8.3.0 |
|
| #
f7b34303 |
| 23-Mar-2012 |
Konstantin Belousov <[email protected]> |
Implement xstrdup() using strlen()/xmalloc()/memcpy() already presented in rtld, instead of pulling in libc strdup().
Submitted by: bde MFC after: 2 weeks
|
| #
758ffbfa |
| 22-Mar-2012 |
Konstantin Belousov <[email protected]> |
Use xmalloc() instead of malloc() in the places where malloc() calls are assumed to not fail.
Make the xcalloc() calling conventions follow the calloc(3) calling conventions and replace unchecked ca
Use xmalloc() instead of malloc() in the places where malloc() calls are assumed to not fail.
Make the xcalloc() calling conventions follow the calloc(3) calling conventions and replace unchecked calls to calloc() with calls to xcalloc().
Remove redundand declarations from xmalloc.c, which are already present in rtld.h.
Reviewed by: kan Discussed with: bde MFC after: 2 weeks
show more ...
|
|
Revision tags: release/9.0.0 |
|
| #
0e9a2605 |
| 24-Aug-2011 |
Konstantin Belousov <[email protected]> |
Rtld links with the specially built pic static libc library to get some C runtime services, like printf(). Unfortunately, the multithread-safeness measures in the libc do not work in rtld environment
Rtld links with the specially built pic static libc library to get some C runtime services, like printf(). Unfortunately, the multithread-safeness measures in the libc do not work in rtld environment.
Rip the kernel printf() implementation and use it in the rtld instead of libc version. This printf does not require any shared global data and thus is mt-safe. Systematically use rtld_printf() and related functions, remove the calls to err(3).
Note that stdio is still pulled from libc due to libmap implementaion using fopen(). This is safe but unoptimal, and can be changed later.
Reported and tested by: pgj Diagnosed and reviewed by: kan (previous version) Approved by: re (bz)
show more ...
|
|
Revision tags: release/7.4.0_cvs, release/8.2.0_cvs, release/7.4.0, release/8.2.0, release/8.1.0_cvs, release/8.1.0, release/7.3.0_cvs, release/7.3.0, release/8.0.0_cvs, release/8.0.0, release/7.2.0_cvs, release/7.2.0, release/7.1.0_cvs, release/7.1.0, release/6.4.0_cvs, release/6.4.0, release/7.0.0_cvs, release/7.0.0, release/6.3.0_cvs, release/6.3.0, release/6.2.0_cvs, release/6.2.0, release/5.5.0_cvs, release/5.5.0, release/6.1.0_cvs, release/6.1.0, release/6.0.0_cvs, release/6.0.0, release/5.4.0_cvs, release/5.4.0, release/4.11.0_cvs, release/4.11.0, release/5.3.0_cvs, release/5.3.0, release/4.10.0_cvs, release/4.10.0, release/5.2.1_cvs, release/5.2.1, release/5.2.0_cvs, release/5.2.0, release/4.9.0_cvs, release/4.9.0 |
|
| #
5407dd5b |
| 19-Jun-2003 |
Matthew N. Dodd <[email protected]> |
Add function prototypes.
|
|
Revision tags: release/5.1.0_cvs, release/5.1.0, release/4.8.0_cvs, release/4.8.0, release/5.0.0_cvs, release/5.0.0, release/4.7.0_cvs, release/4.6.2_cvs, release/4.6.2, release/4.6.1, release/4.6.0_cvs, release/4.5.0_cvs, release/4.4.0_cvs, release/4.3.0_cvs, release/4.3.0, release/4.2.0, release/4.1.1_cvs, release/4.1.0, release/3.5.0_cvs, release/4.0.0_cvs, release/3.4.0_cvs, release/3.3.0_cvs |
|
| #
7f3dea24 |
| 28-Aug-1999 |
Peter Wemm <[email protected]> |
$Id$ -> $FreeBSD$
|
|
Revision tags: release/3.2.0, release/3.1.0, release/3.0.0, release/2.2.8, release/2.2.7, release/2.2.6 |
|
| #
3124c3e0 |
| 07-Mar-1998 |
John Polstra <[email protected]> |
Import the ELF dynamic linker. This is the ElfKit version with quite a few enhancements and bug fixes. There are still some known deficiencies, but it should be adequate to get us started with ELF.
Import the ELF dynamic linker. This is the ElfKit version with quite a few enhancements and bug fixes. There are still some known deficiencies, but it should be adequate to get us started with ELF.
Submitted by: John Polstra <[email protected]>
show more ...
|