[llvm] [AArch64][GISEL] Reduce likelihood of hash collisions for mappings in RegisterBankInfo (PR #87033)
Marc Auberer via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 29 07:39:52 PDT 2024
https://github.com/marcauberer updated https://github.com/llvm/llvm-project/pull/87033
>From 67c9281e8cd127cdde0d9fcffb7a834dbea7c2ce Mon Sep 17 00:00:00 2001
From: Marc Auberer <marc.auberer at chillibits.com>
Date: Sun, 17 Mar 2024 22:15:01 +0100
Subject: [PATCH] [AArch64][GISEL] Reduce likelihood of hash collisions for
mappings in RegisterBankInfo
---
llvm/include/llvm/CodeGen/RegisterBankInfo.h | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/llvm/include/llvm/CodeGen/RegisterBankInfo.h b/llvm/include/llvm/CodeGen/RegisterBankInfo.h
index 62c4a57a605d68..9704e3b1fdedd6 100644
--- a/llvm/include/llvm/CodeGen/RegisterBankInfo.h
+++ b/llvm/include/llvm/CodeGen/RegisterBankInfo.h
@@ -399,22 +399,22 @@ class RegisterBankInfo {
/// Keep dynamically allocated PartialMapping in a separate map.
/// This shouldn't be needed when everything gets TableGen'ed.
- mutable DenseMap<unsigned, std::unique_ptr<const PartialMapping>>
+ mutable DenseMap<hash_code, std::unique_ptr<const PartialMapping>>
MapOfPartialMappings;
/// Keep dynamically allocated ValueMapping in a separate map.
/// This shouldn't be needed when everything gets TableGen'ed.
- mutable DenseMap<unsigned, std::unique_ptr<const ValueMapping>>
+ mutable DenseMap<hash_code, std::unique_ptr<const ValueMapping>>
MapOfValueMappings;
/// Keep dynamically allocated array of ValueMapping in a separate map.
/// This shouldn't be needed when everything gets TableGen'ed.
- mutable DenseMap<unsigned, std::unique_ptr<ValueMapping[]>>
+ mutable DenseMap<hash_code, std::unique_ptr<ValueMapping[]>>
MapOfOperandsMappings;
/// Keep dynamically allocated InstructionMapping in a separate map.
/// This shouldn't be needed when everything gets TableGen'ed.
- mutable DenseMap<unsigned, std::unique_ptr<const InstructionMapping>>
+ mutable DenseMap<hash_code, std::unique_ptr<const InstructionMapping>>
MapOfInstructionMappings;
/// Getting the minimal register class of a physreg is expensive.
More information about the llvm-commits
mailing list