search for: __stderr_used

Displaying 4 results from an estimated 4 matches for "__stderr_used".

2013 Jan 09
0
[LLVMdev] [lld] ELF weak aliases
...it, and so as the ordinal too riht ? Couldnt follow how did the others move ? This is what I see with binutils/ld :- $cat 1.c #include "stdio_impl.h" static FILE *const dummy_file = 0; weak_alias(dummy_file, __stdin_used); weak_alias(dummy_file, __stdout_used); weak_alias(dummy_file, __stderr_used); $cat 2.c int __stdout_used = 10; $readelf -s 1.o | grep -E 'used|dummy_file' 6: 0000000000000000 8 OBJECT LOCAL DEFAULT 4 dummy_file 9: 0000000000000000 8 OBJECT WEAK DEFAULT 4 __stdin_used 10: 0000000000000000 8 OBJECT WEAK DEFAULT 4 __stdout_u...
2013 Jan 09
4
[LLVMdev] [lld] ELF weak aliases
...ge to hack around incorrect handling of ELF weak aliases. In musl __stdio_exit.c <http://git.musl-libc.org/cgit/musl/tree/src/stdio/__stdio_exit.c> we have: static FILE *const dummy_file = 0; weak_alias(dummy_file, __stdin_used); weak_alias(dummy_file, __stdout_used); weak_alias(dummy_file, __stderr_used); weak_alias(old, new) is defined as: extern __typeof(old) new __attribute__((weak, alias(#old))) This generates the following object file: mspencer at mspencer-vm:~/Projects/test$ objdump -st ../musl/src/stdio/__stdio_exit.o ../musl/src/stdio/__stdio_exit.o: file format elf64-x86-64 SYMBOL...
2013 Jan 09
2
[LLVMdev] [lld] ELF weak aliases
...quite sure what you mean here. > > This is what I see with binutils/ld :- > > $cat 1.c > #include "stdio_impl.h" > > static FILE *const dummy_file = 0; > weak_alias(dummy_file, __stdin_used); > weak_alias(dummy_file, __stdout_used); > weak_alias(dummy_file, __stderr_used); > > $cat 2.c > int __stdout_used = 10; > $readelf -s 1.o | grep -E 'used|dummy_file' > 6: 0000000000000000 8 OBJECT LOCAL DEFAULT 4 dummy_file > 9: 0000000000000000 8 OBJECT WEAK DEFAULT 4 __stdin_used > 10: 0000000000000000 8 OBJE...
2013 Jan 09
0
[LLVMdev] [lld] ELF weak aliases
...eak aliases. > > In musl __stdio_exit.c > <http://git.musl-libc.org/cgit/musl/tree/src/stdio/__stdio_exit.c> we > have: > > static FILE *const dummy_file = 0; > weak_alias(dummy_file, __stdin_used); > weak_alias(dummy_file, __stdout_used); > weak_alias(dummy_file, __stderr_used); > > weak_alias(old, new) is defined as: extern __typeof(old) new > __attribute__((weak, alias(#old))) > > This generates the following object file: > mspencer at mspencer-vm:~/Projects/test$ objdump -st > ../musl/src/stdio/__stdio_exit.o > > ../musl/src/stdio/__stdio...