Remove #[macro_use] extern crate tracing from rustc_codegen_llvm.

This commit is contained in:
Nicholas Nethercote 2024-05-22 14:50:24 +10:00
parent 9287aede31
commit 8e94226e61
19 changed files with 18 additions and 4 deletions

View File

@ -16,6 +16,7 @@
use rustc_span::{Pos, Span};
use rustc_target::abi::*;
use rustc_target::asm::*;
use tracing::debug;
use libc::{c_char, c_uint};
use smallvec::SmallVec;

View File

@ -18,6 +18,7 @@
get_native_object_symbols, try_extract_macho_fat_archive, ArArchiveBuilder,
ArchiveBuildFailure, ArchiveBuilder, ArchiveBuilderBuilder, UnknownArchiveKind,
};
use tracing::trace;
use rustc_session::cstore::DllImport;
use rustc_session::Session;

View File

@ -20,6 +20,7 @@
use rustc_middle::dep_graph::WorkProduct;
use rustc_middle::middle::exported_symbols::{SymbolExportInfo, SymbolExportLevel};
use rustc_session::config::{self, CrateType, Lto};
use tracing::{debug, info};
use std::collections::BTreeMap;
use std::ffi::{CStr, CString};

View File

@ -35,6 +35,7 @@
use rustc_span::symbol::sym;
use rustc_span::InnerSpan;
use rustc_target::spec::{CodeModel, RelocModel, SanitizerSet, SplitDebuginfo, TlsModel};
use tracing::debug;
use crate::llvm::diagnostic::OptimizationDiagnosticKind;
use libc::{c_char, c_int, c_void, size_t};

View File

@ -30,6 +30,7 @@
use std::iter;
use std::ops::Deref;
use std::ptr;
use tracing::{debug, instrument};
// All Builders must have an llfn associated with them
#[must_use]

View File

@ -12,6 +12,7 @@
use rustc_middle::ty::layout::{FnAbiOf, HasTyCtxt};
use rustc_middle::ty::{self, Instance, TypeVisitableExt};
use tracing::debug;
/// Codegens a reference to a fn/method item, monomorphizing and
/// inlining as it goes.

View File

@ -19,6 +19,7 @@
use libc::{c_char, c_uint};
use std::fmt::Write;
use tracing::debug;
/*
* A note on nomenclature of linking: "extern", "foreign", and "upcall".

View File

@ -25,6 +25,7 @@
Align, AlignFromBytesError, HasDataLayout, Primitive, Scalar, Size, WrappingRange,
};
use std::ops::Range;
use tracing::{debug, instrument, trace};
pub fn const_alloc_to_llvm<'ll>(
cx: &CodegenCx<'ll, '_>,

View File

@ -9,6 +9,7 @@
};
use rustc_middle::ty::Instance;
use rustc_span::Symbol;
use tracing::{debug, instrument};
/// Holds all of the coverage mapping data associated with a function instance,
/// collected during traversal of `Coverage` statements in the function's MIR.

View File

@ -14,6 +14,7 @@
use rustc_middle::ty::{self, TyCtxt};
use rustc_span::def_id::DefIdSet;
use rustc_span::Symbol;
use tracing::debug;
/// Generates and exports the Coverage Map.
///

View File

@ -17,6 +17,7 @@
use rustc_middle::ty::layout::HasTyCtxt;
use rustc_middle::ty::Instance;
use rustc_target::abi::{Align, Size};
use tracing::{debug, instrument};
use std::cell::RefCell;

View File

@ -41,6 +41,7 @@
use rustc_target::abi::{Align, Size};
use rustc_target::spec::DebuginfoKind;
use smallvec::smallvec;
use tracing::{debug, instrument};
use libc::{c_char, c_longlong, c_uint};
use std::borrow::Cow;

View File

@ -42,6 +42,7 @@
use std::cell::RefCell;
use std::iter;
use std::ops::Range;
use tracing::debug;
mod create_scope_map;
pub mod gdb;

View File

@ -6,7 +6,7 @@
use rustc_hir::def_id::DefId;
use rustc_middle::ty::layout::{HasParamEnv, LayoutOf};
use rustc_middle::ty::{self, Ty};
use trace;
use tracing::trace;
use crate::common::CodegenCx;
use crate::llvm;

View File

@ -24,6 +24,7 @@
use rustc_middle::ty::{Instance, Ty};
use rustc_sanitizers::{cfi, kcfi};
use smallvec::SmallVec;
use tracing::debug;
/// Declare a function.
///

View File

@ -21,6 +21,7 @@
use rustc_span::{sym, Span, Symbol};
use rustc_target::abi::{self, Align, Float, HasDataLayout, Primitive, Size};
use rustc_target::spec::{HasTargetSpec, PanicStrategy};
use tracing::debug;
use std::cmp::Ordering;

View File

@ -15,9 +15,6 @@
#![feature(let_chains)]
#![feature(impl_trait_in_assoc_type)]
#[macro_use]
extern crate tracing;
use back::owned_target_machine::OwnedTargetMachine;
use back::write::{create_informational_target_machine, create_target_machine};

View File

@ -13,6 +13,7 @@
use rustc_middle::ty::{self, Instance, TypeVisitableExt};
use rustc_session::config::CrateType;
use rustc_target::spec::RelocModel;
use tracing::debug;
impl<'tcx> PreDefineMethods<'tcx> for CodegenCx<'_, 'tcx> {
fn predefine_static(

View File

@ -8,6 +8,7 @@
use rustc_target::abi::{Abi, Align, FieldsShape};
use rustc_target::abi::{Float, Int, Pointer};
use rustc_target::abi::{Scalar, Size, Variants};
use tracing::debug;
use std::fmt::Write;