Merge commit '81dc066758ec150b43822d4a0c84aae20fe10f40' into sync_cg_clif-2023-10-09
This commit is contained in:
@@ -1,10 +1,9 @@
|
||||
//! Write the debuginfo into an object file.
|
||||
|
||||
use cranelift_object::ObjectProduct;
|
||||
use rustc_data_structures::fx::FxHashMap;
|
||||
|
||||
use gimli::write::{Address, AttributeValue, EndianVec, Result, Sections, Writer};
|
||||
use gimli::{RunTimeEndian, SectionId};
|
||||
use rustc_data_structures::fx::FxHashMap;
|
||||
|
||||
use super::object::WriteDebugInfo;
|
||||
use super::DebugContext;
|
||||
|
||||
@@ -3,20 +3,18 @@
|
||||
use std::ffi::OsStr;
|
||||
use std::path::{Component, Path};
|
||||
|
||||
use crate::debuginfo::FunctionDebugContext;
|
||||
use crate::prelude::*;
|
||||
|
||||
use cranelift_codegen::binemit::CodeOffset;
|
||||
use cranelift_codegen::MachSrcLoc;
|
||||
use gimli::write::{
|
||||
Address, AttributeValue, FileId, FileInfo, LineProgram, LineString, LineStringTable,
|
||||
};
|
||||
use rustc_data_structures::sync::Lrc;
|
||||
use rustc_span::{
|
||||
FileName, Pos, SourceFile, SourceFileAndLine, SourceFileHash, SourceFileHashAlgorithm,
|
||||
};
|
||||
|
||||
use cranelift_codegen::binemit::CodeOffset;
|
||||
use cranelift_codegen::MachSrcLoc;
|
||||
|
||||
use gimli::write::{
|
||||
Address, AttributeValue, FileId, FileInfo, LineProgram, LineString, LineStringTable,
|
||||
};
|
||||
use crate::debuginfo::FunctionDebugContext;
|
||||
use crate::prelude::*;
|
||||
|
||||
// OPTIMIZATION: It is cheaper to do this in one pass than using `.parent()` and `.file_name()`.
|
||||
fn split_path_dir_and_file(path: &Path) -> (&Path, &OsStr) {
|
||||
|
||||
@@ -5,11 +5,8 @@ mod line_info;
|
||||
mod object;
|
||||
mod unwind;
|
||||
|
||||
use crate::prelude::*;
|
||||
|
||||
use cranelift_codegen::ir::Endianness;
|
||||
use cranelift_codegen::isa::TargetIsa;
|
||||
|
||||
use gimli::write::{
|
||||
Address, AttributeValue, DwarfUnit, FileId, LineProgram, LineString, Range, RangeList,
|
||||
UnitEntryId,
|
||||
@@ -17,8 +14,9 @@ use gimli::write::{
|
||||
use gimli::{Encoding, Format, LineEncoding, RunTimeEndian};
|
||||
use indexmap::IndexSet;
|
||||
|
||||
pub(crate) use emit::{DebugReloc, DebugRelocName};
|
||||
pub(crate) use unwind::UnwindContext;
|
||||
pub(crate) use self::emit::{DebugReloc, DebugRelocName};
|
||||
pub(crate) use self::unwind::UnwindContext;
|
||||
use crate::prelude::*;
|
||||
|
||||
pub(crate) fn producer() -> String {
|
||||
format!(
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
use rustc_data_structures::fx::FxHashMap;
|
||||
|
||||
use cranelift_module::FuncId;
|
||||
use cranelift_object::ObjectProduct;
|
||||
|
||||
use gimli::SectionId;
|
||||
use object::write::{Relocation, StandardSegment};
|
||||
use object::{RelocationEncoding, SectionKind};
|
||||
|
||||
use gimli::SectionId;
|
||||
use rustc_data_structures::fx::FxHashMap;
|
||||
|
||||
use crate::debuginfo::{DebugReloc, DebugRelocName};
|
||||
|
||||
|
||||
@@ -1,15 +1,13 @@
|
||||
//! Unwind info generation (`.eh_frame`)
|
||||
|
||||
use crate::prelude::*;
|
||||
|
||||
use cranelift_codegen::ir::Endianness;
|
||||
use cranelift_codegen::isa::{unwind::UnwindInfo, TargetIsa};
|
||||
|
||||
use cranelift_object::ObjectProduct;
|
||||
use gimli::write::{Address, CieId, EhFrame, FrameTable, Section};
|
||||
use gimli::RunTimeEndian;
|
||||
|
||||
use super::object::WriteDebugInfo;
|
||||
use crate::prelude::*;
|
||||
|
||||
pub(crate) struct UnwindContext {
|
||||
endian: RunTimeEndian,
|
||||
|
||||
Reference in New Issue
Block a user