Where is rust compiler start point?

I know this question may be stupidly, but it is interesting for me to know usually from where rustc starts compiling a rust code. in other word I'm looking for something like a main function in compiler source code.
Where is it located in rustc source?

The main function is here, but that quickly moves to rustc_driver.

1 Like

Oh, thank you!

The rustc_driver crate is also used by rustdoc and clippy-driver, for example.

1 Like