Stuck with program flow and freezing programm

What happens when a function is called? Arguments are, usually, passed by value. How does that happen? The arguments are pushed onto the stack. What happens when the stack meets the heap? Bad things.