diff options
author | David Green <david.green@arm.com> | 2024-04-12 10:57:01 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-12 10:57:01 +0100 |
commit | b24af43fdfa1b1242b7cb77540462212227c57c4 (patch) | |
tree | aa3f8dcf490434ea4e8e3ae4cfe60bd8fffac913 /llvm/lib/CodeGen/MachinePipeliner.cpp | |
parent | f5b2d24b59f168eaeed08b5f45bf0c8dfcc1c292 (diff) | |
download | llvm-b24af43fdfa1b1242b7cb77540462212227c57c4.zip llvm-b24af43fdfa1b1242b7cb77540462212227c57c4.tar.gz llvm-b24af43fdfa1b1242b7cb77540462212227c57c4.tar.bz2 |
[AArch64] Improve scheduling latency into Bundles (#86310)
By default the scheduling info of instructions into a BUNDLE are given a
latency of 0 as they operate on the implicit register of the bundle.
This modifies that for AArch64 so that the latency is adjusted to use
the latency from the instruction in the bundle instead. This essentially
assumes that the bundled instructions are executed in a single cycle,
which for AArch64 is probably OK considering they are mostly used for
MOVPFX bundles, where this can help create slightly better scheduling
especially for in-order cores.
Diffstat (limited to 'llvm/lib/CodeGen/MachinePipeliner.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachinePipeliner.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/MachinePipeliner.cpp b/llvm/lib/CodeGen/MachinePipeliner.cpp index 9305040..4f7d9d0 100644 --- a/llvm/lib/CodeGen/MachinePipeliner.cpp +++ b/llvm/lib/CodeGen/MachinePipeliner.cpp @@ -919,7 +919,8 @@ void SwingSchedulerDAG::updatePhiDependences() { if (!MI->isPHI()) { SDep Dep(SU, SDep::Data, Reg); Dep.setLatency(0); - ST.adjustSchedDependency(SU, 0, &I, MO.getOperandNo(), Dep); + ST.adjustSchedDependency(SU, 0, &I, MO.getOperandNo(), Dep, + &SchedModel); I.addPred(Dep); } else { HasPhiUse = Reg; |