Re: function call

k.mukkamala_at_gmail.com
Date: 05/23/05


Date: 23 May 2005 01:56:08 -0700

You can use the gcc function "void * __builtin_return_address (unsigned
int level)" function. The with level 0 it returns the address where the
function that used __builtin_return_address returns to. For e.g., f1()
called f2() and f3() and f3() called __builtin_return_address then with
level 0 it returns the address of the next instruction in f2() after
f3() call.

KIRAN