1. Jan 30, 2021
  2. Jan 29, 2021
    • J-Y You's avatar
      [TableGen] Fix instantiating multiclass in foreach · 5046c5be
      J-Y You authored
      If multiclass argument comes from loop varaible and argument is record type,
      it will not recognize the type. This patch ensures that loop variables are
      resolved correctly.
      
      Differential Revision: https://reviews.llvm.org/D95308
      5046c5be
    • Nico Weber's avatar
      clang-cl: Accept /std:c11, /std:c17 flags · d087d805
      Nico Weber authored
      clang-cl already defaults to C17 for .c files, but no harm
      in accepting these flags. Fixes PR48185.
      
      Differential Revision: https://reviews.llvm.org/D95575
      d087d805
    • Nico Weber's avatar
      clang-cl: Invent a /winsysroot concept · 82847436
      Nico Weber authored
      On non-Windows platforms, --sysroot can be used to make the compiler use
      a single, hermetic directory for all header and library files.
      
      This is useful, but difficult to do on Windows. After D95472 it's
      possible to achieve this with two flags:
      
          out/gn/bin/clang-cl win.c -fuse-ld=lld \
              /vctoolsdir path/to/VC/Tools/MSVC/14.26.28801 \
              /winsdkdir path/to/win_sdk
      
      But that's still cumbersome: It requires two flags instead of one, and
      it requires writing down the (changing) VC/Tools/MSVC version.
      
      This adds a new `/winsysroot <dir>` flag that's effectively an alias to
      these two flags. With this, building against a hermetic Windows
      toolchain only needs:
      
          out/gn/bin/clang-cl win.c -fuse-ld=lld /winsysroot path
      
      `/winsysroot <dir>` is the same as adding
      
          /vctoolsdir <dir>/VC/Tools/MSVC/<vctoolsver>
          /winsdkdir <dir>/Windows Kits/<winsdkmajorversion>
      
      `<vctoolsver>` is taken from `/vctoolsversion` if passed, or else it's
      the name of the directory in `<dir>/VC/Tools/MSVC` that's the highest
      numeric tuple.
      
      `<winsdkmajorversion>` is the major version in /winsdkversion if passed,
      else it's the name of the directory in `<dir>/Windows Kits` that's the
      highest number.
      
      So `/winsysroot <path>` requires this subfolder structure:
      
        path/
          VC/
            Tools/
              MSVC/
                14.26.28801  (or another number)
                  include/
                  ...
          Windows Kits/
            10/
              Include/
                10.0.19041.0/ (or another number)
                  um/
                  ...
              Lib/
                10.0.19041.0/ (or another number)
                  um/
                    x64/
                    ...
                  ...
      
      Differential Revision: https://reviews.llvm.org/D95534
      82847436
    • Simon Pilgrim's avatar
      [X86][SSE] combineExtractWithShuffle - support zero-extending to allow... · d6b68d13
      Simon Pilgrim authored
      [X86][SSE] combineExtractWithShuffle - support zero-extending to allow extracting from narrow shuffle masks
      
      If the shuffle mask can't be widened to match the original extracted element width, see if the upper bits are zeroable - which allows us to extract+zero-extend the smaller extraction.
      d6b68d13
    • Christian Sigg's avatar
      [mlir] Remove mlir_c_runner_utils_static. · 27924b12
      Christian Sigg authored
      The library is not actually static when BUILD_SHARED_LIBS is on, and tests need to explicitly load it already. Also, the shared objects it was linked to did not use any symbols from it and it was therefore never linked to it.
      
      Reviewed By: ftynse
      
      Differential Revision: https://reviews.llvm.org/D95612
      27924b12
    • Sam McCall's avatar
      Revert "[clangd] Extract symbol-scope logic out of Quality, add tests. NFC" · 7d1b499c
      Sam McCall authored
      On second thought, this can't properly be reused for highlighting.
      
      Consider this example, which Quality wants to consider function-scope,
      but highlighting must consider class-scope:
      
      void foo() {
        class X {
          int ^y;
        };
      }
      7d1b499c
    • Sam McCall's avatar
      [clangd] Extract symbol-scope logic out of Quality, add tests. NFC · d0817b5f
      Sam McCall authored
      This prepares for reuse from the semantic highlighting code.
      
      There's a bit of yak-shaving here:
       - when the enum is moved into the clangd namespace, promote it to a
         scoped enum. This means teaching the decision forest infrastructure
         to deal with scoped enums.
       - AccessibleScope isn't quite the right name: e.g. public class members
         are treated as accessible, but still have class scope. So rename to
         SymbolScope.
       - Rename some QualitySignals members to avoid name conflicts.
         (the string) SymbolScope -> Scope
         (the enum) Scope -> ScopeKind
      d0817b5f
    • Sjoerd Meijer's avatar
      f03f3a84
    • Nico Weber's avatar
      [gn build] port e90e455d · 229c1cff
      Nico Weber authored
      229c1cff
    • Haojian Wu's avatar
      [Syntax] Add syntax-tree-dump in clang-check. · e90e455d
      Haojian Wu authored
      This is useful to experiment/develop syntax trees.
      
      Reviewed By: sammccall
      
      Differential Revision: https://reviews.llvm.org/D95526
      e90e455d
    • Abhina Sreeskantharajan's avatar
      [test] Use host platform specific error message substitution in lit tests · 42a21778
      Abhina Sreeskantharajan authored
      On z/OS, the following error message is not matched correctly in lit tests.
      
      ```
      EDC5129I No such file or directory.
      ```
      
      This patch uses a lit config substitution to check for platform specific error messages.
      
      Reviewed By: muiez, jhenderson
      
      Differential Revision: https://reviews.llvm.org/D95246
      42a21778
    • Nikita Popov's avatar
      [MemCpyOpt] Add test for incorrect optimization across lifetime (NFC) · 6e52eebc
      Nikita Popov authored
      This only affects the MemorySSA-based implementation.
      6e52eebc