On Linux there's a stub subroutine that does exactly that: __i686.get_pc_thunk.<reg>.
Here's the entire subroutine:
__i686.get_pc_thunk.bx:
MOV EBX, DWORD PTR [ESP]
RET
Yup, that's all. If you compile with gcc -m32 -fPIC, you'll see a call to that thunk whenever a function accesses GOT or other relocatable symbols.