summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-xray
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix windows buildbots building llvm-xraySimon Pilgrim2017-01-122-8/+13
| | | | | | | | | | 2 issues: 1 - replaced unix-style pid_t with cross-platform llvm::sys::ProcessInfo::ProcessId 2 - fixed shadow variable warning in lambda expression Reviewed by @filcab llvm-svn: 291760
* [XRay] Include <numeric> for std::accumulate.Dean Michael Berris2017-01-121-0/+1
| | | | | | Fix-up following D24377. llvm-svn: 291750
* [XRay] Implement the `llvm-xray account` subcommandDean Michael Berris2017-01-124-0/+691
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This is the third of a multi-part change to implement subcommands for the `llvm-xray` tool. Here we define the `account` subcommand which does simple function call accounting, generating basic statistics on function calls we find in an XRay log/trace. We support text output and csv output for this subcommand. This change also supports sorting, summing, and filtering the top N results. Part of this tool will later be turned into a library that could be used for basic function call accounting. Depends on D24376. Reviewers: dblaikie, echristo Subscribers: mehdi_amini, dberris, beanz, llvm-commits Differential Revision: https://reviews.llvm.org/D24377 llvm-svn: 291749
* [XRay] Define the library for XRay trace logsDean Michael Berris2017-01-117-422/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In this change we move the definition of the log reading routines from the tools directory in LLVM to {include/llvm,lib}/XRay. We improve the documentation a little bit for the publicly accessible headers, and adjust the top-matter. This also leads to some refactoring and cleanup in the tooling code. In particular, we do the following: - Rename the class from LogReader to Trace, as it better represents the logical set of records as opposed to a log. - Use file type detection instead of asking the user to say what format the input file is. This allows us to keep the interface simple and encapsulate the logic of loading the data appropriately. In future changes we increase the API surface and write dedicated unit tests for the XRay library. Depends on D24376. Reviewers: dblaikie, echristo Subscribers: mehdi_amini, mgorny, llvm-commits, varno Differential Revision: https://reviews.llvm.org/D28345 llvm-svn: 291652
* tools/llvm-xray: Avoid std::errc::protocol_* to appease mingw, like r285261.NAKAMURA Takumi2017-01-113-3/+3
| | | | | | They are oriented from winsock and mingw doesn't import them. llvm-svn: 291636
* [XRay] Fixup includes for modules buildDean Michael Berris2017-01-101-2/+0
| | | | | | | | Remove unnecessary system header include. Follow-up to D24376. llvm-svn: 291533
* [XRay] Don't include <unistd.h> unnecessarilyDean Michael Berris2017-01-101-1/+0
| | | | | | Follow-up to D24376. llvm-svn: 291531
* [XRay] Implement `llvm-xray convert` -- trace file conversionDean Michael Berris2017-01-1010-7/+813
| | | | | | | | | | | | | | | | | | | | This is the second part of a multi-part change to define additional subcommands to the `llvm-xray` tool. This change defines a conversion subcommand to take XRay log files, and turns them from one format to another (binary or YAML). This currently only supports the first version of the log file format, defined in the compiler-rt runtime. Depends on D21987. Reviewers: dblaikie, echristo Subscribers: mehdi_amini, dberris, beanz, llvm-commits Differential Revision: https://reviews.llvm.org/D24376 llvm-svn: 291529
* Make the Error class constructor protectedMehdi Amini2016-11-111-2/+2
| | | | | | | | | This is forcing to use Error::success(), which is in a wide majority of cases a lot more readable. Differential Revision: https://reviews.llvm.org/D26481 llvm-svn: 286561
* xray-extract.cc: Quick fix for mingw, to avoid errc::protocol_error.NAKAMURA Takumi2016-10-271-2/+2
| | | | | | errc::protocol_error is winsock-oriented and mingw doesn't include it. (MS does, though) llvm-svn: 285261
* [XRay] Remove unnecessary include of <unistd.h>Dean Michael Berris2016-10-261-1/+0
| | | | llvm-svn: 285171
* [XRay] Remove unnecessary include of <unistd.h>Dean Michael Berris2016-10-261-2/+0
| | | | llvm-svn: 285170
* [XRay] Move specialisations into correct namespaceDean Michael Berris2016-10-261-0/+6
| | | | llvm-svn: 285168
* [XRay] Remove extra `;` to make -wpedantic happyDean Michael Berris2016-10-261-1/+1
| | | | llvm-svn: 285167
* [XRay] Implement `llvm-xray extract`, start of the llvm-xray toolDean Michael Berris2016-10-267-0/+460
| | | | | | | | | | | | | | | | | | | | Usage: llvm-xray extract <object file> [-o <filename or '-'>] The tool gets the XRay instrumentation map from an object file and turns it into YAML. We first support ELF64 sleds on x86_64 binaries, with provision for supporting other supported platforms and formats later. This is the first of a many-part change to fully implement the `llvm-xray` tool. We also define a subcommand registration and dispatch mechanism to be used by other further subcommand implementations for llvm-xray. Diffusion Revision: https://reviews.llvm.org/D21987 llvm-svn: 285165
* Revert "[XRay] Implement `llvm-xray extract`, start of the llvm-xray tool"Dean Michael Berris2016-10-267-460/+0
| | | | | | Reverts r285155 -- misconfigured tests. llvm-svn: 285156
* [XRay] Implement `llvm-xray extract`, start of the llvm-xray toolDean Michael Berris2016-10-267-0/+460
Usage: llvm-xray extract <object file> [-o <filename or '-'>] The tool gets the XRay instrumentation map from an object file and turns it into YAML. We first support ELF64 sleds on x86_64 binaries, with provision for supporting other supported platforms and formats later. This is the first of a many-part change to fully implement the `llvm-xray` tool. We also define a subcommand registration and dispatch mechanism to be used by other further subcommand implementations for llvm-xray. llvm-svn: 285155
OpenPOWER on IntegriCloud