SuccessChanges

Summary

  1. [NFC][mlir] Adding more operators to EDSC TemplatedIndexedValue (details)
  2. test/CodeGen/AMDGPU: Add a test case that shows a miscompilation (details)
  3. [NFC] Corrected a minor typo in a comment (details)
  4. Detect and disable openmp tests that require multiple hardware processor to run (details)
  5. [ConstantFold] fold fsub -0.0, undef to undef rather than NaN (details)
  6. [DependenceAnalysis] Memory dependence analysis internal caching mechanism is broken in presence of TBAA (PR42733). (details)
  7. [Hexagon] Introduce noop intrinsic to cast between vector predicate types (details)
Commit d0b09f89e0ed01730173e8b609f25da33e826fa6 by zinenko
[NFC][mlir] Adding more operators to EDSC TemplatedIndexedValue

This change adds some missing arithmetic and logical operators to
`TemplatedIndexedValue` for EDSC usage.

Differential Revision: https://reviews.llvm.org/D74686
The file was modifiedmlir/include/mlir/EDSC/Builders.h
The file was modifiedmlir/include/mlir/Dialect/AffineOps/EDSC/Builders.h
Commit 32e4e7196630dfe23072990ef4071df4aaa41bb6 by nicolai.haehnle
test/CodeGen/AMDGPU: Add a test case that shows a miscompilation

Related to https://reviews.llvm.org/D74908

Change-Id: I6ebf3b5c7a32493016994f30d6796c41e95aecde
The file was modifiedllvm/test/CodeGen/AMDGPU/skip-if-dead.ll
Commit a24d46318f669b3882f6c87f58633098e2a157bf by sguelton
[NFC] Corrected a minor typo in a comment
The file was modifiedllvm/lib/Target/ARM/README-Thumb.txt
The file was modifiedllvm/lib/Support/YAMLTraits.cpp
Commit 99b03c1c18de3e4228e31ef04d38f2d530d335be by sguelton
Detect and disable openmp tests that require multiple hardware processor to run

Team tests seem to require at least two physical cores, and using the same trick
as in https://reviews.llvm.org/D55598 doesn't work (why?) .
Using lit configuration instead.

Differential Revision: https://reviews.llvm.org/D74921
The file was modifiedopenmp/runtime/test/ompt/teams/parallel_team.c
The file was modifiedopenmp/runtime/test/lit.cfg
The file was modifiedopenmp/runtime/test/ompt/teams/serial_teams.c
Commit d799190851fdd94800428ba335f864ce5fd8135b by spatel
[ConstantFold] fold fsub -0.0, undef to undef rather than NaN

A question about this behavior came up on llvm-dev:
http://lists.llvm.org/pipermail/llvm-dev/2020-February/139003.html
...and as part of backend improvements in D73978, but this is an IR
change first because we already have fairly thorough tests in place
here.

We decided not to implement a more general change that would have
folded any FP binop with nearly arbitrary constant + undef operand
to undef because that is not theoretically correct (even if it is
practically correct).

Differential Revision: https://reviews.llvm.org/D74713
The file was modifiedllvm/test/Analysis/ConstantFolding/fp-undef.ll
The file was modifiedllvm/lib/IR/ConstantFold.cpp
Commit b0761bbc7639d0901d623e1fbf53ccf6ce066b16 by evgueni.brevnov
[DependenceAnalysis] Memory dependence analysis internal caching mechanism is broken in presence of TBAA (PR42733).

Summary:
There is a flaw in memory dependence analysis caching mechanism when memory accesses with TBAA are involved. Assume we first analysed and cached results for access with TBAA. Later we request dependence for the same memory but without TBAA (or different TBAA). By design these two queries should share one entry in the internal cache which corresponds to a general access (without TBAA).  Thus upon second request internal cached is cleared and we continue analysis for access as if there is no TBAA.

The problem is that even though internal cache is cleared the set of visited nodes is not. That means we won't traverse visited nodes again and populate internal cache with the corresponding dependence results. So we end up  with internal cache in an incomplete state. Current implementation tries to signal that situation by resetting CacheInfo->Pair at line 1104. But that doesn't actually help since later code ignores this invalidation and relies on 'Cache->empty()' property to decide on cache completeness.

Reviewers: reames, hfinkel, chandlerc, fedor.sergeev, asbirlea, fhahn, john.brawn, Prazek, sunfish

Reviewed By: john.brawn

Subscribers: DaniilSuchkov, kosarev, jfb, dantrushin, hiraditya, bmahjour, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D73032
The file was modifiedllvm/lib/Analysis/MemoryDependenceAnalysis.cpp
The file was modifiedllvm/include/llvm/Analysis/MemoryDependenceAnalysis.h
The file was addedllvm/test/Analysis/MemoryDependenceAnalysis/memdep_with_tbaa.ll
Commit c51b0bede82b9eeddce78151dfc257cf738bf367 by kparzysz
[Hexagon] Introduce noop intrinsic to cast between vector predicate types

The (overloaded) intrinsic is llvm.hexagon.V6.pred.typecast[.128B]. The
types of the operand and the return value are HVX boolean vector types.
For each cast, there needs to be a corresponding intrinsic declared,
with different suffixes appended to the name, e.g.
  ; cast <128 x i1> to <32 x i1>
  declare <32 x i1> @llvm.hexagon.V6.pred.typecast.128B.s1(<128 x i1>)
  ; cast <32 x i1> to <64 x i1>
  declare <64 x i1> @llvm.hexagon.V6.pred.typecast.128B.s2(<32 x i1>)
etc.
The file was modifiedllvm/lib/Target/Hexagon/HexagonISelLoweringHVX.cpp
The file was modifiedllvm/lib/Target/Hexagon/HexagonISelLowering.h
The file was addedllvm/test/CodeGen/Hexagon/autohvx/vector-predicate-typecast.ll
The file was modifiedllvm/lib/Target/Hexagon/HexagonISelLowering.cpp
The file was modifiedllvm/include/llvm/IR/IntrinsicsHexagon.td