17ec681f3Smrg/* 27ec681f3Smrg * Copyright © 2021 Collabora Ltd. 37ec681f3Smrg * 47ec681f3Smrg * Derived from tu_pipeline.c which is: 57ec681f3Smrg * Copyright © 2016 Red Hat. 67ec681f3Smrg * Copyright © 2016 Bas Nieuwenhuizen 77ec681f3Smrg * Copyright © 2015 Intel Corporation 87ec681f3Smrg * 97ec681f3Smrg * Permission is hereby granted, free of charge, to any person obtaining a 107ec681f3Smrg * copy of this software and associated documentation files (the "Software"), 117ec681f3Smrg * to deal in the Software without restriction, including without limitation 127ec681f3Smrg * the rights to use, copy, modify, merge, publish, distribute, sublicense, 137ec681f3Smrg * and/or sell copies of the Software, and to permit persons to whom the 147ec681f3Smrg * Software is furnished to do so, subject to the following conditions: 157ec681f3Smrg * 167ec681f3Smrg * The above copyright notice and this permission notice (including the next 177ec681f3Smrg * paragraph) shall be included in all copies or substantial portions of the 187ec681f3Smrg * Software. 197ec681f3Smrg * 207ec681f3Smrg * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 217ec681f3Smrg * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 227ec681f3Smrg * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 237ec681f3Smrg * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 247ec681f3Smrg * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 257ec681f3Smrg * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 267ec681f3Smrg * DEALINGS IN THE SOFTWARE. 277ec681f3Smrg */ 287ec681f3Smrg 297ec681f3Smrg#include "panvk_cs.h" 307ec681f3Smrg#include "panvk_private.h" 317ec681f3Smrg 327ec681f3Smrg#include "pan_bo.h" 337ec681f3Smrg 347ec681f3Smrg#include "nir/nir.h" 357ec681f3Smrg#include "nir/nir_builder.h" 367ec681f3Smrg#include "spirv/nir_spirv.h" 377ec681f3Smrg#include "util/debug.h" 387ec681f3Smrg#include "util/mesa-sha1.h" 397ec681f3Smrg#include "util/u_atomic.h" 407ec681f3Smrg#include "vk_format.h" 417ec681f3Smrg#include "vk_util.h" 427ec681f3Smrg 437ec681f3Smrg#include "panfrost-quirks.h" 447ec681f3Smrg 457ec681f3SmrgVkResult 467ec681f3Smrgpanvk_CreateComputePipelines(VkDevice _device, 477ec681f3Smrg VkPipelineCache pipelineCache, 487ec681f3Smrg uint32_t count, 497ec681f3Smrg const VkComputePipelineCreateInfo *pCreateInfos, 507ec681f3Smrg const VkAllocationCallbacks *pAllocator, 517ec681f3Smrg VkPipeline *pPipelines) 527ec681f3Smrg{ 537ec681f3Smrg panvk_stub(); 547ec681f3Smrg return VK_SUCCESS; 557ec681f3Smrg} 567ec681f3Smrg 577ec681f3Smrgvoid 587ec681f3Smrgpanvk_DestroyPipeline(VkDevice _device, 597ec681f3Smrg VkPipeline _pipeline, 607ec681f3Smrg const VkAllocationCallbacks *pAllocator) 617ec681f3Smrg{ 627ec681f3Smrg VK_FROM_HANDLE(panvk_device, device, _device); 637ec681f3Smrg VK_FROM_HANDLE(panvk_pipeline, pipeline, _pipeline); 647ec681f3Smrg 657ec681f3Smrg panfrost_bo_unreference(pipeline->binary_bo); 667ec681f3Smrg panfrost_bo_unreference(pipeline->state_bo); 677ec681f3Smrg vk_object_free(&device->vk, pAllocator, pipeline); 687ec681f3Smrg} 69