summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* GlobalISel: Implement moreElementsVector for bit opsMatt Arsenault2019-02-199-92/+732
| | | | llvm-svn: 354345
* [yaml2obj][obj2yaml] Remove section type range markers from allowed mappings ↵James Henderson2019-02-193-3/+56
| | | | | | | | | | | | | | | | | | | | | and support hex values yaml2obj/obj2yaml previously supported SHT_LOOS, SHT_HIOS, and SHT_LOPROC for section types. These are simply values that delineate a range and don't really make sense as valid values. For example if a section has type value 0x70000000, obj2yaml shouldn't print this value as SHT_LOPROC. Additionally, this was missing the three other range markers (SHT_HIPROC, SHT_LOUSER and SHT_HIUSER). This change removes these three range markers. It also adds support for specifying the type as an integer, to allow section types that LLVM doesn't know about. Reviewed by: grimar Differential Revision: https://reviews.llvm.org/D58383 llvm-svn: 354344
* Cast from SDValue directly instead of superfluous getNode(). NFCI.Simon Pilgrim2019-02-191-2/+2
| | | | llvm-svn: 354343
* GlobalISel: Verify g_insertMatt Arsenault2019-02-192-0/+68
| | | | llvm-svn: 354342
* [mips] Fix indentations in the test. NFCSimon Atanasyan2019-02-191-13/+13
| | | | llvm-svn: 354341
* [X86][AVX] EltsFromConsecutiveLoads - Add BROADCAST lowering supportSimon Pilgrim2019-02-1911-145/+129
| | | | | | | | | | This patch adds scalar/subvector BROADCAST handling to EltsFromConsecutiveLoads. It mainly shows codegen changes to 32-bit code which failed to handle i64 loads, although 64-bit code is also using this new path to more efficiently combine to a broadcast load. Differential Revision: https://reviews.llvm.org/D58053 llvm-svn: 354340
* [ELF] - Update test case after yaml2obj format change.George Rimar2019-02-191-1/+1
| | | | | | yaml2obj was changed in r354338("[yaml2obj][obj2yaml] - Support SHT_GNU_versym (.gnu.version) section.") llvm-svn: 354339
* [yaml2obj][obj2yaml] - Support SHT_GNU_versym (.gnu.version) section.George Rimar2019-02-196-0/+206
| | | | | | | | | This patch adds support for parsing dumping the .gnu.version section. Description of the section is: https://refspecs.linuxfoundation.org/LSB_1.3.0/gLSB/gLSB/symversion.html#SYMVERTBL Differential revision: https://reviews.llvm.org/D58280 llvm-svn: 354338
* [OpenCL] Change type of block pointer for OpenCLAlexey Bader2019-02-193-20/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: For some reason OpenCL blocks in LLVM IR are represented as function pointers. These pointers do not point to any real function and never get called. Actually they point to some structure, which in turn contains pointer to the real block invoke function. This patch changes represntation of OpenCL blocks in LLVM IR from function pointers to pointers to `%struct.__block_literal_generic`. Such representation allows to avoid unnecessary bitcasts and simplifies further processing (e.g. translation to SPIR-V ) of the module for targets which do not support function pointers. Patch by: Alexey Sotkin. Reviewers: Anastasia, yaxunl, svenvh Reviewed By: Anastasia Subscribers: alexbatashev, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58277 llvm-svn: 354337
* Convert the eh-frame-hdr-abs-fde.s test to use x86 as a target architectureSimon Atanasyan2019-02-191-9/+9
| | | | | | | The test checks common functionality. Let's use `x86` (generic LLD target) as a target architecture. llvm-svn: 354336
* Recommit r354328, r354329 "[obj2yaml][yaml2obj] - Add support of ↵George Rimar2019-02-196-9/+371
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | parsing/dumping of the .gnu.version_r section." Fix: Replace assert(!IO.getContext() && "The IO context is initialized already"); with assert(IO.getContext() && "The IO context is not initialized"); (this was introduced in r354329, where I tried to quickfix the darwin BB and seems copypasted the assert from the wrong place). Original commit message: The section is described here: https://refspecs.linuxfoundation.org/LSB_1.3.0/gLSB/gLSB/symverrqmts.html Patch just teaches obj2yaml/yaml2obj to dump and parse such sections. We did the finalization of string tables very late, and I had to move the logic to make it a bit earlier. That was needed in this patch since .gnu.version_r adds strings to .dynstr. This might also be useful for implementing other special sections. Everything else changed in this patch seems to be straightforward. Differential revision: https://reviews.llvm.org/D58119 llvm-svn: 354335
* [RISCV][NFC] Move some std::string to StringRefAlex Bradbury2019-02-193-5/+5
| | | | llvm-svn: 354333
* Revert r354328, r354329 "[obj2yaml][yaml2obj] - Add support of ↵George Rimar2019-02-196-371/+9
| | | | | | | | | parsing/dumping of the .gnu.version_r section." Something went wrong. Bots are unhappy: http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-ubuntu-fast/builds/44113/steps/test/logs/stdio llvm-svn: 354332
* [clangd] Handle unresolved scope specifier when fixing includes.Eric Liu2019-02-192-41/+226
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: In the following examples, "clangd" is unresolved, and the fixer will try to fix include for `clang::clangd`; however, clang::clangd::X is usually intended. So when handling a qualifier that is unresolved, we change the unresolved name and scopes so that the fixer will fix "clang::clangd::X" in the following example. ``` namespace clang { clangd::X ~~~~~~ } // or clang::clangd::X ~~~~~~ ``` Reviewers: sammccall Reviewed By: sammccall Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D58185 llvm-svn: 354330
* Fix BB after r354328.George Rimar2019-02-191-4/+2
| | | | | | | | | | | | | | | | | | | | | Bot: http://lab.llvm.org:8011/builders/lld-x86_64-darwin13/builds/30188/steps/build_Lld/logs/stdio Error: /Users/buildslave/as-bldslv9_new/lld-x86_64-darwin13/llvm.src/lib/ObjectYAML/ELFYAML.cpp:1013:15: error: unused variable 'Object' [-Werror,-Wunused-variable] const auto *Object = static_cast<ELFYAML::Object *>(IO.getContext()); ^ /Users/buildslave/as-bldslv9_new/lld-x86_64-darwin13/llvm.src/lib/ObjectYAML/ELFYAML.cpp:1023:15: error: unused variable 'Object' [-Werror,-Wunused-variable] const auto *Object = static_cast<ELFYAML::Object *>(IO.getContext()); Fix: change const auto *Object = static_cast<ELFYAML::Object *>(IO.getContext()); assert(Object && "The IO context is not initialized"); to assert(!IO.getContext() && "The IO context is initialized already"); llvm-svn: 354329
* [obj2yaml][yaml2obj] - Add support of parsing/dumping of the .gnu.version_r ↵George Rimar2019-02-196-9/+373
| | | | | | | | | | | | | | | | | | | | section. The section is described here: https://refspecs.linuxfoundation.org/LSB_1.3.0/gLSB/gLSB/symverrqmts.html Patch just teaches obj2yaml/yaml2obj to dump and parse such sections. We did the finalization of string tables very late, and I had to move the logic to make it a bit earlier. That was needed in this patch since .gnu.version_r adds strings to .dynstr. This might also be useful for implementing other special sections. Everything else changed in this patch seems to be straightforward. Differential revision: https://reviews.llvm.org/D58119 llvm-svn: 354328
* Revert "minidump: Add ability to attach (breakpad) symbol files to ↵Pavel Labath2019-02-195-114/+52
| | | | | | | | | | | | | | | | | | placeholder modules" This reverts r354263, because it uncovered a problem in handling of the minidumps with conflicting UUIDs. If a minidump contains two files with the same UUID, we will not create to placeholder modules for them, but instead reuse the first one for the second instance. This creates a problem because these modules have their load address hardcoded in them (and I've added an assert to verify that). Technically this is not a problem with this patch, as the same issue existed in the previous implementation, but it did not have the assert which would diagnose that. Nonetheless, I am reverting this until I figure out what's the best course of action in this situation. llvm-svn: 354324
* [RISCV] Re-organise calling convention testsAlex Bradbury2019-02-193-213/+633
| | | | | | | | Re-organise calling convention tests to prepare for ilp32f and ilp32d hard float ABI tests. It's also clear that we need to introduce similar tests for lp64. llvm-svn: 354323
* Fix BB after r354319 "[yaml2obj] - Do not skip zeroes blocks if there are ↵George Rimar2019-02-191-0/+0
| | | | | | | | | | | | | | | | relocations against them." Fix: move the test to x86 folder. Seems it is needed, because llvm-objdump invocation used in test has -D (disasm) flag. BB: http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/23016 /local/buildbot/slaves/hexagon-build-02/clang-hexagon-elf/stage1/bin/llvm-objdump: error: '/local/buildbot/slaves/hexagon-build-02/clang-hexagon-elf/stage1/test/tools/llvm-objdump/Output/disasm-zeroes-relocations.test.tmp': can't find target: : error: unable to get target for 'x86_64--', see --version and --triple. . llvm-svn: 354322
* [yaml2obj] - Do not skip zeroes blocks if there are relocations against them.George Rimar2019-02-192-10/+68
| | | | | | | | | | | This is for -D -reloc combination. With this patch, we do not skip the zero bytes that have a relocation against them when -reloc is used. If -reloc is not used, then the behavior will be the same. Differential revision: https://reviews.llvm.org/D58174 llvm-svn: 354319
* [yaml2obj] - Do not ignore explicit addresses for .dynsym and .dynstrGeorge Rimar2019-02-192-0/+58
| | | | | | | | | | | This fixes https://bugs.llvm.org/show_bug.cgi?id=40339 Previously if the addresses were set in YAML they were ignored for .dynsym and .dynstr sections. The patch fixes that. Differential revision: https://reviews.llvm.org/D58168 llvm-svn: 354318
* Fix obsolete comment. NFCDiana Picus2019-02-191-1/+1
| | | | | | | Both files mentioned in the comment now include TargetOpcodes.def. Just mention that directly. llvm-svn: 354316
* [mips] Remove trailing whitespaces from the test case. NFCSimon Atanasyan2019-02-191-3/+3
| | | | llvm-svn: 354315
* [NFC] API for signaling that the current loop is being deletedMax Kazantsev2019-02-191-9/+30
| | | | | | | We are planning to be able to delete the current loop in LoopSimplifyCFG in the future. Add API to notify the loop pass manager that it happened. llvm-svn: 354314
* [NFC] Store loop header in a local to keep it available after the loop is ↵Max Kazantsev2019-02-191-11/+9
| | | | | | deleted llvm-svn: 354313
* [mips] Create LA25 thunks for MIPS R6 codeSimon Atanasyan2019-02-192-25/+49
| | | | | | | | MIPS R6 code uses the `R_MIPS_PC26_S2` relocation for calls which might cross boundaries of non-PIC-to-PIC code. We need to create a LA25 thunks for that case. llvm-svn: 354312
* [MIPS] Handle cross-mode (regular <-> microMIPS) jumpsSimon Atanasyan2019-02-197-18/+182
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The patch solves two tasks: 1. MIPS ABI allows to mix regular and microMIPS code and perform cross-mode jumps. Linker needs to detect such cases and replace jump/branch instructions by their cross-mode equivalents. 2. Other tools like dunamic linkers need to recognize cases when dynamic table entries, e_entry field of an ELF header etc point to microMIPS symbol. Linker should provide such information. The first task is implemented in the `MIPS<ELFT>::relocateOne()` method. New routine `fixupCrossModeJump` detects ISA mode change, checks and replaces an instruction. The main problem is how to recognize that relocation target is microMIPS symbol. For absolute and section symbols compiler or assembler set the less-significant bit of the symbol's value or sum of the symbol's value and addend. And this bit signals to linker about microMIPS code. For global symbols compiler cannot do the same trick because other tools like, for example, disassembler wants to know an actual position of the symbol. So compiler sets STO_MIPS_MICROMIPS flag in the `st_other` field. In `MIPS<ELFT>::relocateOne()` method we have a symbol's value only and cannot access any symbol's attributes. To pass type of the symbol (regular/microMIPS) to that routine as well as other places where we write a symbol value as-is (.dynamic section, `Elf_Ehdr::e_entry` field etc) we set when necessary a less-significant bit in the `getSymVA` function. Differential revision: https://reviews.llvm.org/D40147 llvm-svn: 354311
* [ARM GlobalISel] Support G_PHI for Thumb2Diana Picus2019-02-194-136/+186
| | | | | | Same as arm mode. llvm-svn: 354310
* Fix vscode tests for python3Pavel Labath2019-02-191-2/+2
| | | | | | | | encode/decode the data before sending it over the socket. Since (AFAICT) the vscode protocol (unlike the gdb-remote one) is fully textual, using the utf8 codec here is appropriate. llvm-svn: 354308
* [gui] Simplify SourceFileWindowDelegate::WindowDelegateDrawPavel Labath2019-02-191-5/+2
| | | | | | | | | instead of printf-ing into a buffer, and them using that buffer as a format string, simply use the appropriate indirect format string. This also fixes a -Wformat-truncation warning with gcc. llvm-svn: 354307
* [Dominators] Fix and optimize edge insertion of depth-based searchFangrui Song2019-02-191-96/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: After (x,y) is inserted, depth-based search finds all affected v that satisfies: depth(nca(x,y))+1 < depth(v) && there exists a path P from y to v where every w on P satisfies depth(v) <= depth(w) This reduces to a widest path problem (maximizing the depth of the minimum vertex in the path) which can be solved by a modified version of Dijkstra with a bucket queue (named depth-based search in the paper). The algorithm visits vertices in decreasing order of bucket number. However, the current code misused priority_queue to extract them in increasing order. I cannot think of a failing scenario but it surely may process vertices more than once due to the local usage of Processed. This patch fixes this bug and simplifies/optimizes the code a bit. Also add more comments. Reviewers: kuhar Reviewed By: kuhar Subscribers: kristina, jdoerfert, llvm-commits, NutshellySima, brzycki Tags: #llvm Differential Revision: https://reviews.llvm.org/D58349 llvm-svn: 354306
* [X86] Remove command line strings from the ProcIntel* features.Craig Topper2019-02-191-10/+10
| | | | | | These should always follow the CPU string. There's no reason to control them independently. llvm-svn: 354304
* [lldb-instr] Test that we ignore existing macros.Jonas Devlieghere2019-02-193-1/+13
| | | | | | Although the functionality was already present, it wasn't tested. llvm-svn: 354303
* [lldb-instr] Wrap returns of struct/classes in LLDB_RECORD_RESULTJonas Devlieghere2019-02-195-4/+50
| | | | | | | The instrumentation framework requires return values of custom classes and structs to be wrapped in the LLDB_RECORD_RESULT macro. llvm-svn: 354301
* Disable TestModuleCXX.test on WindowsJonas Devlieghere2019-02-191-0/+2
| | | | | | | | | | Importing cxx modules doesn't seem to work on Windows: error: a.out :: Class 'tagARRAYDESC' has a member 'tdescElem' of type 'tagTYPEDESC' which does not have a complete definition. error: a.out :: Class 'tagPARAMDESCEX' has a member 'varDefaultValue' of type 'tagVARIANT' which does not have a complete definition. llvm-svn: 354300
* [GlobalISel][AArch64] Legalize + select some llvm.ctlz.* intrinsicsJessica Paquette2019-02-186-1/+233
| | | | | | | | | | | | Legalize/select llvm.ctlz.* Add select-ctlz to show that we actually select them. Update arm64-clrsb.ll and arm64-vclz.ll to show that we perform valid transformations in optimized builds, and document where GISel can improve. Differential Revision: https://reviews.llvm.org/D58155 llvm-svn: 354299
* [CGP] form usub with overflow from sub+icmpSanjay Patel2019-02-187-99/+189
| | | | | | | | | | | | | | | | | The motivating x86 cases for forming the intrinsic are shown in PR31754 and PR40487: https://bugs.llvm.org/show_bug.cgi?id=31754 https://bugs.llvm.org/show_bug.cgi?id=40487 ..and those are shown in the IR test file and x86 codegen file. Matching the usubo pattern is harder than uaddo because we have 2 independent values rather than a def-use. This adds a TLI hook that should preserve the existing behavior for uaddo formation, but disables usubo formation by default. Only x86 overrides that setting for now although other targets will likely benefit by forming usbuo too. Differential Revision: https://reviews.llvm.org/D57789 llvm-svn: 354298
* [lldbtest] Fix some code to be compatible between py2 and py3.Davide Italiano2019-02-181-18/+4
| | | | llvm-svn: 354297
* [clang][test] Fix FileManagerTest.getFileDontOpenRealPath for WindowsJan Korous2019-02-181-6/+10
| | | | llvm-svn: 354296
* AMDGPU: Use MachineInstr::mayAlias to replace ↵Changpeng Fang2019-02-183-21/+138
| | | | | | | | | | | | | | | areMemAccessesTriviallyDisjoint in LoadStoreOptimizer pass. Summary: This is to fix a memory dependence bug in LoadStoreOptimizer. Reviewers: arsenm, rampitec Differential Revision: https://reviews.llvm.org/D58295 llvm-svn: 354295
* [lldb-instr] Add constructor and move test into lit/toolsJonas Devlieghere2019-02-184-16/+26
| | | | | | | | The test had an implicit constructor for the Foo struct. Also, as the instrumentation doesn't have to be reproducer specific, I moved the tests into the lit/tools directory. llvm-svn: 354294
* GlobalISel: Implement widenScalar for g_extract scalar resultsMatt Arsenault2019-02-185-11/+359
| | | | llvm-svn: 354293
* GlobalISel: Make buildExtract use DstOp/SrcOpMatt Arsenault2019-02-182-13/+16
| | | | llvm-svn: 354292
* Reland "[clang][FileManager] fillRealPathName even if we aren't opening the ↵Jan Korous2019-02-182-0/+32
| | | | | | | | | file" This reverts commit e2bb3121fd4ab5b01f9ec1d2e3e9877db9c6a54c. + fixed test for Windows llvm-svn: 354291
* [LSan][Darwin][NFC] Add comment explaining test failureJulian Lettner2019-02-181-1/+1
| | | | llvm-svn: 354290
* One more fix while I'm looking at this - remove the Jason Molenda2019-02-181-7/+1
| | | | | | | | | unused IsSBProcess method, and have IsFBSProcess return false if we don't have API that we can use to make that determination, so we'll try other API if we can. llvm-svn: 354289
* Ah, misunderstood Jonas' feedback - fix this so we'llJason Molenda2019-02-181-1/+2
| | | | | | | do the right thing when both API are available. We want to try both of them if the first one fails. llvm-svn: 354288
* Clean up an unused variable warning when building this forJason Molenda2019-02-181-0/+4
| | | | | | mac native. llvm-svn: 354287
* [Python3] Fix TestObjCMethods.py to work with py2 and 3.Davide Italiano2019-02-181-1/+1
| | | | llvm-svn: 354286
* [libcxxabi][CMake] Drop unused HandleOutOfTreeLLVM includePetr Hosek2019-02-181-3/+0
| | | | | | | | | | | | This include doesn't seem to be needed for the standalone build (it's not being used by libc++ build either), but introduces unnecessary dependency because HandleOutOfTreeLLVM performs checks that require a working C++ library. We shouldn't require a working C++ library to build libc++abi or libc++ (it's what we're building after all). Differential Revision: https://reviews.llvm.org/D58333 llvm-svn: 354284
OpenPOWER on IntegriCloud