1 .text 2 .globl foo 3 .type foo, @function 4foo: 5 push %ebx 6 movl __GOTT_BASE__, %ebx 7 movl __GOTT_INDEX__(%ecx), %ebx 8 movl x@GOT(%ebx), %eax 9 incl (%eax) 10 call slocal@plt 11 call sglobal@plt 12 call sexternal@plt 13 pop %ebx 14 ret 15 .size foo, .-foo 16 17 .type slocal, @function 18slocal: 19 ret 20 .size slocal, .-slocal 21 22 .globl sglobal 23 .type sglobal, @function 24sglobal: 25 ret 26 .size sglobal, .-sglobal 27 28 .data 29 .4byte slocal 30 31 .comm x,4,4 32