llvm-project
d5607694 - [AMDGPU][SDAG] DAGCombine PTRADD -> disjoint OR (#146075)

Commit
88 days ago
[AMDGPU][SDAG] DAGCombine PTRADD -> disjoint OR (#146075) If we can't fold a PTRADD's offset into its users, lowering them to disjoint ORs is preferable: Often, a 32-bit OR instruction suffices where we'd otherwise use a pair of 32-bit additions with carry. This needs to be a DAGCombine (and not a selection rule) because its main purpose is to enable subsequent DAGCombines for bitwise operations. We don't want to just turn PTRADDs into disjoint ORs whenever that's sound because this transform loses the information that the operation implements pointer arithmetic, which AMDGPU for instance needs when folding constant offsets. For SWDEV-516125.
Author
Parents
Loading