[midend]重命名Sra指令的kind标识

This commit is contained in:
rain2133
2025-08-13 14:55:46 +08:00
parent ea944f6ba0
commit 60cb8d6e49
4 changed files with 7 additions and 7 deletions

View File

@ -751,7 +751,7 @@ class Instruction : public User {
kPhi = 0x1UL << 39,
kBitItoF = 0x1UL << 40,
kBitFtoI = 0x1UL << 41,
kSRA = 0x1UL << 42,
kSra = 0x1UL << 42,
kMulh = 0x1UL << 43
};
@ -855,7 +855,7 @@ public:
return "BitItoF";
case kBitFtoI:
return "BitFtoI";
case kSRA:
case kSra:
return "ashr";
default:
return "Unknown";
@ -868,7 +868,7 @@ public:
bool isBinary() const {
static constexpr uint64_t BinaryOpMask =
(kAdd | kSub | kMul | kDiv | kRem | kAnd | kOr | kSRA | kMulh) |
(kAdd | kSub | kMul | kDiv | kRem | kAnd | kOr | kSra | kMulh) |
(kICmpEQ | kICmpNE | kICmpLT | kICmpGT | kICmpLE | kICmpGE);
return kind & BinaryOpMask;
}