Stack Frame

Noun · Development

Definitions

  1. A contiguous block of memory on the call stack created each time a function is invoked, containing the function's local variables, saved registers, the return address, and the arguments passed to the function. When the function returns, its frame is popped and the memory is reclaimed.

    In plain English: A chunk of memory created each time a function is called, holding its local data, that disappears when the function finishes.

    Example: "The debugger shows 47 stack frames deep — that's our recursion going way too far before hitting the base case."

Related Terms