llvm-project/llvm/lib
Alex Bradbury ce38128194 [RISCV] Avoid redundant branch-to-branch when expanding cmpxchg
If the success value of a cmpxchg is used in a branch, the expanded
cmpxchg sequence ends up with a redundant branch-to-branch (as the
backend atomics expansion happens as late as possible, passes to
optimise such cases have already run). This patch identifies this case
and avoid it when expanding the cmpxchg.

Note that a similar optimisation is possible for a BEQ on the cmpxchg
success value. As it's hard to imagine a case where real-world code may
do that, this patch doens't handle that case.

Differential Revision: https://reviews.llvm.org/D130192
2022-08-17 13:49:15 +01:00
..
Analysis [TTI] Remove getInstructionThroughput cost helper. 2022-08-17 11:41:47 +01:00
AsmParser Remove 'no_sanitize_memtag'. Add 'sanitize_memtag'. 2022-07-13 08:54:41 -07:00
BinaryFormat [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
Bitcode [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
Bitstream
CodeGen [TypePromotion] Don't promote PHI + ZExt if wider than RegisterBitWidth 2022-08-17 09:54:15 +01:00
DWARFLinker [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
DWP llvm-dwp: Include dwo name even when the input is a dwo 2022-07-28 20:24:05 +00:00
DebugInfo [llvm] Qualify auto in range-based for loops (NFC) 2022-08-13 12:55:42 -07:00
Debuginfod [LLVM][Debuginfod] Add missing thread include 2022-08-16 13:56:23 +00:00
Demangle Make demangler independent of LLVM again 2022-08-15 11:44:28 +02:00
ExecutionEngine [ExecutionEngine] Fix a warning 2022-08-15 20:33:10 -07:00
Extensions
FileCheck [llvm][FileCheck] Fix unit tests failures with EXPENSIVE_CHECKS 2022-07-25 08:19:28 +00:00
Frontend [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
FuzzMutate
Fuzzer
IR Use llvm::none_of (NFC) 2022-08-14 16:25:39 -07:00
IRReader
InterfaceStub [llvm] Use value instead of getValue (NFC) 2022-07-13 23:11:56 -07:00
LTO [libLTO] Set data-sections by default in libLTO. 2022-07-27 09:39:39 -05:00
LineEditor Use drop_begin (NFC) 2022-07-31 15:17:09 -07:00
Linker [llvm] Qualify auto in range-based for loops (NFC) 2022-08-13 12:55:42 -07:00
MC [Sparc] Don't use SunStyleELFSectionSwitchSyntax 2022-08-17 12:59:29 +02:00
MCA [MCA] Allow mca::Instruction-s to be recycled and reused 2022-06-24 15:39:51 -07:00
ObjCopy Revert D130458 "[llvm-objcopy] Support --{,de}compress-debug-sections for zstd" 2022-07-29 15:46:51 -07:00
Object [llvm] Qualify auto in range-based for loops (NFC) 2022-08-13 12:55:42 -07:00
ObjectYAML [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
Option [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
Passes [llvm] Qualify auto in range-based for loops (NFC) 2022-08-13 12:55:42 -07:00
ProfileData [llvm] Qualify auto in range-based for loops (NFC) 2022-08-13 12:55:42 -07:00
Remarks Don't use Optional::hasValue (NFC) 2022-06-20 20:05:16 -07:00
Support [ARM] Simplify the creation of escaped build attribute values 2022-08-16 11:49:33 +01:00
TableGen [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
Target [RISCV] Avoid redundant branch-to-branch when expanding cmpxchg 2022-08-17 13:49:15 +01:00
Testing [llvm] Use value_or instead of getValueOr (NFC) 2022-06-18 23:07:11 -07:00
TextAPI [llvm] LLVM_FALLTHROUGH => [[fallthrough]]. NFC 2022-08-08 11:24:15 -07:00
ToolDrivers [llvm-lib] Ignore /VERBOSE flag 2022-07-21 10:06:13 -07:00
Transforms [SLP] Update TODO comment about shuffle mask decoding 2022-08-17 11:41:46 +01:00
WindowsDriver [llvm] Don't use Optional::hasValue (NFC) 2022-06-25 21:42:52 -07:00
WindowsManifest
XRay
CMakeLists.txt