Revert "[AMDGPU] add clamp immediate operand to WMMA iu8 intrinsic (#171069)" (#174303)
This reverts commit 2c376ffeca490a5732e4fd6e98e5351fcf6d692a because it
breaks assembler.
```
$ llvm-mc -triple=amdgcn -mcpu=gfx1250 -show-encoding <<< "v_wmma_i32_16x16x64_iu8 v[16:23], v[0:7], v[8:15], v[16:23] matrix_b_reuse"
v_wmma_i32_16x16x64_iu8 v[16:23], v[0:7], v[8:15], v[16:23] clamp ; encoding: [0x10,0x80,0x72,0xcc,0x00,0x11,0x42,0x1c]
```
We have a fundamental issue in the clamp support in VOP3P instructions,
which will need more changes.
[IR] Reland Optimize PHINode::removeIncomingValue() and PHINode::removeIncomingValueIf() to use the swapping strategy. (#174274)
Reland #171963, #172639 and #173444, they are reverted in
86b9f90b9574b3a7d15d28a91f6316459dcfa046 because of introducing
non-determinism in compiles.
The non-determinism has been fixed in
9b8addffa70cee5b2acc5454712d9cf78ce45710.
Revert "[AMDGPU] add clamp immediate operand to WMMA iu8 intrinsic (#171069)"
This reverts commit 2c376ffeca490a5732e4fd6e98e5351fcf6d692a because it breaks assembler.
```
$ llvm-mc -triple=amdgcn -mcpu=gfx1250 -show-encoding <<< "v_wmma_i32_16x16x64_iu8 v[16:23], v[0:7], v[8:15], v[16:23] matrix_b_reuse"
v_wmma_i32_16x16x64_iu8 v[16:23], v[0:7], v[8:15], v[16:23] clamp ; encoding: [0x10,0x80,0x72,0xcc,0x00,0x11,0x42,0x1c]
```
We have a fundamental issue in the clamp support in VOP3P instructions, which will need more changes.
[RISCV] Support i32 SSHLAT for rv32ip. (#173687)
The rv32ip ssha instruction treats the lower byte of rs2 as a signed shift
amount. If the byte is positive, it is a saturating shift left. If the
byte is negative, it is an arithmetic shift right.
Because out of bounds shift amounts are poison in LLVM semantics, we
can assume the shift amount is a positive number and use ssha to
implement sshlsat.
[flang][cuda] Fix false positive in host intrinsic with device var (#174300)
#174025 was too strict and make couple of downstream testing fail. Relax
the check to skip allowed intrinsics.
Revert "ValueTracking: Improve handling of fadd in computeKnownFPClass." (#174290)
Reverts llvm/llvm-project#174123
This caused test failures within LLVM libc. They can be reproduced by
doing a libc build against a clang with this commit included and running
`ninja -k 0 libc.test.src.math.smoke.log1p_test.__unit__
libc.test.src.math.smoke.log1p_test.__unit__.__NO_FMA_OPT`.
[X86] Avoid assertion failure with implicit immediates for AMX tile dimensions (#174128)
https://github.com/llvm/llvm-project/pull/165556 removed support for
implicit immediates in
`llvm/include/llvm/CodeGen/TileShapeInfo.h/.cpp`. Although implicit
immediates are generally not valid tile dimensions, it is undesirable to
have assertion failures in syntactically valid code; moreover, implicit
immediates (especially zero) are commonly encountered when reducing test
cases.
This patch restores the support for implicit immediates.
Fixes: https://github.com/llvm/llvm-project/issues/174127