aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp
diff options
context:
space:
mode:
authorshadchin <shadchin@yandex-team.ru>2022-02-10 16:44:30 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:44:30 +0300
commit2598ef1d0aee359b4b6d5fdd1758916d5907d04f (patch)
tree012bb94d777798f1f56ac1cec429509766d05181 /contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp
parent6751af0b0c1b952fede40b19b71da8025b5d8bcf (diff)
downloadydb-2598ef1d0aee359b4b6d5fdd1758916d5907d04f.tar.gz
Restoring authorship annotation for <shadchin@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp')
-rw-r--r--contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp b/contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp
index 3d4f66f311..98162305e2 100644
--- a/contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp
+++ b/contrib/libs/llvm12/lib/CodeGen/MIRVRegNamerUtils.cpp
@@ -8,7 +8,7 @@
#include "MIRVRegNamerUtils.h"
#include "llvm/CodeGen/MachineRegisterInfo.h"
-#include "llvm/CodeGen/MachineStableHash.h"
+#include "llvm/CodeGen/MachineStableHash.h"
#include "llvm/IR/Constants.h"
#include "llvm/Support/Debug.h"
@@ -16,11 +16,11 @@ using namespace llvm;
#define DEBUG_TYPE "mir-vregnamer-utils"
-static cl::opt<bool>
- UseStableNamerHash("mir-vreg-namer-use-stable-hash", cl::init(false),
- cl::Hidden,
- cl::desc("Use Stable Hashing for MIR VReg Renaming"));
-
+static cl::opt<bool>
+ UseStableNamerHash("mir-vreg-namer-use-stable-hash", cl::init(false),
+ cl::Hidden,
+ cl::desc("Use Stable Hashing for MIR VReg Renaming"));
+
using VRegRenameMap = std::map<unsigned, unsigned>;
bool VRegRenamer::doVRegRenaming(const VRegRenameMap &VRM) {
@@ -58,14 +58,14 @@ std::string VRegRenamer::getInstructionOpcodeHash(MachineInstr &MI) {
std::string S;
raw_string_ostream OS(S);
- if (UseStableNamerHash) {
- auto Hash = stableHashValue(MI, /* HashVRegs */ true,
- /* HashConstantPoolIndices */ true,
- /* HashMemOperands */ true);
- assert(Hash && "Expected non-zero Hash");
- return std::to_string(Hash).substr(0, 5);
- }
-
+ if (UseStableNamerHash) {
+ auto Hash = stableHashValue(MI, /* HashVRegs */ true,
+ /* HashConstantPoolIndices */ true,
+ /* HashMemOperands */ true);
+ assert(Hash && "Expected non-zero Hash");
+ return std::to_string(Hash).substr(0, 5);
+ }
+
// Gets a hashable artifact from a given MachineOperand (ie an unsigned).
auto GetHashableMO = [this](const MachineOperand &MO) -> unsigned {
switch (MO.getType()) {