GithubHelp home page GithubHelp logo

gimli-rs / addr2line Goto Github PK

View Code? Open in Web Editor NEW
264.0 9.0 56.0 4.28 MB

A cross-platform `addr2line` clone written in Rust, using `gimli`

Home Page: https://docs.rs/addr2line

License: Apache License 2.0

Rust 96.24% Shell 2.88% R 0.88%
addr2line debug-symbols rust symbolicate symbolication cross-platform

addr2line's People

Contributors

alexcrichton avatar atouchet avatar bjorn3 avatar cosmichorrordev avatar cuviper avatar danielocfb avatar dansnow avatar dependabot-support avatar diondokter avatar est31 avatar fitzgen avatar flyingcanoe avatar ignatenkobrain avatar ishitatsuyuki avatar jonhoo avatar jsgf avatar khuey avatar kornelski avatar koute avatar main-- avatar mstange avatar peamaeq avatar philipc avatar rreverser avatar sfackler avatar striezel avatar swatinem avatar tmplt avatar viveksjain avatar vlovich avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

addr2line's Issues

"Invalid ELF section header offset/size/alignment" panic

  1. Download zip archive with problematic elf file: 1.elf.zip
  2. Unpack it somewhere
  3. Using addr2line master branch, run cargo run --example=addr2line -- -e /path/to/1.elf 0x80

Expected output (as produced by addr2line from GNU binutils):
Z:\/1.c:1
I'm not sure why there are two slashes, but path and line number are correct.

Actual output:
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Error("Invalid ELF section header offset/size/alignment")', examples\addr2line.rs:156:17

Add location_iter api

For some use-cases it would be super helpful to be able to iterate over all units/frames or locations in the binary. This could be accomplished simply by exposing the Lines struct.

publish 0.6

0.5 pulls in old object, which uses old goblin 0.0.10; there's been many improvements since then!

Also there's too many goblins hanging out in my Cargo.lock now ;)

Slow find_frames on XUL.dSYM, in unit.parse_functions

I'm trying to get inline call stacks for around 60000 addresses from the Firefox-on-Mac XUL library, from a XUL.dSYM bundle. It takes 2 minutes. That's 2ms per address. Instruments profile

Doing the same on a Linux libxul.so takes 0.8ms per address, and for PDBs it takes 0.19ms per address.

It would be great if this could be made faster. Once the Firefox profiler supports displaying inline call stacks, I want to use this code to get the inline frame information for local builds, and it would be great to not regress symbolication times too much compared to the current state without inline callstacks.

Steps to reproduce:

git clone https://github.com/mstange/profiler-get-symbols/
cd profiler-get-symbols/
git checkout 8152ad4968d847763df3e79388150d87ab214c7e
cargo run -p benchmarks --release

Plan around 10-20min for the first run, because it is slow to compile and downloads large resources. Most importantly, this step creates big-benchmark-fixtures/macos-ci/XUL.dSYM.

Then run the following to run just the dSYM test (this is the command that obtains inline callstacks for 59736 addresses from XUL.dSYM):

cargo run --release -p query-api -- big-benchmark-fixtures/macos-ci/ /symbolicate/v6a1 @fixtures/requests/macos-ci-xul.json > /dev/null

Profiling in Instruments reveals that most of the time is spent in unit.parse_functions. It seems that if many addresses fall into the same unit (?) we might be doing a lot of duplicated work.

Screen Shot 2020-05-18 at 8 34 11 PM

Screen Shot 2020-05-18 at 8 38 10 PM

`cargo bench` is testing no-ops

Currently, get_test_addresses takes first 200 lines and then filters them out to take just functions.

Problem is, for the addr2line-release fixture nm doesn't return even a single function within first 200 lines, so get_test_addresses returns an empty vector, and benchmarks essentially test no-ops.

API flexibility

Prompted by @main--'s comment, here's a few API changes for consideration. The common theme is to make the API more flexible, and less centered on providing an addr2line clone. Note that more flexible may also mean more complicated, so this is a tradeoff. Some of these may be strawman proposals :)

  • Remove the with_functions option, and use a parameter to locate instead (or a different locate method). This allows the caller to decide when doing the locate, not when constructing the Mapping. This is possible because we lazily read the function information.

  • Remove the with_demangling option and stop doing demangling. This should be handled by the caller. Instead, we return a language value that the caller can use to determine how to demangle. This allows the caller to access both the mangled and demangled names if desired, and to implement their own caching of demangled names if required.

  • Remove the with_symbol_table option. The caller should be able to decide whether to use symbols for each query. The caller should also be able to get both debuginfo and symbol table information simultaneously. This may mean having two independent queries: one for debuginfo and one for the symbol table.

  • Make the object crate dependency optional. Instead, define a trait for the required object loader functionality. We can still implement this trait for object for convenience.

  • Avoid the memmap dependency. Using an OwningHandle to tie something to a memmap is a generic operation that has nothing to do with addr2line, and should be implemented elsewhere.

  • Add an endianity parameter to the mapping instead of using EndianDebugInfo. This allows the caller to decide if they only want to support NativeEndian, without incurring size or performance penalties.

Mapping libxul.so on Linux panics in xmas_elf::ElfFile::get_string due to bad slice

I'm not having any luck using addr2line to symbolicate a Firefox libxul.so on Linux.

My code:

extern crate addr2line;

fn main() {
    let mapping = addr2line::Options::default()
        .build(
            "/home/mstange/code/mozilla/obj-x86_64-pc-linux-gnu/dist/bin/libxul.so",
        ).expect("Mapping libxul.so failed");
    println!("0x33e4812: {:?}", mapping.locate(0x33e4812));
}

Output:

    Finished dev [unoptimized + debuginfo] target(s) in 0.0 secs
     Running `target/debug/addr2line-libxul`
