]> granicus.if.org Git - llvm/commitdiff
[APInt] Remove the And/Or/Xor/Not functions from the APIntOps namespace.
authorCraig Topper <craig.topper@gmail.com>
Sun, 5 Mar 2017 16:41:11 +0000 (16:41 +0000)
committerCraig Topper <craig.topper@gmail.com>
Sun, 5 Mar 2017 16:41:11 +0000 (16:41 +0000)
Summary:
They aren't used anywhere in tree and its preferable to use the &, |, ^, or ~ operators.

With my patch to add rvalue reference support to &, |, ^ operators it also becomes less performant to use these functions.

Reviewers: RKSimon, davide, hans

Reviewed By: RKSimon

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D30613

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@296990 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/ADT/APInt.h

index 2acb60f769d45448469a5f602eb6b8d95cde2146..192a5fe31f731d3e274454a5e64479554c74012d 100644 (file)
@@ -1992,27 +1992,6 @@ inline APInt add(const APInt &LHS, const APInt &RHS) { return LHS + RHS; }
 /// Performs subtraction on APInt values.
 inline APInt sub(const APInt &LHS, const APInt &RHS) { return LHS - RHS; }
 
-/// \brief Bitwise AND function for APInt.
-///
-/// Performs bitwise AND operation on APInt LHS and
-/// APInt RHS.
-inline APInt And(const APInt &LHS, const APInt &RHS) { return LHS & RHS; }
-
-/// \brief Bitwise OR function for APInt.
-///
-/// Performs bitwise OR operation on APInt LHS and APInt RHS.
-inline APInt Or(const APInt &LHS, const APInt &RHS) { return LHS | RHS; }
-
-/// \brief Bitwise XOR function for APInt.
-///
-/// Performs bitwise XOR operation on APInt.
-inline APInt Xor(const APInt &LHS, const APInt &RHS) { return LHS ^ RHS; }
-
-/// \brief Bitwise complement function.
-///
-/// Performs a bitwise complement operation on APInt.
-inline APInt Not(const APInt &APIVal) { return ~APIVal; }
-
 } // End of APIntOps namespace
 
 // See friend declaration above. This additional declaration is required in