Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-10 08:44:26

0001 //===- IntrinsicInst.h ------------------------------------------*- C++ -*-===//
0002 //
0003 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
0004 // See https://llvm.org/LICENSE.txt for license information.
0005 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
0006 //
0007 //===----------------------------------------------------------------------===//
0008 
0009 #ifndef LLVM_SANDBOXIR_INTRINSICINST_H
0010 #define LLVM_SANDBOXIR_INTRINSICINST_H
0011 
0012 #include "llvm/IR/IntrinsicInst.h"
0013 #include "llvm/SandboxIR/Instruction.h"
0014 
0015 namespace llvm::sandboxir {
0016 
0017 class IntrinsicInst : public CallInst {
0018   IntrinsicInst(llvm::IntrinsicInst *I, Context &Ctx) : CallInst(I, Ctx) {}
0019 
0020 public:
0021   Intrinsic::ID getIntrinsicID() const {
0022     return cast<llvm::IntrinsicInst>(Val)->getIntrinsicID();
0023   }
0024   bool isAssociative() const {
0025     return cast<llvm::IntrinsicInst>(Val)->isAssociative();
0026   }
0027   bool isCommutative() const {
0028     return cast<llvm::IntrinsicInst>(Val)->isCommutative();
0029   }
0030   bool isAssumeLikeIntrinsic() const {
0031     return cast<llvm::IntrinsicInst>(Val)->isAssumeLikeIntrinsic();
0032   }
0033   static bool mayLowerToFunctionCall(Intrinsic::ID IID) {
0034     return llvm::IntrinsicInst::mayLowerToFunctionCall(IID);
0035   }
0036   static bool classof(const Value *V) {
0037     auto *LLVMV = V->Val;
0038     return isa<llvm::IntrinsicInst>(LLVMV);
0039   }
0040 };
0041 
0042 } // namespace llvm::sandboxir
0043 
0044 #endif // LLVM_SANDBOXIR_INTRINSICINST_H