The EVM is a tiny stack machine that executes bytecode, not Solidity.

Solidity is just a compiler convenience.

If you understand:


1️⃣ The 4 execution data areas (core EVM model)

The EVM has four real working areas (ignore logs/code for now):

Area Lifetime Read Write Cost
Stack Per opcode Cheap
Memory Per transaction Medium (expands)
Calldata Per call Very cheap
Storage Persistent Very expensive

This distinction matters constantly in audits.


2️⃣ Stack: the EVM’s brain

Key facts: