[all-commits] [llvm/llvm-project] 79d380: [AArch64][SVE2] Add codegen patterns for SVE2 FAMI...
SpencerAbson via All-commits
all-commits at lists.llvm.org
Tue Sep 17 01:12:49 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 79d380f2ca288b3d2f9aafb1149f4239e8a8308e
https://github.com/llvm/llvm-project/commit/79d380f2ca288b3d2f9aafb1149f4239e8a8308e
Author: SpencerAbson <Spencer.Abson at arm.com>
Date: 2024-09-17 (Tue, 17 Sep 2024)
Changed paths:
M llvm/lib/Target/AArch64/AArch64SVEInstrInfo.td
A llvm/test/CodeGen/AArch64/aarch64-sve2-faminmax.ll
Log Message:
-----------
[AArch64][SVE2] Add codegen patterns for SVE2 FAMINMAX (#107284)
Tablegen patterns were previously added to lower the following sequences
from generic IR to NEON FAMIN/FAMAX instructions
- `fminimum((abs(a), abs(b)) -> famin(a, b)`
- `fmaximum((abs(a)), abs(b)) -> famax(a, b)`
- https://github.com/llvm/llvm-project/pull/103027
- `fminnum[nnan](abs(a), abs(b)) -> famin(a, b)`
- `fmaxnum[nnan](abs(a), abs(b)) -> famax(a, b)`
- https://github.com/llvm/llvm-project/pull/104766
The same idea has been applied for the scalable vector variants of
[FAMIN](https://developer.arm.com/documentation/ddi0602/2024-06/SVE-Instructions/FAMIN--Floating-point-absolute-minimum--predicated--)/[FAMAX](https://developer.arm.com/documentation/ddi0602/2024-06/SVE-Instructions/FAMAX--Floating-point-absolute-maximum--predicated--).
('nnan' documenatation:
https://llvm.org/docs/LangRef.html#fast-math-flags).
- Changes to LLVM
- lib/target/AArch64/AArch64SVEInstrInfo.td
- Add 'AArch64fminnm_p_nnan' and 'AArch64fmaxnm_p_nnan' patfrags
(patterns predicated on the 'nnan' flag).
- Add 'AArch64famax_p' and 'AArch64famin_p'
- test/CodeGen/AArch64/aarch64-sve2-faminmax.ll
- Add tests to verify the new patterns, including both positive and
negative tests for 'nnan' predicated behavior.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list