[all-commits] [llvm/llvm-project] 5d281a: [LoopInterchange] Constrain number of load/stores...
Madhur Amilkanthwar via All-commits
all-commits at lists.llvm.org
Mon Jan 20 21:19:40 PST 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 5d281a480e5caae09962b863960d7d057e908a3c
https://github.com/llvm/llvm-project/commit/5d281a480e5caae09962b863960d7d057e908a3c
Author: Madhur Amilkanthwar <madhura at nvidia.com>
Date: 2025-01-21 (Tue, 21 Jan 2025)
Changed paths:
M llvm/lib/Transforms/Scalar/LoopInterchange.cpp
A llvm/test/Transforms/LoopInterchange/many-load-stores.ll
Log Message:
-----------
[LoopInterchange] Constrain number of load/stores in a loop (#118973)
In the current state of the code, the transform computes entries for the
dependency matrix until `MaxMemInstrCount` which is 100. After 99th
entry, it terminates and thus overall wastes compile-time.
It would be nice if we can compute total number of entries upfront and
early exit if the number of entries > 100. However, computing the number
of entries is not always possible as it depends on two factors:
1. Number of load-store pairs in a loop.
2. Number of common loop levels for each of the pair.
This patch constrains the whole computation on the number of loads and
stores instructions in the loop.
In another approach, I experimented with computing 1 and constraining
the number of pairs, but that did not lead to any additional benefit in
terms of compile time. However, when other issues are fixed, I can
revisit this approach.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list