Changes

Summary

  1. Revert "[LSR] add testcase for wrongly phi node elimination - NFC" (details)
  2. [X86][SSE] Handle basic inversion of PTEST/TESTP operands (PR38522) (details)
  3. [Transforms][SROA] Promote allocas with mem2reg for scalable types (details)
  4. [clangd] Run semaCodeComplete only with a preamble (details)
  5. [LSR] re-add testcase for wrongly phi node elimination - NFC (details)
  6. [GVNSink] Simplify code. NFC. (details)
  7. [lldb][NFC] Modernize TestExprChar (details)
  8. Silent failing TestWatchpointCount.py aarch64/linux (details)
  9. [Target][ARM] Change VPTMaskValues to the correct encoding (details)
  10. [Target][ARM] Improvements to the VPT Block Insertion Pass (details)
  11. [clangd-vscode] NFC; Improve wording in documentation and update VSCode tasks (details)
  12. [Alignment][NFC] Convert MIR Yaml to MaybeAlign (details)
  13. Revert "[LSR] re-add testcase for wrongly phi node elimination - NFC" (details)
  14. [ARM] Extra vmull loop tests. NFC (details)
  15. Fix "control reaches end of non-void function" warning. NFCI. (details)
  16. [X86][SSE] matchShuffleWithPACK - generalize zero/signbits matching for any packed src type (details)
  17. [NFC] run clang format on the file llvm/include/llvm/MC/MCDirectives.h (details)
  18. [Alignment][NFC] Convert SelectionDAG::InferPtrAlignment to MaybeAlign (details)
Commit 8b8cd150a4a176cd971c604f92de76acdae4a301 by shchenz
Revert "[LSR] add testcase for wrongly phi node elimination - NFC"

This reverts commit dbf5e4f6c7f76d8086b01efed5c37dced3eed4b6.
The testcase has different behaviour on PowerPC and X86.
The file was removedllvm/test/Transforms/LoopStrengthReduce/phi-unknownscev.ll
The file was modifiedllvm/lib/Analysis/ScalarEvolutionExpander.cpp
Commit 918ccb64b02281355a6226fe8af07dc40e8ff9e3 by llvm-dev
[X86][SSE] Handle basic inversion of PTEST/TESTP operands (PR38522)

PTEST/TESTP sets EFLAGS as:
TESTZ: ZF = (Op0 & Op1) == 0
TESTC: CF = (~Op0 & Op1) == 0
TESTNZC: ZF == 0 && CF == 0

If we are inverting the 0'th operand of a PTEST/TESTP instruction we can adjust the comparisons to correct handle the inversion implicitly.

Additionally, for "TESTZ" (ZF) cases, the allones case, PTEST(X,-1) can be simplified to PTEST(X,X).

We can expand this for the TESTZ(X,~Y) pattern and also handle KTEST/KORTEST in the future.

Differential Revision: https://reviews.llvm.org/D76984
The file was modifiedllvm/test/CodeGen/X86/combine-testps.ll
The file was modifiedllvm/test/CodeGen/X86/combine-ptest.ll
The file was modifiedllvm/test/CodeGen/X86/combine-testpd.ll
The file was modifiedllvm/lib/Target/X86/X86ISelLowering.cpp
Commit 84aa6cf1a9fe7c2d1c35b27ba6fbf1ee36a09a71 by cullen.rhodes
[Transforms][SROA] Promote allocas with mem2reg for scalable types

Summary:
Aggregate types containing scalable vectors aren't supported and as far
as I can tell this pass is mostly concerned with optimisations on
aggregate types, so the majority of this pass isn't very useful for
scalable vectors.

This patch modifies SROA such that mem2reg is run on allocas with
scalable types that are promotable, but nothing else such as slicing is
done.

The use of TypeSize in this pass has also been updated to be explicitly
fixed size. When invoking the following methods in DataLayout:

    * getTypeSizeInBits
    * getTypeStoreSize
    * getTypeStoreSizeInBits
    * getTypeAllocSize

we now called getFixedSize on the resultant TypeSize. This is quite an
extensive change with around 50 calls to these functions, and also the
first change of this kind (being explicit about fixed vs scalable
size) as far as I'm aware, so feedback welcome.

A test is included containing IR with scalable vectors that this pass is
able to optimise.

Reviewed By: efriedma

