On this page : http://www.scs.stanford.edu/histar/src/pkg/uclibc/libc/sysdeps/linux/x86_64/sigaction.c
I see these two lines :
extern void restore_rt (void) asm ("__restore_rt") attribute_hidden;
extern void restore (void) asm ("__restore") attribute_hidden;
What is this syntax? Is it setting up restore_rt
to be a function that has inline asm("__restore_rt")
as its body?
Thanks!
Using asm
in a function declaration is a GCC extension (also supported by Clang/LLVM) called asm-label. It is setting the assembler and linker known name of the function.
BTW, in your code attribute_hidden
is probably a macro for some function attribute, probably __attribute__ ((visibility ("hidden")))
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With