thread 'main' panicked at 'slice index starts at 77309416265 but ends at 1434107856', /checkout/src/libcore/slice/mod.rs:741:4
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
             at /checkout/src/libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::_print
             at /checkout/src/libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at /checkout/src/libstd/sys_common/backtrace.rs:60
             at /checkout/src/libstd/panicking.rs:380
   3: std::panicking::default_hook
             at /checkout/src/libstd/panicking.rs:396
   4: std::panicking::rust_panic_with_hook
             at /checkout/src/libstd/panicking.rs:611
   5: std::panicking::begin_panic_new
             at /checkout/src/libstd/panicking.rs:553
   6: std::panicking::begin_panic_fmt
             at /checkout/src/libstd/panicking.rs:521
   7: rust_begin_unwind
             at /checkout/src/libstd/panicking.rs:497
   8: core::panicking::panic_fmt
             at /checkout/src/libcore/panicking.rs:92
   9: core::slice::slice_index_order_fail
             at /checkout/src/libcore/slice/mod.rs:741
  10: <core::ops::range::Range<usize> as core::slice::SliceIndex<[T]>>::index
             at /checkout/src/libcore/slice/mod.rs:864
  11: <core::ops::range::RangeFrom<usize> as core::slice::SliceIndex<[T]>>::index
             at /checkout/src/libcore/slice/mod.rs:947
  12: core::slice::<impl core::ops::index::Index<I> for [T]>::index
             at /checkout/src/libcore/slice/mod.rs:717
  13: xmas_elf::ElfFile::get_str_table::{{closure}}
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/xmas-elf-0.3.0/src/lib.rs:97
  14: <core::result::Result<T, E>>::map
             at /checkout/src/libcore/result.rs:458
  15: xmas_elf::ElfFile::get_str_table
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/xmas-elf-0.3.0/src/lib.rs:97
  16: xmas_elf::ElfFile::get_string
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/xmas-elf-0.3.0/src/lib.rs:72
  17: xmas_elf::sections::SectionHeader::get_name::{{closure}}
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/xmas-elf-0.3.0/src/sections.rs:92
  18: <core::result::Result<T, E>>::and_then
             at /checkout/src/libcore/result.rs:602
  19: xmas_elf::sections::SectionHeader::get_name
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/xmas-elf-0.3.0/src/sections.rs:90
  20: xmas_elf::ElfFile::find_section_by_name
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/xmas-elf-0.3.0/src/lib.rs:84
  21: <object::elf::Elf<'a> as object::object_trait::Object<'a>>::get_section
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/object-0.1.0/src/elf.rs:13
  22: <addr2line::DebugInfo<'object, Endian>>::new
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.3.0/src/lib.rs:271
  23: addr2line::Mapping::symbolicate
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.3.0/src/lib.rs:251
  24: addr2line::Mapping::new_inner::{{closure}}::{{closure}}
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.3.0/src/lib.rs:230
  25: <owning_ref::OwningHandle<O, H>>::try_new
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/owning_ref-0.2.4/src/lib.rs:475
  26: addr2line::Mapping::new_inner::{{closure}}
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.3.0/src/lib.rs:228
  27: <owning_ref::OwningHandle<O, H>>::try_new
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/owning_ref-0.2.4/src/lib.rs:475
  28: addr2line::Mapping::new_inner
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.3.0/src/lib.rs:225
  29: addr2line::Options::build
             at /home/mstange/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.3.0/src/lib.rs:175
  30: addr2line_libxul::main
             at src/main.rs:4
  31: __rust_maybe_catch_panic
             at /checkout/src/libpanic_unwind/lib.rs:98
  32: std::rt::lang_start
             at /checkout/src/libstd/panicking.rs:458
             at /checkout/src/libstd/panic.rs:361
             at /checkout/src/libstd/rt.rs:59
  33: main
  34: __libc_start_main
  35: _start

The Firefox build I'm testing with is a regular local opt build.

Panic when generating backtrace in Servo

When filing servo/servo#26508, I saw a panic coming from addr2line as it attempted to get a backtrace:

index out of bounds: the len is 0 but the index is 57 (thread ScriptThread PipelineId { namespace_id: PipelineNamespaceId(2), index: PipelineIndex(3) }, at /Users/joshmatthews/.cargo/registry/src/github.com-1ecc6299db9ec823/addr2line-0.12.0/src/lib.rs:302)
Servo exited with return value 4

It's not totally clear how to get more information about what's happening here. I could try catching it in lldb.

Unable to clone repository on Windows

$ git clone https://github.com/gimli-rs/addr2line.git
Cloning into 'addr2line'...
remote: Enumerating objects: 96, done.
remote: Counting objects: 100% (96/96), done.
remote: Compressing objects: 100% (55/55), done.
remote: Total 1173 (delta 40), reused 72 (delta 28), pack-reused 1077 eceiving objects:  98% (1150/1173), 1.57 MiB | 3.11 MiB/s
Receiving objects: 100% (1173/1173), 4.08 MiB | 5.58 MiB/s, done.
Resolving deltas: 100% (547/547), done.
error: invalid path 'tests/aux/Cargo.toml'
fatal: unable to checkout working tree
warning: Clone succeeded, but checkout failed.
You can inspect what was checked out with 'git status'
and retry with 'git restore --source=HEAD :/'

This happens because you cannot have file/directory named aux on Windows.

Suggested fix: rename directory to a less harmful name.

Broken by #163.

addr2line panics on XUL.dSYM from recent Firefox macOS builds

Steps to reproduce:

wget https://symbols.mozilla.org/XUL/3378E7F8C8E339A6AAAD847F4A12748D0/XUL.dSYM.tar.bz2
tar -xvf XUL.dSYM.tar.bz2
git clone https://github.com/gimli-rs/addr2line
cd addr2line
cargo run --example addr2line -- -i -f -e ../XUL.dSYM/Contents/Resources/DWARF/XUL 14c601b

Expected results:
A call stack

Actual results:

thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: MissingUnitDie', src/libcore/result.rs:999:5

Context<R>::from_sections encounters Error::MissingUnitDie on 439 out of 23185 units. The broken units are spread out evenly.
In gimli-rs/gimli#436, @philipc said:

I think this is probably an addr2line bug. It should ignore units that it can't parse.

provide pub struct Context<'a, R = gimli::EndianSlice<'a, gimli::RunTimeEndian>>

Currently the Context is restricted to R = gimli::EndianRcSlicegimli::RunTimeEndian

pub struct Context<R = gimli::EndianRcSlice<gimli::RunTimeEndian>>

This prevents the use of a pub struct Context<'a, R = gimli::EndianSlice<'a, gimli::RunTimeEndian>>

Are you open to providing such a Context?

A quick and dirty hack in lib.rs that changes Context to Context with EndianSlice:

//! This crate provides a cross-platform library and binary for translating addresses into
//! function names, file names and line numbers. Given an address in an executable or an
//! offset in a section of a relocatable object, it uses the debugging information to
//! figure out which file name and line number are associated with it.
//!
//! When used as a library, files must first be loaded using the
//! [`object`](https://github.com/gimli-rs/object) crate.
//! A context can then be created with [`Context::new`](./struct.Context.html#method.new).
//! The context caches some of the parsed information so that multiple lookups are
//! efficient.
//! Location information is obtained with
//! [`Context::find_location`](./struct.Context.html#method.find_location).
//! Function information is obtained with
//! [`Context::find_frames`](./struct.Context.html#method.find_frames), which returns
//! a frame for each inline function. Each frame contains both name and location.
//!
//! The crate has an example CLI wrapper around the library which provides some of
//! the functionality of the `addr2line` command line tool distributed with [GNU
//! binutils](https://www.gnu.org/software/binutils/).
//!
//! Currently this library only provides information from the DWARF debugging information,
//! which is parsed using [`gimli`](https://github.com/gimli-rs/gimli).  The example CLI
//! wrapper also uses symbol table information provided by the `object` crate.
#![deny(missing_docs)]
#![no_std]
#![cfg_attr(not(feature = "std"), feature(alloc))]

#[cfg(feature = "std")]
#[macro_use]
extern crate std;

#[cfg(not(feature = "std"))]
extern crate alloc;
#[cfg(not(feature = "std"))]
extern crate core as std;

