summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [DAG] Pull out ComputeNumSignBits call to make debugging easier. NFCI.Simon Pilgrim2019-04-071-2/+2
| | | | llvm-svn: 357861
* [X86][SSE] SimplifyDemandedBitsForTargetNode - Add initial PACKSS supportSimon Pilgrim2019-04-076-187/+67
| | | | | | | | | | In the case where we only want the sign bit (e.g. when using PACKSS truncation of comparison results for MOVMSK) then we can just demand the sign bit of the source operands. This makes use of the fact that PACKSS saturates out of range values to the min/max int values - so the sign bit is always preserved. Differential Revision: https://reviews.llvm.org/D60333 llvm-svn: 357859
* [llvm-objdump] Fix split of source lines; don't ltrim source linesFangrui Song2019-04-072-24/+19
| | | | | | | | | If the file does not end with a newline, it may be dropped. Fix the splitting algorithm. Also delete an unnecessary SourceCache lookup. llvm-svn: 357858
* [llvm-objdump] Simplify some ELF typename: ELFFile<ELFT>::Elf_xxx -> ELFT::xxxFangrui Song2019-04-071-11/+4
| | | | llvm-svn: 357857
* .Fangrui Song2019-04-071-17/+8
| | | | llvm-svn: 357856
* [llvm-objdump] Simplify Expected<T> handling with unwrapOrErrorFangrui Song2019-04-074-327/+170
| | | | llvm-svn: 357855
* [ConstantRange] Shl considers full-set shifting to last bit position.Marcello Maggioni2019-04-072-1/+11
| | | | | | | | | | | | | if we do SHL of two 16-bit ranges like [0, 30000) with [1,2) we get "full-set" instead of what I would have expected [0, 60000) which is still in the 16-bit unsigned range. This patch changes the SHL algorithm to allow getting a usable range even in this case. Differential Revision: https://reviews.llvm.org/D57983 llvm-svn: 357854
* [llvm-objdump] Simplify disassembleObjectFangrui Song2019-04-072-81/+50
| | | | | | | | * Use std::binary_search to replace some std::lower_bound * Use llvm::upper_bound to replace some std::upper_bound * Use format_hex and support::endian::read{16,32} llvm-svn: 357853
* Change some StringRef::data() reinterpret_cast to bytes_begin() or ↵Fangrui Song2019-04-0715-41/+24
| | | | | | arrayRefFromStringRef() llvm-svn: 357852
* [clang-format] Fix Bug 41407Owen Pan2019-04-062-1/+8
| | | | | | Differential Revision: https://reviews.llvm.org/D60359 llvm-svn: 357851
* [gn] Support for per-target runtime directory layoutPetr Hosek2019-04-065-17/+35
| | | | | | | | | | This change also introduces the clang_enable_per_target_runtime_dir to enable the use of per-target runtime directory layout which is the equivalent of LLVM_ENABLE_PER_TARGET_RUNTIME_DIR CMake option. Differential Revision: https://reviews.llvm.org/D60332 llvm-svn: 357850
* [NFC] Fix typo in comment.Nick Lewycky2019-04-061-1/+1
| | | | llvm-svn: 357849
* [X86] When converting (x << C1) AND C2 to (x AND (C2>>C1)) << C1 during ↵Craig Topper2019-04-062-7/+14
| | | | | | isel, try using andl over andq by favoring 32-bit unsigned immediates. llvm-svn: 357848
* [X86] combineBitcastvxi1 - provide dst VT and src SDValue directly. NFCI.Simon Pilgrim2019-04-061-19/+17
| | | | | | Prep work to make it easier to reuse the BITCAST->MOVSMK combine in other cases. llvm-svn: 357847
* [X86] Use a signed mask in foldMaskedShiftToScaledMask to enable a shorter ↵Craig Topper2019-04-063-10/+12
| | | | | | | | | | | immediate encoding. This function reorders AND and SHL to enable the SHL to fold into an LEA. The upper bits of the AND will be shifted out by the SHL so it doesn't matter what mask value we use for these bits. By using sign bits from the original mask in these upper bits we might enable a shorter immediate encoding to be used. llvm-svn: 357846
* [X86] Add test cases to show missed opportunities to use a sign extended 8 ↵Craig Topper2019-04-062-0/+113
| | | | | | | | | | or 32 bit immediate AND when reversing SHL+AND to form an LEA. When we shift the AND mask over we should shift in sign bits instead of zero bits. The scale in the LEA will shift these bits out so it doesn't matter whether we mask the bits off or not. Using sign bits will potentially allow a sign extended immediate to be used. Also add some other test cases for cases that are currently optimal. llvm-svn: 357845
* [X86] Autogenerate complete checks. NFCCraig Topper2019-04-061-16/+30
| | | | llvm-svn: 357844
* Fix spelling mistake. NFCI.Simon Pilgrim2019-04-061-1/+1
| | | | llvm-svn: 357843
* [X86] Add AVX-target expandload and compressstore testsSimon Pilgrim2019-04-062-9/+1512
| | | | llvm-svn: 357842
* [llvm-exegesis][X86] Handle CMOVcc/SETcc OPERAND_COND_CODE OperandTypeRoman Lebedev2019-04-066-27/+69
| | | | | | | | | | | | | | | | | | | | | | Summary: D60041 / D60138 refactoring changed how CMOV/SETcc opcodes are handled. concode is now an immediate, with it's own operand type. This at least allows to not crash on the opcode. However, this still won't generate all the snippets with all the condcode enumerators. D60066 does that. Reviewers: courbet, gchatelet Reviewed By: gchatelet Subscribers: tschuett, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D60057 llvm-svn: 357841
* [X86] Split expandload and compressstore testsSimon Pilgrim2019-04-062-190/+230
| | | | llvm-svn: 357840
* [X86][SSE] Add more exhaustive masked load/store testsSimon Pilgrim2019-04-062-1273/+8844
| | | | | | Reordered/renamed some existing tests to match the cleaned up order llvm-svn: 357839
* [CostModel][X86] Add more exhaustive masked ↵Simon Pilgrim2019-04-062-72/+2050
| | | | | | load/store/gather/scatter/expand/compress cost tests llvm-svn: 357838
* [clang-format] BreakAfterReturnType ignored on functions with numeric ↵Paul Hoad2019-04-062-1/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | template parameters Summary: Addresses PR40696 - https://bugs.llvm.org/show_bug.cgi?id=40696 The BreakAfterReturnType didn't work if it had a single arguments which was a template with an integer template parameter ``` int foo(A<8> a) { return a; } ``` When run with the Mozilla style. would not break after the `int` ``` int TestFn(A<8> a) { return a; } ``` This revision resolves this issue by allowing numeric constants to be considered function parameters if if seen inside `<>` Reviewers: djasper, klimek, JonasToth, krasimir, reuk, alexfh Reviewed By: klimek Subscribers: cfe-commits, llvm-commits Tags: #clang-tools-extra Differential Revision: https://reviews.llvm.org/D59309 llvm-svn: 357837
* [AMDGPU] Sort out and rename multiple CI/VI predicatesStanislav Mekhanoshin2019-04-0614-85/+82
| | | | | | Differential Revision: https://reviews.llvm.org/D60346 llvm-svn: 357835
* [DWARF] Simplify DWARFDebugAranges::findAddressFangrui Song2019-04-062-19/+6
| | | | | | | | The current lower_bound approach has to check two iterators pos and pos-1. Changing it to upper_bound allows us to check one iterator (similar to DWARFUnitVector::getUnitFor*). llvm-svn: 357834
* [Symbolize] Uniquify sorted vector<pair<SymbolDesc, StringRef>>Fangrui Song2019-04-062-10/+16
| | | | llvm-svn: 357833
* [TSan][libdispatch] Remove Darwin-only version of fully-ported testsJulian Lettner2019-04-0610-428/+0
| | | | | | | Remove 10 tests that already have a copy in tsan/libdispatch, without dependencies on Darwin-specifis. llvm-svn: 357832
* tsan: Update test expectations.Peter Collingbourne2019-04-061-2/+2
| | | | llvm-svn: 357831
* gn build: Pacify `gn format`Nico Weber2019-04-051-0/+8
| | | | llvm-svn: 357830
* Unify random timeouts throughout LLDB and make them configurable.Adrian Prantl2019-04-0516-49/+43
| | | | | | | | | | | | | | | | | Since these timeouts guard against catastrophic error in debugserver, I also increased all of them to the maximum value among them. The motivation for this test was the observation that an asanified LLDB would often exhibit seemingly random test failures that could be traced back to debugserver packets getting out of sync. With this path applied I can no longer reproduce the one particular failure mode that I was investigating. rdar://problem/49441261 Differential Revision: https://reviews.llvm.org/D60340 llvm-svn: 357829
* After rL357618, quote ${CMAKE_THREAD_LIBS_INIT} so CMake does notDimitry Andric2019-04-051-1/+1
| | | | | | complain when the variable is empty. Fixes PR 41401. llvm-svn: 357828
* Revert "[Lexer] NFC: Fix an off-by-one bug in getAsCharRange()."Artem Dergachev2019-04-053-25/+2
| | | | | | | | | | This reverts commit r357823. Was breaking clang-tidy! Differential Revision: https://reviews.llvm.org/D59977 llvm-svn: 357827
* [PDB Docs] Add documentation for the hash table format.Zachary Turner2019-04-051-0/+101
| | | | llvm-svn: 357826
* [PDB Docs] The IPI Stream actually has index 4.Zachary Turner2019-04-051-1/+1
| | | | llvm-svn: 357825
* [testsuite] Split Objective-C new syntax testJonas Devlieghere2019-04-055-204/+225
| | | | | | | This splits the second longest test into separate test cases. Similar to what we did for the Objective-C data formatters in r357786. llvm-svn: 357824
* [Lexer] NFC: Fix an off-by-one bug in getAsCharRange().Artem Dergachev2019-04-053-2/+25
| | | | | | | | | | | | | | As the unit test demonstrates, subtracting 1 from the offset was unnecessary. The only user of this function was the plist file emitter (in Static Analyzer and ARCMigrator). It means that a lot of Static Analyzer's plist arrows are in fact off by one character. The patch carefully preserves this completely incorrect behavior and causes no functional change, i.e. no plist format breakage. Differential Revision: https://reviews.llvm.org/D59977 llvm-svn: 357823
* [LLVM-C] Begin to Expose A More General Binary InterfaceRobert Widmann2019-04-054-0/+76
| | | | | | | | | | | | | | | | | | | | | Summary: Provides a new type, `LLVMBinaryRef`, and a binding to `llvm::object::createBinary` for more general interoperation with binary files than `LLVMObjectFileRef`. It also provides the proper non-consuming API for input buffers and populates an out parameter for error handling if necessary - two things the previous API did not do. In a follow-up, I'll define section and symbol iterators and begin to build upon the existing test infrastructure. This patch is a first step towards deprecating that API and replacing it with something more robust. Reviewers: deadalnix, whitequark Reviewed By: whitequark Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D60322 llvm-svn: 357822
* [gn] Support for building compiler-rt builtinsPetr Hosek2019-04-056-83/+602
| | | | | | | | | | | | | | | | This is support for building compiler-rt builtins, The library build should be complete for a subset of supported platforms, but not all CMake options have been replicated in GN. We always use the just built compiler to build all the runtimes, which is equivalent to the CMake runtimes build. This simplifies the build configuration because we don't need to support arbitrary host compiler and can always assume the latest Clang. With GN's toolchain support, this is significantly more efficient than the CMake runtimes build. Differential Revision: https://reviews.llvm.org/D60331 llvm-svn: 357821
* [globalisel] Allow combiners to query legalityDaniel Sanders2019-04-051-0/+3
| | | | llvm-svn: 357820
* [PDB Docs] Delete * LINKER * Stream information.Zachary Turner2019-04-051-4/+0
| | | | | | | This is actually just a module debug info stream, so it should technically be covered by a discussion of the module list. llvm-svn: 357819
* [libc++][CMake] Make sure the benchmarks link against libc++abiLouis Dionne2019-04-051-1/+2
| | | | | | | | | | | | | | The refactoring in r357811 made it so that we didn't add the ABI library to the list of LIBCXX_LIBRARIES. As a result, benchmarks didn't link to the ABI library and were missing symbols. This broke the build bots. As a drive-by fix, we also provide the SHARED ABI library to the linker script instead of the STATIC ABI library. This couldn't be discovered on Apple platforms because libc++.dylib re-exports libc++abi.dylib symbols there. llvm-svn: 357818
* [CMake] Don't explicitly use LLVM_LIBRARY_DIR in standalone buildsAlex Langford2019-04-051-3/+0
| | | | | | | | | | | | | | | | | | | | | | | Summary: This line is unnecessary because add_llvm_executable will handle linking the correct LLVM libraries for you. LLDB standalone builds are totally fine without this. In the best case, having this line here is harmless. In the worst case it can cause link issues. If you build lldb-server for android using the standalone build, this line will cause LLVM_LIBRARY_DIR to be the first place you look for libraries. This is an issue because if you built libc++, it will try to link against that one instead of the one from the android NDK. Meanwhile, the LLVM libraries you're linking against were linked against the libc++ from the NDK. Ideally, we would take advantage of the AFTER option for link_directories(), but that was not available in LLDB's minimum supported version of CMake (CMake 3.4.3). Differential Revision: https://reviews.llvm.org/D60180 llvm-svn: 357817
* [InstCombine] add more tests for fmul+fdiv+sqrt; NFCSanjay Patel2019-04-051-2/+43
| | | | llvm-svn: 357816
* [globalisel] Support 3-type legalForCartesianProduct()Daniel Sanders2019-04-051-0/+8
| | | | llvm-svn: 357815
* Fix PR41395 - __cxa_vec_new may overflow in allocation size calculation.Eric Fiselier2019-04-052-13/+165
| | | | llvm-svn: 357814
* [Test] Remove no_debug_info_test decorator from Obj-C data formatters.Jonas Devlieghere2019-04-0511-11/+0
| | | | | | As discussed in https://reviews.llvm.org/D60300. llvm-svn: 357813
* [LLVM-C] Add bindings to insert basic blocksRobert Widmann2019-04-052-0/+32
| | | | | | | | | | | | | | | | | | | | Summary: Now that we can create standalone basic blocks, it's useful to be able to append them. Add bindings to - Insert a basic block after the current insertion block - Append a basic block to the end of a function's list of basic blocks Reviewers: whitequark, deadalnix, harlanhaskins Reviewed By: whitequark, harlanhaskins Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D59658 llvm-svn: 357812
* [libc++] Localize CMake code only related to the shared libraryLouis Dionne2019-04-051-68/+64
| | | | | | | | | | | | | | | | | | Summary: There's a lot of CMake logic that's only relevant to the shared library, yet it was using a code path and setting variables that impact both the shared and the static libraries. This patch moves this logic so that it clearly only impacts the shared library. Reviewers: phosek, smeenai, EricWF Subscribers: mgorny, christof, jkorous, dexonsmith, libcxx-commits Tags: #libc Differential Revision: https://reviews.llvm.org/D60276 llvm-svn: 357811
* [analyzer] NoStoreFuncVisitor: Suppress reports with no-store in system headers.Artem Dergachev2019-04-053-22/+88
| | | | | | | | | | | | | | | | | The idea behind this heuristic is that normally the visitor is there to inform the user that a certain function may fail to initialize a certain out-parameter. For system header functions this is usually dictated by the contract, and it's unlikely that the header function has accidentally forgot to put the value into the out-parameter; it's more likely that the user has intentionally skipped the error check. Warnings on skipped error checks are more like security warnings; they aren't necessarily useful for all users, and they should instead be introduced on a per-API basis. Differential Revision: https://reviews.llvm.org/D60107 llvm-svn: 357810
OpenPOWER on IntegriCloud