From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22350 invoked by alias); 22 Mar 2018 12:33:10 -0000 Mailing-List: contact elfutils-devel-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Post: List-Help: List-Subscribe: Sender: elfutils-devel-owner@sourceware.org Received: (qmail 21727 invoked by uid 89); 22 Mar 2018 12:33:10 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Checked: by ClamAV 0.99.4 on sourceware.org X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 spammy= X-Spam-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on sourceware.org X-Spam-Level: X-HELO: dd17628.kasserver.com Received: from dd17628.kasserver.com (HELO dd17628.kasserver.com) (85.13.138.83) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 22 Mar 2018 12:33:08 +0000 Received: from agathebauer.localnet (ip5f5bf42a.dynamic.kabel-deutschland.de [95.91.244.42]) by dd17628.kasserver.com (Postfix) with ESMTPSA id 0860B628068E; Thu, 22 Mar 2018 13:33:05 +0100 (CET) From: Milian Wolff To: elfutils-devel@sourceware.org Cc: Ulf Hermann Subject: Re: How to associate Elf with Dwfl_Module returned by dwfl_report_module Date: Thu, 22 Mar 2018 12:33:00 -0000 Message-ID: <1697812.XboV2yofke@agathebauer> In-Reply-To: <5bed10d0-beb2-be95-b22c-3cadba3ad506@qt.io> References: <3517953.ztkfjMdy38@agathebauer> <1946852.ajpeOdNFGP@agathebauer> <5bed10d0-beb2-be95-b22c-3cadba3ad506@qt.io> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart2222846.yzzkux42gX"; micalg="pgp-sha256"; protocol="application/pgp-signature" X-IsSubscribed: yes X-SW-Source: 2018-q1/txt/msg00101.txt.bz2 --nextPart2222846.yzzkux42gX Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" Content-length: 1533 On Donnerstag, 22. M=E4rz 2018 10:11:29 CET Ulf Hermann wrote: > Hi Milian, >=20 > > I am regularly seeing broken backtraces for samples where I have > > the gut feeling that missing reported ELFs are to blame. But we report > > everything, except for scenarios where the mmap events seemingly overla= p. >=20 > Actually, at least for perfparser that's not quite true. When perfparser > encounters an overlap error, it will throw out the entire set of mappings > and restart reporting, with the addresses from the current sample (see > PerfSymbolTable::reportElf() and PerfSymbolTable::clearCache()). Yes, I know :) I was more talking about the libdwfl integraiton in perf the= re. > If that > still gives you overlapping ranges, it means perf has not sent all the mm= ap > events and therefore we're reporting the wrong ELF for some address in yo= ur > sample. That wrong ELF may be larger than the one we actually want and > therefore it can overlap some other ELF an address in your sample points > to. >=20 > I've seen that happen. Make sure to keep your sample rate low enough to > prevent perf from dropping anything. >=20 > I realize we could optimize the reporting a bit, with the dwfl_report_end > callback Mark mentioned, but if you have addresses into two overlapping > ELFs in one sample, that's fundamentally impossible to unwind. In the concrete data file I have at hand, no chunks got lost, so I don't th= ink=20 that mmap events could have been lost? Cheers --=20 Milian Wolff mail@milianw.de http://milianw.de= --nextPart2222846.yzzkux42gX Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit Content-length: 833 -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEezawi1aUvUGg3A1+8zYW/HGdOX8FAlqzooEACgkQ8zYW/HGd OX/H2g//aOUzpLBM/QdnlCkeYrclAs9L48xyS+zbHEamCDl30ICeQqqlXNZW3ZyW BLVhTauXIdGeOxYHH4Neyy/hMPZplltkik3gR43e1ApibOJSzTSwd3PkK3vs4MZn ce8ofR5hY6DXSIPEQXP/B7ayPJtHL6oQughc/hDiLLCtOBDW2spHIddhU5FhIp5g UlkSebBh+9kwwVydLqH2kC35eQsYifEIzm+YnZgrcyaJDx8+NTVU80NXpA0d9uRc 6E53pxVNlZMWkJYh8ZSes2CO2t/1L7NhMIhBLUnmcrHO7Yc5jAEbbPuJ+9dJ5eiW VJX3UNWYVM5BrNj8qtxPD9cZmUEYM8bYHsqOunVTRx/vA93XpGxAhm4cX7b1Ufef cUMbIzxU6Nb1kLIZ0JUZbqI1zF0EUivqI+6bfdE7d3JdrNj1vNkWHKz83xcKY/aC qG7u66riW3uHa6PHM2GPksnUfyjgrM7YFGZoQoLGGRaUvUU0Tr/MKGPF4s747Sf+ uAutAsU+CxRsMxyhoD2EnyrV0Iiu7/b+WGg4dLy3Uvc/G5iTuB+8XaSx/OYVLLQD vqrBt+F5pb9ivBV8J9gkyhkaJpb5J0eGKwz5t8tmCZWFi1z+qfG+5QOfbpOjbH5A 8MjaxWrJ0m8mz+EpfepoRt8zY9kHK14lja2UNNGbIvGpoZdNi5Q= =msC8 -----END PGP SIGNATURE----- --nextPart2222846.yzzkux42gX--