: static (), () .
CPU. - , . , ( 8 32 , ).
, . , 1-4 .
, , . , ; , . , , , , . , , , .
- . , , . , , , , , .
, . , , . , , . , .:)
: :
Register variables are allocated by the compiler, so there is no runtime overhead. The code will simply put the value into the register as soon as the value is generated.
Stack variables are allocated by your program at runtime. Typically, when a function is called, the first thing it will do is reserve enough stack space for all of its local variables. Thus, there is no variable cost.
source
share