summaryrefslogtreecommitdiffstats
path: root/llvm/test/tools
Commit message (Collapse)AuthorAgeFilesLines
* [sancov] blacklist support.Mike Aizatsky2015-12-168-10/+17
| | | | | | | | | | Summary: Using the blacklist the user can filter own unwanted functions from all outputs. By default blacklist contains "fun:__sancov*" line. Differential Revision: http://reviews.llvm.org/D15364 llvm-svn: 255732
* Test cleanup -- remove duplicate run linesXinliang David Li2015-12-151-4/+0
| | | | llvm-svn: 255673
* [llvm-profdata] Add support for weighted merge of profile data (2nd try)Nathan Slingerland2015-12-157-1/+142
| | | | | | | | | | | | | | | | | | | | Summary: This change adds support for specifying a weight when merging profile data with the llvm-profdata tool. Weights are specified by using the --weighted-input=<weight>,<filename> option. Input files not specified with this option (normal positional list after options) are given a default weight of 1. Adding support for arbitrary weighting of input profile data allows for relative importance to be placed on the input data from multiple training runs. Both sampled and instrumented profiles are supported. Reviewers: davidxl, dnovillo, bogner, silvas Subscribers: silvas, davidxl, llvm-commits Differential Revision: http://reviews.llvm.org/D15306 llvm-svn: 255659
* [llvm-readobj] s/FunctionName/LinkageName/ for codeview dumpingReid Kleckner2015-12-151-18/+18
| | | | | | | The symbol being printed in this field comes from the main symbol table, not 0xF1 subsection. Use LinkageName to make that a lot clearer. llvm-svn: 255596
* Start implementing FDE dumping when printing the eh_frame.Pete Cooper2015-12-141-1/+6
| | | | | | | | | | This code adds some simple decoding of the FDE's in an eh_frame. There's still more to be done in terms of error handling and verification. Also, we need to be able to decode the CFI's. llvm-svn: 255550
* Print the eh_frame section in MachoDump.Pete Cooper2015-12-142-0/+18
| | | | | | | | | | | | | | This is the start of work to dump the contents of the eh_frame section. It currently emits CIE entries. FDE entries will come later. It also needs improved error checking which will follow soon. http://reviews.llvm.org/D15502 Reviewed by Kevin Enderby and Lang Hames. llvm-svn: 255546
* [PGO] Value profiling text format reader/writer supportXinliang David Li2015-12-145-0/+180
| | | | | | | | | This patch adds the missing functionality in parsable text format support for value profiling. Differential Revision: http://reviews.llvm.org/D15212 llvm-svn: 255523
* [llvm-dwp] Deduplicate type unitsDavid Blaikie2015-12-143-0/+35
| | | | | | | | It's O(N^2) because it does a simple walk through the existing types to find duplicates, but that will be fixed in a follow-up commit to use a mapping data structure of some kind. llvm-svn: 255482
* [llvm-dwp] Remove some unused test codeDavid Blaikie2015-12-142-5/+0
| | | | llvm-svn: 255481
* [PGO] Revert r255365: solution incomplete, not handling lambda yetXinliang David Li2015-12-112-7/+0
| | | | llvm-svn: 255369
* [PGO] Stop using invalid char in instr variable names.Xinliang David Li2015-12-112-0/+7
| | | | | | | | | | | | | | Before the patch, -fprofile-instr-generate compile will fail if no integrated-as is specified when the file contains any static functions (the -S output is also invalid). This patch fixed the issue. With the change, the index format version will be bumped up by 1. Backward compatibility is preserved with this change. Differential Revision: http://reviews.llvm.org/D15243 llvm-svn: 255365
* [dsymutil] Ignore absolute symbols in the debug mapFrederic Riss2015-12-113-0/+16
| | | | | | | | | | | | Quoting from the comment added to the code: // Objective-C on i386 uses artificial absolute symbols to // perform some link time checks. Those symbols have a fixed 0 // address that might conflict with real symbols in the object // file. As I cannot see a way for absolute symbols to find // their way into the debug information, let's just ignore those. llvm-svn: 255350
* Slit lib/Linker in two.Rafael Espindola2015-12-101-1/+1
| | | | | | | | | | | | | | | | A linker normally has two stages: symbol resolution and "moving stuff". In lib/Linker there is the complication of lazy linking some globals, but it was still far more mixed than it needed to. This splits the linker into a lower level IRMover and the linker proper. The IRMover just takes a list of globals to move and a callback that lets the user control what is lazy linked. The main motivation is that now tools/gold (and soon lld) can use their own symbol resolution to instruct IRMover what to do. llvm-svn: 255254
* [llvm-dwp] Restructure inputs for test case so they're all grouped togetherDavid Blaikie2015-12-075-2/+2
| | | | llvm-svn: 254922
* [llvm-dwp] Add coverage for both the presence and absence of type units, and ↵David Blaikie2015-12-053-23/+35
| | | | | | fix/remove the emission of a broken tu_index when no type units are present llvm-svn: 254833
* [llvm-dwp] Fix the type_units.test since I renamed its inputs as wellDavid Blaikie2015-12-051-1/+1
| | | | llvm-svn: 254830
* [llvm-dwp] Rename the sufficiently-modified test to reflect it's non-simplicityDavid Blaikie2015-12-055-0/+0
| | | | llvm-svn: 254829
* [llvm-dwp] Support debug_tu_indexDavid Blaikie2015-12-053-13/+38
| | | | llvm-svn: 254827
* [llvm-dwp] Remove some out of date commentsDavid Blaikie2015-12-041-2/+0
| | | | llvm-svn: 254772
* [llvm-dwp] Implement the required on-disk probed hash tableDavid Blaikie2015-12-041-2/+2
| | | | llvm-svn: 254770
* [llvm-dwp] Include the debug_line.dwo sectionDavid Blaikie2015-12-041-3/+3
| | | | | | | | | | | | This probably shouldn't be generated in the .dwo file for CUs, only for TUs, but it's in the sample .dwos (generated by clang) so dwp should reflect that. Arguably the DWP tool could be smart enough to know that the CUs shouldn't need a debug_line.dwo section and skip that even when it's legitimately generated for TUs, but that's a bit more off-book. llvm-svn: 254767
* sancov -not-covered-functions.Mike Aizatsky2015-12-042-6/+12
| | | | | | | | | | | | Summary: The command prints out list of functions that were not entered. To do this, addresses are first converted to function locations. Set operations are used for function locations. Differential Revision: http://reviews.llvm.org/D14889 review llvm-svn: 254742
* [llvm-dwp] Retrieve the DWOID from the CU for the cu_index entryDavid Blaikie2015-12-041-2/+4
| | | | llvm-svn: 254731
* Revert "[llvm-profdata] Add support for weighted merge of profile data"Nathan Slingerland2015-12-046-114/+0
| | | | | | | | This reverts commit b7250858d96b8ce567681214273ac0e62713c661. Reverting in order to investigate Windows test failure. llvm-svn: 254687
* [llvm-profdata] Add support for weighted merge of profile dataNathan Slingerland2015-12-046-0/+114
| | | | | | | | | | | | | | | | | | This change adds support for an optional weight when merging profile data with the llvm-profdata tool. Weights are specified by adding an option ':<weight>' suffix to the input file names. Adding support for arbitrary weighting of input profile data allows for relative importance to be placed on the input data from multiple training runs. Both sampled and instrumented profiles are supported. Reviewers: dnovillo, bogner, davidxl Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D14547 llvm-svn: 254669
* [PGO] Add v2 format compatibility testXinliang David Li2015-12-032-0/+20
| | | | llvm-svn: 254572
* [llvm-dwp] Include only the non-empty columns in the cu_indexDavid Blaikie2015-12-021-1/+5
| | | | llvm-svn: 254555
* [llvm-profdata] Change instr prof counter overflow to saturate rather than ↵Nathan Slingerland2015-12-021-4/+12
| | | | | | | | | | | | | | discard Summary: This changes overflow handling during instrumentation profile merge. Rathar than throwing away records that would result in counter overflow, merged counts are instead clamped to the maximum representable value. A warning about counter overflow is still surfaced to the user as before. Reviewers: dnovillo, davidxl, silvas Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D14893 llvm-svn: 254525
* [llvm-dwp] Emit a rather fictional debug_cu_indexDavid Blaikie2015-12-021-6/+7
| | | | | | | | | | | | | | This is very rudimentary support for debug_cu_index, but it is enough to allow llvm-dwarfdump to find the offsets for contributions and correctly dump debug_info. It will need to actually find the real signature of the unit and build the real hash table with the right number of buckets, as per the DWP specification. It will also need to be expanded to cover the tu_index as well. llvm-svn: 254489
* [llvm-dwp] Deduplicate strings in the debug_str.dwo sectionDavid Blaikie2015-12-011-4/+2
| | | | | | | Also, ensure that references to those strings in debug_str_offsets.dwo correctly refer to the deduplicated strings. llvm-svn: 254441
* [llvm-dwp] Correctly update debug_str_offsets.dwo when linking dwo filesDavid Blaikie2015-12-011-3/+3
| | | | | | | | | | This doesn't deduplicate strings in the debug_str section, nor does it properly wire up the index so that debug_info can /find/ these strings, but it does correct the str_offsets specifically. Follow up patches to address those related/next issues. llvm-svn: 254431
* [llvm-dwp] Initial partial prototypeDavid Blaikie2015-12-016-0/+67
| | | | | | | | | | | | | | | | | | | This just concatenates the common DWP sections without doing any of the fancy DWP things like: 1) update str_offsets 2) deduplicating strings 3) merging/creating cu/tu_index Patches for these will follow shortly. (also not sure about target triple/object file type for this tool - do I really need a whole triple just to write an object file that contains purely static/hardcoded bytes in each section? & I guess I should just pick it based on the first input, maybe, rather than hardcoding for now - but we only produce .dwo on ELF platforms with objcopy for now anyway) llvm-svn: 254355
* Add a passing test.Rafael Espindola2015-11-292-0/+28
| | | | | | When a comdat is discarded, any globals defined in it become undefined. llvm-svn: 254258
* Don't depend on the order the IR is copied.Rafael Espindola2015-11-291-12/+13
| | | | llvm-svn: 254257
* Don't depend on the order the IR is copied.Rafael Espindola2015-11-291-14/+14
| | | | llvm-svn: 254256
* Test both input file orders.Rafael Espindola2015-11-271-2/+7
| | | | llvm-svn: 254186
* Add missing file.Rafael Espindola2015-11-271-0/+3
| | | | llvm-svn: 254185
* Make the test a bit more interesting.Rafael Espindola2015-11-271-2/+8
| | | | | | It now covers a regular function replacing an available_externally one. llvm-svn: 254184
* Add a few passing lto tests.Rafael Espindola2015-11-2612-0/+168
| | | | | | | | | | | | | | | I found these while trying to get a prototype to bootstrap. They cover things like * Handling of non linker visible stuff (append, available_externally) * Type merging * Alias to dropped globals * Dropping linkage when converting to a declaration. These should hopefully be generally useful for anyone refactoring the plugin. llvm-svn: 254174
* Make this test a bit more strict.Rafael Espindola2015-11-241-9/+18
| | | | | | It now tests with files in both orders. llvm-svn: 253993
* Add an already passing test.Rafael Espindola2015-11-242-0/+28
| | | | | | | | | This tests that a declaration can resolve to an alias. I broke this locally while prototyping a change and it looks like a nice test to have. llvm-svn: 253984
* [PGO] Add --text option for llvm-profdata show|merge commandsXinliang David Li2015-11-232-0/+61
| | | | | | | | | | | | | | The new option is similar to the SampleProfile dump option. - dump raw/indexed format into text profile format - merge the profile and output into text profile format. Note that Value Profiling data text format is not yet designed. That functionality will be added later. Differential Revision: http://reviews.llvm.org/D14894 llvm-svn: 253913
* Have a single way for creating unique value names.Rafael Espindola2015-11-222-9/+9
| | | | | | | | | | | We had two code paths. One would create names like "foo.1" and the other names like "foo1". For globals it is important to use "foo.1" to help C++ name demangling. For locals there is no strong reason to go one way or the other so I kept the most common mangling (foo1). llvm-svn: 253804
* [ThinLTO] Handle bitcode without function summary sections gracefullyTeresa Johnson2015-11-211-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Several fixes to the handling of bitcode files without function summary sections so that they are skipped during ThinLTO processing in llvm-lto and the gold plugin when appropriate instead of aborting. 1 Don't assert when trying to add a FunctionInfo that doesn't have a summary attached. 2 Skip FunctionInfo structures that don't have attached function summary sections when trying to create the combined function summary. 3 In both llvm-lto and gold-plugin, check whether a bitcode file has a function summary section before trying to parse the index, and skip the bitcode file if it does not. 4 Fix hasFunctionSummaryInMemBuffer in BitcodeReader, which had a bug where we returned to early while looking for the summary section. Also added llvm-lto and gold-plugin based tests for cases where we don't have function summaries in the bitcode file. I verified that either the first couple fixes described above are enough to avoid the crashes, or fixes 1,3,4. But have combined them all here for added robustness. Reviewers: joker.eph Subscribers: llvm-commits, joker.eph Differential Revision: http://reviews.llvm.org/D14903 llvm-svn: 253796
* SamplePGO - Sort samples by source location when emitting as text.Diego Novillo2015-11-192-2/+2
| | | | | | | | When dumping function samples or writing them out as text format, it helps if the samples are emitted sorted by source location. The sorting of the maps is a bit slow, so we only do it on demand. llvm-svn: 253568
* [PGO] Value profiling supportBetul Buyukkurt2015-11-187-25/+64
| | | | | | | | | This change introduces an instrumentation intrinsic instruction for value profiling purposes, the lowering of the instrumentation intrinsic and raw reader updates. The raw profile data files for llvm-profdata testing are updated. llvm-svn: 253484
* [LTO] Appease buildbots take 3James Molloy2015-11-181-2/+2
| | | | | | | | This time I've found a linux box and checked it there. This test now passes. Because I'd introduced an undefined reference in @bar, gold now returns an error. This doesn't matter for the test itself, because it also emits the remarks the test is checking for. But it does cause LIT to notice a nonzero return code which it faults on. llvm-svn: 253454
* [LTO] Buildbot appeasing take 2James Molloy2015-11-181-1/+1
| | | | | | Let's try again. This time using the right function signature. It's a real pity I can't run this on a darwin machine... llvm-svn: 253453
* [LTO] Fix up test/tools/gold/X86/remarks.llJames Molloy2015-11-181-1/+4
| | | | | | It needs the same fixes as in test/LTO/X86/remarks.ll, but this test appears not to get run on my system (but does on the buildbot). Strange. llvm-svn: 253452
* [llvm-objdump] Use the COFF export table for additional symbolsDavid Majnemer2015-11-182-0/+8
| | | | | | | | | Most linked executables do not have a symbol table in COFF. However, it is pretty typical to have some export entries. Use those entries to inform the disassembler about potential function definitions and call targets. llvm-svn: 253429
OpenPOWER on IntegriCloud