diff options
| author | bjorn3 <17426603+bjorn3@users.noreply.github.com> | 2024-12-19 13:53:18 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-12-19 13:53:18 +0100 |
| commit | da415e17c80cd2d79c50ceb66148fa9a4561321c (patch) | |
| tree | 63c83c60f1d534f36dadf4f95742aceabc8f1a07 | |
| parent | 53bbef8305877fd32d0358501fd6fc34a9e33360 (diff) | |
| parent | b046e322628b2a280355e3e2e2472d6b37f926fc (diff) | |
| download | rust-da415e17c80cd2d79c50ceb66148fa9a4561321c.tar.gz rust-da415e17c80cd2d79c50ceb66148fa9a4561321c.zip | |
Merge pull request #1550 from jyn514/logging
hook up tracing to cg_cranelift
| -rw-r--r-- | src/lib.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lib.rs b/src/lib.rs index c38ef82e5b8..dc5d80e7a34 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -27,6 +27,8 @@ extern crate rustc_metadata; extern crate rustc_session; extern crate rustc_span; extern crate rustc_target; +#[macro_use] +extern crate tracing; // This prevents duplicating functions and statics that are already part of the host rustc process. #[allow(unused_extern_crates)] @@ -208,6 +210,7 @@ impl CodegenBackend for CraneliftCodegenBackend { need_metadata_module: bool, ) -> Box<dyn Any> { tcx.dcx().abort_if_errors(); + info!("codegen crate {}", tcx.crate_name(LOCAL_CRATE)); let config = self.config.clone().unwrap_or_else(|| { BackendConfig::from_opts(&tcx.sess.opts.cg.llvm_args) .unwrap_or_else(|err| tcx.sess.dcx().fatal(err)) |
