diff --git a/framework/decode/vulkan_export_json_consumer_base.cpp b/framework/decode/vulkan_export_json_consumer_base.cpp index 4902ae70f1..6a3631212d 100644 --- a/framework/decode/vulkan_export_json_consumer_base.cpp +++ b/framework/decode/vulkan_export_json_consumer_base.cpp @@ -1,6 +1,5 @@ /* ** Copyright (c) 2022-2023 LunarG, Inc. -** Copyright (c) 2023 Advanced Micro Devices, Inc. All rights reserved. ** ** Permission is hereby granted, free of charge, to any person obtaining a ** copy of this software and associated documentation files (the "Software"), @@ -621,30 +620,6 @@ void VulkanExportJsonConsumerBase::Process_vkUpdateDescriptorSetWithTemplateKHR( WriteBlockEnd(); } -void VulkanExportJsonConsumerBase::Process_vkCreateRayTracingPipelinesKHR( - const ApiCallInfo& call_info, - VkResult returnValue, - format::HandleId device, - format::HandleId deferredOperation, - format::HandleId pipelineCache, - uint32_t createInfoCount, - StructPointerDecoder* pCreateInfos, - StructPointerDecoder* pAllocator, - HandlePointerDecoder* pPipelines) -{ - nlohmann::ordered_json& jdata = WriteApiCallStart(call_info, "vkCreateRayTracingPipelinesKHR"); - FieldToJson(jdata[NameReturn()], returnValue, json_options_); - auto& args = jdata[NameArgs()]; - HandleToJson(args["device"], device, json_options_); - HandleToJson(args["deferredOperation"], deferredOperation, json_options_); - HandleToJson(args["pipelineCache"], pipelineCache, json_options_); - FieldToJson(args["createInfoCount"], createInfoCount, json_options_); - FieldToJson(args["pCreateInfos"], pCreateInfos, json_options_); - FieldToJson(args["pAllocator"], pAllocator, json_options_); - HandleToJson(args["pPipelines"], pPipelines, json_options_); - WriteBlockEnd(); -} - void VulkanExportJsonConsumerBase::WriteBlockStart() { json_data_.clear(); // < Dominates profiling (1/2). diff --git a/framework/decode/vulkan_export_json_consumer_base.h b/framework/decode/vulkan_export_json_consumer_base.h index dcd5d3ae38..ba764ee024 100644 --- a/framework/decode/vulkan_export_json_consumer_base.h +++ b/framework/decode/vulkan_export_json_consumer_base.h @@ -1,6 +1,5 @@ /* ** Copyright (c) 2022-2023 LunarG, Inc. -** Copyright (c) 2023 Advanced Micro Devices, Inc. All rights reserved. ** ** Permission is hereby granted, free of charge, to any person obtaining a ** copy of this software and associated documentation files (the "Software"), @@ -180,17 +179,6 @@ class VulkanExportJsonConsumerBase : public VulkanConsumer, public AnnotationHan format::HandleId descriptorUpdateTemplate, DescriptorUpdateTemplateDecoder* pData) override; - virtual void Process_vkCreateRayTracingPipelinesKHR( - const ApiCallInfo& call_info, - VkResult returnValue, - format::HandleId device, - format::HandleId deferredOperation, - format::HandleId pipelineCache, - uint32_t createInfoCount, - StructPointerDecoder* pCreateInfos, - StructPointerDecoder* pAllocator, - HandlePointerDecoder* pPipelines) override; - /// @brief Convert annotations, which are simple {type:enum, key:string, value:string} objects. virtual void ProcessAnnotation(uint64_t block_index, format::AnnotationType type, diff --git a/framework/encode/custom_vulkan_api_call_encoders.h b/framework/encode/custom_vulkan_api_call_encoders.h index 349699b71a..fdbb9ff9b4 100644 --- a/framework/encode/custom_vulkan_api_call_encoders.h +++ b/framework/encode/custom_vulkan_api_call_encoders.h @@ -1,7 +1,6 @@ /* ** Copyright (c) 2018-2020 Valve Corporation ** Copyright (c) 2018-2020 LunarG, Inc. -** Copyright (c) 2023 Advanced Micro Devices, Inc. All rights reserved. ** ** Permission is hereby granted, free of charge, to any person obtaining a ** copy of this software and associated documentation files (the "Software"), diff --git a/framework/generated/generated_vulkan_export_json_consumer.cpp b/framework/generated/generated_vulkan_export_json_consumer.cpp index 98fde44c1b..3ed7084e10 100644 --- a/framework/generated/generated_vulkan_export_json_consumer.cpp +++ b/framework/generated/generated_vulkan_export_json_consumer.cpp @@ -9591,6 +9591,30 @@ void VulkanExportJsonConsumer::Process_vkCmdTraceRaysKHR( WriteBlockEnd(); } +void VulkanExportJsonConsumer::Process_vkCreateRayTracingPipelinesKHR( + const ApiCallInfo& call_info, + VkResult returnValue, + format::HandleId device, + format::HandleId deferredOperation, + format::HandleId pipelineCache, + uint32_t createInfoCount, + StructPointerDecoder* pCreateInfos, + StructPointerDecoder* pAllocator, + HandlePointerDecoder* pPipelines) +{ + nlohmann::ordered_json& jdata = WriteApiCallStart(call_info, "vkCreateRayTracingPipelinesKHR"); + FieldToJson(jdata[NameReturn()], returnValue, json_options_); + auto& args = jdata[NameArgs()]; + HandleToJson(args["device"], device, json_options_); + HandleToJson(args["deferredOperation"], deferredOperation, json_options_); + HandleToJson(args["pipelineCache"], pipelineCache, json_options_); + FieldToJson(args["createInfoCount"], createInfoCount, json_options_); + FieldToJson(args["pCreateInfos"], pCreateInfos, json_options_); + FieldToJson(args["pAllocator"], pAllocator, json_options_); + HandleToJson(args["pPipelines"], pPipelines, json_options_); + WriteBlockEnd(); +} + void VulkanExportJsonConsumer::Process_vkGetRayTracingCaptureReplayShaderGroupHandlesKHR( const ApiCallInfo& call_info, VkResult returnValue, diff --git a/framework/generated/generated_vulkan_export_json_consumer.h b/framework/generated/generated_vulkan_export_json_consumer.h index 174d3b4ae3..0dbd2c1d34 100644 --- a/framework/generated/generated_vulkan_export_json_consumer.h +++ b/framework/generated/generated_vulkan_export_json_consumer.h @@ -4116,6 +4116,17 @@ class VulkanExportJsonConsumer : public VulkanExportJsonConsumerBase uint32_t height, uint32_t depth) override; + virtual void Process_vkCreateRayTracingPipelinesKHR( + const ApiCallInfo& call_info, + VkResult returnValue, + format::HandleId device, + format::HandleId deferredOperation, + format::HandleId pipelineCache, + uint32_t createInfoCount, + StructPointerDecoder* pCreateInfos, + StructPointerDecoder* pAllocator, + HandlePointerDecoder* pPipelines) override; + virtual void Process_vkGetRayTracingCaptureReplayShaderGroupHandlesKHR( const ApiCallInfo& call_info, VkResult returnValue, diff --git a/framework/generated/vulkan_generators/vulkan_export_json_consumer_body_generator.py b/framework/generated/vulkan_generators/vulkan_export_json_consumer_body_generator.py index 7a6e51a677..2d49fe396d 100644 --- a/framework/generated/vulkan_generators/vulkan_export_json_consumer_body_generator.py +++ b/framework/generated/vulkan_generators/vulkan_export_json_consumer_body_generator.py @@ -138,6 +138,13 @@ def need_feature_generation(self): def generate_feature(self): """Performs C++ code generation for the feature.""" first = True + + # TODO: Each code generator is passed a blacklist like framework\generated\vulkan_generators\blacklists.json + # of functions and structures not to generate code for. Once the feature is implemented, the following can be + # replaced with adding vkCreateRayTracingPipelinesKHR in corresponding blacklist. + if 'vkCreateRayTracingPipelinesKHR' in self.APICALL_BLACKLIST: + self.APICALL_BLACKLIST.remove('vkCreateRayTracingPipelinesKHR') + for cmd in self.get_filtered_cmd_names(): if not cmd in self.customImplementationRequired: info = self.feature_cmd_params[cmd] diff --git a/framework/generated/vulkan_generators/vulkan_export_json_consumer_header_generator.py b/framework/generated/vulkan_generators/vulkan_export_json_consumer_header_generator.py index 68371d25dd..0dc59736c6 100644 --- a/framework/generated/vulkan_generators/vulkan_export_json_consumer_header_generator.py +++ b/framework/generated/vulkan_generators/vulkan_export_json_consumer_header_generator.py @@ -86,6 +86,13 @@ def __init__( def generate_feature(self): """Performs C++ code generation for the feature.""" first = True + + # TODO: Each code generator is passed a blacklist like framework\generated\vulkan_generators\blacklists.json + # of functions and structures not to generate code for. Once the feature is implemented, the following can be + # replaced with adding vkCreateRayTracingPipelinesKHR in corresponding blacklist. + if 'vkCreateRayTracingPipelinesKHR' in self.APICALL_BLACKLIST: + self.APICALL_BLACKLIST.remove('vkCreateRayTracingPipelinesKHR') + for cmd in self.get_filtered_cmd_names(): if cmd not in self.customImplementationRequired: info = self.feature_cmd_params[cmd]