[clang] [llvm] [AMDGPU] Introduce asyncmark/wait intrinsics (PR #173259)
Pierre van Houtryve via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 5 02:46:31 PST 2026
================
@@ -1207,7 +1261,56 @@ void WaitcntBrackets::print(raw_ostream &OS) const {
}
OS << '\n';
+ OS << "Async score: ";
+ if (AsyncScore.empty())
+ OS << "none";
+ else
+ llvm::interleaveComma(AsyncScore, OS);
+ OS << '\n';
+
+ OS << "Async markers:";
+ if (AsyncMarkers.empty())
+ OS << "none";
OS << '\n';
+
+ for (const auto &Marker : AsyncMarkers) {
+ for (auto T : inst_counter_types()) {
+ unsigned MarkedScore = Marker[T];
+ switch (T) {
+ case LOAD_CNT:
+ OS << " " << (ST->hasExtendedWaitCounts() ? "LOAD" : "VM")
----------------
Pierre-vh wrote:
I feel like there is a good opportunity to simplify this and the switch above as well. e.g. move all of the printing part into a `toString(T)` util so this entire switch and the one above become `OS << toString(T) << ": " << MarkedScore` ?
https://github.com/llvm/llvm-project/pull/173259
More information about the cfe-commits
mailing list