summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [CFG] Provide construction contexts for return value constructors.Artem Dergachev2018-02-123-2/+98
| | | | | | | | | | | When the current function returns a C++ object by value, CFG elements for constructors that construct the return values can now be queried to discover that they're indeed participating in construction of the respective return value at the respective return statement. Differential Revision: https://reviews.llvm.org/D42875 llvm-svn: 324952
* Do not use Decompressor::isCompressedELFSection. NFC.Rui Ueyama2018-02-121-1/+3
| | | | | | | | | In order to identify a compressed section, we check if a section name starts with ".zdebug" or the section has SHF_COMPRESSED flag. We already use the knowledge in this function. So hiding that check in isCompressedELFSection doesn't make sense. llvm-svn: 324951
* [WebAssembly] MC: Remove redundant `private` specifiersSam Clegg2018-02-122-3/+0
| | | | | | This is inline with the other MCSection and MCSymbol subclasses llvm-svn: 324950
* Remove 'z' in .zdebug when decompressing a section.Rui Ueyama2018-02-124-31/+47
| | | | | | | | | | | When decompressing a compressed debug section, we drop SHF_COMPRESSED flag but we didn't drop "z" in ".zdebug" section name. This patch does that for consistency. This change also fixes the issue that .zdebug_gnu_pubnames are not dropped when we are creating a .gdb_index section. llvm-svn: 324949
* Look for 32-bit libraries in /usr/lib32 for MIPS O32 on FreeBSD.John Baldwin2018-02-122-0/+8
| | | | | | | | | | | | | | | Summary: FreeBSD N64 MIPS systems can include 32-bit libraries for O32 in /usr/lib32 similar to the 32-bit compatibility libraries provided for FreeBSD/amd64 and FreeBSD/powerpc64. Reviewers: dim Reviewed By: dim Differential Revision: https://reviews.llvm.org/D42972 llvm-svn: 324948
* [x86] add select test to show there's no single right answer (PR28968); NFCSanjay Patel2018-02-121-0/+29
| | | | llvm-svn: 324947
* [analyzer] [tests] Fix a typo in analyzer testing script.George Karpenkov2018-02-121-1/+1
| | | | | | Incorrect option instance construction. llvm-svn: 324946
* Simplify switch statement (NFC)Adrian Prantl2018-02-121-5/+3
| | | | llvm-svn: 324945
* s/uncompress/decompress/g.Rui Ueyama2018-02-124-12/+12
| | | | | | | In lld, we use both "uncompress" and "decompress" which is confusing. Since LLVM uses "decompress", we should use the same term. llvm-svn: 324944
* [LSR] Avoid UB overflow when examining reuse opportunitiesGerolf Hoflehner2018-02-122-0/+31
| | | | llvm-svn: 324943
* [WebAssembly] Fix casting MCSymbol to MCSymbolWasm on ELFJacob Gravelle2018-02-121-3/+5
| | | | | | | | | | | | | | Summary: wasm32-unknown-unknown-elf has MCSymbols that are not MCSymbolWasms, so we need a non-asserting cast here. Reviewers: dschuff, sunfish Subscribers: jfb, sbc100, aheejin, llvm-commits Differential Revision: https://reviews.llvm.org/D43205 llvm-svn: 324942
* [DAG] make binops with undef operands consistent with IRSanjay Patel2018-02-125-30/+27
| | | | | | | | | | | | | | | | | | | | | This started by noticing that scalar and vector types were producing different results with div ops in PR36305: https://bugs.llvm.org/show_bug.cgi?id=36305 ...but the problem is bigger. I couldn't keep it straight without a table, so I'm attaching that as a PDF to the review. The x86 tests in undef-ops.ll correspond to that table. Green means that instsimplify and the DAG agree on the result for all types. Red means the DAG was returning undef when IR was not. Yellow means the DAG was returning a non-undef result when IR returned undef. This patch assumes that we're currently doing the right thing in IR. Note: I couldn't find any problems with lowering vector constants as the code comments were warning, but those comments were written long ago in rL36413 . Differential Revision: https://reviews.llvm.org/D43141 llvm-svn: 324941
* [AArch64] Fixes for ARMv8.2-A FP16 scalar intrinsic - clang portionAbderrazek Zaafrani2018-02-122-48/+145
| | | | | | https://reviews.llvm.org/D42993 llvm-svn: 324940
* [X86] Simplify X86DAGToDAGISel::matchBEXTRFromAnd by creating an ↵Craig Topper2018-02-125-38/+43
| | | | | | | | X86ISD::BEXTR node and calling Select. Add isel patterns to recognize this node. This removes a bunch of special case code for selecting the immediate and folding loads. llvm-svn: 324939
* [X86] Remove unused multiclass argument. NFCCraig Topper2018-02-121-3/+3
| | | | llvm-svn: 324938
* [GlobalMerge] Allow merging of dllexported variablesMartin Storsjo2018-02-122-6/+15
| | | | | | | | | If merging them, the dllexport attribute needs to be brought along to the new GlobalAlias. Differential Revision: https://reviews.llvm.org/D43192 llvm-svn: 324937
* Fix the syntax highlighting of strings in dwarfdump.Adrian Prantl2018-02-121-4/+4
| | | | llvm-svn: 324936
* Factor out common condition into an easier to understand helper function (NFC).Adrian Prantl2018-02-122-2/+12
| | | | llvm-svn: 324935
* [ScopBuilder] scalar-indep: Fix mutually referencing PHIs.Michael Kruse2018-02-123-0/+165
| | | | | | | | | | | | | | Two or more PHIs mutually using each other directly or indirectly as incoming value could cause that a PHI WRITE be added before the PHI READ (i.e. it overwrites the current incoming value with the next incoming value before it being read). Fix by ensuring that the PHI WRITE and PHI READ are in the same statement. This should fix the miscompile of SingleSource/Benchmark/Misc/whetstone from the test-suite. llvm-svn: 324934
* Move the debuginfo-dce-or test into debuginfo-variables.ll, NFCVedant Kumar2018-02-122-46/+10
| | | | llvm-svn: 324933
* Revert "[ThinLTO] Add GraphTraits for FunctionSummaries"Volodymyr Sapsai2018-02-124-181/+2
| | | | | | | | | It caused assertion failure Assertion failed: (!DD.IsLambda && !MergeDD.IsLambda && "faked up lambda definition?"), function MergeDefinitionData, file /Users/buildslave/jenkins/workspace/clang-stage1-configure-RA/llvm/tools/clang/lib/Serialization/ASTReaderDecl.cpp, line 1675. on the second stage build bots. llvm-svn: 324932
* Revert "Follow on to rL324854 (Added tests)" as part of r324854 revert.Volodymyr Sapsai2018-02-121-58/+0
| | | | | | r324854 caused broken build on the second stage build bots. llvm-svn: 324931
* Remove the pubnames support from the Xcode project.Jim Ingham2018-02-121-216/+24
| | | | llvm-svn: 324930
* [DebugInfo] Update Checksum handling in CGDebugInfoScott Linder2018-02-122-12/+16
| | | | | | Update to match new DIFile API. llvm-svn: 324929
* [DebugInfo] Unify ChecksumKind and Checksum value in DIFileScott Linder2018-02-1217-122/+198
| | | | | | | | | Rather than encode the absence of a checksum with a Kind variant, instead put both the kind and value in a struct and wrap it in an Optional. Differential Revision: http://reviews.llvm.org/D43043 llvm-svn: 324928
* [InstCombine] X / (X * Y) --> 1.0 / YSanjay Patel2018-02-122-6/+12
| | | | | | | | | This is similar to the instsimplify fold added with D42385 ( rL323716 ) ...but this can't be in instsimplify because we're creating/morphing a different instruction. llvm-svn: 324927
* [InstCombine] add tests for missing fdiv fold; NFCSanjay Patel2018-02-121-0/+42
| | | | llvm-svn: 324926
* Remove dead code for handling DWARF pubnamesAdrian McCarthy2018-02-127-540/+0
| | | | | | | | | | | | Summary: LLDB doesn't use this code, the code has no tests, and the code does suspicious things like hashing pointers to strings instead of the strings themselves. Subscribers: sanjoy, mgorny, JDevlieghere Differential Revision: https://reviews.llvm.org/D43202 llvm-svn: 324925
* [InstCombine] regenerate checks; NFCSanjay Patel2018-02-121-28/+44
| | | | llvm-svn: 324924
* Implement LWG 2835 - fix <tgmath.h>Marshall Clow2018-02-122-5/+13
| | | | llvm-svn: 324923
* [InstCombine] various clean-ups for div transforms; NFCSanjay Patel2018-02-121-108/+94
| | | | llvm-svn: 324922
* [testsuite] Reintroduce test to check leaking.Davide Italiano2018-02-123-0/+141
| | | | | | | It wasn't python leaking, it was lldb. Thanks to Pavel for the explanation. Pointy-hat to me. llvm-svn: 324919
* Add a unit test for Driver::getDefaultModuleCachePath().Adrian Prantl2018-02-122-0/+29
| | | | llvm-svn: 324917
* [LICM] update BlockColors after splitting predecessorsJun Bum Lim2018-02-122-8/+84
| | | | | | | | | | Update BlockColors after splitting predecessors. Do not allow splitting EHPad for sinking when the BlockColors is not empty, so we can simply assign predecessor's color to the new block. Fixes PR36184 llvm-svn: 324916
* Further cleanup to Driver mode code, as suggested by dblaikie [NFC]Erich Keane2018-02-121-9/+7
| | | | llvm-svn: 324915
* [libclang] Add `CXSymbolRole role` to CXIdxEntityRefInfoFangrui Song2018-02-127-15/+85
| | | | | | | | | | | | | | | | | | Summary: CXIdxEntityRefInfo contains the member `CXIdxEntityRefKind kind;` to differentiate implicit and direct calls. However, there are more roles defined in SymbolRole. Among them, `Read/Write` are probably the most useful ones as they can be used to differentiate Read/Write occurrences of a symbol for document highlight in a text document. See `export namespace DocumentHighlightKind` on https://microsoft.github.io/language-server-protocol/specification Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D42895 llvm-svn: 324914
* [Sema] Don't mark plain MS enums as fixedReid Kleckner2018-02-126-48/+92
| | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This fixes a flaw in our AST: PR27098 MSVC always gives plain enums the underlying type 'int'. Clang does this as well, but we claim the enum is "fixed", as if the user actually wrote ': int'. It means we end up emitting spurious -Wsign-compare warnings on code like this: enum Vals { E1, E2, E3 }; bool f(unsigned v1, Vals v2) { return v1 == v2; } We think 'v2' can take on negative values because we think 'Vals' is fixed. This fixes that. Reviewers: rsmith Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D43110 llvm-svn: 324913
* [AArch64] Fixes for ARMv8.2-A FP16 scalar intrinsic - llvm portionAbderrazek Zaafrani2018-02-122-0/+36
| | | | | | https://reviews.llvm.org/D42993 llvm-svn: 324912
* Implement LWG#2908 - The less-than operator for shared pointers could do ↵Marshall Clow2018-02-122-3/+8
| | | | | | more, and mark 2878 as complete as well (we already do that) llvm-svn: 324911
* [X86] Add missing scheduling class tag for i64 absolute address movesSimon Pilgrim2018-02-121-5/+5
| | | | | | | | Expand existing SchedRW to encompass these like it did for the other memory offset movs - added comments to closing braces to keep track of def scopes. We only tagged it with the itinerary class, so completeness checks were erroneously passed (PR35639). llvm-svn: 324910
* Update target-note-test to be current with the AMDGPU changesErich Keane2018-02-121-9/+9
| | | | llvm-svn: 324909
* [AArch64] Improve v8.1-A code-gen for atomic load-andOliver Stannard2018-02-1211-1/+136
| | | | | | | | | | | | | | | | | | | | | | | | Armv8.1-A added an atomic load-clear instruction (which performs bitwise and with the complement of it's operand), but not a load-and instruction. Our current code-generation for atomic load-and always inserts an MVN instruction to invert its argument, even if it could be folded into a constant or another instruction. This adds lowering early in selection DAG to convert a load-and operation into an xor with -1 and a load-clear, allowing the normal DAG optimisations to work on it. To do this, I've had to add a new ISD opcode, ATOMIC_LOAD_CLR. I don't see any easy way to do this with an AArch64-specific ISD node, because the code-generation for atomic operations assumes the SDNodes are of type AtomicSDNode. I've left the old tablegen patterns in because they are still needed for global isel. Differential revision: https://reviews.llvm.org/D42478 llvm-svn: 324908
* Make attribute-target on a Definition-after-use update the LLVM attributesErich Keane2018-02-124-40/+71
| | | | | | | | | | | | | | | As reported here: https://bugs.llvm.org/show_bug.cgi?id=36301 The issue is that the 'use' causes the plain declaration to emit the attributes to LLVM-IR. However, if the definition added it later, these would silently disappear. This commit extracts that logic to its own function in CodeGenModule, and has the attribute-applications done during 'definition' update the attributes properly. Differential Revision: https://reviews.llvm.org/D43095 llvm-svn: 324907
* [sanitizer] Size class map & local cache improvementsKostya Kortchinsky2018-02-123-40/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: - Reland rL324263, this time allowing for a compile-time decision as to whether or not use the 32-bit division. A single test is using a class map covering a maximum size greater than 4GB, this can be checked via the template parameters, and allows SizeClassAllocator64PopulateFreeListOOM to pass; - `MaxCachedHint` is always called on a class id for which we have already computed the size, but we still recompute `Size(class_id)`. Change the prototype of the function to work on sizes instead of class ids. This also allows us to get rid of the `kBatchClassID` special case. Update the callers accordingly; - `InitCache` and `Drain` will start iterating at index 1: index 0 contents are unused and can safely be left to be 0. Plus we do not pay the cost of going through an `UNLIKELY` in `MaxCachedHint`, and touching memory that is otherwise not used; - `const` some variables in the areas modified; - Remove an spurious extra line at the end of a file. Reviewers: alekseyshl, tl0gic, dberris Reviewed By: alekseyshl, dberris Subscribers: dberris, kubamracek, delcypher, llvm-commits, #sanitizers Differential Revision: https://reviews.llvm.org/D43088 llvm-svn: 324906
* [X86][AVX512] Add missing scheduling class tag for KMOVB/KMOVW/KMOVD/KMOVQ ↵Simon Pilgrim2018-02-121-3/+5
| | | | | | | | moves/loads/stores. We only tagged it with the itinerary class, so completeness checks were erroneously passed (PR35639). llvm-svn: 324905
* [OpenMP][libomptarget] Enable the compilation of multiple bc libraries for ↵Gheorghe-Teodor Bercea2018-02-122-43/+53
| | | | | | | | | | | | | | | | | | | runtime inlining Summary: Different NVIDIA GPUs support different compute capabilities. To enable the inlining of runtime functions and the best performance on different generations of NVIDIA GPUs, a bc library for each compute capability needs to be compiled. The same compiler build will then be usable in conjunction with multiple generations of NVIDIA GPUs. To differentiate between versions of the same bc lib, the output file name will contain the compute capability ID. Depends on D14254 Reviewers: Hahnfeld, hfinkel, carlo.bertolli, caomhin, ABataev, grokos Reviewed By: Hahnfeld, grokos Subscribers: guansong, mgorny, openmp-commits Differential Revision: https://reviews.llvm.org/D41724 llvm-svn: 324904
* [AArch64] Refactor identification of SIMD immediatesEvandro Menezes2018-02-121-368/+280
| | | | | | | | Get rid of icky goto loops and make the code easier to maintain (NFC). Differential revision: https://reviews.llvm.org/D42723 llvm-svn: 324903
* Add Invalid-note test negllected in R324673,324674,324675,324676Erich Keane2018-02-121-0/+162
| | | | llvm-svn: 324902
* [X86][AVX512] Add missing scheduling class tag for ↵Simon Pilgrim2018-02-121-3/+7
| | | | | | | | | | VMOVQ/VMOVHLPS/VMOVLHPS/VMOVHPD/VMOVHPS/VMOVLPD/VMOVLPS Tag AVX512 variants to match SSE/AVX originals. We only tagged it with the itinerary class, so completeness checks were erroneously passed (PR35639). llvm-svn: 324901
* Re-commit r324490: [DebugInfo] Improvements to representation of enumeration ↵Momchil Velikov2018-02-125-10/+112
| | | | | | | | types (PR36168) Differential revision: https://reviews.llvm.org/D42736 llvm-svn: 324900
OpenPOWER on IntegriCloud