44 #if ISPC_LLVM_VERSION < OLDEST_SUPPORTED_LLVM || ISPC_LLVM_VERSION > LATEST_SUPPORTED_LLVM 45 #error "Only LLVM 6.0 - 10.0 and 11.0 development branch are supported" 48 #if defined(_WIN32) || defined(_WIN64) 49 #define ISPC_HOST_IS_WINDOWS 50 #elif defined(__linux__) 51 #define ISPC_HOST_IS_LINUX 52 #elif defined(__FreeBSD__) 53 #define ISPC_HOST_IS_FREEBSD 54 #elif defined(__APPLE__) 55 #define ISPC_HOST_IS_APPLE 69 #define ISPC_MAX_NVEC 64 72 #define LAST_OPT_NUMBER 1000 124 SourcePos(
const char *n = NULL,
int fl = 0,
int fc = 0,
int ll = 0,
int lc = 0);
136 llvm::DIFile *GetDIFile()
const;
138 bool operator==(
const SourcePos &p2)
const;
167 #ifdef ISPC_ARM_ENABLED 170 #ifdef ISPC_WASM_ENABLED 183 static std::string SupportedCPUs();
187 std::string GetTripleString()
const;
197 const char *GetISAString()
const;
200 static const char *ISAToTargetString(
Target::ISA isa);
204 const char *GetISATargetString()
const;
207 llvm::Value *SizeOf(llvm::Type *type, llvm::BasicBlock *insertAtEnd);
212 llvm::Value *StructOffset(llvm::Type *type,
int element, llvm::BasicBlock *insertAtEnd);
215 void markFuncWithTargetAttr(llvm::Function *func);
218 bool IsGenericTypeLayoutIndeterminate(llvm::Type *type);
220 const llvm::Target *
getTarget()
const {
return m_target; }
237 std::string
getCPU()
const {
return m_cpu; }
519 enum MathLib { Math_ISPC, Math_ISPCFast, Math_SVML, Math_System };
615 char currentDirectory[1024];
bool m_hasTranscendentals
bool isMultiTargetCompilation
Define enums describing target platform.
const llvm::Target * m_target
TargetLibRegistry * target_registry
bool hasVecPrefetch() const
This structure collects together a number of global variables.
bool getGeneratePIC() const
int m_nativeVectorAlignment
std::vector< std::pair< std::string, std::string > > m_funcAttributes
bool disableBlendedMaskedStores
std::map< std::pair< int, std::string >, bool > turnOffWarnings
Interface class for statements in the ispc language.
Structure that defines a compilation target.
Registry to handle bitcode libraries.
int getNativeVectorAlignment() const
std::vector< std::string > includePath
bool getMaskingIsFree() const
Symbol table that holds all known symbols during parsing and compilation.
int getMaskBitCount() const
int getDataTypeWidth() const
Type implementation for pointers to other types.
int getNativeVectorWidth() const
std::set< int > debug_stages
bool disableMaskAllOnOptimizations
bool disableGatherScatterOptimizations
bool disableCoherentControlFlow
Abstract base class for nodes in the abstract syntax tree (AST).
SourcePos Union(const SourcePos &p1, const SourcePos &p2)
bool mangleFunctionsWithTarget
CodegenOptLevel codegenOptLevel
AtomicType represents basic types like floats, ints, etc.
Representation of a range of positions in a source file.
bool disableUniformMemoryOptimizations
bool generateDebuggingSymbols
bool hasTranscendentals() const
llvm::TargetMachine * m_targetMachine
bool disableHandlePseudoMemoryOps
bool force32BitAddressing
int getVectorWidth() const
const llvm::DataLayout * getDataLayout() const
bool disableUniformControlFlow
llvm::DataLayout * m_dataLayout
const llvm::Target * getTarget() const
bool disableMaskedStoreToStore
bool hasTrigonometry() const
std::string getCPU() const
Type representing a function (return type + argument types)
Representation of a program symbol.
Interface class that defines the type abstraction.
ISPCTarget getISPCTarget() const
Expr is the abstract base class that defines the interface that all expression types must implement...
std::set< int > off_stages
std::vector< std::string > cppArgs
llvm::AttrBuilder * m_tf_attributes
llvm::TargetMachine * GetTargetMachine() const
bool disableGatherScatterFlattening
Structure that collects optimization options.
One-dimensional array type.