Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 19 additions & 12 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ codegen-units = 256

[dependencies]
cpp_demangle = {version = "0.5", optional = true}
gimli = {version = "0.32", optional = true}
gimli = {version = "0.33", optional = true}
libc = "0.2"
memmap2 = {version = "0.9", default-features = false}
miniz_oxide = {version = "0.9", default-features = false, features = ["simd", "with-alloc"], optional = true}
Expand All @@ -187,7 +187,7 @@ zstd = {version = "0.13", default-features = false, optional = true}
[dev-dependencies]
# For performance comparison; pinned, because we use #[doc(hidden)]
# APIs.
addr2line = "=0.25.1"
addr2line = "=0.26.0"
anyhow = "1.0"
blazesym-dev = {path = "dev", features = ["generate-unit-test-files"]}
criterion = {version = "0.8", default-features = false, features = ["rayon", "cargo_bench_support"]}
Expand Down
6 changes: 3 additions & 3 deletions src/dwarf/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ fn name_entry<'dwarf>(
let abbrev = if let Some(abbrev) = entries.read_abbreviation()? {
abbrev
} else {
return Err(gimli::Error::NoEntryAtGivenOffset)
return Err(gimli::Error::NoEntryAtGivenOffset(offset.0 as u64))
};

let mut name = None;
Expand Down Expand Up @@ -112,7 +112,7 @@ fn name_attr<'dwarf>(

struct InlinedState<'call, 'dwarf> {
// Mutable fields.
entries: gimli::EntriesRaw<'call, 'call, R<'dwarf>>,
entries: gimli::EntriesRaw<'call, R<'dwarf>>,
functions: Vec<InlinedFunction<'dwarf>>,
addresses: Vec<InlinedFunctionAddress>,

Expand Down Expand Up @@ -395,7 +395,7 @@ impl<'dwarf> Function<'dwarf> {


fn skip(
entries: &mut gimli::EntriesRaw<'_, '_, R<'dwarf>>,
entries: &mut gimli::EntriesRaw<'_, R<'dwarf>>,
abbrev: &gimli::Abbreviation,
depth: isize,
) -> Result<(), Error> {
Expand Down
6 changes: 3 additions & 3 deletions src/dwarf/units.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ impl<'dwarf> Units<'dwarf> {
let mut units = sections.units();
while let Some(header) = units.next()? {
let unit_id = res_units.len();
let offset = match header.offset().as_debug_info_offset() {
let offset = match header.offset().to_debug_info_offset(&header) {
Some(offset) => offset,
None => continue,
};
Expand Down Expand Up @@ -268,13 +268,13 @@ impl<'dwarf> Units<'dwarf> {
.binary_search_by_key(&offset.0, |unit| unit.offset().0)
{
// There is never a DIE at the unit offset or before the first unit.
Ok(_) | Err(0) => return Err(gimli::Error::NoEntryAtGivenOffset),
Ok(_) | Err(0) => return Err(gimli::Error::NoEntryAtGivenOffset(offset.0 as u64)),
Err(i) => self.units[i - 1].dw_unit(),
};

let unit_offset = offset
.to_unit_offset(&unit.header)
.ok_or(gimli::Error::NoEntryAtGivenOffset)?;
.ok_or(gimli::Error::NoEntryAtGivenOffset(offset.0 as u64))?;
let unit = gimli::UnitRef::new(&self.dwarf, unit);
Ok((unit, unit_offset))
}
Expand Down
Loading