[PATCH] D148558: [CodeGen] Improve handling -Ofast generated code by ComplexDeinterleaving pass
Igor Kirillov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 17 11:58:05 PDT 2023
igor.kirillov created this revision.
Herald added subscribers: hiraditya, kristof.beyls.
Herald added a project: All.
igor.kirillov requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead.
Herald added a project: LLVM.
Code generated with -Ofast and -O3 -ffp-contract=fast (add
-ffinite-math-only to enable vectorization) can differ significantly.
Code compiled with -O3 can be deinterleaved using patterns as the
instruction order is preserved. However, with the -Ofast flag, there
can be multiple changes in the computation sequence, and even the real
and imaginary parts may not be calculated in parallel.
For more details, refer to
llvm/test/CodeGen/AArch64/complex-deinterleaving-*-fast.ll and
llvm/test/CodeGen/AArch64/complex-deinterleaving-*-fast.ll tests.
This patch implements a more general approach and enables handling most
-Ofast cases.
Depends on D148550 <https://reviews.llvm.org/D148550>
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D148558
Files:
llvm/include/llvm/CodeGen/TargetLowering.h
llvm/lib/CodeGen/ComplexDeinterleavingPass.cpp
llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
llvm/lib/Target/AArch64/AArch64ISelLowering.h
llvm/lib/Target/ARM/ARMISelLowering.cpp
llvm/lib/Target/ARM/ARMISelLowering.h
llvm/test/CodeGen/AArch64/complex-deinterleaving-add-mull-fixed-fast.ll
llvm/test/CodeGen/AArch64/complex-deinterleaving-add-mull-scalable-fast.ll
llvm/test/CodeGen/AArch64/complex-deinterleaving-mixed-cases.ll
llvm/test/CodeGen/AArch64/complex-deinterleaving-uniform-cases.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D148558.514349.patch
Type: text/x-patch
Size: 42778 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230417/3b995dc4/attachment.bin>
More information about the llvm-commits
mailing list