summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Fix for expanding __pragmas in macro argumentsAmy Huang2019-10-072-33/+58
| | | | | | | | | | | | | | | | | Summary: Avoid parsing __pragma into an annotation token when macro arguments are pre-expanded. This is what clang currently does when parsing _Pragmas. Fixes https://bugs.llvm.org/show_bug.cgi?id=41128, where clang crashed when trying to get the length of an annotation token. Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D68114 llvm-svn: 373950
* [libc++abi] Introduce a LIBCXXABI_LIBRARY_VERSION optionLouis Dionne2019-10-072-1/+6
| | | | | | | | That option controls the 'VERSION' attribute of the libc++abi shared library, which in turn controls the name of the actual dylib being produced. llvm-svn: 373949
* gn build: try to make system-libs.windows.test passNico Weber2019-10-071-1/+1
| | | | llvm-svn: 373948
* AMDGPU/GlobalISel: Handle more G_INSERT casesMatt Arsenault2019-10-074-77/+185
| | | | | | | | | Start manually writing a table to get the subreg index. TableGen should probably generate this, but I'm not sure what it looks like in the arbitrary case where subregisters are allowed to not fully cover the super-registers. llvm-svn: 373947
* GlobalISel: Partially implement lower for G_INSERTMatt Arsenault2019-10-074-13/+193
| | | | llvm-svn: 373946
* AMDGPU/GlobalISel: Fix selection of 16-bit shiftsMatt Arsenault2019-10-074-297/+816
| | | | llvm-svn: 373945
* AMDGPU/GlobalISel: Select VALU G_AMDGPU_FFBH_U32Matt Arsenault2019-10-072-8/+8
| | | | llvm-svn: 373944
* AMDGPU/GlobalISel: Use S_MOV_B64 for inline constantsMatt Arsenault2019-10-073-31/+39
| | | | | | | This hides some defects in SIFoldOperands when the immediates are split. llvm-svn: 373943
* AMDGPU/GlobalISel: Widen 16-bit G_MERGE_VALUEs sourcesMatt Arsenault2019-10-078-5469/+11866
| | | | | | Continue making a mess of merge/unmerge legality. llvm-svn: 373942
* [libc++abi] Do not define -Dcxxabi_shared_EXPORTS when building libc++abiLouis Dionne2019-10-071-1/+3
| | | | | | | CMake sets adds that definition automatically, but we don't need or use it. llvm-svn: 373940
* [OPENMP50]Treat range-based for as canonical loop.Alexey Bataev2019-10-0727-42/+291
| | | | | | | According to OpenMP 5.0, range-based for is also considered as a canonical form of loops. llvm-svn: 373939
* AMDGPU/GlobalISel: Select more G_INSERT casesMatt Arsenault2019-10-072-42/+503
| | | | | | | | | | At minimum handle the s64 insert type, which are emitted in real cases during legalization. We really need TableGen to emit something to emit something like the inverse of composeSubRegIndices do determine the subreg index to use. llvm-svn: 373938
* GlobalISel: Add target pre-isel instructionsMatt Arsenault2019-10-0715-6/+140
| | | | | | | | | | | | | | Allows targets to introduce regbankselectable pseudo-instructions. Currently the closet feature to this is an intrinsic. However this requires creating a public intrinsic declaration. This litters the public intrinsic namespace with operations we don't necessarily want to expose to IR producers, and would rather leave as private to the backend. Use a new instruction bit. A previous attempt tried to keep using enum value ranges, but it turned into a mess. llvm-svn: 373937
* [clang] [cmake] Support LLVM_DISTRIBUTION_COMPONENTS in stand-alone buildMichal Gorny2019-10-071-0/+5
| | | | | | Differential Revision: https://reviews.llvm.org/D68412 llvm-svn: 373936
* Second attempt to add iterator_range::empty()Jordan Rose2019-10-0719-32/+33
| | | | | | | | | | | | Doing this makes MSVC complain that `empty(someRange)` could refer to either C++17's std::empty or LLVM's llvm::empty, which previously we avoided via SFINAE because std::empty is defined in terms of an empty member rather than begin and end. So, switch callers over to the new method as it is added. https://reviews.llvm.org/D68439 llvm-svn: 373935
* [libc++abi] Remove redundant link flags on Apple platformsLouis Dionne2019-10-071-18/+1
| | | | | | | | | | | | | | | These flags are already set when we create the cxxabi_shared target using the SOVERSION and VERSION target properties, and the install_name was already being overriden to '@rpath/libc++abi.1.dylib' by CMake because no 'CMAKE_INSTALL_NAME_DIR' option was specified. So this is effectively a removal of dead code with no intended functionality change. The only think we're losing here is that we used to link against libSystem.B.dylib instead of libSystem.dylib when building libc++abi for macOS 10.6 -- however, I strongly suspect nobody's building libc++abi from source for that target anymore. llvm-svn: 373934
* Try to get clangd tests passing on Windows.Nico Weber2019-10-072-10/+10
| | | | | | Part of PR43592. See also r328645. llvm-svn: 373932
* [platform process list] add a flag for showing the processes of all usersWalter Erquinigo2019-10-075-4/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: For context: https://reviews.llvm.org/D68293 We need a way to show all the processes on android regardless of the user id. When you run `platform process list`, you only see the processes with the same user as the user that launched lldb-server. However, it's quite useful to see all the processes, though, and it will lay a foundation for full apk debugging support from lldb. Before: ``` PID PARENT USER TRIPLE NAME ====== ====== ========== ======================== ============================ 3234 1 aarch64-unknown-linux-android adbd 8034 3234 aarch64-unknown-linux-android sh 9096 3234 aarch64-unknown-linux-android sh 9098 9096 aarch64-unknown-linux-android lldb-server (lldb) ^D ``` Now: ``` (lldb) platform process list -x 205 matching processes were found on "remote-android" PID PARENT USER TRIPLE NAME ====== ====== ========== ======================== ============================ 1 0 init 524 1 init 525 1 init 531 1 ueventd 568 1 logd 569 1 aarch64-unknown-linux-android servicemanager 570 1 aarch64-unknown-linux-android hwservicemanager 571 1 aarch64-unknown-linux-android vndservicemanager 577 1 aarch64-unknown-linux-android qseecomd 580 577 aarch64-unknown-linux-android qseecomd ... 23816 979 com.android.providers.calendar 24600 979 com.verizon.mips.services 27888 979 com.hualai 28043 2378 com.android.chrome:sandboxed_process0 31449 979 com.att.shm 31779 979 com.samsung.android.authfw 31846 979 com.samsung.android.server.iris 32014 979 com.samsung.android.MtpApplication 32045 979 com.samsung.InputEventApp ``` Reviewers: labath,xiaobai,aadsm,clayborg Subscribers: llvm-svn: 373931
* [scudo][standalone] Correct releaseToOS behaviorKostya Kortchinsky2019-10-073-27/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: There was an issue in `releaseToOSMaybe`: one of the criteria to decide if we should proceed with the release was wrong. Namely: ``` const uptr N = Sci->Stats.PoppedBlocks - Sci->Stats.PushedBlocks; if (N * BlockSize < PageSize) return; // No chance to release anything. ``` I meant to check if the amount of bytes in the free list was lower than a page, but this actually checks if the amount of **in use** bytes was lower than a page. The correct code is: ``` const uptr BytesInFreeList = Region->AllocatedUser - (Region->Stats.PoppedBlocks - Region->Stats.PushedBlocks) * BlockSize; if (BytesInFreeList < PageSize) return 0; // No chance to release anything. ``` Consequences of the bug: - if a class size has less than a page worth of in-use bytes (allocated or in a cache), reclaiming would not occur, whatever the amount of blocks in the free list; in real world scenarios this is unlikely to happen and be impactful; - if a class size had less than a page worth of free bytes (and enough in-use bytes, etc), then reclaiming would be attempted, with likely no result. This means the reclaiming was overzealous at times. I didn't have a good way to test for this, so I changed the prototype of the function to return the number of bytes released, allowing to get the information needed. The test added fails with the initial criteria. Another issue is that `ReleaseToOsInterval` can actually be 0, meaning we always try to release (side note: it's terrible for performances). so change a `> 0` check to `>= 0`. Additionally, decrease the `CanRelease` threshold to `PageSize / 32`. I still have to make that configurable but I will do it at another time. Finally, rename some variables in `printStats`: I feel like "available" was too ambiguous, so change it to "total". Reviewers: morehouse, hctim, eugenis, vitalybuka, cferris Reviewed By: morehouse Subscribers: delcypher, #sanitizers, llvm-commits Tags: #llvm, #sanitizers Differential Revision: https://reviews.llvm.org/D68471 llvm-svn: 373930
* Fix Calling Convention through aliasesErich Keane2019-10-074-2/+41
| | | | | | | | | | | | | | r369697 changed the behavior of stripPointerCasts to no longer include aliases. However, the code in CGDeclCXX.cpp's createAtExitStub counted on the looking through aliases to properly set the calling convention of a call. The result of the change was that the calling convention mismatch of the call would be replaced with a llvm.trap, causing a runtime crash. Differential Revision: https://reviews.llvm.org/D68584 llvm-svn: 373929
* [libTooling][NFC] Fix build break in r373916.Yitzhak Mandelbaum2019-10-071-14/+22
| | | | | | r373916 used raw strings inside macro calls, which breaks some builds. llvm-svn: 373928
* [DWARFASTParserClang] Factor out structure-like type parsing, NFCVedant Kumar2019-10-074-432/+473
| | | | | | | | | | | Split out the logic to parse structure-like types into a separate function, in an attempt to reduce the complexity of ParseTypeFromDWARF. Inspired by discussion in https://reviews.llvm.org/D68130. Differential Revision: https://reviews.llvm.org/D68422 llvm-svn: 373927
* [DWARFASTParserClang] Delete commented-out typedef, NFCVedant Kumar2019-10-071-18/+19
| | | | | | (& group together all the protected members & typedefs) llvm-svn: 373926
* ProcessInstanceInfoMatch: Don't match processes with no name if a name match ↵Pavel Labath2019-10-072-1/+18
| | | | | | | | | | | | | | | | | | | | | | | was requested Since D68289, a couple of tests on linux started being extremely flaky. All of them were doing name-based attaching and were failing because they couldn't find an unambiguous process to attach to. The patch above changed the process finding logic, so that failure to find a process name does not constitute an error. This meant that a lot more transient processes showed up in the process list during the test suite run. Previously, these processes would not appear as they would be gone by the time we went to read their executable name, arguments, etc. Now, this alone should not cause an issue were it not for the fact that we were considering a process with no name as if it matched by default (even if we were explicitly searching for a process with a specified name). This meant that any of the "transient" processes with no name would make the name match ambiguous. That clearly seems like a bug to me so I fix that. llvm-svn: 373925
* [clangd] Fix raciness in code completion testsKadir Cetinkaya2019-10-071-11/+19
| | | | | | | | | | | | Reviewers: sammccall, ilya-biryukov Subscribers: MaskRay, jkorous, arphaman, usaxena95, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D68273 llvm-svn: 373924
* [Remarks] Pass StringBlockValue as StringRef.Florian Hahn2019-10-071-1/+1
| | | | | | | | | | | | | | | After changing the remark serialization, we now pass StringRefs to the serializer. We should use StringRef for StringBlockVal, to avoid creating temporary objects, which then cause StringBlockVal.Value to point to invalid memory. Reviewers: thegameg, anemet Reviewed By: thegameg Differential Revision: https://reviews.llvm.org/D68571 llvm-svn: 373923
* [clang-format] [PR27004] omits leading space for noexcept when formatting ↵Paul Hoad2019-10-072-0/+34
| | | | | | | | | | | | | | | | | | | | | | | | | operator delete() Summary: clang-format is incorrectly thinking the parameter parens are part of a cast operation, this is resulting in there sometimes being not space between the paren and the noexcept (and other keywords like volatile etc..) ``` void operator++(int) noexcept; void operator++(int &) noexcept; void operator delete(void *, std::size_t, const std::nothrow_t &)noexcept; ``` Reviewers: klimek, owenpan, mitchell-stellar Reviewed By: mitchell-stellar Subscribers: cfe-commits Tags: #clang-format, #clang Differential Revision: https://reviews.llvm.org/D68481 llvm-svn: 373922
* [clang-format] [NFC] Ensure clang-format is itself clang-formatted.Paul Hoad2019-10-071-34/+37
| | | | | | | | | | | | | | | | | | | Summary: Before making a proposed change, ensure ClangFormat.cpp is fully clang-formatted, no functional change just clang-formatting using the in tree .clang-format. Reviewers: mitchell-stellar Reviewed By: mitchell-stellar Subscribers: Eugene.Zelenko, cfe-commits Tags: #clang-format, #clang Differential Revision: https://reviews.llvm.org/D68551 llvm-svn: 373921
* Fix build errors caused by rL373914.Wei Mi2019-10-072-5/+6
| | | | llvm-svn: 373919
* Codegen - silence static analyzer getAs<> null dereference warnings. NFCI.Simon Pilgrim2019-10-078-12/+12
| | | | | | The static analyzer is warning about potential null dereferences, but in these cases we should be able to use castAs<> directly and if not assert will fire for us. llvm-svn: 373918
* [llvm-profdata] Minor format fixWenlei He2019-10-071-0/+1
| | | | | | | | | | | | | | Summary: Minor format fix for output of "llvm-profdata -show" Reviewers: wmi Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D68440 llvm-svn: 373917
* [libTooling] Add `toString` method to the Stencil classYitzhak Mandelbaum2019-10-073-0/+127
| | | | | | | | | | | | | | | | | Summary: `toString` generates a string representation of the stencil. Patch by Harshal T. Lehri. Reviewers: gribozavr Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D68574 llvm-svn: 373916
* [X86][SSE] getTargetShuffleInputs - move VT.isSimple/isVector checks inside. ↵Simon Pilgrim2019-10-071-4/+11
| | | | | | | | NFCI. Stop all the callers from having to check the value type before calling getTargetShuffleInputs. llvm-svn: 373915
* [SampleFDO] Add compression support for any section in ExtBinary profile formatWei Mi2019-10-0712-112/+387
| | | | | | | | | | | | | Previously ExtBinary profile format only supports compression using zlib for profile symbol list. In this patch, we extend the compression support to any section. User can select some or all of the sections to compress. In an experiment, for a 45M profile in ExtBinary format, compressing name table reduced its size to 24M, and compressing all the sections reduced its size to 11M. Differential Revision: https://reviews.llvm.org/D68253 llvm-svn: 373914
* [LoopVectorize] add test that asserted after cost model change (PR43582); NFCSanjay Patel2019-10-071-0/+127
| | | | llvm-svn: 373913
* Allow update_test_checks.py to not scrub names.David Greene2019-10-072-3/+8
| | | | | | | | | | Add a --preserve-names option to tell the script not to replace IR names. Sometimes tests want those names. For example if a test is looking for a modification to an existing instruction we'll want to make the names. Differential Revision: https://reviews.llvm.org/D68081 llvm-svn: 373912
* Sema - silence static analyzer getAs<> null dereference warnings. NFCI.Simon Pilgrim2019-10-074-11/+11
| | | | | | The static analyzer is warning about potential null dereferences, but in these cases we should be able to use castAs<> directly and if not assert will fire for us. llvm-svn: 373911
* [clang] Add test for FindNextToken in Lexer.Utkarsh Saxena2019-10-071-2/+23
| | | | | | | | | | | | Reviewers: ilya-biryukov Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D68565 llvm-svn: 373910
* Fix another sphinx warning.Kevin P. Neal2019-10-071-2/+2
| | | | | | Differential Revision: https://reviews.llvm.org/D64746 llvm-svn: 373909
* Regenerate ptr-rotate.ll . NFCAmaury Sechet2019-10-071-1/+6
| | | | llvm-svn: 373908
* [Mips] Always save RA when disabling frame pointer eliminationSimon Atanasyan2019-10-077-160/+276
| | | | | | | | | | | | This ensures that frame-based unwinding will continue to work when calling a noreturn function; there is not much use having the caller's frame pointer saved if you don't also have the caller's program counter. Patch by James Clarke. Differential Revision: https://reviews.llvm.org/D68542 llvm-svn: 373907
* [Mips] Fix evaluating J-format branch targetsSimon Atanasyan2019-10-073-4/+41
| | | | | | | | | | | | J/JAL/JALX/JALS are absolute branches, but stay within the current 256 MB-aligned region, so we must include the high bits of the instruction address when calculating the branch target. Patch by James Clarke. Differential Revision: https://reviews.llvm.org/D68548 llvm-svn: 373906
* RewriteModernObjC - silence static analyzer getAs<> null dereference ↵Simon Pilgrim2019-10-071-7/+7
| | | | | | | | warnings. NFCI. The static analyzer is warning about potential null dereferences, but in these cases we should be able to use castAs<> directly and if not assert will fire for us. llvm-svn: 373905
* AST - silence static analyzer getAs<> null dereference warnings. NFCI.Simon Pilgrim2019-10-076-14/+11
| | | | | | The static analyzer is warning about potential null dereferences, but in these cases we should be able to use castAs<> directly and if not assert will fire for us. llvm-svn: 373904
* [LLVM-C] Add bindings to create macro debug infowhitequark2019-10-074-39/+137
| | | | | | | | | | | | | | | | Summary: The C API doesn't have the bindings to create macro debug information. Reviewers: whitequark, CodaFi, deadalnix Reviewed By: whitequark Subscribers: aprantl, hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D58334 llvm-svn: 373903
* Fix sphinx warnings.Kevin P. Neal2019-10-071-2/+2
| | | | | | Differential Revision: https://reviews.llvm.org/D64746 llvm-svn: 373902
* Test commitMirko Brkusanin2019-10-071-1/+1
| | | | | | Fix comment. llvm-svn: 373901
* [FPEnv] Add constrained intrinsics for lrint and lroundKevin P. Neal2019-10-0716-28/+516
| | | | | | | | | | | Earlier in the year intrinsics for lrint, llrint, lround and llround were added to llvm. The constrained versions are now implemented here. Reviewed by: andrew.w.kaylor, craig.topper, cameron.mcinally Approved by: craig.topper Differential Revision: https://reviews.llvm.org/D64746 llvm-svn: 373900
* gn build: use better triple on windowsNico Weber2019-10-071-1/+1
| | | | | | | | | | | The CMake build uses "x86_64-pc-windows-msvc". The "-msvc" suffix is important because e.g. clang/test/lit.cfg.py matches against the suffix "windows-msvc" to compute the presence of the "ms-sdk" and the absence of the "LP64" feature. Differential Revision: https://reviews.llvm.org/D68572 llvm-svn: 373899
* Revert r373888 "[IA] Recognize hexadecimal escape sequences"Nico Weber2019-10-072-21/+1
| | | | | | | | | It broke MC/AsmParser/directive_ascii.s on all bots: Assertion failed: (Index < Length && "Invalid index!"), function operator[], file ../../llvm/include/llvm/ADT/StringRef.h, line 243. llvm-svn: 373898
OpenPOWER on IntegriCloud