Skip to content

Commit 8ae0694

Browse files
committed
Remove #[macro_use] extern crate tracing from rustc_codegen_ssa.
1 parent 8e94226 commit 8ae0694

File tree

19 files changed

+24
-8
lines changed

19 files changed

+24
-8
lines changed

compiler/rustc_codegen_ssa/src/assert_module_sources.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ use rustc_span::{Span, Symbol};
3737
use std::borrow::Cow;
3838
use std::fmt;
3939
use thin_vec::ThinVec;
40+
use tracing::debug;
4041

4142
#[allow(missing_docs)]
4243
pub fn assert_module_sources(tcx: TyCtxt<'_>, set_reuse: &dyn Fn(&mut CguReuseTracker)) {

compiler/rustc_codegen_ssa/src/back/link.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ use std::ops::Deref;
5252
use std::path::{Path, PathBuf};
5353
use std::process::{ExitStatus, Output, Stdio};
5454
use std::{env, fmt, fs, io, mem, str};
55+
use tracing::{debug, info, warn};
5556

5657
pub fn ensure_removed(dcx: &DiagCtxt, path: &Path) {
5758
if let Err(e) = fs::remove_file(path) {

compiler/rustc_codegen_ssa/src/back/linker.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ use rustc_session::Session;
2222
use rustc_target::spec::{Cc, LinkOutputKind, LinkerFlavor, Lld};
2323

2424
use cc::windows_registry;
25+
use tracing::{debug, warn};
2526

2627
/// Disables non-English messages from localized linkers.
2728
/// Such messages may cause issues with text encoding on Windows (#35785)

compiler/rustc_codegen_ssa/src/back/rpath.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ use rustc_data_structures::fx::FxHashSet;
33
use rustc_fs_util::try_canonicalize;
44
use std::ffi::OsString;
55
use std::path::{Path, PathBuf};
6+
use tracing::debug;
67

78
pub struct RPathConfig<'a> {
89
pub libs: &'a [&'a Path],

compiler/rustc_codegen_ssa/src/back/symbol_export.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ use rustc_middle::ty::{GenericArgKind, GenericArgsRef};
1818
use rustc_middle::util::Providers;
1919
use rustc_session::config::{CrateType, OomStrategy};
2020
use rustc_target::spec::{SanitizerSet, TlsModel};
21+
use tracing::debug;
2122

2223
pub fn threshold(tcx: TyCtxt<'_>) -> SymbolExportLevel {
2324
crates_export_threshold(tcx.crate_types())

compiler/rustc_codegen_ssa/src/back/write.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ use std::str;
4949
use std::sync::mpsc::{channel, Receiver, Sender};
5050
use std::sync::Arc;
5151
use std::thread;
52+
use tracing::debug;
5253

5354
const PRE_LTO_BC_EXT: &str = "pre-lto.bc";
5455

compiler/rustc_codegen_ssa/src/base.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ use std::collections::BTreeSet;
4545
use std::time::{Duration, Instant};
4646

4747
use itertools::Itertools;
48+
use tracing::{debug, info};
4849

4950
pub fn bin_op_to_icmp_predicate(op: BinOp, signed: bool) -> IntPredicate {
5051
match op {

compiler/rustc_codegen_ssa/src/lib.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,6 @@
1515
//! The backend-agnostic functions of this crate use functions defined in various traits that
1616
//! have to be implemented by each backend.
1717
18-
#[macro_use]
19-
extern crate tracing;
20-
2118
use rustc_ast as ast;
2219
use rustc_data_structures::fx::FxHashSet;
2320
use rustc_data_structures::fx::FxIndexMap;

compiler/rustc_codegen_ssa/src/meth.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ use rustc_middle::ty::{self, GenericArgKind, Ty};
55
use rustc_session::config::Lto;
66
use rustc_symbol_mangling::typeid_for_trait_ref;
77
use rustc_target::abi::call::FnAbi;
8+
use tracing::{debug, instrument};
89

910
#[derive(Copy, Clone, Debug)]
1011
pub struct VirtualIndex(u64);

compiler/rustc_codegen_ssa/src/mir/analyze.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ use rustc_middle::mir::visit::{MutatingUseContext, NonMutatingUseContext, PlaceC
1111
use rustc_middle::mir::{self, DefLocation, Location, TerminatorKind};
1212
use rustc_middle::ty::layout::{HasTyCtxt, LayoutOf};
1313
use rustc_middle::{bug, span_bug};
14+
use tracing::debug;
1415

1516
pub fn non_ssa_locals<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>>(
1617
fx: &FunctionCx<'a, 'tcx, Bx>,

0 commit comments

Comments
 (0)