Lifetime cannot be arbitrary. Allocation in Data, BSS remains till the end of the program. Allocation in the heap remains until the program break is moved or that memory is reallocated. Same for the stack.
Consider the following example
int func(int n)
{
int x = n;
return x+x;
}
int main()
{
int x = 5;
x = func(x);
long* ptr = &x;
printf("Argument : %ld\n", *ptr);
printf("Return Address: %p\n", ptr[-3]);
}
When compiled under gcc-7 (Ubuntu 7.3.0-16ubuntu3) 7.3.0, gives the output
Argument : 10
Return Address: 0x80484db
Where the return address represents the address at which the execution resumes after returing from func.