Skip to content
  1. Nov 11, 2019
    • Nick Desaulniers's avatar
      change LLVM_VERSION_SUFFIX default from svn to git · 49fb4a96
      Nick Desaulniers authored
      
      
      Summary:
      Sayonara SVN!
      
      Signed-off-by: default avatarNick Desaulniers <ndesaulniers@google.com>
      
      Reviewers: tstellar, jyknight, lebedev.ri, smeenai, mgorny, hans, mclow.lists
      
      Reviewed By: mgorny, hans
      
      Subscribers: christof, libcxx-commits, llvm-commits, srhines
      
      Tags: #libc, #llvm
      
      Differential Revision: https://reviews.llvm.org/D70019
      49fb4a96
    • Sam McCall's avatar
      [Format] Fix clang-format.el unit tests after commit f349cc37 · a81c1a9c
      Sam McCall authored
      Also add a comment that test is not automatically run, and how to run it.
      
      Patch by Philipp Stephani!
      a81c1a9c
    • Pavel Labath's avatar
      lldb: Fix some -Wdeprecated-copy warnings · a14eb8f4
      Pavel Labath authored
      gcc-9 started warning when a class defined a copy constructor without a
      copy assignment operator (or vice-versa).
      
      This fixes those warnings by deleting the other special member too
      (after verifying it doesn't do anything non-trivial).
      a14eb8f4
    • LLVM GN Syncbot's avatar
      gn build: Merge 8d288a06 · 2da34a43
      LLVM GN Syncbot authored
      2da34a43
    • Abel Kocsis's avatar
    • Abel Kocsis's avatar
    • Francis Visoiu Mistrih's avatar
      [ObjC] Override TailCallKind when lowering objc intrinsics · a9a3781d
      Francis Visoiu Mistrih authored
      The tail-call-kind-ness is known by the ObjCARC analysis and can be
      enforced while lowering the intrinsics to calls.
      
      This allows us to get the requested tail calls at -O0 without trying to
      preserve the attributes throughout passes that change code even at -O0
      ,like the Always Inliner, where the ObjCOpt pass doesn't run.
      
      Differential Revision: https://reviews.llvm.org/D69980
      a9a3781d
    • Pavel Labath's avatar
      Fix TestNoGPacketSupported on linux · 135a493f
      Pavel Labath authored
      The mock server pretends the process stopped with signal 17, which is
      SIGCHLD on linux. This causes lldb to resume to process, utterly
      confusing the test. Lldb probably shouldn't resume in this case, but for
      now this issue can be fixed by changing the signal number to 2, which is
      SIGINT just about anywhere.
      135a493f
    • Abel Kocsis's avatar
    • Stefan Pintile's avatar
      [PowerPC] Implementing overflow version for XO-Form instructions · fdf3d176
      Stefan Pintile authored
      The Overflow version of XO-Form instruction uses the SO, OV and
      OV32 special registers.
      
      This changes modifies existing multiclasses and instruction
      definitions to allow for the use of the XER register to record
      the various types if overflow from possible add, subtract and
      multiply instructions. It then modifies the existing instructions
      as to use these multiclasses as needed.
      
      Patch By: Kamau Bridgeman
      
      Differential Revision: https://reviews.llvm.org/D66902
      fdf3d176
    • Haojian Wu's avatar
      [clangd] fixes semantic highlighting test · f8c17fe1
      Haojian Wu authored
      Summary: fixes https://github.com/clangd/clangd/issues/176
      
      Patch by liu hui!
      
      Reviewers: ilya-biryukov, hokein, sammccall
      
      Reviewed By: hokein
      
      Subscribers: MaskRay, jkorous, arphaman, kadircet, usaxena95, cfe-commits
      
      Tags: #clang-tools-extra, #clang
      
      Differential Revision: https://reviews.llvm.org/D70078
      f8c17fe1
    • Martin Probst's avatar
      clang-format: [JS] test declared fields. · 6bcd8d4a
      Martin Probst authored
      Summary:
      TypeScript now supports declaring fields:
      
          class Foo {
            declare field: string;
          }
      
      clang-format happens to already format this fine, so this change just
      adds a regression test.
      
      Reviewers: krasimir
      
      Subscribers: cfe-commits
      
      Tags: #clang
      
      Differential Revision: https://reviews.llvm.org/D69972
      6bcd8d4a
    • Martin Probst's avatar
      clang-format: [JS] support null operators. · a7638d38
      Martin Probst authored
      Summary:
      JavaScript / TypeScript is adding two new operators: the null
      propagating operator `?.` and the nullish coalescing operator `??`.
      
          const x = foo ?? 'default';
          const z = foo?.bar?.baz;
      
      This change adds support to lex and format both.
      
      Reviewers: krasimir
      
      Subscribers: cfe-commits
      
      Tags: #clang
      
      Differential Revision: https://reviews.llvm.org/D69971
      a7638d38
    • Louis Dionne's avatar
      [libc++] Mark __call_once_proxy as hidden and internal · 48b7068b
      Louis Dionne authored
      We effectively never want to export that function, which is an
      implementation detail of libc++. This was previously tried in
      603715c6 and then reverted in 8335dd31 because it caused
      linker warnings. These linker warnings should go away now that we
      use internal_linkage instead of always_inline to implement per-TU
      insulation.
      48b7068b
    • joanlluch's avatar
      [TargetLowering][DAGCombine][MSP430] Shift Amount Threshold in DAGCombine (4) (Baseline tests) · abbbf988
      joanlluch authored
      Summary: Baseline tests before applying D70042
      
      Reviewers: spatel, asl
      
      Subscribers: llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D70083
      abbbf988
    • Sanjay Patel's avatar
      Revert "[InstCombine] avoid crash from deleting an instruction that still has... · 29f5d167
      Sanjay Patel authored
      Revert "[InstCombine] avoid crash from deleting an instruction that still has uses (PR43723) (3rd try)"
      
      This reverts commit 3db8a3ef.
      This caused a different memory-sanitizer failure than earlier attempts,
      but it's still not right.
      29f5d167
    • Sanjay Patel's avatar
      [InstCombine] avoid crash from deleting an instruction that still has uses (PR43723) (3rd try) · 3db8a3ef
      Sanjay Patel authored
      Re-try because earlier attempts were reverted due to use-after-free.
      Hopefully, diagnosed correctly this time - we replace/remove the
      invariant.start first rather than the invariant.end to avoid angering
      worklist-based iteration.
      
      We gather a set of white-listed instructions in isAllocSiteRemovable() and then
      replace/erase them. But we don't know in general if the instructions in the set
      have uses amongst themselves, so order of deletion makes a difference.
      
      There's already a special-case for the llvm.objectsize intrinsic, so add another
      for llvm.invariant.start.
      
      Should fix:
      https://bugs.llvm.org/show_bug.cgi?id=43723
      
      Differential Revision: https://reviews.llvm.org/D69977
      3db8a3ef
    • Tom Weaver's avatar
      Revert "[DBG][OPT] Attempt to salvage or undef debug info when removing... · 9f48a160
      Tom Weaver authored
      Revert "[DBG][OPT] Attempt to salvage or undef debug info when removing trivially deletable instructions in the Reassociate Expression pass."
      
      This reverts commit 1984a27d.
      9f48a160
    • Tom Weaver's avatar
      [DBG][OPT] Attempt to salvage or undef debug info when removing trivially... · 1984a27d
      Tom Weaver authored
      [DBG][OPT] Attempt to salvage or undef debug info when removing trivially deletable instructions in the Reassociate Expression pass.
      
      Reviewed By: aprantl, vsk
      
      Differential revision: https://reviews.llvm.org/D69943
      1984a27d
    • Tom Weaver's avatar
      [NFC][TEST_COMMIT] Add fullstop to comment. · 75af15d8
      Tom Weaver authored
      75af15d8
    • Utkarsh Saxena's avatar
      [clangd] Use name of Macro to compute its SymbolID, NFC. · 02ec6ff7
      Utkarsh Saxena authored
      Summary:
      We use the name from the IdentifierInfo of the Macro to compute its
      SymbolID. It is better to just take the Name as a parameter to avoid
      storing the IdentifierInfo whenever we need the SymbolID for the Macro.
      
      Patch by UTKARSH SAXENA!
      
      Reviewers: hokein
      
      Reviewed By: hokein
      
      Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, cfe-commits
      
      Tags: #clang
      
      Differential Revision: https://reviews.llvm.org/D69937
      02ec6ff7
    • Simon Pilgrim's avatar
    • Simon Pilgrim's avatar
      b47c7cd4
    • Simon Pilgrim's avatar
      Fix -Wparentheses warning. NFCI. · 0040c4ba
      Simon Pilgrim authored
      0040c4ba
    • Simon Pilgrim's avatar
      8383be0f
    • Nuno Lopes's avatar
      docs: fix warning in LangRef parsing · a7244c56
      Nuno Lopes authored
      a7244c56
    • Jay Foad's avatar
      [InstCombine] Simplify binary op when only one operand is a select · 9323ef4e
      Jay Foad authored
      Summary:
      SimplifySelectsFeedingBinaryOp simplified binary ops when both operands
      were selects with the same condition. This patch extends it to handle
      these cases where only one operand is a select:
      
      X op (C ? P : Q) -> C ? (X op P) : (X op Q)
        // if X op P and X op Q both simplify
      (C ? P : Q) op Y -> C ? (P op Y) : (Q op Y)
        // if P op Y and Q op Y both simplify
      
      For example: X *fast (C ? 1.0 : 0.0) -> C ? X : 0.0
      
      Reviewers: mcberg2017, majnemer, craig.topper, qcolombet, mcrosier
      
      Subscribers: hiraditya, llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D64713
      9323ef4e
    • Michał Górny's avatar
      [lldb] [test] Fix typo in TestSendSignal · e2f0b243
      Michał Górny authored
      e2f0b243
    • Hans Wennborg's avatar
      Revert cdcf58e5 "[RISCV] enable LTO support, pass some options to linker." · b1ac1f00
      Hans Wennborg authored
      This started passing target-features on the linker line, not just for RISCV but
      for all targets, leading to error messages in Chromium Android build:
      
        '+soft-float-abi' is not a recognized feature for this target (ignoring feature)
        '+soft-float-abi' is not a recognized feature for this target (ignoring feature)
      
      See Phabricator review for details.
      
      Reverting until this can be fixed properly.
      
      > Summary:
      > 1. enable LTO need to pass target feature and abi to LTO code generation
      >    RISCV backend need the target feature to decide which extension used in
      >    code generation.
      > 2. move getTargetFeatures to CommonArgs.h and add ForLTOPlugin flag
      > 3. add general tools::getTargetABI in CommonArgs.h because different target uses different
      >    way to get the target ABI.
      >
      > Patch by Kuan Hsu Chen (khchen)
      >
      > Reviewers: lenary, lewis-revill, asb, MaskRay
      >
      > Reviewed By: lenary
      >
      > Subscribers: hiraditya, dschuff, aheejin, fedor.sergeev, mehdi_amini, inglorion, asb, rbar, johnrusso, simoncook, apazos, sabuasal, niosHD, kito-cheng, shiva0217, jrtc27, MaskRay, zzheng, edward-jones, steven_wu, rogfer01, MartinMosbeck, brucehoult, the_o, dexonsmith, rkruppe, PkmX, jocewei, psnobl, benna, Jim, lenary, s.egerton, pzheng, cfe-commits
      >
      > Tags: #clang
      >
      > Differential Revision: https://reviews.llvm.org/D67409
      b1ac1f00
    • Michał Górny's avatar
      36937ec7
    • Luís Marques's avatar
      [RISCV][NFC] Add nounwind to LKK test functions · 4197a765
      Luís Marques authored
      Differential Revision: https://reviews.llvm.org/D70067
      4197a765
    • Haojian Wu's avatar
      [clangd] Fix a regression of not showing documentation from forward declarations. · 41104a94
      Haojian Wu authored
      Summary:
      There is a regression from https://reviews.llvm.org/D68467. Unlike class
      forward declarations, function ducomentation is written in the declaration in
      headers, the function definition doesn't contain any documentation, cases like:
      
      ```
      foo.h
      // this is foo.
      void foo();
      foo.cc
      
      void foo() {}
      ```
      we should still show documentation from the foo declaration.
      
      Reviewers: ilya-biryukov
      
      Reviewed By: ilya-biryukov
      
      Subscribers: MaskRay, jkorous, arphaman, kadircet, usaxena95, cfe-commits
      
      Tags: #clang
      
      Differential Revision: https://reviews.llvm.org/D69961
      41104a94
    • QingShan Zhang's avatar
    • joanlluch's avatar
      [TargetLowering][DAGCombine][MSP430] Shift Amount Threshold in DAGCombine (3) · e0012c5d
      joanlluch authored
      Summary:
      Additional filtering of undesired shifts for targets that do not support them efficiently.
      
      Related with  D69116 and  D69120
      
      Applies the TLI.getShiftAmountThreshold hook to prevent undesired generation of shifts for the following IR code:
      
      ```
      define i16 @testShiftBits(i16 %a) {
      entry:
        %and = and i16 %a, -64
        %cmp = icmp eq i16 %and, 64
        %conv = zext i1 %cmp to i16
        ret i16 %conv
      }
      
      define i16 @testShiftBits_11(i16 %a) {
      entry:
        %cmp = icmp ugt i16 %a, 63
        %conv = zext i1 %cmp to i16
        ret i16 %conv
      }
      
      define i16 @testShiftBits_12(i16 %a) {
      entry:
        %cmp = icmp ult i16 %a, 64
        %conv = zext i1 %cmp to i16
        ret i16 %conv
      }
      ```
      The attached diff file shows the piece code in TargetLowering that is responsible for the generation of shifts in relation to the IR above.
      
      Before applying this patch, shifts will be generated to replace non-legal icmp immediates. However, shifts may be undesired if they are even more expensive for the target.
      
      For all my previous patches in this series (cited above) I added test cases for the MSP430 target. However, in this case, the target is not suitable for showing improvements related with this patch, because the MSP430 does not implement "isLegalICmpImmediate". The default implementation returns always true, therefore the patched code in TargetLowering is never reached for that target. Targets implementing both "isLegalICmpImmediate" and "getShiftAmountThreshold" will benefit from this.
      
      The differential effect of this patch can only be shown for the MSP430 by temporarily implementing "isLegalICmpImmediate" to return false for large immediates. This is simulated with the implementation of a command line flag that was incorporated in D69975
      
      This patch belongs to a initiative to "relax" the generation of shifts by LLVM for targets requiring it
      
      Reviewers: spatel, lebedev.ri, asl
      
      Reviewed By: spatel
      
      Subscribers: lenary, hiraditya, llvm-commits
      
      Tags: #llvm
      
      Differential Revision: https://reviews.llvm.org/D69326
      e0012c5d
    • Georgii Rymar's avatar
    • Matt Arsenault's avatar
      Use MCRegister in copyPhysReg · e6c9a9af
      Matt Arsenault authored
      e6c9a9af
    • Georgii Rymar's avatar
      [FixBB] - An attemp to fix clang-armv7-linux-build-cache builder. · a26d7b62
      Georgii Rymar authored
      http://lab.llvm.org:8011/builders/clang-armv7-linux-build-cache/builds/22130/steps/build%20stage%201/logs/stdio
      
      /usr/bin/c++   -DGTEST_HAS_RTTI=0 -D_DEBUG -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE -D_LARGEFILE_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Ilib/ObjectYAML -I/home/buildslave/buildslave/clang-armv7-linux-build-cache/llvm/llvm/lib/ObjectYAML -I/usr/include/libxml2 -Iinclude -I/home/buildslave/buildslave/clang-armv7-linux-build-cache/llvm/llvm/include -mthumb -fPIC -fvisibility-inlines-hidden -Werror=date-time -Werror=unguarded-availability-new -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -pedantic -Wno-long-long -Wimplicit-fallthrough -Wcovered-switch-default -Wno-noexcept-type -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Wstring-conversion -fdiagnostics-color -ffunction-sections -fdata-sections -O3    -UNDEBUG  -fno-exceptions -fno-rtti -std=c++14 -MMD -MT lib/ObjectYAML/CMakeFiles/LLVMObjectYAML.dir/YAML.cpp.o -MF lib/ObjectYAML/CMakeFiles/LLVMObjectYAML.dir/YAML.cpp.o.d -o lib/ObjectYAML/CMakeFiles/LLVMObjectYAML.dir/YAML.cpp.o -c /home/buildslave/buildslave/clang-armv7-linux-build-cache/llvm/llvm/lib/ObjectYAML/YAML.cpp
      /home/buildslave/buildslave/clang-armv7-linux-build-cache/llvm/llvm/lib/ObjectYAML/YAML.cpp:42:41: error: no matching function for call to 'min'
          OS.write((const char *)Data.data(), std::min(N, Data.size()));
                                              ^~~~~~~~
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/algorithmfwd.h:370:5: note: candidate template ignored: deduced conflicting types for parameter '_Tp' ('unsigned long long' vs. 'unsigned int')
          min(const _Tp&, const _Tp&);
          ^
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/stl_algo.h:3451:5: note: candidate template ignored: could not match 'initializer_list<type-parameter-0-0>' against 'unsigned long long'
          min(initializer_list<_Tp> __l, _Compare __comp)
          ^
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/algorithmfwd.h:375:5: note: candidate function template not viable: requires 3 arguments, but 2 were provided
          min(const _Tp&, const _Tp&, _Compare);
          ^
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/stl_algo.h:3445:5: note: candidate function template not viable: requires single argument '__l', but 2 arguments were provided
          min(initializer_list<_Tp> __l)
          ^
      /home/buildslave/buildslave/clang-armv7-linux-build-cache/llvm/llvm/lib/ObjectYAML/YAML.cpp:46:28: error: no matching function for call to 'min'
        for (uint64_t I = 0, E = std::min(N, Data.size() / 2); I != E; ++I) {
                                 ^~~~~~~~
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/algorithmfwd.h:370:5: note: candidate template ignored: deduced conflicting types for parameter '_Tp' ('unsigned long long' vs. 'unsigned int')
          min(const _Tp&, const _Tp&);
          ^
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/stl_algo.h:3451:5: note: candidate template ignored: could not match 'initializer_list<type-parameter-0-0>' against 'unsigned long long'
          min(initializer_list<_Tp> __l, _Compare __comp)
          ^
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/algorithmfwd.h:375:5: note: candidate function template not viable: requires 3 arguments, but 2 were provided
          min(const _Tp&, const _Tp&, _Compare);
          ^
      /usr/bin/../lib/gcc/arm-linux-gnueabihf/5.4.0/../../../../include/c++/5.4.0/bits/stl_algo.h:3445:5: note: candidate function template not viable: requires single argument '__l', but 2 arguments were provided
          min(initializer_list<_Tp> __l)
      
      Fix: specify the type for std::min call.
      a26d7b62
    • Sander de Smalen's avatar
      [AArch64][SVE] Spilling/filling of SVE callee-saves. · 84a0c8e3
      Sander de Smalen authored
      Implement the spills/fills of callee-saved SVE registers using STR and LDR
      instructions.
      
      Also adds the `aarch64_sve_vector_pcs` attribute to specify the
      callee-saved registers to be used for functions that return SVE vectors or
      take SVE vectors as arguments. The callee-saved registers are vector
      registers z8-z23 and predicate registers p4-p15.
      
      The overal frame-layout with SVE will be as follows:
      
         +-------------+
         | stack args  |
         +-------------+
         | Callee Saves|
         |   X29, X30  |
         |-------------| <- FP
         | SVE Callee  | < //////////////
         | saved regs  | < //////////////
         |    z23      | < //////////////
         |     :       | < // SCALABLE //
         |    z8       | < //////////////
         |    p15      | < /// STACK ////
         |     :       | < //////////////
         |    p4       | < //// AREA ////
         +-------------+ < //////////////
         |     :       | < //////////////
         |  SVE locals | < //////////////
         |     :       | < //////////////
         +-------------+
         |/////////////| alignment gap.
         |     :       |
         | Stack objs  |
         |     :       |
         +-------------+ <- SP after call and frame-setup
      
      Reviewers: cameron.mcinally, efriedma, greened, thegameg, ostannard, rengolin
      
      Reviewed By: ostannard
      
      Differential Revision: https://reviews.llvm.org/D68996
      84a0c8e3
    • Georgii Rymar's avatar
      [yaml2obj] - Add a way to describe the custom data that is not part of an output section. · 06456daa
      Georgii Rymar authored
      Currently there is no way to describe the data that is not a part of an output section.
      It can be a data used to align sections or to fill the gaps with something,
      or another kind of custom data. In this patch I suggest a way to describe it. It looks like that:
      
      ```
      Sections:
        - Type:    CustomFiller
          Pattern: "CCDD"
          Size:    4
        - Name:    .bar
          Type:    SHT_PROGBITS
          Content: "FF"
      ```
      
      I.e. I've added a kind of synthetic section with a synthetic type "CustomFiller".
      In the code it is called a "SyntheticFiller", which is "a synthetic section which
      might be used to write the custom data around regular output sections. It does
      not present in the sections header table, but it might affect the output file size and
      program headers produced. Think about it as about piece of data."
      
      `SyntheticFiller` currently has a `Pattern` field and a `Size` field + an optional `Name`.
      When written, `Size` of bytes in the output will be filled with a `Pattern`.
      It is possible to reference a named filler it by name from the program headers description,
      just like any other normal section.
      
      Differential revision: https://reviews.llvm.org/D69709
      06456daa
    • Ilya Biryukov's avatar
      [clangd] Fixes colon escaping on Windows · b4f46a9b
      Ilya Biryukov authored
      vscode always escapes the colon on the file uri, which causes the semantic highlighting fails on windows.
      
      fixes: https://github.com/clangd/clangd/issues/176
      b4f46a9b
Loading