summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [asan] Intercept all Heap* related imports from ucrtbase.dllReid Kleckner2016-03-245-23/+171
| | | | | | | | | | | | | | | | | | | | | | ucrtbase.dll appears to be built with some kind of cross-module inlining, because there are calls to imported Heap* routines sprinkled throughout the code. This inlining defeats our attempts to hotpatch malloc, _malloc_base, and related functions. Failing to intercept an allocation or deallocation results in a crash when the program attempts to deallocate or reallocate memory with the wrong allocator. This change patches the IAT of ucrtbase.dll to replace the addresses of the imported Heap* functions with implementations provided by ASan. We don't globally intercept the win32 Heap* functions because they are typically used by system DLLs that run before ASan initializes. Eventually, we may want to intercept them, but for now I think this is the minimal change that will keep ASan stable. Reviewers: samsonov Differential Revision: http://reviews.llvm.org/D18413 llvm-svn: 264327
* [ThinLTO] Use bulk importing in llvm-linkTeresa Johnson2016-03-241-56/+89
| | | | | | | | | | | | | | | Summary: Use bulk importing so we can avoid the use of post-pass metadata linking. Cloned the ModuleLazyLoaderCache from the FunctionImport pass to facilitate this. Reviewers: joker.eph Subscribers: dexonsmith, llvm-commits, joker.eph Differential Revision: http://reviews.llvm.org/D18455 llvm-svn: 264326
* [clang-tidy] Add support for different char-types for the ↵Etienne Bergeron2016-03-242-14/+64
| | | | | | | | | | | | | | | | | | | | | readability-redundant-string-cstr checker. Summary: The current checker is able to recognize std::string but does not recognize other string variants. This patch is adding the support for any string defined with basic_string without considering the the underlying char type. The most common variant is: 'std::wstring' based on 'wchar_t'. There are also other string variants added to the standard: u16string, u32string, etc... Reviewers: alexfh Subscribers: mamai, dblaikie, cfe-commits Differential Revision: http://reviews.llvm.org/D18412 llvm-svn: 264325
* [Hexagon] Generate PIC-specific versions of save/restore routinesKrzysztof Parzyszek2016-03-244-9/+112
| | | | | | | | | | | | In PIC mode, the registers R14, R15 and R28 are reserved for use by the PLT handling code. This causes all functions to clobber these registers. While this is not new for regular function calls, it does also apply to save/restore functions, which do not follow the standard ABI conventions with respect to the volatile/non-volatile registers. Patch by Jyotsna Verma. llvm-svn: 264324
* Change ADL to produce lookup results in a deterministic order. This fixes someRichard Smith2016-03-244-21/+35
| | | | | | | rare issues with nondeterministic diagnostic order, and some very common issues with nondeterministic module builds. llvm-svn: 264323
* Simplify AArch64 isRelRelativeAdhemerval Zanella2016-03-242-17/+36
| | | | | | | | This patch simplifies the isRelRelative for AArch64 and add the missing ones for bootstrap and test-suite. It also adds more testing for shared object creation. llvm-svn: 264322
* Stop relying on mapped_iterator's function having a result_type. That facilityRichard Smith2016-03-241-1/+3
| | | | | | | is deprecated in modern C++ and unnecessary since decltype can be used to query the relevant type. llvm-svn: 264321
* [Statepoints] Fix yet another issue around gc pointer uniqueingSanjoy Das2016-03-244-28/+64
| | | | | | | | | | | | | Given that StatepointLowering now uniques derived pointers before putting them in the per-statepoint spill map, we may end up with missing entries for derived pointers when we visit a gc.relocate on a pointer that was de-duplicated away. Fix this by keeping two maps, one mapping gc pointers to their de-duplicated values, and one mapping a de-duplicated value to the slot it is spilled in. llvm-svn: 264320
* Minor cosmestic changes (NFC)Sanjoy Das2016-03-242-13/+12
| | | | | | | - Reflow comments - Rename function llvm-svn: 264319
* [Docs] Updating CMake docs to include LLVM_OPTIMIZED_TABLEGENChris Bieneman2016-03-241-0/+6
| | | | | | This is based on feedback on llvm-commits from Sean Silvas. llvm-svn: 264318
* [debuginfo] Include dwo_name in the split unit to improve dwp diagnosticsDavid Blaikie2016-03-242-12/+19
| | | | | | | | | | | | | | | | | | | When multiple DWP files are merged together and duplicate DWO IDs are found it's currently difficult to give an actionable error message - the DW_AT_name of the CU could be provided, but might be identical (if the same source file is built into two different configurations), which doesn't help the user identify the problem. When no intermediate DWP files are generated, the path to the two DWO files could be provided - but is lost once the DWOs are merged into a DWP. So, include the name of the DWO (dwo_name) in the split file so that collissions involving a source CU from a DWP can be better diagnosed. (improvements to llvm-dwp using this to come shortly) llvm-svn: 264316
* Fix a missing comma between two string literals.Etienne Bergeron2016-03-241-1/+1
| | | | | | | | | | | | | | | | | Summary: The two literals are currently appended. I'm not sure what was broken by this. Please double check carefully. Silly bug found by an on-going checker for clang-tidy. Reviewers: alexfh, arsenm, rnk Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D18454 llvm-svn: 264315
* [docs] Clarify Error example in Programmer's Manual.Lang Hames2016-03-241-4/+6
| | | | llvm-svn: 264314
* [LLE] Check for mismatching types between the store and the load earlierAdam Nemet2016-03-242-4/+52
| | | | | | | | | | | | | | | isDependenceDistanceOfOne asserts that the store and the load access through the same type. This function is also used by removeDependencesFromMultipleStores so we need to make sure we filter out mismatching types before reaching this point. Now we do this when the initial candidates are gathered. This is a refinement of the fix made in r262267. Fixes PR27048. llvm-svn: 264313
* Use None to construct an empty ArrayRef. NFC.Pete Cooper2016-03-241-1/+1
| | | | | | Suggested by David Blaikie in response to r264234. llvm-svn: 264311
* don't hardcode the name of the llc checks scriptSanjay Patel2016-03-241-5/+2
| | | | | | | | | | We lose the 'utils' directory name in our advertising line with this change. We could retain that, but I don't see the point. This removes a dependency for making the script apply to more than 'llc'. Ie, we'll want to change the script name if it works with opt/clang too. llvm-svn: 264310
* [MC][mips] Add MipsMCInstrAnalysis class and register it as MC instruction ↵Simon Atanasyan2016-03-242-0/+72
| | | | | | | | | | | | | analyzer The `MipsMCInstrAnalysis` class overrides the `evaluateBranch` method and calculates target addresses for branch and calls instructions. That allows llvm-objdump to print functions' names in branch instructions in the disassemble mode. Differential Revision: http://reviews.llvm.org/D18209 llvm-svn: 264309
* Remove unnecessary redirect from testSanjoy Das2016-03-241-2/+2
| | | | llvm-svn: 264308
* reorganize llc checks script to allow more flexibility, part 2; NFCISanjay Patel2016-03-241-73/+104
| | | | | | | | The goal is to enhance this script to be used with opt and clang: Break 'main' into functions and change variable names to be more generic because we want to handle more than x86 asm output. llvm-svn: 264307
* Fix gold tests for llvm-readobj format change.Rafael Espindola2016-03-242-4/+6
| | | | llvm-svn: 264306
* [X86][XOP] Fixed instruction postfixes to more closely match operandsSimon Pilgrim2016-03-242-91/+91
| | | | | | Suggested by Sanjay in D18189 as the multiple folding options in XOP instructions can be tricky llvm-svn: 264305
* [ELF] Follow-up to r264300. Update test case expectations to reflect recent ↵Simon Atanasyan2016-03-2413-22/+63
| | | | | | changes in llvm-readobj. NFC. llvm-svn: 264304
* BitcodeWriter: Move abbreviation for GenericDINode; almost NFCDuncan P. N. Exon Smith2016-03-243-21/+19
| | | | | | | | | | | | Simplify ValueEnumerator and WriteModuleMetadata by shifting the logic for the METADATA_GENERIC_DEBUG abbreviation into WriteGenericDINode. (This is just like r264302, but for GenericDINode.) The only change is that the abbreviation is emitted later in the bitcode, just before the first `GenericDINode` record. This shouldn't be observable though. llvm-svn: 264303
* BitcodeWriter: Move abbreviation for DILocation; almost NFCDuncan P. N. Exon Smith2016-03-243-20/+18
| | | | | | | | | | | Simplify ValueEnumerator and WriteModuleMetadata by shifting the logic for the METADATA_LOCATION abbreviation into WriteDILocation. The only change is that the abbreviation is emitted later in the bitcode, just before the first `DILocation` record. This shouldn't be observable though. llvm-svn: 264302
* BitcodeWriter: Split out named metadata; almost NFCDuncan P. N. Exon Smith2016-03-241-25/+31
| | | | | | | | | | | | Split writeNamedMetadata out of WriteModuleMetadata to write named metadata, and createNamedMetadataAbbrev for the abbreviation. There should be no effective functionality change, although the layout of the bitcode will change. Previously, the abbreviation was emitted at the top of the block, but now it is delayed until immediately before the named metadata records are emitted. llvm-svn: 264301
* [llvm-readobj] Decode st_other symbol's flagsSimon Atanasyan2016-03-2412-18/+102
| | | | | | | | | The patch supports common STV_xxx visibility flags and MIPS specific STO_MIPS_xxx flags. Differential Revision: http://reviews.llvm.org/D18447 llvm-svn: 264300
* Bitcode: Module* -> Module&, NFCDuncan P. N. Exon Smith2016-03-241-5/+5
| | | | llvm-svn: 264299
* AVX-512: Generate KTEST instead of TEST fir i1 vectorsElena Demikhovsky2016-03-242-7/+138
| | | | | | | | | | | | KTEST instruction may be used instead of TEST in this case: %int_sel3 = bitcast <8 x i1> %sel3 to i8 %res = icmp eq i8 %int_sel3, zeroinitializer br i1 %res, label %L2, label %L1 Differential Revision: http://reviews.llvm.org/D18444 llvm-svn: 264298
* ErrorTest.cpp: Move instantiations out of anonymous namespace. gcc didn't ↵NAKAMURA Takumi2016-03-241-4/+3
| | | | | | complain. llvm-svn: 264297
* CodeGen: extend RHS when splitting ATOMIC_CMP_SWAP_WITH_SUCCESS.Tim Northover2016-03-244-5/+79
| | | | | | | | | | | | | If the operation's type has been promoted during type legalization, we need to account for the fact that the high bits of the comparison operand are likely unspecified. The LHS is usually zero-extended, but MIPS sign extends it, so we have to be slightly careful. Patch by Simon Dardis. llvm-svn: 264296
* AMDGPU/SI: Add Polaris supportTom Stellard2016-03-241-0/+8
| | | | | | Patch By: Sonny Jiang llvm-svn: 264295
* [X86][XOP] Merged 128/256 bit 4op instruction definitions. NFCI.Simon Pilgrim2016-03-241-15/+14
| | | | llvm-svn: 264294
* Define ErrorInfo::ID explicitly.NAKAMURA Takumi2016-03-243-3/+7
| | | | llvm-svn: 264293
* Fix another case where we were unconditionally linking linkonce GVs.Rafael Espindola2016-03-243-0/+24
| | | | | | | With this I think that now llvm-link, lld and the gold plugin should agree on which symbol is kept. llvm-svn: 264292
* Error.cpp: Fix a warning. [-Wpedantic]NAKAMURA Takumi2016-03-241-1/+1
| | | | llvm-svn: 264291
* ErrorTest.cpp: Fix an expression, possibly typo.NAKAMURA Takumi2016-03-241-1/+1
| | | | llvm-svn: 264290
* Dsiable FormatStyle::GetStyleOfFile test case for mingw.Eric Liu2016-03-241-1/+1
| | | | llvm-svn: 264289
* Fix resolution of linkonce symbols in comdats.Rafael Espindola2016-03-243-2/+23
| | | | | | | | | | | After comdat processing, the symbols still go through regular symbol resolution. We were not doing it for linkonce symbols since they are lazy linked. This fixes pr27044. llvm-svn: 264288
* [mips] Range check vsplat_simm5 and vsplat_simm10Daniel Sanders2016-03-243-213/+262
| | | | | | | | | | | | Summary: Reviewers: vkalintiris Subscribers: llvm-commits, dsanders Differential Revision: http://reviews.llvm.org/D18177 llvm-svn: 264287
* [CMAKE] Try to find the correct globbing expressionJohannes Doerfert2016-03-241-1/+1
| | | | llvm-svn: 264286
* Remove unsafe AssertZext after promoting result of FP_TO_FP16Pirama Arumuga Nainar2016-03-242-4/+13
| | | | | | | | | | | | | | | Summary: Some target lowerings of FP_TO_FP16, for instance ARM's vcvtb.f16.f32 instruction, do not guarantee that the top 16 bits are zeroed out. Remove the unsafe AssertZext and add tests to exercise this. Reviewers: jmolloy, sbaranga, kristof.beyls, aadg Subscribers: llvm-commits, srhines, aemerson Differential Revision: http://reviews.llvm.org/D18426 llvm-svn: 264285
* [FIX] Handle accesses to "null" in MemIntrinsicsJohannes Doerfert2016-03-243-8/+64
| | | | | | | | | This fixes PR27035. While we now exclude MemIntrinsics from the polyhedral model if they would access "null" we could exploit this even more, e.g., remove all parameter combinations that would lead to the execution of this statement from the context. llvm-svn: 264284
* Restrict clang-format to lib/ [NFC]Johannes Doerfert2016-03-241-1/+1
| | | | llvm-svn: 264283
* [PowerPC] Disable direct moves for extractelement and bitcast in 32-bit modeNemanja Ivanovic2016-03-242-2/+17
| | | | | | | | | | | | This patch corresponds to review: http://reviews.llvm.org/D17711 It disables direct moves on these operations in 32-bit mode since the patterns assume 64-bit registers. The final patch is slightly different from the Phabricator review as the bitcast operations needed to be disabled in 32-bit mode as well. This fixes PR26617. llvm-svn: 264282
* Recommitted r263425 "Supporting all entities declared in lexical scope in ↵Amjad Aboud2016-03-245-20/+92
| | | | | | | | | | LLVM debug info." After fixing PR26942 (the fix is included in this commit). Differential Revision: http://reviews.llvm.org/D18350 llvm-svn: 264281
* Recommitted r263424 "Supporting all entities declared in lexical scope in ↵Amjad Aboud2016-03-2421-91/+916
| | | | | | | | | | LLVM debug info." After fixing PR26942 (the fix is included in this commit). Differential Revision: http://reviews.llvm.org/D18350 llvm-svn: 264280
* [mips] Range check simm10Daniel Sanders2016-03-244-4/+17
| | | | | | | | | | | | Summary: Reviewers: vkalintiris Subscribers: llvm-commits, dsanders Differential Revision: http://reviews.llvm.org/D18148 llvm-svn: 264279
* Added support for different VFSs in format::getStyle. Disable ↵Eric Liu2016-03-243-9/+55
| | | | | | platform-related test case for MS compilers to avoid breaking buildbot. llvm-svn: 264277
* Revert "Added support for different VFSs in format::getStyle."Eric Liu2016-03-241-17/+7
| | | | | | This reverts commit r264253. It is breaking the buildbot http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-windows10pro-fast/builds/2203 llvm-svn: 264276
* Revert "removed redundant comment in format::getStyle."Eric Liu2016-03-241-7/+17
| | | | | | This reverts commit r264254. llvm-svn: 264275
OpenPOWER on IntegriCloud