aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/IR/ModuleSummaryIndex.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2023-02-11 12:38:04 +0000
committerDimitry Andric <dim@FreeBSD.org>2023-02-11 12:38:11 +0000
commite3b557809604d036af6e00c60f012c2025b59a5e (patch)
tree8a11ba2269a3b669601e2fd41145b174008f4da8 /llvm/lib/IR/ModuleSummaryIndex.cpp
parent08e8dd7b9db7bb4a9de26d44c1cbfd24e869c014 (diff)
Diffstat (limited to 'llvm/lib/IR/ModuleSummaryIndex.cpp')
-rw-r--r--llvm/lib/IR/ModuleSummaryIndex.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/IR/ModuleSummaryIndex.cpp b/llvm/lib/IR/ModuleSummaryIndex.cpp
index 3e82987801c7..2d1440756a95 100644
--- a/llvm/lib/IR/ModuleSummaryIndex.cpp
+++ b/llvm/lib/IR/ModuleSummaryIndex.cpp
@@ -570,8 +570,7 @@ void ModuleSummaryIndex::exportToDot(
" [color=brown]; // call (hotness : Hot)",
" [style=bold,color=red]; // call (hotness : Critical)"};
- assert(static_cast<size_t>(TypeOrHotness) <
- sizeof(EdgeAttrs) / sizeof(EdgeAttrs[0]));
+ assert(static_cast<size_t>(TypeOrHotness) < std::size(EdgeAttrs));
OS << Pfx << NodeId(SrcMod, SrcId) << " -> " << NodeId(DstMod, DstId)
<< EdgeAttrs[TypeOrHotness] << "\n";
};