mirror of
git://git.musl-libc.org/musl
synced 2025-03-05 03:07:29 +00:00
make __init_tp function static when static linking
this slightly reduces the code size cost of TLS/thread-pointer for static linking since __init_tp can be inlined into its only caller and removed. this is analogous to the handling of __init_libc in __libc_start_main, where the function only has external linkage when it needs to be called from the dynamic linker.
This commit is contained in:
parent
f109781c16
commit
5f51d52915
3
src/env/__init_tls.c
vendored
3
src/env/__init_tls.c
vendored
@ -8,6 +8,9 @@
|
||||
#include "atomic.h"
|
||||
#include "syscall.h"
|
||||
|
||||
#ifndef SHARED
|
||||
static
|
||||
#endif
|
||||
int __init_tp(void *p)
|
||||
{
|
||||
pthread_t td = p;
|
||||
|
Loading…
Reference in New Issue
Block a user