#[cfg(feature = "cpp_demangle")]
extern crate cpp_demangle;
pub extern crate fallible_iterator;
pub extern crate gimli;
extern crate intervaltree;
extern crate lazycell;
#[cfg(feature = "object")]
pub extern crate object;
#[cfg(feature = "rustc-demangle")]
extern crate rustc_demangle;
extern crate smallvec;

#[cfg(feature = "std")]
mod alloc {
    pub use std::{borrow, rc, string, vec};
}

use alloc::borrow::Cow;
#[cfg(feature = "object")]
use alloc::rc::Rc;
use alloc::string::{String, ToString};
use alloc::vec::Vec;

#[cfg(feature = "rustc-demangle")]
use alloc::format;

use std::cmp::Ordering;
use std::u64;

use fallible_iterator::FallibleIterator;
use intervaltree::{Element, IntervalTree};
use lazycell::LazyCell;
use smallvec::SmallVec;

struct Func<T> {
    entry_off: gimli::UnitOffset<T>,
    depth: isize,
}

struct Lines<R: gimli::Reader> {
    lnp: gimli::CompleteLineProgram<R, R::Offset>,
    sequences: Vec<gimli::LineSequence<R>>,
}

struct ResUnit<R>
where
    R: gimli::Reader,
{
    dw_unit: gimli::Unit<R>,
    lang: Option<gimli::DwLang>,
    lines: LazyCell<Result<Lines<R>, Error>>,
    funcs: LazyCell<Result<IntervalTree<u64, Func<R::Offset>>, Error>>,
}

/// The state necessary to perform address to line translation.
///
/// Constructing a `Context` is somewhat costly, so users should aim to reuse `Context`s
/// when performing lookups for many addresses in the same executable.
pub struct Context<'a, R = gimli::EndianSlice<'a, gimli::RunTimeEndian>>
where
    R: gimli::Reader,
{
    unit_ranges: Vec<(gimli::Range, usize)>,
    units: Vec<ResUnit<R>>,
    sections: gimli::Dwarf<R>,
    _buf: core::marker::PhantomData<&'a [u8]>,
}

impl<'a, R: gimli::Reader> Context<'a, R> {
    /// Construct a new `Context` from DWARF sections.
    pub fn from_sections(
        debug_abbrev: gimli::DebugAbbrev<R>,
        debug_addr: gimli::DebugAddr<R>,
        debug_info: gimli::DebugInfo<R>,
        debug_line: gimli::DebugLine<R>,
        debug_line_str: gimli::DebugLineStr<R>,
        debug_ranges: gimli::DebugRanges<R>,
        debug_rnglists: gimli::DebugRngLists<R>,
        debug_str: gimli::DebugStr<R>,
        debug_str_offsets: gimli::DebugStrOffsets<R>,
        default_section: R,
    ) -> Result<Self, Error> {
        let sections = gimli::Dwarf {
            debug_abbrev,
            debug_addr,
            debug_info,
            debug_line,
            debug_line_str,
            debug_str,
            debug_str_offsets,
            debug_str_sup: default_section.clone().into(),
            debug_types: default_section.clone().into(),
            locations: gimli::LocationLists::new(
                default_section.clone().into(),
                default_section.clone().into(),
            ),
            ranges: gimli::RangeLists::new(debug_ranges, debug_rnglists),
        };

        let mut unit_ranges = Vec::new();
        let mut res_units = Vec::new();
        let mut units = sections.units();
        while let Some(header) = units.next()? {
            let unit_id = res_units.len();
            let dw_unit = sections.unit(header)?;

            let lang;
            {
                let mut cursor = dw_unit.entries();

                let unit = match cursor.next_dfs()? {
                    Some((_, unit)) if unit.tag() == gimli::DW_TAG_compile_unit => unit,
                    _ => continue, // wtf?
                };

                lang = match unit.attr_value(gimli::DW_AT_language)? {
                    Some(gimli::AttributeValue::Language(lang)) => Some(lang),
                    _ => None,
                };
                let mut ranges = sections.unit_ranges(&dw_unit)?;
                while let Some(range) = ranges.next()? {
                    if range.begin == range.end {
                        continue;
                    }

                    unit_ranges.push((range, unit_id));
                }
            }

            res_units.push(ResUnit {
                dw_unit,
                lang,
                lines: LazyCell::new(),
                funcs: LazyCell::new(),
            });
        }

        unit_ranges.sort_by_key(|x| x.0.begin);

        // Ranges need to be disjoint so that we can binary search, but weak symbols can
        // cause overlap. In this case, we don't care which unit is used, so ignore the
        // beginning of the subseqent range to avoid overlap.
        let mut prev_end = 0;
        for range in &mut unit_ranges {
            if range.0.begin < prev_end {
                range.0.begin = prev_end;
            }
            if range.0.end < prev_end {
                range.0.end = prev_end;
            } else {
                prev_end = range.0.end;
            }
        }
        debug_assert!(unit_ranges.windows(2).all(|w| w[0].0.end <= w[1].0.begin));

        Ok(Context {
            units: res_units,
            unit_ranges,
            sections,
            _buf: core::marker::PhantomData,
        })
    }
}

impl<R> ResUnit<R>
where
    R: gimli::Reader,
{
    fn parse_lines(&self) -> Result<Option<&Lines<R>>, Error> {
        let ilnp = match self.dw_unit.line_program {
            Some(ref ilnp) => ilnp,
            None => return Ok(None),
        };
        self.lines
            .borrow_with(|| {
                let (lnp, mut sequences) = ilnp.clone().sequences()?;
                sequences.retain(|x| x.start != 0);
                sequences.sort_by_key(|x| x.start);
                Ok(Lines { lnp, sequences })
            })
            .as_ref()
            .map(Some)
            .map_err(Error::clone)
    }

    fn parse_functions(
        &self,
        sections: &gimli::Dwarf<R>,
    ) -> Result<&IntervalTree<u64, Func<R::Offset>>, Error> {
        self.funcs
            .borrow_with(|| {
                let mut results = Vec::new();
                let mut depth = 0;
                let mut cursor = self.dw_unit.entries();
                while let Some((d, entry)) = cursor.next_dfs()? {
                    depth += d;
                    match entry.tag() {
                        gimli::DW_TAG_subprogram | gimli::DW_TAG_inlined_subroutine => {
                            let mut ranges = sections.die_ranges(&self.dw_unit, entry)?;
                            while let Some(range) = ranges.next()? {
                                // Ignore invalid DWARF so that a query of 0 does not give
                                // a long list of matches.
                                // TODO: don't ignore if there is a section at this address
                                if range.begin == 0 {
                                    continue;
                                }
                                results.push(Element {
                                    range: range.begin..range.end,
                                    value: Func {
                                        entry_off: entry.offset(),
                                        depth,
                                    },
                                });
                            }
                        }
                        _ => (),
                    }
                }

                let tree: IntervalTree<_, _> = results.into_iter().collect();
                Ok(tree)
            })
            .as_ref()
            .map_err(Error::clone)
    }
}

