0

Title. Since you can enable escape analysis, there should also be an opcode that uses stack allocation instead of heap, right? Or how would that work?

Olle Härstedt
  • 3,799
  • 1
  • 24
  • 57
  • I don't know about the PHP VM, but escape analysis does not require that the entire object gets stack allocated. The compiler could simply output bytecode that doesn't create the entire object at all, instead only directly allocating the members that are actually used – UnholySheep Aug 30 '22 at 19:41
  • @UnholySheep That is true, I guess. Maybe someone could shed some light on that as well. :) – Olle Härstedt Aug 30 '22 at 20:02

0 Answers0