I recently stumbled upon <this diagram of compiler...
# compiler
p
I recently stumbled upon this diagram of compiler architecture, so I thought I'll share a diagram of declared dependencies between lowerings, see the thread (in this particular case, it's for JS IR backend). It's a part of working on Python backend (https://github.com/krzema12/kotlin-python, #python). It can get out of date quickly, so long-term it would be best to have it auto-generated. The code responsible for generating it is for now here in a GitHub issue. Should be easy to adapt for JVM or any other backend
👏 3
m
If you just extracted those from `prerequisite`parameter of `makeLoweringPhase`declarations, then I assume this map is probably much incomplete as it is impossible to mark and maintain all the dependencies (including optimization ones) of a particular phase. I guess these are just some most obvious ones that someone felt like it's important to specify, but generally phases relay on the global ordering. Prove me wrong.
p
true, implicit dependencies exist in the global ordering and the true value of this diagram is questionable