1 .text 2 .type implementation1, @function 3 implementation1: 4 movl $1, %eax 5 ret 6 .size implementation1, .-implementation1 7 .type implementation2, @function 8 implementation2: 9 movl $2, %eax 10 ret 11 .size implementation2, .-implementation2 12 .type resolver2, @function 13 resolver2: 14 movl $implementation2, %eax 15 ret 16 .size resolver2, .-resolver2 17 .type func2, @gnu_indirect_function 18 .set func2,resolver2 19 .type resolver1, @function 20 resolver1: 21 movl $implementation1, %eax 22 ret 23 .size resolver1, .-resolver1 24 .globl func1 25 .type func1, @gnu_indirect_function 26 .set func1,resolver1 27 .globl get_func2 28 .type get_func2, @function 29 get_func2: 30 movl func2@GOT, %eax 31 ret 32 .size get_func2, .-get_func2 33 .globl call_func2 34 .type call_func2, @function 35 call_func2: 36 jmp *func2@GOT 37 .size call_func2, .-call_func2 38 .globl func2_p 39 #ifdef CHECK_PLT 40 .section .rodata,"a",@progbits 41 #else 42 .section .data.rel,"aw",@progbits 43 #endif 44 .align 4 45 .type func2_p, @object 46 .size func2_p, 4 47 func2_p: 48 .long func2 49 .section .note.GNU-stack,"",@progbits 50