LLVM 20.0.0git
|
#include "DXILTranslateMetadata.h"
#include "DXILResource.h"
#include "DXILResourceAnalysis.h"
#include "DXILShaderFlags.h"
#include "DirectX.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/Twine.h"
#include "llvm/Analysis/DXILMetadataAnalysis.h"
#include "llvm/Analysis/DXILResource.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DiagnosticInfo.h"
#include "llvm/IR/DiagnosticPrinter.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/IRBuilder.h"
#include "llvm/IR/LLVMContext.h"
#include "llvm/IR/Metadata.h"
#include "llvm/IR/Module.h"
#include "llvm/InitializePasses.h"
#include "llvm/Pass.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/VersionTuple.h"
#include "llvm/TargetParser/Triple.h"
#include <cstdint>
Go to the source code of this file.
Variables | |
dxil translate | metadata |
dxil translate DXIL Translate | Metadata |
dxil translate DXIL Translate | false |
MDTuple * constructEntryMetadata | ( | const Function * | EntryFn, |
MDTuple * | Signatures, | ||
MDNode * | Resources, | ||
MDTuple * | Properties, | ||
LLVMContext & | Ctx | ||
) |
Definition at line 217 of file DXILTranslateMetadata.cpp.
References llvm::MDNode::get(), llvm::MDString::get(), llvm::ValueAsMetadata::get(), llvm::Value::getName(), and Signatures.
Referenced by emitEntryMD(), and emitTopLevelLibraryNode().
|
static |
Definition at line 276 of file DXILTranslateMetadata.cpp.
References llvm::NamedMDNode::addOperand(), llvm::dxil::ModuleMetadataInfo::DXILVersion, llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), llvm::IRBuilderBase::getInt32(), llvm::VersionTuple::getMajor(), and llvm::VersionTuple::getMinor().
Referenced by translateMetadata().
|
static |
Definition at line 236 of file DXILTranslateMetadata.cpp.
References constructEntryMetadata(), llvm::dxil::EntryProperties::Entry, llvm::Function::getContext(), getEntryPropAsMetadata(), and Signatures.
Referenced by translateMetadata().
|
static |
Definition at line 75 of file DXILTranslateMetadata.cpp.
References llvm::NamedMDNode::addOperand(), assert(), llvm::DXILBindingMap::cbuffers(), llvm::SmallVectorBase< Size_T >::empty(), llvm::DXILBindingMap::empty(), llvm::MDNode::get(), llvm::dxil::Resources::hasCBuffers(), llvm::dxil::Resources::hasUAVs(), llvm::SmallVectorTemplateBase< T, bool >::push_back(), llvm::DXILBindingMap::samplers(), llvm::DXILBindingMap::srvs(), llvm::DXILBindingMap::uavs(), llvm::dxil::Resources::writeCBuffers(), and llvm::dxil::Resources::writeUAVs().
Referenced by translateMetadata().
|
static |
Definition at line 263 of file DXILTranslateMetadata.cpp.
References llvm::NamedMDNode::addOperand(), llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), llvm::MDString::get(), llvm::IRBuilderBase::getInt32(), llvm::VersionTuple::getMajor(), llvm::VersionTuple::getMinor(), getShortShaderStage(), llvm::dxil::ModuleMetadataInfo::ShaderModelVersion, and llvm::dxil::ModuleMetadataInfo::ShaderProfile.
Referenced by translateMetadata().
Definition at line 288 of file DXILTranslateMetadata.cpp.
References llvm::SmallVectorImpl< T >::append(), constructEntryMetadata(), llvm::MDNode::get(), and getTagValueAsMetadata().
Referenced by translateMetadata().
|
static |
Definition at line 246 of file DXILTranslateMetadata.cpp.
References llvm::NamedMDNode::addOperand(), llvm::NamedMDNode::clearOperands(), llvm::VersionTuple::empty(), llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), llvm::IRBuilderBase::getInt32(), llvm::VersionTuple::getMajor(), llvm::VersionTuple::getMinor(), and llvm::dxil::ModuleMetadataInfo::ValidatorVersion.
Referenced by translateMetadata().
|
static |
Definition at line 183 of file DXILTranslateMetadata.cpp.
References llvm::SmallVectorImpl< T >::append(), llvm::SmallVectorImpl< T >::emplace_back(), llvm::SmallVectorBase< Size_T >::empty(), llvm::dxil::EntryProperties::Entry, llvm::ConstantAsMetadata::get(), llvm::MDNode::get(), llvm::Function::getContext(), llvm::Type::getInt32Ty(), getShaderStage(), getTagValueAsMetadata(), llvm::dxil::EntryProperties::NumThreadsX, llvm::dxil::EntryProperties::NumThreadsY, llvm::dxil::EntryProperties::NumThreadsZ, and llvm::dxil::EntryProperties::ShaderStage.
Referenced by emitEntryMD().
|
static |
Definition at line 148 of file DXILTranslateMetadata.cpp.
References llvm::Triple::Pixel.
Referenced by getEntryPropAsMetadata().
|
static |
Definition at line 122 of file DXILTranslateMetadata.cpp.
References llvm::Triple::Amplification, llvm::Triple::Compute, llvm::Triple::Domain, llvm::Triple::Geometry, llvm::Triple::Hull, llvm::Triple::Library, llvm_unreachable, llvm::Triple::Mesh, llvm::Triple::Pixel, and llvm::Triple::Vertex.
Referenced by emitShaderModelVersionMD(), and translateMetadata().
|
static |
Definition at line 153 of file DXILTranslateMetadata.cpp.
References llvm::SmallVectorImpl< T >::emplace_back(), llvm::ConstantAsMetadata::get(), llvm::Type::getInt32Ty(), llvm::Type::getInt64Ty(), and llvm_unreachable.
Referenced by emitTopLevelLibraryNode(), and getEntryPropAsMetadata().
INITIALIZE_PASS_BEGIN | ( | DXILTranslateMetadataLegacy | , |
"dxil-translate-metadata" | , | ||
"DXIL Translate Metadata" | , | ||
false | , | ||
false | |||
) |
|
static |
Definition at line 303 of file DXILTranslateMetadata.cpp.
References llvm::NamedMDNode::addOperand(), emitDXILVersionTupleMD(), emitEntryMD(), emitResourceMetadata(), emitShaderModelVersionMD(), emitTopLevelLibraryNode(), emitValidatorVersionMD(), llvm::SmallVectorImpl< T >::emplace_back(), llvm::dxil::EntryProperties::Entry, llvm::dxil::ModuleMetadataInfo::EntryPropertyVec, llvm::Triple::getEnvironmentTypeName(), llvm::Value::getName(), llvm::NamedMDNode::getOperand(), getShortShaderStage(), llvm::dxil::ModuleMetadataInfo::ShaderProfile, llvm::dxil::EntryProperties::ShaderStage, and Signatures.
Referenced by llvm::DXILTranslateMetadata::run().
dxil translate DXIL Translate false |
Definition at line 431 of file DXILTranslateMetadata.cpp.
dxil translate metadata |
Definition at line 430 of file DXILTranslateMetadata.cpp.
dxil translate DXIL Translate Metadata |
Definition at line 431 of file DXILTranslateMetadata.cpp.