summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [CodeView] Add a random access type visitor.Zachary Turner2017-05-1222-133/+724
| | | | | | | | | | | | This adds a visitor that is capable of accessing type records randomly and caching intermediate results that it learns about during partial linear scans. This yields amortized O(1) access to a type stream even though type streams cannot normally be indexed. Differential Revision: https://reviews.llvm.org/D33009 llvm-svn: 302936
* [Sema] Support implicit scalar to vector conversionsSimon Dardis2017-05-1210-97/+988
| | | | | | | | | | | | | | | | | | This patch teaches clang to perform implicit scalar to vector conversions when one of the operands of a binary vector expression is a scalar which can be converted to the element type of the vector without truncation following GCC's implementation. If the (constant) scalar is can be casted safely, it is implicitly casted to the vector elements type and splatted to produce a vector of the same type. Contributions from: Petar Jovanovic Reviewers: bruno, vkalintiris Differential Revision: https://reviews.llvm.org/D25866 llvm-svn: 302935
* [include-fixer] Don't throw exception when parsing unknown arguments inHaojian Wu2017-05-121-1/+1
| | | | | | vim script. llvm-svn: 302934
* [AArch64][Falkor] Refine modeling of multiply accumulate forwarding.Geoff Berry2017-05-122-44/+61
| | | | llvm-svn: 302933
* [modules] Simplify module macro handling in non-local-submodule-visibility mode.Richard Smith2017-05-121-12/+7
| | | | | | | | | | | | | | | | | | | | | | | | | When reaching the end of a module, we used to convert its macros to ModuleMacros but also leave them in the MacroDirective chain for the identifier. This meant that every lookup of such a macro would find two (identical) definitions. It also made it difficult to determine the correct owner for a macro when reaching the end of a module: the most recent MacroDirective in the chain could be from an #included submodule rather than the current module. Simplify this: whenever we convert a MacroDirective to a ModuleMacro when leaving a module, clear out the MacroDirective chain for that identifier, and just rely on the ModuleMacro to provide the macro definition information. (We don't want to do this for local submodule visibility mode, because in that mode we maintain a distinct MacroDirective chain for each submodule, and we need to keep around the prior MacroDirective in case we re-enter the submodule -- for instance, if its header is #included more than once in a module build, we need the include guard directive to stick around. But the problem doesn't arise in this case for the same reason: each submodule has its own MacroDirective chain, so the macros don't leak out of submodules in the first place.) llvm-svn: 302932
* [APInt] Add an assert to check for divide by zero in udivrem. NFCCraig Topper2017-05-121-0/+1
| | | | | | udiv and urem already had the same assert. llvm-svn: 302931
* [APInt] Remove unnecessary checks of rhsWords==1 with lhsWords==1 from udiv ↵Craig Topper2017-05-121-2/+2
| | | | | | | | and udivrem. NFC At this point in the code rhsWords is guaranteed to be non-zero and less than or equal to lhsWords. So if lhsWords is 1, rhsWords must also be 1. urem alread had the check removed so this makes all 3 consistent. llvm-svn: 302930
* Clang-format and whitespace cleanup of source codeJonathan Peyton2017-05-1275-54486/+53500
| | | | | | | | | | | | | This patch contains the clang-format and cleanup of the entire code base. Some of clang-formats changes made the code look worse in places. A best effort was made to resolve the bulk of these problems, but many remain. Most of the problems were mangling line-breaks and tabbing of comments. Patch by Terry Wilmarth Differential Revision: https://reviews.llvm.org/D32659 llvm-svn: 302929
* AMDGPU: Add lit.local.cfg to disable global-isel tests when global-isel is ↵Tom Stellard2017-05-121-0/+2
| | | | | | | | disabled This should fix bots broken by r302919. llvm-svn: 302928
* Strip trailing whitespace. NFCI.Simon Pilgrim2017-05-121-7/+7
| | | | llvm-svn: 302927
* [Simplify] Reset all stats between runs.Michael Kruse2017-05-121-0/+3
| | | | llvm-svn: 302926
* [KnownBits] Add bit counting methods to KnownBits struct and use them where ↵Craig Topper2017-05-1217-89/+136
| | | | | | | | | | | | possible This patch adds min/max population count, leading/trailing zero/one bit counting methods. The min methods return answers based on bits that are known without considering unknown bits. The max methods give answers taking into account the largest count that unknown bits could give. Differential Revision: https://reviews.llvm.org/D32931 llvm-svn: 302925
* [ubsan] Enable debug info in test binariesReid Kleckner2017-05-122-6/+2
| | | | | | | This fixes tests that use debug info to check ubsan stack traces. One was XFAILd on Windows and the other was actively failing for weeks. llvm-svn: 302924
* [codeview] Fix assertion failure introduced in r295354 refactoringReid Kleckner2017-05-122-2/+26
| | | | | | | | CodeViewDebug sets Asm to nullptr to disable debug info generation. You can get a .ll file like no-cus.ll from 'clang -gcodeview -g0', which happens in the ubsan test suite. llvm-svn: 302923
* Make sure we have actually written what is expected by the test.Galina Kistanova2017-05-121-1/+1
| | | | llvm-svn: 302922
* [ELF] - Apply clang-format. NFC.George Rimar2017-05-121-13/+28
| | | | llvm-svn: 302921
* Disable two failing darwin lsan testsFrancis Ricci2017-05-122-2/+2
| | | | | | | | These tests don't fail consistently in all cases, but they fail most of the time on the buildbots. Mark as UNSUPPORTED for now to avoid buildbots failing due to XPASS. llvm-svn: 302920
* AMDGPU/GlobalISel: Mark 32-bit integer constants as legalTom Stellard2017-05-122-0/+21
| | | | | | | | | | | | Reviewers: arsenm Reviewed By: arsenm Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, igorb, dstuttard, tpr, t-tye, llvm-commits Differential Revision: https://reviews.llvm.org/D33115 llvm-svn: 302919
* [index] Index template specialization arguments for function templatsAlex Lorenz2017-05-122-0/+49
| | | | | | | | Also ensure that class template specialization arguments are covered rdar://31812032 llvm-svn: 302918
* [asan/win] Re-enable Win64 asan tests on Win8+Reid Kleckner2017-05-121-5/+12
| | | | | | | | Our theory is that reserving large amounts of shadow memory isn't reliable on Win7 and earlier NT kernels. This affects the clang-x64-ninja-win7 buildbot, which uses Windows 7. llvm-svn: 302917
* [APInt] Use MathExtras.h BitsToFloat/Double and Float/DoubleToBits instead ↵Craig Topper2017-05-121-24/+4
| | | | | | | | | | of type punning through a union The functions in MathExtras.h uses a safer memcpy instead of going through a union. Differential Revision: https://reviews.llvm.org/D33116 llvm-svn: 302916
* Simplify DINamespace caching in CGDebugInfoAdrian Prantl2017-05-122-31/+16
| | | | | | | | | | | | | | This addresses review feedback from r302840. By not canonicalizing namespace decls and using lexical decl context instead of lookuing up the semantic decl context we can take advantage of the fact that DINamespaces a reuniqued. This way non-module debug info is unchanged and module debug info still gets distinct namespace declarations when they ocur in different modules. Thanks to Richard Smith for pointing this out! llvm-svn: 302915
* [SPARC] Support 'f' and 'e' inline asm constraints.James Y Knight2017-05-122-0/+16
| | | | | | | | Patch by Patrick Boettcher. Differential Revision: https://reviews.llvm.org/D29117 llvm-svn: 302913
* Disable two failing darwin lsan testsFrancis Ricci2017-05-122-0/+4
| | | | | | These are causing buildbot failures, disable for now. llvm-svn: 302912
* [SPARC] Support 'f' and 'e' inline asm constraints.James Y Knight2017-05-125-3/+77
| | | | | | | | Based on patch by Patrick Boettcher and Chris Dewhurst. Differential Revision: https://reviews.llvm.org/D29116 llvm-svn: 302911
* [x86] add tests for potential vector narrowing optimization (PR32790)Sanjay Patel2017-05-121-0/+111
| | | | llvm-svn: 302910
* [LoopUnroll] Fix a test. REQUIRE should be REQUIRES.Davide Italiano2017-05-121-1/+1
| | | | | | Found by inspection. llvm-svn: 302909
* [NewGVN] Improve debug output a bit. NFCI.Davide Italiano2017-05-121-1/+1
| | | | | | | While debugging a predicate info problem, I noticed this was missing a newline, making the debug output slightly less readable. llvm-svn: 302908
* [DAGCombine] Use SelectionDAG::getAnyExtOrTrunc helper. NFCI.Simon Pilgrim2017-05-121-8/+2
| | | | llvm-svn: 302907
* [NewGVN] Format an assertion and fix a typo. NFCI.Davide Italiano2017-05-121-3/+2
| | | | llvm-svn: 302906
* [NewGVN] Don't incorrectly reset the memory leader.Davide Italiano2017-05-122-1/+69
| | | | | | | | | | This code was missing a check for stores, so we were thinking the congruency class didn't have any memory members, and reset the memory leader. Differential Revision: https://reviews.llvm.org/D33056 llvm-svn: 302905
* Enable lsan test suite on Darwin x86_64 buildsFrancis Ricci2017-05-123-4/+12
| | | | | | | | | | Reviewers: kubamracek, alekseyshl Subscribers: mgorny, llvm-commits Differential Revision: https://reviews.llvm.org/D32191 llvm-svn: 302904
* Optimize orphan placement in a general way.Rafael Espindola2017-05-125-120/+253
| | | | | | | | | | | | | | | | | | | | | | | | | | We used to place orphans by just using compareSectionsNonScript. Then we noticed that since linker scripts can use another order, we should first try match the section to a given PT_LOAD. But there is nothing special about PT_LOAD. The same issue can show up for PT_GNU_RELRO for example. In general, we have to search for the most similar section and put the orphan next to it. Most similar being defined as how long they follow the same code path in compareSecitonsNonScript. That is what this patch does. We now compute a rank for each output section, with a bit for each branch in what was compareSectionsNonScript. With this findOrphanPos is now fully general and orphan placement can be optimized by placing every section with the same rank at once. The included testcase is a variation of many-sections.s that uses allocatable sections to avoid the fast path in the existing code. Without threads it goes form 46 seconds to 0.9 seconds. llvm-svn: 302903
* [Polly][NewPM] Port ScopDetection to the new PassManagerPhilip Pfaffe2017-05-129-191/+266
| | | | | | | | | | | | | | | | Summary: This is a proof of concept of how to port polly-passes to the new PassManager architecture. This approach works ootb for Function-Passes, but might not be directly applicable to Scop/Region-Passes. While we could just run the Analyses/Transforms over functions instead, we'd surrender the nice pipelining behaviour we have now. Reviewers: Meinersbur, grosser Reviewed By: grosser Subscribers: pollydev, sanjoy, nemanjai, llvm-commits Tags: #polly Differential Revision: https://reviews.llvm.org/D31459 llvm-svn: 302902
* Enabling the /bigobj flag for SemaDeclAttr.cpp.Aaron Ballman2017-05-121-0/+1
| | | | | | This resolves compile errors with MSVC 2015 x64 debug builds where SemaDeclAttr.cpp is hitting the section symbol limit. llvm-svn: 302901
* Add dyld to sanitizer procmaps on darwinFrancis Ricci2017-05-122-7/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Sanitizer procmaps uses dyld apis to iterate over the list of images in the process. This is much more performan than manually recursing over all of the memory regions in the process, however, dyld does not report itself in the list of images. In order to prevent reporting leaks from dyld globals and to symbolize dyld functions in stack traces, this patch special-cases dyld and ensures that it is added to the list of modules. This is accomplished by recursing through the memory map of the process until a dyld Mach header is found. While this recursion is expensive, it is run before the full set of images has been loaded in the process, so only a few calls are required. The result is cached so that it never needs to be searched for when the full process memory map exists, as this would be incredibly slow, on the order of minutes for leak sanitizer with only 25 or so libraries loaded. Reviewers: alekseyshl, kubamracek Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D32968 llvm-svn: 302899
* Account for stack redzone when computing sp on darwinFrancis Ricci2017-05-121-0/+4
| | | | | | | | | | | thread_get_register_pointer_values handles the redzone computation automatically, but is marked as an unavailable API function. This patch replicates its logic accounting for the stack redzone on x86_64. Should fix flakiness in the use_stack_threaded test for lsan on darwin. llvm-svn: 302898
* [DAGCombine] Use SelectionDAG::getZExtOrTrunc helper. NFCI.Simon Pilgrim2017-05-121-8/+2
| | | | llvm-svn: 302897
* Use SDValue::getOperand() helper. NFCI.Simon Pilgrim2017-05-122-22/+19
| | | | llvm-svn: 302896
* [Hexagon] Make sure to pass empty struct arguments with nontrivial ctorsKrzysztof Parzyszek2017-05-122-7/+3
| | | | | | | | Thanks to Richard Smith for the suggested fix. This fixes llvm.org/PR33009 llvm-svn: 302895
* Use SDValue::getOperand() helper. NFCI.Simon Pilgrim2017-05-121-22/+19
| | | | llvm-svn: 302894
* clang-format: [JS] support non-null assertions after all identifiers.Martin Probst2017-05-122-1/+3
| | | | | | | | | | | | | | | | | Summary: Previously: x = namespace !; Now: x = namespace!; Reviewers: djasper Subscribers: klimek Differential Revision: https://reviews.llvm.org/D33113 llvm-svn: 302893
* [NFC] [Fortran Support] Run -instnamer on testcasesSiddharth Bhat2017-05-122-40/+40
| | | | llvm-svn: 302892
* [FIX] Fix regression caused by c29f4ed, testcase matches outputSiddharth Bhat2017-05-121-1/+1
| | | | | | | - Commit changed codegen for induction variables - Updated testcase llvm-svn: 302891
* [clang-tidy] Add a test for PR33020Alexander Kornienko2017-05-121-0/+20
| | | | | | Fix committed in clang as r302889. llvm-svn: 302890
* Fix an assertion failure (PR33020).Alexander Kornienko2017-05-121-2/+3
| | | | | | Adding a test separately (tools/extra/test/clang-tidy/misc-use-after-move.cpp). llvm-svn: 302889
* [Polly][CMake] Fix variable name in target exportsPhilip Pfaffe2017-05-121-1/+1
| | | | llvm-svn: 302888
* [msan] Remove a failing test from MemorySanitizer.ICmpRelationalAlexander Potapenko2017-05-121-2/+4
| | | | | | | | | | | This is a follow-up to r302787, which broke MemorySanitizer.ICmpRelational. MSan is now reporting a false positive on the following test case: TestForNotPoisoned((poisoned(-1, 0x80000000U) >= poisoned(-1, 0U))) , which is sort of anticipated, because we're approximating the comparison with an OR of the arguments' shadow values. llvm-svn: 302887
* [NFC] [Fortran Support] Cleanup Fortran Array pattern mactch testcasesSiddharth Bhat2017-05-122-88/+63
| | | | | | | | | | - Move the testcases to ScopInfo/ since the processing takes place in ScopBuilder. - Cleanup testcases, run -polly-canonicalize on them, find minimal set of opt parameters. llvm-svn: 302886
* [AVR] Migrate to new StructType::get owing to Supress all uses of ↵Leslie Zhai2017-05-121-1/+1
| | | | | | | | | | | | LLVM_END_WITH_NULL Reviewers: dylanmckay, jroelofs, RKSimon, serge-sans-paille Reviewed By: serge-sans-paille Differential Revision: https://reviews.llvm.org/D33119 llvm-svn: 302885
OpenPOWER on IntegriCloud