summaryrefslogtreecommitdiff
path: root/libpthread/nptl/sysdeps/mips
AgeCommit message (Collapse)Author
2023-11-09libpthread/nptl: make default stack size configurableBen Wolsieffer
Threads currently have 2-4 MiB stacks by default (depending on the platform). This is fine on MMU platforms, where this stack space is not actually allocated until it is used, but tends to waste a large amount of memory on no-MMU platforms. This patch adds a PTHREADS_STACK_DEFAULT_SIZE Kconfig option that allows the user to override the default stack size at build time. This allows the user to select a reasonable default stack size for the software that runs on their system, and avoids the need to patch every package to add calls to pthread_attr_setstacksize(). An alternative to this patch would be to change the hardcoded default stack size on no-MMU platforms, but it is difficult to choose an appropriate value because the minimum required stack depends on the software in use. This would also be a breaking change. Signed-off-by: Ben Wolsieffer <ben.wolsieffer@hefring.com>
2017-01-28remove PID cachingWaldemar Brodkorb
Follow GNU C Library from c579f48edba88380635ab98cb612030e3ed8691e and remove the PID caching. These simplifies the architecture specific assembly code. The run of the test suite found no regressions, it even solves some of the test failures for x86/x86_64/sparc. Reviewed-by: Max Filippov <jcmvbkbc@gmail.com> Reviewed-by: Vineet Gupta <Vineet.Gupta1@synopsys.com> Acked-by: Matthew Fortune <Matthew.Fortune@imgtec.com> Acked-by: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
2016-09-26use a single libc and deduplicate threading codeWaldemar Brodkorb
Similar to musl libc a single libc has many benefits and solves some open issues with uClibc-ng. - no pthread_mutex_* weak symbols exported anymore - applications no longer failing to link when either -lrt or -lpthread are missing for dynamic and static linking mode - smaller C library - slightly better runtime performance
2016-07-31deduplicate jmpbuf-unwind.hWaldemar Brodkorb
Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
2016-06-18remove unused MakefilesWaldemar Brodkorb
2014-09-16buildsys: remove now redundant lib placement definesBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2014-02-02mips: silence 'set but not used' warningsSteve Ellcey
This patch uses 'attribute_unused' to clean up a number of warnings messages that are generated when doing a MIPS build. All of the changes are in MIPS specific files and there are no code changes other then adding the unused attribute where needed. Signed-off-by: Steve Ellcey <sellcey@mips.com> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2012-11-18Replace FSF snail mail address with URLsMike Frysinger
This matches a similar change made to glibc. No functional changes here. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2012-06-15move *longjmp related prototypes to setjmp.hPeter S. Mazinger
Provide common prototypes for __longjmp, __libc_longjmp, __libc_siglongjmp _longjmp_unwind, __libc_unwind_longjmp in setjmp.h in preparation for use in LT new Add __longjmp to h8300 and i960 Make common longjmp.c good for NPTL Guard _longjmp_unwind use in sh's longjmp.c for NPTL (I think sh could use the common one) Remove unneeded attribute_noreturn, prototype provides it already Signed-off-by: Peter S. Mazinger <ps.m@gmx.net> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2010-12-01Revert "libc_tls: Do not include generic libc-tls from arch specific ↵Carmelo Amoroso
implementation" This reverts commit 0c468129356f5ce6780e7369c271d74631ae03ba. Indeed recent updates into buildsys managed to filter-out generic implementation when arch specific one is defined, so duplicated symbols into the libc.a In the meanwhile, do a minor fix into mips version not using relative path to include <generic/libc-tls.c> Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
2010-11-29libc_tls: Do not include generic libc-tls from arch specific implementationCarmelo Amoroso
libpthread/nptl/sysdeps/generic/libc-tls.c is built as well, so it does not need that arch specific version of libc-tls.c (MIPS and ALPHA) includes it. The arch libc-tls.s is aimed to provide the implementation of __tls_get_addr for the static libc.a, because on these archs the linker relaxations are not required and it could be possible to have local-dynamic access models in static libraries as well. Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
2010-11-11ntpl: fix static linking by not leaking SSP_ALL_CFLAGSNatanael Copa
The SSP_ALL_CFLAGS in nptl arch CFLAGS leaks out and forces things like dl-support.c, brk.c, sbrk.c memcpy, etc to be built with -fstack-protector-all. This is bad when linking statically since initializing TLS will call those functions before SSP is initialized. The libpthread itself will still be built with -fstack-protector-all due to CFLAGS-nptl has SSP_ALL_CFLAGS in libpthread/nptl/Makefile.in Thanks to Timo Teras for helping with this. Signed-off-by: Natanael Copa <natanael.copa@gmail.com> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2010-07-14nptl: remove superfluous =1 from definesBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2010-07-06nptl: fix buildsysBernhard Reutner-Fischer
Now automatically picks the correct (arch and subarch specific) impls in favour of generic impls. make O=/tmp/objs PREFIX=/my/sysroot -j works now as expected (both out-of-tree as well as parallel-safe). Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2010-07-06nptl: simplify buildsysBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2010-06-30mips/syscall-error: Choose the correct version for setting up errno.Khem Raj
* Current function is a C protype and PSEUDO macro does not transfer syscall return parameters to correct argument registers for a C function. This causes problem with syscalls setting wrong value for errno when they encounter an error. * Fixes PR/2089 for mips/nptl Signed-off-by: Khem Raj <raj.khem@gmail.com>
2010-05-07mips/Makefile.arch: Remove -f option to $(do_awk)Khem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2010-04-12use user-provided host binariesBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
2010-02-23get rid of extra variables for nptl pregen altogetherAustin Foxley
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2010-02-22nptl/headers: Convert the makefile targets into variables.Khem Raj
* Introduce pregen-headers-y which is list of generated headers during the build and add this to pregen target in top level makefile. Also add nptl_headers, nptl_arch_headers, nptl_linux_headers to this if compiling with nptl. * Replace pthread_pregen var with pregen-headers-y. * Make nptl_headers, nptl_arch_headers, nptl_linux_headers variables instead of sub targets. Signed-off-by: Khem Raj <raj.khem@gmail.com>
2010-02-17Fix nptl build for mipsKhem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2010-02-11mips/sysdep.h: Unify mips sysdep.hKhem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com>
2010-02-09nptl: sysdep headers update for i386, mips and x86_64Carmelo Amoroso
Update the arch specific sysdep headers to include the common header under libc/sysdeps/linux/common instead of libpthread/nptl/sysdeps/generic. Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
2010-01-25mips/dl-tls.h: Adjust TLS_TPREL_VALUE and TLS_DTPREL_VALUEKhem Raj
* Symbol values are passed in directly into these macros instead of the symbol structure. Signed-off-by: Khem Raj <raj.khem@gmail.com>
2009-12-11Revert "nptl: make build depend directly on nptl headers"Austin Foxley
This reverts commit 641e7e36ad0a9b2899b04f256c5b243ada7da279. Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2009-12-09nptl: make build depend directly on nptl headersAustin Foxley
gets rid of nptl_headers,nptl_arch_headers,nptl_linux_headers targets also, clean up extra slashes in i386/sparc and unify the implementation of nptl header generation between all archs Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2009-10-17whitespace fixesAustin Foxley
Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2009-10-17libpthread/nptl: core of the "Native Posix Threading Library" for uClibcAustin Foxley
targetting arm,sh,i386,mips,sparc for now Signed-off-by: Austin Foxley <austinf@cetoncorp.com>
2005-05-20Back out nptl changes, which for now will be done in branches/uClibc-nptlEric Andersen
2005-05-07Import in NPTL code from glibc. For further information please"Steven J. Hill"
consult the 'README.NPTL' file.