Lines Matching refs:function_info

726   VarInfo* function_info = GetVarInfo(function_name);  in ValidateFunction()  local
727 if (function_info->kind == VarKind::kUnused) { in ValidateFunction()
728 function_info->kind = VarKind::kFunction; in ValidateFunction()
729 function_info->function_builder = module_builder_->AddFunction(); in ValidateFunction()
730 function_info->index = function_info->function_builder->func_index(); in ValidateFunction()
731 function_info->mutable_variable = false; in ValidateFunction()
732 } else if (function_info->kind != VarKind::kFunction) { in ValidateFunction()
734 } else if (function_info->function_defined) { in ValidateFunction()
738 function_info->function_defined = true; in ValidateFunction()
739 function_info->function_builder->SetName(function_name_str); in ValidateFunction()
740 current_function_builder_ = function_info->function_builder; in ValidateFunction()
805 function_info = GetVarInfo(function_name); in ValidateFunction()
806 if (function_info->type->IsA(AsmType::None())) { in ValidateFunction()
807 DCHECK_EQ(function_info->kind, VarKind::kFunction); in ValidateFunction()
808 function_info->type = function_type; in ValidateFunction()
809 } else if (!function_type->IsA(function_info->type)) { in ValidateFunction()
2096 VarInfo* function_info = GetVarInfo(function_name); in ValidateCall() local
2097 if (function_info->kind == VarKind::kUnused) { in ValidateCall()
2102 function_info->kind = VarKind::kTable; in ValidateCall()
2103 function_info->mask = mask; in ValidateCall()
2104 function_info->index = index; in ValidateCall()
2105 function_info->mutable_variable = false; in ValidateCall()
2107 if (function_info->kind != VarKind::kTable) { in ValidateCall()
2110 if (function_info->mask != mask) { in ValidateCall()
2114 current_function_builder_->EmitI32Const(function_info->index); in ValidateCall()
2122 VarInfo* function_info = GetVarInfo(function_name); in ValidateCall() local
2123 if (function_info->kind == VarKind::kUnused) { in ValidateCall()
2124 function_info->kind = VarKind::kFunction; in ValidateCall()
2125 function_info->function_builder = module_builder_->AddFunction(); in ValidateCall()
2126 function_info->index = function_info->function_builder->func_index(); in ValidateCall()
2127 function_info->mutable_variable = false; in ValidateCall()
2129 if (function_info->kind != VarKind::kFunction && in ValidateCall()
2130 function_info->kind < VarKind::kImportedFunction) { in ValidateCall()
2160 VarInfo* function_info = GetVarInfo(function_name); in ValidateCall() local
2179 function_info->kind <= VarKind::kImportedFunction && in ValidateCall()
2201 if (function_info->kind == VarKind::kImportedFunction) { in ValidateCall()
2210 DCHECK_NOT_NULL(function_info->import); in ValidateCall()
2213 auto it = function_info->import->cache.find(*sig); in ValidateCall()
2214 if (it != function_info->import->cache.end()) { in ValidateCall()
2216 DCHECK(function_info->function_defined); in ValidateCall()
2219 module_builder_->AddImport(function_info->import->function_name, sig); in ValidateCall()
2220 function_info->import->cache[*sig] = index; in ValidateCall()
2221 function_info->function_defined = true; in ValidateCall()
2225 } else if (function_info->kind > VarKind::kImportedFunction) { in ValidateCall()
2226 AsmCallableType* callable = function_info->type->AsCallableType(); in ValidateCall()
2251 switch (function_info->kind) { in ValidateCall()
2274 if (function_info->kind == VarKind::kMathMin) { in ValidateCall()
2284 if (function_info->kind == VarKind::kMathMin) { in ValidateCall()
2297 if (function_info->kind == VarKind::kMathMin) { in ValidateCall()
2342 DCHECK(function_info->kind == VarKind::kFunction || in ValidateCall()
2343 function_info->kind == VarKind::kTable); in ValidateCall()
2344 if (function_info->type->IsA(AsmType::None())) { in ValidateCall()
2345 function_info->type = function_type; in ValidateCall()
2347 AsmCallableType* callable = function_info->type->AsCallableType(); in ValidateCall()
2353 if (function_info->kind == VarKind::kTable) { in ValidateCall()
2362 current_function_builder_->EmitDirectCallIndex(function_info->index); in ValidateCall()