[all-commits] [llvm/llvm-project] b0bea8: [X86] Prefer vmovmsk instead of vtest for alderlake.
Luo, Yuanke via All-commits
all-commits at lists.llvm.org
Thu Jun 8 02:39:11 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: b0bea80ab479e9bb016fcdb62d7d0eceec2b28e3
https://github.com/llvm/llvm-project/commit/b0bea80ab479e9bb016fcdb62d7d0eceec2b28e3
Author: Luo, Yuanke <yuanke.luo at intel.com>
Date: 2023-06-08 (Thu, 08 Jun 2023)
Changed paths:
M llvm/lib/Target/X86/X86.td
M llvm/lib/Target/X86/X86ISelLowering.cpp
M llvm/test/CodeGen/X86/combine-movmsk-avx.ll
M llvm/test/CodeGen/X86/combine-movmsk.ll
Log Message:
-----------
[X86] Prefer vmovmsk instead of vtest for alderlake.
On alderlake E-core, the latency of VMOVMSKPS is 5 for YMM/XMM. The
latency of VPTESTPS is 7 for YMM and is 5 for XMM. Since alderlake use
the P-core schedule model, we can't determine which one better based on
the latency information of schedule model. Alternatively we add an
tuning feature for alderlake and select VMOVMSKPS with the indication
for the tuning feature. In the case of "vmovmskps + test + jcc", the
test and jcc can be fused, while vtest and jcc can't.
Differential Revision: https://reviews.llvm.org/D152227
More information about the All-commits
mailing list