aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp
diff options
context:
space:
mode:
authorLuke Lau <luke@igalia.com>2024-06-23 20:20:59 +0800
committerGitHub <noreply@github.com>2024-06-23 20:20:59 +0800
commiteb76bc38ffc286e62fdb8f8d897b5de04b2575be (patch)
tree55c6f0374c0f0678c0f4bdacfba68719f67b97b2 /llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp
parentf372bb45e39b7eae94930fc419724e12596a8361 (diff)
downloadllvm-eb76bc38ffc286e62fdb8f8d897b5de04b2575be.zip
llvm-eb76bc38ffc286e62fdb8f8d897b5de04b2575be.tar.gz
llvm-eb76bc38ffc286e62fdb8f8d897b5de04b2575be.tar.bz2
[RISCV] Relax RISCVInsertVSETVLI output VL peeking to cover registers (#96200)
If the AVL in a VSETVLIInfo is the output VL of a vsetvli with the same VLMAX, we treat it as the AVL of said vsetvli. This allows us to remove a true dependency as well as treating VSETVLIInfos as equal in more places and avoid toggles. We do this in two places, needVSETVLI and computeInfoForInstr. However we don't do this in computeInfoForInstr's vsetvli equivalent, getInfoForVSETVLI. We also have a restriction only in computeInfoForInstr that the AVL can't be a register as we want to avoid extending live ranges. This patch does two interlinked things: 1) It adds this AVL "peeking" to getInfoForVSETVLI 2) It relaxes the constraint that the AVL can't be a register in computeInfoForInstr, since it removes a use of the output VL which can actually reduce register pressure. E.g. see the diff in @vector_init_vsetvli_N and @test6 Now that getInfoForVSETVLI and computeInfoForInstr are consistent, we can remove the check in needVSETVLI. We also need to update how we update LiveIntervals in insertVSETVLI, as we can now end up needing to extend the LiveRange of the AVL across blocks.
Diffstat (limited to 'llvm/lib/CodeGen/AssignmentTrackingAnalysis.cpp')
0 files changed, 0 insertions, 0 deletions