summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Add missed file from previous commit (r344838)David Blaikie2018-10-201-0/+3
| | | | llvm-svn: 344839
* DebugInfo: Use DW_OP_addrx in DWARFv5David Blaikie2018-10-204-6/+41
| | | | | | Reuse addresses in the address pool, even in non-split cases. llvm-svn: 344838
* DebugInfo: Implement debug_rnglists.dwoDavid Blaikie2018-10-203-3/+107
| | | | | | | Save space/relocations in .o files by keeping dwo ranges in the dwo file rather than the .o file. llvm-svn: 344837
* DebugInfo: Use address pool forms in debug_rnglistsDavid Blaikie2018-10-2011-121/+140
| | | | | | Save no relocations by reusing addresses from the address pool. llvm-svn: 344836
* llvm-dwarfdump: Support RLE_addressx and RLE_startx_length in .debug_rnglistsDavid Blaikie2018-10-206-31/+123
| | | | llvm-svn: 344835
* DebugInfo: Use debug_addr for non-dwo addresses in DWARF 5David Blaikie2018-10-2017-48/+78
| | | | | | | | Putting addresses in the address pool, even with non-fission, can reduce relocations - reusing the addresses from debug_info and debug_rnglists (the latter coming soon) llvm-svn: 344834
* [CodeGen] Use the mangle context owned by CodeGenModule to correctlyAkira Hatanaka2018-10-202-4/+60
| | | | | | | | | | | | | | | mangle types of lambda objects captured by a block instead of creating a new mangle context everytime a captured field type is mangled. This fixes a bug in IRGen's block helper merging code that was introduced in r339438 where two blocks capturing two distinct lambdas would end up sharing helper functions and the block descriptor. This happened because the ID number used to distinguish lambdas defined in the same context is reset everytime a mangled context is created. rdar://problem/45314494 llvm-svn: 344833
* [X86] Add support for more than 32 features for __builtin_cpu_isCraig Topper2018-10-204-29/+69
| | | | | | | | | | | | | | libgcc supports more than 32 features by adding a new 32-bit variable __cpu_features2. This adds the clang support for checking these feature bits. Patches for compiler-rt and llvm to support this are coming as well. Probably still need an additional patch for target multiversioning in clang. Differential Revision: https://reviews.llvm.org/D53458 llvm-svn: 344832
* [X86] Add additional CPUs and features to Host.cpp and X86TargetParser.def ↵Craig Topper2018-10-202-69/+99
| | | | | | | | | | | | | | | | to match compiler-rt and enable __builtin_cpu_supports/__builtin_cpu_is support in clang Summary: This matches LLVM to D53461 for compiler-rt. Reviewers: echristo, erichkeane Reviewed By: echristo Subscribers: dberris, llvm-commits Differential Revision: https://reviews.llvm.org/D53462 llvm-svn: 344831
* [X86][compiler-rt] Add additional CPUs and features to the cpu detection to ↵Craig Topper2018-10-201-35/+78
| | | | | | | | | | | | | | | | match libgcc Summary: This patch adds additional features and cpus from libgcc. Unfortunately we've overflowed the existing 32-bits of features so we had to add a new __cpu_features2 variable to hold the additional bits. This matches libgcc as far as I can tell. Reviewers: echristo Reviewed By: echristo Subscribers: dberris, llvm-commits Differential Revision: https://reviews.llvm.org/D53461 llvm-svn: 344830
* [libcxx] [test] Don't detect Windows' UCRT with TEST_COMPILER_C1XXBilly Robert O'Neal III2018-10-202-7/+3
| | | | | | The test is trying to avoid saying aligned_alloc on Windows' UCRT, which does not (and can not) implement aligned_alloc. However, it's testing for c1xx, meaning clang on Windows will fail this test when using the UCRT. llvm-svn: 344829
* Make -Wfor-loop-analysis work with C++17Richard Trieu2018-10-202-2/+27
| | | | | | | | | For now, disable the "variable in loop condition not modified" warning to not be emitted when there is a structured binding variable in the loop condition. https://bugs.llvm.org/show_bug.cgi?id=39285 llvm-svn: 344828
* Disable unittests/clangd/JSONTransportTests.cpp on versions of macosxAkira Hatanaka2018-10-201-2/+3
| | | | | | | | earlier than 10.13. rdar://problem/45310173 llvm-svn: 344827
* [WebAssembly] Implement vector sext_inreg and tests with comparisonsThomas Lively2018-10-204-24/+884
| | | | | | | | | | | | Summary: Depends on D53251. Reviewers: aheejin, dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D53252 llvm-svn: 344826
* [WebAssembly] Custom lower i64x2 constant shifts to avoid wrapThomas Lively2018-10-205-3/+81
| | | | | | | | | | | | Summary: Depends on D53057. Reviewers: aheejin, dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D53251 llvm-svn: 344825
* [X86] When checking the bits in cpu_features for function multiversioning ↵Craig Topper2018-10-203-5/+20
| | | | | | | | | | | | | | | | | | | dispatcher in the resolver, make sure all the required bits are set. Not just one of them Summary: The multiversioning code repurposed the code from __builtin_cpu_supports for checking if a single feature is enabled. That code essentially performed (_cpu_features & (1 << C)) != 0. But with the multiversioning path, the mask is no longer guaranteed to be a power of 2. So we return true anytime any one of the bits in the mask is set not just all of the bits. The correct check is (_cpu_features & mask) == mask Reviewers: erichkeane, echristo Reviewed By: echristo Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D53460 llvm-svn: 344824
* [analyzer] Be more plugin-friendly by moving static locals into .cpp files.Artem Dergachev2018-10-2012-17/+51
| | | | | | | | | | | | | | | | | | The GDMIndex functions return a pointer that's used as a key for looking up data, but addresses of local statics defined in header files aren't the same across shared library boundaries and the result is that analyzer plugins can't access this data. Event types are uniqued by using the addresses of a local static defined in a header files, but it isn't the same across shared library boundaries and plugins can't currently handle ImplicitNullDerefEvents. Patches by Joe Ranieri! Differential Revision: https://reviews.llvm.org/D52905 Differential Revision: https://reviews.llvm.org/D52906 llvm-svn: 344823
* [MachineCSE][GlobalISel] Making sure MachineCSE works mid-GlobalISel (again)Roman Tereshin2018-10-204-48/+77
| | | | | | | | | | | | | | | | | | | | | | | | Change of approach, it looks like it's a much better idea to deal with the vregs that have LLTs and reg classes both properly, than trying to avoid creating those across all GlobalISel passes and all targets. The change mostly touches MachineRegisterInfo::constrainRegClass, which is apparently only used by MachineCSE. The changes are NFC for any pipeline but one that contains MachineCSE mid-GlobalISel. NOTE on isCallerPreservedOrConstPhysReg change in MachineCSE: There is no test covering it as the only way to insert a new pass (MachineCSE) from a command line I know of is llc's -run-pass option, which only works with MIR, but MIRParser freezes reserved registers upon MachineFunctions creation, making it impossible to reproduce the state that exposes the issue. Reviwed By: aditya_nandakumar Differential Revision: https://reviews.llvm.org/D53144 llvm-svn: 344822
* [libcxx] [test] Add missing <stdexcept> to map at tests.Billy Robert O'Neal III2018-10-192-3/+5
| | | | | | Reviewed as https://reviews.llvm.org/D50551 llvm-svn: 344821
* Repair thread-unsafe modifications of n_alive in F.pass.cppBilly Robert O'Neal III2018-10-191-4/+10
| | | | | | | | In this example, the ctor of G runs in the main thread in the expression G(), and also in the copy ctor of G() in the DECAY_COPY inside std::thread. The main thread destroys the G() instance at the semicolon, and the started thread destroys the G() after it returns. Thus there is a race between the threads on the n_alive variable. The fix is to join with the background thread before attempting to destroy the G in the main thread. llvm-svn: 344820
* [llvm-objdump] Fix --file-headers (-f) optionPetar Jovanovic2018-10-194-6/+9
| | | | | | | | | | | | | | | | | Changed the format call to match the surrounding code. Previously it was printing an unsigned int while the return type being printed was long unsigned int or wider. This caused problems for big-endian systems which were discovered on mips64. Also, the printed address had less characters than it should because the character count was directly obtained from the number of bytes in the address. The tests were adapted to fit this fix and now use longer addresses. Patch by Milos Stojanovic. Differential Revision: https://reviews.llvm.org/D53403 llvm-svn: 344818
* [LoopVectorize] Loop vectorization for minimum and maximumThomas Lively2018-10-193-0/+82
| | | | | | | | | | | | Summary: Depends on D52766. Reviewers: aheejin, dschuff Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D52767 llvm-svn: 344816
* AMDGPU: Add support pattern for SUB of one bitChangpeng Fang2018-10-193-0/+83
| | | | | | | | | | | | | Summary: Add selection patterns to support one bit Sub. Reviewers: rampitec, arsenm Differential Revision: https://reviews.llvm.org/D52946 llvm-svn: 344815
* [NFC][InstCombine] Undo stray changeEvandro Menezes2018-10-191-2/+2
| | | | | | Undo stray change introduced by r344725. llvm-svn: 344814
* [X86] Remove some left over code from when MVT:i1 was a legal type for AVX512.Craig Topper2018-10-191-3/+0
| | | | llvm-svn: 344813
* Fix typos in assert messageMatt Arsenault2018-10-191-2/+2
| | | | llvm-svn: 344812
* [GISel]: Allow PHIs to be DCEdAditya Nandakumar2018-10-192-1/+2
| | | | | | | | | | | https://reviews.llvm.org/D53304 Currently dead phis are not cleaned up during DCE. This patch allows dead PHI and G_PHI insts to be deleted. Reviewed by: dsanders llvm-svn: 344811
* [PDB] Test variadic function type in PDBAaron Smith2018-10-194-7/+15
| | | | | | This adds back the test case reverted in commit: d260a269200824c5c1c8c6de531fd5aa63db9c35 llvm-svn: 344809
* [X86] In PostprocessISelDAG, start from allnodes_end, not the root.Craig Topper2018-10-191-2/+1
| | | | | | | | | | There is no guarantee the root is at the end if isel created any nodes without morphing them. This includes the nodes created by manual isel from C++ code in X86ISelDAGToDAG. This is similar to r333415 from PowerPC which is where I originally stole the peephole loop from. I don't have a test case, but without this a future patch doesn't work which is how I found it. llvm-svn: 344808
* [DWARF] Make llvm-dwarfdump display location lists in a .dwp file correctly. ↵Wolfgang Pieb2018-10-198-45/+160
| | | | | | | | | | | | | Fixes PR38990. Considers the index when extracting location lists from a .dwp file. Majority of the patch by David Blaikie. Reviewers: dblaikie Differential revision: https://reviews.llvm.org/D53155 llvm-svn: 344807
* Revert "[Driver] Reland: Default Android toolchains to libc++."Dan Albert2018-10-193-62/+65
| | | | | | This reverts commit 84677d5009d613232d360fda27e6e41fb5cb6700. llvm-svn: 344806
* [WebAssembly] Handle undefined lane indices in SIMD patternsThomas Lively2018-10-193-2/+306
| | | | | | | | | | | | | | | | Summary: Undefined indices in shuffles can be used when not all lanes of the output vector will be used. This happens for example in the expansion of vector reduce operations. Regardless, undefs are legal as lane indices in IR and should be supported. Reviewers: aheejin, dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D53057 llvm-svn: 344803
* Fix a use-after-RAUW bug in large GEP splittingKrzysztof Pszeniczny2018-10-192-3/+42
| | | | | | | | | | | | | | | | | | | Summary: Large GEP splitting, introduced in rL332015, uses a `DenseMap<AssertingVH<Value>, ...>`. This causes an assertion to fail (in debug builds) or undefined behaviour to occur (in release builds) when a value is RAUWed. This manifested itself in the 7zip benchmark from the llvm test suite built on ARM with `-fstrict-vtable-pointers` enabled while RAUWing invariant group launders and splits in CodeGenPrepare. This patch merges the large offsets of the argument and the result of an invariant.group strip/launder intrinsic before RAUWing. Reviewers: Prazek, javed.absar, haicheng, efriedma Reviewed By: Prazek, efriedma Subscribers: kristof.beyls, hiraditya, llvm-commits Differential Revision: https://reviews.llvm.org/D51936 llvm-svn: 344802
* PR24164, PR39336: init-captures are not distinct full-expressions.Richard Smith2018-10-199-50/+95
| | | | | | | | | Rather, they are subexpressions of the enclosing lambda-expression, and any temporaries in them are destroyed at the end of that full-expression, or when the corresponding lambda-expression is destroyed if they are lifetime-extended. llvm-svn: 344801
* Add basic test that we perform lifetime extension in the expectedRichard Smith2018-10-191-0/+190
| | | | | | situations. llvm-svn: 344800
* [InstCombine] InstCombine and InstSimplify for minimum and maximumThomas Lively2018-10-199-18/+920
| | | | | | | | | | | | Summary: Depends on D52765 Reviewers: aheejin, dschuff Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D52766 llvm-svn: 344799
* [lldb] Add support in Status::AsCString to retrieve win32 system error stringsAaron Smith2018-10-192-1/+51
| | | | | | | | | | Reviewers: rnk, zturner, aleksandr.urakov Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D53092 llvm-svn: 344798
* [llvm-mca] Remove a stale TODO comment. NFCAndrea Di Biagio2018-10-191-2/+0
| | | | | | | Starting from revision r344334, we can now describe optimizable register-register moves in the machine scheduling models. llvm-svn: 344797
* [ConstantFolding] Constant fold minimum and maximum intrinsicsThomas Lively2018-10-192-0/+150
| | | | | | | | | | | | Summary: Depends on D52764 Reviewers: aheejin, dschuff Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D52765 llvm-svn: 344796
* [Driver] Reland: Default Android toolchains to libc++.Dan Albert2018-10-193-65/+62
| | | | | | | | The sanitizer builder that was broken by this should now be fixed. Original review was https://reviews.llvm.org/D53109 llvm-svn: 344795
* [dwarfdump] Hide ranges in diff-mode.Jonas Devlieghere2018-10-192-1/+13
| | | | | | | | | llvm-dwarfdump --diff should not print DW_AT_ranges. This patch fixes that. Differential revision: https://reviews.llvm.org/D53353 llvm-svn: 344794
* [InstCombine] use m_Neg() in dyn_castNegVal() to match vectors with undef eltsSanjay Patel2018-10-192-7/+8
| | | | llvm-svn: 344793
* [Hexagon] Remove support for V4Krzysztof Parzyszek2018-10-1954-2133/+1919
| | | | llvm-svn: 344791
* [InstCombine] move/add tests for sub/neg; NFCSanjay Patel2018-10-192-52/+228
| | | | | | | These should all be handled using "dyn_castNegVal", but that misses vectors with undef elements. llvm-svn: 344790
* Java annotation declaration being handled correctlyHans Wennborg2018-10-192-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | Previously, Java annotation declarations (@interface AnnotationName) were being handled as ObjC interfaces. This caused the brace formatting to mess up, so that when you had a class with an interface defined in it, it would indent the final brace of the class. It used to format this class like so: class A { @interface B {} } But will now just skip the @interface and format it like so: class A { @interface B {} } Patch by Sam Maier! Differential Revision: https://reviews.llvm.org/D53434 llvm-svn: 344789
* [lldbsuite, windows] Disable two tail call frames tests that fail on WindowsStella Stamenova2018-10-192-0/+5
| | | | | | | | | | | | | | Summary: These tests fail on Windows because of known limitations (a.k.a. bugs) with the current implementation of GetFrameAtIndex Reviewers: asmith, vsk Reviewed By: vsk Subscribers: abidh, lldb-commits Differential Revision: https://reviews.llvm.org/D53415 llvm-svn: 344788
* [clangd] Set workspace root when initializing ClangdServer, disallow mutation.Sam McCall2018-10-194-24/+13
| | | | | | | | | | | | | | | | | | Summary: Rename instance variable to WorkspaceRoot to match what we call it internally. Add fixme to set it automatically. Don't do it yet, clients have assumptions that the constructor won't access the FS. Don't second-guess the provided root. Reviewers: ioeric Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, cfe-commits Differential Revision: https://reviews.llvm.org/D53404 llvm-svn: 344787
* [Hexagon] Remove support for V4Krzysztof Parzyszek2018-10-195-23/+6
| | | | llvm-svn: 344786
* [clang-tidy] Resolve readability-else-after-return false positive for ↵Marek Kurdej2018-10-192-57/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | constexpr if. Summary: It fixes the false positive when using constexpr if and where else cannot be removed: Example: ``` if constexpr (sizeof(int) > 4) // ... return /* ... */; else // This else cannot be removed. // ... return /* ... */; ``` Reviewers: alexfh, aaron.ballman Reviewed By: aaron.ballman Subscribers: lebedev.ri, xazax.hun, cfe-commits Differential Revision: https://reviews.llvm.org/D53372 llvm-svn: 344785
* [ASTImporter] Removed uneeded default case label.Balazs Keri2018-10-191-2/+2
| | | | llvm-svn: 344784
OpenPOWER on IntegriCloud