[llvm] [MachineScheduler][RISCV] Release the pending queue base on condition (PR #125468)
Piyou Chen via llvm-commits
llvm-commits at lists.llvm.org
Sun Feb 9 20:59:04 PST 2025
================
@@ -954,3 +954,36 @@ bool RISCVRegisterInfo::getRegAllocationHints(
return BaseImplRetVal;
}
+
+bool RISCVRegisterInfo::needReleasePendingQueue(
+ MachineFunction &MF, ArrayRef<unsigned> MaxSetPressure) const {
+ for (unsigned Idx = 0; Idx < MaxSetPressure.size(); Idx++) {
+ // Consider only the RVV Register, as RVV spilling/reloading has higher
+ // potential costs than hazards.
+ if (!StringRef(getRegPressureSetName(Idx)).starts_with("VM") &&
+ !StringRef(getRegPressureSetName(Idx)).starts_with("VRM8NoV0"))
+ continue;
+ const unsigned RVVRegPressureThreshold = 7;
----------------
BeMg wrote:
Update: Make threshold as cl:opt
https://github.com/llvm/llvm-project/pull/125468
More information about the llvm-commits
mailing list