- Apr 22, 2018
-
-
Jonas Devlieghere authored
Makes error handling more consistent by using the helpers in support. llvm-svn: 330537
-
Jonas Devlieghere authored
Makes error handling more consistent by using the helpers in support. llvm-svn: 330536
-
Brian Gesiak authored
Summary: `llvm-bcanalyzer` prints out the stream type of the file it is analyzing. If the file begins with the LLVM IR magic number, it reports a stream type of "LLVM IR". However, any other bitstream format is reported as "unknown". Add some checks for two other common bitstream formats: Clang AST files, which begin with 'CPCH', and Clang serialized diagnostics, which begin with 'DIAG'. Test Plan: `check-llvm` Reviewers: pcc, aprantl, mehdi_amini, davide, george.karpenkov, JDevlieghere Reviewed By: JDevlieghere Subscribers: JDevlieghere, bruno, davide, llvm-commits Differential Revision: https://reviews.llvm.org/D41979 llvm-svn: 330529
-
- Apr 21, 2018
-
-
Jonas Devlieghere authored
Use convenience helpers in WithColor to print errors, warnings and notes in a few more tools. llvm-svn: 330524
-
- Apr 20, 2018
-
-
Alexander Shaposhnikov authored
This diff fixes sh_link for various types of sections (i.e. for SHT_ARM_EXIDX, SHT_HASH). In particular, this change enables us to use llvm-objcopy with clang -gsplit-dwarf for the target android-arm. Test plan: make check-all Differential revision: https://reviews.llvm.org/D45851 llvm-svn: 330478
-
Florian Hahn authored
This patch adds a StatsFile option to LTO/Config.h and updates both LLVMGold and llvm-lto2 to set it. Reviewers: MatzeB, tejohnson, espindola Reviewed By: tejohnson Differential Revision: https://reviews.llvm.org/D45531 llvm-svn: 330411
-
- Apr 19, 2018
-
-
Gerolf Hoflehner authored
llvm-svn: 330364
-
Francis Visoiu Mistrih authored
When disassembling with -D, skip virtual sections by printing "..." for each symbol. This patch also implements `MachOObjectFile::isSectionVirtual`. Test case comes from: ``` .zerofill __DATA,__common,_data64unsigned,472,3 ``` Differential Revision: https://reviews.llvm.org/D45824 llvm-svn: 330342
-
Teresa Johnson authored
Summary: Instead of manually invoking PrintStatistics, simply invoke llvm_shutdown which will take care of destroying managed statics, and as a side effect will destroy the StatisticInfo ManagedStatic, invoking PrintStatistics when needed. Reviewers: fhahn Subscribers: inglorion, llvm-commits Differential Revision: https://reviews.llvm.org/D45820 llvm-svn: 330341
-
- Apr 18, 2018
-
-
Jonas Devlieghere authored
Use convenience helpers in WithColor to print errors and notes. Differential revision: https://reviews.llvm.org/D45666 llvm-svn: 330267
-
Simon Pilgrim authored
We were calling getExtraProcessorInfo() without checking hasExtraProcessorInfo(), resulting in an assertion. llvm-svn: 330263
-
Jonas Devlieghere authored
Use convenience helpers in WithColor to print errors and warnings. Differential revision: https://reviews.llvm.org/D45658 llvm-svn: 330262
-
Jonas Devlieghere authored
Use convenience helpers in WithColor to print errors and warnings. Differential revision: https://reviews.llvm.org/D45667 llvm-svn: 330261
-
Simon Pilgrim authored
Avoid calling the unique_ptr multiple times. llvm-svn: 330260
-
Simon Pilgrim authored
Makes multiple error messages much easier to read. llvm-svn: 330258
-
Simon Pilgrim authored
Has been useful while trying to get around all the error reporting issues mentioned on PR37049. llvm-svn: 330255
-
Teresa Johnson authored
Summary: Adds support for LTO opt remarks (optionally with hotness) to gold-plugin. Reviewers: anemet Subscribers: fhahn, mehdi_amini, llvm-commits Differential Revision: https://reviews.llvm.org/D45752 llvm-svn: 330252
-
- Apr 17, 2018
-
-
Peter Collingbourne authored
Differential Revision: https://reviews.llvm.org/D45740 llvm-svn: 330222
-
Zachary Turner authored
The DBI stream contains a list of module descriptors. At the beginning of each descriptor is a structure representing the first section contribution in the output file for that module. LLD currently doesn't fill out this structure at all, but link.exe does. So as a precursor to emitting this data in LLD, we first need a way to dump it so that it can be checked. This patch adds support for the dumping, and verifies via a test that LLD emits bogus information. llvm-svn: 330208
-
- Apr 16, 2018
-
-
Adrian McCarthy authored
If a class's first data member is an instance of an empty class, then an assertion in the PrettyClassLayoutGraphicalDumper would fail. The storage is reserved, but it's not marked as in use. As far as I understand, it's the assertion that's faulty, so I removed it and updated the nearby comment. Found by running llvm-pdbutil against its own PDB, and this assertion would fail on HashAdjusters, which is a HashTable whose first data member is a TraitsT, which is a PdbHashTraits<T>, which is an empty struct. (The struct has a specialization for uint32_t, but that specialization doesn't apply here because the T is actually ulittle32_t.) Differential Revision: https://reviews.llvm.org/D45645 llvm-svn: 330135
-
- Apr 14, 2018
-
-
Jonas Devlieghere authored
Create convenience functions for printing error, warning and note to stdout. Previously we had similar functions being used in dsymutil, but given that this pattern is so common it makes sense to make it available globally. llvm-svn: 330091
-
- Apr 13, 2018
-
-
Roman Tereshin authored
llvm-svn: 330070
-
Roman Tereshin authored
As demonstrated by the regression tests added in this patch, the following cases are valid cases: 1. A Function with no DISubprogram attached, but various debug info related to its instructions, coming, for instance, from an inlined function, also defined somewhere else in the same module; 2. ... or coming exclusively from the functions inlined and eliminated from the module entirely. The ValueMap shared between CloneFunctionInto calls within CloneModule needs to contain identity mappings for all of the DISubprogram's to prevent them from being duplicated by MapMetadata / RemapInstruction calls, this is achieved via DebugInfoFinder collecting all the DISubprogram's. However, CloneFunctionInto was missing calls into DebugInfoFinder for functions w/o DISubprogram's attached, but still referring DISubprogram's from within (case 1). This patch fixes that. The fix above, however, exposes another issue: if a module contains a DISubprogram referenced only indirectly from other debug info metadata, but not attached to any Function defined within the module (case 2), cloning such a module causes a DICompileUnit duplication: it will be moved in indirecty via a DISubprogram by DebugInfoFinder first (because of the first bug fix described above), without being self-mapped within the shared ValueMap, and then will be copied during named metadata cloning. So this patch makes sure DebugInfoFinder visits DICompileUnit's referenced from DISubprogram's as it goes w/o re-processing llvm.dbg.cu list over and over again for every function cloned, and makes sure that CloneFunctionInto self-maps DICompileUnit's referenced from the entire function, not just its own DISubprogram attached that may also be missing. The most convenient way of tesing CloneModule I found is to rely on CloneModule call from `opt -run-twice`, instead of writing tedious unit tests. That feature has a couple of properties that makes it hard to use for this purpose though: 1. CloneModule doesn't copy source filename, making `opt -run-twice` report it as a difference. 2. `opt -run-twice` does the second run on the original module, not its clone, making the result of cloning completely invisible in opt's actual output with and without `-run-twice` both, which directly contradicts `opt -run-twice`s own error message. This patch fixes this as well. Reviewed By: aprantl Reviewers: loladiro, GorNishanov, espindola, echristo, dexonsmith Subscribers: vsk, debug-info, JDevlieghere, llvm-commits Differential Revision: https://reviews.llvm.org/D45593 llvm-svn: 330069
-
Rui Ueyama authored
We have a few functions that virtually all command wants to run on process startup/shutdown. This patch adds InitLLVM class to do that all at once, so that we don't need to copy-n-paste boilerplate code to each llvm command's main() function. Differential Revision: https://reviews.llvm.org/D45602 llvm-svn: 330046
-
Sean Fertile authored
Add support for the PPC64_GLINK dynamic tag which is used in the ElfV2 abi. Differential Revision: https://reviews.llvm.org/D45574 llvm-svn: 330038
-
Andrea Di Biagio authored
[llvm-mca] Ensure that instructions with a schedule read-advance are always issued in the right order. Normally, the Scheduler prioritizes older instructions over younger instructions during the instruction issue stage. In one particular case where a dependent instruction had a schedule read-advance associated to one of the input operands, this rule was not correctly applied. This patch fixes the issue and adds a test to verify that we don't regress that particular case. llvm-svn: 330032
-
Clement Courbet authored
Reviewers: gchatelet Subscribers: tschuett, llvm-commits Differential Revision: https://reviews.llvm.org/D45625 llvm-svn: 330026
-
Yunlian Jiang authored
Summary: This enables debug fission on implicit ThinLTO when linked with gold. It will put the .dwo files in a directory specified by user. Reviewers: tejohnson, pcc, dblaikie Reviewed By: pcc Subscribers: JDevlieghere, mehdi_amini, inglorion Differential Revision: https://reviews.llvm.org/D44792 llvm-svn: 329988
-
- Apr 12, 2018
-
-
Brian Gesiak authored
Summary: llvm-diff incorrectly reports that there's a diff when input IR contains undef/zeroinitializer/constantvector/indirectbr. (This happens even if two identical files are given, e.g. `llvm-diff x.ll x.ll`) This is fix to the bug report https://bugs.llvm.org/show_bug.cgi?id=33623 . Reviewers: dexonsmith, rjmccall Reviewed By: rjmccall Subscribers: chenwj, mgrang, llvm-commits Differential Revision: https://reviews.llvm.org/D34856 llvm-svn: 329957
-
Sam Clegg authored
Differential Revision: https://reviews.llvm.org/D45579 llvm-svn: 329947
-
Andrea Di Biagio authored
llvm-svn: 329895
-
Jake Ehrlich authored
TableGen seems to work differently on windows. I'll need to revert this This reverts commit 7a153ddea067b24da59f6a66c733d79205969501. llvm-svn: 329867
-
Jake Ehrlich authored
Swithces from using the command line library to using TableGen. This will allow llvm-strip to exist and allow refinements of the command line syntax. Differential Revision: https://reviews.llvm.org/D44236 llvm-svn: 329863
-
- Apr 11, 2018
-
-
David Blaikie authored
These aren't the .def style files used in LLVM that require a macro defined before their inclusion - they're just basic non-modular includes to stamp out command line flag variables. llvm-svn: 329840
-
Andrea Di Biagio authored
[llvm-mca] Let the Scheduler notify dispatch stall events caused by the lack of scheduling resources. This patch moves part of the logic that notifies dispatch stall events from the DispatchUnit to the Scheduler. The main goal of this patch is to remove (yet another) dependency between the DispatchUnit and the Scheduler. Before this patch, the DispatchUnit had to know about `Scheduler::Event` and how to classify stalls due to the lack of scheduling resources. This patch removes that knowledge and simplifies the logic in DispatchUnit::checkScheduler. This is another change done in preparation for the work to fix PR36663. No functional change intended. llvm-svn: 329835
-
Andrea Di Biagio authored
It caused a buildbot failure (clang-ppc64le-linux-multistage - build #6424) llvm-svn: 329812
-
Andrea Di Biagio authored
llvm-svn: 329807
-
Andrea Di Biagio authored
llvm-svn: 329796
-
Andrea Di Biagio authored
Also, removed flag -verbose in favor of flag -retire-stats. llvm-svn: 329794
-
Andrea Di Biagio authored
Added flag -scheduler-stats to print scheduler related statistics. llvm-svn: 329792
-