Thanks to visit codestin.com
Credit goes to llvm.org

LLVM 22.0.0git
SPIRVPrepareFunctions.cpp File Reference
#include "SPIRV.h"
#include "SPIRVSubtarget.h"
#include "SPIRVTargetMachine.h"
#include "SPIRVUtils.h"
#include "llvm/ADT/StringExtras.h"
#include "llvm/Analysis/ValueTracking.h"
#include "llvm/CodeGen/IntrinsicLowering.h"
#include "llvm/IR/IRBuilder.h"
#include "llvm/IR/IntrinsicInst.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/IR/IntrinsicsSPIRV.h"
#include "llvm/Transforms/Utils/Cloning.h"
#include "llvm/Transforms/Utils/LowerMemIntrinsics.h"
#include <regex>

Go to the source code of this file.

Functions

 INITIALIZE_PASS (SPIRVPrepareFunctions, "prepare-functions", "SPIRV prepare functions", false, false) static std
static FunctiongetOrCreateFunction (Module *M, Type *RetTy, ArrayRef< Type * > ArgTypes, StringRef Name)
static bool lowerIntrinsicToFunction (IntrinsicInst *Intrinsic)
static std::string getAnnotation (Value *AnnoVal, Value *OptAnnoVal)
static SmallVector< Metadata * > parseAnnotation (Value *I, const std::string &Anno, LLVMContext &Ctx, Type *Int32Ty)
static void lowerPtrAnnotation (IntrinsicInst *II)
static void lowerFunnelShifts (IntrinsicInst *FSHIntrinsic)
static void lowerExpectAssume (IntrinsicInst *II)
static bool toSpvLifetimeIntrinsic (IntrinsicInst *II, Intrinsic::ID NewID)

Function Documentation

◆ getAnnotation()

std::string getAnnotation ( Value * AnnoVal,
Value * OptAnnoVal )
static

◆ getOrCreateFunction()

◆ INITIALIZE_PASS()

INITIALIZE_PASS ( SPIRVPrepareFunctions ,
"prepare-functions" ,
"SPIRV prepare functions" ,
false ,
false  )

◆ lowerExpectAssume()

void lowerExpectAssume ( IntrinsicInst * II)
static

◆ lowerFunnelShifts()

◆ lowerIntrinsicToFunction()

◆ lowerPtrAnnotation()

◆ parseAnnotation()

◆ toSpvLifetimeIntrinsic()

bool toSpvLifetimeIntrinsic ( IntrinsicInst * II,
Intrinsic::ID NewID )
static

Definition at line 362 of file SPIRVPrepareFunctions.cpp.

References llvm::cast(), II, and Size.