Skip to content

Commit

Permalink
Auto merge of rust-lang#75187 - pawanbisht62:feature/incorporate-trac…
Browse files Browse the repository at this point in the history
…ing, r=oli-obk

Incorporated Tracing Crate in some libraries

Issue rust-lang#74747
  • Loading branch information
bors committed Aug 17, 2020
2 parents e8df0b8 + bab1588 commit 8d185ca
Show file tree
Hide file tree
Showing 24 changed files with 24 additions and 24 deletions.
2 changes: 1 addition & 1 deletion src/librustc_builtin_macros/Cargo.toml
Expand Up @@ -11,7 +11,7 @@ doctest = false

[dependencies]
rustc_parse_format = { path = "../librustc_parse_format" }
log = { package = "tracing", version = "0.1" }
tracing = "0.1"
rustc_ast_pretty = { path = "../librustc_ast_pretty" }
rustc_attr = { path = "../librustc_attr" }
rustc_data_structures = { path = "../librustc_data_structures" }
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_builtin_macros/test.rs
Expand Up @@ -299,7 +299,7 @@ pub fn expand_test_or_bench(
// extern crate test
let test_extern = cx.item(sp, test_id, vec![], ast::ItemKind::ExternCrate(None));

log::debug!("synthetic test item:\n{}\n", pprust::item_to_string(&test_const));
tracing::debug!("synthetic test item:\n{}\n", pprust::item_to_string(&test_const));

vec![
// Access to libtest under a hygienic name
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_builtin_macros/test_harness.rs
@@ -1,6 +1,5 @@
// Code that generates a test runner to run all the tests in a crate

use log::debug;
use rustc_ast::ast;
use rustc_ast::attr;
use rustc_ast::entry::EntryPointType;
Expand All @@ -16,6 +15,7 @@ use rustc_span::symbol::{sym, Ident, Symbol};
use rustc_span::{Span, DUMMY_SP};
use rustc_target::spec::PanicStrategy;
use smallvec::{smallvec, SmallVec};
use tracing::debug;

use std::{iter, mem};

Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/Cargo.toml
Expand Up @@ -15,7 +15,7 @@ bitflags = "1.0"
flate2 = "1.0"
libc = "0.2"
measureme = "0.7.1"
log = { package = "tracing", version = "0.1" }
tracing = "0.1"
rustc_middle = { path = "../librustc_middle" }
rustc-demangle = "0.1"
rustc_attr = { path = "../librustc_attr" }
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/asm.rs
Expand Up @@ -19,7 +19,7 @@ use rustc_target::abi::*;
use rustc_target::asm::*;

use libc::{c_char, c_uint};
use log::debug;
use tracing::debug;

impl AsmBuilderMethods<'tcx> for Builder<'a, 'll, 'tcx> {
fn codegen_llvm_inline_asm(
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/back/lto.rs
Expand Up @@ -4,7 +4,6 @@ use crate::back::write::{
use crate::llvm::archive_ro::ArchiveRO;
use crate::llvm::{self, False, True};
use crate::{LlvmCodegenBackend, ModuleLlvm};
use log::{debug, info};
use rustc_codegen_ssa::back::lto::{LtoModuleCodegen, SerializedModule, ThinModule, ThinShared};
use rustc_codegen_ssa::back::symbol_export;
use rustc_codegen_ssa::back::write::{CodegenContext, FatLTOInput, ModuleConfig};
Expand All @@ -18,6 +17,7 @@ use rustc_middle::dep_graph::WorkProduct;
use rustc_middle::middle::exported_symbols::SymbolExportLevel;
use rustc_session::cgu_reuse_tracker::CguReuse;
use rustc_session::config::{self, CrateType, Lto};
use tracing::{debug, info};

use std::ffi::{CStr, CString};
use std::fs::File;
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/back/write.rs
Expand Up @@ -11,7 +11,6 @@ use crate::llvm_util;
use crate::type_::Type;
use crate::LlvmCodegenBackend;
use crate::ModuleLlvm;
use log::debug;
use rustc_codegen_ssa::back::write::{BitcodeSection, CodegenContext, EmitObj, ModuleConfig};
use rustc_codegen_ssa::traits::*;
use rustc_codegen_ssa::{CompiledModule, ModuleCodegen};
Expand All @@ -26,6 +25,7 @@ use rustc_session::Session;
use rustc_span::symbol::sym;
use rustc_span::InnerSpan;
use rustc_target::spec::{CodeModel, RelocModel};
use tracing::debug;

use libc::{c_char, c_int, c_uint, c_void, size_t};
use std::ffi::CString;
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/builder.rs
Expand Up @@ -6,7 +6,6 @@ use crate::type_::Type;
use crate::type_of::LayoutLlvmExt;
use crate::value::Value;
use libc::{c_char, c_uint};
use log::debug;
use rustc_codegen_ssa::base::to_immediate;
use rustc_codegen_ssa::common::{IntPredicate, RealPredicate, TypeKind};
use rustc_codegen_ssa::mir::operand::{OperandRef, OperandValue};
Expand All @@ -26,6 +25,7 @@ use std::ffi::CStr;
use std::iter::TrustedLen;
use std::ops::{Deref, Range};
use std::ptr;
use tracing::debug;

// All Builders must have an llfn associated with them
#[must_use]
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/callee.rs
Expand Up @@ -9,8 +9,8 @@ use crate::attributes;
use crate::context::CodegenCx;
use crate::llvm;
use crate::value::Value;
use log::debug;
use rustc_codegen_ssa::traits::*;
use tracing::debug;

use rustc_middle::ty::layout::{FnAbiExt, HasTyCtxt};
use rustc_middle::ty::{self, Instance, TypeFoldable};
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/common.rs
Expand Up @@ -19,7 +19,7 @@ use rustc_span::symbol::Symbol;
use rustc_target::abi::{self, AddressSpace, HasDataLayout, LayoutOf, Pointer, Size};

use libc::{c_char, c_uint};
use log::debug;
use tracing::debug;

/*
* A note on nomenclature of linking: "extern", "foreign", and "upcall".
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/consts.rs
Expand Up @@ -6,7 +6,6 @@ use crate::type_::Type;
use crate::type_of::LayoutLlvmExt;
use crate::value::Value;
use libc::c_uint;
use log::debug;
use rustc_codegen_ssa::traits::*;
use rustc_hir as hir;
use rustc_hir::def_id::DefId;
Expand All @@ -21,6 +20,7 @@ use rustc_middle::{bug, span_bug};
use rustc_span::symbol::sym;
use rustc_span::Span;
use rustc_target::abi::{AddressSpace, Align, HasDataLayout, LayoutOf, Primitive, Scalar, Size};
use tracing::debug;

use std::ffi::CStr;

Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/coverageinfo/mapgen.rs
Expand Up @@ -3,11 +3,11 @@ use crate::coverageinfo;
use crate::llvm;

use llvm::coverageinfo::CounterMappingRegion;
use log::debug;
use rustc_codegen_ssa::coverageinfo::map::{Counter, CounterExpression, Region};
use rustc_codegen_ssa::traits::{BaseTypeMethods, ConstMethods};
use rustc_data_structures::fx::FxIndexSet;
use rustc_llvm::RustString;
use tracing::debug;

use std::ffi::CString;

Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/coverageinfo/mod.rs
Expand Up @@ -5,14 +5,14 @@ use crate::common::CodegenCx;

use libc::c_uint;
use llvm::coverageinfo::CounterMappingRegion;
use log::debug;
use rustc_codegen_ssa::coverageinfo::map::{CounterExpression, ExprKind, FunctionCoverage, Region};
use rustc_codegen_ssa::traits::{
BaseTypeMethods, CoverageInfoBuilderMethods, CoverageInfoMethods, MiscMethods, StaticMethods,
};
use rustc_data_structures::fx::FxHashMap;
use rustc_llvm::RustString;
use rustc_middle::ty::Instance;
use tracing::debug;

use std::cell::RefCell;
use std::ffi::CString;
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/debuginfo/metadata.rs
Expand Up @@ -18,7 +18,6 @@ use crate::llvm::debuginfo::{
};
use crate::value::Value;

use log::debug;
use rustc_ast::ast;
use rustc_codegen_ssa::traits::*;
use rustc_data_structures::const_cstr;
Expand All @@ -43,6 +42,7 @@ use rustc_span::{self, SourceFile, SourceFileHash, Span};
use rustc_target::abi::{Abi, Align, HasDataLayout, Integer, LayoutOf, TagEncoding};
use rustc_target::abi::{Int, Pointer, F32, F64};
use rustc_target::abi::{Primitive, Size, VariantIdx, Variants};
use tracing::debug;

use libc::{c_longlong, c_uint};
use std::collections::hash_map::Entry;
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/debuginfo/mod.rs
Expand Up @@ -33,9 +33,9 @@ use rustc_span::{self, BytePos, Span};
use rustc_target::abi::{LayoutOf, Primitive, Size};

use libc::c_uint;
use log::debug;
use smallvec::SmallVec;
use std::cell::RefCell;
use tracing::debug;

mod create_scope_map;
pub mod gdb;
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/declare.rs
Expand Up @@ -18,9 +18,9 @@ use crate::llvm;
use crate::llvm::AttributePlace::Function;
use crate::type_::Type;
use crate::value::Value;
use log::debug;
use rustc_codegen_ssa::traits::*;
use rustc_middle::ty::Ty;
use tracing::debug;

/// Declare a function.
///
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/intrinsic.rs
Expand Up @@ -7,7 +7,7 @@ use crate::type_of::LayoutLlvmExt;
use crate::va_arg::emit_va_arg;
use crate::value::Value;

use log::debug;
use tracing::debug;

use rustc_ast::ast;
use rustc_codegen_ssa::base::{compare_simd_types, to_immediate, wants_msvc_seh};
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/metadata.rs
Expand Up @@ -4,10 +4,10 @@ use crate::llvm::{mk_section_iter, False, ObjectFile};
use rustc_middle::middle::cstore::MetadataLoader;
use rustc_target::spec::Target;

use log::debug;
use rustc_codegen_ssa::METADATA_FILENAME;
use rustc_data_structures::owning_ref::OwningRef;
use rustc_data_structures::rustc_erase_owner;
use tracing::debug;

use rustc_fs_util::path_to_c_string;
use std::path::Path;
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/mono_item.rs
Expand Up @@ -4,14 +4,14 @@ use crate::base;
use crate::context::CodegenCx;
use crate::llvm;
use crate::type_of::LayoutLlvmExt;
use log::debug;
use rustc_codegen_ssa::traits::*;
use rustc_hir::def_id::{DefId, LOCAL_CRATE};
pub use rustc_middle::mir::mono::MonoItem;
use rustc_middle::mir::mono::{Linkage, Visibility};
use rustc_middle::ty::layout::FnAbiExt;
use rustc_middle::ty::{self, Instance, TypeFoldable};
use rustc_target::abi::LayoutOf;
use tracing::debug;

impl PreDefineMethods<'tcx> for CodegenCx<'ll, 'tcx> {
fn predefine_static(
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_llvm/type_of.rs
@@ -1,7 +1,6 @@
use crate::abi::FnAbi;
use crate::common::*;
use crate::type_::Type;
use log::debug;
use rustc_codegen_ssa::traits::*;
use rustc_middle::bug;
use rustc_middle::ty::layout::{FnAbiExt, TyAndLayout};
Expand All @@ -10,6 +9,7 @@ use rustc_middle::ty::{self, Ty, TypeFoldable};
use rustc_target::abi::{Abi, AddressSpace, Align, FieldsShape};
use rustc_target::abi::{Int, Pointer, F32, F64};
use rustc_target::abi::{LayoutOf, PointeeInfo, Scalar, Size, TyAndLayoutMethods, Variants};
use tracing::debug;

use std::fmt::Write;

Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_ssa/Cargo.toml
Expand Up @@ -14,7 +14,7 @@ bitflags = "1.2.1"
cc = "1.0.1"
num_cpus = "1.0"
memmap = "0.7"
log = { package = "tracing", version = "0.1" }
tracing = "0.1"
libc = "0.2.50"
jobserver = "0.1.11"
tempfile = "3.1"
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_codegen_ssa/lib.rs
Expand Up @@ -19,7 +19,7 @@
#[macro_use]
extern crate rustc_macros;
#[macro_use]
extern crate log;
extern crate tracing;
#[macro_use]
extern crate rustc_middle;

Expand Down
2 changes: 1 addition & 1 deletion src/librustc_data_structures/Cargo.toml
Expand Up @@ -12,7 +12,7 @@ doctest = false
[dependencies]
ena = "0.14"
indexmap = "1.5.1"
log = { package = "tracing", version = "0.1" }
tracing = "0.1"
jobserver_crate = { version = "0.1.13", package = "jobserver" }
lazy_static = "1"
once_cell = { version = "1", features = ["parking_lot"] }
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_data_structures/lib.rs
Expand Up @@ -26,7 +26,7 @@
#![allow(rustc::default_hash_types)]

#[macro_use]
extern crate log;
extern crate tracing;
#[macro_use]
extern crate cfg_if;
#[macro_use]
Expand Down

0 comments on commit 8d185ca

Please sign in to comment.