/// An iterator over function frames.
pub struct FrameIter<'ctx, R>
where
    R: gimli::Reader + 'ctx,
{
    unit_id: usize,
    units: &'ctx Vec<ResUnit<R>>,
    sections: &'ctx gimli::Dwarf<R>,
    funcs: smallvec::IntoIter<[&'ctx Func<R::Offset>; 16]>,
    next: Option<Location>,
}

/// A function frame.
pub struct Frame<R: gimli::Reader> {
    /// The name of the function.
    pub function: Option<FunctionName<R>>,
    /// The source location corresponding to this frame.
    pub location: Option<Location>,
}

/// A function name.
pub struct FunctionName<R: gimli::Reader> {
    name: R,
    /// The language of the compilation unit containing this function.
    pub language: Option<gimli::DwLang>,
}

impl<R: gimli::Reader> FunctionName<R> {
    /// The raw name of this function before demangling.
    pub fn raw_name(&self) -> Result<Cow<str>, Error> {
        self.name.to_string_lossy()
    }

    /// The name of this function after demangling (if applicable).
    pub fn demangle(&self) -> Result<Cow<str>, Error> {
        self.raw_name().map(|x| demangle_auto(x, self.language))
    }
}

/// Demangle a symbol name using the demangling scheme for the given language.
///
/// Returns `None` if demangling failed or is not required.
#[allow(unused_variables)]
pub fn demangle(name: &str, language: gimli::DwLang) -> Option<String> {
    match language {
        #[cfg(feature = "rustc-demangle")]
        gimli::DW_LANG_Rust => rustc_demangle::try_demangle(name)
            .ok()
            .as_ref()
            .map(|x| format!("{:#}", x)),
        #[cfg(feature = "cpp_demangle")]
        gimli::DW_LANG_C_plus_plus
        | gimli::DW_LANG_C_plus_plus_03
        | gimli::DW_LANG_C_plus_plus_11
        | gimli::DW_LANG_C_plus_plus_14 => cpp_demangle::Symbol::new(name)
            .ok()
            .and_then(|x| x.demangle(&Default::default()).ok()),
        _ => None,
    }
}

/// Apply 'best effort' demangling of a symbol name.
///
/// If `language` is given, then only the demangling scheme for that language
/// is used.
///
/// If `language` is `None`, then heuristics are used to determine how to
/// demangle the name. Currently, these heuristics are very basic.
///
/// If demangling fails or is not required, then `name` is returned unchanged.
pub fn demangle_auto(name: Cow<str>, language: Option<gimli::DwLang>) -> Cow<str> {
    match language {
        Some(language) => demangle(name.as_ref(), language),
        None => demangle(name.as_ref(), gimli::DW_LANG_Rust)
            .or_else(|| demangle(name.as_ref(), gimli::DW_LANG_C_plus_plus)),
    }
    .map(Cow::from)
    .unwrap_or(name)
}

/// A source location.
pub struct Location {
    /// The file name.
    pub file: Option<String>,
    /// The line number.
    pub line: Option<u64>,
    /// The column number.
    pub column: Option<u64>,
}

impl<'a, R> Context<'a, R>
where
    R: gimli::Reader,
{
    fn find_unit(&self, probe: u64) -> Option<usize> {
        let idx = self.unit_ranges.binary_search_by(|r| {
            if probe < r.0.begin {
                Ordering::Greater
            } else if probe >= r.0.end {
                Ordering::Less
            } else {
                Ordering::Equal
            }
        });
        let idx = match idx {
            Ok(x) => x,
            Err(_) => return None,
        };

        let (_, unit_id) = self.unit_ranges[idx];
        Some(unit_id)
    }

    /// Find the source file and line corresponding to the given virtual memory address.
    pub fn find_location(&self, probe: u64) -> Result<Option<Location>, Error> {
        match self.find_unit(probe) {
            Some(unit_id) => self.units[unit_id].find_location(probe, &self.sections),
            None => Ok(None),
        }
    }

    /// Return an iterator for the function frames corresponding to the given virtual
    /// memory address.
    ///
    /// If the probe address is not for an inline function then only one frame is
    /// returned.
    ///
    /// If the probe address is for an inline function then the first frame corresponds
    /// to the innermost inline function.  Subsequent frames contain the caller and call
    /// location, until an non-inline caller is reached.
    pub fn find_frames(&self, probe: u64) -> Result<FrameIter<R>, Error> {
        let (unit_id, loc, funcs) = match self.find_unit(probe) {
            Some(unit_id) => {
                let unit = &self.units[unit_id];
                let loc = unit.find_location(probe, &self.sections)?;
                let funcs = unit.parse_functions(&self.sections)?;
                let mut res: SmallVec<[_; 16]> =
                    funcs.query_point(probe).map(|x| &x.value).collect();
                res.sort_by_key(|x| -x.depth);
                (unit_id, loc, res)
            }
            None => (0, None, SmallVec::new()),
        };

        Ok(FrameIter {
            unit_id,
            units: &self.units,
            sections: &self.sections,
            funcs: funcs.into_iter(),
            next: loc,
        })
    }
}

impl<R> ResUnit<R>
where
    R: gimli::Reader,
{
    fn find_location(
        &self,
        probe: u64,
        sections: &gimli::Dwarf<R>,
    ) -> Result<Option<Location>, Error> {
        let lines = match self.parse_lines()? {
            Some(lines) => lines,
            None => return Ok(None),
        };
        let idx = lines.sequences.binary_search_by(|ln| {
            if probe < ln.start {
                Ordering::Greater
            } else if probe >= ln.end {
                Ordering::Less
            } else {
                Ordering::Equal
            }
        });
        let idx = match idx {
            Ok(x) => x,
            Err(_) => return Ok(None),
        };
        let ln = &lines.sequences[idx];
        let mut sm = lines.lnp.resume_from(ln);
        let mut file = None;
        let mut line = None;
        let mut column = None;
        while let Some((_, row)) = sm.next_row()? {
            if row.address() > probe {
                break;
            }

            file = row.file(lines.lnp.header());
            line = row.line();
            column = match row.column() {
                gimli::ColumnType::LeftEdge => None,
                gimli::ColumnType::Column(x) => Some(x),
            };
        }

        let file = match file {
            Some(file) => Some(self.render_file(file, lines, sections)?),
            None => None,
        };

        Ok(Some(Location { file, line, column }))
    }

    fn render_file(
        &self,
        file: &gimli::FileEntry<R, R::Offset>,
        lines: &Lines<R>,
        sections: &gimli::Dwarf<R>,
    ) -> Result<String, gimli::Error> {
        let mut path = if let Some(ref comp_dir) = self.dw_unit.comp_dir {
            String::from(comp_dir.to_string_lossy()?.as_ref())
        } else {
            String::new()
        };

        if let Some(directory) = file.directory(lines.lnp.header()) {
            path_push(
                &mut path,
                sections
                    .attr_string(&self.dw_unit, directory)?
                    .to_string_lossy()?
                    .as_ref(),
            );
        }

        path_push(
            &mut path,
            sections
                .attr_string(&self.dw_unit, file.path_name())?
                .to_string_lossy()?
                .as_ref(),
        );

        Ok(path)
    }
}

fn path_push(path: &mut String, p: &str) {
    if p.starts_with("/") {
        *path = p.to_string();
    } else {
        if !path.ends_with("/") {
            *path += "/";
        }
        *path += p;
    }
}

type Error = gimli::Error;

fn name_attr<'abbrev, 'unit, R>(
    entry: &gimli::DebuggingInformationEntry<'abbrev, 'unit, R, R::Offset>,
    unit: &ResUnit<R>,
    sections: &gimli::Dwarf<R>,
    units: &[ResUnit<R>],
    recursion_limit: usize,
) -> Result<Option<R>, Error>
where
    R: gimli::Reader,
{
    if recursion_limit == 0 {
        return Ok(None);
    }

    if let Some(attr) = entry.attr_value(gimli::DW_AT_linkage_name)? {
        if let Ok(val) = sections.attr_string(&unit.dw_unit, attr) {
            return Ok(Some(val));
        }
    }
    if let Some(attr) = entry.attr_value(gimli::DW_AT_MIPS_linkage_name)? {
        if let Ok(val) = sections.attr_string(&unit.dw_unit, attr) {
            return Ok(Some(val));
        }
    }
    if let Some(attr) = entry.attr_value(gimli::DW_AT_name)? {
        if let Ok(val) = sections.attr_string(&unit.dw_unit, attr) {
            return Ok(Some(val));
        }
    }

    let next = entry
        .attr_value(gimli::DW_AT_abstract_origin)?
        .or(entry.attr_value(gimli::DW_AT_specification)?);
    match next {
        Some(gimli::AttributeValue::UnitRef(offset)) => {
            let mut entries = unit.dw_unit.entries_at_offset(offset)?;
            if let Some((_, entry)) = entries.next_dfs()? {
                return name_attr(entry, unit, sections, units, recursion_limit - 1);
            } else {
                return Err(gimli::Error::NoEntryAtGivenOffset);
            }
        }
        Some(gimli::AttributeValue::DebugInfoRef(dr)) => {
            if let Some((unit, offset)) = units
                .iter()
                .filter_map(|unit| {
                    gimli::UnitSectionOffset::DebugInfoOffset(dr)
                        .to_unit_offset(&unit.dw_unit)
                        .map(|uo| (unit, uo))
                })
                .next()
            {
                let mut entries = unit.dw_unit.entries_at_offset(offset)?;
                if let Some((_, entry)) = entries.next_dfs()? {
                    return name_attr(entry, unit, sections, units, recursion_limit - 1);
                }
            } else {
                return Err(gimli::Error::NoEntryAtGivenOffset);
            }
        }
        _ => {}
    }

    Ok(None)
}

impl<'ctx, R> FrameIter<'ctx, R>
where
    R: gimli::Reader + 'ctx,
{
    /// Advances the iterator and returns the next frame.
    pub fn next(&mut self) -> Result<Option<Frame<R>>, Error> {
        let (loc, func) = match (self.next.take(), self.funcs.next()) {
            (None, None) => return Ok(None),
            (loc, Some(func)) => (loc, func),
            (Some(loc), None) => {
                return Ok(Some(Frame {
                    function: None,
                    location: Some(loc),
                }))
            }
        };

        let unit = &self.units[self.unit_id];

        let mut cursor = unit.dw_unit.entries_at_offset(func.entry_off)?;
        let (_, entry) = cursor
            .next_dfs()?
            .expect("DIE we read a while ago is no longer readable??");

        // Set an arbitrary recursion limit of 16
        let name = name_attr(entry, unit, self.sections, self.units, 16)?;

        if entry.tag() == gimli::DW_TAG_inlined_subroutine {
            let file = match entry.attr_value(gimli::DW_AT_call_file)? {
                Some(gimli::AttributeValue::FileIndex(fi)) => match unit.parse_lines()? {
                    Some(lines) => match lines.lnp.header().file(fi) {
                        Some(file) => Some(unit.render_file(file, lines, self.sections)?),
                        None => None,
                    },
                    None => None,
                },
                _ => None,
            };

            let line = entry
                .attr(gimli::DW_AT_call_line)?
                .and_then(|x| x.udata_value())
                .and_then(|x| if x == 0 { None } else { Some(x) });
            let column = entry
                .attr(gimli::DW_AT_call_column)?
                .and_then(|x| x.udata_value());

            self.next = Some(Location { file, line, column });
        }


        Ok(Some(Frame {
            function: name.map(|name| FunctionName {
                name,
                language: unit.lang,
            }),
            location: loc,
        }))
    }
}

impl<'ctx, R> FallibleIterator for FrameIter<'ctx, R>
where
    R: gimli::Reader + 'ctx,
{
    type Item = Frame<R>;
    type Error = Error;

    #[inline]
    fn next(&mut self) -> Result<Option<Frame<R>>, Error> {
        self.next()
    }
}

Update to `gimli` 0.18 and publish a new version on crates.io

I'd like to bump my gimli dependency in not-perf to 0.18, but I can't since addr2line still depends on gimli 0.17. (The version of addr2line on crates.io is even older with gimli 0.16 as a dependency.)

In general it'd be nice to always release a new addr2line every time a new gimli is released. (Since addr2line directly exposes gimli types in Context::from-sections.)

assertion failed: addresses.windows(2).all(|w| w[0].range.end <= w[1].range.begin) with Android libmozglue.so

In debug builds, parsing this libmozglue.so causes a panic:

cargo run --example addr2line -- -e /Users/mstange/code/profiler-get-symbols/fixtures/android32-local/libmozglue.so 0xa7ab0

thread 'main' panicked at 'assertion failed: addresses.windows(2).all(|w| w[0].range.end <= w[1].range.begin)', <::core::macros::panic macros>:2:2
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

It's hitting this debug assertion:

addr2line/src/lib.rs

Lines 780 to 782 in a153abf

debug_assert!(addresses
.windows(2)
.all(|w| w[0].range.end <= w[1].range.begin));

Many addresses are missing file + line information

When using addr2line to find file and line information from a local Firefox build on macOS, many addresses end up without file or line information. Here's one example:

  1. Download nsEmbedFunctions.o.
  2. Look up addresses 0x104d and 0x1052.

Result:

cargo run --release --example addr2line -- -C -f -i --exe /Users/mstange/code/obj-m-opt/toolkit/xre/nsEmbedFunctions.o 0x104d 0x1052
    Finished release [optimized + debuginfo] target(s) in 0.18s
     Running `target/release/examples/addr2line -C -f -i --exe /Users/mstange/code/obj-m-opt/toolkit/xre/nsEmbedFunctions.o 0x104d 0x1052`
XRE_InitChildProcess(int, char**, XREChildData const*)
??:?
XRE_InitChildProcess(int, char**, XREChildData const*)
??:?

lldb finds file + line + column information for these addresses correctly: nsEmbedFunctions.cpp:740:34.

(Edit: unnecessary details elided, see next comment for atos getting it right)

`addr2line` command should locate dSYMs on macOS

Currently, addr2line on macOS requires you to manually pass the path to the dSYM DWARF file, rather than the executable itself. It'd be neat if the addr2line command line tool could automatically figure this out for you. Related to #4.

#![no_std] support

In order for addr2line to be integrated into libstd, it requires support for the #![no_std] environment. This also helps with integration into embedded programs and OS kernels.

There exist DWARF files in the wild where a program entry's ranges are not contained within the CU

Using the separate debug info for libpthread.so.0 on Xenial.

~/dev/addr2line/target/debug/addr2line -f -e /usr/lib/debug/.build-id/4d/7f52f335dc9665c2dcf308ce6514a6ae86dede.debug 5555

thread 'main' panicked at 'assertion failed: unit.ranges.iter().any(|range| range.begin <= r.begin && range.end >= r.end)', src/lib.rs:597

The DWARF contains an inline subprogram that is not within the CU's declared ranges.

Support byte based API ?

I would like to use this in an application but it seems the only entry point in the API is a path based one.

Do you plan on supporting an AsRef<[u8]> or a simple &[u8] entry point ?

As it stands now the API as is would essentially double memory usage for a consumer which has already loaded / obtained the bytes in some lawful (or unlawful) manner, as it appears to memmap the binary/bytes.

Thanks and awesome crate!

Are column values of 0 ever exposed?

I came across ColumnType::LeftEdge when reading gimli code recently, and it made me wonder how function calls at the start of a line are exposed by addr2line. There's a piece of code that turns 0 into None.

Support reading in object files for executables on macOS

By default, the linker doesn't include debug info into the resulting executable. It's either left in the .o files or put in a dsym file. In the situation where it's left in the .o files there are OSO stabs entries that give the paths of the .o files. We should read those in as needed to resolve the addresses.

Handle overlapping ranges

This assert triggers for some binaries.

May also need better validation of ranges in general. May also want to ignore ranges that begin at 0. Also see #49 for some changes that may be required.

addr2line example should handle macos universal binaries

iOS APP , dsym file

echo 0xFF1BE4 | ./addr2line  -s -i -f -p -a -e /Users/xiejunyi/Desktop/atosl/xxx.app.dSYM/Contents/Resources/DWARF/xxx
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: "Unknown file magic"', src/libcore/result.rs:906:4
note: Run with `RUST_BACKTRACE=1` for a backtrace.

integration into libstd

Hi, has integration into libstd been attempted yet (rust-lang/rust#46439)? Have there been any blockers that are not resolved yet? If no, I'd like to conduct such a project.

Blockers for addr2line itself (in no particular order):

Trait bound not satisfied

Apologies if this has an obvious fix.

Making a new crate as so:

cargo new test_crate
cd test_crate
cargo add object
cargo add addr2line

Using this source:

extern crate object;
extern crate addr2line;

use addr2line::Context;
use object::Object;

fn main() {
    let data: Vec<u8> = Vec::new();
    let obj = object::File::parse(&data).unwrap();
    let addr2line = Context::new(&obj).unwrap();
    println!("Hello World");
}

I get the following compile error, even though I believe this should work based on the README and examples:

warning: unused import: `object::Object`
 --> src\main.rs:5:5
  |
5 | use object::Object;
  |     ^^^^^^^^^^^^^^
  |
  = note: #[warn(unused_imports)] on by default

error[E0277]: the trait bound `object::File<'_>: object::traits::Object<'_, '_>` is not satisfied
  --> src\main.rs:10:21
   |
10 |     let addr2line = Context::new(&obj).unwrap();
   |                     ^^^^^^^^^^^^ the trait `object::traits::Object<'_, '_>` is not implemented for `object::File<'_>`
   |
   = note: required by `<addr2line::Context<gimli::endian_reader::EndianReader<gimli::endianity::RunTimeEndian, std::rc::Rc<[u8]>>>>::new`

The versions being used here are object = "0.11.0" and addr2line = "0.7.0". I'm not sure why the trait bound is not satisfied, because everything looks fine according to the documentation and object::File correctly implements object::Object. Also I pulled in object::Object with use because I thought that might have been the issue, but all this did was give me a warning. I'm using rustc 1.30.1 on stable-x86_64-pc-windows-msvc

Add more convenience APIs

In jonhoo/inferno#14 (comment), @jonhoo said:

The un_inline function introduced in this PR has to:

* open the file

* pass it to `object::File::parse`

* pass that to `Context::new`

* call `Context::find_frames`

* iterate over the frames (with an extra `unwrap` it seems)

* tease out the function name from each frame using (somewhat simplified)
  ```rust
  addr2line::demangle_auto(frame.function.map(|func| func.raw_name()), func.language))
  ```

To me at least, that's very similar to the flow of examples/addr2line.rs, and it seems unfortunate to have to repeat the whole boilerplate if this is a common use-case for addr2line (looking up function stack by address). In particular, I wonder whether addr2line could provide a convenience API for "create a new Context from a file" (maybe using mmap and from_sections internally if possible), and "iterate over the functions of an address" (including demangling the raw_name). Something like Context::from_file(&File) -> Context and Context::resolve_iter(u64) -> impl Iterator<Item = Function>, where Function is a struct that holds the demangled name, file, line number, etc.

I haven't given any thought to what exactly the API should be, but making things easier is certainly a good goal.

Expose inlining chains, not just last step

Mapping::locate() currently exposes only the closest function to a given address, which means that any address will only be resolved to the deepest inlined function that contains it. It would be better if locate returned the full chain of function ancestors for an address.

include LICENSE*

Apache-2.0 requires text license to be present along with source and binaries. MIT requires some sort of this as well.

tests are failing on ppc64

failures:
---- identity_map stdout ----
	thread 'identity_map' panicked at 'assertion failed: `(left != right)`
  left: `0`,
 right: `0`', tests/integration_test.rs:76:4
note: Run with `RUST_BACKTRACE=1` for a backtrace.
---- with_functions stdout ----
	thread 'with_functions' panicked at 'assertion failed: `(left != right)`
  left: `0`,
 right: `0`', tests/integration_test.rs:148:4
failures:
    identity_map
    with_functions

Not sure how to debug it...

addr2line -f fails with "InvalidDebugSymbols(SubroutineMissingName(0, 100459))"

Way to reproduce:

wget http://slonopotamus.org/libUE4Editor-Core.so
addr2line -f -e libUE4Editor-Core.so 0x2c09b2

Expected output (as produced by addr2line from GNU binutils and gdb, and I know this is correct result):

_Z20PlatformCrashHandleriP9siginfo_tPv
/home/marat/production/ue4/Engine/Source/Runtime/Core/Private/Linux/LinuxPlatformCrashContext.cpp:595

Actual output:

addr2line: Error(Msg("failed to analyze debug information"), State { next_error: Some(Error(Msg("encountered invalid compilation unit"), State { next_error: Some(Error(InvalidDebugSymbols(SubroutineMissingName(0, 100459)), State { next_error: None, backtrace: None })), backtrace: None })), backtrace: None })

Note that running without -f switch properly resolves filename/lineno, it's only function name that fails to resolve.

Funny facts:

  1. addr2line from elfutils works in the opposite way: it resolves function name but fails with filename/lineno.
  2. addr2line from elftoolchain segfaults when trying to resolve function name, and gives wrong filename/lineno.
  3. addr2line from FreeBSD gives wrong filename/lineno and fails to find function name

So, among five addr2line implementations, there are no two that behave the same way.

Set default R for Context

If we expect users to often end up with Context<EndianRcSlice<RunTimeEndian>>, should we just make that the default type? As in:

pub struct Context<R = EndianRcSlice<RunTimeEndian>> {}

That would save users of the library to explicitly type out the full type for Context in the common case!

output_equivalence fails tests in 0.10.0 release

This is only an issue in the last published release ( the only one I've tested ), but the problem seems to be fixed in current git master, and after locally applying the output_equivalence parts of commits:

( From #129 )

Tests pass.

So feel free to close this after publishing a fixed release, this bug is mostly for visibility of other linux vendors who may be packaging this crate, and are likely to see the same issue.

 addr2line -v
GNU addr2line (Gentoo 2.32 p2) 2.32.0
Copyright (C) 2019 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.

First failure:

$ addr2line -af --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -af --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
thread 'addr2line -ai' panicked at 'Output not equivalent:

Diffed:

--- /tmp/left	2019-12-21 18:56:30.826601208 +1300
+++ /tmp/right	2019-12-21 18:56:24.013586079 +1300
@@ -1,8 +1,8 @@
-addr2line -ai --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
+<prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ai --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
 0x000000000002c67e
 <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
 0x000000000002c65d
-4qwhkote7wbuge48:?
+<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
 0x000000000002c562
 <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
 0x000000000002c846
Full Output
     Running `<prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5`
thread 'addr2line -af' panicked at 'Output not equivalent:

$ addr2line -af --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -af --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace.
thread 'addr2line -ai' panicked at 'Output not equivalent:

$ addr2line -ai --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
4qwhkote7wbuge48:?
0x000000000002c562
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ai --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -a' panicked at 'Output not equivalent:

$ addr2line -a --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
4qwhkote7wbuge48:?
0x000000000002c562
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -a --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line ' panicked at 'Output not equivalent:

$ addr2line  --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
4qwhkote7wbuge48:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line  --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aif' panicked at 'Output not equivalent:

$ addr2line -aif --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aif --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aip' panicked at 'Output not equivalent:

$ addr2line -aip --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: 4qwhkote7wbuge48:?
0x000000000002c562: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aip --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aips' panicked at 'Output not equivalent:

$ addr2line -aips --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: output_equivalence.rs:?
0x000000000002c65d: 4qwhkote7wbuge48:?
0x000000000002c562: output_equivalence.rs:35
0x000000000002c846: output_equivalence.rs:69
0x000000000002f8ff: output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aips --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: output_equivalence.rs:?
0x000000000002c65d: output_equivalence.rs:?
0x000000000002c562: output_equivalence.rs:35
0x000000000002c846: output_equivalence.rs:69
0x000000000002f8ff: output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aipf' panicked at 'Output not equivalent:

$ addr2line -aipf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aipf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ais' panicked at 'Output not equivalent:

$ addr2line -ais --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
output_equivalence.rs:?
0x000000000002c65d
4qwhkote7wbuge48:?
0x000000000002c562
output_equivalence.rs:35
0x000000000002c846
output_equivalence.rs:69
0x000000000002f8ff
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ais --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
output_equivalence.rs:?
0x000000000002c65d
output_equivalence.rs:?
0x000000000002c562
output_equivalence.rs:35
0x000000000002c846
output_equivalence.rs:69
0x000000000002f8ff
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aipsf' panicked at 'Output not equivalent:

$ addr2line -aipsf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aipsf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at output_equivalence.rs:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aisf' panicked at 'Output not equivalent:

$ addr2line -aisf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aisf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
output_equivalence.rs:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ap' panicked at 'Output not equivalent:

$ addr2line -ap --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: 4qwhkote7wbuge48:?
0x000000000002c562: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ap --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -apf' panicked at 'Output not equivalent:

$ addr2line -apf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -apf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -aps' panicked at 'Output not equivalent:

$ addr2line -aps --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: output_equivalence.rs:?
0x000000000002c65d: 4qwhkote7wbuge48:?
0x000000000002c562: output_equivalence.rs:35
0x000000000002c846: output_equivalence.rs:69
0x000000000002f8ff: output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -aps --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: output_equivalence.rs:?
0x000000000002c65d: output_equivalence.rs:?
0x000000000002c562: output_equivalence.rs:35
0x000000000002c846: output_equivalence.rs:69
0x000000000002f8ff: output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -apsf' panicked at 'Output not equivalent:

$ addr2line -apsf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -apsf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e: _ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
0x000000000002c65d: _ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at output_equivalence.rs:?
0x000000000002c562: _ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
0x000000000002c846: _ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
0x000000000002f8ff: _ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -as' panicked at 'Output not equivalent:

$ addr2line -as --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
output_equivalence.rs:?
0x000000000002c65d
4qwhkote7wbuge48:?
0x000000000002c562
output_equivalence.rs:35
0x000000000002c846
output_equivalence.rs:69
0x000000000002f8ff
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -as --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
output_equivalence.rs:?
0x000000000002c65d
output_equivalence.rs:?
0x000000000002c562
output_equivalence.rs:35
0x000000000002c846
output_equivalence.rs:69
0x000000000002f8ff
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -f' panicked at 'Output not equivalent:

$ addr2line -f --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -f --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -asf' panicked at 'Output not equivalent:

$ addr2line -asf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -asf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
0x000000000002c67e
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
0x000000000002c65d
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
output_equivalence.rs:?
0x000000000002c562
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
0x000000000002c846
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
0x000000000002f8ff
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -if' panicked at 'Output not equivalent:

$ addr2line -if --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -if --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -i' panicked at 'Output not equivalent:

$ addr2line -i --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
4qwhkote7wbuge48:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -i --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ips' panicked at 'Output not equivalent:

$ addr2line -ips --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
4qwhkote7wbuge48:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ips --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
output_equivalence.rs:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ipf' panicked at 'Output not equivalent:

$ addr2line -ipf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ipf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ip' panicked at 'Output not equivalent:

$ addr2line -ip --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
4qwhkote7wbuge48:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ip --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ipsf' panicked at 'Output not equivalent:

$ addr2line -ipsf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ipsf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -is' panicked at 'Output not equivalent:

$ addr2line -is --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
4qwhkote7wbuge48:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -is --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
output_equivalence.rs:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -isf' panicked at 'Output not equivalent:

$ addr2line -isf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -isf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -p' panicked at 'Output not equivalent:

$ addr2line -p --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
4qwhkote7wbuge48:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -p --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
<prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -pf' panicked at 'Output not equivalent:

$ addr2line -pf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -pf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at <prefix>/addr2line-0.10.0/tests/output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -ps' panicked at 'Output not equivalent:

$ addr2line -ps --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
4qwhkote7wbuge48:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -ps --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
output_equivalence.rs:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -psf' panicked at 'Output not equivalent:

$ addr2line -psf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at 4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -psf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E at output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE at output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E at output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E at output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E at output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -s' panicked at 'Output not equivalent:

$ addr2line -s --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
4qwhkote7wbuge48:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -s --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
output_equivalence.rs:?
output_equivalence.rs:?
output_equivalence.rs:35
output_equivalence.rs:69
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
thread 'addr2line -sf' panicked at 'Output not equivalent:

$ addr2line -sf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
4qwhkote7wbuge48:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119

$ <prefix>/addr2line-0.10.0/target/debug/examples/addr2line -sf --exe <prefix>/addr2line-0.10.0/target/debug/deps/output_equivalence-c011e9a44ff0efa5 0x2c67e 0x2c65d 0x2c562 0x2c846 0x2f8ff
_ZN18output_equivalence10make_trace3bar17h05e1db7b058104e0E
output_equivalence.rs:?
_ZN18output_equivalence10make_trace3foo17h624cfc25584b65edE
output_equivalence.rs:?
_ZN18output_equivalence10make_trace17hbd85c48bc340dd45E
output_equivalence.rs:35
_ZN18output_equivalence8run_test17hfbece1cff0906e34E
output_equivalence.rs:69
_ZN18output_equivalence10make_tests28_$u7b$$u7b$closure$u7d$$u7d$28_$u7b$$u7b$closure$u7d$$u7d$17he0b1b81d4a5ca5b9E
output_equivalence.rs:119



', tests/output_equivalence.rs:79:5
error: test failed, to rerun pass '--test output_equivalence'

Remove trailing hash value from demangled Rust symbol names

When demangling Rust symbol names, binutils addr2line removes the trailing hash value. The rustc_demangle crate allows Demangle to be formatted with or without the hash. I think this crate should match the behavior of binutils.

From rustc-demangle:

// With hash
assert_eq!(format!("{}", demangle("_ZN3foo17h05af221e174051e9E")), "foo::h05af221e174051e9");
// Without hash
assert_eq!(format!("{:#}", demangle("_ZN3foo17h05af221e174051e9E")), "foo");

addr2line should use .symtab information

In the absence of .debug_line information, there is still other file and address information in .debug_info that we can use to give vague information about the address.

Panic in intervaltree

This isn't an issue in addr2line itself, but intervaltree doesn't say what repo it lives in so I have no idea how to file an issue against it ๐Ÿ˜ข

thread 'main' panicked at 'assertion failed: !nodes.is_empty()', /Users/sfackler/.cargo/registry/src/github.com-1ecc6299db9ec823/intervaltree-0.2.0/src/lib.rs:100:8
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
   1: std::panicking::default_hook::{{closure}}
   2: std::panicking::default_hook
   3: std::panicking::rust_panic_with_hook
   4: std::panicking::begin_panic
   5: <intervaltree::IntervalTree<K, V>>::update_max
   6: <intervaltree::IntervalTree<K, V> as core::iter::traits::FromIterator<I>>::from_iter
   7: core::iter::iterator::Iterator::collect
   8: <addr2line::Context<R>>::parse_functions
   9: addr2line::main
  10: __rust_maybe_catch_panic
  11: std::rt::lang_start
  12: main

It specifically looks like its collect implementation is broken for empty iterators.

Fails on missing .debug_info section

(Maybe a duplicate of #3 โ€” I'm not sure.)

gimli's implementation of addr2line fails on Oracle JDK 8's libjvm.so, whereas binutil's implementation works flawlessly.

gimli's:

$ ./target/release/addr2line -C -f -e /usr/lib/jvm/java-8-oracle/jre/lib/amd64/server/libjvm.so 000000000091e000
addr2line: Error(Msg("failed to analyze debug information"), State { next_error: Some(Error(MissingDebugSection("debug_info"), State { next_error: None, backtrace: Some(stack backtrace:
   0:     0x559631789acc - backtrace::backtrace::trace::head074f24009bd74
   1:     0x559631789c1b - backtrace::capture::Backtrace::new::h11e309b878e9f688
   2:     0x5596317893e6 - error_chain::make_backtrace::h6cd7696f430e9230
   3:     0x559631789498 - <error_chain::State as core::default::Default>::default::ha4af8d3cd6140f0f
   4:     0x559631788e3d - addr2line::errors::Error::from_kind::hc3b9178c0cb85af0
   5:     0x55963177327d - addr2line::EndianDebugInfo::new::h126bc89d22af9e03
   6:     0x559631771237 - addr2line::Mapping::new_inner::h77f64885c8711c0f
   7:     0x5596316ca78a - addr2line::main::he19bf927f0143433
   8:     0x5596317e298a - panic_unwind::__rust_maybe_catch_panic
                        at /checkout/src/libpanic_unwind/lib.rs:98
   9:     0x5596317dc190 - std::panicking::try<(),closure>
                        at /checkout/src/libstd/panicking.rs:433
                         - std::panic::catch_unwind<closure,()>
                        at /checkout/src/libstd/panic.rs:361
                         - std::rt::lang_start
                        at /checkout/src/libstd/rt.rs:59
  10:     0x7fe16e93282f - __libc_start_main
  11:     0x5596316c7e58 - _start
  12:                0x0 - <unknown>) })), backtrace: Some(stack backtrace:
   0:     0x559631789acc - backtrace::backtrace::trace::head074f24009bd74
   1:     0x559631789c1b - backtrace::capture::Backtrace::new::h11e309b878e9f688
   2:     0x5596317893e6 - error_chain::make_backtrace::h6cd7696f430e9230
   3:     0x559631789498 - <error_chain::State as core::default::Default>::default::ha4af8d3cd6140f0f
   4:     0x559631788e3d - addr2line::errors::Error::from_kind::hc3b9178c0cb85af0
   5:     0x55963177327d - addr2line::EndianDebugInfo::new::h126bc89d22af9e03
   6:     0x559631771237 - addr2line::Mapping::new_inner::h77f64885c8711c0f
   7:     0x5596316ca78a - addr2line::main::he19bf927f0143433
   8:     0x5596317e298a - panic_unwind::__rust_maybe_catch_panic
                        at /checkout/src/libpanic_unwind/lib.rs:98
   9:     0x5596317dc190 - std::panicking::try<(),closure>
                        at /checkout/src/libstd/panicking.rs:433
                         - std::panic::catch_unwind<closure,()>
                        at /checkout/src/libstd/panic.rs:361
                         - std::rt::lang_start
                        at /checkout/src/libstd/rt.rs:59
  10:     0x7fe16e93282f - __libc_start_main
  11:     0x5596316c7e58 - _start
  12:                0x0 - <unknown>) })

binutils':

$ /usr/bin/addr2line -C -f -e /usr/lib/jvm/java-8-oracle/jre/lib/amd64/server/libjvm.so  000000000091e000
ValueRecorder<_jobject*>::find_index(_jobject*)
??:?

Fix self tests

Self tests are currently ignored because they were causing hangs in Travis (see #54 (comment)). Need to find out why and fix them.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.