Lines Matching refs:kernels
130 for (auto &iter : kernels) { in parseEntryPoint()
139 kernels.push_back(SPIRVKernelInfo(funcId, name)); in parseEntryPoint()
152 for (auto &kernel : kernels) { in parseFunction()
193 for (auto &kernel : kernels) { in parseName()
233 for (auto &kernel : kernels) { in parseTypePointer()
257 for (auto &kernel : kernels) { in parseOpString()
313 for (auto &kernel : kernels) { in applyDecoration()
410 for (auto &kernel : kernels) { in parseOpTypeImage()
428 for (auto& kernel : kernels) { in parseExecutionMode()
591 for (auto &kernel : kernels) { in parsingComplete()
631 std::vector<SPIRVKernelInfo> kernels; member in SPIRVKernelParser
647 struct clc_kernel_info *kernels; in clc_spirv_get_kernels_info() local
655 *num_kernels = parser.kernels.size(); in clc_spirv_get_kernels_info()
660 kernels = reinterpret_cast<struct clc_kernel_info *>(calloc(*num_kernels, in clc_spirv_get_kernels_info()
661 sizeof(*kernels))); in clc_spirv_get_kernels_info()
662 assert(kernels); in clc_spirv_get_kernels_info()
663 for (unsigned i = 0; i < parser.kernels.size(); i++) { in clc_spirv_get_kernels_info()
664 kernels[i].name = strdup(parser.kernels[i].name.c_str()); in clc_spirv_get_kernels_info()
665 kernels[i].num_args = parser.kernels[i].args.size(); in clc_spirv_get_kernels_info()
666 kernels[i].vec_hint_size = parser.kernels[i].vecHint >> 16; in clc_spirv_get_kernels_info()
667 kernels[i].vec_hint_type = (enum clc_vec_hint_type)(parser.kernels[i].vecHint & 0xFFFF); in clc_spirv_get_kernels_info()
668 if (!kernels[i].num_args) in clc_spirv_get_kernels_info()
673 args = reinterpret_cast<struct clc_kernel_arg *>(calloc(kernels[i].num_args, in clc_spirv_get_kernels_info()
674 sizeof(*kernels->args))); in clc_spirv_get_kernels_info()
675 kernels[i].args = args; in clc_spirv_get_kernels_info()
677 for (unsigned j = 0; j < kernels[i].num_args; j++) { in clc_spirv_get_kernels_info()
678 if (!parser.kernels[i].args[j].name.empty()) in clc_spirv_get_kernels_info()
679 args[j].name = strdup(parser.kernels[i].args[j].name.c_str()); in clc_spirv_get_kernels_info()
680 args[j].type_name = strdup(parser.kernels[i].args[j].typeName.c_str()); in clc_spirv_get_kernels_info()
681 args[j].address_qualifier = parser.kernels[i].args[j].addrQualifier; in clc_spirv_get_kernels_info()
682 args[j].type_qualifier = parser.kernels[i].args[j].typeQualifier; in clc_spirv_get_kernels_info()
683 args[j].access_qualifier = parser.kernels[i].args[j].accessQualifier; in clc_spirv_get_kernels_info()
697 *out_kernels = kernels; in clc_spirv_get_kernels_info()
704 clc_free_kernels_info(const struct clc_kernel_info *kernels, in clc_free_kernels_info() argument
707 if (!kernels) in clc_free_kernels_info()
711 if (kernels[i].args) { in clc_free_kernels_info()
712 for (unsigned j = 0; j < kernels[i].num_args; j++) { in clc_free_kernels_info()
713 free((void *)kernels[i].args[j].name); in clc_free_kernels_info()
714 free((void *)kernels[i].args[j].type_name); in clc_free_kernels_info()
717 free((void *)kernels[i].name); in clc_free_kernels_info()
720 free((void *)kernels); in clc_free_kernels_info()