llvm-project/llvm/test
Jessica Clarke 6c80361b84 [SelectionDAG][Mips][PowerPC][RISCV][WebAssembly] Teach computeKnownBits/ComputeNumSignBits about atomics
Unlike normal loads these don't have an extension field, but we know
from TargetLowering whether these are sign-extending or zero-extending,
and so can optimise away unnecessary extensions.

This was noticed on RISC-V, where sign extensions in the calling
convention would result in unnecessary explicit extension instructions,
but this also fixes some Mips inefficiencies. PowerPC sees churn in the
tests as all the zero extensions are only for promoting 32-bit to
64-bit, but these zero extensions are still not optimised away as they
should be, likely due to i32 being a legal type.

This also simplifies the WebAssembly code somewhat, which currently
works around the lack of target-independent combines with some ugly
patterns that break once they're optimised away.

Re-landed with correct handling in ComputeNumSignBits for Tmp == VTBits,
where zero-extending atomics were incorrectly returning 0 rather than
the (slightly confusing) required return value of 1.

Reviewed By: RKSimon, atanasyan

Differential Revision: https://reviews.llvm.org/D101342
2021-05-06 04:01:20 +01:00
..
Analysis [NFC][X86][CostModel] Add tests for byteswap intrinsic 2021-05-05 20:11:46 +03:00
Assembler [LLParser] Print mismatched types in error message 2021-04-21 13:10:37 -07:00
Bindings [ARM][AArch64] Require appropriate features for crypto algorithms 2021-04-28 16:26:18 +01:00
Bitcode Preserve metadata on masked intrinsics in auto-upgrade 2021-05-05 15:51:46 -05:00
BugPoint [AIX] Add %pluginext and update tests to use proper pluginext 2021-04-27 20:34:54 -04:00
CodeGen [SelectionDAG][Mips][PowerPC][RISCV][WebAssembly] Teach computeKnownBits/ComputeNumSignBits about atomics 2021-05-06 04:01:20 +01:00
DebugInfo [MCAsmInfo] Support UsesCFIForDebug for targets with no exception handling 2021-05-06 04:53:45 +05:30
Demangle [demangler] Initial support for the new Rust mangling scheme 2021-05-03 16:44:30 -07:00
Examples
ExecutionEngine [JITLink] Add testcase that was accidentally left out of 19e402d2b3. 2021-04-17 11:55:55 -07:00
Feature
FileCheck Fix PR46880: Fail CHECK-NOT with undefined variable 2021-04-20 14:42:46 +01:00
Instrumentation [ASAN][AMDGPU] Add support for accesses to global and constant addrspaces 2021-05-03 09:01:15 +05:30
Integer
JitListener
LTO
Linker Linker: Avoid scheduling the link of a global value twice due to an alias 2021-04-28 13:22:10 -07:00
MC [M68k][test][NFC] Scrubing some tests 2021-05-05 17:48:28 -07:00
MachineVerifier GlobalISel: Relax verification of physical register copy types 2021-04-28 08:45:41 -04:00
Object [yaml2obj/obj2yaml/llvm-readobj] Support printing and parsing AVR-specific e_flags 2021-04-15 15:54:28 +02:00
ObjectYAML
Other Make dependency between certain analysis passes transitive (reapply) 2021-05-05 15:17:55 +02:00
SafepointIRVerifier
Support [SystemZ][z/OS] Add the functions needed for handling EBCDIC I/O 2021-05-03 08:52:38 -04:00
SymbolRewriter
TableGen [TableGen] Use sign rotated VBR for OPC_EmitInteger. 2021-05-02 12:40:44 -07:00
ThinLTO/X86 Preserve the lexical order for global variables during llvm-link merge 2021-04-26 10:11:34 -07:00
Transforms [InstCombine] Fully disable select to and/or i1 folding 2021-05-06 09:29:52 +09:00
Unit
Verifier [NFC][Verifier] Split token1.ll into two, assert/non-assert versions 2021-04-28 13:58:38 +03:00
YAMLParser
tools [llvm-objcopy][ELF] --only-keep-debug: set offset/size of segments with no sections to zero 2021-05-05 10:26:57 -07:00
.clang-format
CMakeLists.txt [llvm-rc] Add a GNU windres-like frontend to llvm-rc 2021-04-26 22:04:29 +03:00
TestRunner.sh
lit.cfg.py [AIX] Add %pluginext and update tests to use proper pluginext 2021-04-27 20:34:54 -04:00
lit.site.cfg.py.in [AIX] Add %pluginext and update tests to use proper pluginext 2021-04-27 20:34:54 -04:00