[llvm] 23e3c3d - [IRBuilder] Add missing NoFolder::CreatePointerBitCastOrAddrSpaceCast(); NFC

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 3 10:11:38 PST 2020


Author: Nikita Popov
Date: 2020-02-03T19:11:27+01:00
New Revision: 23e3c3df260ac9d2872d684699141c131db95688

URL: https://github.com/llvm/llvm-project/commit/23e3c3df260ac9d2872d684699141c131db95688
DIFF: https://github.com/llvm/llvm-project/commit/23e3c3df260ac9d2872d684699141c131db95688.diff

LOG: [IRBuilder] Add missing NoFolder::CreatePointerBitCastOrAddrSpaceCast(); NFC

Split out from D73835. This method was added to ConstantFolder and
TargetFolder, but not NoFolder.

Added: 
    

Modified: 
    llvm/include/llvm/IR/NoFolder.h

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/IR/NoFolder.h b/llvm/include/llvm/IR/NoFolder.h
index 85fd2ab6a605..9073878476b6 100644
--- a/llvm/include/llvm/IR/NoFolder.h
+++ b/llvm/include/llvm/IR/NoFolder.h
@@ -235,6 +235,11 @@ class NoFolder {
     return CastInst::CreatePointerCast(C, DestTy);
   }
 
+  Instruction *CreatePointerBitCastOrAddrSpaceCast(
+      Constant *C, Type *DestTy) const {
+    return CastInst::CreatePointerBitCastOrAddrSpaceCast(C, DestTy);
+  }
+
   Instruction *CreateIntCast(Constant *C, Type *DestTy,
                        bool isSigned) const {
     return CastInst::CreateIntegerCast(C, DestTy, isSigned);


        


More information about the llvm-commits mailing list