1. Feb 28, 2019
    • Jan Korous's avatar
      [clang][index-while-building] FileIndexRecord · edbbe470
      Jan Korous authored
      Basic data structures for index
      
      Tests are missing from this patch - will be covered properly by tests for the whole feature.
      I'm just trying to split into smaller patches to make it easier for reviewers.
      
      Differential Revision: https://reviews.llvm.org/D58478
      
      llvm-svn: 355035
      edbbe470
    • James Y Knight's avatar
      Fixup compilation/test failures after r354960 and r355013. · f33b1f49
      James Y Knight authored
      llvm-svn: 355034
      f33b1f49
    • Joerg Sonnenberger's avatar
      Use Secure PLT as default on NetBSD/PowerPC. · b4a9d3e8
      Joerg Sonnenberger authored
      llvm-svn: 355033
      b4a9d3e8
    • Zachary Turner's avatar
      Move Host/Symbols.cpp to Symbols/LocateSymbolFile.cpp · 80552918
      Zachary Turner authored
      Given that we have a target named Symbols, one wonders why a
      file named Symbols.cpp is not in this target.  To be clear,
      the functions exposed from this file are really focused on
      *locating* a symbol file on a given host, which is where the
      ambiguity comes in.  However, it makes more sense conceptually
      to be in the Symbols target. While some of the specific places
      to search for symbol files might change depending on the Host,
      this is not inherently true in the same way that, for example,
      "accessing the file system" or "starting threads" is
      fundamentally dependent on the Host.
      
      PDBs, for example, recently became a reality on non-Windows platforms,
      and it's theoretically possible that DSYMs could become a thing on non
      MacOSX platforms (maybe in a remote debugging scenario). Other types of
      symbol files, such as DWO, DWP, etc have never been tied to any Host
      platform anyway.
      
      After this patch, there is only one remaining dependency from
      Host to Target.
      
      Differential Revision: https://reviews.llvm.org/D58730
      
      llvm-svn: 355032
      80552918
    • Matt Davis's avatar
      [llvm-cxxfilt] Re-enable split and demangle stdin input on certain non-alphanumerics. · 1d5c2352
      Matt Davis authored
      This restores the patch that splits demangled stdin input on
      non-alphanumerics.  I had reverted this patch earlier because it broke
      Windows build-bots.  I have updated the test so that it passes on
      Windows.
      
      I was running the test from powershell and never saw the issue until I
      switched to the mingw shell.
      
      This reverts commit 628ab5c6.
      
      llvm-svn: 355031
      1d5c2352
    • Evgeniy Stepanov's avatar
      [hwasan, asan] Intercept vfork. · f46a52b5
      Evgeniy Stepanov authored
      Summary:
      Intercept vfork on arm, aarch64, i386 and x86_64.
      
      Reviewers: pcc, vitalybuka
      
      Subscribers: kubamracek, mgorny, javed.absar, krytarowski, kristof.beyls, #sanitizers, llvm-commits
      
      Tags: #sanitizers, #llvm
      
      Differential Revision: https://reviews.llvm.org/D58533
      
      llvm-svn: 355030
      f46a52b5
    • Alexandre Ganea's avatar
      [LLD][COFF] Support /threads[:no] like the ELF driver · 97b2b063
      Alexandre Ganea authored
      Differential review: https://reviews.llvm.org/D58594
      
      llvm-svn: 355029
      97b2b063
    • Evgeniy Stepanov's avatar
      [hwasan] Fix tests after .cc->.cpp renaming. · c6bcc185
      Evgeniy Stepanov authored
      llvm-svn: 355028
      c6bcc185
    • Alexey Bataev's avatar
      [OPENMP]Delay emission of the error for unsupported types. · 123ad196
      Alexey Bataev authored
      If the type is unsupported on the device side, it still must be emitted,
      but we should emit errors for operations with such types.
      
      llvm-svn: 355027
      123ad196
    • Jim Ingham's avatar
      Pass arguments correctly to the objc object checker on arm64 · b12ac2b6
      Jim Ingham authored
      Traditionally objc had two entry points, objc_msgSend for scalar
      return methods, and objc_msgSend_stret for struct return convention
      methods.  But on arm64 the second was not needed (since arm64 doesn't
      use an argument register for the struct return pointer) so it was removed.
      
      The code that dispatches to the objc object checker when it sees some
      flavor of objc_msgSend was not aware of this change so was sending the
      wrong arguments to the checker.
      
      <rdar://problem/48315890>
      
      Differential Revision: https://reviews.llvm.org/D58699
      
      llvm-svn: 355026
      b12ac2b6
    • Philip Reames's avatar
      Seperate volatility and atomicity/ordering in SelectionDAG · 288a95fc
      Philip Reames authored
      At the moment, we mark every atomic memory access as being also volatile. This is unnecessarily conservative and prohibits many legal transforms (DCE, folding, etc..).
      
      This patch removes MOVolatile from the MachineMemOperands of atomic, but not volatile, instructions. This should be strictly NFC after a series of previous patches which have gone in to ensure backend code is conservative about handling of isAtomic MMOs. Once it's in and baked for a bit, we'll start working through removing unnecessary bailouts one by one. We applied this same strategy to the middle end a few years ago, with good success.
      
      To make sure this patch itself is NFC, it is build on top of a series of other patches which adjust code to (for the moment) be as conservative for an atomic access as for a volatile access and build up a test corpus (mostly in test/CodeGen/X86/atomics-unordered.ll)..
      
      Previously landed
      
          D57593 Fix a bug in the definition of isUnordered on MachineMemOperand
          D57596 [CodeGen] Be conservative about atomic accesses as for volatile
          D57802 Be conservative about unordered accesses for the moment
          rL353959: [Tests] First batch of cornercase tests for unordered atomics.
          rL353966: [Tests] RMW folding tests w/unordered atomic operations.
          rL353972: [Tests] More unordered atomic lowering tests.
          rL353989: [SelectionDAG] Inline a single use helper function, and remove last non-MMO interface
          rL354740: [Hexagon, SystemZ] Be super conservative about atomics
          rL354800: [Lanai] Be super conservative about atomics
          rL354845: [ARM] Be super conservative about atomics
      
      Attention Out of Tree Backend Owners: This patch may break you. If it does, you can use the TLI getMMOFlags hook to restore the MOVolatile to any instruction you need to. (See llvm-dev thread titled "PSA: Changes to how atomics are handled in backends" started Feb 27, 2019.)
      
      Differential Revision: https://reviews.llvm.org/D57601
      
      llvm-svn: 355025
      288a95fc
    • Hyrum Wright's avatar
      [clang-tidy] Add the abseil-time-subtraction check · c526e026
      Hyrum Wright authored
      Differential Revision: https://reviews.llvm.org/D58137
      
      llvm-svn: 355024
      c526e026
    • Rong Xu's avatar
      Fixed ubsan failures in r355005. · ac552f77
      Rong Xu authored
      llvm-svn: 355023
      ac552f77
    • Julian Lettner's avatar
      [NFC][Sanitizer] Hard-code fast/slow unwinder at call site · 46e1b16e
      Julian Lettner authored
      Also assert that the caller always gets what it requested.
      
      This purely mechanical change simplifies future refactorings and
      eventual removal of BufferedStackTrace::Unwind.
      
      Reviewers: vitalybuka
      
      Differential Revision: https://reviews.llvm.org/D58557
      
      llvm-svn: 355022
      46e1b16e
    • Matt Davis's avatar
      Revert "[llvm-cxxfilt] Split and demangle stdin input on certain non-alphanumerics." · 628ab5c6
      Matt Davis authored
      This reverts commit 5cd5f8f2.
      The test passes on linux, but fails on the windows build-bots.
      
      This test failure seems to be a quoting issue between my test and
      FileCheck on Windows.  I'm reverting this patch until I can replicate
      and fix in my Windows environment.
      
      llvm-svn: 355021
      628ab5c6
    • Sanjay Patel's avatar
      [InstCombine] add tests for add+ext+add; NFC · ac96a92d
      Sanjay Patel authored
      llvm-svn: 355020
      ac96a92d
    • Jonathan Metzman's avatar
      [libFuzzer][Windows] Port fork mode to Windows · 518514e8
      Jonathan Metzman authored
      Summary:
      Port libFuzzer's fork mode to Windows.
      Implement Windows versions of MkDir, RmDir, and IterateDirRecursive to do this.
      Don't print error messages under new normal uses of FileSize (on a non-existent file).
      Implement portable way of piping output to /dev/null.
      Fix test for Windows and comment fork-sigusr.test on why it won't be ported to Win.
      
      Reviewers: zturner
      
      Reviewed By: zturner
      
      Subscribers: kcc, zturner, jdoerfert, #sanitizers, llvm-commits
      
      Tags: #sanitizers, #llvm
      
      Differential Revision: https://reviews.llvm.org/D58513
      
      llvm-svn: 355019
      518514e8
    • Julian Lettner's avatar
      [Darwin][NFC] Refactor throttling of 64bit sanitizer tests on Darwin · 6eef7d05
      Julian Lettner authored
      Underlying condition for throttling is "has large mmap'd regions" (i.e.,
      shadow memory) and not sanitizers in general (e.g., UBSan does not need
      to be throttled).
      
      Rename parallelism group `darwin-64bit-sanitizer` to `shadow-memory` and
      apply it unconditionally to all tests which require it. We can then have
      all the Darwin throttling logic in one place in the commen lit config.
      
      Throttle sanitizer_common unit tests. Configuration was previously
      missing from sanitizer_common/Unit/lit.site.cfg.
      
      Reviewed by: kubamracek
      
      Differential Revision: https://reviews.llvm.org/D58677
      
      llvm-svn: 355018
      6eef7d05
    • Akira Hatanaka's avatar
      Add triples to the test I committed in r355012 to fix windows bots. · b65a8ad7
      Akira Hatanaka authored
      llvm-svn: 355017
      b65a8ad7
    • Simon Pilgrim's avatar
      [X86][AVX] Pull out some INSERT_SUBVECTOR combines into a combineConcatVectorOps helper. NFCI · 1001a6ab
      Simon Pilgrim authored
      A lot of the INSERT_SUBVECTOR combines can be more generally handled as if they have come from a CONCAT_VECTORS node.
      
      I've been investigating adding a CONCAT_VECTORS combine to X86, but this is a much easier first step that avoids the issue of handling a number of pre-legalization issues that I've encountered.
      
      Differential Revision: https://reviews.llvm.org/D58583
      
      llvm-svn: 355015
      1001a6ab
    • Matt Davis's avatar
      [llvm-readobj] Print section type values for unknown sections. · 7a24dbdf
      Matt Davis authored
      Summary:
      This patch displays a hexadecimal section value (Elf_Shdr::sh_type) or section-relative offset when printing unknown sections.
      
      Here is a subset of the output (ignoring the fields following "Type" when dumping an ELF's GNU `--section-headers` table).
      Section Headers:
      ```
        [Nr] Name              Type
        [16] android_rel       LOOS+0x1
        [17] android_rela      LOOS+0x2
        [27] unknown           0x1000: <unknown>
        [28] loos              LOOS+0
        [30] hios              VERSYM
        [31] loproc            LOPROC+0
        [33] hiproc            LOPROC+0xFFFFFFF
        [34] louser            LOUSER+0
        [36] hiuser            LOUSER+0x7FFFFFFF
      ```
      
      As a comparison, the previous output looked something like the above, but with a blank "Type" field:
      ```
        [Nr] Name              Type
        [27] unknown
        [28] loos
        [30] hios              VERSYM
        [31] loproc
        [33] hiproc
        [34] louser
        [36] hiuser
      ```
      
      This fixes PR40773
      
      Reviewers: jhenderson, rupprecht, Bigcheese
      
      Reviewed By: jhenderson, rupprecht, Bigcheese
      
      Subscribers: MaskRay, Bigcheese, srhines, jdoerfert, llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D58701
      
      llvm-svn: 355014
      7a24dbdf
    • Alexey Lapshin's avatar
      Attempt to fix buildbot after r354972 [#1]. NFCI. · d89d6380
      Alexey Lapshin authored
      llvm-svn: 355013
      d89d6380
    • Akira Hatanaka's avatar
      Avoid needlessly copying a block to the heap when a block literal · c5792aa9
      Akira Hatanaka authored
      initializes a local auto variable or is assigned to a local auto
      variable that is declared in the scope that introduced the block
      literal.
      
      rdar://problem/13289333
      
      https://reviews.llvm.org/D58514
      
      llvm-svn: 355012
      c5792aa9
    • Matt Davis's avatar
      [llvm-cxxfilt] Re-enable the delimiters test on Windows. · 69bec619
      Matt Davis authored
      The original intent was to enable this test for Windows; however, that
      initial patch broke one of the build-bots.  I temporarily disabled this
      test on Windows until that issue was resolved.  It was resolved in my
      previous patch (cfd1d9742ee2d1b8dd6b7), and now I am re-enabling this
      test.
      
      llvm-svn: 355011
      69bec619
    • Louis Dionne's avatar
      [libc++] Add is_nothrow_convertible from P0758R1 · ab19068b
      Louis Dionne authored
      Reviewed as https://reviews.llvm.org/D58019.
      Thanks to Zoe Carver for the patch.
      
      llvm-svn: 355010
      ab19068b
    • Jonas Devlieghere's avatar
      [Reproducer] Make 'reproducer generate' a NOOP during replay. · 2dca6538
      Jonas Devlieghere authored
      Instead of filtering out the 'reproducer generate' command during
      replay, just make the operation a NOOP.
      
      llvm-svn: 355009
      2dca6538
    • David Goldman's avatar
      Support framework import/include auto-completion · 3e804d25
      David Goldman authored
      Frameworks filesystem representations:
        UIKit.framework/Headers/%header%
      
      Framework import format:
        #import <UIKit/%header%>
      
      Thus the completion code must map the input format of <UIKit/> to
      the path of UIKit.framework/Headers as well as strip the
      ".framework" suffix when auto-completing the framework name.
      
      llvm-svn: 355008
      3e804d25
    • Matt Davis's avatar
      Clean up the delimiters test. · eaa89536
      Matt Davis authored
      Ideally this is a NFCI, used single quotes in most cases.  Hopefully
      this will make the Windows bot happy.
      
      I've marked this unsupported on windows, until I get my windows box
      setup with this patch to test.  I'll remove that constraint after I'm
      confident this will pass on windows.  I just want to silence the
      buildbots for now.
      
      llvm-svn: 355007
      eaa89536
    • Louis Dionne's avatar
      [libc++] Remove visibility-related warnings with Clang 8 · 1be935f4
      Louis Dionne authored
      The attributes were placed incorrectly -- they need to be after the
      "struct" keyword, not before.
      
      llvm-svn: 355006
      1be935f4
    • Rong Xu's avatar
      Recommit r354930 "[PGO] Context sensitive PGO (part 1)" · 6cdf3d80
      Rong Xu authored
      Fixed UBSan failures.
      
      llvm-svn: 355005
      6cdf3d80
    • James Henderson's avatar
      [llvm-readobj]Add additional testing for various ELF features · 416603e3
      James Henderson authored
      This patch adds testing of areas of the code that are not fully tested,
      in particular dynamic table printing, ELF type printing, handling of
      edge cases where things are missing/empty (relocations/program header
      tables/section header table), and the --string-dump switch.
      
      Reviewed by: grimar, higuoxing, rupprecht
      
      Differential Revision: https://reviews.llvm.org/D58677
      
      llvm-svn: 355003
      416603e3
    • Jonas Devlieghere's avatar
      [Reproducers] Add more logging to reproducer instrumentation · 8c436ce3
      Jonas Devlieghere authored
      Debugging issues with instrumentation capture and replay can be
      particularly tricky, especially because part of the process takes places
      even before the debugger is initialized. This patch adds more logging
      capabilities to these classes, hidden behind a macro define.
      
      Differential revision: https://reviews.llvm.org/D58566
      
      llvm-svn: 355002
      8c436ce3
    • Xing GUO's avatar
      [llvm-objdump] Should print strings when dumping DT_RPATH, DT_RUNPATH,... · d78164a8
      Xing GUO authored
      [llvm-objdump] Should print strings when dumping DT_RPATH, DT_RUNPATH, DT_SONAME, DT_AUXILIARY and DT_FILTER tags in dynamic section.
      
      Summary:
      Before:
      ```
      Dynamic Section:
        NEEDED               libpthread.so.0
        ...
        NEEDED               ld-linux-x86-64.so.2
        RPATH                0x00000000001c2e61
      ```
      
      After:
      ```
      Dynamic Section:
        NEEDED               libpthread.so.0
        ...
        NEEDED               ld-linux-x86-64.so.2
        RPATH                $ORIGIN/../lib
      ```
      
      Only a small problem here, I have no idea on choosing test case. I see there's a test 
      file(test/tools/llvm-objdump/private-headers-dynamic-section.test). But it has no DT_RPATH and DT_RUNPATH tags. Shall I replace the ELF file in the 
      Inputs dir by a new one?
      
      Reviewers: jhenderson, grimar
      
      Reviewed By: jhenderson
      
      Subscribers: srhines, rupprecht, jfb, llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D58707
      
      llvm-svn: 355001
      d78164a8
    • Balazs Keri's avatar
      [ASTImporter] Improve import of FileID. · 9cf39dfb
      Balazs Keri authored
      Summary:
      Even if the content cache has a directory and filename, it may be a virtual file.
      The old code returned with error in this case, but it is worth to try to handle
      the file as it were a memory buffer.
      
      Reviewers: a.sidorin, shafik, martong, a_sidorin
      
      Reviewed By: shafik
      
      Subscribers: efriedma, rnkovacs, cfe-commits, dkrupp, martong, Szelethus, gamesh411
      
      Tags: #clang
      
      Differential Revision: https://reviews.llvm.org/D57590
      
      llvm-svn: 355000
      9cf39dfb
    • Kostya Kortchinsky's avatar
      [scudo][standalone] Add a standalone vector class · b3a924af
      Kostya Kortchinsky authored
      Summary:
      This CL adds a standalone vector class that will be used by the scoped
      strings when they land. We reimplement our own vector class because we
      can't use the std library one.
      
      It's mostly borrowed from the current sanitizer_common one, with LLVM
      code style changes.
      
      Additionnally a casing change in a function name that slipped through
      the previous review (the function isn't used yet).
      
      Reviewers: vitalybuka, eugenis, flowerhack, dmmoore415, mcgrathr, morehouse
      
      Reviewed By: vitalybuka
      
      Subscribers: mgorny, delcypher, #sanitizers, llvm-commits
      
      Tags: #llvm, #sanitizers
      
      Differential Revision: https://reviews.llvm.org/D58689
      
      llvm-svn: 354999
      b3a924af
    • Matt Davis's avatar
      [llvm-cxxfilt] Split and demangle stdin input on certain non-alphanumerics. · 5cd5f8f2
      Matt Davis authored
      Summary:
      This patch attempts to replicate GNU c++-filt behavior when splitting stdin input for demangling.
      
      Previously, cxx-filt would split input only on spaces.  Each delimited item is then demangled.
      From what I have tested, GNU c++filt also splits input on any character that does not make
      up the mangled name (notably commas, but also a large set of non-alphanumeric characters).
      
      This patch splits stdin input on any character that does not belong to the Itanium mangling
      format (since Itanium is currently the only supported format in llvm-cxxfilt).
      
      This is an update to PR39990
      
      Reviewers: jhenderson, tejohnson, compnerd
      
      Reviewed By: compnerd
      
      Subscribers: erik.pilkington, llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D58416
      
      llvm-svn: 354998
      5cd5f8f2
    • Nikita Popov's avatar
      [InstCombine] Add additional add.sat overflow tests; NFC · a54fe156
      Nikita Popov authored
      Baseline for D58593.
      
      llvm-svn: 354996
      a54fe156
    • Marshall Clow's avatar
      I changed a 'enable_if<...>::type to' 'enable_if_t<...>' but forgot to remove... · 5c814099
      Marshall Clow authored
      I changed a 'enable_if<...>::type to' 'enable_if_t<...>' but forgot to remove the preceding 'typename'
      
      llvm-svn: 354995
      5c814099
    • Dmitri Gribenko's avatar
      Added documentation for clangd v9+ features · 5d58625e
      Dmitri Gribenko authored
      Reviewers: ilya-biryukov
      
      Subscribers: ioeric, MaskRay, jkorous, arphaman, kadircet, jdoerfert, cfe-commits
      
      Tags: #clang
      
      Differential Revision: https://reviews.llvm.org/D58717
      
      llvm-svn: 354994
      5d58625e
  2. Feb 27, 2019