name
string
code
string
asm
string
file
string
spvtools::opt::Loop::GetInductionStepOperation(spvtools::opt::Instruction const*) const
Instruction* Loop::GetInductionStepOperation( const Instruction* induction) const { // Induction must be a phi instruction. assert(induction->opcode() == spv::Op::OpPhi); Instruction* step = nullptr; analysis::DefUseManager* def_use_manager = context_->get_def_use_mgr(); // Traverse the incoming operan...
pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x18(%rbp), %rdi callq 0x76b0f0 cmpl $0xf5, %eax jne 0x92ee9a jmp 0x92eeb9 leaq 0x2cd313(%rip), %rdi # 0xbfc1b4 leaq 0x2cd332(%rip), %rsi # 0xbfc1da movl $0x27, %edx leaq 0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_descriptor.cpp
spvtools::opt::LoopFissionImpl::TraverseUseDef(spvtools::opt::Instruction*, std::set<spvtools::opt::Instruction*, std::less<spvtools::opt::Instruction*>, std::allocator<spvtools::opt::Instruction*>>*, bool, bool)
void LoopFissionImpl::TraverseUseDef(Instruction* inst, std::set<Instruction*>* returned_set, bool ignore_phi_users, bool report_loads) { assert(returned_set && "Set to be returned cannot be null."); analysis::DefUseManager* def_use = contex...
pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movb %r8b, %al movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) andb $0x1, %cl movb %cl, -0x19(%rbp) andb $0x1, %al movb %al, -0x1a(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x88(%rbp) xorl %eax, %eax cmpq $0x0, -0x18(%rbp) movb %al, -0x79(%rbp) je 0x93a133 m...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fission.cpp
spvtools::opt::LoopFusionPass::Process()
Pass::Status LoopFusionPass::Process() { bool modified = false; Module* module = context()->module(); // Process each function in the module for (Function& f : *module) { modified |= ProcessFunction(&f); } return modified ? Status::SuccessWithChange : Status::SuccessWithoutChange; }
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x50(%rbp) movb $0x0, -0x9(%rbp) callq 0x76b110 movq %rax, %rdi callq 0x738aa0 movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdi callq 0x76f840 movq %rax, -0x30(%rbp) movq %rdx, ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion_pass.cpp
spvtools::opt::LoopPeeling::FixExitCondition(std::function<unsigned int (spvtools::opt::Instruction*)> const&)
void LoopPeeling::FixExitCondition( const std::function<uint32_t(Instruction*)>& condition_builder) { CFG& cfg = *context_->cfg(); uint32_t condition_block_id = 0; for (uint32_t id : cfg.preds(GetClonedLoop()->GetMergeBlock()->id())) { if (GetClonedLoop()->IsInsideLoop(id)) { condition_block_id = i...
pushq %rbp movq %rsp, %rbp subq $0x160, %rsp # imm = 0x160 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x128(%rbp) movq (%rax), %rdi callq 0x77e030 movq -0x128(%rbp), %rdi movq %rax, -0x18(%rbp) movl $0x0, -0x1c(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x120(%rbp) callq 0x9...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_peeling.cpp
spvtools::opt::LoopPeelingPass::ProcessFunction(spvtools::opt::Function*)
bool LoopPeelingPass::ProcessFunction(Function* f) { bool modified = false; LoopDescriptor& loop_descriptor = *context()->GetLoopDescriptor(f); std::vector<Loop*> to_process_loop; to_process_loop.reserve(loop_descriptor.NumLoops()); for (Loop& l : loop_descriptor) { to_process_loop.push_back(&l); } ...
pushq %rbp movq %rsp, %rbp subq $0x240, %rsp # imm = 0x240 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x230(%rbp) movb $0x0, -0x11(%rbp) callq 0x76b110 movq %rax, %rdi movq -0x10(%rbp), %rsi callq 0x913e40 movq %rax, -0x20(%rbp) leaq -0x38(%rbp), %rdi callq 0x9196f0 movq -...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_peeling.cpp
spvtools::opt::LoopPeelingPass::LoopPeelingInfo::GetFirstNonLoopInvariantOperand(spvtools::opt::Instruction*) const
uint32_t LoopPeelingPass::LoopPeelingInfo::GetFirstNonLoopInvariantOperand( Instruction* condition) const { for (uint32_t i = 0; i < condition->NumInOperands(); i++) { BasicBlock* bb = context_->get_instr_block(condition->GetSingleWordInOperand(i)); if (!bb || !loop_->IsInsideLoop(bb)) { ret...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x30(%rbp) movl $0x0, -0x1c(%rbp) movl -0x1c(%rbp), %eax movl %eax, -0x34(%rbp) movq -0x18(%rbp), %rdi callq 0x76b860 movl %eax, %ecx movl -0x34(%rbp), %eax cmpl %ecx, %eax jae 0x949357 movq -0x3...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_peeling.cpp
spvtools::opt::LoopPeelingPass::LoopPeelingInfo::EvalOperator(spvtools::opt::LoopPeelingPass::CmpOperator, spvtools::opt::SExpression, spvtools::opt::SExpression, bool*) const
bool LoopPeelingPass::LoopPeelingInfo::EvalOperator(CmpOperator cmp_op, SExpression lhs, SExpression rhs, bool* result) const { assert(scev_analysis_->IsLoopInvar...
pushq %rbp movq %rsp, %rbp subq $0x110, %rsp # imm = 0x110 movq 0x10(%rbp), %rax movq %rdx, -0x18(%rbp) movq %rcx, -0x10(%rbp) movq %r8, -0x28(%rbp) movq %r9, -0x20(%rbp) movq %rdi, -0x30(%rbp) movl %esi, -0x34(%rbp) movq -0x30(%rbp), %rax movq %rax, -0xd0(%rbp) movq 0x10(%rax), %rcx movq %rcx, -0xc8(%rbp) m...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_peeling.cpp
spvtools::opt::InstructionBuilder::AddULessThan(unsigned int, unsigned int)
Instruction* AddULessThan(uint32_t op1, uint32_t op2) { analysis::Bool bool_type; uint32_t type = GetContext()->get_type_mgr()->GetId(&bool_type); // TODO(1841): Handle id overflow. std::unique_ptr<Instruction> inst(new Instruction( GetContext(), spv::Op::OpULessThan, type, GetContext()->TakeNex...
pushq %rbp movq %rsp, %rbp subq $0x1a0, %rsp # imm = 0x1A0 movq %rdi, -0x8(%rbp) movl %esi, -0xc(%rbp) movl %edx, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x188(%rbp) leaq -0x38(%rbp), %rdi callq 0x7c49c0 movq -0x188(%rbp), %rdi callq 0x7720d0 movq %rax, %rdi callq 0x76b2c0 movq %rax, %rdi leaq -0x38(%r...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/ir_builder.h
spvtools::opt::LoopUtils::CreateLoopDedicatedExits()
void LoopUtils::CreateLoopDedicatedExits() { Function* function = loop_->GetHeaderBlock()->GetParent(); LoopDescriptor& loop_desc = *context_->GetLoopDescriptor(function); CFG& cfg = *context_->cfg(); analysis::DefUseManager* def_use_mgr = context_->get_def_use_mgr(); const IRContext::Analysis PreservedAnaly...
pushq %rbp movq %rsp, %rbp subq $0x2c0, %rsp # imm = 0x2C0 movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x258(%rbp) movq 0x10(%rax), %rdi callq 0x9209f0 movq %rax, %rdi callq 0x7781c0 movq %rax, %rcx movq -0x258(%rbp), %rax movq %rcx, -0x10(%rbp) movq (%rax), %rdi movq -0x10(%rbp), %rsi callq 0x91...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_utils.cpp
spvtools::opt::LoopUtils::CloneLoop(spvtools::opt::LoopUtils::LoopCloningResult*, std::vector<spvtools::opt::BasicBlock*, std::allocator<spvtools::opt::BasicBlock*>> const&) const
Loop* LoopUtils::CloneLoop( LoopCloningResult* cloning_result, const std::vector<BasicBlock*>& ordered_loop_blocks) const { analysis::DefUseManager* def_use_mgr = context_->get_def_use_mgr(); std::unique_ptr<Loop> new_loop = MakeUnique<Loop>(context_); CFG& cfg = *context_->cfg(); // Clone and place ...
pushq %rbp movq %rsp, %rbp subq $0x190, %rsp # imm = 0x190 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x108(%rbp) movq (%rax), %rdi callq 0x76b8a0 movq -0x108(%rbp), %rsi movq %rax, -0x20(%rbp) leaq -0x28(%rbp), %rdi callq 0x956380 movq -0x108(%rbp),...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_utils.cpp
spvtools::opt::CodeMetrics::Analyze(spvtools::opt::Loop const&)
void CodeMetrics::Analyze(const Loop& loop) { CFG& cfg = *loop.GetContext()->cfg(); roi_size_ = 0; block_sizes_.clear(); for (uint32_t id : loop.GetBlocks()) { const BasicBlock* bb = cfg.block(id); size_t bb_size = 0; bb->ForEachInst([&bb_size](const Instruction* insn) { if (insn->opcode() =...
pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x80(%rbp) movq -0x10(%rbp), %rdi callq 0x934340 movq %rax, %rdi callq 0x77e030 movq -0x80(%rbp), %rdi movq %rax, -0x18(%rbp) movq $0x0, 0x38(%rdi) callq 0x956820 movq -0x10(%rbp), %rdi callq 0x934...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_utils.cpp
spvtools::opt::(anonymous namespace)::LCSSARewriter::UseRewriter::GetOrBuildIncoming(unsigned int)
Instruction* GetOrBuildIncoming(uint32_t bb_id) { assert(base_->cfg_->block(bb_id) != nullptr && "Unknown basic block"); Instruction*& incoming_phi = bb_to_phi_[bb_id]; if (incoming_phi) { return incoming_phi; } BasicBlock* bb = &*base_->cfg_->block(bb_id); // If this is an...
pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x70(%rbp) movq (%rax), %rax movq 0x8(%rax), %rdi movl -0x14(%rbp), %esi callq 0x7a1f70 movq %rax, %rcx xorl %eax, %eax cmpq $0x0, %rcx movb %al, -0x61(%rbp) je 0x95303e movb $0x1, %al movb %al, ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_utils.cpp
spvtools::opt::TreeDFIterator<spvtools::opt::Loop>::MoveToNextNode()
inline void MoveToNextNode() { if (!current_) return; if (parent_iterators_.empty()) { current_ = nullptr; return; } std::pair<NodePtr, NodeIterator>& next_it = parent_iterators_.top(); // Set the new node. current_ = *next_it.second; // Update the iterator for the next child. ...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x48(%rbp) cmpq $0x0, (%rax) jne 0x956edf jmp 0x956fe1 movq -0x48(%rbp), %rdi addq $0x8, %rdi callq 0x9221e0 testb $0x1, %al jne 0x956ef2 jmp 0x956f02 movq -0x48(%rbp), %rax movq $0x0, (%rax) jmp 0x956fe1 movq -0x48(%rbp...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/tree_iterator.h
spvtools::opt::LoopUtils::PartiallyUnroll(unsigned long)
bool LoopUtils::PartiallyUnroll(size_t factor) { if (factor == 1 || !CanPerformUnroll()) return false; // Create the unroller utility. LoopUnrollerUtilsImpl unroller{context_, loop_->GetHeaderBlock()->GetParent()}; unroller.Init(loop_); // If the unrolling factor is larger t...
pushq %rbp movq %rsp, %rbp subq $0x1f0, %rsp # imm = 0x1F0 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x1d8(%rbp) cmpq $0x1, -0x18(%rbp) je 0x959125 movq -0x1d8(%rbp), %rdi callq 0x958ca0 testb $0x1, %al jne 0x95912e movb $0x0, -0x1(%rbp) jmp 0x959236 movq -0x1d8(%rbp), ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unroller.cpp
spvtools::opt::LoopUnroller::Process()
Pass::Status LoopUnroller::Process() { bool changed = false; for (Function& f : *context()->module()) { if (f.IsDeclaration()) { continue; } LoopDescriptor* LD = context()->GetLoopDescriptor(&f); for (Loop& loop : *LD) { LoopUtils loop_utils{context(), &loop}; if (!loop.HasUnrollL...
pushq %rbp movq %rsp, %rbp subq $0x130, %rsp # imm = 0x130 movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x130(%rbp) movb $0x0, -0x9(%rbp) callq 0x76b110 movq %rax, %rdi callq 0x738aa0 movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rdi callq 0x76f840 movq %rax, -0x28(%rbp) movq %rdx, -0x20(%rbp) movq -0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unroller.cpp
spvtools::opt::(anonymous namespace)::LoopUnrollerUtilsImpl::Unroll(spvtools::opt::Loop*, unsigned long)
void LoopUnrollerUtilsImpl::Unroll(Loop* loop, size_t factor) { // If we unroll a loop partially it will not be safe to unroll it further. // This is due to the current method of calculating the number of loop // iterations. MarkLoopControlAsDontUnroll(loop); std::vector<Instruction*> inductions; loop->Get...
pushq %rbp movq %rsp, %rbp subq $0x160, %rsp # imm = 0x160 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x158(%rbp) movq -0x10(%rbp), %rsi callq 0x95abc0 leaq -0x30(%rbp), %rdi callq 0x757ad0 movq -0x10(%rbp), %rdi leaq -0x30(%rbp), %rsi callq 0x931d30...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unroller.cpp
spvtools::opt::(anonymous namespace)::LoopUnrollerUtilsImpl::CloseUnrolledLoop(spvtools::opt::Loop*)
void LoopUnrollerUtilsImpl::CloseUnrolledLoop(Loop* loop) { // Remove the OpLoopMerge instruction from the function. Instruction* merge_inst = loop->GetHeaderBlock()->GetLoopMergeInst(); invalidated_instructions_.push_back(merge_inst); // Remove the final backedge to the header and make it point instead to the...
pushq %rbp movq %rsp, %rbp subq $0x130, %rsp # imm = 0x130 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x108(%rbp) movq -0x10(%rbp), %rdi callq 0x9209f0 movq %rax, %rdi callq 0x815780 movq -0x108(%rbp), %rdi movq %rax, -0x18(%rbp) addq $0x28, %rdi leaq -0x18(%rbp), %rsi cal...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unroller.cpp
spvtools::opt::(anonymous namespace)::LoopUnrollState::NextIterationState()
void NextIterationState() { previous_phi_ = new_phi; previous_latch_block_ = new_latch_block; previous_condition_block_ = new_condition_block; previous_phis_ = std::move(new_phis_); // Clear new nodes. new_phi = nullptr; new_continue_block = nullptr; new_condition_block = nullptr; n...
pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x10(%rbp) movq 0x48(%rdi), %rax movq %rax, (%rdi) movq 0x68(%rdi), %rax movq %rax, 0x38(%rdi) movq 0x58(%rdi), %rax movq %rax, 0x40(%rdi) movq %rdi, %rsi addq $0x20, %rsi addq $0x8, %rdi callq 0x95d130 movq -0x10(%rbp),...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unroller.cpp
spvtools::opt::(anonymous namespace)::LoopUnrollerUtilsImpl::LinkLastPhisToStart(spvtools::opt::Loop*) const
void LoopUnrollerUtilsImpl::LinkLastPhisToStart(Loop* loop) const { std::vector<Instruction*> inductions; loop->GetInductionVariables(inductions); for (size_t i = 0; i < inductions.size(); ++i) { Instruction* last_phi_in_block = state_.previous_phis_[i]; uint32_t phi_index = GetPhiIndexFromLabel...
pushq %rbp movq %rsp, %rbp subq $0x100, %rsp # imm = 0x100 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0xd8(%rbp) leaq -0x28(%rbp), %rdi callq 0x757ad0 movq -0x10(%rbp), %rdi leaq -0x28(%rbp), %rsi callq 0x931d30 movq $0x0, -0x30(%rbp) movq -0x30(%rbp), %rax movq %rax, -0xe...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unroller.cpp
spvtools::opt::(anonymous namespace)::LoopUnswitch::IsConditionNonConstantLoopInvariant(spvtools::opt::Instruction*)
bool IsConditionNonConstantLoopInvariant(Instruction* insn) { assert(insn->IsBranch()); assert(insn->opcode() != spv::Op::OpBranch); analysis::DefUseManager* def_use_mgr = context_->get_def_use_mgr(); Instruction* condition = def_use_mgr->GetDef(insn->GetOperand(0).words[0]); if (condition->IsConst...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x18(%rbp), %rdi callq 0x804ff0 testb $0x1, %al jne 0x9605d7 jmp 0x9605d9 jmp 0x9605f8 leaq 0x29f2cd(%rip), %rdi # 0xbff8ad leaq 0x29f2d7(%rip), %rsi # 0xbff8be movl $0x225...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_unswitch_pass.cpp
spvtools::opt::MemPass::GetPtr(unsigned int, unsigned int*)
Instruction* MemPass::GetPtr(uint32_t ptrId, uint32_t* varId) { *varId = ptrId; Instruction* ptrInst = get_def_use_mgr()->GetDef(*varId); Instruction* varInst; if (ptrInst->opcode() == spv::Op::OpConstantNull) { *varId = 0; return ptrInst; } if (ptrInst->opcode() != spv::Op::OpVariable && pt...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x40(%rbp) movl -0x14(%rbp), %ecx movq -0x20(%rbp), %rax movl %ecx, (%rax) callq 0x76b080 movq %rax, %rdi movq -0x20(%rbp), %rax movl (%rax), %esi callq 0x895fb0 movq %rax,...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/mem_pass.cpp
spvtools::opt::MemPass::Type2Undef(unsigned int)
uint32_t MemPass::Type2Undef(uint32_t type_id) { const auto uitr = type2undefs_.find(type_id); if (uitr != type2undefs_.end()) return uitr->second; const uint32_t undefId = TakeNextId(); if (undefId == 0) { return 0; } std::unique_ptr<Instruction> undef_inst( new Instruction(context(), spv::Op::O...
pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x60(%rbp) addq $0xa8, %rdi leaq -0x14(%rbp), %rsi callq 0x3941c0 movq -0x60(%rbp), %rdi movq %rax, -0x20(%rbp) addq $0xa8, %rdi callq 0x395030 movq %rax, -0x28(%rbp) leaq -0x20(%rbp), %rdi leaq ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/mem_pass.cpp
spvtools::opt::MemPass::RemovePhiOperands(spvtools::opt::Instruction*, std::unordered_set<spvtools::opt::BasicBlock*, std::hash<spvtools::opt::BasicBlock*>, std::equal_to<spvtools::opt::BasicBlock*>, std::allocator<spvtools::opt::BasicBlock*>> const&)
void MemPass::RemovePhiOperands( Instruction* phi, const std::unordered_set<BasicBlock*>& reachable_blocks) { std::vector<Operand> keep_operands; uint32_t type_id = 0; // The id of an undefined value we've generated. uint32_t undef_id = 0; // Traverse all the operands in |phi|. Build the new operand vect...
pushq %rbp movq %rsp, %rbp subq $0x120, %rsp # imm = 0x120 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0xf8(%rbp) leaq -0x30(%rbp), %rdi callq 0x772080 movl $0x0, -0x34(%rbp) movl $0x0, -0x38(%rbp) movl $0x0, -0x3c(%rbp) movl -0x3c(%rbp), %eax movl %e...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/mem_pass.cpp
spvtools::opt::MergeReturnPass::Process()
Pass::Status MergeReturnPass::Process() { bool is_shader = context()->get_feature_mgr()->HasCapability(spv::Capability::Shader); bool failed = false; ProcessFunction pfn = [&failed, is_shader, this](Function* function) { std::vector<BasicBlock*> return_blocks = CollectReturnBlocks(function); if (re...
pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x60(%rbp) callq 0x76b110 movq %rax, %rdi callq 0x76c140 movq %rax, %rdi movl $0x1, %esi callq 0x76c180 movb %al, %cl movq -0x60(%rbp), %rax andb $0x1, %cl movb %cl, -0x11(%rbp) movb $0x0, -0x12(%rbp) leaq -0x12(%rbp),...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::ProcessStructured(spvtools::opt::Function*, std::vector<spvtools::opt::BasicBlock*, std::allocator<spvtools::opt::BasicBlock*>> const&)
bool MergeReturnPass::ProcessStructured( Function* function, const std::vector<BasicBlock*>& return_blocks) { if (HasNontrivialUnreachableBlocks(function)) { if (consumer()) { std::string message = "Module contains unreachable blocks during merge return. Run dead " "branch eliminati...
pushq %rbp movq %rsp, %rbp subq $0x180, %rsp # imm = 0x180 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x160(%rbp) movq -0x18(%rbp), %rsi callq 0x96bd80 testb $0x1, %al jne 0x96b854 jmp 0x96b8ee movq -0x160(%rbp), %rdi callq 0x78c790 movq %rax, %rdi...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::RecordImmediateDominators(spvtools::opt::Function*)
void MergeReturnPass::RecordImmediateDominators(Function* function) { DominatorAnalysis* dom_tree = context()->GetDominatorAnalysis(function); for (BasicBlock& bb : *function) { BasicBlock* dominator_bb = dom_tree->ImmediateDominator(&bb); if (dominator_bb && dominator_bb != cfg()->pseudo_entry_block()) { ...
pushq %rbp movq %rsp, %rbp subq $0x80, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x68(%rbp) callq 0x76b110 movq %rax, %rdi movq -0x10(%rbp), %rsi callq 0x915280 movq %rax, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdi callq 0x76f940 movq %rax,...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::ProcessStructuredBlock(spvtools::opt::BasicBlock*)
void MergeReturnPass::ProcessStructuredBlock(BasicBlock* block) { spv::Op tail_opcode = block->tail()->opcode(); if (tail_opcode == spv::Op::OpReturn || tail_opcode == spv::Op::OpReturnValue) { if (!return_flag_) { AddReturnFlag(); } } if (tail_opcode == spv::Op::OpReturn || tail_opco...
pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x40(%rbp) movq -0x10(%rbp), %rsi leaq -0x20(%rbp), %rdi callq 0x7f6850 leaq -0x20(%rbp), %rdi callq 0x7754f0 movq %rax, %rdi callq 0x76b0f0 movl %eax, -0x14(%rbp) cmpl $0xfd, -0x14(%rbp) je 0x96c2...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::AddReturnFlag()
void MergeReturnPass::AddReturnFlag() { if (return_flag_) return; analysis::TypeManager* type_mgr = context()->get_type_mgr(); analysis::ConstantManager* const_mgr = context()->get_constant_mgr(); analysis::Bool temp; uint32_t bool_id = type_mgr->GetTypeInstruction(&temp); analysis::Bool* bool_type = type...
pushq %rbp movq %rsp, %rbp subq $0x240, %rsp # imm = 0x240 movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x1f0(%rbp) cmpq $0x0, 0x100(%rax) je 0x96d289 jmp 0x96d6d3 movq -0x1f0(%rbp), %rdi callq 0x76b110 movq %rax, %rdi callq 0x76b2c0 movq -0x1f0(%rbp), %rdi movq %rax, -0x10(%rbp) callq 0x76b110 mo...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::RecordReturned(spvtools::opt::BasicBlock*)
void MergeReturnPass::RecordReturned(BasicBlock* block) { if (block->tail()->opcode() != spv::Op::OpReturn && block->tail()->opcode() != spv::Op::OpReturnValue) return; assert(return_flag_ && "Did not generate the return flag variable."); if (!constant_true_) { analysis::Bool temp; const analy...
pushq %rbp movq %rsp, %rbp subq $0x220, %rsp # imm = 0x220 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x1c8(%rbp) movq -0x10(%rbp), %rsi leaq -0x18(%rbp), %rdi callq 0x7f6850 leaq -0x18(%rbp), %rdi callq 0x7754f0 movq %rax, %rdi callq 0x76b0f0 movl %eax, %ecx xorl %eax, %e...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::MergeReturnBlocks(spvtools::opt::Function*, std::vector<spvtools::opt::BasicBlock*, std::allocator<spvtools::opt::BasicBlock*>> const&)
void MergeReturnPass::MergeReturnBlocks( Function* function, const std::vector<BasicBlock*>& return_blocks) { if (return_blocks.size() <= 1) { // No work to do. return; } CreateReturnBlock(); uint32_t return_id = final_return_block_->id(); auto ret_block_iter = --function->end(); // Create the ...
pushq %rbp movq %rsp, %rbp subq $0x3c0, %rsp # imm = 0x3C0 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x318(%rbp) movq -0x18(%rbp), %rdi callq 0x831880 cmpq $0x1, %rax ja 0x96f326 jmp 0x96fb70 movq -0x318(%rbp), %rdi callq 0x96c770 movq -0x318(%rbp),...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::MergeReturnPass::CreateSingleCaseSwitch(spvtools::opt::BasicBlock*)
bool MergeReturnPass::CreateSingleCaseSwitch(BasicBlock* merge_target) { // Insert the switch before any code is run. We have to split the entry // block to make sure the OpVariable instructions remain in the entry block. BasicBlock* start_block = &*function_->begin(); auto split_pos = start_block->begin(); ...
pushq %rbp movq %rsp, %rbp subq $0xc0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x90(%rbp) movq 0xf8(%rax), %rdi callq 0x76f940 movq %rax, -0x30(%rbp) movq %rdx, -0x28(%rbp) leaq -0x30(%rbp), %rdi callq 0x76fa10 movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rsi leaq -0x38(%rbp),...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/merge_return_pass.cpp
spvtools::opt::ModifyMaximalReconvergence::RemoveMaximalReconvergence()
bool ModifyMaximalReconvergence::RemoveMaximalReconvergence() { bool changed = false; std::vector<Instruction*> to_remove; Instruction* mode = &*get_module()->execution_mode_begin(); while (mode) { if (mode->opcode() != spv::Op::OpExecutionMode && mode->opcode() != spv::Op::OpExecutionModeId) { ...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x40(%rbp) movb $0x0, -0x9(%rbp) leaq -0x28(%rbp), %rdi callq 0x757ad0 movq -0x40(%rbp), %rdi callq 0x7750e0 movq %rax, %rsi leaq -0x38(%rbp), %rdi callq 0x976da0 leaq -0x38(%rbp), %rdi callq 0x772880 movq %rax, -0x30(%r...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/modify_maximal_reconvergence.cpp
spvtools::opt::ModifyMaximalReconvergence::GetPreservedAnalyses()
IRContext::Analysis GetPreservedAnalyses() override { return IRContext::kAnalysisDefUse | IRContext::kAnalysisInstrToBlockMapping | IRContext::kAnalysisDecorations | IRContext::kAnalysisCombinators | IRContext::kAnalysisCFG | IRContext::kAnalysisNameMap | IRContext::kAnal...
pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movl $0x1, %edi movl $0x2, %esi callq 0x76b3b0 movl %eax, %edi movl $0x4, %esi callq 0x76b3b0 movl %eax, %edi movl $0x8, %esi callq 0x76b3b0 movl %eax, %edi movl $0x10, %esi callq 0x76b3b0 movl %eax, %edi movl $0x80, %esi callq 0x76b3b0 movl %eax, %edi m...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/modify_maximal_reconvergence.h
spvtools::opt::Module::GetTypes()
std::vector<Instruction*> Module::GetTypes() { std::vector<Instruction*> type_insts; for (auto& inst : types_values_) { if (IsTypeInst(inst.opcode())) type_insts.push_back(&inst); } return type_insts; }
pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x58(%rbp) movq %rdi, %rax movq %rax, -0x50(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) movb $0x0, -0x11(%rbp) callq 0x757ad0 movq -0x48(%rbp), %rax addq $0x4e0, %rax # imm = 0x4E0 movq %rax, -0x20(%r...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/module.cpp
spvtools::opt::Module::ToBinary(std::vector<unsigned int, std::allocator<unsigned int>>*, bool) const
void Module::ToBinary(std::vector<uint32_t>* binary, bool skip_nop) const { binary->push_back(header_.magic_number); binary->push_back(header_.version); // TODO(antiagainst): should we change the generator number? binary->push_back(header_.generator); binary->push_back(header_.bound); binary->push_back(head...
pushq %rbp movq %rsp, %rbp subq $0xa0, %rsp movb %dl, %al movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) andb $0x1, %al movb %al, -0x11(%rbp) movq -0x8(%rbp), %rsi movq %rsi, -0xa0(%rbp) movq -0x10(%rbp), %rdi callq 0xf2b10 movq -0xa0(%rbp), %rsi movq -0x10(%rbp), %rdi addq $0x4, %rsi callq 0xf2b10 movq -0xa0(%rbp), %rsi...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/module.cpp
spvtools::opt::operator<<(std::ostream&, spvtools::opt::Module const&)
std::ostream& operator<<(std::ostream& str, const Module& module) { module.ForEachInst([&str](const Instruction* inst) { str << *inst; if (inst->opcode() != spv::Op::OpFunctionEnd) { str << std::endl; } }); return str; }
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x40(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x38(%rbp) leaq -0x30(%rbp), %rdi leaq -0x38(%rbp), %rsi callq 0x978200 movq -0x40(%rbp), %rdi leaq -0x30(%rbp), %rsi xorl %edx, %edx callq 0x977630 le...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/module.cpp
spvtools::opt::InstructionList::ForEachInst(std::function<void (spvtools::opt::Instruction*)> const&, bool)
inline void ForEachInst(const std::function<void(Instruction*)>& f, bool run_on_debug_line_insts) { auto next = begin(); for (auto i = next; i != end(); i = next) { ++next; i->ForEachInst(f, run_on_debug_line_insts); } }
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movb %dl, %al movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) andb $0x1, %al movb %al, -0x11(%rbp) movq -0x8(%rbp), %rsi movq %rsi, -0x38(%rbp) leaq -0x20(%rbp), %rdi callq 0x7758e0 leaq -0x28(%rbp), %rdi leaq -0x20(%rbp), %rsi callq 0x771a80 movq -0x38(%rbp), %rsi leaq -0x30(%r...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/instruction_list.h
spvtools::opt::SSAPropagator::Run(spvtools::opt::Function*)
bool SSAPropagator::Run(Function* fn) { Initialize(fn); bool changed = false; while (!blocks_.empty() || !ssa_edge_uses_.empty()) { // Simulate all blocks first. Simulating blocks will add SSA edges to // follow after all the blocks have been simulated. if (!blocks_.empty()) { auto block = bloc...
pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x58(%rbp) movq -0x10(%rbp), %rsi callq 0x97a0d0 movb $0x0, -0x11(%rbp) movq -0x58(%rbp), %rdi addq $0x78, %rdi callq 0x96aa80 movb %al, %cl movb $0x1, %al testb $0x1, %cl movb %al, -0x59(%rbp) jne...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/propagator.cpp
spvtools::opt::(anonymous namespace)::ComputeRegisterLiveness::ComputeRegisterLiveness(spvtools::opt::RegisterLiveness*, spvtools::opt::Function*)
ComputeRegisterLiveness(RegisterLiveness* reg_pressure, Function* f) : reg_pressure_(reg_pressure), context_(reg_pressure->GetContext()), function_(f), cfg_(*reg_pressure->GetContext()->cfg()), def_use_manager_(*reg_pressure->GetContext()->get_def_use_mgr()), dom_tree_( ...
pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rcx movq %rcx, (%rax) movq -0x10(%rbp), %rdi callq 0x988540 movq %rax, %rcx movq -0x20(%rbp), %rax movq %rcx, 0x8(%rax) movq -0x18(%rbp), %rcx m...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/register_pressure.cpp
spvtools::opt::RegisterLiveness::SimulateFission(spvtools::opt::Loop const&, std::unordered_set<spvtools::opt::Instruction*, std::hash<spvtools::opt::Instruction*>, std::equal_to<spvtools::opt::Instruction*>, std::allocator<spvtools::opt::Instruction*>> const&, std::unordered_set<spvtools::opt::Instruction*, std::hash<...
void RegisterLiveness::SimulateFission( const Loop& loop, const std::unordered_set<Instruction*>& moved_inst, const std::unordered_set<Instruction*>& copied_inst, RegionRegisterLiveness* l1_sim_result, RegionRegisterLiveness* l2_sim_result) const { l1_sim_result->Clear(); l2_sim_result->Clear(); ...
pushq %rbp movq %rsp, %rbp subq $0x6e0, %rsp # imm = 0x6E0 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq %r9, -0x30(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x660(%rbp) movq -0x28(%rbp), %rdi callq 0x987150 movq -0x30(%rbp), %rdi callq 0x...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/register_pressure.cpp
spvtools::opt::ScalarEvolutionAnalysis::AnalyzeInstruction(spvtools::opt::Instruction const*)
SENode* ScalarEvolutionAnalysis::AnalyzeInstruction(const Instruction* inst) { auto itr = recurrent_node_map_.find(inst); if (itr != recurrent_node_map_.end()) return itr->second; SENode* output = nullptr; switch (inst->opcode()) { case spv::Op::OpPhi: { output = AnalyzePhiInstruction(inst); br...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x38(%rbp) addq $0x8, %rdi leaq -0x18(%rbp), %rsi callq 0x98de20 movq -0x38(%rbp), %rdi movq %rax, -0x20(%rbp) addq $0x8, %rdi callq 0x98de80 movq %rax, -0x28(%rbp) leaq -0x20(%rbp), %rdi leaq -0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::ScalarEvolutionAnalysis::CreateSubtraction(spvtools::opt::SENode*, spvtools::opt::SENode*)
SENode* ScalarEvolutionAnalysis::CreateSubtraction(SENode* operand_1, SENode* operand_2) { // Fold if both operands are constant. if (operand_1->GetType() == SENode::Constant && operand_2->GetType() == SENode::Constant) { return CreateConstant(operand_1->...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x18(%rbp), %rdi movq (%rdi), %rax callq *(%rax) cmpl $0x0, %eax jne 0x98a8e6 movq -0x20(%rbp), %rdi movq (%rdi), %rax callq *(%rax) cmpl $0x0, %eax jne 0x...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::ScalarEvolutionAnalysis::AnalyzePhiInstruction(spvtools::opt::Instruction const*)
SENode* ScalarEvolutionAnalysis::AnalyzePhiInstruction(const Instruction* phi) { // The phi should only have two incoming value pairs. if (phi->NumInOperands() != 4) { return CreateCantComputeNode(); } analysis::DefUseManager* def_use = context_->get_def_use_mgr(); // Get the basic block this instructio...
pushq %rbp movq %rsp, %rbp subq $0x110, %rsp # imm = 0x110 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0xa8(%rbp) movq -0x18(%rbp), %rdi callq 0x76b860 cmpl $0x4, %eax je 0x98aaa1 movq -0xa8(%rbp), %rdi callq 0x98a320 movq %rax, -0x8(%rbp) jmp 0x98b03d movq -0xa8(%rbp), %...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::ScalarEvolutionAnalysis::BuildGraphWithoutRecurrentTerm(spvtools::opt::SENode*, spvtools::opt::Loop const*)
SENode* ScalarEvolutionAnalysis::BuildGraphWithoutRecurrentTerm( SENode* node, const Loop* loop) { // If the node is already a recurrent expression belonging to loop then just // return the offset. SERecurrentNode* recurrent = node->AsSERecurrentNode(); if (recurrent) { if (recurrent->GetLoop() == loop)...
pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rax movq %rax, -0xa0(%rbp) movq -0x18(%rbp), %rdi movq (%rdi), %rax callq *0x30(%rax) movq %rax, -0x28(%rbp) cmpq $0x0, -0x28(%rbp) je 0x98b825 movq -0x28(%rbp), %rdi callq 0x94ea30 cmpq -...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::ScalarEvolutionAnalysis::GetRecurrentTerm(spvtools::opt::SENode*, spvtools::opt::Loop const*)
SERecurrentNode* ScalarEvolutionAnalysis::GetRecurrentTerm(SENode* node, const Loop* loop) { for (auto itr = node->graph_begin(); itr != node->graph_end(); ++itr) { SERecurrentNode* rec = itr->AsSERecurrentNode(); if (rec && rec->GetLoop() == loop) { ...
pushq %rbp movq %rsp, %rbp subq $0xf0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x18(%rbp), %rsi leaq -0x78(%rbp), %rdi callq 0x98e360 movq -0x18(%rbp), %rsi leaq -0xd0(%rbp), %rdi callq 0x98e3c0 leaq -0x78(%rbp), %rdi leaq -0xd0(%rbp), %rsi callq 0x98e390 movb %al, -0xe1(%rbp) le...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::SENode::operator==(spvtools::opt::SENode const&) const
bool SENode::operator==(const SENode& other) const { if (GetType() != other.GetType()) return false; if (other.GetChildren().size() != children_.size()) return false; const SERecurrentNode* this_as_recurrent = AsSERecurrentNode(); // Check the children are the same, for SERecurrentNodes we need to check the ...
pushq %rbp movq %rsp, %rbp subq $0x80, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x40(%rbp) movq (%rdi), %rax callq *(%rax) movl %eax, -0x34(%rbp) movq -0x18(%rbp), %rdi movq (%rdi), %rax callq *(%rax) movl %eax, %ecx movl -0x34(%rbp), %eax cmpl %ecx, %eax je 0x98bcae movb $0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::SENode::DumpDot(std::ostream&, bool) const
void SENode::DumpDot(std::ostream& out, bool recurse) const { size_t unique_id = std::hash<const SENode*>{}(this); out << unique_id << " [label=\"" << AsString() << " "; if (GetType() == SENode::Constant) { out << "\nwith value: " << this->AsSEConstantNode()->FoldToSingleValue(); } out << "\"]\n"; for (...
pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movb %dl, %al movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) andb $0x1, %al movb %al, -0x11(%rbp) movq -0x8(%rbp), %rsi movq %rsi, -0x80(%rbp) leaq -0x21(%rbp), %rdi callq 0x98e7f0 movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rdi movq -0x20(%rbp), %rsi callq 0xd9f40 movq %rax, %rd...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::(anonymous namespace)::RemoveOneNodeFromMultiplyChain(spvtools::opt::SEMultiplyNode*, spvtools::opt::SENode const*)
SENode* RemoveOneNodeFromMultiplyChain(SEMultiplyNode* mul, const SENode* node) { SENode* lhs = mul->GetChildren()[0]; SENode* rhs = mul->GetChildren()[1]; if (lhs == node) { return rhs; } if (rhs == node) { return lhs; } if (lhs->AsSEMultiplyNode()) { SE...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rdi callq 0x98e890 movq %rax, %rdi xorl %eax, %eax movl %eax, %esi callq 0x990370 movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rdi callq 0x98e890 movq %rax, %rdi movl $0x1, %esi callq 0x990370 mov...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::(anonymous namespace)::IsGreaterThanZero::Visit(spvtools::opt::SERecurrentNode const*)
Signedness Visit(const SERecurrentNode* node) { Signedness coeff_sign = Visit(node->GetCoefficient()); // SERecurrentNode represent an affine expression in the range [0, // loop_bound], so the result cannot be strictly positive or negative. switch (coeff_sign) { default: break; case ...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x10(%rbp), %rdi callq 0x94f980 movq -0x48(%rbp), %rdi movq %rax, %rsi callq 0x98c860 movl %eax, -0x14(%rbp) movl -0x14(%rbp), %eax movl %eax, -0x3c(%rbp) subl $0x1, %eax je 0x98ca...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::(anonymous namespace)::IsGreaterThanZero::Visit(spvtools::opt::SEValueUnknown const*)
Signedness Visit(const SEValueUnknown* node) { Instruction* insn = context_->get_def_use_mgr()->GetDef(node->ResultId()); analysis::Type* type = context_->get_type_mgr()->GetType(insn->type_id()); assert(type && "Can't retrieve a type for the instruction"); analysis::Integer* int_type = type->AsInteger(...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x40(%rbp) movq (%rax), %rdi callq 0x76b8a0 movq %rax, -0x48(%rbp) movq -0x10(%rbp), %rdi callq 0x98e310 movq -0x48(%rbp), %rdi movl %eax, %esi callq 0x895fb0 movq %rax, %rcx movq -0x40(%rbp), %rax...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::(anonymous namespace)::IsGreaterThanZero::GetMulCombiner() const
Combiner GetMulCombiner() const { return [](Signedness lhs, Signedness rhs) { switch (lhs) { case Signedness::kPositiveOrNegative: break; case Signedness::kStrictlyNegative: { switch (rhs) { case Signedness::kPositiveOrNegative: { break; ...
pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, %rax movq %rax, -0x20(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) leaq -0x11(%rbp), %rsi callq 0x98d300 movq -0x20(%rbp), %rax addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis.cpp
spvtools::opt::SENodeSimplifyImpl::Simplify()
SENode* SENodeSimplifyImpl::Simplify() { // We only handle graphs with an addition, multiplication, or negation, at the // root. if (node_->GetType() != SENode::Add && node_->GetType() != SENode::Multiply && node_->GetType() != SENode::Negative) return node_; SENode* simplified_polynomial = SimplifyP...
pushq %rbp movq %rsp, %rbp subq $0x110, %rsp # imm = 0x110 movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x100(%rbp) movq 0x8(%rax), %rdi movq (%rdi), %rax callq *(%rax) cmpl $0x2, %eax je 0x997236 movq -0x100(%rbp), %rax movq 0x8(%rax), %rdi movq (%rdi), %rax callq *(%rax) cmpl $0x3, %eax je 0x9...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis_simplification.cpp
spvtools::opt::SENodeSimplifyImpl::FoldRecurrentAddExpressions(spvtools::opt::SENode*)
SENode* SENodeSimplifyImpl::FoldRecurrentAddExpressions(SENode* root) { std::unique_ptr<SEAddNode> new_node{new SEAddNode(&analysis_)}; // A mapping of loops to the list of recurrent expressions which are with // respect to those loops. std::map<const Loop*, std::vector<std::pair<SERecurrentNode*, bool>>> ...
pushq %rbp movq %rsp, %rbp subq $0x240, %rsp # imm = 0x240 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x1c0(%rbp) movl $0x30, %edi callq 0xdb140 movq %rax, %rdi movq -0x1c0(%rbp), %rax movq %rdi, -0x1b8(%rbp) movq (%rax), %rsi callq 0x98dde0 movq -0x1b8(%rbp), %rsi leaq ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis_simplification.cpp
spvtools::opt::SENodeSimplifyImpl::GatherAccumulatorsFromChildNodes(spvtools::opt::SENode*, spvtools::opt::SENode*, bool)
void SENodeSimplifyImpl::GatherAccumulatorsFromChildNodes(SENode* new_node, SENode* child, bool negation) { int32_t sign = negation ? -1 : 1; if (child->GetType() == SENode::Constant) { // Collec...
pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movb %cl, %al movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) andb $0x1, %al movb %al, -0x19(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x80(%rbp) movb -0x19(%rbp), %dl movl $0x1, %eax movl $0xffffffff, %ecx # imm = 0xFFFFFFFF testb $0x1, %dl cmovnel %e...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis_simplification.cpp
spvtools::opt::StructuredCFGAnalysis::MergeBlock(unsigned int)
uint32_t StructuredCFGAnalysis::MergeBlock(uint32_t bb_id) { uint32_t header_id = ContainingConstruct(bb_id); if (header_id == 0) { return 0; } BasicBlock* header = context_->cfg()->block(header_id); Instruction* merge_inst = header->GetMergeInst(); return merge_inst->GetSingleWordInOperand(kMergeNodeI...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x30(%rbp) movl -0x14(%rbp), %esi callq 0x805210 movl %eax, -0x18(%rbp) cmpl $0x0, -0x18(%rbp) jne 0x99cfe1 movl $0x0, -0x4(%rbp) jmp 0x99d017 movq -0x30(%rbp), %rax movq (%rax), %rdi callq 0x77e...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/struct_cfg_analysis.cpp
spvtools::opt::StructuredCFGAnalysis::LoopContinueBlock(unsigned int)
uint32_t StructuredCFGAnalysis::LoopContinueBlock(uint32_t bb_id) { uint32_t header_id = ContainingLoop(bb_id); if (header_id == 0) { return 0; } BasicBlock* header = context_->cfg()->block(header_id); Instruction* merge_inst = header->GetMergeInst(); return merge_inst->GetSingleWordInOperand(kContinue...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x30(%rbp) movl -0x14(%rbp), %esi callq 0x879730 movl %eax, -0x18(%rbp) cmpl $0x0, -0x18(%rbp) jne 0x99d121 movl $0x0, -0x4(%rbp) jmp 0x99d15a movq -0x30(%rbp), %rax movq (%rax), %rdi callq 0x77e...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/struct_cfg_analysis.cpp
spvtools::opt::ExtInsConflict(std::vector<unsigned int, std::allocator<unsigned int>> const&, spvtools::opt::Instruction const*, unsigned int)
bool ExtInsConflict(const std::vector<uint32_t>& extIndices, const Instruction* insInst, const uint32_t extOffset) { if (extIndices.size() - extOffset == insInst->NumInOperands() - 2) return false; uint32_t extNumIndices = static_cast<uint32_t>(extIndices.size()) - extOffset; uint32_t insN...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rdi callq 0xe8df0 movl -0x1c(%rbp), %ecx subq %rcx, %rax movq %rax, -0x38(%rbp) movq -0x18(%rbp), %rdi callq 0x76b860 movl %eax, %ecx movq -0x38(%rbp), %rax subl $0x2, %ecx movl %ecx, %ecx...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/composite.cpp
spvtools::opt::LoopDependenceAnalysis::GetDependence(spvtools::opt::Instruction const*, spvtools::opt::Instruction const*, spvtools::opt::DistanceVector*)
bool LoopDependenceAnalysis::GetDependence(const Instruction* source, const Instruction* destination, DistanceVector* distance_vector) { // Start off by finding and marking all the loops in |loops_| that are // irrelevant to the d...
pushq %rbp movq %rsp, %rbp subq $0x560, %rsp # imm = 0x560 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x520(%rbp) movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx movq -0x28(%rbp), %rcx callq 0x9b6e60 movq -0x520(%rbp), %rdi mov...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::LoopDependenceAnalysis::ZIVTest(std::pair<spvtools::opt::SENode*, spvtools::opt::SENode*> const&)
bool LoopDependenceAnalysis::ZIVTest( const std::pair<SENode*, SENode*>& subscript_pair) { auto source = std::get<0>(subscript_pair); auto destination = std::get<1>(subscript_pair); PrintDebug("Performing ZIVTest"); // If source == destination, dependence with direction = and distance 0. if (source == de...
pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0xa8(%rbp) movq -0x18(%rbp), %rdi callq 0x9a79b0 movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rdi callq 0x9a79d0 movq (%rax), %rax movq %rax, -0x28(%rbp) leaq -0x49(%rbp), %rdi cal...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::LoopDependenceAnalysis::GCDMIVTest(std::pair<spvtools::opt::SENode*, spvtools::opt::SENode*> const&)
bool LoopDependenceAnalysis::GCDMIVTest( const std::pair<SENode*, SENode*>& subscript_pair) { auto source = std::get<0>(subscript_pair); auto destination = std::get<1>(subscript_pair); // Bail out if source/destination is in an unexpected form. if (!IsInCorrectFormForGCDTest(source) || !IsInCorrectFo...
pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rdi callq 0x9a79b0 movq (%rax), %rax movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rdi callq 0x9a79d0 movq (%rax), %rax movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rdi callq 0x9a4a40 testb $0x1, %al jne 0x9a0da2 jmp 0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::LoopDependenceAnalysis::WeakZeroSourceSIVTest(spvtools::opt::SENode*, spvtools::opt::SERecurrentNode*, spvtools::opt::SENode*, spvtools::opt::DistanceEntry*)
bool LoopDependenceAnalysis::WeakZeroSourceSIVTest( SENode* source, SERecurrentNode* destination, SENode* coefficient, DistanceEntry* distance_entry) { PrintDebug("Performing WeakZeroSourceSIVTest."); std::pair<SENode*, SENode*> subscript_pair = std::make_pair(source, destination); const Loop* subsc...
pushq %rbp movq %rsp, %rbp subq $0x630, %rsp # imm = 0x630 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq %r8, -0x30(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x600(%rbp) leaq -0x51(%rbp), %rdi callq 0xd99e0 leaq -0x50(%rbp), %rdi leaq 0x2617d4(%rip), %rsi ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::LoopDependenceAnalysis::WeakZeroDestinationSIVTest(spvtools::opt::SERecurrentNode*, spvtools::opt::SENode*, spvtools::opt::SENode*, spvtools::opt::DistanceEntry*)
bool LoopDependenceAnalysis::WeakZeroDestinationSIVTest( SERecurrentNode* source, SENode* destination, SENode* coefficient, DistanceEntry* distance_entry) { PrintDebug("Performing WeakZeroDestinationSIVTest."); // Build an SENode for distance. std::pair<SENode*, SENode*> subscript_pair = std::make_p...
pushq %rbp movq %rsp, %rbp subq $0x610, %rsp # imm = 0x610 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq %r8, -0x30(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x5e0(%rbp) leaq -0x51(%rbp), %rdi callq 0xd99e0 leaq -0x50(%rbp), %rdi leaq 0x261073(%rip), %rsi ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::LoopDependenceAnalysis::WeakCrossingSIVTest(spvtools::opt::SENode*, spvtools::opt::SENode*, spvtools::opt::SENode*, spvtools::opt::DistanceEntry*)
bool LoopDependenceAnalysis::WeakCrossingSIVTest( SENode* source, SENode* destination, SENode* coefficient, DistanceEntry* distance_entry) { PrintDebug("Performing WeakCrossingSIVTest."); // We currently can't handle symbolic WeakCrossingSIVTests. If either source // or destination are not SERecurrentNode...
pushq %rbp movq %rsp, %rbp subq $0x1a0, %rsp # imm = 0x1A0 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) movq %r8, -0x30(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x180(%rbp) leaq -0x51(%rbp), %rdi callq 0xd99e0 leaq -0x50(%rbp), %rdi leaq 0x25ff42(%rip), %rsi ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::(anonymous namespace)::AreOffsetsAndCoefficientsConstant(std::vector<spvtools::opt::SERecurrentNode*, std::allocator<spvtools::opt::SERecurrentNode*>> const&)
bool AreOffsetsAndCoefficientsConstant( const std::vector<SERecurrentNode*>& nodes) { for (auto node : nodes) { if (!node->GetOffset()->AsSEConstantNode() || !node->GetOffset()->AsSEConstantNode()) { return false; } } return true; }
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rdi callq 0x9ad770 movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rdi callq 0x9ad7a0 movq %rax, -0x28(%rbp) leaq -0x20(%rbp), %rdi leaq -0x28(%rbp), %rsi callq 0x9ad7d0 testb $0x1, %al jne 0x9a...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::(anonymous namespace)::CalculateConstantTerm(std::vector<spvtools::opt::SERecurrentNode*, std::allocator<spvtools::opt::SERecurrentNode*>> const&, std::vector<spvtools::opt::SEConstantNode*, std::allocator<spvtools::opt::SEConstantNode*>> const&)
int64_t CalculateConstantTerm(const std::vector<SERecurrentNode*>& recurrences, const std::vector<SEConstantNode*>& constants) { int64_t constant_term = 0; for (auto recurrence : recurrences) { constant_term += recurrence->GetOffset()->AsSEConstantNode()->FoldToSingleValue(...
pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq $0x0, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rdi callq 0x9ad770 movq %rax, -0x28(%rbp) movq -0x20(%rbp), %rdi callq 0x9ad7a0 movq %rax, -0x30(%rbp) leaq -0x28(%rbp), %rdi leaq -0x30(%rbp), ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::(anonymous namespace)::CalculateGCDFromCoefficients(std::vector<spvtools::opt::SERecurrentNode*, std::allocator<spvtools::opt::SERecurrentNode*>> const&, long)
int64_t CalculateGCDFromCoefficients( const std::vector<SERecurrentNode*>& recurrences, int64_t running_gcd) { for (SERecurrentNode* recurrence : recurrences) { auto coefficient = recurrence->GetCoefficient()->AsSEConstantNode(); running_gcd = GreatestCommonDivisor( running_gcd, std::abs(coeffici...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rdi callq 0x9ad770 movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rdi callq 0x9ad7a0 movq %rax, -0x28(%rbp) leaq -0x20(%rbp), %rdi leaq -0x28(%rbp), %rsi callq 0x9ad7d0 tes...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::LoopDependenceAnalysis::PropagateConstraints(std::pair<spvtools::opt::SENode*, spvtools::opt::SENode*> const&, std::vector<spvtools::opt::Constraint*, std::allocator<spvtools::opt::Constraint*>> const&)
SubscriptPair LoopDependenceAnalysis::PropagateConstraints( const SubscriptPair& subscript_pair, const std::vector<Constraint*>& constraints) { SENode* new_first = subscript_pair.first; SENode* new_second = subscript_pair.second; for (auto& constraint : constraints) { // In the paper this is a[k]. We...
pushq %rbp movq %rsp, %rbp subq $0x110, %rsp # imm = 0x110 movq %rdi, -0x18(%rbp) movq %rsi, -0x20(%rbp) movq %rdx, -0x28(%rbp) movq -0x18(%rbp), %rax movq %rax, -0xa0(%rbp) movq -0x20(%rbp), %rax movq (%rax), %rax movq %rax, -0x30(%rbp) movq -0x20(%rbp), %rax movq 0x8(%rax), %rax movq %rax, -0x38(%rbp) movq...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.cpp
spvtools::opt::SENode::CollectValueUnknownNodes()
std::vector<SEValueUnknown*> CollectValueUnknownNodes() { std::vector<SEValueUnknown*> value_unknown_nodes{}; if (auto value_unknown_node = AsSEValueUnknown()) { value_unknown_nodes.push_back(value_unknown_node); } for (auto child : GetChildren()) { auto child_value_unknown_nodes = child->...
pushq %rbp movq %rsp, %rbp subq $0xa0, %rsp movq %rdi, -0x90(%rbp) movq %rdi, %rax movq %rax, -0x98(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x88(%rbp) movb $0x0, -0x11(%rbp) xorl %esi, %esi movl $0x18, %edx callq 0xd7340 movq -0x90(%rbp), %rdi callq 0x9abc90 movq -0x88(%rbp...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/scalar_analysis_nodes.h
spvtools::opt::DistanceEntry::DistanceEntry(long, long)
DistanceEntry(int64_t x, int64_t y) : dependence_information(DependenceInformation::POINT), direction(Directions::ALL), distance(0), peel_first(false), peel_last(false), point_x(x), point_y(y) {}
pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movl $0x5, (%rax) movl $0x7, 0x4(%rax) movq $0x0, 0x8(%rax) movb $0x0, 0x10(%rax) movb $0x0, 0x11(%rax) movq -0x10(%rbp), %rcx movq %rcx, 0x18(%rax) movq -0x18(%rbp), %rcx movq %rcx, 0x20(%rax) popq %rbp...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence.h
spvtools::opt::LoopDependenceAnalysis::GetLoopForSubscriptPair(std::pair<spvtools::opt::SENode*, spvtools::opt::SENode*> const&)
const Loop* LoopDependenceAnalysis::GetLoopForSubscriptPair( const std::pair<SENode*, SENode*>& subscript_pair) { // Collect all the SERecurrentNodes. std::vector<SERecurrentNode*> source_nodes = std::get<0>(subscript_pair)->CollectRecurrentNodes(); std::vector<SERecurrentNode*> destination_nodes = ...
pushq %rbp movq %rsp, %rbp subq $0x110, %rsp # imm = 0x110 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x108(%rbp) movq -0x18(%rbp), %rdi callq 0x9a79b0 movq (%rax), %rsi leaq -0x30(%rbp), %rdi callq 0x9a7b30 movq -0x18(%rbp), %rdi callq 0x9a79d0 movq (%rax), %rsi leaq -0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence_helpers.cpp
spvtools::opt::LoopDependenceAnalysis::GetTripCount(spvtools::opt::Loop const*)
SENode* LoopDependenceAnalysis::GetTripCount(const Loop* loop) { BasicBlock* condition_block = loop->FindConditionBlock(); if (!condition_block) { return nullptr; } Instruction* induction_instr = loop->FindConditionVariable(condition_block); if (!induction_instr) { return nullptr; } Instruction* c...
pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x18(%rbp), %rdi callq 0x92f200 movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) jne 0x9b6619 movq $0x0, -0x8(%rbp) jmp 0x9b66f2 movq -0x18(%rbp), %rdi movq -0x20(%rbp), %rsi callq ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence_helpers.cpp
spvtools::opt::LoopDependenceAnalysis::GetSubscripts(spvtools::opt::Instruction const*)
std::vector<Instruction*> LoopDependenceAnalysis::GetSubscripts( const Instruction* instruction) { Instruction* access_chain = GetOperandDefinition(instruction, 0); std::vector<Instruction*> subscripts; for (auto i = 1u; i < access_chain->NumInOperandWords(); ++i) { subscripts.push_back(GetOperandDefini...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x38(%rbp) movq %rdi, %rax movq %rax, -0x48(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x40(%rbp) movq -0x18(%rbp), %rsi xorl %edx, %edx callq 0x9b5c20 movq -0x38(%rbp), %rdi movq %rax, -0x20(%rbp) ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence_helpers.cpp
spvtools::opt::LoopDependenceAnalysis::MarkUnsusedDistanceEntriesAsIrrelevant(spvtools::opt::Instruction const*, spvtools::opt::Instruction const*, spvtools::opt::DistanceVector*)
void LoopDependenceAnalysis::MarkUnsusedDistanceEntriesAsIrrelevant( const Instruction* source, const Instruction* destination, DistanceVector* distance_vector) { std::vector<Instruction*> source_subscripts = GetSubscripts(source); std::vector<Instruction*> destination_subscripts = GetSubscripts(destination...
pushq %rbp movq %rsp, %rbp subq $0x1b0, %rsp # imm = 0x1B0 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq -0x8(%rbp), %rsi movq %rsi, -0x190(%rbp) movq -0x10(%rbp), %rdx leaq -0x38(%rbp), %rdi callq 0x9b6b30 movq -0x190(%rbp), %rsi movq -0x18(%rbp), %rdx leaq ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence_helpers.cpp
spvtools::opt::Constraint::operator==(spvtools::opt::Constraint const&) const
bool Constraint::operator==(const Constraint& other) const { // A distance of |d| is equivalent to a line |x - y = -d| if ((GetType() == ConstraintType::Distance && other.GetType() == ConstraintType::Line) || (GetType() == ConstraintType::Line && other.GetType() == ConstraintType::Distance)) { ...
pushq %rbp movq %rsp, %rbp subq $0xf0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rdi movq %rdi, -0x70(%rbp) movq (%rdi), %rax callq *(%rax) cmpl $0x1, %eax jne 0x9b72c3 movq -0x18(%rbp), %rdi movq (%rdi), %rax callq *(%rax) cmpl $0x0, %eax je 0x9b72e7 movq -0x70(%rbp), %rdi movq (%rdi), %rax...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_dependence_helpers.cpp
spvtools::opt::LoopFusion::CheckInit()
bool LoopFusion::CheckInit() { int64_t loop_0_init; if (!loop_0_->GetInductionInitValue(induction_0_, &loop_0_init)) { return false; } int64_t loop_1_init; if (!loop_1_->GetInductionInitValue(induction_1_, &loop_1_init)) { return false; } if (loop_0_init != loop_1_init) { return false; } ...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x28(%rbp) movq 0x8(%rax), %rdi movq 0x20(%rax), %rsi leaq -0x18(%rbp), %rdx callq 0x92f3c0 testb $0x1, %al jne 0x9ba58f movb $0x0, -0x1(%rbp) jmp 0x9ba5c2 movq -0x28(%rbp), %rax movq 0x10(%rax), %rdi movq 0x28(%rax), ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::LoopFusion::CheckCondition()
bool LoopFusion::CheckCondition() { auto condition_0 = loop_0_->GetConditionInst(); auto condition_1 = loop_1_->GetConditionInst(); if (!loop_0_->IsSupportedCondition(condition_0->opcode()) || !loop_1_->IsSupportedCondition(condition_1->opcode())) { return false; } if (condition_0->opcode() != con...
pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) movq 0x8(%rax), %rdi callq 0x92f130 movq %rax, %rcx movq -0x48(%rbp), %rax movq %rcx, -0x18(%rbp) movq 0x10(%rax), %rdi callq 0x92f130 movq %rax, %rcx movq -0x48(%rbp), %rax movq %rcx, -0x20(%rbp) movq 0x8(%...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::LoopFusion::CheckStep()
bool LoopFusion::CheckStep() { auto scalar_analysis = context_->GetScalarEvolutionAnalysis(); SENode* induction_node_0 = scalar_analysis->SimplifyExpression( scalar_analysis->AnalyzeInstruction(induction_0_)); if (!induction_node_0->AsSERecurrentNode()) { return false; } SENode* induction_step_0 = ...
pushq %rbp movq %rsp, %rbp subq $0x50, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x48(%rbp) movq (%rax), %rdi callq 0x94e560 movq %rax, %rcx movq -0x48(%rbp), %rax movq %rcx, -0x18(%rbp) movq -0x18(%rbp), %rcx movq %rcx, -0x40(%rbp) movq -0x18(%rbp), %rdi movq 0x20(%rax), %rsi callq 0x98a600 movq -...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::LoopFusion::LocationToMemOps(std::vector<spvtools::opt::Instruction*, std::allocator<spvtools::opt::Instruction*>> const&)
std::map<Instruction*, std::vector<Instruction*>> LoopFusion::LocationToMemOps( const std::vector<Instruction*>& mem_ops) { std::map<Instruction*, std::vector<Instruction*>> location_map{}; for (auto instruction : mem_ops) { auto access_location = context_->get_def_use_mgr()->GetDef( instruction->G...
pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x50(%rbp) movq %rdi, %rax movq %rax, -0x60(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x58(%rbp) movb $0x0, -0x19(%rbp) xorl %esi, %esi movl $0x30, %edx callq 0xd7340 movq -0x50(%rbp), %rdi callq 0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::LoopFusion::GetLoadsAndStoresInLoop(spvtools::opt::Loop*)
std::pair<std::vector<Instruction*>, std::vector<Instruction*>> LoopFusion::GetLoadsAndStoresInLoop(Loop* loop) { std::vector<Instruction*> loads{}; std::vector<Instruction*> stores{}; for (auto block_id : loop->GetBlocks()) { if (block_id == loop->GetContinueBlock()->id()) { continue; } for (...
pushq %rbp movq %rsp, %rbp subq $0xd0, %rsp movq %rdi, -0xc0(%rbp) movq %rdi, %rax movq %rax, -0xb8(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rax movq %rax, -0xb0(%rbp) leaq -0x30(%rbp), %rdi xorl %esi, %esi movl $0x18, %edx callq 0xd7340 leaq -0x30(%rbp), %rdi callq 0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::LoopFusion::IsUsedInLoop(spvtools::opt::Instruction*, spvtools::opt::Loop*)
bool LoopFusion::IsUsedInLoop(Instruction* instruction, Loop* loop) { auto not_used = context_->get_def_use_mgr()->WhileEachUser( instruction, [this, loop](Instruction* user) { auto block_id = context_->get_instr_block(user)->id(); return !loop->IsInsideLoop(block_id); }); return !not_u...
pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x70(%rbp) movq (%rax), %rdi callq 0x76b8a0 movq %rax, %rcx movq -0x70(%rbp), %rax movq %rcx, -0x68(%rbp) movq -0x10(%rbp), %rcx movq %rcx, -0x60(%rbp) movq %rax, -0x50(%rbp)...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::LoopFusion::Fuse()
void LoopFusion::Fuse() { assert(AreCompatible() && "Can't fuse, loops aren't compatible"); assert(IsLegal() && "Can't fuse, illegal"); // Save the pointers/ids, won't be found in the middle of doing modifications. auto header_1 = loop_1_->GetHeaderBlock()->id(); auto condition_1 = loop_1_->FindConditionBloc...
pushq %rbp movq %rsp, %rbp subq $0x450, %rsp # imm = 0x450 movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x310(%rbp) callq 0x9b9e20 movb %al, %cl xorl %eax, %eax testb $0x1, %cl movb %al, -0x301(%rbp) jne 0x9bbd00 jmp 0x9bbd0a movb $0x1, %al movb %al, -0x301(%rbp) jmp 0x9bbd0a movb -0x301(%rbp), %a...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/loop_fusion.cpp
spvtools::opt::Function::RemoveEmptyBlocks()
inline void Function::RemoveEmptyBlocks() { auto first_empty = std::remove_if(std::begin(blocks_), std::end(blocks_), [](const std::unique_ptr<BasicBlock>& bb) -> bool { return bb->GetLabelInst()->opcode() == spv::Op::OpNop; }); blocks_.erase(fi...
pushq %rbp movq %rsp, %rbp subq $0x60, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x58(%rbp) addq $0x98, %rdi callq 0x87ddf0 movq -0x58(%rbp), %rdi movq %rax, -0x18(%rbp) addq $0x98, %rdi callq 0x87de20 movq %rax, -0x20(%rbp) movq -0x18(%rbp), %rdi movq -0x20(%rbp), %rsi callq 0x9c1950 movq %rax, %rcx...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/opt/function.h
spvtools::utils::ParseAndEncodeIntegerNumber(char const*, spvtools::utils::NumberType const&, std::function<void (unsigned int)>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)
EncodeNumberStatus ParseAndEncodeIntegerNumber( const char* text, const NumberType& type, std::function<void(uint32_t)> emit, std::string* error_msg) { if (!text) { ErrorMsgStream(error_msg) << "The given text is a nullptr"; return EncodeNumberStatus::kInvalidText; } if (!IsIntegral(type)) { ...
pushq %rbp movq %rsp, %rbp subq $0x120, %rsp # imm = 0x120 movq %rdx, -0xe0(%rbp) movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) cmpq $0x0, -0x10(%rbp) jne 0x9c3b1b movq -0x28(%rbp), %rsi leaq -0x38(%rbp), %rdi callq 0x9c4050 leaq -0x38(%rbp), %rdi leaq 0x241277(%...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/parse_number.cpp
spvtools::utils::ParseAndEncodeFloatingPointNumber(char const*, spvtools::utils::NumberType const&, std::function<void (unsigned int)>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)
EncodeNumberStatus ParseAndEncodeFloatingPointNumber( const char* text, const NumberType& type, std::function<void(uint32_t)> emit, std::string* error_msg) { if (!text) { ErrorMsgStream(error_msg) << "The given text is a nullptr"; return EncodeNumberStatus::kInvalidText; } if (!IsFloating(type)) ...
pushq %rbp movq %rsp, %rbp subq $0xe0, %rsp movq %rdx, -0xd8(%rbp) movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) cmpq $0x0, -0x10(%rbp) jne 0x9c42fb movq -0x28(%rbp), %rsi leaq -0x38(%rbp), %rdi callq 0x9c4050 leaq -0x38(%rbp), %rdi leaq 0x240a97(%rip), %rsi # 0xc04d78 c...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/parse_number.cpp
spvtools::utils::ParseAndEncodeNumber(char const*, spvtools::utils::NumberType const&, std::function<void (unsigned int)>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>*)
EncodeNumberStatus ParseAndEncodeNumber(const char* text, const NumberType& type, std::function<void(uint32_t)> emit, std::string* error_msg) { if (!text) { ErrorMsgStream(error_msg) << "The giv...
pushq %rbp movq %rsp, %rbp subq $0xb0, %rsp movq %rdx, -0x90(%rbp) movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq %rcx, -0x28(%rbp) cmpq $0x0, -0x10(%rbp) jne 0x9c46ab movq -0x28(%rbp), %rsi leaq -0x38(%rbp), %rdi callq 0x9c4050 leaq -0x38(%rbp), %rdi leaq 0x2406e7(%rip), %rsi # 0xc04d78 c...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/parse_number.cpp
spvtools::utils::AssumedBitWidth(spvtools::utils::NumberType const&)
inline int AssumedBitWidth(const NumberType& type) { switch (type.kind) { case SPV_NUMBER_SIGNED_INT: case SPV_NUMBER_UNSIGNED_INT: case SPV_NUMBER_FLOATING: return type.bitwidth; default: break; } // We don't care about this case. return 0; }
pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movl 0x4(%rax), %eax decl %eax subl $0x2, %eax ja 0x9c4803 jmp 0x9c47f8 movq -0x10(%rbp), %rax movl (%rax), %eax movl %eax, -0x4(%rbp) jmp 0x9c480c jmp 0x9c4805 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax popq %rbp retq nopw %cs:(%rax,%rax) nopl (...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/parse_number.h
bool spvtools::utils::ParseNumber<long>(char const*, long*)
bool ParseNumber(const char* text, T* value_pointer) { // C++11 doesn't define std::istringstream(int8_t&), so calling this method // with a single-byte type leads to implementation-defined behaviour. // Similarly for uint8_t. static_assert(sizeof(T) > 1, "Single-byte types are not supported in ...
pushq %rbp movq %rsp, %rbp subq $0x1e0, %rsp # imm = 0x1E0 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) cmpq $0x0, -0x10(%rbp) jne 0x9c4873 movb $0x0, -0x1(%rbp) jmp 0x9c49fd movq -0x10(%rbp), %rax movq %rax, -0x1d0(%rbp) leaq -0x1b9(%rbp), %rdi callq 0xd99e0 movq -0x1d0(%rbp), %rsi leaq -0x1b8(%rbp), %rdi ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/parse_number.h
bool spvtools::utils::CheckRangeAndIfHexThenSignExtend<unsigned long>(unsigned long, spvtools::utils::NumberType const&, bool, unsigned long*)
bool CheckRangeAndIfHexThenSignExtend(T value, const NumberType& type, bool is_hex, T* updated_value_for_hex) { // The encoded result has three regions of bits that are of interest, from // least to most significant: // - magnitude bits, where the magnitude of the number wo...
pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movb %dl, %al movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) andb $0x1, %al movb %al, -0x19(%rbp) movq %rcx, -0x28(%rbp) movq -0x18(%rbp), %rdi callq 0x9c47e0 movl %eax, -0x2c(%rbp) cmpl $0x40, -0x2c(%rbp) jne 0x9c4d8a movq $-0x1, %rax movq %rax, -0x60(%rbp) jmp 0x9c4d9f movl ...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/parse_number.h
std::istream& spvtools::utils::operator>><spvtools::utils::FloatProxy<spvtools::utils::Float16>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<spvtools::utils::Float16>>>(std::istream&, spvtools::utils::HexFloat<spvtools::utils::FloatProxy<spvtools::utils::Float16>, spvtools::utils::HexFloatTraits<spvtool...
std::istream& operator>>(std::istream& is, HexFloat<T, Traits>& value) { using HF = HexFloat<T, Traits>; using uint_type = typename HF::uint_type; using int_type = typename HF::int_type; value.set_value(static_cast<typename HF::native_type>(0.f)); if (is.flags() & std::ios::skipws) { // If the user want...
pushq %rbp movq %rsp, %rbp subq $0x80, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax movq %rax, -0x68(%rbp) leaq -0x1a(%rbp), %rdi xorl %esi, %esi callq 0x852900 movq -0x68(%rbp), %rdi movzwl -0x1a(%rbp), %esi callq 0x852f10 movq -0x10(%rbp), %rdi movq (%rdi), %rax addq -0x18(%rax), %rdi cal...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/hex_float.h
bool spvtools::utils::RejectParseDueToLeadingSign<spvtools::utils::FloatProxy<float>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<float>>>(std::istream&, bool, spvtools::utils::HexFloat<spvtools::utils::FloatProxy<float>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<float>>>&)
inline bool RejectParseDueToLeadingSign(std::istream& is, bool negate_value, HexFloat<T, Traits>& value) { if (negate_value) { auto next_char = is.peek(); if (next_char == '-' || next_char == '+') { // Fail the parse. Emulate standard behaviour by setting the val...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movb %sil, %al movq %rdi, -0x10(%rbp) andb $0x1, %al movb %al, -0x11(%rbp) movq %rdx, -0x20(%rbp) testb $0x1, -0x11(%rbp) je 0x9c6913 movq -0x10(%rbp), %rdi callq 0xda120 movl %eax, -0x24(%rbp) cmpl $0x2d, -0x24(%rbp) je 0x9c68d6 cmpl $0x2b, -0x24(%rbp) jne 0x9c6911 leaq -0x2...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/hex_float.h
std::istream& spvtools::utils::operator>><spvtools::utils::FloatProxy<double>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<double>>>(std::istream&, spvtools::utils::HexFloat<spvtools::utils::FloatProxy<double>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<double>>>&)
std::istream& operator>>(std::istream& is, HexFloat<T, Traits>& value) { using HF = HexFloat<T, Traits>; using uint_type = typename HF::uint_type; using int_type = typename HF::int_type; value.set_value(static_cast<typename HF::native_type>(0.f)); if (is.flags() & std::ios::skipws) { // If the user want...
pushq %rbp movq %rsp, %rbp subq $0xe0, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax movq %rax, -0xc8(%rbp) leaq -0x20(%rbp), %rdi xorps %xmm0, %xmm0 callq 0x850da0 movq -0xc8(%rbp), %rdi movq -0x20(%rbp), %rsi callq 0x9c7b50 movq -0x10(%rbp), %rdi movq (%rdi), %rax addq -0x18(%rax), %rdi ca...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/hex_float.h
bool spvtools::utils::RejectParseDueToLeadingSign<spvtools::utils::FloatProxy<double>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<double>>>(std::istream&, bool, spvtools::utils::HexFloat<spvtools::utils::FloatProxy<double>, spvtools::utils::HexFloatTraits<spvtools::utils::FloatProxy<double>>>&)
inline bool RejectParseDueToLeadingSign(std::istream& is, bool negate_value, HexFloat<T, Traits>& value) { if (negate_value) { auto next_char = is.peek(); if (next_char == '-' || next_char == '+') { // Fail the parse. Emulate standard behaviour by setting the val...
pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movb %sil, %al movq %rdi, -0x10(%rbp) andb $0x1, %al movb %al, -0x11(%rbp) movq %rdx, -0x20(%rbp) testb $0x1, -0x11(%rbp) je 0x9c7e88 movq -0x10(%rbp), %rdi callq 0xda120 movl %eax, -0x24(%rbp) cmpl $0x2d, -0x24(%rbp) je 0x9c7e46 cmpl $0x2b, -0x24(%rbp) jne 0x9c7e86 leaq -0x3...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/hex_float.h
spvtools::utils::SplitFlagArgs(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&)
std::pair<std::string, std::string> SplitFlagArgs(const std::string& flag) { if (flag.size() < 2) return make_pair(flag, std::string()); // Detect the last dash before the pass name. Since we have to // handle single dash options (-O and -Os), count up to two dashes. size_t dash_ix = 0; if (flag[0] == '-' &&...
pushq %rbp movq %rsp, %rbp subq $0x100, %rsp # imm = 0x100 movq %rdi, -0xf0(%rbp) movq %rdi, %rax movq %rax, -0xe8(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x10(%rbp), %rdi callq 0xdbe00 cmpq $0x2, %rax jae 0x9c820c movq -0x10(%rbp), %rax movq %rax, -0xf8(%rbp) leaq -0x30(%rbp), %rdi callq 0x...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/string_utils.cpp
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> spvtools::utils::ToString<unsigned long>(unsigned long)
std::string ToString(T val) { static_assert( std::is_arithmetic<T>::value, "spvtools::utils::ToString is restricted to only arithmetic values"); std::stringstream os; os << val; return os.str(); }
pushq %rbp movq %rsp, %rbp subq $0x1b0, %rsp # imm = 0x1B0 movq %rdi, -0x1a8(%rbp) movq %rdi, %rax movq %rax, -0x1a0(%rbp) movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) leaq -0x198(%rbp), %rdi callq 0xd7a60 leaq -0x198(%rbp), %rdi addq $0x10, %rdi movq -0x10(%rbp), %rsi callq 0xd9f40 movq -0x1a8(%rbp), %rdi l...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/util/string_utils.h
spvtools::AssemblyGrammar::lookupSpecConstantOpcode(spv::Op) const
spv_result_t AssemblyGrammar::lookupSpecConstantOpcode(spv::Op opcode) const { const auto* last = kOpSpecConstantOpcodes + kNumOpSpecConstantOpcodes; const auto* found = std::find_if(kOpSpecConstantOpcodes, last, [opcode](const SpecConstantOpcodeEntry& entry) { return o...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movl %esi, -0x14(%rbp) leaq 0x626b6a(%rip), %rax # 0xfef390 addq $0x3d0, %rax # imm = 0x3D0 movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rsi movl -0x14(%rbp), %eax movl %eax, -0x2c(%rbp) movl -0x2c(%rbp), %edx leaq 0x626b4c(%rip), %rdi # 0...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/assembly_grammar.cpp
spvBinaryParse
spv_result_t spvBinaryParse(const spv_const_context context, void* user_data, const uint32_t* code, const size_t num_words, spv_parsed_header_fn_t parsed_header, spv_parsed_instruction_fn_t parsed_instruction, ...
pushq %rbp movq %rsp, %rbp subq $0x1e0, %rsp # imm = 0x1E0 movq 0x10(%rbp), %rax movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq %r9, -0x30(%rbp) movq -0x8(%rbp), %rsi leaq -0x70(%rbp), %rdi callq 0x9cd3c0 cmpq $0x0, 0x10(%rbp) je 0x9c94f3...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/binary.cpp
(anonymous namespace)::Parser::Parser(spv_context_t const*, void*, spv_result_t (*)(void*, spv_endianness_t, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int), spv_result_t (*)(void*, spv_parsed_instruction_t const*))
Parser(const spv_const_context context, void* user_data, spv_parsed_header_fn_t parsed_header_fn, spv_parsed_instruction_fn_t parsed_instruction_fn) : grammar_(context), consumer_(context->consumer), user_data_(user_data), parsed_header_fn_(parsed_header_fn), pars...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq %r8, -0x28(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x30(%rbp) movq -0x10(%rbp), %rsi callq 0x81f320 movq -0x30(%rbp), %rdi movq -0x10(%rbp), %rax addq $0x20, %rax movq %rax, 0x20(%...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/binary.cpp
(anonymous namespace)::Parser::State::State(unsigned int const*, unsigned long, spv_diagnostic_t**)
State(const uint32_t* words_arg, size_t num_words_arg, spv_diagnostic* diagnostic_arg) : words(words_arg), num_words(num_words_arg), diagnostic(diagnostic_arg), word_index(0), instruction_count(0), endian(), requires_endian_conversion(false) ...
pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x28(%rbp) movq -0x10(%rbp), %rax movq %rax, (%rdi) movq -0x18(%rbp), %rax movq %rax, 0x8(%rdi) movq -0x20(%rbp), %rax movq %rax, 0x10(%rdi) movq $0x0,...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/binary.cpp
(anonymous namespace)::Parser::exhaustedInputDiagnostic(unsigned long, spv::Op, spv_operand_type_t)
spv_result_t exhaustedInputDiagnostic(size_t inst_offset, spv::Op opcode, spv_operand_type_t type) { return diagnostic() << "End of input reached while decoding Op" << spvOpcodeString(opcode) << " starting at word " << inst_offs...
pushq %rbp movq %rsp, %rbp subq $0x230, %rsp # imm = 0x230 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movl %edx, -0x14(%rbp) movl %ecx, -0x18(%rbp) movq -0x8(%rbp), %rsi movq %rsi, -0x220(%rbp) leaq -0x1f0(%rbp), %rdi callq 0x9ca6f0 leaq -0x1f0(%rbp), %rdi leaq 0x2392b8(%rip), %rsi # 0xc05626 callq 0x9c...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/binary.cpp
(anonymous namespace)::Parser::setNumericTypeInfoForType(spv_parsed_operand_t*, unsigned int)
spv_result_t Parser::setNumericTypeInfoForType( spv_parsed_operand_t* parsed_operand, uint32_t type_id) { assert(type_id != 0); auto type_info_iter = _.type_id_to_number_type_info.find(type_id); if (type_info_iter == _.type_id_to_number_type_info.end()) { return diagnostic() << "Type Id " << type_id << " ...
pushq %rbp movq %rsp, %rbp subq $0x3f0, %rsp # imm = 0x3F0 movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rax movq %rax, -0x3f0(%rbp) cmpl $0x0, -0x1c(%rbp) je 0x9cc4b9 jmp 0x9cc4d8 leaq 0x20ecdf(%rip), %rdi # 0xbdb19f leaq 0x238ea3(%rip), %rsi # 0xc0536a movl $...
/DiligentGraphics[P]DiligentCore/ThirdParty/SPIRV-Tools/source/binary.cpp