From 8c058dd2d752f9ac26a085eb93e1b6e864583be0 Mon Sep 17 00:00:00 2001 From: David Sherwood Date: Mon, 26 Oct 2020 15:12:58 +0000 Subject: [PATCH] [SVE] Remove TypeSize comparison operators All known instances in the code where we relied upon the TypeSize comparison operators have now been changed to either use scalar interger comparisons or one of the TypeSize::isKnownXY functions. It is now safe to remove the comparison operators. Differential Revision: https://reviews.llvm.org/D90160 --- llvm/include/llvm/Support/TypeSize.h | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/llvm/include/llvm/Support/TypeSize.h b/llvm/include/llvm/Support/TypeSize.h index 47fb90d..392dd1a 100644 --- a/llvm/include/llvm/Support/TypeSize.h +++ b/llvm/include/llvm/Support/TypeSize.h @@ -206,25 +206,6 @@ public: uint64_t getFixedSize() const { return getFixedValue(); } uint64_t getKnownMinSize() const { return getKnownMinValue(); } - friend bool operator<(const TypeSize &LHS, const TypeSize &RHS) { - assert(LHS.IsScalable == RHS.IsScalable && - "Ordering comparison of scalable and fixed types"); - - return LHS.MinVal < RHS.MinVal; - } - - friend bool operator>(const TypeSize &LHS, const TypeSize &RHS) { - return RHS < LHS; - } - - friend bool operator<=(const TypeSize &LHS, const TypeSize &RHS) { - return !(RHS < LHS); - } - - friend bool operator>=(const TypeSize &LHS, const TypeSize& RHS) { - return !(LHS < RHS); - } - TypeSize &operator-=(TypeSize RHS) { assert(IsScalable == RHS.IsScalable && "Subtraction using mixed scalable and fixed types"); -- 2.7.4