summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* [AMDGPU] Removed unused methodTim Renouf2018-09-131-22/+0
| | | | | | | | | | | | | Summary: I accidentally left this behind in D50306, and it causes a build warning when I build with gcc7. Subscribers: arsenm, kzhuravl, jvesely, wdng, nhaehnle, yaxunl, dstuttard, t-tye, llvm-commits Differential Revision: https://reviews.llvm.org/D52022 Change-Id: I30f7a47047e9d9d841f652da66d2fea19e74842c llvm-svn: 342189
* Remember to sort the Xcode project file. NFC.Jim Ingham2018-09-131-2612/+2612
| | | | llvm-svn: 342188
* [SanitizerCoverage] Create comdat for global arrays.Matt Morehouse2018-09-136-21/+32
| | | | | | | | | | | | | | | | | Summary: Place global arrays in comdat sections with their associated functions. This makes sure they are stripped along with the functions they reference, even on the BFD linker. Reviewers: eugenis Reviewed By: eugenis Subscribers: eraman, hiraditya, llvm-commits Differential Revision: https://reviews.llvm.org/D51902 llvm-svn: 342186
* Add a "scripted" breakpoint type to lldb.Jim Ingham2018-09-1327-2633/+3257
| | | | | | | | | | This change allows you to write a new breakpoint type where the logic for setting breakpoints is determined by a Python callback written using the SB API's. Differential Revision: https://reviews.llvm.org/D51830 llvm-svn: 342185
* [NFC][InstCombine] PR38708 - inefficient pattern for high-bits checking 3.Roman Lebedev2018-09-132-0/+520
| | | | | | | | | | | | | The last, non-canonical variant: https://godbolt.org/z/aCMsPk https://rise4fun.com/Alive/I6f It can only happen due to the extra use on the inner shift. But here it is ok. https://bugs.llvm.org/show_bug.cgi?id=38708 llvm-svn: 342184
* [DAGCombine] Fix crash when store merging created an extract_subvector with ↵Amara Emerson2018-09-132-1/+27
| | | | | | | | invalid index. Differential Revision: https://reviews.llvm.org/D51831 llvm-svn: 342183
* LLVMExegesisX86Tests: link to LLVMCore, too.Roman Lebedev2018-09-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes build for me. Refs. D52054 [215/217] Linking CXX executable unittests/tools/llvm-exegesis/X86/LLVMExegesisX86Tests FAILED: unittests/tools/llvm-exegesis/X86/LLVMExegesisX86Tests : && /usr/bin/g++ -pipe -O2 -g0 -UNDEBUG -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wno-class-memaccess -Wno-noexcept-type -Wdelete-non-virtual-dtor -Wno-comment -fdiagnostics-color -ffunction-sections -fdata-sections -pipe -O2 -g0 -UNDEBUG -fuse-ld=lld -Wl,--color-diagnostics -Wl,-allow-shlib-undefined -Wl,-O3 -Wl,--gc-sections unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/AssemblerTest.cpp.o unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/AnalysisTest.cpp.o unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/SnippetGeneratorTest.cpp.o unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/RegisterAliasingTest.cpp.o unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/TargetTest.cpp.o -o unittests/tools/llvm-exegesis/X86/LLVMExegesisX86Tests -Wl,-rpath,/build/llvm-build-GCC-release/lib lib/libLLVMMC.so.8svn lib/libLLVMMCParser.so.8svn lib/libLLVMObject.so.8svn lib/libLLVMSymbolize.so.8svn lib/libLLVMX86CodeGen.so.8svn lib/libLLVMX86AsmParser.so.8svn lib/libLLVMX86AsmPrinter.so.8svn lib/libLLVMX86Desc.so.8svn lib/libLLVMX86Disassembler.so.8svn lib/libLLVMX86Info.so.8svn lib/libLLVMX86Utils.so.8svn lib/libLLVMSupport.so.8svn -lpthread lib/libgtest_main.so.8svn lib/libgtest.so.8svn -lpthread lib/libLLVMExegesis.so.8svn lib/libLLVMExegesisX86.so.8svn && : ld.lld: error: undefined symbol: llvm::LLVMContext::~LLVMContext() >>> referenced by AssemblerTest.cpp >>> unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/AssemblerTest.cpp.o:(exegesis::(anonymous namespace)::X86MachineFunctionGeneratorTest_DISABLED_JitFunction_Test::TestBody()) ld.lld: error: undefined symbol: llvm::LLVMContext::~LLVMContext() >>> referenced by AssemblerTest.cpp >>> unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/AssemblerTest.cpp.o:(exegesis::(anonymous namespace)::X86MachineFunctionGeneratorTest_DISABLED_JitFunctionXOR32rr_Default_Test::TestBody()) ld.lld: error: undefined symbol: llvm::LLVMContext::~LLVMContext() >>> referenced by AssemblerTest.cpp >>> unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/AssemblerTest.cpp.o:(void exegesis::MachineFunctionGeneratorBaseTest::Check<int, int, int, int, int, int, int, int>(exegesis::ExegesisTarget const&, llvm::ArrayRef<unsigned int>, llvm::MCInst, int, int, int, int, int, int, int, int)) ld.lld: error: undefined symbol: llvm::LLVMContext::~LLVMContext() >>> referenced by AssemblerTest.cpp >>> unittests/tools/llvm-exegesis/X86/CMakeFiles/LLVMExegesisX86Tests.dir/AssemblerTest.cpp.o:(exegesis::(anonymous namespace)::X86MachineFunctionGeneratorTest_DISABLED_JitFunctionMOV32ri_Test::TestBody()) collect2: error: ld returned 1 exit status ninja: build stopped: subcommand failed. llvm-svn: 342182
* Add support for descriptions with command completions.Raphael Isemann2018-09-1318-106/+424
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This patch adds a framework for adding descriptions to the command completions we provide. It also adds descriptions for completed top-level commands so that we can test this code. Completions are in general supposed to be displayed alongside the completion itself. The descriptions can be used to provide additional information about the completion to the user. Examples for descriptions are function signatures when completing function calls in the expression command or the binary name when providing completion for a symbol. There is still some boilerplate code from the old completion API left in LLDB (mostly because the respective APIs are reused for non-completion related purposes, so the CompletionRequest doesn't make sense to be used), so that's why I still had to change some function signatures. Also, as the old API only passes around a list of matches, and the descriptions are for these functions just another list, I had to add some code that essentially just ensures that both lists are always the same side (e.g. all the manual calls to `descriptions->AddString(X)` below a `matches->AddString(Y)` call). The initial command descriptions that come with this patch are just reusing the existing short help that is already added in LLDB. An example completion with descriptions looks like this: ``` (lldb) pl Available completions: platform -- Commands to manage and create platforms. plugin -- Commands for managing LLDB plugins. ``` Reviewers: #lldb, jingham Reviewed By: #lldb, jingham Subscribers: jingham, JDevlieghere, lldb-commits Differential Revision: https://reviews.llvm.org/D51175 llvm-svn: 342181
* [llvm-exegesis] Add missing MC dependency to CMakeLists.txtSam Clegg2018-09-131-0/+1
| | | | | | | | | | | See rL342148 This probably only shows up in BUILD_SHARED_LIBS=ON builds which might explain how it crept in. Differential Revision: https://reviews.llvm.org/D52054 llvm-svn: 342180
* [bindings/go] Add DebugLoc parameter to InsertXXXAtEnd()Peter Collingbourne2018-09-131-4/+8
| | | | | | | | | | | | These functions previously passed nil for the location, which always resulted in a crash. This is a signature breaking change, but I cannot see how they could have been used before. Patch by Ben Clayton! Differential Revision: https://reviews.llvm.org/D51970 llvm-svn: 342179
* Add dependency on new llvm-cxxmap tool to check-llvm.Richard Smith2018-09-131-0/+1
| | | | llvm-svn: 342178
* Diagnose likely typos in #include directives.Richard Smith2018-09-134-2/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: When someone writes #include "<some_file>" or #include " some_file " the compiler returns "file not fuond..." with fonts and quotes that may make it hard to see there are excess quotes or surprising bytes in the filename. Assuming that files are usually logically named and start and end with an alphanumeric character, we can check for the file's existence by stripping the non-alphanumeric leading or trailing characters. If the file is found, emit a non-fatal error with a FixItHint. Patch by Christy Lee! Reviewers: aaron.ballman, erikjv, rsmith Reviewed By: rsmith Subscribers: lebedev.ri, xbolva00, sammccall, modocache, erikjv, aaron.ballman, cfe-commits Differential Revision: https://reviews.llvm.org/D51333 llvm-svn: 342177
* [MachineInstr] In addRegisterKilled and addRegisterDead, don't remove ↵Craig Topper2018-09-132-2/+28
| | | | | | | | | | | | | | operands from inline assembly instructions if they have an associated flag operand. INLINEASM instructions use extra operands to carry flags. If a register operand is removed without removing the flag operand, then the flags will no longer make sense. This patch fixes this by preventing the removal when a flag operand is present. The included test case was generated by MS inline assembly. Longer term maybe we should fix the inline assembly parsing to not generate redundant operands. Differential Revision: https://reviews.llvm.org/D51829 llvm-svn: 342176
* [X86] Fix register resizings for inline assembly register operands.Nirav Dave2018-09-137-220/+421
| | | | | | | | | | | | | | When replacing a named register input to the appropriately sized sub/super-register. In the case of a 64-bit value being assigned to a register in 32-bit mode, match GCC's assignment. Reviewers: eli.friedman, craig.topper Subscribers: nickdesaulniers, llvm-commits, hiraditya Differential Revision: https://reviews.llvm.org/D51502 llvm-svn: 342175
* [X86] Cleanup pair returns. NFCI.Nirav Dave2018-09-131-32/+14
| | | | llvm-svn: 342174
* [InstCombine] Inefficient pattern for high-bits checking 2 (PR38708)Roman Lebedev2018-09-133-59/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: It is sometimes important to check that some newly-computed value is non-negative and only n bits wide (where n is a variable.) There are many ways to check that: https://godbolt.org/z/o4RB8D The last variant seems best? (I'm sure there are some other variations i haven't thought of..) More complicated, canonical pattern: https://rise4fun.com/Alive/uhA We do need to have two `switch()`'es like this, to not mismatch the swappable predicates. https://bugs.llvm.org/show_bug.cgi?id=38708 Reviewers: spatel, craig.topper, RKSimon Reviewed By: spatel Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D52001 llvm-svn: 342173
* [PartiallyInlineLibCalls] Add DebugCounter supportGeorge Burgess IV2018-09-132-0/+50
| | | | | | | | | | | This adds DebugCounter support to the PartiallyInlineLibCalls pass, which should make debugging/automated bisection easier in the future. Patch by Zhizhou Yang! Differential Revision: https://reviews.llvm.org/D50093 llvm-svn: 342172
* [NFC][InstCombine] Test what happens if 'unefficient high bit check' pattern ↵Roman Lebedev2018-09-134-0/+60
| | | | | | | | | | is on both sides. Came up in https://reviews.llvm.org/D52001#1233827 While we don't do a good job here, we at least want to make sure that we don't have any inf-loops. llvm-svn: 342171
* [DCE] Add DebugCounter supportGeorge Burgess IV2018-09-132-0/+28
| | | | | | | | Patch by Zhizhou Yang! Differential Revision: https://reviews.llvm.org/D50092 llvm-svn: 342170
* Revert "[cmake] Fix a unittest when `LLVM_LINK_LLVM_DYLIB` is requested."Volodymyr Sapsai2018-09-131-6/+4
| | | | | | | | | | This reverts commit r342150 as it caused test failure LLVM-Unit :: Passes/./PluginsTests/PluginsTests.LoadPlugin on multiple bots. llvm-svn: 342169
* Add flag to llvm-profdata to allow symbols in profile data to be remapped, andRichard Smith2018-09-1324-9/+507
| | | | | | | | | | | | | | | | | add a tool to generate symbol remapping files. Summary: The new tool llvm-cxxmap builds a symbol mapping table from a file containing a description of partial equivalences to apply to mangled names and files containing old and new symbol tables. Reviewers: davidxl Subscribers: mgorny, llvm-commits Differential Revision: https://reviews.llvm.org/D51470 llvm-svn: 342168
* NativeProcessProtocol: Sink ReadMemoryWithoutTrap into base classPavel Labath2018-09-136-26/+11
| | | | | | | | The two existing implementations have the function implemented identically, and there's no reason to believe that this would be different for other implementations. llvm-svn: 342167
* Fix a couple of mangling canonicalizer corner case bugs.Richard Smith2018-09-132-19/+33
| | | | | | | | | | | | | | | | Summary: The hash computed for an ArrayType was different when first constructed versus when later profiled due to the constructor default argument, and we were not tracking constructor / destructor variant as part of the mangled name AST, leading to incorrect equivalences. Reviewers: erik.pilkington Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D51463 llvm-svn: 342166
* Support -fno-omit-frame-pointer with -pg.Stephen Hines2018-09-132-1/+7
| | | | | | | | | | | | | | | | | | Summary: Previously, any instance of -fomit-frame-pointer would make it such that -pg was an invalid flag combination. If -fno-omit-frame-pointer is passed later on the command line (such that it actually takes effect), -pg should be allowed. Reviewers: nickdesaulniers Reviewed By: nickdesaulniers Subscribers: manojgupta, nickdesaulniers, cfe-commits, kongyi, chh, pirama Differential Revision: https://reviews.llvm.org/D51713 llvm-svn: 342165
* [hwasan] use a single Printf per line when printing a report (more friendly ↵Kostya Serebryany2018-09-131-5/+8
| | | | | | to android logging) llvm-svn: 342164
* [InstCombine] Fold (xor (min/max X, Y), -1) -> (max/min ~X, ~Y) when X and Y ↵Craig Topper2018-09-134-36/+65
| | | | | | | | | | | | | | are freely invertible. This allows the xor to be removed completely. This might help with recomitting r341674, but seems good regardless. Coincidentally fixes PR38915. Differential Revision: https://reviews.llvm.org/D51964 llvm-svn: 342163
* [InstCombine] Add test cases for D51964. NFCCraig Topper2018-09-131-0/+128
| | | | llvm-svn: 342162
* Common infrastructure for reading a profile remapping file and buildingRichard Smith2018-09-135-0/+312
| | | | | | | | a mangling remapper from it. Differential Revision: https://reviews.llvm.org/D51246 llvm-svn: 342161
* [RISCV][MC] Reject bare symbols for the simm6 and simm6nonzero operand typesAna Pazos2018-09-133-14/+16
| | | | | | | | | | | | | | | | | | | | Summary: Fixed assertions due to invalid fixup when encoding compressed instructions (c.addi, c.addiw, c.li, c.andi) with bare symbols with/without modifiers. This matches GAS behavior as well. This bug was uncovered by a LLVM MC Disassembler Protocol Buffer Fuzzer for the RISC-V assembly language. Reviewers: asb Reviewed By: asb Subscribers: rbar, johnrusso, simoncook, sabuasal, niosHD, kito-cheng, shiva0217, zzheng, edward-jones, mgrang, rogfer01, MartinMosbeck, brucehoult, the_o, rkruppe, PkmX, jocewei, asb Differential Revision: https://reviews.llvm.org/D52005 llvm-svn: 342160
* [RISCV] Fix decoding of invalid instruction with C extension enabled.Ana Pazos2018-09-133-2/+33
| | | | | | | | | | | | | | | | | | | | | | Summary: The illegal instruction 0x00 0x00 is being wrongly decoded as c.addi4spn with 0 immediate. The invalid instruction 0x01 0x61 is being wrongly decoded as c.addi16sp with 0 immediate. This bug was uncovered by a LLVM MC Disassembler Protocol Buffer Fuzzer for the RISC-V assembly language. Reviewers: asb Reviewed By: asb Subscribers: rbar, johnrusso, simoncook, sabuasal, niosHD, kito-cheng, shiva0217, zzheng, edward-jones, mgrang, rogfer01, MartinMosbeck, brucehoult, the_o, rkruppe, PkmX, jocewei, asb Differential Revision: https://reviews.llvm.org/D51815 llvm-svn: 342159
* lld-link: For nonexisting inputs, omit follow-on diagnosticsNico Weber2018-09-132-0/+8
| | | | | | | | | | | | | | | | For lld-link missing.obj, lld-link currently prints: lld-link: error: could not open foo.obj: No such file or directory lld-link: warning: /machine is not specified. x64 is assumed lld-link: error: subsystem must be defined The 2nd and 3rd diagnostics are consequences of the input not existing and are not interesting. If input files are missing, the best thing we can do is point that out and then return. Differential Revision: https://reviews.llvm.org/D51981 llvm-svn: 342158
* [WebAssembly] Fix signature of `main` in FixFunctionBitcastsSam Clegg2018-09-133-2/+20
| | | | | | | | | Also, add a check to ensure that when main has the expected signature we do not create a wrapper. Differential Revision: https://reviews.llvm.org/D51562 llvm-svn: 342157
* [AArch64] Add integer abs testcases for D51873.Simon Pilgrim2018-09-131-0/+52
| | | | llvm-svn: 342156
* [clangd] Introduce PostingList interfaceKirill Bobyrev2018-09-138-161/+216
| | | | | | | | | | | | | | | | This patch abstracts `PostingList` interface and reuses existing implementation. It will be used later to test different `PostingList` representations. No functionality change is introduced, this patch is mostly refactoring so that the following patches could focus on functionality while not being too hard to review. Reviewed By: sammccall, ioeric Differential Revision: https://reviews.llvm.org/D51982 llvm-svn: 342155
* [cmake] Fix missing DEPENDS.Richard Diamond2018-09-134-0/+12
| | | | | | Not sure how I didn't catch this. llvm-svn: 342154
* [LLDB] - Improved DWARF5 support.George Rimar2018-09-1318-81/+393
| | | | | | | | | This patch improves the support of DWARF5. Particularly the reporting of source code locations. Differential revision: https://reviews.llvm.org/D51935 llvm-svn: 342153
* [NFC]Refactor MultiVersion Resolver Emission to combine typesErich Keane2018-09-134-93/+108
| | | | | | | | | Previously, both types (plus the future target-clones) of multiversioning had a separate ResolverOption structure and emission function. This patch combines the two, at the expense of a slightly more expensive sorting function. llvm-svn: 342152
* [OPENMP] Fix PR38903: Crash on instantiation of the non-dependentAlexey Bataev2018-09-139-67/+144
| | | | | | | | | | | declare reduction. If the declare reduction construct with the non-dependent type is defined in the template construct, the compiler might crash on the template instantition. Reworked the whole instantiation scheme for the declare reduction constructs to fix this problem correctly. llvm-svn: 342151
* [cmake] Fix a unittest when `LLVM_LINK_LLVM_DYLIB` is requested.Richard Diamond2018-09-131-4/+6
| | | | llvm-svn: 342150
* [InstCombine] remove checks for IsFreeToInvert()Sanjay Patel2018-09-131-3/+1
| | | | | | | | | I accidentally committed this diff with rL342147 because I had applied D51964. We probably do need those checks, but D51964 has tests and more discussion/motivation, so they should be re-added with that patch. llvm-svn: 342149
* Renovate CMake files in the `llvm-(cfi-verify|exegesis|mca)` tools.Richard Diamond2018-09-135-43/+27
| | | | llvm-svn: 342148
* [InstCombine] reorder folds to reduce chance of infinite loopsSanjay Patel2018-09-131-22/+20
| | | | | | | | | | | | | | | | I don't have a test case for this, but it's motivated by the discussion in D51964, and I've added TODO comments for the better fix - move simplifications into instsimplify because that's more efficient and reduces risk of infinite loops in instcombine caused by transforms trying to do the opposite folds. In this case, we know that the transform that tries to move 'not' through min/max can be fooled by the multiple uses of a value in another min/max, so try to squash the foldSPFofSPF() patterns first. llvm-svn: 342147
* [ELF] Guard --fix-cortex-a53-843419 against --just-symsPeter Smith2018-09-132-1/+23
| | | | | | | | | | | | | | If --just-syms is used the mapping symbols from the ELF file will be absolute symbols with no section. The code to process mapping symbols in --fix-cortex-a53-843419 assumes that these symbols have a defining section so a crash will result when --just-syms is used. The simple fix is to not process the symbol when it doesn't have a section. Fixes PR37971 Differential Revision: https://reviews.llvm.org/D52038 llvm-svn: 342146
* Add missing REQUIRES x86 to test/COFF/icf-safe.sAzharuddin Mohammed2018-09-131-0/+1
| | | | | | | | | | | | Reviewers: ruiu, pcc Reviewed By: ruiu Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D51764 llvm-svn: 342145
* Fix typo in error message. NFC.Azharuddin Mohammed2018-09-131-1/+1
| | | | | | | | | | | | | | Summary: It should be "wasm-ld", not "wasm-lld". Reviewers: ruiu Reviewed By: ruiu Subscribers: aheejin, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D51767 llvm-svn: 342144
* [clangd] Fix Dexp buildKirill Bobyrev2018-09-131-1/+1
| | | | | | %s/MaxCandidateCount/Limit/g after rL342138. llvm-svn: 342143
* [DWARFExpression] Read literars as unsigned values.Jonas Devlieghere2018-09-134-1/+82
| | | | | | | | | | | | | | | | | | | | | | | | After landing r341457, we started seeing a failure on the swift-lldb bots. The change was correct and pretty straightforward, a DW_OP_constu was replaced with DW_OP_lit23, the value remaining identical. 0x000000f4: DW_TAG_variable DW_AT_location (0x00000000 [0x0000000100000a51, 0x0000000100000d47): DW_OP_lit23, DW_OP_stack_value) DW_AT_name ("number") However, this broke LLDB. (Int) number = <extracting data from value failed> The value was read correctly, but apparently the value's type was different. When reading a constu it was reading a uint64 (m_type = e_ulonglong) while for the literal, it got a signed int (m_type = e_sint). This change makes sure we read the value as an unsigned. Differential revision: https://reviews.llvm.org/D51730 llvm-svn: 342142
* [ARM] Allow truncs as sources in ARM CGPSam Parker2018-09-132-20/+23
| | | | | | | | | | We previously only allowed truncs as sinks, but now allow them as sources too. We do this by checking that the result type is the narrow type that we're trying to optimise for. Differential Revision: https://reviews.llvm.org/D51978 llvm-svn: 342141
* [ARM] Fix FixConst for ARMCodeGenPrepareSam Parker2018-09-132-21/+13
| | | | | | | | | | Part of FixConsts wrongly assumes either a 8- or 16-bit constant which can result in the wrong constants being generated during promotion. Differential Revision: https://reviews.llvm.org/D52032 llvm-svn: 342140
* Print correctly dependency paths on WindowsDavid Bolvansky2018-09-134-18/+22
| | | | | | | | | | | | | | | | | | | Summary: Before: main.o: main.c ../include/lib\test.h After: main.o: main.c ../include/lib/test.h Fixes PR38877 Reviewers: zturner Subscribers: xbolva00, cfe-commits Differential Revision: https://reviews.llvm.org/D51847 llvm-svn: 342139
OpenPOWER on IntegriCloud