[PATCH] D151299: [ARM] Remove unused functions isExpImmValue, isExpImm, and isInvertedExpImm
Kazu Hirata via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed May 24 09:06:21 PDT 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rG94daee2e737c: [ARM] Remove unused functions isExpImmValue, isExpImm, and isInvertedExpImm (authored by kazu).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D151299/new/
https://reviews.llvm.org/D151299
Files:
llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
Index: llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
===================================================================
--- llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
+++ llvm/lib/Target/ARM/AsmParser/ARMAsmParser.cpp
@@ -1260,34 +1260,6 @@
return isImmediate<1, 33>();
}
- template<int shift>
- bool isExpImmValue(uint64_t Value) const {
- uint64_t mask = (1 << shift) - 1;
- if ((Value & mask) != 0 || (Value >> shift) > 0xff)
- return false;
- return true;
- }
-
- template<int shift>
- bool isExpImm() const {
- if (!isImm()) return false;
- const MCConstantExpr *CE = dyn_cast<MCConstantExpr>(getImm());
- if (!CE) return false;
-
- return isExpImmValue<shift>(CE->getValue());
- }
-
- template<int shift, int size>
- bool isInvertedExpImm() const {
- if (!isImm()) return false;
- const MCConstantExpr *CE = dyn_cast<MCConstantExpr>(getImm());
- if (!CE) return false;
-
- uint64_t OriginalValue = CE->getValue();
- uint64_t InvertedValue = OriginalValue ^ (((uint64_t)1 << size) - 1);
- return isExpImmValue<shift>(InvertedValue);
- }
-
bool isPKHLSLImm() const {
return isImmediate<0, 32>();
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D151299.525206.patch
Type: text/x-patch
Size: 1182 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230524/53121c72/attachment.bin>
More information about the llvm-commits
mailing list