Differential Revision: https://reviews.llvm.org/D76720
The file was addedllvm/test/Transforms/SROA/scalable-vectors.ll
The file was modifiedllvm/lib/Transforms/Scalar/SROA.cpp
Commit 43aa04eb7a617ee75dfcbbe2d395b8208e66c0e0 by kadircet
[clangd] Run semaCodeComplete only with a preamble

Summary:
It is used by code completion and signature help. Code completion
already uses a special no-compile mode for missing preambles, so this change is
a no-op for that.

As for signature help, it already blocks for a preamble and missing it implies
clang has failed to parse the preamble and retrying it in signature help likely
will fail again. And even if it doesn't, request latency will be too high to be
useful as parsing preambles is expensive.

Reviewers: sammccall

Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, usaxena95, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D77204
The file was modifiedclang-tools-extra/clangd/unittests/ClangdTests.cpp
The file was modifiedclang-tools-extra/clangd/ClangdServer.cpp
The file was modifiedclang-tools-extra/clangd/CodeComplete.h
The file was modifiedclang-tools-extra/clangd/unittests/CodeCompleteTests.cpp
The file was modifiedclang-tools-extra/clangd/CodeComplete.cpp
Commit f25a1b4f58d66805257a05f13e8581551574ce22 by shchenz
[LSR] re-add testcase for wrongly phi node elimination - NFC

Retest the case on X86/SystemZ/AArch64/PowerPC
The file was modifiedllvm/lib/Analysis/ScalarEvolutionExpander.cpp
The file was addedllvm/test/Transforms/LoopStrengthReduce/phi-unknownscev.ll
Commit 66b9f5f7f0d26d789f74ddc8a99d0e446d17a22c by benny.kra
[GVNSink] Simplify code. NFC.
The file was modifiedllvm/lib/Transforms/Scalar/GVNSink.cpp
Commit 9beba4245a77ae75db874146036b77fb76398e4c by Raphael Isemann
[lldb][NFC] Modernize TestExprChar
The file was modifiedlldb/test/API/commands/expression/char/TestExprsChar.py
Commit c9d15880542ef483470ee33dbd055b68396d4537 by omair.javaid
Silent failing TestWatchpointCount.py aarch64/linux

Skip TestWatchpointCount.py for aarch64-linux to fix lldb aarch64 linux buildbot.

http://lab.llvm.org:8011/builders/lldb-aarch64-ubuntu/
The file was modifiedlldb/test/API/commands/watchpoints/watchpoint_count/TestWatchpointCount.py
Commit dad848280d3b740524803595d463510e1090ab59 by pierre.vanhoutryve
[Target][ARM] Change VPTMaskValues to the correct encoding

VPTMaskValue was using the "instruction" encoding to represent the masks
(= the same encoding as the one used by the instructions in an object file),
but it is only used to build MCOperands, so it should use the MCOperand
encoding of the masks, which is slightly different.

Differential Revision: https://reviews.llvm.org/D76139
The file was modifiedllvm/lib/Target/ARM/ARMLowOverheadLoops.cpp
The file was modifiedllvm/lib/Target/ARM/Utils/ARMBaseInfo.h
The file was modifiedllvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
The file was modifiedllvm/lib/Target/ARM/ARMBaseInstrInfo.h
Commit 2effe8f5e72ac94286445c0fdfd2cad6999f4cb4 by pierre.vanhoutryve
[Target][ARM] Improvements to the VPT Block Insertion Pass

This allows the MVE VPT Block insertion pass to remove VPNOTs in
order to create more complex VPT blocks such as TE, TEET, TETE, etc.

Differential Revision: https://reviews.llvm.org/D75993
The file was modifiedllvm/lib/Target/ARM/MVEVPTBlockPass.cpp
The file was modifiedllvm/lib/Target/ARM/Thumb2InstrInfo.h
The file was modifiedllvm/test/CodeGen/Thumb2/mve-pred-not.ll
The file was modifiedllvm/test/CodeGen/Thumb2/mve-vpt-3-blocks-kill-vpr.mir
The file was addedllvm/test/CodeGen/Thumb2/mve-vpt-block-elses.mir
The file was modifiedllvm/test/CodeGen/Thumb2/mve-pred-threshold.ll
The file was modifiedllvm/test/CodeGen/Thumb2/mve-vpt-nots.mir
Commit db3d64eebbe0aad87631c6fada01b06753377a44 by kbobyrev
[clangd-vscode] NFC; Improve wording in documentation and update VSCode tasks

Summary:
VSCode tasks are updated to the latest supported versions: deprecated
values are removed and replaced by their new counterparts.

