Why stack-based VM? Why not queue-based VM?
问题 As I investigated, there are 2 major ways to implement process VM: stack-based, such as JVM, CLR, etc. or register-based, such as Lua, Dalvik, etc. Register-based approach mimics the architecture of physical processors. But for the stack-based approach, there are many other data structures. I think which approach to choose mainly depends on how we want to store/fetch operands. So why choose stack? How about queue-based VM? Or other options such as linked list? 回答1: StackOverflow is really not