rust/compiler/rustc_driver
Ralf Jung 6a8cdbd285
Rollup merge of #76474 - bjorn3:driver_selected_codegen, r=oli-obk
Add option to pass a custom codegen backend from a driver

This allows the driver to pass information to the codegen backend. For example the headcrab debugger may in the future want to use cg_clif to JIT code to be injected in the debuggee. This would PR make it possible to tell cg_clif which symbol can be found at which address and to tell it to inject the JITed code into the right process.

This PR may also help with https://github.com/rust-lang/miri/pull/1540 by allowing miri to provide a codegen backend that only emits metadata and doesn't perform any codegen.

cc @nbaksalyar (headcrab)
cc @RalfJung (miri)
2020-09-28 18:39:40 +02:00
..
src Rollup merge of #76474 - bjorn3:driver_selected_codegen, r=oli-obk 2020-09-28 18:39:40 +02:00
Cargo.toml just max_level_info 2020-09-11 09:37:51 -07:00
README.md

The driver crate is effectively the "main" function for the rust compiler. It orchestrates the compilation process and "knits together" the code from the other crates within rustc. This crate itself does not contain any of the "main logic" of the compiler (though it does have some code related to pretty printing or other minor compiler options).

For more information about how the driver works, see the rustc dev guide.