Reviewers: hokein

Reviewed By: hokein

Subscribers: ilya-biryukov, MaskRay, jkorous, arphaman, kadircet, usaxena95, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D76595
The file was modifiedclang-tools-extra/clangd/clients/clangd-vscode/.vscode/launch.json
The file was modifiedclang-tools-extra/clangd/clients/clangd-vscode/DEVELOPING.md
The file was modifiedclang-tools-extra/clangd/clients/clangd-vscode/tsconfig.json
The file was modifiedclang-tools-extra/clangd/clients/clangd-vscode/.vscode/tasks.json
The file was modifiedclang-tools-extra/clangd/clients/clangd-vscode/src/extension.ts
Commit bf573bea19eabb41ed35c31b0d187c7068172bfa by gchatelet
[Alignment][NFC] Convert MIR Yaml to MaybeAlign

Summary:
Although it may look like non NFC it is. especially the MIRParser may set `0` to the MachineFrameInfo and MachineFunction, but they all deal with `Align` internally and assume that `0` means `1`.
https://github.com/llvm/llvm-project/blob/93fc0ba145c2f9619d3174c95cacda5d4a0a2815/llvm/include/llvm/CodeGen/MachineFrameInfo.h#L483

This is patch is part of a series to introduce an Alignment type.
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2019-July/133851.html
See this patch for the introduction of the type: https://reviews.llvm.org/D64790

Reviewers: courbet

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77203
The file was modifiedllvm/lib/CodeGen/MIRPrinter.cpp
The file was modifiedllvm/include/llvm/CodeGen/MIRYamlMapping.h
The file was modifiedllvm/lib/CodeGen/MIRParser/MIRParser.cpp
Commit e344f8b9db4c173a5a268c52820e7ccf078ebe3b by shchenz
Revert "[LSR] re-add testcase for wrongly phi node elimination - NFC"

This reverts commit f25a1b4f58d66805257a05f13e8581551574ce22.
ARM and hexagon fail at the new added case.
The file was removedllvm/test/Transforms/LoopStrengthReduce/phi-unknownscev.ll
The file was modifiedllvm/lib/Analysis/ScalarEvolutionExpander.cpp
Commit a0c537834ae86a586aa0a17bc2e48d13c4515a3d by david.green
[ARM] Extra vmull loop tests. NFC
The file was addedllvm/test/CodeGen/Thumb2/mve-vmull-loop.ll
Commit 43eca880c6eda10fd191c4e9e04bf04830c9c6f2 by llvm-dev
Fix "control reaches end of non-void function" warning. NFCI.
The file was modifiedclang-tools-extra/clangd/SemanticHighlighting.cpp
Commit 481413d3940402fdbef9f19963430e75409dc148 by llvm-dev
[X86][SSE] matchShuffleWithPACK - generalize zero/signbits matching for any packed src type

First step toward making use of canLowerByDroppingEvenElements to match chains of PACKSS/PACKUS for compaction shuffles.

At the moment we still only match a single stage but the MatchPACK is now more general.
The file was modifiedllvm/lib/Target/X86/X86ISelLowering.cpp
Commit 65e0079f21aeb5126bfaee18d3feedbb911c1da8 by diggerlin
[NFC] run clang format on the file llvm/include/llvm/MC/MCDirectives.h

SUMMARY:

run clang format on the file llvm/include/llvm/MC/MCDirectives.h

Reviewers: Jason liu
Subscribers: rupprecht, seiyai,hiraditya

Differential Revision: https://reviews.llvm.org/D77170
The file was modifiedllvm/include/llvm/MC/MCDirectives.h
Commit 3a78f44daf37bd16ae69eea06a1b45428e33f16f by gchatelet
[Alignment][NFC] Convert SelectionDAG::InferPtrAlignment to MaybeAlign

Summary:
This is patch is part of a series to introduce an Alignment type.
See this thread for context: http://lists.llvm.org/pipermail/llvm-dev/2019-July/133851.html
See this patch for the introduction of the type: https://reviews.llvm.org/D64790

Reviewers: courbet

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D77212
The file was modifiedllvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
The file was modifiedllvm/include/llvm/CodeGen/SelectionDAG.h
The file was modifiedllvm/lib/Target/ARM/ARMISelLowering.cpp
The file was modifiedllvm/lib/Target/X86/X86ISelLowering.cpp
The file was modifiedllvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
The file was modifiedllvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
The file was modifiedllvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp