/third_party/spirv-tools/source/opt/ |
D | local_single_store_elim_pass.cpp | 146 bool LocalSingleStoreElimPass::ProcessVariable(Instruction* var_inst) { in ProcessVariable() argument 148 FindUses(var_inst, &users); in ProcessVariable() 150 Instruction* store_inst = FindSingleStoreAndCheckUses(var_inst, users); in ProcessVariable() 162 uint32_t var_id = var_inst->result_id(); in ProcessVariable() 166 context()->get_type_mgr()->GetType(var_inst->type_id()); in ProcessVariable() 186 Instruction* var_inst, const std::vector<Instruction*>& users) const { in FindSingleStoreAndCheckUses() argument 191 if (var_inst->NumInOperands() > 1) { in FindSingleStoreAndCheckUses() 192 store_inst = var_inst; in FindSingleStoreAndCheckUses() 242 const Instruction* var_inst, std::vector<Instruction*>* users) const { in FindUses() argument 244 def_use_mgr->ForEachUser(var_inst, [users, this](Instruction* user) { in FindUses()
|
D | copy_prop_arrays.cpp | 49 for (auto var_inst = entry_bb->begin(); var_inst->opcode() == SpvOpVariable; in Process() local 50 ++var_inst) { in Process() 51 if (!IsPointerToArrayType(var_inst->type_id())) { in Process() 56 Instruction* store_inst = FindStoreInstruction(&*var_inst); in Process() 63 FindSourceObjectIfPossible(&*var_inst, store_inst); in Process() 66 if (CanUpdateUses(&*var_inst, source_object->GetPointerTypeId(this))) { in Process() 68 PropagateObject(&*var_inst, source_object.get(), store_inst); in Process() 77 CopyPropagateArrays::FindSourceObjectIfPossible(Instruction* var_inst, in FindSourceObjectIfPossible() argument 79 assert(var_inst->opcode() == SpvOpVariable && "Expecting a variable."); in FindSourceObjectIfPossible() 88 if (!HasValidReferencesOnly(var_inst, store_inst)) { in FindSourceObjectIfPossible() [all …]
|
D | local_single_store_elim_pass.h | 72 bool ProcessVariable(Instruction* var_inst); 77 void FindUses(const Instruction* var_inst, 84 Instruction* var_inst, const std::vector<Instruction*>& users) const;
|
D | code_sink.cpp | 273 bool CodeSinkingPass::HasPossibleStore(Instruction* var_inst) { in HasPossibleStore() argument 274 assert(var_inst->opcode() == SpvOpVariable || in HasPossibleStore() 275 var_inst->opcode() == SpvOpAccessChain || in HasPossibleStore() 276 var_inst->opcode() == SpvOpPtrAccessChain); in HasPossibleStore() 278 return get_def_use_mgr()->WhileEachUser(var_inst, [this](Instruction* use) { in HasPossibleStore()
|
D | copy_prop_arrays.h | 83 MemoryObject(Instruction* var_inst, iterator begin, iterator end); 172 Instruction* var_inst, Instruction* store_inst); 177 void PropagateObject(Instruction* var_inst, MemoryObject* source, 249 Instruction* FindStoreInstruction(const Instruction* var_inst) const;
|
D | inst_bindless_check_pass.cpp | 199 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in AnalyzeDescriptorReference() local 200 if (var_inst->opcode() != SpvOp::SpvOpVariable) return false; in AnalyzeDescriptorReference() 202 var_inst->GetSingleWordInOperand(kSpvVariableStorageClassInIdx); in AnalyzeDescriptorReference() 213 uint32_t var_ty_id = var_inst->type_id(); in AnalyzeDescriptorReference() 239 Instruction* desc_type_inst = GetPointeeTypeInst(var_inst); in AnalyzeDescriptorReference() 294 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in AnalyzeDescriptorReference() local 295 if (var_inst->opcode() != SpvOpVariable) { in AnalyzeDescriptorReference() 367 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in GenLastByteIdx() local 368 Instruction* desc_ty_inst = GetPointeeTypeInst(var_inst); in GenLastByteIdx() 599 Instruction* var_inst = get_def_use_mgr()->GetDef(ref.var_id); in GenDescIdxCheckCode() local [all …]
|
D | amd_ext_to_khr.cpp | 232 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceSwizzleInvocations() local 234 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceSwizzleInvocations() 355 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceSwizzleInvocationsMasked() local 357 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceSwizzleInvocationsMasked() 428 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceWriteInvocation() local 430 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceWriteInvocation() 485 Instruction* var_inst = def_use_mgr->GetDef(var_id); in ReplaceMbcnt() local 486 Instruction* var_ptr_type = def_use_mgr->GetDef(var_inst->type_id()); in ReplaceMbcnt()
|
D | inline_pass.cpp | 168 std::unique_ptr<Instruction> var_inst(callee_var_itr->Clone(context())); in CloneAndMapLocals() local 174 var_inst->SetResultId(newId); in CloneAndMapLocals() 175 var_inst->UpdateDebugInlinedAt( in CloneAndMapLocals() 179 new_vars->push_back(std::move(var_inst)); in CloneAndMapLocals() 209 std::unique_ptr<Instruction> var_inst( in CreateReturnVar() local 213 new_vars->push_back(std::move(var_inst)); in CreateReturnVar()
|
/third_party/skia/third_party/externals/swiftshader/third_party/SPIRV-Tools/source/opt/ |
D | local_single_store_elim_pass.cpp | 146 bool LocalSingleStoreElimPass::ProcessVariable(Instruction* var_inst) { in ProcessVariable() argument 148 FindUses(var_inst, &users); in ProcessVariable() 150 Instruction* store_inst = FindSingleStoreAndCheckUses(var_inst, users); in ProcessVariable() 162 uint32_t var_id = var_inst->result_id(); in ProcessVariable() 166 context()->get_type_mgr()->GetType(var_inst->type_id()); in ProcessVariable() 206 Instruction* var_inst, const std::vector<Instruction*>& users) const { in FindSingleStoreAndCheckUses() argument 211 if (var_inst->NumInOperands() > 1) { in FindSingleStoreAndCheckUses() 212 store_inst = var_inst; in FindSingleStoreAndCheckUses() 262 const Instruction* var_inst, std::vector<Instruction*>* users) const { in FindUses() argument 264 def_use_mgr->ForEachUser(var_inst, [users, this](Instruction* user) { in FindUses()
|
D | copy_prop_arrays.cpp | 49 for (auto var_inst = entry_bb->begin(); var_inst->opcode() == SpvOpVariable; in Process() local 50 ++var_inst) { in Process() 51 if (!IsPointerToArrayType(var_inst->type_id())) { in Process() 56 Instruction* store_inst = FindStoreInstruction(&*var_inst); in Process() 63 FindSourceObjectIfPossible(&*var_inst, store_inst); in Process() 66 if (CanUpdateUses(&*var_inst, source_object->GetPointerTypeId(this))) { in Process() 68 PropagateObject(&*var_inst, source_object.get(), store_inst); in Process() 77 CopyPropagateArrays::FindSourceObjectIfPossible(Instruction* var_inst, in FindSourceObjectIfPossible() argument 79 assert(var_inst->opcode() == SpvOpVariable && "Expecting a variable."); in FindSourceObjectIfPossible() 88 if (!HasValidReferencesOnly(var_inst, store_inst)) { in FindSourceObjectIfPossible() [all …]
|
D | local_single_store_elim_pass.h | 72 bool ProcessVariable(Instruction* var_inst); 77 void FindUses(const Instruction* var_inst, 84 Instruction* var_inst, const std::vector<Instruction*>& users) const;
|
D | copy_prop_arrays.h | 67 MemoryObject(Instruction* var_inst, iterator begin, iterator end); 150 Instruction* var_inst, Instruction* store_inst); 155 void PropagateObject(Instruction* var_inst, MemoryObject* source, 223 Instruction* FindStoreInstruction(const Instruction* var_inst) const;
|
D | code_sink.cpp | 273 bool CodeSinkingPass::HasPossibleStore(Instruction* var_inst) { in HasPossibleStore() argument 274 assert(var_inst->opcode() == SpvOpVariable || in HasPossibleStore() 275 var_inst->opcode() == SpvOpAccessChain || in HasPossibleStore() 276 var_inst->opcode() == SpvOpPtrAccessChain); in HasPossibleStore() 278 return get_def_use_mgr()->WhileEachUser(var_inst, [this](Instruction* use) { in HasPossibleStore()
|
D | inst_bindless_check_pass.cpp | 206 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in AnalyzeDescriptorReference() local 207 if (var_inst->opcode() != SpvOp::SpvOpVariable) return false; in AnalyzeDescriptorReference() 209 var_inst->GetSingleWordInOperand(kSpvVariableStorageClassInIdx); in AnalyzeDescriptorReference() 220 uint32_t var_ty_id = var_inst->type_id(); in AnalyzeDescriptorReference() 246 Instruction* desc_type_inst = GetPointeeTypeInst(var_inst); in AnalyzeDescriptorReference() 301 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in AnalyzeDescriptorReference() local 302 if (var_inst->opcode() != SpvOpVariable) { in AnalyzeDescriptorReference() 374 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in GenLastByteIdx() local 375 Instruction* desc_ty_inst = GetPointeeTypeInst(var_inst); in GenLastByteIdx() 606 Instruction* var_inst = get_def_use_mgr()->GetDef(ref.var_id); in GenDescIdxCheckCode() local [all …]
|
D | amd_ext_to_khr.cpp | 232 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceSwizzleInvocations() local 234 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceSwizzleInvocations() 355 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceSwizzleInvocationsMasked() local 357 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceSwizzleInvocationsMasked() 428 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceWriteInvocation() local 430 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceWriteInvocation() 485 Instruction* var_inst = def_use_mgr->GetDef(var_id); in ReplaceMbcnt() local 486 Instruction* var_ptr_type = def_use_mgr->GetDef(var_inst->type_id()); in ReplaceMbcnt()
|
D | inline_pass.cpp | 168 std::unique_ptr<Instruction> var_inst(callee_var_itr->Clone(context())); in CloneAndMapLocals() local 174 var_inst->SetResultId(newId); in CloneAndMapLocals() 175 var_inst->UpdateDebugInlinedAt( in CloneAndMapLocals() 179 new_vars->push_back(std::move(var_inst)); in CloneAndMapLocals() 209 std::unique_ptr<Instruction> var_inst( in CreateReturnVar() local 213 new_vars->push_back(std::move(var_inst)); in CreateReturnVar()
|
D | code_sink.h | 84 bool HasPossibleStore(Instruction* var_inst);
|
/third_party/skia/third_party/externals/spirv-tools/source/opt/ |
D | local_single_store_elim_pass.cpp | 146 bool LocalSingleStoreElimPass::ProcessVariable(Instruction* var_inst) { in ProcessVariable() argument 148 FindUses(var_inst, &users); in ProcessVariable() 150 Instruction* store_inst = FindSingleStoreAndCheckUses(var_inst, users); in ProcessVariable() 162 uint32_t var_id = var_inst->result_id(); in ProcessVariable() 166 context()->get_type_mgr()->GetType(var_inst->type_id()); in ProcessVariable() 206 Instruction* var_inst, const std::vector<Instruction*>& users) const { in FindSingleStoreAndCheckUses() argument 211 if (var_inst->NumInOperands() > 1) { in FindSingleStoreAndCheckUses() 212 store_inst = var_inst; in FindSingleStoreAndCheckUses() 262 const Instruction* var_inst, std::vector<Instruction*>* users) const { in FindUses() argument 264 def_use_mgr->ForEachUser(var_inst, [users, this](Instruction* user) { in FindUses()
|
D | copy_prop_arrays.cpp | 49 for (auto var_inst = entry_bb->begin(); var_inst->opcode() == SpvOpVariable; in Process() local 50 ++var_inst) { in Process() 51 if (!IsPointerToArrayType(var_inst->type_id())) { in Process() 56 Instruction* store_inst = FindStoreInstruction(&*var_inst); in Process() 63 FindSourceObjectIfPossible(&*var_inst, store_inst); in Process() 66 if (CanUpdateUses(&*var_inst, source_object->GetPointerTypeId(this))) { in Process() 68 PropagateObject(&*var_inst, source_object.get(), store_inst); in Process() 77 CopyPropagateArrays::FindSourceObjectIfPossible(Instruction* var_inst, in FindSourceObjectIfPossible() argument 79 assert(var_inst->opcode() == SpvOpVariable && "Expecting a variable."); in FindSourceObjectIfPossible() 88 if (!HasValidReferencesOnly(var_inst, store_inst)) { in FindSourceObjectIfPossible() [all …]
|
D | local_single_store_elim_pass.h | 72 bool ProcessVariable(Instruction* var_inst); 77 void FindUses(const Instruction* var_inst, 84 Instruction* var_inst, const std::vector<Instruction*>& users) const;
|
D | copy_prop_arrays.h | 67 MemoryObject(Instruction* var_inst, iterator begin, iterator end); 150 Instruction* var_inst, Instruction* store_inst); 155 void PropagateObject(Instruction* var_inst, MemoryObject* source, 223 Instruction* FindStoreInstruction(const Instruction* var_inst) const;
|
D | code_sink.cpp | 273 bool CodeSinkingPass::HasPossibleStore(Instruction* var_inst) { in HasPossibleStore() argument 274 assert(var_inst->opcode() == SpvOpVariable || in HasPossibleStore() 275 var_inst->opcode() == SpvOpAccessChain || in HasPossibleStore() 276 var_inst->opcode() == SpvOpPtrAccessChain); in HasPossibleStore() 278 return get_def_use_mgr()->WhileEachUser(var_inst, [this](Instruction* use) { in HasPossibleStore()
|
D | inst_bindless_check_pass.cpp | 206 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in AnalyzeDescriptorReference() local 207 if (var_inst->opcode() != SpvOp::SpvOpVariable) return false; in AnalyzeDescriptorReference() 209 var_inst->GetSingleWordInOperand(kSpvVariableStorageClassInIdx); in AnalyzeDescriptorReference() 220 uint32_t var_ty_id = var_inst->type_id(); in AnalyzeDescriptorReference() 246 Instruction* desc_type_inst = GetPointeeTypeInst(var_inst); in AnalyzeDescriptorReference() 301 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in AnalyzeDescriptorReference() local 302 if (var_inst->opcode() != SpvOpVariable) { in AnalyzeDescriptorReference() 374 Instruction* var_inst = get_def_use_mgr()->GetDef(ref->var_id); in GenLastByteIdx() local 375 Instruction* desc_ty_inst = GetPointeeTypeInst(var_inst); in GenLastByteIdx() 606 Instruction* var_inst = get_def_use_mgr()->GetDef(ref.var_id); in GenDescIdxCheckCode() local [all …]
|
D | amd_ext_to_khr.cpp | 232 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceSwizzleInvocations() local 234 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceSwizzleInvocations() 355 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceSwizzleInvocationsMasked() local 357 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceSwizzleInvocationsMasked() 428 Instruction* var_inst = ctx->get_def_use_mgr()->GetDef(var_id); in ReplaceWriteInvocation() local 430 ctx->get_def_use_mgr()->GetDef(var_inst->type_id()); in ReplaceWriteInvocation() 485 Instruction* var_inst = def_use_mgr->GetDef(var_id); in ReplaceMbcnt() local 486 Instruction* var_ptr_type = def_use_mgr->GetDef(var_inst->type_id()); in ReplaceMbcnt()
|
D | inline_pass.cpp | 168 std::unique_ptr<Instruction> var_inst(callee_var_itr->Clone(context())); in CloneAndMapLocals() local 174 var_inst->SetResultId(newId); in CloneAndMapLocals() 175 var_inst->UpdateDebugInlinedAt( in CloneAndMapLocals() 179 new_vars->push_back(std::move(var_inst)); in CloneAndMapLocals() 209 std::unique_ptr<Instruction> var_inst( in CreateReturnVar() local 213 new_vars->push_back(std::move(var_inst)); in CreateReturnVar()
|