[llvm] [BOLT] Fix double conversion in CacheMetrics (PR #75253)
Maksim Panchenko via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 12 17:06:50 PST 2023
================
@@ -14,22 +14,18 @@
#include "bolt/Passes/CacheMetrics.h"
#include "bolt/Core/BinaryBasicBlock.h"
#include "bolt/Core/BinaryFunction.h"
-#include "llvm/Support/CommandLine.h"
#include <unordered_map>
using namespace llvm;
using namespace bolt;
-namespace opts {
-
-extern cl::OptionCategory BoltOptCategory;
+namespace {
-extern cl::opt<unsigned> ITLBPageSize;
-extern cl::opt<unsigned> ITLBEntries;
+/// The size of an i-tlb cache page.
+constexpr unsigned ITLBPageSize = 4096;
-} // namespace opts
-
-namespace {
+/// The number of entries in the i-tlb cache.
+constexpr unsigned ITLBEntries = 16;
----------------
maksfb wrote:
Why is the number of entries 16? I don't want to block this change, but at some point we'll have to address this issue for other platforms as well.
https://github.com/llvm/llvm-project/pull/75253
More information about the llvm-commits
mailing list