When I started to port the code to ESP32S3 following the example of ESP32C3, I realized I had to read the code closely. Here are the notes along the way.

Where does the code get started on esp32?

Based on esp-idf, Toit (I like to pronounce it as tight) creates a new platform with a new programming language for developers.

For the code to start on the esp32 device, check all the files inside toolchains/esp32/. They contains all the building details for esp32. Inside its subfolder main, there is a toit.c. The function app_main() is the entry point. Inside toit_start() is called.