does V8 uses stack and heap like the JVM? if so does it put primitives on the stack and objects on the heap?
null
undefined
true
false
Boolean.TRUE
Boolean.FALSE
V8 has two compilers: non-optimizing (aka full) and optimizing one:
Speaking of JVM: it can perform so called stack allocation and allocate a non-escaping object on the stack instead of the heap. A more generic optimization (scalar replacement) can sometimes completely eliminate allocation of non-escaping object and explode it into separate fields.
2.1m questions
2.1m answers
60 comments
57.0k users