- hello.c
#include <stdio.h>
int hello(void)
{
printf("Hello, World!\n");
return 0;
}
int main(void)
{
hello();
return 0;
}
$ gcc -o hello hello.c
$ nm hello
0000000000600e40 d _DYNAMIC
0000000000600fe8 d _GLOBAL_OFFSET_TABLE_
0000000000400640 R _IO_stdin_used
w _Jv_RegisterClasses
0000000000600e20 d __CTOR_END__
0000000000600e18 d __CTOR_LIST__
0000000000600e30 D __DTOR_END__
0000000000600e28 d __DTOR_LIST__
0000000000400740 r __FRAME_END__
0000000000600e38 d __JCR_END__
0000000000600e38 d __JCR_LIST__
0000000000601020 A __bss_start
0000000000601010 D __data_start
00000000004005f0 t __do_global_ctors_aux
0000000000400490 t __do_global_dtors_aux
0000000000601018 D __dso_handle
w __gmon_start__
0000000000600e14 d __init_array_end
0000000000600e14 d __init_array_start
00000000004005e0 T __libc_csu_fini
0000000000400550 T __libc_csu_init
U __libc_start_main@@GLIBC_2.2.5
0000000000601020 A _edata
0000000000601030 A _end
0000000000400628 T _fini
00000000004003f0 T _init
0000000000400638 t _real_fini
0000000000400440 T _start
000000000040046c t call_gmon_start
0000000000601020 b completed.5890
0000000000601010 W data_start
0000000000601028 b dtor_idx.5892
0000000000400500 t frame_dummy
0000000000400524 T hello
0000000000400539 T main
U puts@@GLIBC_2.2.5