diff --git a/.github/workflows/rebase.yml b/.github/workflows/rebase.yml index a0b7de74..270e9e2b 100644 --- a/.github/workflows/rebase.yml +++ b/.github/workflows/rebase.yml @@ -7,7 +7,6 @@ jobs: name: Rebase if: github.event.issue.pull_request != '' && contains(github.event.comment.body, '/rebase') && (github.event.comment.author_association == 'OWNER' || - github.event.comment.author_association == 'MEMBER' || github.event.comment.author_association == 'COLLABORATOR') runs-on: ubuntu-latest steps: diff --git a/cmake/XglCompileDefinitions.cmake b/cmake/XglCompileDefinitions.cmake index 703ecb70..9a04ed2f 100644 --- a/cmake/XglCompileDefinitions.cmake +++ b/cmake/XglCompileDefinitions.cmake @@ -88,6 +88,12 @@ macro(xgl_set_compile_definitions) endif() #endif +#if VKI_GPU_DECOMPRESS + if(VKI_GPU_DECOMPRESS) + target_compile_definitions(xgl PRIVATE VKI_GPU_DECOMPRESS) + endif() +#endif + #if VKI_EXPOSE_EXT_CONDITIONAL_RENDERING if(VKI_EXPOSE_EXT_CONDITIONAL_RENDERING) target_compile_definitions(xgl PRIVATE VKI_EXPOSE_EXT_CONDITIONAL_RENDERING) diff --git a/cmake/XglHelper.cmake b/cmake/XglHelper.cmake index 7c3d2414..899b3c5b 100644 --- a/cmake/XglHelper.cmake +++ b/cmake/XglHelper.cmake @@ -24,43 +24,6 @@ ####################################################################################################################### include_guard() -### Helper Macros ##################################################################################################### -macro(target_find_headers _target) - get_target_property(${_target}_INCLUDES_DIRS ${_target} INCLUDE_DIRECTORIES) - - if(${_target}_INCLUDES_DIRS) - foreach(_include_dir IN ITEMS ${${_target}_INCLUDES_DIRS}) - file(GLOB_RECURSE _include_files - LIST_DIRECTORIES false - "${_include_dir}/*.h" - "${_include_dir}/*.hpp" - ) - - list(APPEND ${_target}_INCLUDES ${_include_files}) - endforeach() - - target_sources(${_target} PRIVATE ${${_target}_INCLUDES}) - endif() -endmacro() - -# Source Groups Helper ############################################################################# -# This helper creates source groups for generators that support them. This is primarily MSVC and -# XCode, but there are other generators that support IDE project files. -# -# Note: this only adds files that have been added to the target's SOURCES property. To add headers -# to this list, be sure that you call target_find_headers before you call target_source_groups. -macro(target_source_groups _target) - get_target_property(${_target}_SOURCES ${_target} SOURCES) - foreach(_source IN ITEMS ${${_target}_SOURCES}) - set(_source ${_source}) - get_filename_component(_source_path "${_source}" ABSOLUTE) - file(RELATIVE_PATH _source_path_rel "${PROJECT_SOURCE_DIR}" "${_source_path}") - get_filename_component(_source_path_rel "${_source_path_rel}" DIRECTORY) - string(REPLACE "/" "\\" _group_path "${_source_path_rel}") - source_group("${_group_path}" FILES "${_source}") - endforeach() -endmacro() - macro(xgl_append_common_sanitizer_flags) if(NOT MSVC) # Append -fno-omit-frame-pointer and turn on debug info to get better stack traces. diff --git a/cmake/XglOptions.cmake b/cmake/XglOptions.cmake index 94c60e6d..83fc9bdb 100644 --- a/cmake/XglOptions.cmake +++ b/cmake/XglOptions.cmake @@ -52,12 +52,8 @@ macro(xgl_options) option(VKI_KHR_SHADER_SUBGROUP_EXTENDED_TYPES "Build vulkan with KHR_SHADER_SUBGROUP_EXTENDED_TYPES" OFF) #endif -#if VKI_EXPOSE_SW_DECOMPRESS - option(VKI_EXPOSE_SW_DECOMPRESS "Expose SW_DECOMPRESS" OFF) -#endif - -#if VKI_3RD_PARTY_IP_PROPERTY_ID - option(VKI_3RD_PARTY_IP_PROPERTY_ID "Build vulkan with 3RD_PARTY_IP_PROPERTY_ID" OFF) +#if VKI_GPU_DECOMPRESS + option(VKI_GPU_DECOMPRESS "Build vulkan with GPU_DECOMPRESS" OFF) #endif #if VKI_EXT_EXTENDED_DYNAMIC_STATE diff --git a/cmake/XglOverrides.cmake b/cmake/XglOverrides.cmake index 19cbfb3a..a59cdeb4 100644 --- a/cmake/XglOverrides.cmake +++ b/cmake/XglOverrides.cmake @@ -94,6 +94,12 @@ macro(xgl_get_path) set(XGL_PAL_PATH ${PROJECT_SOURCE_DIR}/../pal CACHE PATH "Specify the path to the PAL project.") endif() +#if VKI_GPU_DECOMPRESS + if(VKI_GPU_DECOMPRESS) + set(XGL_GPUTEXDECODER_PATH ${PROJECT_SOURCE_DIR}/icd/imported/gputexdecoder CACHE PATH "Specify the path to the gpu texture decoe project.") + endif() +#endif + # VKGC path if (EXISTS ${PROJECT_SOURCE_DIR}/../llpc/CMakeLists.txt) # On github, the default repo name is llpc instead of compiler @@ -162,10 +168,6 @@ macro(xgl_overrides_pal) # Dri3 set(PAL_BUILD_DRI3 ${BUILD_DRI3_SUPPORT} CACHE BOOL "PAL build with Dri3 enabled" FORCE) -#if VKI_3RD_PARTY_IP_PROPERTY_ID - set(PAL_3RD_PARTY_IP_PROPERTY_ID ${VKI_3RD_PARTY_IP_PROPERTY_ID}) -#endif - if(EXISTS ${XGL_METROHASH_PATH}) set(PAL_METROHASH_PATH ${XGL_METROHASH_PATH} CACHE PATH "${PROJECT_NAME} override." FORCE) endif() diff --git a/icd/CMakeLists.txt b/icd/CMakeLists.txt index 80d9dcdf..79f38145 100644 --- a/icd/CMakeLists.txt +++ b/icd/CMakeLists.txt @@ -46,6 +46,12 @@ if (BUILD_WAYLAND_SUPPORT) target_include_directories(xgl PUBLIC ${WAYLAND_INCLUDE_DIRS}) endif() +#if VKI_GPU_DECOMPRESS +if (VKI_GPU_DECOMPRESS) + target_include_directories(xgl PRIVATE ${XGL_GPUTEXDECODER_PATH}) +endif() +#endif + target_include_directories(xgl PRIVATE ${CMAKE_CURRENT_SOURCE_DIR} api @@ -56,6 +62,13 @@ target_include_directories(xgl PRIVATE # PAL add_subdirectory(${XGL_PAL_PATH} ${PROJECT_BINARY_DIR}/pal) +#if VKI_GPU_DECOMPRESS +# GPU Texture Decode +if (VKI_GPU_DECOMPRESS) + add_subdirectory(${XGL_GPUTEXDECODER_PATH} ${PROJECT_BINARY_DIR}/gputexdecoder) +endif() +#endif + # XGL cache creator tool if(XGL_BUILD_CACHE_CREATOR) if(NOT ICD_BUILD_LLPC) @@ -136,6 +149,14 @@ target_sources(xgl PRIVATE api/icd_main.cpp ) +#if VKI_GPU_DECOMPRESS +if(VKI_GPU_DECOMPRESS) + target_sources(xgl PRIVATE + api/appopt/gpu_decode_layer.cpp + ) +endif() +#endif + if(ICD_BUILD_LLPC) target_sources(xgl PRIVATE api/compiler_solution_llpc.cpp @@ -273,8 +294,6 @@ target_sources(xgl PRIVATE layers/vk_layer_switchable_graphics.cpp ) -### ICD Android interface ###################################################### - ### Link Libraries ##################################################################################################### if (UNIX) target_link_libraries(xgl PRIVATE dl c stdc++ ${CMAKE_DL_LIBS} pthread) @@ -318,6 +337,12 @@ target_link_libraries(xgl PRIVATE vkgc) target_link_libraries(xgl PRIVATE pal) target_link_libraries(xgl PRIVATE khronos_vulkan_interface) +#if VKI_GPU_DECOMPRESS +if(VKI_GPU_DECOMPRESS) + target_link_libraries(xgl PRIVATE gputexdecoder) +endif() +#endif + ### XGL cache_support #### add_library(xgl_cache_support INTERFACE) @@ -332,12 +357,6 @@ target_link_libraries(xgl_cache_support INTERFACE pal) target_link_libraries(xgl PRIVATE xgl_cache_support) -### Visual Studio Filters ############################################################################################## -target_find_headers(xgl) -if(MSVC) - target_source_groups(xgl) -endif() - ### ICD loader configuration ########################################################################################### if(UNIX) include(GNUInstallDirs) diff --git a/icd/Loader/LunarG/Lnx/amd-icd.json b/icd/Loader/LunarG/Lnx/amd-icd.json index 9bc02e29..64ae431d 100644 --- a/icd/Loader/LunarG/Lnx/amd-icd.json +++ b/icd/Loader/LunarG/Lnx/amd-icd.json @@ -2,13 +2,13 @@ "file_format_version": "1.0.0", "ICD": { "library_path": "@AMDVLK_INSTALL_PATH@/amdvlk@ISABITS@.so", - "api_version": "1.2.182" + "api_version": "1.2.185" }, "layer": { "name": "VK_LAYER_AMD_switchable_graphics_@ISABITS@", "type": "GLOBAL", "library_path": "@AMDVLK_INSTALL_PATH@/amdvlk@ISABITS@.so", - "api_version": "1.2.182", + "api_version": "1.2.185", "implementation_version": "1", "description": "AMD switchable graphics layer", "functions": { diff --git a/icd/api/app_resource_optimizer.cpp b/icd/api/app_resource_optimizer.cpp index 68a54f73..1d53326f 100644 --- a/icd/api/app_resource_optimizer.cpp +++ b/icd/api/app_resource_optimizer.cpp @@ -423,6 +423,25 @@ void ResourceOptimizer::BuildAppProfile() m_appProfile.entries[i].action.resourceCreate.dccMode = DccMode::DccEnableMode; } } + else if (appProfile == AppProfile::Rage2) + { + // Disable DCC for resource causing corruption + if (gfxIpLevel == Pal::GfxIpLevel::GfxIp10_3) + { + i = m_appProfile.entryCount++; + m_appProfile.entries[i].pattern.match.apiHash = true; + m_appProfile.entries[i].pattern.targetKey.apiHash = 0xb92ea6fe16e91aba; + m_appProfile.entries[i].action.resourceCreate.apply.dccMode = true; + m_appProfile.entries[i].action.resourceCreate.dccMode = DccMode::DccDisableMode; + + // This resource is just for Renderdoc + i = m_appProfile.entryCount++; + m_appProfile.entries[i].pattern.match.apiHash = true; + m_appProfile.entries[i].pattern.targetKey.apiHash = 0x111fa3cb932fb5fa; + m_appProfile.entries[i].action.resourceCreate.apply.dccMode = true; + m_appProfile.entries[i].action.resourceCreate.dccMode = DccMode::DccDisableMode; + } + } } #if ICD_RUNTIME_APP_PROFILE diff --git a/icd/api/app_shader_optimizer.cpp b/icd/api/app_shader_optimizer.cpp index 5b24b1b3..4242272c 100644 --- a/icd/api/app_shader_optimizer.cpp +++ b/icd/api/app_shader_optimizer.cpp @@ -78,7 +78,7 @@ void ShaderOptimizer::ApplyProfileToShaderCreateInfo( const PipelineProfile& profile, const PipelineOptimizerKey& pipelineKey, ShaderStage shaderStage, - PipelineShaderOptionsPtr options) + PipelineShaderOptionsPtr options) const { for (uint32_t entry = 0; entry < profile.entryCount; ++entry) { @@ -220,7 +220,7 @@ void ShaderOptimizer::ApplyProfileToShaderCreateInfo( void ShaderOptimizer::OverrideShaderCreateInfo( const PipelineOptimizerKey& pipelineKey, ShaderStage shaderStage, - PipelineShaderOptionsPtr options) + PipelineShaderOptionsPtr options) const { ApplyProfileToShaderCreateInfo(m_appProfile, pipelineKey, shaderStage, options); @@ -237,7 +237,7 @@ void ShaderOptimizer::OverrideGraphicsPipelineCreateInfo( const PipelineOptimizerKey& pipelineKey, VkShaderStageFlagBits shaderStages, Pal::GraphicsPipelineCreateInfo* pPalCreateInfo, - Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos) + Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos) const { ApplyProfileToGraphicsPipelineCreateInfo( m_appProfile, pipelineKey, shaderStages, pPalCreateInfo, pGraphicsShaderInfos); @@ -254,7 +254,7 @@ void ShaderOptimizer::OverrideGraphicsPipelineCreateInfo( // ===================================================================================================================== void ShaderOptimizer::OverrideComputePipelineCreateInfo( const PipelineOptimizerKey& pipelineKey, - Pal::DynamicComputeShaderInfo* pDynamicCompueShaderInfo) + Pal::DynamicComputeShaderInfo* pDynamicCompueShaderInfo) const { ApplyProfileToComputePipelineCreateInfo(m_appProfile, pipelineKey, pDynamicCompueShaderInfo); @@ -289,14 +289,14 @@ ShaderOptimizer::~ShaderOptimizer() // ===================================================================================================================== void ShaderOptimizer::ApplyProfileToDynamicComputeShaderInfo( const ShaderProfileAction& action, - Pal::DynamicComputeShaderInfo* pComputeShaderInfo) + Pal::DynamicComputeShaderInfo* pComputeShaderInfo) const { } // ===================================================================================================================== void ShaderOptimizer::ApplyProfileToDynamicGraphicsShaderInfo( const ShaderProfileAction& action, - Pal::DynamicGraphicsShaderInfo* pGraphicsShaderInfo) + Pal::DynamicGraphicsShaderInfo* pGraphicsShaderInfo) const { if (action.dynamicShaderInfo.apply.cuEnableMask) @@ -311,7 +311,7 @@ void ShaderOptimizer::ApplyProfileToGraphicsPipelineCreateInfo( const PipelineOptimizerKey& pipelineKey, VkShaderStageFlagBits shaderStages, Pal::GraphicsPipelineCreateInfo* pPalCreateInfo, - Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos) + Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos) const { for (uint32_t entry = 0; entry < profile.entryCount; ++entry) { @@ -375,7 +375,7 @@ void ShaderOptimizer::ApplyProfileToGraphicsPipelineCreateInfo( void ShaderOptimizer::ApplyProfileToComputePipelineCreateInfo( const PipelineProfile& profile, const PipelineOptimizerKey& pipelineKey, - Pal::DynamicComputeShaderInfo* pDynamicComputeShaderInfo) + Pal::DynamicComputeShaderInfo* pDynamicComputeShaderInfo) const { for (uint32_t entry = 0; entry < profile.entryCount; ++entry) { @@ -400,7 +400,7 @@ void ShaderOptimizer::ApplyProfileToComputePipelineCreateInfo( // ===================================================================================================================== Pal::ShaderHash ShaderOptimizer::GetFirstMatchingShaderHash( const PipelineProfilePattern& pattern, - const PipelineOptimizerKey& pipelineKey) + const PipelineOptimizerKey& pipelineKey) const { for (uint32_t stage = 0; stage < ShaderStageCount; ++stage) { @@ -427,7 +427,7 @@ Pal::ShaderHash ShaderOptimizer::GetFirstMatchingShaderHash( // ===================================================================================================================== bool ShaderOptimizer::ProfilePatternMatchesPipeline( const PipelineProfilePattern& pattern, - const PipelineOptimizerKey& pipelineKey) + const PipelineOptimizerKey& pipelineKey) const { if (pattern.match.always) { @@ -733,7 +733,7 @@ void ShaderOptimizer::BuildAppProfileLlpc() void ShaderOptimizer::PrintProfileEntryMatch( const PipelineProfile& profile, uint32_t index, - const PipelineOptimizerKey& key) + const PipelineOptimizerKey& key) const { Util::MutexAuto lock(&m_printMutex); diff --git a/icd/api/appopt/gpu_decode_layer.cpp b/icd/api/appopt/gpu_decode_layer.cpp new file mode 100644 index 00000000..1601022d --- /dev/null +++ b/icd/api/appopt/gpu_decode_layer.cpp @@ -0,0 +1,348 @@ +/* + *********************************************************************************************************************** + * + * Copyright (c) 2020-2021 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"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + **********************************************************************************************************************/ +/** +*********************************************************************************************************************** +* @file gpu_decode_layer.cpp +* @brief Implementation of gpu decode layer. +*********************************************************************************************************************** +*/ +#if VKI_GPU_DECOMPRESS +#include "gpu_decode_layer.h" +#include "include/vk_image.h" +#include "palImage.h" +#include "palHashMapImpl.h" +#include "palListImpl.h" +#include "palUtil.h" +#include "palInlineFuncs.h" +#include "include/vk_buffer.h" +#include "include/vk_utils.h" +#include "include/vk_cmdbuffer.h" +#include "include/vk_device.h" + +namespace GpuTexDecoder +{ + Pal::Result ClientCreateInternalComputePipeline( + const DeviceInitInfo& initInfo, + const CompileTimeConstants& constInfo, + const PipelineBuildInfo& buildInfo, + Pal::IPipeline** ppResultPipeline, + void** ppResultMemory) + { + VkResult result = VK_SUCCESS; + vk::Device* pDevice = reinterpret_cast(initInfo.pClientUserData); + VkSpecializationMapEntry mapEntries[4] = + { + // local_thread_x + { + 0, + 0, + sizeof(uint32_t) + }, + + // local_thread_y + { + 1, + 1 * sizeof(uint32_t), + sizeof(uint32_t) + }, + + // isSrgb Format + { + 2, + 2 * sizeof(uint32_t), + sizeof(uint32_t) + }, + + // isBufferTexture + { + 3, + 3 * sizeof(uint32_t), + sizeof(uint32_t) + } + + }; + + VkSpecializationInfo specializationInfo = + { + constInfo.numConstants, + &mapEntries[0], + constInfo.numConstants * sizeof(uint32_t), + constInfo.pConstants + }; + + Vkgc::ResourceMappingRootNode rootNode = {}; + Vkgc::ResourceMappingNode nodes[GpuTexDecoder::AstcInternalPipelineNodes] = {}; + if (buildInfo.shaderType == GpuTexDecoder::InternalTexConvertCsType::ConvertASTCToRGBA8) + { + GpuTexDecoder::GpuDecodeMappingNode* pDecodeNode = buildInfo.pUserDataNodes; + for (size_t index = 0; index < GpuTexDecoder::AstcInternalPipelineNodes; index++) + { + if (pDecodeNode[index].nodeType == GpuTexDecoder::NodeType::Image) + { + nodes[index].type = Vkgc::ResourceMappingNodeType::DescriptorResource; + nodes[index].sizeInDwords = pDecodeNode[index].sizeInDwords; + nodes[index].offsetInDwords = pDecodeNode[index].offsetInDwords; + nodes[index].srdRange.binding = pDecodeNode[index].binding; + nodes[index].srdRange.set = pDecodeNode[index].set; + } + else + { + Vkgc::ResourceMappingNodeType vkgcType = + (pDecodeNode[index].nodeType == GpuTexDecoder::NodeType::Buffer) ? + Vkgc::ResourceMappingNodeType::DescriptorBuffer : + Vkgc::ResourceMappingNodeType::DescriptorTexelBuffer; + nodes[index].type = vkgcType; + nodes[index].sizeInDwords = pDecodeNode[index].sizeInDwords; + nodes[index].offsetInDwords = pDecodeNode[index].offsetInDwords; + nodes[index].srdRange.binding = pDecodeNode[index].binding; + nodes[index].srdRange.set = pDecodeNode[index].set; + } + } + + rootNode.node.type = Vkgc::ResourceMappingNodeType::DescriptorTableVaPtr; + rootNode.node.offsetInDwords = 0; + rootNode.node.sizeInDwords = 1; + rootNode.node.tablePtr.nodeCount = GpuTexDecoder::AstcInternalPipelineNodes; + rootNode.node.tablePtr.pNext = &nodes[0]; + rootNode.visibility = Vkgc::ShaderStageComputeBit; + } + + Vkgc::BinaryData spvBin = { buildInfo.code.spvSize, buildInfo.code.pSpvCode }; + + result = pDevice->CreateInternalComputePipeline(buildInfo.code.spvSize, + static_cast(buildInfo.code.pSpvCode), + buildInfo.nodeCount, + &rootNode, + 0, + false,//forceWave64, + &specializationInfo, + &pDevice->GetInternalTexDecodePipeline()); + + *ppResultPipeline = pDevice->GetInternalTexDecodePipeline().pPipeline[0]; + + return result == VK_SUCCESS ? Pal::Result::Success : Pal::Result::ErrorUnknown; + } +} + +namespace vk +{ +// ===================================================================================================================== +GpuDecoderLayer::GpuDecoderLayer( + Device* pDevice) + : + m_pDevice(pDevice) +{ +} + +// ===================================================================================================================== +GpuDecoderLayer::~GpuDecoderLayer() +{ + if(m_pGpuTexDecoder != nullptr) + { + m_pDevice->VkInstance()->FreeMem(m_pGpuTexDecoder); + m_pGpuTexDecoder = nullptr; + } +} + +VkResult GpuDecoderLayer::Init(Device* pDevice) +{ + VkResult result = VK_SUCCESS; + + void* pMemory = m_pDevice->VkInstance()->AllocMem( + sizeof(GpuTexDecoder::Device), + VK_DEFAULT_MEM_ALIGN, + VK_SYSTEM_ALLOCATION_SCOPE_DEVICE); + + if (pMemory == nullptr) + { + result = VK_ERROR_OUT_OF_HOST_MEMORY; + } + + if (result == VK_SUCCESS) + { + GpuTexDecoder::DeviceInitInfo initInfo = {}; + initInfo.pDeviceProperties = &pDevice->VkPhysicalDevice(DefaultDeviceIndex)->PalProperties(); + initInfo.gpuIdx = DefaultDeviceIndex; + initInfo.pClientUserData = pDevice; + initInfo.pPalDevice = pDevice->PalDevice(DefaultDeviceIndex); + initInfo.pPlatform = pDevice->VkInstance()->PalPlatform(); + + m_pGpuTexDecoder = VK_PLACEMENT_NEW(pMemory) GpuTexDecoder::Device(); + m_pGpuTexDecoder->Init(initInfo); + } + + return result; +} + +namespace entry +{ +namespace gpuDecoderWapper +{ +// ===================================================================================================================== +VKAPI_ATTR void VKAPI_CALL vkCmdCopyImage( + VkCommandBuffer cmdBuffer, + VkImage srcImage, + VkImageLayout srcImageLayout, + VkImage dstImage, + VkImageLayout dstImageLayout, + uint32_t regionCount, + const VkImageCopy* pRegions) +{ + CmdBuffer* pCmdBuffer = ApiCmdBuffer::ObjectFromHandle(cmdBuffer); + Device* pDevice = pCmdBuffer->VkDevice(); + GpuDecoderLayer* pDecodeWrapper = pDevice->GetGpuDecoderLayer(); + + const Image* const pSrcImage = Image::ObjectFromHandle(srcImage); + const Image* const pDstImage = Image::ObjectFromHandle(dstImage); + + const Pal::SwizzledFormat srcFormat = VkToPalFormat(pSrcImage->GetFormat(), pDevice->GetRuntimeSettings()); + const Pal::SwizzledFormat dstFormat = VkToPalFormat(pDstImage->GetFormat(), pDevice->GetRuntimeSettings()); + + if (Formats::IsASTCFormat(pDstImage->GetFormat())) + { + VK_ASSERT(Formats::IsASTCFormat(pDstImage->GetFormat())); + uint32_t maxObj = pCmdBuffer->EstimateMaxObjectsOnVirtualStack(sizeof(Pal::ImageCopyRegion)); + + const auto maxRegions = Util::Max(maxObj, MaxPalAspectsPerMask); + auto regionBatch = Util::Min(regionCount * MaxPalAspectsPerMask, maxRegions); + + VirtualStackFrame virtStackFrame(pCmdBuffer->GetStackAllocator()); + Pal::ImageCopyRegion* pPalRegions = + virtStackFrame.AllocArray(regionBatch); + + VkFormat format = pDstImage->GetFormat(); + AstcMappedInfo mapInfo = {}; + Formats::GetAstcMappedInfo(format, &mapInfo); + uint32_t const_data[4] = + { + // local_thread_x + mapInfo.wScale, + // local_thread_y + mapInfo.hScale, + // is srgb + pDecodeWrapper->isAstcSrgbaFormat(format), + // is buffer copy + false + }; + + GpuTexDecoder::CompileTimeConstants constInfo = {}; + constInfo.numConstants = 4; + constInfo.pConstants = const_data; + + for (uint32_t regionIdx = 0; regionIdx < regionCount;) + { + uint32_t palRegionCount = 0; + + while ((regionIdx < regionCount) && + (palRegionCount <= (regionBatch - MaxPalAspectsPerMask))) + { + VkToPalImageCopyRegion(pRegions[regionIdx], srcFormat.format, dstFormat.format, + pPalRegions, &palRegionCount); + + ++regionIdx; + } + + pDevice->GetGpuDecoderLayer()->GetTexDecoder()->GpuDecodeImage( + GpuTexDecoder::InternalTexConvertCsType::ConvertASTCToRGBA8, + pCmdBuffer->PalCmdBuffer(DefaultDeviceIndex), + pSrcImage->PalImage(DefaultDeviceIndex), + pDstImage->PalImage(DefaultDeviceIndex), + regionCount, pPalRegions, constInfo); + } + + virtStackFrame.FreeArray(pPalRegions); + } + else + { + DECODER_WAPPER_CALL_NEXT_LAYER(vkCmdCopyImage(cmdBuffer, + srcImage, + srcImageLayout, + dstImage, + dstImageLayout, + regionCount, + pRegions)); + } +} + +// ==================================================================================================================== +VKAPI_ATTR VkResult VKAPI_CALL vkCreateImage( + VkDevice device, + const VkImageCreateInfo* pCreateInfo, + const VkAllocationCallbacks* pAllocator, + VkImage* pImage) +{ + VkResult vkResult = VK_SUCCESS; + VkFormat format = pCreateInfo->format; + Device* pDevice = ApiDevice::ObjectFromHandle(device); + GpuDecoderLayer* pDecodeWrapper = pDevice->GetGpuDecoderLayer(); + + if (Formats::IsASTCFormat(format) && + (pCreateInfo->usage == VK_IMAGE_USAGE_TRANSFER_SRC_BIT)) + { + AstcMappedInfo mapInfo = {}; + Formats::GetAstcMappedInfo(format, &mapInfo); + + VkImageCreateInfo astcSrcInfo = *pCreateInfo; + VkExtent3D extent = + { + (astcSrcInfo.extent.width + mapInfo.wScale - 1) / mapInfo.wScale, + (astcSrcInfo.extent.height + mapInfo.hScale - 1) / mapInfo.hScale, + astcSrcInfo.extent.depth + }; + + astcSrcInfo.format = VK_FORMAT_R32G32B32A32_UINT; + astcSrcInfo.extent = extent; + vkResult = DECODER_WAPPER_CALL_NEXT_LAYER(vkCreateImage)(device, + &astcSrcInfo, + pAllocator, + pImage); + + } + else + { + vkResult = DECODER_WAPPER_CALL_NEXT_LAYER(vkCreateImage)(device, + pCreateInfo, + pAllocator, + pImage); + } + + return vkResult; +} + +}// namespace gpuDecoderWapper +}// namespace entry + +// ===================================================================================================================== +void GpuDecoderLayer::OverrideDispatchTable( + DispatchTable* pDispatchTable) +{ + // Save current device dispatch table to use as the next layer. + m_nextLayer = *pDispatchTable; + + DECODER_WAPPER_OVERRIDE_ENTRY(vkCreateImage); + DECODER_WAPPER_OVERRIDE_ENTRY(vkCmdCopyImage); +} +} // namespace vk +#endif /* VKI_GPU_DECOMPRESS */ diff --git a/icd/api/appopt/gpu_decode_layer.h b/icd/api/appopt/gpu_decode_layer.h new file mode 100644 index 00000000..a1c7ffd1 --- /dev/null +++ b/icd/api/appopt/gpu_decode_layer.h @@ -0,0 +1,85 @@ +/* + *********************************************************************************************************************** + * + * Copyright (c) 2020-2021 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"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + **********************************************************************************************************************/ +/** +*********************************************************************************************************************** +* @file gpu_decode_layer.h +* @brief Declaration of gpu decode layer for compressed texture/image +*********************************************************************************************************************** +*/ + +#if VKI_GPU_DECOMPRESS +#ifndef __GPU_DECODE_LAYER_H +#define __GPU_DECODE_LAYER_H + +#pragma once +#include "opt_layer.h" +#include "include/vk_alloccb.h" +#include "include/vk_conv.h" +#include "include/vk_private_data_slot.h" +#include "palList.h" +#include "gpuTexDecoder.h" + +namespace vk +{ + +// ===================================================================================================================== +// GPU Decoder Wrapper +class GpuDecoderLayer final : public OptLayer +{ +public: + GpuDecoderLayer(Device* pDevice); + ~GpuDecoderLayer(); + VkResult Init(Device* pDevice); + + virtual void OverrideDispatchTable(DispatchTable* pDispatchTable) override; + VK_INLINE GpuTexDecoder::Device* GetTexDecoder() + { + return m_pGpuTexDecoder; + } + + VK_INLINE bool isAstcSrgbaFormat(VkFormat format) + { + return Formats::IsASTCFormat(format) && + (static_cast(format) % 2 == 0); + } + +private: + Device* m_pDevice; + GpuTexDecoder::Device* m_pGpuTexDecoder; + PAL_DISALLOW_COPY_AND_ASSIGN(GpuDecoderLayer); +}; + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +#define DECODER_WAPPER_OVERRIDE_ALIAS(entry_name, func_name) \ + pDispatchTable->OverrideEntryPoints()->entry_name = vk::entry::gpuDecoderWapper::func_name; + +#define DECODER_WAPPER_OVERRIDE_ENTRY(entry_name) DECODER_WAPPER_OVERRIDE_ALIAS(entry_name, entry_name) + +#define DECODER_WAPPER_CALL_NEXT_LAYER(entry_name) \ + pDecodeWrapper->GetNextLayer()->GetEntryPoints().entry_name + +} // namespace vk +#endif /* __GPU_DECODE_LAYER_H */ +#endif /* VKI_GPU_DECOMPRESS */ diff --git a/icd/api/compiler_solution_llpc.cpp b/icd/api/compiler_solution_llpc.cpp index 2c0c5654..ba9c9e5c 100644 --- a/icd/api/compiler_solution_llpc.cpp +++ b/icd/api/compiler_solution_llpc.cpp @@ -298,14 +298,12 @@ VkResult CompilerSolutionLlpc::CreateGraphicsPipelineBinary( GraphicsPipelineBinaryCreateInfo* pCreateInfo, size_t* pPipelineBinarySize, const void** ppPipelineBinary, - uint32_t rasterizationStream, Vkgc::PipelineShaderInfo** ppShadersInfo, void* pPipelineDumpHandle, uint64_t pipelineHash, int64_t* pCompileTime) { VK_IGNORE(pDevice); - VK_IGNORE(rasterizationStream); VK_IGNORE(pipelineHash); const RuntimeSettings& settings = m_pPhysicalDevice->GetRuntimeSettings(); auto pInstance = m_pPhysicalDevice->Manager()->VkInstance(); diff --git a/icd/api/graphics_pipeline_common.cpp b/icd/api/graphics_pipeline_common.cpp index b436f2aa..7c99fbba 100644 --- a/icd/api/graphics_pipeline_common.cpp +++ b/icd/api/graphics_pipeline_common.cpp @@ -23,6 +23,7 @@ * **********************************************************************************************************************/ +#include "include/app_shader_optimizer.h" #include "include/graphics_pipeline_common.h" #include "include/vk_cmdbuffer.h" #include "include/vk_device.h" @@ -115,16 +116,134 @@ constexpr uint32_t FoiDynamicStatesMask = 0 | (1 << static_cast(DynamicStatesInternal::ColorWriteEnableExt)); // ===================================================================================================================== -static VK_INLINE bool IsDynamicStateEnabled( - const uint32_t dynamicStateFlags, - const DynamicStatesInternal internalState) +// Helper function used to check whether a specific dynamic state is set +static bool IsDynamicStateEnabled(const uint32_t dynamicStateFlags, const DynamicStatesInternal internalState) { return dynamicStateFlags & (1 << static_cast(internalState)); } // ===================================================================================================================== -static VkShaderStageFlagBits GetActiveShaderStages( - const VkGraphicsPipelineCreateInfo* pGraphicsPipelineCreateInfo +// Returns true if the given VkBlendFactor factor is a dual source blend factor +static VK_INLINE bool IsDualSourceBlend(VkBlendFactor blend) +{ + switch (blend) + { + case VK_BLEND_FACTOR_SRC1_COLOR: + case VK_BLEND_FACTOR_ONE_MINUS_SRC1_COLOR: + case VK_BLEND_FACTOR_SRC1_ALPHA: + case VK_BLEND_FACTOR_ONE_MINUS_SRC1_ALPHA: + return true; + default: + return false; + } +} + +// ===================================================================================================================== +static VK_INLINE void BuildPalColorBlendStateCreateInfo( + const VkPipelineColorBlendStateCreateInfo* pColorBlendState, + Pal::ColorBlendStateCreateInfo* pInfo) +{ + const uint32_t numColorTargets = Min(pColorBlendState->attachmentCount, Pal::MaxColorTargets); + + for (uint32_t i = 0; i < numColorTargets; ++i) + { + const VkPipelineColorBlendAttachmentState& attachmentState = pColorBlendState->pAttachments[i]; + auto pBlendDst = &pInfo->targets[i]; + + pBlendDst->blendEnable = (attachmentState.blendEnable == VK_TRUE); + pBlendDst->srcBlendColor = VkToPalBlend(attachmentState.srcColorBlendFactor); + pBlendDst->dstBlendColor = VkToPalBlend(attachmentState.dstColorBlendFactor); + pBlendDst->blendFuncColor = VkToPalBlendFunc(attachmentState.colorBlendOp); + pBlendDst->srcBlendAlpha = VkToPalBlend(attachmentState.srcAlphaBlendFactor); + pBlendDst->dstBlendAlpha = VkToPalBlend(attachmentState.dstAlphaBlendFactor); + pBlendDst->blendFuncAlpha = VkToPalBlendFunc(attachmentState.alphaBlendOp); + } +} + +// ===================================================================================================================== +bool GraphicsPipelineCommon::GetDualSourceBlendEnableState( + const Device* pDevice, + const VkPipelineColorBlendStateCreateInfo* pColorBlendState, + const Pal::ColorBlendStateCreateInfo* pPalInfo) +{ + bool dualSourceBlend = false; + + bool canEnableDualSourceBlend; + if (pPalInfo != nullptr) + { + canEnableDualSourceBlend = pDevice->PalDevice(DefaultDeviceIndex)->CanEnableDualSourceBlend(*pPalInfo); + } + else + { + Pal::ColorBlendStateCreateInfo palInfo = {}; + BuildPalColorBlendStateCreateInfo(pColorBlendState, &palInfo); + canEnableDualSourceBlend = pDevice->PalDevice(DefaultDeviceIndex)->CanEnableDualSourceBlend(palInfo); + } + + if (canEnableDualSourceBlend) + { + const uint32_t numColorTargets = Min(pColorBlendState->attachmentCount, Pal::MaxColorTargets); + for (uint32_t i = 0; (i < numColorTargets) && (dualSourceBlend == false); ++i) + { + const VkPipelineColorBlendAttachmentState& attachmentState = pColorBlendState->pAttachments[i]; + + bool attachmentEnabled = false; + + if (attachmentState.blendEnable == VK_TRUE) + { + attachmentEnabled |= IsDualSourceBlend(attachmentState.srcAlphaBlendFactor); + attachmentEnabled |= IsDualSourceBlend(attachmentState.dstAlphaBlendFactor); + attachmentEnabled |= IsDualSourceBlend(attachmentState.srcColorBlendFactor); + attachmentEnabled |= IsDualSourceBlend(attachmentState.dstColorBlendFactor); + } + + dualSourceBlend |= attachmentEnabled; + } + } + + return dualSourceBlend; +} + +// ===================================================================================================================== +bool GraphicsPipelineCommon::IsSrcAlphaUsedInBlend(VkBlendFactor blend) +{ + switch (blend) + { + case VK_BLEND_FACTOR_SRC_ALPHA: + case VK_BLEND_FACTOR_ONE_MINUS_SRC_ALPHA: + case VK_BLEND_FACTOR_SRC_ALPHA_SATURATE: + case VK_BLEND_FACTOR_SRC1_ALPHA: + case VK_BLEND_FACTOR_ONE_MINUS_SRC1_ALPHA: + return true; + default: + return false; + } +} + +// ===================================================================================================================== +static VK_INLINE VkFormat GetDepthFormat( + const RenderPass* pRenderPass, + const uint32_t subpassIndex + ) +{ + return (pRenderPass != nullptr) ? + pRenderPass->GetDepthStencilAttachmentFormat(subpassIndex) : + VK_FORMAT_UNDEFINED; +} + +// ===================================================================================================================== +static VK_INLINE uint32_t GetColorAttachmentCount( + const RenderPass* pRenderPass, + const uint32_t subpassIndex +) +{ + return (pRenderPass != nullptr) ? pRenderPass->GetSubpassColorReferenceCount(subpassIndex) : + 0u; +} + +// ===================================================================================================================== +VkShaderStageFlagBits GraphicsPipelineCommon::GetActiveShaderStages( + const VkGraphicsPipelineCreateInfo* pGraphicsPipelineCreateInfo ) { VK_ASSERT(pGraphicsPipelineCreateInfo != nullptr); @@ -141,8 +260,8 @@ static VkShaderStageFlagBits GetActiveShaderStages( } // ===================================================================================================================== -static uint32_t GetDynamicStateFlags( - const VkPipelineDynamicStateCreateInfo* pDy +uint32_t GraphicsPipelineCommon::GetDynamicStateFlags( + const VkPipelineDynamicStateCreateInfo* pDy ) { uint32_t dynamicState = 0; @@ -385,13 +504,6 @@ static void BuildRasterizationState( } break; - case VK_STRUCTURE_TYPE_PIPELINE_RASTERIZATION_STATE_STREAM_CREATE_INFO_EXT: - { - const auto* pRsStream = static_cast(pNext); - - pInfo->rasterizationStream = pRsStream->rasterizationStream; - } - break; case VK_STRUCTURE_TYPE_PIPELINE_RASTERIZATION_LINE_STATE_CREATE_INFO_EXT: { const auto* pRsLine = @@ -584,16 +696,16 @@ static void BuildMultisampleState( { if (pMs != nullptr) { + pInfo->flags.customMultiSampleState = true; pInfo->flags.force1x1ShaderRate = (pMs->sampleShadingEnable || (pMs->rasterizationSamples == VK_SAMPLE_COUNT_8_BIT)); + pInfo->flags.sampleShadingEnable = pMs->sampleShadingEnable; // Sample Locations - EXTRACT_VK_STRUCTURES_1( + EXTRACT_VK_STRUCTURES_0( SampleLocations, - PipelineMultisampleStateCreateInfo, PipelineSampleLocationsStateCreateInfoEXT, - pMs, - PIPELINE_MULTISAMPLE_STATE_CREATE_INFO, + static_cast(pMs->pNext), PIPELINE_SAMPLE_LOCATIONS_STATE_CREATE_INFO_EXT) pInfo->flags.customSampleLocations = ((pPipelineSampleLocationsStateCreateInfoEXT != nullptr) && @@ -685,6 +797,7 @@ static void BuildMultisampleState( } } +// ===================================================================================================================== static void BuildDepthStencilState( const VkPipelineDepthStencilStateCreateInfo* pDs, const uint32_t dynamicStateFlags, @@ -746,73 +859,6 @@ static void BuildDepthStencilState( pInfo->immedInfo.stencilRefMasks.backOpValue = DefaultStencilOpValue; } -// ===================================================================================================================== -// Returns true if the given VkBlendFactor factor is a dual source blend factor -static VK_INLINE bool IsDualSourceBlend(VkBlendFactor blend) -{ - switch (blend) - { - case VK_BLEND_FACTOR_SRC1_COLOR: - case VK_BLEND_FACTOR_ONE_MINUS_SRC1_COLOR: - case VK_BLEND_FACTOR_SRC1_ALPHA: - case VK_BLEND_FACTOR_ONE_MINUS_SRC1_ALPHA: - return true; - default: - return false; - } -} - -// ===================================================================================================================== -static VK_INLINE VkFormat GetDepthFormat( - const RenderPass* pRenderPass, - const uint32_t subpassIndex - ) -{ - return (pRenderPass != nullptr) ? - pRenderPass->GetDepthStencilAttachmentFormat(subpassIndex) : - VK_FORMAT_UNDEFINED; -} - -// ===================================================================================================================== -static VK_INLINE uint32_t GetColorAttachmentCount( - const RenderPass* pRenderPass, - const uint32_t subpassIndex -) -{ - return (pRenderPass != nullptr) ? pRenderPass->GetSubpassColorReferenceCount(subpassIndex) : - 0u; -} - -// ===================================================================================================================== -bool GetDualSourceBlendEnableState(const VkPipelineColorBlendAttachmentState& pColorBlendAttachmentState) -{ - bool dualSourceBlend = false; - - dualSourceBlend |= IsDualSourceBlend(pColorBlendAttachmentState.srcAlphaBlendFactor); - dualSourceBlend |= IsDualSourceBlend(pColorBlendAttachmentState.dstAlphaBlendFactor); - dualSourceBlend |= IsDualSourceBlend(pColorBlendAttachmentState.srcColorBlendFactor); - dualSourceBlend |= IsDualSourceBlend(pColorBlendAttachmentState.dstColorBlendFactor); - dualSourceBlend &= (pColorBlendAttachmentState.blendEnable == VK_TRUE); - - return dualSourceBlend; -} - -// ===================================================================================================================== -bool IsSrcAlphaUsedInBlend(VkBlendFactor blend) -{ - switch (blend) - { - case VK_BLEND_FACTOR_SRC_ALPHA: - case VK_BLEND_FACTOR_ONE_MINUS_SRC_ALPHA: - case VK_BLEND_FACTOR_SRC_ALPHA_SATURATE: - case VK_BLEND_FACTOR_SRC1_ALPHA: - case VK_BLEND_FACTOR_ONE_MINUS_SRC1_ALPHA: - return true; - default: - return false; - } -} - // ===================================================================================================================== static void BuildColorBlendState( const Device* pDevice, @@ -866,7 +912,6 @@ static void BuildColorBlendState( const VkPipelineColorBlendAttachmentState& src = pCb->pAttachments[i]; auto pCbDst = &pInfo->pipeline.cbState.target[i]; - auto pBlendDst = &pInfo->blend.targets[i]; if (pRenderPass != nullptr) { @@ -897,17 +942,10 @@ static void BuildColorBlendState( blendingEnabled |= (src.blendEnable == VK_TRUE); } - - pBlendDst->blendEnable = (src.blendEnable == VK_TRUE); - pBlendDst->srcBlendColor = VkToPalBlend(src.srcColorBlendFactor); - pBlendDst->dstBlendColor = VkToPalBlend(src.dstColorBlendFactor); - pBlendDst->blendFuncColor = VkToPalBlendFunc(src.colorBlendOp); - pBlendDst->srcBlendAlpha = VkToPalBlend(src.srcAlphaBlendFactor); - pBlendDst->dstBlendAlpha = VkToPalBlend(src.dstAlphaBlendFactor); - pBlendDst->blendFuncAlpha = VkToPalBlendFunc(src.alphaBlendOp); - - dualSourceBlend |= GetDualSourceBlendEnableState(src); } + + BuildPalColorBlendStateCreateInfo(pCb, &pInfo->blend); + dualSourceBlend = GraphicsPipelineCommon::GetDualSourceBlendEnableState(pDevice, pCb, &pInfo->blend); } pInfo->pipeline.cbState.dualSourceBlendEnable = dualSourceBlend; @@ -1042,17 +1080,13 @@ static void BuildFragmentShaderState( pInfo->pLayout = PipelineLayout::ObjectFromHandle(pIn->layout); - if ((pIn->pRasterizationState->rasterizerDiscardEnable == VK_FALSE) || - IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::RasterizerDiscardEnableExt)) - { - // Build states via VkPipelineMultisampleStateCreateInfo - BuildMultisampleState(pIn->pMultisampleState, pRenderPass, subpass, dynamicStateFlags, pInfo); + // Build states via VkPipelineMultisampleStateCreateInfo + BuildMultisampleState(pIn->pMultisampleState, pRenderPass, subpass, dynamicStateFlags, pInfo); - if (GetDepthFormat(pRenderPass, subpass) != VK_FORMAT_UNDEFINED) - { - // Build states via VkPipelineDepthStencilStateCreateInfo - BuildDepthStencilState(pIn->pDepthStencilState, dynamicStateFlags, pInfo); - } + if (GetDepthFormat(pRenderPass, subpass) != VK_FORMAT_UNDEFINED) + { + // Build states via VkPipelineDepthStencilStateCreateInfo + BuildDepthStencilState(pIn->pDepthStencilState, dynamicStateFlags, pInfo); } if (IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::DepthTestEnableExt) == false) @@ -1086,41 +1120,37 @@ static void BuildFragmentOutputInterfaceState( { const RenderPass* pRenderPass = RenderPass::ObjectFromHandle(pIn->renderPass); const uint32_t subpass = pIn->subpass; - const bool rasterizerEnable = ((pIn->pRasterizationState->rasterizerDiscardEnable == VK_FALSE) || - IsDynamicStateEnabled(dynamicStateFlags, - DynamicStatesInternal::RasterizerDiscardEnableExt)); - if (rasterizerEnable && - (GetColorAttachmentCount(pRenderPass, subpass) != 0)) + pInfo->dbFormat = GetDepthFormat(pRenderPass, subpass); + + if (GetColorAttachmentCount(pRenderPass, subpass) != 0) { // Build states via VkPipelineColorBlendStateCreateInfo BuildColorBlendState( pDevice, - pIn->pColorBlendState, - pRenderPass, - subpass, - dynamicStateFlags, - pInfo); + pIn->pColorBlendState, + pRenderPass, + subpass, + dynamicStateFlags, + pInfo); } // According to the spec, VkPipelineMultisampleStateCreateInfo::alphaToCoverageEnable and alphaToOneEnable // belongs to fragment output interface section // The alpha component of the fragment's first color output is replaced with one if alphaToOneEnable is set. - if (rasterizerEnable && (pIn->pMultisampleState != nullptr)) + if (pIn->pMultisampleState != nullptr) { pInfo->pipeline.cbState.target[0].forceAlphaToOne = (pIn->pMultisampleState->alphaToOneEnable == VK_TRUE); pInfo->pipeline.cbState.alphaToCoverageEnable = (pIn->pMultisampleState->alphaToCoverageEnable == VK_TRUE); } - pInfo->dbFormat = GetDepthFormat(pRenderPass, subpass); - // According to the spec, VkPipelineDepthStencilStateCreateInfo::depthWriteEnable belongs to fragment output // interface section if ((pInfo->dbFormat != VK_FORMAT_UNDEFINED) && - rasterizerEnable && (pIn->pDepthStencilState != nullptr)) { - pInfo->immedInfo.depthStencilCreateInfo.depthWriteEnable = (pIn->pDepthStencilState->depthWriteEnable == VK_TRUE); + pInfo->immedInfo.depthStencilCreateInfo.depthWriteEnable = + (pIn->pDepthStencilState->depthWriteEnable == VK_TRUE); } BuildRenderingState(pDevice, @@ -1208,7 +1238,7 @@ static void BuildExecutablePipelineState( } if ((pInfo->immedInfo.rasterizerDiscardEnable == true) || - (pIn->pMultisampleState == nullptr) || + (pInfo->flags.customMultiSampleState == false) || ((pInfo->flags.bresenhamEnable == true) && (pInfo->flags.customSampleLocations == false))) { pInfo->msaa.coverageSamples = 1; @@ -1225,10 +1255,23 @@ static void BuildExecutablePipelineState( pInfo->immedInfo.samplePattern = {}; + pInfo->flags.sampleShadingEnable = false; + pInfo->staticStateMask &= ~(1 << static_cast(DynamicStatesInternal::SampleLocationsExt)); } +#if PAL_BUILD_GFX103 + // Both MSAA and VRS would utilize the value of PS_ITER_SAMPLES + // Thus, choose the min combiner (i.e. choose the higher quality rate) when both features are enabled + if ((pInfo->msaa.pixelShaderSamples > 1) && + (pInfo->immedInfo.vrsRateParams.flags.exposeVrsPixelsMask == 1)) + { + pInfo->immedInfo.vrsRateParams.combinerState[ + static_cast(Pal::VrsCombinerStage::PsIterSamples)] = Pal::VrsCombiner::Min; + } +#endif + pInfo->flags.bindDepthStencilObject = !(IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::StencilOpExt) || IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::StencilTestEnableExt) || @@ -1257,6 +1300,7 @@ void GraphicsPipelineCommon::BuildPipelineObjectCreateInfo( const Device* pDevice, const VkGraphicsPipelineCreateInfo* pIn, const VbBindingInfo* pVbInfo, + const GraphicsPipelineBinaryInfo* pBinInfo, GraphicsPipelineObjectCreateInfo* pInfo) { const VkGraphicsPipelineCreateInfo* pGraphicsPipelineCreateInfo = pIn; @@ -1264,22 +1308,75 @@ void GraphicsPipelineCommon::BuildPipelineObjectCreateInfo( pInfo->activeStages = GetActiveShaderStages(pGraphicsPipelineCreateInfo ); - uint32_t dynamicStateFlags = GetDynamicStateFlags(pGraphicsPipelineCreateInfo->pDynamicState + uint32_t dynamicStateFlags = GraphicsPipelineCommon::GetDynamicStateFlags( + pGraphicsPipelineCreateInfo->pDynamicState ); BuildVertexInputInterfaceState(pDevice, pIn, pVbInfo, dynamicStateFlags, false, pInfo); - BuildPreRasterizationShaderState(pDevice, pIn, dynamicStateFlags, pInfo); + BuildPreRasterizationShaderState(pDevice, + pIn, + dynamicStateFlags, + pInfo); - BuildFragmentShaderState(pDevice, pIn, dynamicStateFlags, pInfo); + const bool enableRasterization = + (pInfo->immedInfo.rasterizerDiscardEnable == false) || + IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::RasterizerDiscardEnableExt); - BuildFragmentOutputInterfaceState(pDevice, pIn, dynamicStateFlags, pInfo); + if (enableRasterization) + { + BuildFragmentShaderState(pDevice, + pIn, + dynamicStateFlags, + pInfo); + + BuildFragmentOutputInterfaceState(pDevice, pIn, dynamicStateFlags, pInfo); + } { BuildExecutablePipelineState(pDevice, pIn, dynamicStateFlags, pInfo); + + if ((pBinInfo != nullptr) && (pBinInfo->pOptimizerKey != nullptr)) + { + pDevice->GetShaderOptimizer()->OverrideGraphicsPipelineCreateInfo( + *pBinInfo->pOptimizerKey, + pInfo->activeStages, + &pInfo->pipeline, + &pInfo->immedInfo.graphicsShaderInfos); + } } } +// ===================================================================================================================== +// Build the input information for pipeline compiler to create the graphics pipeline binaries +VkResult GraphicsPipelineCommon::BuildPipelineBinaryCreateInfo( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + GraphicsPipelineBinaryCreateInfo* pBinInfo, + GraphicsPipelineShaderStageInfo* pShaderInfo, + VbBindingInfo* pVbInfo, + ShaderModuleHandle* pTempModules) +{ + PipelineCompiler* pCompiler = pDevice->GetCompiler(DefaultDeviceIndex); + + VkResult result = BuildShaderStageInfo(pDevice, + pCreateInfo->stageCount, + pCreateInfo->pStages, + [](const uint32_t inputIdx, const uint32_t stageIdx) + { + return stageIdx; + }, + pShaderInfo->stages, + pTempModules); + + if (result == VK_SUCCESS) + { + result = pCompiler->ConvertGraphicsPipelineInfo(pDevice, pCreateInfo, pShaderInfo, pBinInfo, pVbInfo); + } + + return result; +} + // ===================================================================================================================== // Generates a hash using the contents of a VkPipelineVertexInputStateCreateInfo struct // Pipeline compilation affected by: @@ -1685,9 +1782,10 @@ static void GenerateHashFromColorBlendStateCreateInfo( // - pCreateInfo->subpass uint64_t GraphicsPipelineCommon::BuildApiHash( const VkGraphicsPipelineCreateInfo* pCreateInfo, - const GraphicsPipelineObjectCreateInfo* pInfo, - Util::MetroHash::Hash* pBaseHash) + const GraphicsPipelineObjectCreateInfo* pInfo) { + Util::MetroHash::Hash baseHash; + Util::MetroHash128 baseHasher; Util::MetroHash128 apiHasher; @@ -1810,11 +1908,11 @@ uint64_t GraphicsPipelineCommon::BuildApiHash( } } - baseHasher.Finalize(reinterpret_cast(pBaseHash)); + baseHasher.Finalize(reinterpret_cast(&baseHash)); uint64_t apiHash; Util::MetroHash::Hash apiHashFull; - apiHasher.Update(*pBaseHash); + apiHasher.Update(baseHash); apiHasher.Finalize(reinterpret_cast(&apiHashFull)); apiHash = Util::MetroHash::Compact64(&apiHashFull); diff --git a/icd/api/include/app_profile.h b/icd/api/include/app_profile.h index f9df517b..1619864f 100644 --- a/icd/api/include/app_profile.h +++ b/icd/api/include/app_profile.h @@ -101,6 +101,7 @@ enum class AppProfile : uint32_t XSystemEngine, // XSystem Engine by Laminar Research UnityEngine, // Unity Engine by Unity Technologies (Default) SaschaWillemsExamples, // Vulkan Examples by Sascha Willems + Maxon, // Maxon }; struct ProfileSettings diff --git a/icd/api/include/app_shader_optimizer.h b/icd/api/include/app_shader_optimizer.h index 395c621c..bb4e5e5a 100644 --- a/icd/api/include/app_shader_optimizer.h +++ b/icd/api/include/app_shader_optimizer.h @@ -94,17 +94,17 @@ class ShaderOptimizer void OverrideShaderCreateInfo( const PipelineOptimizerKey& pipelineKey, ShaderStage shaderStage, - PipelineShaderOptionsPtr options); + PipelineShaderOptionsPtr options) const; void OverrideGraphicsPipelineCreateInfo( const PipelineOptimizerKey& pipelineKey, VkShaderStageFlagBits shaderStages, Pal::GraphicsPipelineCreateInfo* pPalCreateInfo, - Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos); + Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos) const; void OverrideComputePipelineCreateInfo( const PipelineOptimizerKey& pipelineKey, - Pal::DynamicComputeShaderInfo* pDynamicCompueShaderInfo); + Pal::DynamicComputeShaderInfo* pDynamicCompueShaderInfo) const; private: PAL_DISALLOW_COPY_AND_ASSIGN(ShaderOptimizer); @@ -113,35 +113,35 @@ class ShaderOptimizer const PipelineProfile& profile, const PipelineOptimizerKey& pipelineKey, ShaderStage shaderStage, - PipelineShaderOptionsPtr options); + PipelineShaderOptionsPtr options) const; void ApplyProfileToGraphicsPipelineCreateInfo( const PipelineProfile& profile, const PipelineOptimizerKey& pipelineKey, VkShaderStageFlagBits shaderStages, Pal::GraphicsPipelineCreateInfo* pPalCreateInfo, - Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos); + Pal::DynamicGraphicsShaderInfos* pGraphicsShaderInfos) const; void ApplyProfileToComputePipelineCreateInfo( const PipelineProfile& profile, const PipelineOptimizerKey& pipelineKey, - Pal::DynamicComputeShaderInfo* pDynamicComputeShaderInfo); + Pal::DynamicComputeShaderInfo* pDynamicComputeShaderInfo) const; void ApplyProfileToDynamicGraphicsShaderInfo( const ShaderProfileAction& action, - Pal::DynamicGraphicsShaderInfo* pGraphicsShaderInfo); + Pal::DynamicGraphicsShaderInfo* pGraphicsShaderInfo) const; void ApplyProfileToDynamicComputeShaderInfo( const ShaderProfileAction& action, - Pal::DynamicComputeShaderInfo* pComputeShaderInfo); + Pal::DynamicComputeShaderInfo* pComputeShaderInfo) const; bool ProfilePatternMatchesPipeline( const PipelineProfilePattern& pattern, - const PipelineOptimizerKey& pipelineKey); + const PipelineOptimizerKey& pipelineKey) const; Pal::ShaderHash GetFirstMatchingShaderHash( const PipelineProfilePattern& pattern, - const PipelineOptimizerKey& pipelineKey); + const PipelineOptimizerKey& pipelineKey) const; void BuildTuningProfile(); void BuildAppProfile(); @@ -154,7 +154,10 @@ class ShaderOptimizer #endif #if PAL_ENABLE_PRINTS_ASSERTS - void PrintProfileEntryMatch(const PipelineProfile& profile, uint32_t index, const PipelineOptimizerKey& key); + void PrintProfileEntryMatch( + const PipelineProfile& profile, + uint32_t index, + const PipelineOptimizerKey& key) const; #endif Device* m_pDevice; @@ -170,7 +173,7 @@ class ShaderOptimizer #endif #if PAL_ENABLE_PRINTS_ASSERTS - Util::Mutex m_printMutex; + mutable Util::Mutex m_printMutex; #endif }; diff --git a/icd/api/include/compiler_solution.h b/icd/api/include/compiler_solution.h index 0ce7c85d..908b29df 100644 --- a/icd/api/include/compiler_solution.h +++ b/icd/api/include/compiler_solution.h @@ -94,9 +94,9 @@ struct GraphicsPipelineBinaryCreateInfo PipelineOptimizerKey pipelineProfileKey; PipelineCompilerType compilerType; FreeCompilerBinary freeCompilerBinary; - Util::MetroHash::Hash basePipelineHash; PipelineCreationFeedback pipelineFeedback; PipelineCreationFeedback stageFeedback[ShaderStage::ShaderStageGfxCount]; + uint32_t rasterizationStream; }; // ===================================================================================================================== @@ -110,7 +110,6 @@ struct ComputePipelineBinaryCreateInfo PipelineOptimizerKey pipelineProfileKey; PipelineCompilerType compilerType; FreeCompilerBinary freeCompilerBinary; - Util::MetroHash::Hash basePipelineHash; PipelineCreationFeedback pipelineFeedback; PipelineCreationFeedback stageFeedback; }; @@ -160,7 +159,6 @@ class CompilerSolution GraphicsPipelineBinaryCreateInfo* pCreateInfo, size_t* pPipelineBinarySize, const void** ppPipelineBinary, - uint32_t rasterizationStream, Vkgc::PipelineShaderInfo** ppShadersInfo, void* pPipelineDumpHandle, uint64_t pipelineHash, diff --git a/icd/api/include/compiler_solution_llpc.h b/icd/api/include/compiler_solution_llpc.h index 32663748..7595481b 100644 --- a/icd/api/include/compiler_solution_llpc.h +++ b/icd/api/include/compiler_solution_llpc.h @@ -84,7 +84,6 @@ class CompilerSolutionLlpc final : public CompilerSolution GraphicsPipelineBinaryCreateInfo* pCreateInfo, size_t* pPipelineBinarySize, const void** ppPipelineBinary, - uint32_t rasterizationStream, Vkgc::PipelineShaderInfo** ppShadersInfo, void* pPipelineDumpHandle, uint64_t pipelineHash, diff --git a/icd/api/include/graphics_pipeline_common.h b/icd/api/include/graphics_pipeline_common.h index 6660a915..4690dd4b 100644 --- a/icd/api/include/graphics_pipeline_common.h +++ b/icd/api/include/graphics_pipeline_common.h @@ -36,6 +36,10 @@ namespace vk { +struct PipelineOptimizerKey; +struct GraphicsPipelineBinaryCreateInfo; +struct GraphicsPipelineShaderStageInfo; + // ===================================================================================================================== // Sample pattern structure containing pal format sample locations and sample counts // ToDo: Move this struct to different header once render_graph implementation is removed. @@ -112,7 +116,6 @@ struct GraphicsPipelineObjectCreateInfo const PipelineLayout* pLayout; uint32_t sampleCoverage; VkShaderStageFlagBits activeStages; - uint32_t rasterizationStream; VkFormat dbFormat; union @@ -124,44 +127,76 @@ struct GraphicsPipelineObjectCreateInfo uint32_t bindTriangleRasterState : 1; uint32_t bindStencilRefMasks : 1; uint32_t bindInputAssemblyState : 1; + uint32_t customMultiSampleState : 1; uint32_t customSampleLocations : 1; uint32_t force1x1ShaderRate : 1; - uint32_t reserved : 25; + uint32_t sampleShadingEnable : 1; + uint32_t reserved : 23; }; uint32_t value; - }flags; + } flags; }; // ===================================================================================================================== -// Returns true if Dual Source Blending is to be enabled based on the given ColorBlendAttachmentState -bool GetDualSourceBlendEnableState(const VkPipelineColorBlendAttachmentState& pColorBlendAttachmentState); - -// ===================================================================================================================== -// Returns true if src alpha is used in blending -bool IsSrcAlphaUsedInBlend(VkBlendFactor blend); +// Include pipeline binary information from compiler which affects information info of pipeline object +struct GraphicsPipelineBinaryInfo +{ + const PipelineOptimizerKey* pOptimizerKey; +}; // ===================================================================================================================== // The common part used by both executable graphics pipelines and graphics pipeline libraries class GraphicsPipelineCommon : public Pipeline { +public: + // Get the active shader stages through API info + static VkShaderStageFlagBits GetActiveShaderStages( + const VkGraphicsPipelineCreateInfo* pGraphicsPipelineCreateInfo + ); + + // Returns true if Dual Source Blending is to be enabled based on the given ColorBlendAttachmentState + static bool GetDualSourceBlendEnableState( + const Device* pDevice, + const VkPipelineColorBlendStateCreateInfo* pColorBlendState, + const Pal::ColorBlendStateCreateInfo* pPalInfo = nullptr); + + // Returns true if src alpha is used in blending + static bool IsSrcAlphaUsedInBlend(VkBlendFactor blend); + + // Get the dynamics states specified by API info + static uint32_t GetDynamicStateFlags( + const VkPipelineDynamicStateCreateInfo* pDy + ); + protected: - // Convert API infomation into internal pipeline create info + // Convert API information into internal create info used to create internal pipeline binary + static VkResult BuildPipelineBinaryCreateInfo( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + GraphicsPipelineBinaryCreateInfo* pBinInfo, + GraphicsPipelineShaderStageInfo* pShaderInfo, + VbBindingInfo* pVbInfo, + ShaderModuleHandle* pTempModules); + + // Convert API information into internal create info used to create internal pipeline object static void BuildPipelineObjectCreateInfo( const Device* pDevice, const VkGraphicsPipelineCreateInfo* pIn, const VbBindingInfo* pVbInfo, - GraphicsPipelineObjectCreateInfo* pInfo); + const GraphicsPipelineBinaryInfo* pBinInfo, + GraphicsPipelineObjectCreateInfo* pObjInfo); // Generates the API PSO hash using the contents of the VkGraphicsPipelineCreateInfo struct static uint64_t BuildApiHash( const VkGraphicsPipelineCreateInfo* pCreateInfo, - const GraphicsPipelineObjectCreateInfo* pInfo, - Util::MetroHash::Hash* pBaseHash); + const GraphicsPipelineObjectCreateInfo* pInfo); - GraphicsPipelineCommon(Device* const pDevice) - : Pipeline(pDevice, VK_PIPELINE_BIND_POINT_GRAPHICS) + GraphicsPipelineCommon( + Device* const pDevice) + : Pipeline( + pDevice, + VK_PIPELINE_BIND_POINT_GRAPHICS) { } - }; } diff --git a/icd/api/include/khronos/sdk-1.2/vulkan_beta.h b/icd/api/include/khronos/sdk-1.2/vulkan_beta.h index 9aebb1ab..c615bb35 100644 --- a/icd/api/include/khronos/sdk-1.2/vulkan_beta.h +++ b/icd/api/include/khronos/sdk-1.2/vulkan_beta.h @@ -134,7 +134,7 @@ typedef struct VkVideoCapabilitiesKHR { typedef struct VkPhysicalDeviceVideoFormatInfoKHR { VkStructureType sType; - const void* pNext; + void* pNext; VkImageUsageFlags imageUsage; const VkVideoProfilesKHR* pVideoProfiles; } VkPhysicalDeviceVideoFormatInfoKHR; diff --git a/icd/api/include/khronos/sdk-1.2/vulkan_core.h b/icd/api/include/khronos/sdk-1.2/vulkan_core.h index b2448fb2..8166e173 100644 --- a/icd/api/include/khronos/sdk-1.2/vulkan_core.h +++ b/icd/api/include/khronos/sdk-1.2/vulkan_core.h @@ -72,7 +72,7 @@ extern "C" { #define VK_API_VERSION_1_0 VK_MAKE_API_VERSION(0, 1, 0, 0)// Patch version should always be set to 0 // Version of this file -#define VK_HEADER_VERSION 182 +#define VK_HEADER_VERSION 185 // Complete version of this file #define VK_HEADER_VERSION_COMPLETE VK_MAKE_API_VERSION(0, 1, 2, VK_HEADER_VERSION) @@ -120,6 +120,7 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkDescriptorSet) VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkDescriptorPool) VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkFramebuffer) VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkCommandPool) +#define VK_UUID_SIZE 16U #define VK_ATTACHMENT_UNUSED (~0U) #define VK_FALSE 0U #define VK_LOD_CLAMP_NONE 1000.0F @@ -132,7 +133,6 @@ VK_DEFINE_NON_DISPATCHABLE_HANDLE(VkCommandPool) #define VK_MAX_MEMORY_TYPES 32U #define VK_MAX_MEMORY_HEAPS 16U #define VK_MAX_PHYSICAL_DEVICE_NAME_SIZE 256U -#define VK_UUID_SIZE 16U #define VK_MAX_EXTENSION_NAME_SIZE 256U #define VK_MAX_DESCRIPTION_SIZE 256U @@ -714,6 +714,7 @@ typedef enum VkStructureType { VK_STRUCTURE_TYPE_BUFFER_DEVICE_ADDRESS_CREATE_INFO_EXT = 1000244002, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TOOL_PROPERTIES_EXT = 1000245000, VK_STRUCTURE_TYPE_VALIDATION_FEATURES_EXT = 1000247000, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRESENT_WAIT_FEATURES_KHR = 1000248000, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COOPERATIVE_MATRIX_FEATURES_NV = 1000249000, VK_STRUCTURE_TYPE_COOPERATIVE_MATRIX_PROPERTIES_NV = 1000249001, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COOPERATIVE_MATRIX_PROPERTIES_NV = 1000249002, @@ -741,6 +742,7 @@ typedef enum VkStructureType { VK_STRUCTURE_TYPE_PIPELINE_EXECUTABLE_INFO_KHR = 1000269003, VK_STRUCTURE_TYPE_PIPELINE_EXECUTABLE_STATISTIC_KHR = 1000269004, VK_STRUCTURE_TYPE_PIPELINE_EXECUTABLE_INTERNAL_REPRESENTATION_KHR = 1000269005, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_ATOMIC_FLOAT_2_FEATURES_EXT = 1000273000, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_DEMOTE_TO_HELPER_INVOCATION_FEATURES_EXT = 1000276000, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_NV = 1000277000, VK_STRUCTURE_TYPE_GRAPHICS_SHADER_GROUP_CREATE_INFO_NV = 1000277001, @@ -765,6 +767,8 @@ typedef enum VkStructureType { VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_CUSTOM_BORDER_COLOR_PROPERTIES_EXT = 1000287001, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_CUSTOM_BORDER_COLOR_FEATURES_EXT = 1000287002, VK_STRUCTURE_TYPE_PIPELINE_LIBRARY_CREATE_INFO_KHR = 1000290000, + VK_STRUCTURE_TYPE_PRESENT_ID_KHR = 1000294000, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRESENT_ID_FEATURES_KHR = 1000294001, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRIVATE_DATA_FEATURES_EXT = 1000295000, VK_STRUCTURE_TYPE_DEVICE_PRIVATE_DATA_CREATE_INFO_EXT = 1000295001, VK_STRUCTURE_TYPE_PRIVATE_DATA_SLOT_CREATE_INFO_EXT = 1000295002, @@ -825,9 +829,12 @@ typedef enum VkStructureType { VK_STRUCTURE_TYPE_MEMORY_GET_ZIRCON_HANDLE_INFO_FUCHSIA = 1000364002, VK_STRUCTURE_TYPE_IMPORT_SEMAPHORE_ZIRCON_HANDLE_INFO_FUCHSIA = 1000365000, VK_STRUCTURE_TYPE_SEMAPHORE_GET_ZIRCON_HANDLE_INFO_FUCHSIA = 1000365001, - VK_STRUCTURE_TYPE_SUBPASSS_SHADING_PIPELINE_CREATE_INFO_HUAWEI = 1000369000, + VK_STRUCTURE_TYPE_SUBPASS_SHADING_PIPELINE_CREATE_INFO_HUAWEI = 1000369000, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SUBPASS_SHADING_FEATURES_HUAWEI = 1000369001, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SUBPASS_SHADING_PROPERTIES_HUAWEI = 1000369002, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_INVOCATION_MASK_FEATURES_HUAWEI = 1000370000, + VK_STRUCTURE_TYPE_MEMORY_GET_REMOTE_ADDRESS_INFO_NV = 1000371000, + VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_EXTERNAL_MEMORY_RDMA_FEATURES_NV = 1000371001, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_EXTENDED_DYNAMIC_STATE_2_FEATURES_EXT = 1000377000, VK_STRUCTURE_TYPE_SCREEN_SURFACE_CREATE_INFO_QNX = 1000378000, VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COLOR_WRITE_ENABLE_FEATURES_EXT = 1000381000, @@ -1058,6 +1065,11 @@ typedef enum VkObjectType { VK_OBJECT_TYPE_MAX_ENUM = 0x7FFFFFFF } VkObjectType; +typedef enum VkPipelineCacheHeaderVersion { + VK_PIPELINE_CACHE_HEADER_VERSION_ONE = 1, + VK_PIPELINE_CACHE_HEADER_VERSION_MAX_ENUM = 0x7FFFFFFF +} VkPipelineCacheHeaderVersion; + typedef enum VkVendorId { VK_VENDOR_ID_VIV = 0x10001, VK_VENDOR_ID_VSI = 0x10002, @@ -1068,11 +1080,6 @@ typedef enum VkVendorId { VK_VENDOR_ID_MAX_ENUM = 0x7FFFFFFF } VkVendorId; -typedef enum VkPipelineCacheHeaderVersion { - VK_PIPELINE_CACHE_HEADER_VERSION_ONE = 1, - VK_PIPELINE_CACHE_HEADER_VERSION_MAX_ENUM = 0x7FFFFFFF -} VkPipelineCacheHeaderVersion; - typedef enum VkSystemAllocationScope { VK_SYSTEM_ALLOCATION_SCOPE_COMMAND = 0, VK_SYSTEM_ALLOCATION_SCOPE_OBJECT = 1, @@ -1917,6 +1924,7 @@ typedef enum VkImageUsageFlagBits { #ifdef VK_ENABLE_BETA_EXTENSIONS VK_IMAGE_USAGE_VIDEO_ENCODE_DPB_BIT_KHR = 0x00008000, #endif + VK_IMAGE_USAGE_INVOCATION_MASK_BIT_HUAWEI = 0x00040000, VK_IMAGE_USAGE_SHADING_RATE_IMAGE_BIT_NV = VK_IMAGE_USAGE_FRAGMENT_SHADING_RATE_ATTACHMENT_BIT_KHR, VK_IMAGE_USAGE_FLAG_BITS_MAX_ENUM = 0x7FFFFFFF } VkImageUsageFlagBits; @@ -1940,6 +1948,7 @@ typedef enum VkMemoryPropertyFlagBits { VK_MEMORY_PROPERTY_PROTECTED_BIT = 0x00000020, VK_MEMORY_PROPERTY_DEVICE_COHERENT_BIT_AMD = 0x00000040, VK_MEMORY_PROPERTY_DEVICE_UNCACHED_BIT_AMD = 0x00000080, + VK_MEMORY_PROPERTY_RDMA_CAPABLE_BIT_NV = 0x00000100, VK_MEMORY_PROPERTY_FLAG_BITS_MAX_ENUM = 0x7FFFFFFF } VkMemoryPropertyFlagBits; typedef VkFlags VkMemoryPropertyFlags; @@ -2421,6 +2430,14 @@ typedef struct VkMemoryBarrier { VkAccessFlags dstAccessMask; } VkMemoryBarrier; +typedef struct VkPipelineCacheHeaderVersionOne { + uint32_t headerSize; + VkPipelineCacheHeaderVersion headerVersion; + uint32_t vendorID; + uint32_t deviceID; + uint8_t pipelineCacheUUID[VK_UUID_SIZE]; +} VkPipelineCacheHeaderVersionOne; + typedef void* (VKAPI_PTR *PFN_vkAllocationFunction)( void* pUserData, size_t size, @@ -4492,6 +4509,7 @@ typedef enum VkExternalMemoryHandleTypeFlagBits { VK_EXTERNAL_MEMORY_HANDLE_TYPE_HOST_ALLOCATION_BIT_EXT = 0x00000080, VK_EXTERNAL_MEMORY_HANDLE_TYPE_HOST_MAPPED_FOREIGN_MEMORY_BIT_EXT = 0x00000100, VK_EXTERNAL_MEMORY_HANDLE_TYPE_ZIRCON_VMO_BIT_FUCHSIA = 0x00000800, + VK_EXTERNAL_MEMORY_HANDLE_TYPE_RDMA_ADDRESS_BIT_NV = 0x00001000, VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD_BIT_KHR = VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD_BIT, VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_BIT_KHR = VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_BIT, VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_KMT_BIT_KHR = VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_WIN32_KMT_BIT, @@ -6177,7 +6195,7 @@ typedef struct VkAcquireNextImageInfoKHR { typedef struct VkDeviceGroupPresentCapabilitiesKHR { VkStructureType sType; - const void* pNext; + void* pNext; uint32_t presentMask[VK_MAX_DEVICE_GROUP_SIZE]; VkDeviceGroupPresentModeFlagsKHR modes; } VkDeviceGroupPresentCapabilitiesKHR; @@ -7052,7 +7070,7 @@ typedef struct VkPhysicalDevicePerformanceQueryPropertiesKHR { typedef struct VkPerformanceCounterKHR { VkStructureType sType; - const void* pNext; + void* pNext; VkPerformanceCounterUnitKHR unit; VkPerformanceCounterScopeKHR scope; VkPerformanceCounterStorageKHR storage; @@ -7061,7 +7079,7 @@ typedef struct VkPerformanceCounterKHR { typedef struct VkPerformanceCounterDescriptionKHR { VkStructureType sType; - const void* pNext; + void* pNext; VkPerformanceCounterDescriptionFlagsKHR flags; char name[VK_MAX_DESCRIPTION_SIZE]; char category[VK_MAX_DESCRIPTION_SIZE]; @@ -7662,6 +7680,26 @@ typedef VkAttachmentDescriptionStencilLayout VkAttachmentDescriptionStencilLayou +#define VK_KHR_present_wait 1 +#define VK_KHR_PRESENT_WAIT_SPEC_VERSION 1 +#define VK_KHR_PRESENT_WAIT_EXTENSION_NAME "VK_KHR_present_wait" +typedef struct VkPhysicalDevicePresentWaitFeaturesKHR { + VkStructureType sType; + void* pNext; + VkBool32 presentWait; +} VkPhysicalDevicePresentWaitFeaturesKHR; + +typedef VkResult (VKAPI_PTR *PFN_vkWaitForPresentKHR)(VkDevice device, VkSwapchainKHR swapchain, uint64_t presentId, uint64_t timeout); + +#ifndef VK_NO_PROTOTYPES +VKAPI_ATTR VkResult VKAPI_CALL vkWaitForPresentKHR( + VkDevice device, + VkSwapchainKHR swapchain, + uint64_t presentId, + uint64_t timeout); +#endif + + #define VK_KHR_uniform_buffer_standard_layout 1 #define VK_KHR_UNIFORM_BUFFER_STANDARD_LAYOUT_SPEC_VERSION 1 #define VK_KHR_UNIFORM_BUFFER_STANDARD_LAYOUT_EXTENSION_NAME "VK_KHR_uniform_buffer_standard_layout" @@ -7843,6 +7881,24 @@ typedef struct VkPipelineLibraryCreateInfoKHR { #define VK_KHR_SHADER_NON_SEMANTIC_INFO_EXTENSION_NAME "VK_KHR_shader_non_semantic_info" +#define VK_KHR_present_id 1 +#define VK_KHR_PRESENT_ID_SPEC_VERSION 1 +#define VK_KHR_PRESENT_ID_EXTENSION_NAME "VK_KHR_present_id" +typedef struct VkPresentIdKHR { + VkStructureType sType; + const void* pNext; + uint32_t swapchainCount; + const uint64_t* pPresentIds; +} VkPresentIdKHR; + +typedef struct VkPhysicalDevicePresentIdFeaturesKHR { + VkStructureType sType; + void* pNext; + VkBool32 presentId; +} VkPhysicalDevicePresentIdFeaturesKHR; + + + #define VK_KHR_synchronization2 1 typedef uint64_t VkFlags64; #define VK_KHR_SYNCHRONIZATION_2_SPEC_VERSION 1 @@ -7865,7 +7921,7 @@ static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_LATE_FRAGMENT_TESTS static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_COLOR_ATTACHMENT_OUTPUT_BIT_KHR = 0x00000400ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_COMPUTE_SHADER_BIT_KHR = 0x00000800ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_ALL_TRANSFER_BIT_KHR = 0x00001000ULL; -static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_TRANSFER_BIT_KHR = 0x00001000; +static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_TRANSFER_BIT_KHR = 0x00001000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_BOTTOM_OF_PIPE_BIT_KHR = 0x00002000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_HOST_BIT_KHR = 0x00004000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_ALL_GRAPHICS_BIT_KHR = 0x00008000ULL; @@ -7887,15 +7943,16 @@ static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_TRANSFORM_FEEDBACK_ static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_CONDITIONAL_RENDERING_BIT_EXT = 0x00040000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_COMMAND_PREPROCESS_BIT_NV = 0x00020000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_FRAGMENT_SHADING_RATE_ATTACHMENT_BIT_KHR = 0x00400000ULL; -static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_SHADING_RATE_IMAGE_BIT_NV = 0x00400000; +static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_SHADING_RATE_IMAGE_BIT_NV = 0x00400000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_ACCELERATION_STRUCTURE_BUILD_BIT_KHR = 0x02000000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_RAY_TRACING_SHADER_BIT_KHR = 0x00200000ULL; -static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_RAY_TRACING_SHADER_BIT_NV = 0x00200000; -static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_ACCELERATION_STRUCTURE_BUILD_BIT_NV = 0x02000000; +static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_RAY_TRACING_SHADER_BIT_NV = 0x00200000ULL; +static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_ACCELERATION_STRUCTURE_BUILD_BIT_NV = 0x02000000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_FRAGMENT_DENSITY_PROCESS_BIT_EXT = 0x00800000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_TASK_SHADER_BIT_NV = 0x00080000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_MESH_SHADER_BIT_NV = 0x00100000ULL; static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_SUBPASS_SHADING_BIT_HUAWEI = 0x8000000000ULL; +static const VkPipelineStageFlagBits2KHR VK_PIPELINE_STAGE_2_INVOCATION_MASK_BIT_HUAWEI = 0x10000000000ULL; typedef VkFlags64 VkAccessFlags2KHR; @@ -7941,13 +7998,14 @@ static const VkAccessFlagBits2KHR VK_ACCESS_2_CONDITIONAL_RENDERING_READ_BIT_EXT static const VkAccessFlagBits2KHR VK_ACCESS_2_COMMAND_PREPROCESS_READ_BIT_NV = 0x00020000ULL; static const VkAccessFlagBits2KHR VK_ACCESS_2_COMMAND_PREPROCESS_WRITE_BIT_NV = 0x00040000ULL; static const VkAccessFlagBits2KHR VK_ACCESS_2_FRAGMENT_SHADING_RATE_ATTACHMENT_READ_BIT_KHR = 0x00800000ULL; -static const VkAccessFlagBits2KHR VK_ACCESS_2_SHADING_RATE_IMAGE_READ_BIT_NV = 0x00800000; +static const VkAccessFlagBits2KHR VK_ACCESS_2_SHADING_RATE_IMAGE_READ_BIT_NV = 0x00800000ULL; static const VkAccessFlagBits2KHR VK_ACCESS_2_ACCELERATION_STRUCTURE_READ_BIT_KHR = 0x00200000ULL; static const VkAccessFlagBits2KHR VK_ACCESS_2_ACCELERATION_STRUCTURE_WRITE_BIT_KHR = 0x00400000ULL; -static const VkAccessFlagBits2KHR VK_ACCESS_2_ACCELERATION_STRUCTURE_READ_BIT_NV = 0x00200000; -static const VkAccessFlagBits2KHR VK_ACCESS_2_ACCELERATION_STRUCTURE_WRITE_BIT_NV = 0x00400000; +static const VkAccessFlagBits2KHR VK_ACCESS_2_ACCELERATION_STRUCTURE_READ_BIT_NV = 0x00200000ULL; +static const VkAccessFlagBits2KHR VK_ACCESS_2_ACCELERATION_STRUCTURE_WRITE_BIT_NV = 0x00400000ULL; static const VkAccessFlagBits2KHR VK_ACCESS_2_FRAGMENT_DENSITY_MAP_READ_BIT_EXT = 0x01000000ULL; static const VkAccessFlagBits2KHR VK_ACCESS_2_COLOR_ATTACHMENT_READ_NONCOHERENT_BIT_EXT = 0x00080000ULL; +static const VkAccessFlagBits2KHR VK_ACCESS_2_INVOCATION_MASK_READ_BIT_HUAWEI = 0x8000000000ULL; typedef enum VkSubmitFlagBitsKHR { @@ -11588,6 +11646,28 @@ VKAPI_ATTR void VKAPI_CALL vkCmdSetStencilOpEXT( #endif +#define VK_EXT_shader_atomic_float2 1 +#define VK_EXT_SHADER_ATOMIC_FLOAT_2_SPEC_VERSION 1 +#define VK_EXT_SHADER_ATOMIC_FLOAT_2_EXTENSION_NAME "VK_EXT_shader_atomic_float2" +typedef struct VkPhysicalDeviceShaderAtomicFloat2FeaturesEXT { + VkStructureType sType; + void* pNext; + VkBool32 shaderBufferFloat16Atomics; + VkBool32 shaderBufferFloat16AtomicAdd; + VkBool32 shaderBufferFloat16AtomicMinMax; + VkBool32 shaderBufferFloat32AtomicMinMax; + VkBool32 shaderBufferFloat64AtomicMinMax; + VkBool32 shaderSharedFloat16Atomics; + VkBool32 shaderSharedFloat16AtomicAdd; + VkBool32 shaderSharedFloat16AtomicMinMax; + VkBool32 shaderSharedFloat32AtomicMinMax; + VkBool32 shaderSharedFloat64AtomicMinMax; + VkBool32 shaderImageFloat32AtomicMinMax; + VkBool32 sparseImageFloat32AtomicMinMax; +} VkPhysicalDeviceShaderAtomicFloat2FeaturesEXT; + + + #define VK_EXT_shader_demote_to_helper_invocation 1 #define VK_EXT_SHADER_DEMOTE_TO_HELPER_INVOCATION_SPEC_VERSION 1 #define VK_EXT_SHADER_DEMOTE_TO_HELPER_INVOCATION_EXTENSION_NAME "VK_EXT_shader_demote_to_helper_invocation" @@ -11867,7 +11947,7 @@ typedef struct VkPhysicalDeviceDeviceMemoryReportFeaturesEXT { typedef struct VkDeviceMemoryReportCallbackDataEXT { VkStructureType sType; - const void* pNext; + void* pNext; VkDeviceMemoryReportFlagsEXT flags; VkDeviceMemoryReportEventTypeEXT type; uint64_t memoryObjectId; @@ -12202,7 +12282,7 @@ typedef struct VkAccelerationStructureMotionInstanceNV { typedef struct VkPhysicalDeviceRayTracingMotionBlurFeaturesNV { VkStructureType sType; - const void* pNext; + void* pNext; VkBool32 rayTracingMotionBlur; VkBool32 rayTracingMotionBlurPipelineTraceRaysIndirect; } VkPhysicalDeviceRayTracingMotionBlurFeaturesNV; @@ -12371,7 +12451,7 @@ typedef struct VkPhysicalDeviceDrmPropertiesEXT { #define VK_HUAWEI_subpass_shading 1 -#define VK_HUAWEI_SUBPASS_SHADING_SPEC_VERSION 0 +#define VK_HUAWEI_SUBPASS_SHADING_SPEC_VERSION 2 #define VK_HUAWEI_SUBPASS_SHADING_EXTENSION_NAME "VK_HUAWEI_subpass_shading" typedef struct VkSubpassShadingPipelineCreateInfoHUAWEI { VkStructureType sType; @@ -12392,11 +12472,12 @@ typedef struct VkPhysicalDeviceSubpassShadingPropertiesHUAWEI { uint32_t maxSubpassShadingWorkgroupSizeAspectRatio; } VkPhysicalDeviceSubpassShadingPropertiesHUAWEI; -typedef VkResult (VKAPI_PTR *PFN_vkGetSubpassShadingMaxWorkgroupSizeHUAWEI)(VkRenderPass renderpass, VkExtent2D* pMaxWorkgroupSize); +typedef VkResult (VKAPI_PTR *PFN_vkGetDeviceSubpassShadingMaxWorkgroupSizeHUAWEI)(VkDevice device, VkRenderPass renderpass, VkExtent2D* pMaxWorkgroupSize); typedef void (VKAPI_PTR *PFN_vkCmdSubpassShadingHUAWEI)(VkCommandBuffer commandBuffer); #ifndef VK_NO_PROTOTYPES -VKAPI_ATTR VkResult VKAPI_CALL vkGetSubpassShadingMaxWorkgroupSizeHUAWEI( +VKAPI_ATTR VkResult VKAPI_CALL vkGetDeviceSubpassShadingMaxWorkgroupSizeHUAWEI( + VkDevice device, VkRenderPass renderpass, VkExtent2D* pMaxWorkgroupSize); @@ -12405,6 +12486,52 @@ VKAPI_ATTR void VKAPI_CALL vkCmdSubpassShadingHUAWEI( #endif +#define VK_HUAWEI_invocation_mask 1 +#define VK_HUAWEI_INVOCATION_MASK_SPEC_VERSION 1 +#define VK_HUAWEI_INVOCATION_MASK_EXTENSION_NAME "VK_HUAWEI_invocation_mask" +typedef struct VkPhysicalDeviceInvocationMaskFeaturesHUAWEI { + VkStructureType sType; + void* pNext; + VkBool32 invocationMask; +} VkPhysicalDeviceInvocationMaskFeaturesHUAWEI; + +typedef void (VKAPI_PTR *PFN_vkCmdBindInvocationMaskHUAWEI)(VkCommandBuffer commandBuffer, VkImageView imageView, VkImageLayout imageLayout); + +#ifndef VK_NO_PROTOTYPES +VKAPI_ATTR void VKAPI_CALL vkCmdBindInvocationMaskHUAWEI( + VkCommandBuffer commandBuffer, + VkImageView imageView, + VkImageLayout imageLayout); +#endif + + +#define VK_NV_external_memory_rdma 1 +typedef void* VkRemoteAddressNV; +#define VK_NV_EXTERNAL_MEMORY_RDMA_SPEC_VERSION 1 +#define VK_NV_EXTERNAL_MEMORY_RDMA_EXTENSION_NAME "VK_NV_external_memory_rdma" +typedef struct VkMemoryGetRemoteAddressInfoNV { + VkStructureType sType; + const void* pNext; + VkDeviceMemory memory; + VkExternalMemoryHandleTypeFlagBits handleType; +} VkMemoryGetRemoteAddressInfoNV; + +typedef struct VkPhysicalDeviceExternalMemoryRDMAFeaturesNV { + VkStructureType sType; + void* pNext; + VkBool32 externalMemoryRDMA; +} VkPhysicalDeviceExternalMemoryRDMAFeaturesNV; + +typedef VkResult (VKAPI_PTR *PFN_vkGetMemoryRemoteAddressNV)(VkDevice device, const VkMemoryGetRemoteAddressInfoNV* pMemoryGetRemoteAddressInfo, VkRemoteAddressNV* pAddress); + +#ifndef VK_NO_PROTOTYPES +VKAPI_ATTR VkResult VKAPI_CALL vkGetMemoryRemoteAddressNV( + VkDevice device, + const VkMemoryGetRemoteAddressInfoNV* pMemoryGetRemoteAddressInfo, + VkRemoteAddressNV* pAddress); +#endif + + #define VK_EXT_extended_dynamic_state2 1 #define VK_EXT_EXTENDED_DYNAMIC_STATE_2_SPEC_VERSION 1 #define VK_EXT_EXTENDED_DYNAMIC_STATE_2_EXTENSION_NAME "VK_EXT_extended_dynamic_state2" diff --git a/icd/api/include/pipeline_compiler.h b/icd/api/include/pipeline_compiler.h index 841b78c9..f7cf8a44 100644 --- a/icd/api/include/pipeline_compiler.h +++ b/icd/api/include/pipeline_compiler.h @@ -51,6 +51,30 @@ struct ShaderModuleHandle; class PipelineBinaryCache; +// ===================================================================================================================== +struct ShaderStageInfo +{ + ShaderStage stage; + const ShaderModuleHandle* pModuleHandle; + Pal::ShaderHash codeHash; // This hash includes entry point info + size_t codeSize; + const char* pEntryPoint; + VkPipelineShaderStageCreateFlags flags; + const VkSpecializationInfo* pSpecializationInfo; +}; + +// ===================================================================================================================== +struct GraphicsPipelineShaderStageInfo +{ + ShaderStageInfo stages[ShaderStage::ShaderStageGfxCount]; +}; + +// ===================================================================================================================== +struct ComputePipelineShaderStageInfo +{ + ShaderStageInfo stage; +}; + // ===================================================================================================================== class PipelineCompiler { @@ -102,7 +126,6 @@ class PipelineCompiler GraphicsPipelineBinaryCreateInfo* pCreateInfo, size_t* pPipelineBinarySize, const void** ppPipelineBinary, - uint32_t rasterizationStream, Util::MetroHash::Hash* pCacheId); VkResult CreateComputePipelineBinary( @@ -114,11 +137,15 @@ class PipelineCompiler const void** ppPipelineBinary, Util::MetroHash::Hash* pCacheId); - void UpdatePipelineCreationFeedback( + static void GetPipelineCreationFeedback( + const VkStructHeader* pHeader, + const VkPipelineCreationFeedbackCreateInfoEXT** ppPipelineCreationFeadbackCreateInfo); + + static void UpdatePipelineCreationFeedback( VkPipelineCreationFeedbackEXT* pPipelineCreationFeedback, const PipelineCreationFeedback* pFeedbackFromCompiler); - VkResult SetPipelineCreationFeedbackInfo( + static VkResult SetPipelineCreationFeedbackInfo( const VkPipelineCreationFeedbackCreateInfoEXT* pPipelineCreationFeadbackCreateInfo, uint32_t stageCount, const VkPipelineShaderStageCreateInfo* pStages, @@ -126,17 +153,19 @@ class PipelineCompiler const PipelineCreationFeedback* pStageFeedback); VkResult ConvertGraphicsPipelineInfo( - Device* pDevice, + const Device* pDevice, const VkGraphicsPipelineCreateInfo* pIn, - GraphicsPipelineBinaryCreateInfo* pInfo, - VbBindingInfo* pVbInfo, - const VkPipelineCreationFeedbackCreateInfoEXT** ppPipelineCreationFeadbackCreateInfo); + const GraphicsPipelineShaderStageInfo* pShaderInfo, + GraphicsPipelineBinaryCreateInfo* pCreateInfo, + VbBindingInfo* pVbInfo); VkResult ConvertComputePipelineInfo( - Device* pDevice, + const Device* pDevice, const VkComputePipelineCreateInfo* pIn, - ComputePipelineBinaryCreateInfo* pInfo, - const VkPipelineCreationFeedbackCreateInfoEXT** ppPipelineCreationFeadbackCreateInfo); + const ComputePipelineShaderStageInfo* pShaderInfo, + ComputePipelineBinaryCreateInfo* pInfo); + + bool IsValidShaderModule(const ShaderModuleHandle* pShaderModule) const; void FreeShaderModule(ShaderModuleHandle* pShaderModule); @@ -182,16 +211,6 @@ class PipelineCompiler private: PAL_DISALLOW_COPY_AND_ASSIGN(PipelineCompiler); - void ApplyProfileOptions( - Device* pDevice, - ShaderStage stage, - ShaderModule* pShaderModule, - Vkgc::PipelineOptions* pPipelineOptions, - Vkgc::PipelineShaderInfo* pShaderInfo, - PipelineOptimizerKey* pProfileKey, - Vkgc::NggState* pNggState - ); - template bool ReplacePipelineBinary( const PipelineBuildInfo* pPipelineBuildInfo, diff --git a/icd/api/include/vk_cmdbuffer.h b/icd/api/include/vk_cmdbuffer.h index a617470c..4f6e4be7 100644 --- a/icd/api/include/vk_cmdbuffer.h +++ b/icd/api/include/vk_cmdbuffer.h @@ -118,7 +118,7 @@ struct PipelineBindState PipelineDynamicBindInfo dynamicBindInfo; }; -union DirtyState +union DirtyGraphicsState { struct { @@ -196,8 +196,8 @@ struct AllGpuRenderState Framebuffer* pFramebuffer; // Dirty bits indicate which state should be validated. It assumed viewport/scissor in perGpuStates will likely be - // changed for all GPUs if it is changed for any GPU. Put DirtyState management here will be easier to manage. - DirtyState dirty; + // changed for all GPUs if it is changed for any GPU. Put DirtyGraphicsState management here will be easier to manage. + DirtyGraphicsState dirtyGraphics; // Value of VK_PIPELINE_CREATE_VIEW_INDEX_FROM_DEVICE_INDEX_BIT // defined by the last bound GraphicsPipeline, which was not nullptr. @@ -973,7 +973,7 @@ class CmdBuffer VK_INLINE uint32_t NumDeviceEvents(uint32_t numEvents) const { - return m_pDevice->NumPalDevices() * numEvents; + return m_numPalDevices * numEvents; } #if VK_ENABLE_DEBUG_BARRIERS @@ -1023,8 +1023,7 @@ class CmdBuffer return &pPerGpuState[deviceIdx]; } - AllGpuRenderState* RenderState() - { return &m_allGpuState; } + AllGpuRenderState* RenderState() { return &m_allGpuState; } // Get a safe number of objects that can be allocated by the virtual stack frame allocator without risking OOM error. uint32_t EstimateMaxObjectsOnVirtualStack(size_t objectSize) const @@ -1194,7 +1193,8 @@ class CmdBuffer uint32_t useSplitReleaseAcquire : 1; uint32_t reserved2 : 3; uint32_t reserved3 : 1; - uint32_t reserved : 16; + uint32_t reserved4 : 1; + uint32_t reserved : 15; }; }; @@ -1206,6 +1206,7 @@ class CmdBuffer uint32_t m_curDeviceMask; // Device mask the command buffer is currently set to uint32_t m_rpDeviceMask; // Device mask for the render pass instance uint32_t m_cbBeginDeviceMask; // Device mask this command buffer began with + const uint32_t m_numPalDevices; VkShaderStageFlags m_validShaderStageFlags; Pal::ICmdBuffer* m_pPalCmdBuffers[MaxPalDevices]; VirtualStackAllocator* m_pStackAllocator; @@ -1299,7 +1300,7 @@ void CmdBuffer::PalCmdBufferSetUserData( uint32_t perDeviceStride, const uint32_t* pEntryValues) { - for (uint32_t deviceIdx = 0; deviceIdx < m_pDevice->NumPalDevices(); deviceIdx++) + for (uint32_t deviceIdx = 0; deviceIdx < m_numPalDevices; deviceIdx++) { PalCmdBuffer(deviceIdx)->CmdSetUserData(bindPoint, firstEntry, @@ -1317,7 +1318,7 @@ void CmdBuffer::InsertDeviceEvents( uint32_t stride ) const { - for (uint32_t deviceIdx = 0; deviceIdx < m_pDevice->NumPalDevices(); deviceIdx++) + for (uint32_t deviceIdx = 0; deviceIdx < m_numPalDevices; deviceIdx++) { pDestEvents[(deviceIdx * stride) + index] = pSrcEvents->PalEvent(deviceIdx); } diff --git a/icd/api/include/vk_compute_pipeline.h b/icd/api/include/vk_compute_pipeline.h index a544ea6c..e1d81f82 100644 --- a/icd/api/include/vk_compute_pipeline.h +++ b/icd/api/include/vk_compute_pipeline.h @@ -112,8 +112,7 @@ class ComputePipeline final : public Pipeline, public NonDispatchable AMD_SHADER_TRINARY_MINMAX, AMD_TEXTURE_GATHER_BIAS_LOD, - // ANDROID Extensions - // GOOGLE Extensions GOOGLE_DECORATE_STRING, GOOGLE_HLSL_FUNCTIONALITY1, diff --git a/icd/api/include/vk_formats.h b/icd/api/include/vk_formats.h index 76266bad..413cf3de 100644 --- a/icd/api/include/vk_formats.h +++ b/icd/api/include/vk_formats.h @@ -40,6 +40,17 @@ namespace vk { +#if ( VKI_GPU_DECOMPRESS) + +// ===================================================================================================================== +struct AstcMappedInfo +{ + VkFormat format; + uint32_t wScale; + uint32_t hScale; +}; +#endif + // ===================================================================================================================== // Container for storing compile-time meta-information about Vulkan formats. // @@ -65,6 +76,9 @@ struct Formats VK_INLINE static uint32_t GetIndex(VkFormat format); VK_INLINE static VkFormat FromIndex(uint32_t index); +#if ( VKI_GPU_DECOMPRESS) + static void GetAstcMappedInfo(VkFormat format, AstcMappedInfo* pMapInfo); +#endif static VkExtent3D ElementsToTexels(VkFormat format, const VkExtent3D& extent, const RuntimeSettings& settings); static Pal::Formats::NumericSupportFlags GetNumberFormat(VkFormat format, const RuntimeSettings& settings); }; diff --git a/icd/api/include/vk_graphics_pipeline.h b/icd/api/include/vk_graphics_pipeline.h index e2d9a8d1..48beb4e1 100644 --- a/icd/api/include/vk_graphics_pipeline.h +++ b/icd/api/include/vk_graphics_pipeline.h @@ -210,6 +210,29 @@ class GraphicsPipeline final : public GraphicsPipelineCommon, public NonDispatch void CreateStaticState(); void DestroyStaticState(const VkAllocationCallbacks* pAllocator); + static VkResult CreatePipelineBinaries( + Device* pDevice, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + const GraphicsPipelineShaderStageInfo* pShaderInfo, + GraphicsPipelineBinaryCreateInfo* pBinaryCreateInfo, + PipelineCache* pPipelineCache, + const VkPipelineCreationFeedbackCreateInfoEXT* pCreationFeedbackInfo, + Util::MetroHash::Hash* pCacheIds, + size_t* pPipelineBinarySizes, + const void** pPipelineBinaries); + + static VkResult CreatePipelineObjects( + Device* pDevice, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + const VkAllocationCallbacks* pAllocator, + const VbBindingInfo* pVbInfo, + const size_t* pPipelineBinarySizes, + const void** pPipelineBinaries, + PipelineCache* pPipelineCache, + const Util::MetroHash::Hash* pCacheIds, + GraphicsPipelineObjectCreateInfo* pObjectCreateInfo, + VkPipeline* pPipeline); + ~GraphicsPipeline(); private: diff --git a/icd/api/include/vk_image.h b/icd/api/include/vk_image.h index fdfc20c1..9d9e7e8f 100644 --- a/icd/api/include/vk_image.h +++ b/icd/api/include/vk_image.h @@ -248,7 +248,7 @@ class Image final : public NonDispatchable uint32_t boundToExternalMemory : 1; // If true, indicates the image is bound to an external memory, and // the m_pPalMemory is a pointer to an external Pal image (does // not include backing pinned system memory case). - uint32_t androidPresentable : 1; // True if this image is created as Android presentable image. + uint32_t reservedBit : 1; uint32_t externalPinnedHost : 1; // True if image backing memory is compatible with pinned sysmem. uint32_t externalD3DHandle : 1; // True if image is backed by a D3D11 image uint32_t isColorFormat : 1; // True if the image has a color format @@ -355,10 +355,6 @@ class Image final : public NonDispatchable SwapChain* m_pSwapChain; // If this image is a presentable image this tells // which swap chain the image belongs to - Memory* m_pImageMemory; // If this image is Android presentable image this tells the gpuMemory - // bound. Android swapchain is implemented in loader.Presentable image - // use this member to track the gpuMemory created from external handle. - ResourceOptimizerKey m_ResourceKey; // This goes last. The memory for the rest of the array is calculated dynamically based on the number of GPUs in diff --git a/icd/api/include/vk_memory.h b/icd/api/include/vk_memory.h index 58c8fb9e..67eb9947 100644 --- a/icd/api/include/vk_memory.h +++ b/icd/api/include/vk_memory.h @@ -89,7 +89,6 @@ struct ImportMemoryInfo { Pal::OsExternalHandle handle; // A handle on Windows, or a fd on Linux. bool isNtHandle; // It's a Windows-specific flag indicates the handle is shared via NT. - bool isAhbHandle; // Android-specific flgs indicates handle is Android Hardware Buffer }; // ===================================================================================================================== diff --git a/icd/api/include/vk_physical_device.h b/icd/api/include/vk_physical_device.h index 39c2270e..59ae25d5 100644 --- a/icd/api/include/vk_physical_device.h +++ b/icd/api/include/vk_physical_device.h @@ -244,7 +244,7 @@ class PhysicalDevice uint32_t* pCount, VkQueueFamilyProperties2* pQueueProperties) const; - VkResult GetFeatures(VkPhysicalDeviceFeatures* pFeatures) const; + size_t GetFeatures(VkPhysicalDeviceFeatures* pFeatures) const; VK_INLINE VkResult GetFormatProperties( VkFormat format, @@ -324,11 +324,6 @@ class PhysicalDevice VkExternalMemoryHandleTypeFlagBits handleType, VkExternalMemoryProperties* pExternalMemoryProperties) const; - VkResult GetAndroidHarewareBufferUsage( - VkImageUsageFlags usage, - VkImageCreateFlags createFlags, - uint64_t* pAHBUsage) const; - VkResult GetImageFormatProperties( VkFormat format, VkImageType type, @@ -431,8 +426,9 @@ class PhysicalDevice uint32_t* pPropertyCount, VkSparseImageFormatProperties2* pProperties); - void GetFeatures2( - VkStructHeaderNonConst* pFeatures) const; + size_t GetFeatures2( + VkStructHeaderNonConst* pFeatures, + bool updateFeatures) const; void GetMemoryProperties2( VkPhysicalDeviceMemoryProperties2* pMemoryProperties); diff --git a/icd/api/include/vk_pipeline.h b/icd/api/include/vk_pipeline.h index 746c8841..4e3640b2 100644 --- a/icd/api/include/vk_pipeline.h +++ b/icd/api/include/vk_pipeline.h @@ -60,6 +60,8 @@ class ComputePipeline; class GraphicsPipeline; class PipelineLayout; struct RuntimeSettings; +struct ShaderStageInfo; +struct ShaderModuleHandle; // The top-level user data layout is portioned into different sections based on the value type (push constant, // descriptor set addresses, etc.). This structure describes the offsets and sizes of those regions. @@ -140,9 +142,7 @@ class Pipeline const UserDataLayout* GetUserDataLayout(void) const { return &m_userDataLayout; } static VK_FORCEINLINE Pipeline* BaseObjectFromHandle(VkPipeline pipeline) - { - return reinterpret_cast(pipeline); - } + { return reinterpret_cast(pipeline); } const Pal::IPipeline* PalPipeline(int32_t idx) const { @@ -156,19 +156,13 @@ class Pipeline return m_pPalPipeline[idx]; } - VK_INLINE uint64_t PalPipelineHash() const - { - return m_palPipelineHash; - } + VK_INLINE uint64_t PalPipelineHash() const { return m_palPipelineHash; } - VK_INLINE uint64_t GetApiHash() const - { return m_apiHash; } + VK_INLINE uint64_t GetApiHash() const { return m_apiHash; } - VK_INLINE const PipelineBinaryInfo* GetBinary() const - { return m_pBinary; } + VK_INLINE const PipelineBinaryInfo* GetBinary() const { return m_pBinary; } - VK_INLINE VkPipelineBindPoint GetType() const - { return m_type; } + VK_INLINE VkPipelineBindPoint GetType() const { return m_type; } // This function returns true if any of the bits in the given state mask (corresponding to shifted values of // VK_DYNAMIC_STATE_*) should be programmed by the pipeline when it is bound (instead of by the application via @@ -213,6 +207,20 @@ class Pipeline const VkPipelineDynamicStateCreateInfo& desc, Util::MetroHash128* pHasher); + static VkResult BuildShaderStageInfo( + const Device* pDevice, + const uint32_t stageCount, + const VkPipelineShaderStageCreateInfo* pStages, + uint32_t (*pfnGetOutputIdx)(const uint32_t inputIdx, + const uint32_t stageIdx), + ShaderStageInfo* pShaderStageInfo, + ShaderModuleHandle* pTempModules); + + static void FreeTempModules( + const Device* pDevice, + const uint32_t maxStageCount, + ShaderModuleHandle* pTempModules); + Device* const m_pDevice; UserDataLayout m_userDataLayout; Pal::IPipeline* m_pPalPipeline[MaxPalDevices]; diff --git a/icd/api/include/vk_pipeline_layout.h b/icd/api/include/vk_pipeline_layout.h index eee3d785..f000365a 100644 --- a/icd/api/include/vk_pipeline_layout.h +++ b/icd/api/include/vk_pipeline_layout.h @@ -116,11 +116,10 @@ class PipelineLayout final : public NonDispatchable const void* GetCode() const { return m_pCode; } const ShaderModuleHandle* GetShaderModuleHandle() const { return &m_handle; } - Pal::ShaderHash GetCodeHash(const char* pEntryPoint) const; + Pal::ShaderHash GetCodeHash(const char* pEntryPoint) const + { return GetCodeHash(m_codeHash, pEntryPoint); } void* GetShaderData(PipelineCompilerType compilerType) const - { - return GetShaderData(compilerType, &m_handle); - } + { return GetShaderData(compilerType, &m_handle); } - void* GetFirstValidShaderData() const; + void* GetFirstValidShaderData() const + { return GetFirstValidShaderData(&m_handle); } + + static Pal::ShaderHash BuildCodeHash(const void* pCode, const size_t codeSize); + + static Pal::ShaderHash GetCodeHash(Pal::ShaderHash codeHash, const char* pEntryPoint); static void* GetShaderData(PipelineCompilerType compilerType, const ShaderModuleHandle* pHandle); + static void* GetFirstValidShaderData(const ShaderModuleHandle* pHandle); + protected: ShaderModule(size_t codeSize, const void* pCode); VkResult Init(const Device* pDevice, VkShaderModuleCreateFlags flags); diff --git a/icd/api/include/vk_utils.h b/icd/api/include/vk_utils.h index 17c52817..5d65237e 100644 --- a/icd/api/include/vk_utils.h +++ b/icd/api/include/vk_utils.h @@ -139,7 +139,7 @@ VK_INLINE uint64_t TicksToNano(uint64_t ticks) // ===================================================================================================================== // Get driver build time hash -VK_INLINE const uint32_t GetBuildTimeHash() +VK_INLINE uint32_t GetBuildTimeHash() { return Util::HashLiteralString(__DATE__ __TIME__); } diff --git a/icd/api/internal_mem_mgr.cpp b/icd/api/internal_mem_mgr.cpp index 459421c4..e97f2263 100644 --- a/icd/api/internal_mem_mgr.cpp +++ b/icd/api/internal_mem_mgr.cpp @@ -195,7 +195,7 @@ VkResult InternalMemMgr::Init() &m_pCommonPools[InternalPoolCpuCacheableGpuUncached]); } - // Set-up GPU- and CPU-only pools for internal debugging code (e.g. raytracing dumping). These pools + // Set-up GPU- and CPU-only pools for internal debugging code. These pools // have the debug flag so that their allocations are never mixed into other internal allocations. if (result == VK_SUCCESS) { diff --git a/icd/api/pipeline_compiler.cpp b/icd/api/pipeline_compiler.cpp index 8325790e..320f8e71 100644 --- a/icd/api/pipeline_compiler.cpp +++ b/icd/api/pipeline_compiler.cpp @@ -54,6 +54,65 @@ namespace vk { +// ===================================================================================================================== +// The shader stages of Pre-Rasterization Shaders section +constexpr uint32_t PrsShaderMask = 0 + | ((1 << ShaderStage::ShaderStageVertex) + | (1 << ShaderStage::ShaderStageTessControl) + | (1 << ShaderStage::ShaderStageTessEval) + | (1 << ShaderStage::ShaderStageGeometry)); + +// ===================================================================================================================== +// The shader stages of Fragment Shader (Post-Rasterization) section +constexpr uint32_t FgsShaderMask = (1 << ShaderStage::ShaderStageFragment); + +// ===================================================================================================================== +// Helper function used to check whether a specific dynamic state is set +static bool IsDynamicStateEnabled(const uint32_t dynamicStateFlags, const DynamicStatesInternal internalState) +{ + return dynamicStateFlags & (1 << static_cast(internalState)); +} + +// ===================================================================================================================== +// Builds app profile key and applies profile options. +static void ApplyProfileOptions( + const Device* pDevice, + const ShaderStage stage, + const Pal::ShaderHash shaderHash, + const size_t shaderSize, + Vkgc::PipelineOptions* pPipelineOptions, + Vkgc::PipelineShaderInfo* pShaderInfo, + PipelineOptimizerKey* pProfileKey, + Vkgc::NggState* pNggState + ) +{ + auto& settings = pDevice->GetRuntimeSettings(); + PipelineShaderOptionsPtr options = {}; + options.pPipelineOptions = pPipelineOptions; + options.pOptions = &pShaderInfo->options; + options.pNggState = pNggState; + + auto& shaderKey = pProfileKey->shaders[stage]; + if (settings.pipelineUseShaderHashAsProfileHash) + { + const void* pModuleData = pShaderInfo->pModuleData; + shaderKey.codeHash.lower = Vkgc::IPipelineDumper::GetShaderHash(pModuleData); + shaderKey.codeHash.upper = 0; + } + else + { + // Populate the pipeline profile key. The hash used by the profile is different from the default + // internal hash in that it only depends on the SPIRV code + entry point. This is to reduce the + // chance that internal changes to our hash calculation logic drop us off pipeline profiles. + shaderKey.codeHash = shaderHash; + } + shaderKey.codeSize = shaderSize; + + // Override the compile parameters based on any app profile + const auto* pShaderOptimizer = pDevice->GetShaderOptimizer(); + pShaderOptimizer->OverrideShaderCreateInfo(*pProfileKey, stage, options); +} + // ===================================================================================================================== PipelineCompiler::PipelineCompiler( PhysicalDevice* pPhysicalDevice) @@ -315,6 +374,18 @@ VkResult PipelineCompiler::BuildShaderModule( return result; } +// ===================================================================================================================== +// Check whether the shader module is valid +bool PipelineCompiler::IsValidShaderModule( + const ShaderModuleHandle* pShaderModule) const +{ + bool isValid = false; + + isValid |= (pShaderModule->pLlpcShaderModule != nullptr); + + return isValid; +} + // ===================================================================================================================== // Frees shader module memory void PipelineCompiler::FreeShaderModule( @@ -620,7 +691,6 @@ VkResult PipelineCompiler::CreateGraphicsPipelineBinary( GraphicsPipelineBinaryCreateInfo* pCreateInfo, size_t* pPipelineBinarySize, const void** ppPipelineBinary, - uint32_t rasterizationStream, Util::MetroHash::Hash* pCacheId) { VkResult result = VK_SUCCESS; @@ -719,10 +789,7 @@ VkResult PipelineCompiler::CreateGraphicsPipelineBinary( hash.Update(deviceIdx); hash.Update(pCreateInfo->compilerType); hash.Update(pCreateInfo->pipelineInfo.dynamicVertexStride); - if (pCreateInfo->compilerType == PipelineCompilerTypeLlpc) - { - hash.Update(reinterpret_cast(settings.llpcOptions), sizeof(settings.llpcOptions)); - } + hash.Update(m_pPhysicalDevice->GetSettingsLoader()->GetSettingsHash()); hash.Finalize(pCacheId->bytes); @@ -753,7 +820,6 @@ VkResult PipelineCompiler::CreateGraphicsPipelineBinary( pCreateInfo, pPipelineBinarySize, ppPipelineBinary, - rasterizationStream, shaderInfos, pPipelineDumpHandle, pipelineHash, @@ -915,11 +981,8 @@ VkResult PipelineCompiler::CreateComputePipelineBinary( hash.Update(pCreateInfo->pipelineProfileKey); hash.Update(deviceIdx); hash.Update(pCreateInfo->compilerType); - hash.Update(settings.forceCsThreadGroupSwizzleMode); - if (pCreateInfo->compilerType == PipelineCompilerTypeLlpc) - { - hash.Update(reinterpret_cast(settings.llpcOptions), sizeof(settings.llpcOptions)); - } + hash.Update(m_pPhysicalDevice->GetSettingsLoader()->GetSettingsHash()); + hash.Finalize(pCacheId->bytes); cacheResult = GetCachedPipelineBinary(pCacheId, pPipelineBinaryCache, pPipelineBinarySize, ppPipelineBinary, @@ -1017,7 +1080,7 @@ VkResult PipelineCompiler::CreateComputePipelineBinary( // ===================================================================================================================== // If provided, obtains the the pipeline creation feedback create info pointer and clears the feedback flags. -void PipelineCompiler::GetPipelineCreationInfoNext( +void PipelineCompiler::GetPipelineCreationFeedback( const VkStructHeader* pHeader, const VkPipelineCreationFeedbackCreateInfoEXT** ppPipelineCreationFeadbackCreateInfo) { @@ -1120,314 +1183,241 @@ VkResult PipelineCompiler::SetPipelineCreationFeedbackInfo( } // ===================================================================================================================== -// Converts Vulkan graphics pipeline parameters to an internal structure -VkResult PipelineCompiler::ConvertGraphicsPipelineInfo( - Device* pDevice, - const VkGraphicsPipelineCreateInfo* pIn, - GraphicsPipelineBinaryCreateInfo* pCreateInfo, - VbBindingInfo* pVbInfo, - const VkPipelineCreationFeedbackCreateInfoEXT** ppPipelineCreationFeadbackCreateInfo) +// Builds the description of the internal descriptor set used to represent the VB table for SC. Returns the number +// of ResourceMappingNodes consumed by this function. This function does not add the node that describes the top-level +// pointer to this set. +void BuildLlpcVertexInputDescriptors( + const Device* pDevice, + const VkPipelineVertexInputStateCreateInfo* pInput, + VbBindingInfo* pVbInfo) { - VK_ASSERT(pIn != nullptr); + VK_ASSERT(pVbInfo != nullptr); - VkResult result = VK_SUCCESS; - const RuntimeSettings& settings = m_pPhysicalDevice->GetRuntimeSettings(); - auto pInstance = m_pPhysicalDevice->Manager()->VkInstance(); - auto flags = pIn->flags; + const uint32_t srdDwSize = pDevice->GetProperties().descriptorSizes.bufferView / sizeof(uint32_t); + uint32_t activeBindings = 0; - EXTRACT_VK_STRUCTURES_0( - gfxPipeline, - GraphicsPipelineCreateInfo, - pIn, - GRAPHICS_PIPELINE_CREATE_INFO) + // Sort the strides by binding slot + uint32_t strideByBindingSlot[Pal::MaxVertexBuffers] = {}; - if ((pIn != nullptr) && (ppPipelineCreationFeadbackCreateInfo != nullptr)) + for (uint32_t recordIndex = 0; recordIndex < pInput->vertexBindingDescriptionCount; ++recordIndex) { - GetPipelineCreationInfoNext( - reinterpret_cast(pIn->pNext), - ppPipelineCreationFeadbackCreateInfo); + const VkVertexInputBindingDescription& record = pInput->pVertexBindingDescriptions[recordIndex]; + + strideByBindingSlot[record.binding] = record.stride; } - // Fill in necessary non-zero defaults in case some information is missing - const RenderPass* pRenderPass = nullptr; - const PipelineLayout* pLayout = nullptr; - const VkPipelineShaderStageCreateInfo* pStageInfos[ShaderStage::ShaderStageGfxCount] = {}; + // Build the description of the VB table by inserting all of the active binding slots into it + pVbInfo->bindingCount = 0; + pVbInfo->bindingTableSize = 0; + // Find the set of active vertex buffer bindings by figuring out which vertex attributes are consumed by the + // pipeline. + // + // (Note that this ignores inputs eliminated by whole program optimization, but considering that we have not yet + // compiled the shader and have not performed whole program optimization, this is the best we can do; it's a + // chicken-egg problem). - if (pGraphicsPipelineCreateInfo != nullptr) + for (uint32_t aindex = 0; aindex < pInput->vertexAttributeDescriptionCount; ++aindex) { - for (uint32_t i = 0; i < pGraphicsPipelineCreateInfo->stageCount; ++i) - { - ShaderStage stage = ShaderFlagBitToStage(pGraphicsPipelineCreateInfo->pStages[i].stage); - VK_ASSERT(stage < ShaderStage::ShaderStageGfxCount); - pStageInfos[stage] = &pGraphicsPipelineCreateInfo->pStages[i]; - } + const VkVertexInputAttributeDescription& attrib = pInput->pVertexAttributeDescriptions[aindex]; + + VK_ASSERT(attrib.binding < Pal::MaxVertexBuffers); - uint32 activeStages = {}; + bool isNotActiveBinding = ((1 << attrib.binding) & activeBindings) == 0; - for (uint32_t i = 0; i < pGraphicsPipelineCreateInfo->stageCount; ++i) + if (isNotActiveBinding) { - activeStages = activeStages | pGraphicsPipelineCreateInfo->pStages[i].stage; - } + // Write out the meta information that the VB binding manager needs from pipelines + auto* pOutBinding = &pVbInfo->bindings[pVbInfo->bindingCount++]; + activeBindings |= (1 << attrib.binding); - VK_IGNORE(pGraphicsPipelineCreateInfo->flags & VK_PIPELINE_CREATE_ALLOW_DERIVATIVES_BIT); + pOutBinding->slot = attrib.binding; + pOutBinding->byteStride = strideByBindingSlot[attrib.binding]; - pRenderPass = RenderPass::ObjectFromHandle(pGraphicsPipelineCreateInfo->renderPass); + pVbInfo->bindingTableSize = Util::Max(pVbInfo->bindingTableSize, attrib.binding + 1); + } + } +} - if (pGraphicsPipelineCreateInfo->layout != VK_NULL_HANDLE) +// ===================================================================================================================== +static void BuildRasterizationState( + const VkPipelineRasterizationStateCreateInfo* pRs, + const uint32_t dynamicStateFlags, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + if (pRs != nullptr) + { + EXTRACT_VK_STRUCTURES_1( + rasterizationDepthClipState, + PipelineRasterizationDepthClipStateCreateInfoEXT, + PipelineRasterizationStateStreamCreateInfoEXT, + static_cast(pRs->pNext), + PIPELINE_RASTERIZATION_DEPTH_CLIP_STATE_CREATE_INFO_EXT, + PIPELINE_RASTERIZATION_STATE_STREAM_CREATE_INFO_EXT); + + pCreateInfo->pipelineInfo.vpState.depthClipEnable = (pRs->depthClampEnable == VK_FALSE); + pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable = (pRs->rasterizerDiscardEnable != VK_FALSE); + pCreateInfo->pipelineInfo.rsState.polygonMode = pRs->polygonMode; + pCreateInfo->pipelineInfo.rsState.cullMode = pRs->cullMode; + pCreateInfo->pipelineInfo.rsState.frontFace = pRs->frontFace; + pCreateInfo->pipelineInfo.rsState.depthBiasEnable = pRs->depthBiasEnable; + + if (pPipelineRasterizationDepthClipStateCreateInfoEXT != nullptr) { - pLayout = PipelineLayout::ObjectFromHandle(pGraphicsPipelineCreateInfo->layout); + pCreateInfo->pipelineInfo.vpState.depthClipEnable = + pPipelineRasterizationDepthClipStateCreateInfoEXT->depthClipEnable; } - pCreateInfo->pipelineInfo.pVertexInput = pGraphicsPipelineCreateInfo->pVertexInputState; - - const VkPipelineInputAssemblyStateCreateInfo* pIa = pGraphicsPipelineCreateInfo->pInputAssemblyState; - - // According to the spec this should never be null - VK_ASSERT(pIa != nullptr); - - pCreateInfo->pipelineInfo.iaState.enableMultiView = (pRenderPass != nullptr) ? - pRenderPass->IsMultiviewEnabled() : - 0; - - pCreateInfo->pipelineInfo.iaState.topology = pIa->topology; - pCreateInfo->pipelineInfo.iaState.disableVertexReuse = false; - - if (activeStages & (VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT | VK_SHADER_STAGE_TESSELLATION_EVALUATION_BIT)) + if (pPipelineRasterizationStateStreamCreateInfoEXT != nullptr) { - EXTRACT_VK_STRUCTURES_1( - Tess, - PipelineTessellationStateCreateInfo, - PipelineTessellationDomainOriginStateCreateInfo, - pGraphicsPipelineCreateInfo->pTessellationState, - PIPELINE_TESSELLATION_STATE_CREATE_INFO, - PIPELINE_TESSELLATION_DOMAIN_ORIGIN_STATE_CREATE_INFO) - - if (pPipelineTessellationStateCreateInfo != nullptr) - { - pCreateInfo->pipelineInfo.iaState.patchControlPoints = pPipelineTessellationStateCreateInfo->patchControlPoints; - } - - if (pPipelineTessellationDomainOriginStateCreateInfo) - { - // Vulkan 1.0 incorrectly specified the tessellation u,v coordinate origin as lower left even though - // framebuffer and image coordinate origins are in the upper left. This has since been fixed, but - // an extension exists to use the previous behavior. Doing so with flat shading would likely appear - // incorrect, but Vulkan specifies that the provoking vertex is undefined when tessellation is active. - if (pPipelineTessellationDomainOriginStateCreateInfo->domainOrigin == VK_TESSELLATION_DOMAIN_ORIGIN_LOWER_LEFT) - { - pCreateInfo->pipelineInfo.iaState.switchWinding = true; - } - } + pCreateInfo->rasterizationStream = pPipelineRasterizationStateStreamCreateInfoEXT->rasterizationStream; } - const VkPipelineRasterizationStateCreateInfo* pRs = pGraphicsPipelineCreateInfo->pRasterizationState; - - // By default rasterization is disabled, unless rasterization creation info is present - pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable = true; - - if (pRs != nullptr) + if (IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::RasterizerDiscardEnableExt) == true) { - pCreateInfo->pipelineInfo.vpState.depthClipEnable = (pRs->depthClampEnable == VK_FALSE); - pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable = (pRs->rasterizerDiscardEnable != VK_FALSE); - pCreateInfo->pipelineInfo.rsState.polygonMode = pRs->polygonMode; - pCreateInfo->pipelineInfo.rsState.cullMode = pRs->cullMode; - pCreateInfo->pipelineInfo.rsState.frontFace = pRs->frontFace; - pCreateInfo->pipelineInfo.rsState.depthBiasEnable = pRs->depthBiasEnable; - - union - { - const VkStructHeader* pInfo; - const VkPipelineRasterizationDepthClipStateCreateInfoEXT* pRsDepthClip; - }; - - pInfo = static_cast(pRs->pNext); - - while (pInfo != nullptr) - { - switch (static_cast(pInfo->sType)) - { - case VK_STRUCTURE_TYPE_PIPELINE_RASTERIZATION_DEPTH_CLIP_STATE_CREATE_INFO_EXT: - pCreateInfo->pipelineInfo.vpState.depthClipEnable = pRsDepthClip->depthClipEnable; - - break; - default: - break; - } - - pInfo = pInfo->pNext; - } - - const VkPipelineDynamicStateCreateInfo* pDy = pGraphicsPipelineCreateInfo->pDynamicState; - - if (pDy != nullptr) - { - for (uint32_t i = 0; i < pDy->dynamicStateCount; ++i) - { - switch (static_cast(pDy->pDynamicStates[i])) - { - case VK_DYNAMIC_STATE_RASTERIZER_DISCARD_ENABLE_EXT: - pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable = false; - break; - default: - break; - } - } - } + pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable = false; } + } +} - const VkPipelineMultisampleStateCreateInfo* pMs = pGraphicsPipelineCreateInfo->pMultisampleState; - - pCreateInfo->pipelineInfo.rsState.numSamples = 1; +// ===================================================================================================================== +static void BuildMultisampleState( + const Device* pDevice, + const VkPipelineMultisampleStateCreateInfo* pMs, + const RenderPass* pRenderPass, + const uint32_t subpass, + const uint32_t dynamicStateFlags, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + if (pMs != nullptr) + { + EXTRACT_VK_STRUCTURES_0( + SampleLocations, + PipelineSampleLocationsStateCreateInfoEXT, + static_cast(pMs->pNext), + PIPELINE_SAMPLE_LOCATIONS_STATE_CREATE_INFO_EXT); - if ((pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable != VK_TRUE) && (pMs != nullptr)) + if (pMs->rasterizationSamples != 1) { - EXTRACT_VK_STRUCTURES_1( - SampleLocations, - PipelineMultisampleStateCreateInfo, - PipelineSampleLocationsStateCreateInfoEXT, - pMs, - PIPELINE_MULTISAMPLE_STATE_CREATE_INFO, - PIPELINE_SAMPLE_LOCATIONS_STATE_CREATE_INFO_EXT) - - bool multisampleEnable = (pMs->rasterizationSamples != 1); - - if (multisampleEnable) - { - uint32_t rasterizationSampleCount = pMs->rasterizationSamples; + uint32_t rasterizationSampleCount = pMs->rasterizationSamples; - uint32_t subpassCoverageSampleCount = (pRenderPass != nullptr) ? - pRenderPass->GetSubpassMaxSampleCount(pGraphicsPipelineCreateInfo->subpass) : - rasterizationSampleCount; + uint32_t subpassCoverageSampleCount = (pRenderPass != nullptr) ? + pRenderPass->GetSubpassMaxSampleCount(subpass) : + rasterizationSampleCount; - uint32_t subpassColorSampleCount = (pRenderPass != nullptr) ? - pRenderPass->GetSubpassColorSampleCount(pGraphicsPipelineCreateInfo->subpass) : - rasterizationSampleCount; + uint32_t subpassColorSampleCount = (pRenderPass != nullptr) ? + pRenderPass->GetSubpassColorSampleCount(subpass) : + rasterizationSampleCount; - // subpassCoverageSampleCount would be equal to zero if there are zero attachments. - subpassCoverageSampleCount = (subpassCoverageSampleCount == 0) ? - rasterizationSampleCount : - subpassCoverageSampleCount; + // subpassCoverageSampleCount would be equal to zero if there are zero attachments. + subpassCoverageSampleCount = (subpassCoverageSampleCount == 0) ? + rasterizationSampleCount : + subpassCoverageSampleCount; - subpassColorSampleCount = (subpassColorSampleCount == 0) ? - subpassCoverageSampleCount : - subpassColorSampleCount; + subpassColorSampleCount = (subpassColorSampleCount == 0) ? + subpassCoverageSampleCount : + subpassColorSampleCount; - if (pMs->sampleShadingEnable && (pMs->minSampleShading > 0.0f)) - { - pCreateInfo->pipelineInfo.rsState.perSampleShading = - ((subpassColorSampleCount * pMs->minSampleShading) > 1.0f); - } - else - { - pCreateInfo->pipelineInfo.rsState.perSampleShading = false; - } - - pCreateInfo->pipelineInfo.rsState.numSamples = rasterizationSampleCount; - - // NOTE: The sample pattern index here is actually the offset of sample position pair. This is - // different from the field of creation info of image view. For image view, the sample pattern - // index is really table index of the sample pattern. - pCreateInfo->pipelineInfo.rsState.samplePatternIdx = - Device::GetDefaultSamplePatternIndex(subpassCoverageSampleCount) * Pal::MaxMsaaRasterizerSamples; - } - - pCreateInfo->pipelineInfo.cbState.alphaToCoverageEnable = (pMs->alphaToCoverageEnable == VK_TRUE); - if (pPipelineSampleLocationsStateCreateInfoEXT != nullptr) + if (pMs->sampleShadingEnable && (pMs->minSampleShading > 0.0f)) { - pCreateInfo->sampleLocationGridSize = - pPipelineSampleLocationsStateCreateInfoEXT->sampleLocationsInfo.sampleLocationGridSize; + pCreateInfo->pipelineInfo.rsState.perSampleShading = + ((subpassColorSampleCount * pMs->minSampleShading) > 1.0f); } - } - - const VkPipelineColorBlendStateCreateInfo* pCb = pGraphicsPipelineCreateInfo->pColorBlendState; - bool dualSourceBlend = false; - - if ((pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable != VK_TRUE) && (pCb != nullptr)) - { - const uint32_t numColorTargets = Util::Min(pCb->attachmentCount, Pal::MaxColorTargets); - - for (uint32_t i = 0; i < numColorTargets; ++i) + else { - const VkPipelineColorBlendAttachmentState& src = pCb->pAttachments[i]; - auto pLlpcCbDst = &pCreateInfo->pipelineInfo.cbState.target[i]; - - VkFormat cbFormat = VK_FORMAT_UNDEFINED; - - if (pRenderPass != nullptr) - { - cbFormat = pRenderPass->GetColorAttachmentFormat(pGraphicsPipelineCreateInfo->subpass, i); - } + pCreateInfo->pipelineInfo.rsState.perSampleShading = false; + } - // If the sub pass attachment format is UNDEFINED, then it means that that subpass does not - // want to write to any attachment for that output (VK_ATTACHMENT_UNUSED). Under such cases, - // disable shader writes through that target. There is one exception for alphaToCoverageEnable - // and attachment zero, which can be set to VK_ATTACHMENT_UNUSED. - if ((cbFormat != VK_FORMAT_UNDEFINED) || - (pCreateInfo->pipelineInfo.cbState.alphaToCoverageEnable && (i == 0u))) - { - pLlpcCbDst->format = (cbFormat != VK_FORMAT_UNDEFINED) ? - cbFormat : pRenderPass->GetAttachmentDesc(i).format; - pLlpcCbDst->blendEnable = (src.blendEnable == VK_TRUE); - pLlpcCbDst->blendSrcAlphaToColor = IsSrcAlphaUsedInBlend(src.srcAlphaBlendFactor) || - IsSrcAlphaUsedInBlend(src.dstAlphaBlendFactor) || - IsSrcAlphaUsedInBlend(src.srcColorBlendFactor) || - IsSrcAlphaUsedInBlend(src.dstColorBlendFactor); - pLlpcCbDst->channelWriteMask = src.colorWriteMask; - } + pCreateInfo->pipelineInfo.rsState.numSamples = rasterizationSampleCount; - dualSourceBlend |= GetDualSourceBlendEnableState(src); - } + // NOTE: The sample pattern index here is actually the offset of sample position pair. This is + // different from the field of creation info of image view. For image view, the sample pattern + // index is really table index of the sample pattern. + pCreateInfo->pipelineInfo.rsState.samplePatternIdx = + Device::GetDefaultSamplePatternIndex(subpassCoverageSampleCount) * Pal::MaxMsaaRasterizerSamples; } - pCreateInfo->pipelineInfo.cbState.dualSourceBlendEnable = dualSourceBlend; - - VkFormat dbFormat = VK_FORMAT_UNDEFINED; + pCreateInfo->pipelineInfo.cbState.alphaToCoverageEnable = (pMs->alphaToCoverageEnable == VK_TRUE); + if (pPipelineSampleLocationsStateCreateInfoEXT != nullptr) + { + pCreateInfo->sampleLocationGridSize = + pPipelineSampleLocationsStateCreateInfoEXT->sampleLocationsInfo.sampleLocationGridSize; + } - if (pRenderPass != nullptr) + if (pCreateInfo->pipelineInfo.rsState.perSampleShading) { - dbFormat = pRenderPass->GetDepthStencilAttachmentFormat(pGraphicsPipelineCreateInfo->subpass); + const RuntimeSettings& settings = pDevice->GetRuntimeSettings(); + if (!(pCreateInfo->sampleLocationGridSize.width > 1 || pCreateInfo->sampleLocationGridSize.height > 1 + )) + { + pCreateInfo->pipelineInfo.options.enableInterpModePatch = true; + } } + } + else + { + pCreateInfo->pipelineInfo.rsState.numSamples = 1; + } +} - pCreateInfo->dbFormat = dbFormat; +// ===================================================================================================================== +static void BuildViewportState( + const Device* pDevice, + const VkPipelineViewportStateCreateInfo* pVs, + const uint32_t dynamicStateFlags, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + if (pVs != nullptr) + { } +} - if (m_gfxIp.major >= 10) +// ===================================================================================================================== +static void BuildNggState( + const Device* pDevice, + const VkShaderStageFlagBits activeStages, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + const RuntimeSettings& settings = pDevice->GetRuntimeSettings(); + const Pal::DeviceProperties& deviceProp = pDevice->VkPhysicalDevice(DefaultDeviceIndex)->PalProperties(); + + if (deviceProp.gfxLevel >= Pal::GfxIpLevel::GfxIp10_1) { - const bool hasGs = pStageInfos[ShaderStage::ShaderStageGeometry] != nullptr; - const bool hasTess = pStageInfos[ShaderStage::ShaderStageTessControl] != nullptr; + const bool hasGs = activeStages & VK_SHADER_STAGE_GEOMETRY_BIT; + const bool hasTess = activeStages & VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT; + const GraphicsPipelineType pipelineType = hasTess ? (hasGs ? GraphicsPipelineTypeTessGs : GraphicsPipelineTypeTess) : (hasGs ? GraphicsPipelineTypeGs : GraphicsPipelineTypeVsFs); - pCreateInfo->pipelineInfo.nggState.enableNgg = + pCreateInfo->pipelineInfo.nggState.enableNgg = Util::TestAnyFlagSet(settings.enableNgg, pipelineType); pCreateInfo->pipelineInfo.nggState.enableGsUse = Util::TestAnyFlagSet( settings.enableNgg, GraphicsPipelineTypeGs | GraphicsPipelineTypeTessGs); #if LLPC_CLIENT_INTERFACE_MAJOR_VERSION < 44 - pCreateInfo->pipelineInfo.nggState.forceNonPassthrough = settings.nggForceCullingMode; + pCreateInfo->pipelineInfo.nggState.forceNonPassthrough = settings.nggForceCullingMode; #else - pCreateInfo->pipelineInfo.nggState.forceCullingMode = settings.nggForceCullingMode; + pCreateInfo->pipelineInfo.nggState.forceCullingMode = settings.nggForceCullingMode; #endif - pCreateInfo->pipelineInfo.nggState.alwaysUsePrimShaderTable = settings.nggAlwaysUsePrimShaderTable; - pCreateInfo->pipelineInfo.nggState.compactMode = + pCreateInfo->pipelineInfo.nggState.alwaysUsePrimShaderTable = settings.nggAlwaysUsePrimShaderTable; + pCreateInfo->pipelineInfo.nggState.compactMode = static_cast(settings.nggCompactionMode); #if LLPC_CLIENT_INTERFACE_MAJOR_VERSION < 45 - pCreateInfo->pipelineInfo.nggState.enableFastLaunch = false; + pCreateInfo->pipelineInfo.nggState.enableFastLaunch = false; #endif - pCreateInfo->pipelineInfo.nggState.enableVertexReuse = false; - pCreateInfo->pipelineInfo.nggState.enableBackfaceCulling = settings.nggEnableBackfaceCulling; - pCreateInfo->pipelineInfo.nggState.enableFrustumCulling = settings.nggEnableFrustumCulling; - pCreateInfo->pipelineInfo.nggState.enableBoxFilterCulling = settings.nggEnableBoxFilterCulling; - pCreateInfo->pipelineInfo.nggState.enableSphereCulling = settings.nggEnableSphereCulling; - pCreateInfo->pipelineInfo.nggState.enableSmallPrimFilter = settings.nggEnableSmallPrimFilter; - pCreateInfo->pipelineInfo.nggState.enableCullDistanceCulling = settings.nggEnableCullDistanceCulling; + pCreateInfo->pipelineInfo.nggState.enableVertexReuse = false; + pCreateInfo->pipelineInfo.nggState.enableBackfaceCulling = settings.nggEnableBackfaceCulling; + pCreateInfo->pipelineInfo.nggState.enableFrustumCulling = settings.nggEnableFrustumCulling; + pCreateInfo->pipelineInfo.nggState.enableBoxFilterCulling = settings.nggEnableBoxFilterCulling; + pCreateInfo->pipelineInfo.nggState.enableSphereCulling = settings.nggEnableSphereCulling; + pCreateInfo->pipelineInfo.nggState.enableSmallPrimFilter = settings.nggEnableSmallPrimFilter; + pCreateInfo->pipelineInfo.nggState.enableCullDistanceCulling = settings.nggEnableCullDistanceCulling; if (settings.disableNggCulling) { uint32_t disableNggCullingMask = (settings.disableNggCulling & DisableNggCullingAlways); - uint32_t numTargets = 0; + uint32_t numTargets = 0; for (uint32_t i = 0; i < Pal::MaxColorTargets; ++i) { @@ -1453,79 +1443,78 @@ VkResult PipelineCompiler::ConvertGraphicsPipelineInfo( } } - pCreateInfo->pipelineInfo.nggState.backfaceExponent = settings.nggBackfaceExponent; - pCreateInfo->pipelineInfo.nggState.subgroupSizing = + pCreateInfo->pipelineInfo.nggState.backfaceExponent = settings.nggBackfaceExponent; + pCreateInfo->pipelineInfo.nggState.subgroupSizing = static_cast(settings.nggSubgroupSizing); - pCreateInfo->pipelineInfo.nggState.primsPerSubgroup = settings.nggPrimsPerSubgroup; - pCreateInfo->pipelineInfo.nggState.vertsPerSubgroup = settings.nggVertsPerSubgroup; + pCreateInfo->pipelineInfo.nggState.primsPerSubgroup = settings.nggPrimsPerSubgroup; + pCreateInfo->pipelineInfo.nggState.vertsPerSubgroup = settings.nggVertsPerSubgroup; } +} - pCreateInfo->flags = flags; - - ApplyPipelineOptions(pDevice, flags, &pCreateInfo->pipelineInfo.options); - - // Build the LLPC pipeline - Vkgc::PipelineShaderInfo* shaderInfos[] = - { - &pCreateInfo->pipelineInfo.vs, - &pCreateInfo->pipelineInfo.tcs, - &pCreateInfo->pipelineInfo.tes, - &pCreateInfo->pipelineInfo.gs, - &pCreateInfo->pipelineInfo.fs - }; - - // Apply patches - pCreateInfo->pipelineInfo.pInstance = pInstance; - pCreateInfo->pipelineInfo.pfnOutputAlloc = AllocateShaderOutput; - - uint32_t stageMask = 0; - - for (uint32_t stage = 0; stage < ShaderStage::ShaderStageGfxCount; ++stage) +// ===================================================================================================================== +static void BuildPipelineShaderInfo( + const Device* pDevice, + const ShaderStageInfo* pShaderInfoIn, + Vkgc::PipelineShaderInfo* pShaderInfoOut, + Vkgc::PipelineOptions* pPipelineOptions, + PipelineOptimizerKey* pOptimizerKey, + Vkgc::NggState* pNggState + ) +{ + if (pShaderInfoIn != nullptr) { - auto pStage = pStageInfos[stage]; - auto pShaderInfo = shaderInfos[stage]; + const Pal::DeviceProperties& deviceProp = pDevice->VkPhysicalDevice(DefaultDeviceIndex)->PalProperties(); + const Vkgc::ShaderStage stage = pShaderInfoIn->stage; - if (pStage == nullptr) - continue; + PipelineCompiler* pCompiler = pDevice->GetCompiler(DefaultDeviceIndex); - stageMask |= (1 << stage); + pShaderInfoOut->pModuleData = ShaderModule::GetFirstValidShaderData(pShaderInfoIn->pModuleHandle); + pShaderInfoOut->pSpecializationInfo = pShaderInfoIn->pSpecializationInfo; + pShaderInfoOut->pEntryTarget = pShaderInfoIn->pEntryPoint; + pShaderInfoOut->entryStage = stage; - auto pShaderModule = ShaderModule::ObjectFromHandle(pStage->module); - pShaderInfo->pModuleData = pShaderModule->GetFirstValidShaderData(); - pShaderInfo->pSpecializationInfo = pStage->pSpecializationInfo; - pShaderInfo->pEntryTarget = pStage->pName; - pShaderInfo->entryStage = static_cast(stage); + pCompiler->ApplyDefaultShaderOptions(stage, + &pShaderInfoOut->options + ); - ApplyDefaultShaderOptions(static_cast(stage), - &pShaderInfo->options - ); - - if ((pStage->flags & VK_PIPELINE_SHADER_STAGE_CREATE_ALLOW_VARYING_SUBGROUP_SIZE_BIT_EXT) != 0) + if ((pShaderInfoIn->flags & VK_PIPELINE_SHADER_STAGE_CREATE_ALLOW_VARYING_SUBGROUP_SIZE_BIT_EXT) != 0) { - pShaderInfo->options.allowVaryWaveSize = true; + pShaderInfoOut->options.allowVaryWaveSize = true; } ApplyProfileOptions(pDevice, - static_cast(stage), - pShaderModule, - &pCreateInfo->pipelineInfo.options, - pShaderInfo, - &pCreateInfo->pipelineProfileKey, - &pCreateInfo->pipelineInfo.nggState + stage, + pShaderInfoIn->codeHash, + pShaderInfoIn->codeSize, + pPipelineOptions, + pShaderInfoOut, + pOptimizerKey, + pNggState ); } +} + +// ===================================================================================================================== +static VkResult BuildPipelineResourceMapping( + const Device* pDevice, + const PipelineLayout* pLayout, + const uint32_t stageMask, + const VbBindingInfo* pVbInfo, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + VkResult result = VK_SUCCESS; if ((pLayout != nullptr) && (pLayout->GetPipelineInfo()->mappingBufferSize > 0)) { size_t genericMappingBufferSize = pLayout->GetPipelineInfo()->mappingBufferSize; - size_t tempBufferSize = genericMappingBufferSize + pCreateInfo->mappingBufferSize; - pCreateInfo->pTempBuffer = pInstance->AllocMem(tempBufferSize, - VK_DEFAULT_MEM_ALIGN, - VK_SYSTEM_ALLOCATION_SCOPE_COMMAND); + size_t tempBufferSize = genericMappingBufferSize + pCreateInfo->mappingBufferSize; + pCreateInfo->pTempBuffer = pDevice->VkInstance()->AllocMem(tempBufferSize, + VK_DEFAULT_MEM_ALIGN, + VK_SYSTEM_ALLOCATION_SCOPE_COMMAND); if (pCreateInfo->pTempBuffer == nullptr) { @@ -1537,47 +1526,337 @@ VkResult PipelineCompiler::ConvertGraphicsPipelineInfo( // NOTE: Zero the allocated space that is used to create pipeline resource mappings. Some // fields of resource mapping nodes are unused for certain node types. We must initialize - // them to zeroes. + // them to zeros. memset(pCreateInfo->pTempBuffer, 0, tempBufferSize); // Build the LLPC resource mapping description. This data contains things about how shader // inputs like descriptor set bindings are communicated to this pipeline in a form that // LLPC can understand. result = pLayout->BuildLlpcPipelineMapping(stageMask, + pVbInfo, pCreateInfo->pTempBuffer, - &pCreateInfo->pipelineInfo.resourceMapping, - pCreateInfo->pipelineInfo.pVertexInput, - pVbInfo); + &pCreateInfo->pipelineInfo.resourceMapping); } } - pCreateInfo->compilerType = CheckCompilerType(&pCreateInfo->pipelineInfo); + return result; +} + +// ===================================================================================================================== +template +static void BuildPipelineShadersInfo( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + const GraphicsPipelineShaderStageInfo* pShaderInfo, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + + pCreateInfo->flags = pIn->flags; + + pDevice->GetCompiler(DefaultDeviceIndex)->ApplyPipelineOptions(pDevice, pIn->flags, &pCreateInfo->pipelineInfo.options); + + Vkgc::PipelineShaderInfo* ppShaderInfoOut[] = + { + &pCreateInfo->pipelineInfo.vs, + &pCreateInfo->pipelineInfo.tcs, + &pCreateInfo->pipelineInfo.tes, + &pCreateInfo->pipelineInfo.gs, + &pCreateInfo->pipelineInfo.fs, + }; for (uint32_t stage = 0; stage < ShaderStage::ShaderStageGfxCount; ++stage) { - auto pStage = pStageInfos[stage]; - auto pShaderInfo = shaderInfos[stage]; + if (pShaderInfo->stages[stage].pModuleHandle != nullptr) + { + BuildPipelineShaderInfo(pDevice, + &pShaderInfo->stages[stage], + ppShaderInfoOut[stage], + &pCreateInfo->pipelineInfo.options, + &pCreateInfo->pipelineProfileKey, + &pCreateInfo->pipelineInfo.nggState + ); + } + } - if (pStage == nullptr) - continue; + pCreateInfo->compilerType = pDevice->GetCompiler(DefaultDeviceIndex)->CheckCompilerType(&pCreateInfo->pipelineInfo); - auto pShaderModule = ShaderModule::ObjectFromHandle(pStage->module); - pShaderInfo->pModuleData = pShaderModule->GetShaderData(pCreateInfo->compilerType); + for (uint32_t stage = 0; stage < ShaderStage::ShaderStageGfxCount; ++stage) + { + if (((shaderMask & (1 << stage)) != 0) && (pShaderInfo->stages[stage].pModuleHandle != nullptr)) + { + ppShaderInfoOut[stage]->pModuleData = + ShaderModule::GetShaderData(pCreateInfo->compilerType, pShaderInfo->stages[stage].pModuleHandle); + } } +} - if (pIn->pDynamicState != nullptr) +// ===================================================================================================================== +static void BuildColorBlendState( + const Device* pDevice, + const VkPipelineColorBlendStateCreateInfo* pCb, + const RenderPass* pRenderPass, + const uint32_t subpass, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + bool dualSourceBlendEnabled = false; + + if (pCb != nullptr) { - for( uint32_t ndx = 0; ndx < pIn->pDynamicState->dynamicStateCount; ++ndx) + const uint32_t numColorTargets = Util::Min(pCb->attachmentCount, Pal::MaxColorTargets); + + for (uint32_t i = 0; i < numColorTargets; ++i) { - if(pIn->pDynamicState->pDynamicStates[ndx] == VK_DYNAMIC_STATE_VERTEX_INPUT_BINDING_STRIDE_EXT) + const VkPipelineColorBlendAttachmentState& src = pCb->pAttachments[i]; + auto pLlpcCbDst = &pCreateInfo->pipelineInfo.cbState.target[i]; + + VkFormat cbFormat = VK_FORMAT_UNDEFINED; + + if (pRenderPass != nullptr) { - pCreateInfo->pipelineInfo.dynamicVertexStride = true; - break; + cbFormat = pRenderPass->GetColorAttachmentFormat(subpass, i); + } + + // If the sub pass attachment format is UNDEFINED, then it means that that subpass does not + // want to write to any attachment for that output (VK_ATTACHMENT_UNUSED). Under such cases, + // disable shader writes through that target. There is one exception for alphaToCoverageEnable + // and attachment zero, which can be set to VK_ATTACHMENT_UNUSED. + if ((cbFormat != VK_FORMAT_UNDEFINED) || (i == 0u)) + { + VkFormat renderPassFormat = ((pRenderPass != nullptr) ? + pRenderPass->GetAttachmentDesc(i).format : + VK_FORMAT_UNDEFINED); + + pLlpcCbDst->format = (cbFormat != VK_FORMAT_UNDEFINED) ? + cbFormat : renderPassFormat; + + pLlpcCbDst->blendEnable = (src.blendEnable == VK_TRUE); + pLlpcCbDst->blendSrcAlphaToColor = + GraphicsPipelineCommon::IsSrcAlphaUsedInBlend(src.srcAlphaBlendFactor) || + GraphicsPipelineCommon::IsSrcAlphaUsedInBlend(src.dstAlphaBlendFactor) || + GraphicsPipelineCommon::IsSrcAlphaUsedInBlend(src.srcColorBlendFactor) || + GraphicsPipelineCommon::IsSrcAlphaUsedInBlend(src.dstColorBlendFactor); + pLlpcCbDst->channelWriteMask = src.colorWriteMask; + } + } + + dualSourceBlendEnabled = GraphicsPipelineCommon::GetDualSourceBlendEnableState(pDevice, pCb); + } + + pCreateInfo->pipelineInfo.cbState.dualSourceBlendEnable = dualSourceBlendEnabled; + + VkFormat dbFormat = VK_FORMAT_UNDEFINED; + + if (pRenderPass != nullptr) + { + dbFormat = pRenderPass->GetDepthStencilAttachmentFormat(subpass); + } + + pCreateInfo->dbFormat = dbFormat; +} + +// ===================================================================================================================== +static void BuildVertexInputInterfaceState( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + const uint32_t dynamicStateFlags, + GraphicsPipelineBinaryCreateInfo* pCreateInfo, + VbBindingInfo* pVbInfo) +{ + VK_ASSERT(pIn->pVertexInputState); + + pCreateInfo->pipelineInfo.pVertexInput = pIn->pVertexInputState; + pCreateInfo->pipelineInfo.iaState.topology = pIn->pInputAssemblyState->topology; + pCreateInfo->pipelineInfo.iaState.disableVertexReuse = false; + + if (IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::VertexInputBindingStrideExt) == true) + { + pCreateInfo->pipelineInfo.dynamicVertexStride = true; + } + + BuildLlpcVertexInputDescriptors(pDevice, pIn->pVertexInputState, pVbInfo); +} + +// ===================================================================================================================== +static void BuildPreRasterizationShaderState( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + const GraphicsPipelineShaderStageInfo* pShaderInfo, + const uint32_t dynamicStateFlags, + const VkShaderStageFlagBits activeStages, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + const RenderPass* pRenderPass = RenderPass::ObjectFromHandle(pIn->renderPass); + + BuildRasterizationState(pIn->pRasterizationState, dynamicStateFlags, pCreateInfo); + + BuildViewportState(pDevice, pIn->pViewportState, dynamicStateFlags, pCreateInfo); + + BuildNggState(pDevice, activeStages, pCreateInfo); + + if (activeStages & (VK_SHADER_STAGE_TESSELLATION_CONTROL_BIT | VK_SHADER_STAGE_TESSELLATION_EVALUATION_BIT)) + { + EXTRACT_VK_STRUCTURES_1( + Tess, + PipelineTessellationStateCreateInfo, + PipelineTessellationDomainOriginStateCreateInfo, + pIn->pTessellationState, + PIPELINE_TESSELLATION_STATE_CREATE_INFO, + PIPELINE_TESSELLATION_DOMAIN_ORIGIN_STATE_CREATE_INFO) + + if (pPipelineTessellationStateCreateInfo != nullptr) + { + pCreateInfo->pipelineInfo.iaState.patchControlPoints = pPipelineTessellationStateCreateInfo->patchControlPoints; + } + + if (pPipelineTessellationDomainOriginStateCreateInfo) + { + // Vulkan 1.0 incorrectly specified the tessellation u,v coordinate origin as lower left even though + // framebuffer and image coordinate origins are in the upper left. This has since been fixed, but + // an extension exists to use the previous behavior. Doing so with flat shading would likely appear + // incorrect, but Vulkan specifies that the provoking vertex is undefined when tessellation is active. + if (pPipelineTessellationDomainOriginStateCreateInfo->domainOrigin == VK_TESSELLATION_DOMAIN_ORIGIN_LOWER_LEFT) + { + pCreateInfo->pipelineInfo.iaState.switchWinding = true; } } } - pCreateInfo->freeCompilerBinary = FreeWithCompiler; + BuildPipelineShadersInfo(pDevice, pIn, pShaderInfo, pCreateInfo); +} + +// ===================================================================================================================== +static void BuildFragmentShaderState( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + const GraphicsPipelineShaderStageInfo* pShaderInfo, + const uint32_t dynamicStateFlags, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + const RenderPass* pRenderPass = RenderPass::ObjectFromHandle(pIn->renderPass); + + BuildMultisampleState(pDevice, pIn->pMultisampleState, pRenderPass, pIn->subpass, dynamicStateFlags, pCreateInfo); + + BuildPipelineShadersInfo(pDevice, pIn, pShaderInfo, pCreateInfo); + + // Handle VkPipelineDepthStencilStateCreateInfo + if (pIn->pDepthStencilState != nullptr) + { + } +} + +// ===================================================================================================================== +static void BuildFragmentOutputInterfaceState( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + GraphicsPipelineBinaryCreateInfo* pCreateInfo) +{ + const RenderPass* pRenderPass = RenderPass::ObjectFromHandle(pIn->renderPass); + + BuildColorBlendState(pDevice, + pIn->pColorBlendState, + pRenderPass, pIn->subpass, pCreateInfo); + + pCreateInfo->pipelineInfo.iaState.enableMultiView = + (pRenderPass != nullptr) ? pRenderPass->IsMultiviewEnabled() : + false; + + // Handle VkPipelineDepthStencilStateCreateInfo + if (pIn->pDepthStencilState != nullptr) + { + } +} + +// ===================================================================================================================== +static VkResult BuildExecutablePipelineState( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + const uint32_t dynamicStateFlags, + GraphicsPipelineBinaryCreateInfo* pCreateInfo, + VbBindingInfo* pVbInfo) +{ + const RuntimeSettings& settings = pDevice->GetRuntimeSettings(); + PipelineCompiler* pDefaultCompiler = pDevice->GetCompiler(DefaultDeviceIndex); + + const PipelineLayout* pLayout = PipelineLayout::ObjectFromHandle(pIn->layout); + + if (pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable == true) + { + pCreateInfo->pipelineInfo.rsState.numSamples = 1; + pCreateInfo->pipelineInfo.rsState.perSampleShading = false; + pCreateInfo->pipelineInfo.rsState.samplePatternIdx = 0; + pCreateInfo->pipelineInfo.cbState.alphaToCoverageEnable = false; + pCreateInfo->pipelineInfo.options.enableInterpModePatch = false; + + memset(pCreateInfo->pipelineInfo.cbState.target, 0, sizeof(pCreateInfo->pipelineInfo.cbState.target)); + + pCreateInfo->pipelineInfo.cbState.dualSourceBlendEnable = false; + } + + Vkgc::PipelineShaderInfo* shaderInfos[] = + { + &pCreateInfo->pipelineInfo.vs, + &pCreateInfo->pipelineInfo.tcs, + &pCreateInfo->pipelineInfo.tes, + &pCreateInfo->pipelineInfo.gs, + &pCreateInfo->pipelineInfo.fs, + }; + + uint32_t availableStageMask = 0; + + for (uint32_t stage = 0; stage < ShaderStage::ShaderStageGfxCount; ++stage) + { + if (shaderInfos[stage]->pModuleData != nullptr) + { + availableStageMask |= (1 << stage); + } + } + + VkResult result = BuildPipelineResourceMapping(pDevice, pLayout, availableStageMask, pVbInfo, pCreateInfo); + + return result; +} + +// ===================================================================================================================== +// Converts Vulkan graphics pipeline parameters to an internal structure +VkResult PipelineCompiler::ConvertGraphicsPipelineInfo( + const Device* pDevice, + const VkGraphicsPipelineCreateInfo* pIn, + const GraphicsPipelineShaderStageInfo* pShaderInfo, + GraphicsPipelineBinaryCreateInfo* pCreateInfo, + VbBindingInfo* pVbInfo) +{ + VK_ASSERT(pIn != nullptr); + + VkResult result = VK_SUCCESS; + + const VkGraphicsPipelineCreateInfo* pGraphicsPipelineCreateInfo = pIn; + + VkShaderStageFlagBits activeStages = GraphicsPipelineCommon::GetActiveShaderStages( + pIn + ); + + uint32_t dynamicStateFlags = GraphicsPipelineCommon::GetDynamicStateFlags( + pIn->pDynamicState + ); + + BuildVertexInputInterfaceState(pDevice, pIn, dynamicStateFlags, pCreateInfo, pVbInfo); + + BuildPreRasterizationShaderState(pDevice, pIn, pShaderInfo, dynamicStateFlags, activeStages, pCreateInfo); + + const bool enableRasterization = + (pCreateInfo->pipelineInfo.rsState.rasterizerDiscardEnable == false) || + IsDynamicStateEnabled(dynamicStateFlags, DynamicStatesInternal::RasterizerDiscardEnableExt); + + if (enableRasterization) + { + BuildFragmentShaderState(pDevice, pIn, pShaderInfo, dynamicStateFlags, pCreateInfo); + + BuildFragmentOutputInterfaceState(pDevice, pIn, pCreateInfo); + } + + { + result = BuildExecutablePipelineState(pDevice, pIn, dynamicStateFlags, pCreateInfo, pVbInfo); + } return result; } @@ -1657,15 +1936,15 @@ void PipelineCompiler::ApplyPipelineOptions( pOptions->enableRelocatableShaderElf = settings.enableRelocatableShaders; pOptions->disableImageResourceCheck = settings.disableImageResourceTypeCheck; - if (pDevice->GetEnabledFeatures().extendedRobustness.robustBufferAccess) + if (pDevice->GetEnabledFeatures().robustBufferAccessExtended) { pOptions->extendedRobustness.robustBufferAccess = true; } - if (pDevice->GetEnabledFeatures().extendedRobustness.robustImageAccess) + if (pDevice->GetEnabledFeatures().robustImageAccessExtended) { pOptions->extendedRobustness.robustImageAccess = true; } - if (pDevice->GetEnabledFeatures().extendedRobustness.nullDescriptor) + if (pDevice->GetEnabledFeatures().nullDescriptorExtended) { pOptions->extendedRobustness.nullDescriptor = true; } @@ -1674,10 +1953,10 @@ void PipelineCompiler::ApplyPipelineOptions( // ===================================================================================================================== // Converts Vulkan compute pipeline parameters to an internal structure VkResult PipelineCompiler::ConvertComputePipelineInfo( - Device* pDevice, + const Device* pDevice, const VkComputePipelineCreateInfo* pIn, - ComputePipelineBinaryCreateInfo* pCreateInfo, - const VkPipelineCreationFeedbackCreateInfoEXT** ppPipelineCreationFeadbackCreateInfo) + const ComputePipelineShaderStageInfo* pShaderInfo, + ComputePipelineBinaryCreateInfo* pCreateInfo) { VkResult result = VK_SUCCESS; @@ -1687,10 +1966,6 @@ VkResult PipelineCompiler::ConvertComputePipelineInfo( VK_ASSERT(pIn->sType == VK_STRUCTURE_TYPE_COMPUTE_PIPELINE_CREATE_INFO); - GetPipelineCreationInfoNext( - reinterpret_cast(pIn->pNext), - ppPipelineCreationFeadbackCreateInfo); - if (pIn->layout != VK_NULL_HANDLE) { pLayout = PipelineLayout::ObjectFromHandle(pIn->layout); @@ -1700,14 +1975,13 @@ VkResult PipelineCompiler::ConvertComputePipelineInfo( ApplyPipelineOptions(pDevice, pIn->flags, &pCreateInfo->pipelineInfo.options); - ShaderModule* pShaderModule = ShaderModule::ObjectFromHandle(pIn->stage.module); - - pCreateInfo->pipelineInfo.cs.pModuleData = pShaderModule->GetFirstValidShaderData(); - pCreateInfo->pipelineInfo.cs.pSpecializationInfo = pIn->stage.pSpecializationInfo; - pCreateInfo->pipelineInfo.cs.pEntryTarget = pIn->stage.pName; + pCreateInfo->pipelineInfo.cs.pModuleData = + ShaderModule::GetFirstValidShaderData(pShaderInfo->stage.pModuleHandle); + pCreateInfo->pipelineInfo.cs.pSpecializationInfo = pShaderInfo->stage.pSpecializationInfo; + pCreateInfo->pipelineInfo.cs.pEntryTarget = pShaderInfo->stage.pEntryPoint; pCreateInfo->pipelineInfo.cs.entryStage = Vkgc::ShaderStageCompute; - if ((pIn->stage.flags & VK_PIPELINE_SHADER_STAGE_CREATE_ALLOW_VARYING_SUBGROUP_SIZE_BIT_EXT) != 0) + if ((pShaderInfo->stage.flags & VK_PIPELINE_SHADER_STAGE_CREATE_ALLOW_VARYING_SUBGROUP_SIZE_BIT_EXT) != 0) { pCreateInfo->pipelineInfo.cs.options.allowVaryWaveSize = true; } @@ -1739,15 +2013,15 @@ VkResult PipelineCompiler::ConvertComputePipelineInfo( // inputs like descriptor set bindings are communicated to this pipeline in a form that // LLPC can understand. result = pLayout->BuildLlpcPipelineMapping(Vkgc::ShaderStageComputeBit, - pCreateInfo->pTempBuffer, - &pCreateInfo->pipelineInfo.resourceMapping, nullptr, - nullptr); + pCreateInfo->pTempBuffer, + &pCreateInfo->pipelineInfo.resourceMapping); } } pCreateInfo->compilerType = CheckCompilerType(&pCreateInfo->pipelineInfo); - pCreateInfo->pipelineInfo.cs.pModuleData = pShaderModule->GetShaderData(pCreateInfo->compilerType); + pCreateInfo->pipelineInfo.cs.pModuleData = + ShaderModule::GetShaderData(pCreateInfo->compilerType, pShaderInfo->stage.pModuleHandle);; ApplyDefaultShaderOptions(ShaderStage::ShaderStageCompute, &pCreateInfo->pipelineInfo.cs.options @@ -1755,7 +2029,8 @@ VkResult PipelineCompiler::ConvertComputePipelineInfo( ApplyProfileOptions(pDevice, ShaderStage::ShaderStageCompute, - pShaderModule, + pShaderInfo->stage.codeHash, + pShaderInfo->stage.codeSize, nullptr, &pCreateInfo->pipelineInfo.cs, &pCreateInfo->pipelineProfileKey, @@ -1803,45 +2078,6 @@ void PipelineCompiler::ApplyDefaultShaderOptions( } -// ===================================================================================================================== -// Builds app profile key and applies profile options. -void PipelineCompiler::ApplyProfileOptions( - Device* pDevice, - ShaderStage stage, - ShaderModule* pShaderModule, - Vkgc::PipelineOptions* pPipelineOptions, - Vkgc::PipelineShaderInfo* pShaderInfo, - PipelineOptimizerKey* pProfileKey, - Vkgc::NggState* pNggState - ) -{ - auto& settings = m_pPhysicalDevice->GetRuntimeSettings(); - PipelineShaderOptionsPtr options = {}; - options.pPipelineOptions = pPipelineOptions; - options.pOptions = &pShaderInfo->options; - options.pNggState = pNggState; - - auto& shaderKey = pProfileKey->shaders[stage]; - if (settings.pipelineUseShaderHashAsProfileHash) - { - const void* pModuleData = pShaderInfo->pModuleData; - shaderKey.codeHash.lower = Vkgc::IPipelineDumper::GetShaderHash(pModuleData); - shaderKey.codeHash.upper = 0; - } - else - { - // Populate the pipeline profile key. The hash used by the profile is different from the default - // internal hash in that it only depends on the SPIRV code + entry point. This is to reduce the - // chance that internal changes to our hash calculation logic drop us off pipeline profiles. - shaderKey.codeHash = pShaderModule->GetCodeHash(pShaderInfo->pEntryTarget); - } - shaderKey.codeSize = pShaderModule->GetCodeSize(); - - // Override the compile parameters based on any app profile - auto* pShaderOptimizer = pDevice->GetShaderOptimizer(); - pShaderOptimizer->OverrideShaderCreateInfo(*pProfileKey, stage, options); -} - // ===================================================================================================================== // Free compute pipeline binary void PipelineCompiler::FreeComputePipelineBinary( diff --git a/icd/api/vk_buffer.cpp b/icd/api/vk_buffer.cpp index 5a881b9b..c77b281c 100644 --- a/icd/api/vk_buffer.cpp +++ b/icd/api/vk_buffer.cpp @@ -291,8 +291,6 @@ void Buffer::LogBufferCreate( static_cast(PalUsageFlag::TransformFeedbackCounterBuffer), "Usage Flag Mismatch"); static_assert(VK_BUFFER_USAGE_CONDITIONAL_RENDERING_BIT_EXT == static_cast(PalUsageFlag::ConditionalRendering), "Usage Flag Mismatch"); - static_assert(VK_BUFFER_USAGE_RAY_TRACING_BIT_NV == - static_cast(PalUsageFlag::RayTracing), "Usage Flag Mismatch"); static_assert(VK_BUFFER_USAGE_SHADER_DEVICE_ADDRESS_BIT_EXT == static_cast(PalUsageFlag::ShaderDeviceAddress), "Usage Flag Mismatch"); diff --git a/icd/api/vk_cmdbuffer.cpp b/icd/api/vk_cmdbuffer.cpp index 58ce8bed..366d6e77 100644 --- a/icd/api/vk_cmdbuffer.cpp +++ b/icd/api/vk_cmdbuffer.cpp @@ -241,7 +241,7 @@ Pal::Result CreateClearRegions ( // Returns Pal::Result::Success if completed successfully. template Pal::Result CreateClearSubresRanges( - const vk::ImageView* pColorImageView, + const vk::ImageView* pImageView, const VkClearAttachment& clearInfo, const uint32_t rectCount, const VkClearRect* const pRects, @@ -254,15 +254,30 @@ Pal::Result CreateClearSubresRanges( Pal::Result palResult = Pal::Result::Success; Pal::SubresRange subresRange = {}; - pColorImageView->GetFrameBufferAttachmentSubresRange(&subresRange); + pImageView->GetFrameBufferAttachmentSubresRange(&subresRange); pOutClearSubresRanges->Clear(); + bool hasPlaneDepthAndStencil = false; + + if (pImageView->GetImage()->HasStencil() && pImageView->GetImage()->HasDepth()) + { + if (clearInfo.aspectMask == VK_IMAGE_ASPECT_STENCIL_BIT) + { + subresRange.startSubres.plane = 1; + } + else + { + hasPlaneDepthAndStencil = (clearInfo.aspectMask == + (VK_IMAGE_ASPECT_STENCIL_BIT | VK_IMAGE_ASPECT_DEPTH_BIT)); + } + } + if (viewMask > 0) { const auto layerRanges = RangesOfOnesInBitMask(viewMask); - palResult = pOutClearSubresRanges->Reserve(layerRanges.NumElements()); + palResult = pOutClearSubresRanges->Reserve(layerRanges.NumElements() *(hasPlaneDepthAndStencil ? 2 : 1)); if (palResult == Pal::Result::Success) { @@ -271,12 +286,20 @@ Pal::Result CreateClearSubresRanges( pOutClearSubresRanges->PushBack(subresRange); pOutClearSubresRanges->Back().startSubres.arraySlice += layerRangeIt.Get().offset; pOutClearSubresRanges->Back().numSlices = layerRangeIt.Get().extent; + + if (hasPlaneDepthAndStencil) + { + subresRange.startSubres.plane = 1; + pOutClearSubresRanges->PushBack(subresRange); + pOutClearSubresRanges->Back().startSubres.arraySlice += layerRangeIt.Get().offset; + pOutClearSubresRanges->Back().numSlices = layerRangeIt.Get().extent; + } } } } else { - palResult = pOutClearSubresRanges->Reserve(rectCount); + palResult = pOutClearSubresRanges->Reserve(rectCount *(hasPlaneDepthAndStencil ? 2 : 1)); if (palResult == Pal::Result::Success) { @@ -285,6 +308,14 @@ Pal::Result CreateClearSubresRanges( pOutClearSubresRanges->PushBack(subresRange); pOutClearSubresRanges->Back().startSubres.arraySlice += pRects[rectIndex].baseArrayLayer; pOutClearSubresRanges->Back().numSlices = pRects[rectIndex].layerCount; + + if (hasPlaneDepthAndStencil) + { + subresRange.startSubres.plane = 1; + pOutClearSubresRanges->PushBack(subresRange); + pOutClearSubresRanges->Back().startSubres.arraySlice += pRects[rectIndex].baseArrayLayer; + pOutClearSubresRanges->Back().numSlices = pRects[rectIndex].layerCount; + } } } } @@ -438,6 +469,7 @@ CmdBuffer::CmdBuffer( m_curDeviceMask(0), m_rpDeviceMask(0), m_cbBeginDeviceMask(0), + m_numPalDevices(pDevice->NumPalDevices()), m_validShaderStageFlags(pDevice->VkPhysicalDevice(DefaultDeviceIndex)->GetValidShaderStages(queueFamilyIndex)), m_pStackAllocator(nullptr), m_flags(), @@ -575,7 +607,7 @@ VkResult CmdBuffer::Initialize( size_t palMemOffset = 0; const size_t palSize = m_pDevice->PalDevice(DefaultDeviceIndex)->GetCmdBufferSize(groupCreateInfo, &result); - const uint32_t numGroupedCmdBuffers = m_pDevice->NumPalDevices(); + const uint32_t numGroupedCmdBuffers = m_numPalDevices; for (uint32_t groupedIdx = 0; (groupedIdx < numGroupedCmdBuffers) && (result == Pal::Result::Success); groupedIdx++) { @@ -709,7 +741,10 @@ Pal::Result CmdBuffer::PalCmdBufferReset(Pal::ICmdAllocator* pCmdAllocator, bool } while (deviceGroup.IterateNext()); - m_cbBeginDeviceMask = 0; + if (returnGpuMemory) + { + m_cbBeginDeviceMask = 0; + } } return result; @@ -1320,7 +1355,7 @@ VkResult CmdBuffer::Begin( // Dirty all the dynamic states, the bit should be cleared with 0 when the corresponding state is // static. - m_allGpuState.dirty.u32All = 0xFFFFFFFF; + m_allGpuState.dirtyGraphics.u32All = 0xFFFFFFFF; if ((m_palQueueType == Pal::QueueTypeUniversal) && m_flags.preBindDefaultState) { @@ -1340,7 +1375,7 @@ VkResult CmdBuffer::Begin( while (deviceGroupVrs.IterateNext()); } - m_allGpuState.dirty.vrs = 0; + m_allGpuState.dirtyGraphics.vrs = 0; } DbgBarrierPostCmd(DbgBarrierCmdBufStart); @@ -1405,7 +1440,7 @@ void CmdBuffer::ResetPipelineState() m_allGpuState.palToApiPipeline[uint32_t(Pal::PipelineBindPoint::Compute)] = PipelineBindCompute; m_allGpuState.palToApiPipeline[uint32_t(Pal::PipelineBindPoint::Graphics)] = PipelineBindGraphics; - const uint32_t numPalDevices = m_pDevice->NumPalDevices(); + const uint32_t numPalDevices = m_numPalDevices; uint32_t deviceIdx = 0; do @@ -1462,16 +1497,15 @@ void CmdBuffer::ResetState() VkResult CmdBuffer::Reset(VkCommandBufferResetFlags flags) { VkResult result = VK_SUCCESS; + bool releaseResources = ((flags & VK_COMMAND_BUFFER_RESET_RELEASE_RESOURCES_BIT) != 0); - if (m_flags.wasBegun) + if (m_flags.disableResetReleaseResources) { - bool releaseResources = ((flags & VK_COMMAND_BUFFER_RESET_RELEASE_RESOURCES_BIT) != 0); - - if (m_flags.disableResetReleaseResources) - { - releaseResources = false; - } + releaseResources = false; + } + if (m_flags.wasBegun || releaseResources) + { // If the command buffer is being recorded, the stack allocator will still be around. // Make sure to free it. if (m_flags.isRecording) @@ -1637,15 +1671,15 @@ void CmdBuffer::BindPipeline( { DbgBarrierPreCmd(DbgBarrierBindPipeline); + const Pipeline* pPipeline = Pipeline::BaseObjectFromHandle(pipeline); + switch (pipelineBindPoint) { case VK_PIPELINE_BIND_POINT_COMPUTE: { - const ComputePipeline* pPipeline = ComputePipeline::ObjectFromHandle(pipeline); - - if (pPipeline != m_allGpuState.pComputePipeline) + if (m_allGpuState.pComputePipeline != pPipeline) { - m_allGpuState.pComputePipeline = pPipeline; + m_allGpuState.pComputePipeline = static_cast(pPipeline); if (PalPipelineBindingOwnedBy(Pal::PipelineBindPoint::Compute, PipelineBindCompute)) { @@ -1660,11 +1694,9 @@ void CmdBuffer::BindPipeline( case VK_PIPELINE_BIND_POINT_GRAPHICS: { - const GraphicsPipeline* pPipeline = GraphicsPipeline::ObjectFromHandle(pipeline); - if (m_allGpuState.pGraphicsPipeline != pPipeline) { - m_allGpuState.pGraphicsPipeline = pPipeline; + m_allGpuState.pGraphicsPipeline = static_cast(pPipeline); // Can bind the graphics pipeline immediately since only API graphics pipelines use the PAL // graphics pipeline. Note that wave limits may still defer the bind inside RebindPipeline(). @@ -2114,7 +2146,7 @@ void CmdBuffer::BindIndexBuffer( // Initializes VB binding manager state. Should be called when the command buffer is being initialized. void CmdBuffer::InitializeVertexBuffer() { - for (uint32 deviceIdx = 0; deviceIdx < m_pDevice->NumPalDevices(); deviceIdx++) + for (uint32 deviceIdx = 0; deviceIdx < m_numPalDevices; deviceIdx++) { Pal::BufferViewInfo* pBindings = &PerGpuState(deviceIdx)->vbBindings[0]; @@ -2136,7 +2168,7 @@ void CmdBuffer::InitializeVertexBuffer() // Called to reset the state of the VB manager because the parent command buffer is being reset. void CmdBuffer::ResetVertexBuffer() { - for (uint32 deviceIdx = 0; deviceIdx < m_pDevice->NumPalDevices(); deviceIdx++) + for (uint32 deviceIdx = 0; deviceIdx < m_numPalDevices; deviceIdx++) { Pal::BufferViewInfo* pBindings = &PerGpuState(deviceIdx)->vbBindings[0]; @@ -3017,15 +3049,16 @@ void CmdBuffer::ClearAttachments( uint32_t rectCount, const VkClearRect* pRects) { - if ((m_flags.is2ndLvl == false) && (m_allGpuState.pFramebuffer != nullptr)) { - ClearImageAttachments(attachmentCount, pAttachments, rectCount, pRects); - } - else - { - ClearBoundAttachments(attachmentCount, pAttachments, rectCount, pRects); + if ((m_flags.is2ndLvl == false) && (m_allGpuState.pFramebuffer != nullptr)) + { + ClearImageAttachments(attachmentCount, pAttachments, rectCount, pRects); + } + else + { + ClearBoundAttachments(attachmentCount, pAttachments, rectCount, pRects); + } } - } // ===================================================================================================================== @@ -3700,7 +3733,7 @@ void CmdBuffer::ExecuteBarriers( return; } - const Image** pTransitionImages = (m_pDevice->NumPalDevices() > 1) && (imageMemoryBarrierCount > 0) ? + const Image** pTransitionImages = (m_numPalDevices > 1) && (imageMemoryBarrierCount > 0) ? virtStackFrame.AllocArray(MaxTransitionCount) : nullptr; for (uint32_t i = 0; i < memBarrierCount; ++i) @@ -5420,7 +5453,7 @@ void CmdBuffer::BeginRenderPass( { utils::IterateMask deviceGroup(pDeviceGroupRenderPassBeginInfo->deviceMask); - VK_ASSERT(m_pDevice->NumPalDevices() == pDeviceGroupRenderPassBeginInfo->deviceRenderAreaCount); + VK_ASSERT(m_numPalDevices == pDeviceGroupRenderPassBeginInfo->deviceRenderAreaCount); do { @@ -5442,11 +5475,11 @@ void CmdBuffer::BeginRenderPass( if (replicateRenderArea) { - m_renderPassInstance.renderAreaCount = m_pDevice->NumPalDevices(); + m_renderPassInstance.renderAreaCount = m_numPalDevices; const auto& srcRect = pRenderPassBeginInfo->renderArea; - for (uint32_t deviceIdx = 0; deviceIdx < m_pDevice->NumPalDevices(); deviceIdx++) + for (uint32_t deviceIdx = 0; deviceIdx < m_numPalDevices; deviceIdx++) { auto* pDstRect = &m_renderPassInstance.renderArea[deviceIdx]; @@ -6609,7 +6642,7 @@ void CmdBuffer::SetViewport( } while (deviceGroup.IterateNext()); - m_allGpuState.dirty.viewport = 1; + m_allGpuState.dirtyGraphics.viewport = 1; m_allGpuState.staticTokens.viewports = DynamicRenderStateToken; } @@ -6648,7 +6681,7 @@ void CmdBuffer::SetAllViewports( } while (deviceGroup.IterateNext()); - m_allGpuState.dirty.viewport = 1; + m_allGpuState.dirtyGraphics.viewport = 1; m_allGpuState.staticTokens.viewports = staticToken; } @@ -6670,7 +6703,7 @@ void CmdBuffer::SetScissor( } while (deviceGroup.IterateNext()); - m_allGpuState.dirty.scissor = 1; + m_allGpuState.dirtyGraphics.scissor = 1; m_allGpuState.staticTokens.scissorRect = DynamicRenderStateToken; } @@ -6710,7 +6743,7 @@ void CmdBuffer::SetAllScissors( } while (deviceGroup.IterateNext()); - m_allGpuState.dirty.scissor = 1; + m_allGpuState.dirtyGraphics.scissor = 1; m_allGpuState.staticTokens.scissorRect = staticToken; } @@ -6821,7 +6854,7 @@ void CmdBuffer::SetStencilCompareMask( m_allGpuState.stencilRefMasks.backReadMask = static_cast(stencilCompareMask); } - m_allGpuState.dirty.stencilRef = 1; + m_allGpuState.dirtyGraphics.stencilRef = 1; } // ===================================================================================================================== @@ -6838,7 +6871,7 @@ void CmdBuffer::SetStencilWriteMask( m_allGpuState.stencilRefMasks.backWriteMask = static_cast(stencilWriteMask); } - m_allGpuState.dirty.stencilRef = 1; + m_allGpuState.dirtyGraphics.stencilRef = 1; } // ===================================================================================================================== @@ -6855,7 +6888,7 @@ void CmdBuffer::SetStencilReference( m_allGpuState.stencilRefMasks.backRef = static_cast(stencilReference); } - m_allGpuState.dirty.stencilRef = 1; + m_allGpuState.dirtyGraphics.stencilRef = 1; } #if VK_ENABLE_DEBUG_BARRIERS @@ -7201,7 +7234,7 @@ void CmdBuffer::CmdSetPerDrawVrsRate( // Don't call CmdSetPerDrawVrsRate here since we have to observe the // currently bound pipeline to see if we should clamp the rate. // Calling Pal->CmdSetPerDrawVrsRate will happen in ValidateStates - m_allGpuState.dirty.vrs = 1; + m_allGpuState.dirtyGraphics.vrs = 1; m_allGpuState.staticTokens.fragmentShadingRate = DynamicRenderStateToken; } @@ -7263,7 +7296,7 @@ void CmdBuffer::CmdEndConditionalRendering() // ===================================================================================================================== void CmdBuffer::ValidateStates() { - if (m_allGpuState.dirty.u32All != 0) + if (m_allGpuState.dirtyGraphics.u32All != 0) { Pal::IDepthStencilState* pPalDepthStencil[MaxPalDevices] = {}; @@ -7272,7 +7305,7 @@ void CmdBuffer::ValidateStates() { const uint32_t deviceIdx = deviceGroup.Index(); - if (m_allGpuState.dirty.viewport) + if (m_allGpuState.dirtyGraphics.viewport) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7281,7 +7314,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.scissor) + if (m_allGpuState.dirtyGraphics.scissor) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7290,7 +7323,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.rasterState) + if (m_allGpuState.dirtyGraphics.rasterState) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7299,7 +7332,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.stencilRef) + if (m_allGpuState.dirtyGraphics.stencilRef) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7308,7 +7341,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.inputAssembly) + if (m_allGpuState.dirtyGraphics.inputAssembly) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7317,7 +7350,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.vrs) + if (m_allGpuState.dirtyGraphics.vrs) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7339,7 +7372,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.depthStencil) + if (m_allGpuState.dirtyGraphics.depthStencil) { RenderStateCache* pRSCache = m_pDevice->GetRenderStateCache(); @@ -7398,7 +7431,7 @@ void CmdBuffer::ValidateStates() pPalDepthStencil[deviceIdx]); } - if (m_allGpuState.dirty.colorWriteEnable) + if (m_allGpuState.dirtyGraphics.colorWriteEnable) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7408,7 +7441,7 @@ void CmdBuffer::ValidateStates() DbgBarrierPostCmd(DbgBarrierSetDynamicPipelineState); } - if (m_allGpuState.dirty.rasterizerDiscardEnable) + if (m_allGpuState.dirtyGraphics.rasterizerDiscardEnable) { DbgBarrierPreCmd(DbgBarrierSetDynamicPipelineState); @@ -7420,7 +7453,7 @@ void CmdBuffer::ValidateStates() while (deviceGroup.IterateNext()); // Clear the dirty bits - m_allGpuState.dirty.u32All = 0; + m_allGpuState.dirtyGraphics.u32All = 0; } } @@ -7433,7 +7466,7 @@ void CmdBuffer::SetCullModeEXT( if (m_allGpuState.triangleRasterState.cullMode != palCullMode) { m_allGpuState.triangleRasterState.cullMode = palCullMode; - m_allGpuState.dirty.rasterState = 1; + m_allGpuState.dirtyGraphics.rasterState = 1; } m_allGpuState.staticTokens.triangleRasterState = DynamicRenderStateToken; @@ -7448,7 +7481,7 @@ void CmdBuffer::SetFrontFaceEXT( if (m_allGpuState.triangleRasterState.frontFace != palFrontFace) { m_allGpuState.triangleRasterState.frontFace = palFrontFace; - m_allGpuState.dirty.rasterState = 1; + m_allGpuState.dirtyGraphics.rasterState = 1; } m_allGpuState.staticTokens.triangleRasterState = DynamicRenderStateToken; @@ -7463,7 +7496,7 @@ void CmdBuffer::SetPrimitiveTopologyEXT( if (m_allGpuState.inputAssemblyState.topology != palTopology) { m_allGpuState.inputAssemblyState.topology = palTopology; - m_allGpuState.dirty.inputAssembly = 1; + m_allGpuState.dirtyGraphics.inputAssembly = 1; } m_allGpuState.staticTokens.inputAssemblyState = DynamicRenderStateToken; @@ -7476,7 +7509,7 @@ void CmdBuffer::SetDepthTestEnableEXT( if (m_allGpuState.depthStencilCreateInfo.depthEnable != static_cast(depthTestEnable)) { m_allGpuState.depthStencilCreateInfo.depthEnable = depthTestEnable; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } @@ -7487,7 +7520,7 @@ void CmdBuffer::SetDepthWriteEnableEXT( if (m_allGpuState.depthStencilCreateInfo.depthWriteEnable != static_cast(depthWriteEnable)) { m_allGpuState.depthStencilCreateInfo.depthWriteEnable = depthWriteEnable; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } @@ -7500,7 +7533,7 @@ void CmdBuffer::SetDepthCompareOpEXT( if (m_allGpuState.depthStencilCreateInfo.depthFunc != compareOp) { m_allGpuState.depthStencilCreateInfo.depthFunc = compareOp; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } @@ -7511,7 +7544,7 @@ void CmdBuffer::SetDepthBoundsTestEnableEXT( if (m_allGpuState.depthStencilCreateInfo.depthBoundsEnable != static_cast(depthBoundsTestEnable)) { m_allGpuState.depthStencilCreateInfo.depthBoundsEnable = depthBoundsTestEnable; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } @@ -7522,7 +7555,7 @@ void CmdBuffer::SetStencilTestEnableEXT( if (m_allGpuState.depthStencilCreateInfo.stencilEnable != static_cast(stencilTestEnable)) { m_allGpuState.depthStencilCreateInfo.stencilEnable = stencilTestEnable; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } @@ -7553,7 +7586,7 @@ void CmdBuffer::SetStencilOpEXT( pCreateInfo->front.stencilDepthFailOp = palDepthFailOp; pCreateInfo->front.stencilFunc = palCompareOp; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } @@ -7569,7 +7602,7 @@ void CmdBuffer::SetStencilOpEXT( pCreateInfo->back.stencilDepthFailOp = palDepthFailOp; pCreateInfo->back.stencilFunc = palCompareOp; - m_allGpuState.dirty.depthStencil = 1; + m_allGpuState.dirtyGraphics.depthStencil = 1; } } } @@ -7595,7 +7628,7 @@ void CmdBuffer::SetColorWriteEnableEXT( } } - m_allGpuState.dirty.colorWriteEnable = 1; + m_allGpuState.dirtyGraphics.colorWriteEnable = 1; } } @@ -7604,7 +7637,7 @@ void CmdBuffer::SetRasterizerDiscardEnableEXT( VkBool32 rasterizerDiscardEnable) { m_allGpuState.rasterizerDiscardEnable = rasterizerDiscardEnable; - m_allGpuState.dirty.rasterizerDiscardEnable = 1; + m_allGpuState.dirtyGraphics.rasterizerDiscardEnable = 1; } // ===================================================================================================================== @@ -7614,7 +7647,7 @@ void CmdBuffer::SetPrimitiveRestartEnableEXT( if (m_allGpuState.inputAssemblyState.primitiveRestartEnable != static_cast(primitiveRestartEnable)) { m_allGpuState.inputAssemblyState.primitiveRestartEnable = primitiveRestartEnable; - m_allGpuState.dirty.inputAssembly = 1; + m_allGpuState.dirtyGraphics.inputAssembly = 1; } m_allGpuState.staticTokens.inputAssemblyState = DynamicRenderStateToken; @@ -7627,7 +7660,7 @@ void CmdBuffer::SetDepthBiasEnableEXT( if (m_allGpuState.triangleRasterState.flags.depthBiasEnable != depthBiasEnable) { m_allGpuState.triangleRasterState.flags.depthBiasEnable = depthBiasEnable; - m_allGpuState.dirty.rasterState = 1; + m_allGpuState.dirtyGraphics.rasterState = 1; } m_allGpuState.staticTokens.triangleRasterState = DynamicRenderStateToken; diff --git a/icd/api/vk_compute_pipeline.cpp b/icd/api/vk_compute_pipeline.cpp index fc4bbc44..3118c0a7 100644 --- a/icd/api/vk_compute_pipeline.cpp +++ b/icd/api/vk_compute_pipeline.cpp @@ -45,9 +45,10 @@ namespace vk // - pCreateInfo->pStage // - pCreateInfo->layout uint64_t ComputePipeline::BuildApiHash( - const VkComputePipelineCreateInfo* pCreateInfo, - Util::MetroHash::Hash* pBaseHash) + const VkComputePipelineCreateInfo* pCreateInfo) { + Util::MetroHash::Hash bashHash; + Util::MetroHash128 baseHasher; Util::MetroHash128 apiHasher; @@ -64,11 +65,11 @@ uint64_t ComputePipeline::BuildApiHash( apiHasher.Update(pCreateInfo->basePipelineIndex); - baseHasher.Finalize(reinterpret_cast(pBaseHash)); + baseHasher.Finalize(reinterpret_cast(&bashHash)); uint64_t apiHash; Util::MetroHash::Hash apiHashFull; - apiHasher.Update(*pBaseHash); + apiHasher.Update(bashHash); apiHasher.Finalize(reinterpret_cast(&apiHashFull)); apiHash = Util::MetroHash::Compact64(&apiHashFull); @@ -103,7 +104,9 @@ ComputePipeline::ComputePipeline( uint32_t staticStateMask, uint64_t apiHash) : - Pipeline(pDevice, VK_PIPELINE_BIND_POINT_COMPUTE), + Pipeline( + pDevice, + VK_PIPELINE_BIND_POINT_COMPUTE), m_info(immedInfo) { Pipeline::Init(pPalPipeline, pPipelineLayout, pPipelineBinary, staticStateMask, apiHash); @@ -134,13 +137,28 @@ VkResult ComputePipeline::Create( Util::MetroHash::Hash cacheId[MaxPalDevices] = {}; PipelineCompiler* pDefaultCompiler = pDevice->GetCompiler(DefaultDeviceIndex); ComputePipelineBinaryCreateInfo binaryCreateInfo = {}; - uint64_t apiPsoHash = BuildApiHash( - pCreateInfo, - &binaryCreateInfo.basePipelineHash); + uint64_t apiPsoHash = BuildApiHash(pCreateInfo); + + const VkPipelineCreationFeedbackCreateInfoEXT* pPipelineCreationFeedbackCreateInfo = nullptr; + pDefaultCompiler->GetPipelineCreationFeedback(static_cast(pCreateInfo->pNext), + &pPipelineCreationFeedbackCreateInfo); + + ComputePipelineShaderStageInfo shaderInfo = {}; + ShaderModuleHandle tempModule = {}; + VkResult result = BuildShaderStageInfo(pDevice, + 1, + &pCreateInfo->stage, + [](const uint32_t inputIdx, const uint32_t stageIdx) + { + return 0u; + }, + &shaderInfo.stage, + &tempModule); - const VkPipelineCreationFeedbackCreateInfoEXT* pPipelineCreationFeadbackCreateInfo = nullptr; - VkResult result = pDefaultCompiler->ConvertComputePipelineInfo( - pDevice, pCreateInfo, &binaryCreateInfo, &pPipelineCreationFeadbackCreateInfo); + if (result == VK_SUCCESS) + { + result = pDefaultCompiler->ConvertComputePipelineInfo(pDevice, pCreateInfo, &shaderInfo, &binaryCreateInfo); + } uint64_t pipelineHash = Vkgc::IPipelineDumper::GetPipelineHash(&binaryCreateInfo.pipelineInfo); for (uint32_t deviceIdx = 0; @@ -278,6 +296,7 @@ VkResult ComputePipeline::Create( if (result == VK_SUCCESS) { + // On success, wrap it up in a Vulkan object and return. VK_PLACEMENT_NEW(pSystemMem) ComputePipeline(pDevice, pPalPipeline, @@ -301,6 +320,9 @@ VkResult ComputePipeline::Create( } } + // Free the temporary newly-built shader modules + FreeTempModules(pDevice, 1, &tempModule); + // Free the created pipeline binaries now that the PAL Pipelines/PipelineBinaryInfo have read them. for (uint32_t deviceIdx = 0; deviceIdx < pDevice->NumPalDevices(); deviceIdx++) { @@ -332,7 +354,7 @@ VkResult ComputePipeline::Create( binaryCreateInfo.pipelineFeedback.feedbackValid = true; binaryCreateInfo.pipelineFeedback.duration = duration; pDefaultCompiler->SetPipelineCreationFeedbackInfo( - pPipelineCreationFeadbackCreateInfo, + pPipelineCreationFeedbackCreateInfo, 0, nullptr, &binaryCreateInfo.pipelineFeedback, diff --git a/icd/api/vk_device.cpp b/icd/api/vk_device.cpp index 92af992e..fc252172 100644 --- a/icd/api/vk_device.cpp +++ b/icd/api/vk_device.cpp @@ -73,6 +73,10 @@ #include "appopt/async_layer.h" +#if VKI_GPU_DECOMPRESS +#include "appopt/gpu_decode_layer.h" +#endif + #include "appopt/barrier_filter_layer.h" #include "appopt/strange_brigade_layer.h" @@ -148,47 +152,74 @@ namespace vk // ===================================================================================================================== // Returns VK_SUCCESS if all requested features are supported, VK_ERROR_FEATURE_NOT_PRESENT otherwise. -template static VkResult VerifyRequestedPhysicalDeviceFeatures( const PhysicalDevice* pPhysicalDevice, - const T* pRequestedFeatures) + VirtualStackFrame* pVirtStackFrame, + const void* pRequestedFeatures, + bool isPhysicalDeviceFeature) { - T supportedFeatures; size_t headerSize; + size_t structSize; - // Start by making a copy of the requested features all so that uninitialized struct padding always matches below. - memcpy(&supportedFeatures, pRequestedFeatures, sizeof(T)); + VkBool32* pSupportedFeatures = nullptr; + VkStructHeaderNonConst structSizeFeaturesHeader = {}; + structSizeFeaturesHeader.sType = static_cast(pRequestedFeatures)->sType; + VkResult result = VK_SUCCESS; - if (std::is_same::value) - { - pPhysicalDevice->GetFeatures(reinterpret_cast(&supportedFeatures)); + structSize = isPhysicalDeviceFeature ? pPhysicalDevice->GetFeatures(nullptr) : + pPhysicalDevice->GetFeatures2((&structSizeFeaturesHeader), false); - // The original VkPhysicalDeviceFeatures struct doesn't contain a VkStructHeader - headerSize = 0; - } - else + // allocate appropriate sized memory to pSupportedFeatures + pSupportedFeatures = pVirtStackFrame->AllocArray(structSize/sizeof(VkBool32)); + + if ((pSupportedFeatures != nullptr) && (structSize != 0)) { - VkStructHeaderNonConst* pHeader = reinterpret_cast(&supportedFeatures); + // Start by making a copy of the requested features all so that uninitialized struct padding always matches below. + memcpy(pSupportedFeatures, pRequestedFeatures, structSize); - pHeader->pNext = nullptr; // Make sure GetFeatures2 doesn't clobber the original requested features chain - pPhysicalDevice->GetFeatures2(pHeader); + if (isPhysicalDeviceFeature) + { + VkPhysicalDeviceFeatures* pPhysicalDeviceFeatures = reinterpret_cast(pSupportedFeatures); - headerSize = offsetof(VkPhysicalDeviceFeatures2, features); - } + pPhysicalDevice->GetFeatures(pPhysicalDeviceFeatures); - const size_t numFeatures = (sizeof(T) - headerSize) / sizeof(VkBool32); // Struct padding may give us extra features - const auto supported = static_cast(Util::VoidPtrInc(&supportedFeatures, headerSize)); - const auto requested = static_cast(Util::VoidPtrInc(pRequestedFeatures, headerSize)); + // The original VkPhysicalDeviceFeatures struct doesn't contain a VkStructHeader + headerSize = 0; + } + else + { + VkStructHeaderNonConst* pHeader = reinterpret_cast(pSupportedFeatures); - for (size_t featureNdx = 0; featureNdx < numFeatures; ++featureNdx) - { - if (requested[featureNdx] && !supported[featureNdx]) + pHeader->pNext = nullptr; // Make sure GetFeatures2 doesn't clobber the original requested features chain + + // update the features using default true + pPhysicalDevice->GetFeatures2(pHeader, true); + + headerSize = offsetof(VkPhysicalDeviceFeatures2, features); + } + + const size_t numFeatures = (structSize - headerSize) / sizeof(VkBool32); // Struct padding may give us extra features + const auto supported = static_cast(Util::VoidPtrInc(pSupportedFeatures, headerSize)); + const auto requested = static_cast(Util::VoidPtrInc(pRequestedFeatures, headerSize)); + + for (size_t featureNdx = 0; featureNdx < numFeatures; ++featureNdx) { - return VK_ERROR_FEATURE_NOT_PRESENT; + if (requested[featureNdx] && !supported[featureNdx]) + { + result = VK_ERROR_FEATURE_NOT_PRESENT; + + break; + } } } + else + { + result = VK_ERROR_OUT_OF_HOST_MEMORY; + } - return VK_SUCCESS; + pVirtStackFrame->FreeArray(pSupportedFeatures); + + return result; } // ===================================================================================================================== @@ -228,6 +259,9 @@ Device::Device( m_pAsyncLayer(nullptr), m_pAppOptLayer(nullptr), m_pBarrierFilterLayer(nullptr), +#if VKI_GPU_DECOMPRESS + m_pGpuDecoderLayer(nullptr), +#endif m_allocationSizeTracking(m_settings.memoryDeviceOverallocationAllowed ? false : true), m_useComputeAsTransferQueue(useComputeAsTransferQueue), m_useGlobalGpuVa(false) @@ -443,536 +477,189 @@ VkResult Device::Create( const VkStructHeader* pHeader = nullptr; - for (pHeader = static_cast(pCreateInfo->pNext); - ((pHeader != nullptr) && (vkResult == VK_SUCCESS)); - pHeader = pHeader->pNext) - { - switch (static_cast(pHeader->sType)) - { - case VK_STRUCTURE_TYPE_DEVICE_GROUP_DEVICE_CREATE_INFO: - { - const VkDeviceGroupDeviceCreateInfo* pDeviceGroupCreateInfo = - reinterpret_cast(pHeader); - - numDevices = pDeviceGroupCreateInfo->physicalDeviceCount; - - VK_ASSERT(numDevices <= MaxPalDevices); - numDevices = Util::Min(numDevices, MaxPalDevices); - - for (uint32_t deviceIdx = 0; deviceIdx < numDevices; deviceIdx++) - { - pPhysicalDevice = ApiPhysicalDevice::ObjectFromHandle( - pDeviceGroupCreateInfo->pPhysicalDevices[deviceIdx]); - - pPalDevices[deviceIdx] = pPhysicalDevice->PalDevice(); - pPhysicalDevices[deviceIdx] = pPhysicalDevice; - - VK_ASSERT(pInstance == pPhysicalDevice->VkInstance()); - } - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FEATURES_2: - { - const auto pPhysicalDeviceFeatures2 = reinterpret_cast(pHeader); - - VK_ASSERT(pCreateInfo->pEnabledFeatures == nullptr); - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pPhysicalDeviceFeatures2); - - // If present, VkPhysicalDeviceFeatures2 controls which features are enabled instead of pEnabledFeatures - pEnabledFeatures = &pPhysicalDeviceFeatures2->features; - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_16BIT_STORAGE_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_8BIT_STORAGE_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_GPA_FEATURES_AMD: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SAMPLER_YCBCR_CONVERSION_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VARIABLE_POINTER_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROTECTED_MEMORY_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MULTIVIEW_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_DRAW_PARAMETER_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_DESCRIPTOR_INDEXING_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FLOAT16_INT8_FEATURES_KHR: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + VirtualStackAllocator* pStackAllocator = nullptr; - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + palResult = pInstance->StackMgr()->AcquireAllocator(&pStackAllocator); - break; - } + if (palResult == Pal::Result::Success) + { + VirtualStackFrame virtStackFrame(pStackAllocator); - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SCALAR_BLOCK_LAYOUT_FEATURES: + for (pHeader = static_cast(pCreateInfo->pNext); + ((pHeader != nullptr) && (vkResult == VK_SUCCESS)); + pHeader = pHeader->pNext) { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->scalarBlockLayout) + switch (static_cast(pHeader->sType)) { - scalarBlockLayoutEnabled = true; - } - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TRANSFORM_FEEDBACK_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_MEMORY_MODEL_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_DEMOTE_TO_HELPER_INVOCATION_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_IMAGE_ATOMIC_INT64_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_ATOMIC_INT64_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PIPELINE_CREATION_CACHE_CONTROL_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MEMORY_PRIORITY_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_DEPTH_CLIP_ENABLE_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_HOST_QUERY_RESET_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_BUFFER_DEVICE_ADDRESS_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->bufferDeviceAddressMultiDevice) + case VK_STRUCTURE_TYPE_DEVICE_GROUP_DEVICE_CREATE_INFO: { - bufferDeviceAddressMultiDeviceEnabled = true; - } - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_LINE_RASTERIZATION_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_UNIFORM_BUFFER_STANDARD_LAYOUT_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SEPARATE_DEPTH_STENCIL_LAYOUTS_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_CLOCK_FEATURES_KHR: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_SUBGROUP_EXTENDED_TYPES_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SUBGROUP_SIZE_CONTROL_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGELESS_FRAMEBUFFER_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PIPELINE_EXECUTABLE_PROPERTIES_FEATURES_KHR: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TIMELINE_SEMAPHORE_FEATURES: - { + const VkDeviceGroupDeviceCreateInfo* pDeviceGroupCreateInfo = + reinterpret_cast(pHeader); - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + numDevices = pDeviceGroupCreateInfo->physicalDeviceCount; - break; - } - case VK_STRUCTURE_TYPE_DEVICE_MEMORY_OVERALLOCATION_CREATE_INFO_AMD: - { - const VkDeviceMemoryOverallocationCreateInfoAMD* pMemoryOverallocationCreateInfo = - reinterpret_cast(pHeader); + VK_ASSERT(numDevices <= MaxPalDevices); + numDevices = Util::Min(numDevices, MaxPalDevices); - overallocationBehavior = pMemoryOverallocationCreateInfo->overallocationBehavior; + for (uint32_t deviceIdx = 0; deviceIdx < numDevices; deviceIdx++) + { + pPhysicalDevice = ApiPhysicalDevice::ObjectFromHandle( + pDeviceGroupCreateInfo->pPhysicalDevices[deviceIdx]); - break; - } + pPalDevices[deviceIdx] = pPhysicalDevice->PalDevice(); + pPhysicalDevices[deviceIdx] = pPhysicalDevice; - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VERTEX_ATTRIBUTE_DIVISOR_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); - - break; - } + VK_ASSERT(pInstance == pPhysicalDevice->VkInstance()); + } + break; + } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FEATURES_2: + { + VK_ASSERT(pCreateInfo->pEnabledFeatures == nullptr); - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COHERENT_MEMORY_FEATURES_AMD: - { - const VkPhysicalDeviceCoherentMemoryFeaturesAMD * pDeviceCoherentMemory = - reinterpret_cast(pHeader); - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pDeviceCoherentMemory); + // If present, VkPhysicalDeviceFeatures2 controls which features are enabled instead of pEnabledFeatures + pEnabledFeatures = &reinterpret_cast(pHeader)->features; - if (vkResult == VK_SUCCESS) - { - deviceCoherentMemoryEnabled = enabledDeviceExtensions.IsExtensionEnabled( - DeviceExtensions::AMD_DEVICE_COHERENT_MEMORY) && - pDeviceCoherentMemory->deviceCoherentMemory; + break; } - break; - } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SCALAR_BLOCK_LAYOUT_FEATURES: + { + if (reinterpret_cast(pHeader)->scalarBlockLayout) + { + scalarBlockLayoutEnabled = true; + } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_1_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + break; + } - break; - } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_BUFFER_DEVICE_ADDRESS_FEATURES: + { + if (reinterpret_cast(pHeader)->bufferDeviceAddressMultiDevice) + { + bufferDeviceAddressMultiDeviceEnabled = true; + } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_2_FEATURES: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + break; + } - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->scalarBlockLayout) + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TIMELINE_SEMAPHORE_FEATURES: { - scalarBlockLayoutEnabled = true; + + break; } - break; - } + case VK_STRUCTURE_TYPE_DEVICE_MEMORY_OVERALLOCATION_CREATE_INFO_AMD: + { + const VkDeviceMemoryOverallocationCreateInfoAMD* pMemoryOverallocationCreateInfo = + reinterpret_cast(pHeader); - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FRAGMENT_SHADING_RATE_FEATURES_KHR: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + overallocationBehavior = pMemoryOverallocationCreateInfo->overallocationBehavior; - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->attachmentFragmentShadingRate) - { - attachmentFragmentShadingRate = true; + break; } - break; - } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_CONDITIONAL_RENDERING_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COHERENT_MEMORY_FEATURES_AMD: + { - break; - } + deviceCoherentMemoryEnabled = enabledDeviceExtensions.IsExtensionEnabled( + DeviceExtensions::AMD_DEVICE_COHERENT_MEMORY) && + reinterpret_cast(pHeader)->deviceCoherentMemory; - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TEXEL_BUFFER_ALIGNMENT_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + break; + } - break; - } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_VULKAN_1_2_FEATURES: + { - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_ROBUSTNESS_2_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + if (reinterpret_cast(pHeader)->scalarBlockLayout) + { + scalarBlockLayoutEnabled = true; + } - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->robustBufferAccess2) - { - extendedRobustnessEnabled.robustBufferAccess = true; + break; } - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->robustImageAccess2) + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FRAGMENT_SHADING_RATE_FEATURES_KHR: { - extendedRobustnessEnabled.robustImageAccess = true; + + if (reinterpret_cast(pHeader)->attachmentFragmentShadingRate) + { + attachmentFragmentShadingRate = true; + } + break; } - if ((vkResult == VK_SUCCESS) && - reinterpret_cast(pHeader)->nullDescriptor) + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_ROBUSTNESS_2_FEATURES_EXT: { - extendedRobustnessEnabled.nullDescriptor = true; - } - break; - } + if (reinterpret_cast(pHeader)->robustBufferAccess2) + { + extendedRobustnessEnabled.robustBufferAccess = true; + } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_EXTENDED_DYNAMIC_STATE_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + if (reinterpret_cast(pHeader)->robustImageAccess2) + { + extendedRobustnessEnabled.robustImageAccess = true; + } - break; - } + if (reinterpret_cast(pHeader)->nullDescriptor) + { + extendedRobustnessEnabled.nullDescriptor = true; + } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRIVATE_DATA_FEATURES_EXT: - { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - reinterpret_cast(pHeader)); + break; + } - if (vkResult == VK_SUCCESS) + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRIVATE_DATA_FEATURES_EXT: { privateDataEnabled = reinterpret_cast(pHeader)->privateData; - } - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_ROBUSTNESS_FEATURES_EXT: - { - const VkPhysicalDeviceImageRobustnessFeaturesEXT* pImageRobustnessFeatures = - reinterpret_cast(pHeader); - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pImageRobustnessFeatures); - - if ((vkResult == VK_SUCCESS) && - pImageRobustnessFeatures->robustImageAccess) - { - extendedRobustnessEnabled.robustImageAccess = true; + break; } - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_4444_FORMATS_FEATURES_EXT: - { - const auto* pFeatures = reinterpret_cast(pHeader); - - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pFeatures); - - break; - } - - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COLOR_WRITE_ENABLE_FEATURES_EXT: - { - const auto pColorWriteEnableFeatures = - reinterpret_cast(pHeader); - - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pColorWriteEnableFeatures); - - break; - } + case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_ROBUSTNESS_FEATURES_EXT: + { + if (reinterpret_cast(pHeader)->robustImageAccess) + { + extendedRobustnessEnabled.robustImageAccess = true; + } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_YCBCR_IMAGE_ARRAYS_FEATURES_EXT: - { - const auto pYcbcrImageArraysFeatures = - reinterpret_cast(pHeader); + break; + } - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pYcbcrImageArraysFeatures); + default: + break; + } - break; + // TODO Remove below check after physical device properties for the following extensions are added. + // The loader device create info should be ignored by the driver. + if ((static_cast(pHeader->sType) != VK_STRUCTURE_TYPE_LOADER_DEVICE_CREATE_INFO) + && (static_cast(pHeader->sType) != VK_STRUCTURE_TYPE_DEVICE_GROUP_DEVICE_CREATE_INFO) + && (static_cast(pHeader->sType) != VK_STRUCTURE_TYPE_DEVICE_PRIVATE_DATA_CREATE_INFO_EXT) + && (static_cast(pHeader->sType) != VK_STRUCTURE_TYPE_DEVICE_MEMORY_OVERALLOCATION_CREATE_INFO_AMD)) + { + vkResult = VerifyRequestedPhysicalDeviceFeatures(pPhysicalDevice, &virtStackFrame, pHeader, false); + } } - case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_ZERO_INITIALIZE_WORKGROUP_MEMORY_FEATURES_KHR: + // If the pNext chain includes a VkPhysicalDeviceFeatures2 structure, then pEnabledFeatures must be NULL. + if ((vkResult == VK_SUCCESS) && (pCreateInfo->pEnabledFeatures != nullptr)) { - const auto* pFeatures = reinterpret_cast(pHeader); - - vkResult = VerifyRequestedPhysicalDeviceFeatures( + vkResult = VerifyRequestedPhysicalDeviceFeatures( pPhysicalDevice, - pFeatures); - - break; + &virtStackFrame, + pCreateInfo->pEnabledFeatures, + true); } - default: - break; - } + // Release the stack allocator + pInstance->StackMgr()->ReleaseAllocator(pStackAllocator); } - - // If the pNext chain includes a VkPhysicalDeviceFeatures2 structure, then pEnabledFeatures must be NULL. - if ((vkResult == VK_SUCCESS) && (pCreateInfo->pEnabledFeatures != nullptr)) + else { - vkResult = VerifyRequestedPhysicalDeviceFeatures( - pPhysicalDevice, - pCreateInfo->pEnabledFeatures); + vkResult = PalToVkResult(palResult); } for (uint32 i = 0; ((i < pCreateInfo->queueCreateInfoCount) && (vkResult == VK_SUCCESS)); ++i) @@ -1507,9 +1194,11 @@ VkResult Device::Initialize( deviceProps.engineProperties[Pal::EngineTypeDma].minTimestampAlignment : deviceProps.engineProperties[Pal::EngineTypeUniversal].minTimestampAlignment; - m_enabledFeatures.deviceCoherentMemory = deviceCoherentMemoryEnabled; - m_enabledFeatures.scalarBlockLayout = scalarBlockLayoutEnabled; - m_enabledFeatures.extendedRobustness = extendedRobustnessEnabled; + m_enabledFeatures.deviceCoherentMemory = deviceCoherentMemoryEnabled; + m_enabledFeatures.scalarBlockLayout = scalarBlockLayoutEnabled; + m_enabledFeatures.robustBufferAccessExtended = extendedRobustnessEnabled.robustBufferAccess; + m_enabledFeatures.robustImageAccessExtended = extendedRobustnessEnabled.robustImageAccess; + m_enabledFeatures.nullDescriptorExtended = extendedRobustnessEnabled.nullDescriptor; // If VkPhysicalDeviceBufferDeviceAddressFeaturesEXT.bufferDeviceAddressMultiDevice is enabled // and if globalGpuVaSupport is supported and if multiple devices are used set the global GpuVa. @@ -1625,6 +1314,25 @@ VkResult Device::Initialize( } } +#if VKI_GPU_DECOMPRESS + if ((result == VK_SUCCESS) && (m_settings.enableShaderDecode)) + { + void* pGpuDecoderLayer = nullptr; + + pGpuDecoderLayer = VkInstance()->AllocMem(sizeof(GpuDecoderLayer), VK_SYSTEM_ALLOCATION_SCOPE_DEVICE); + + if (pGpuDecoderLayer != nullptr) + { + m_pGpuDecoderLayer = VK_PLACEMENT_NEW(pGpuDecoderLayer) GpuDecoderLayer(this); + result = m_pGpuDecoderLayer->Init(this); + } + else + { + result = VK_ERROR_OUT_OF_HOST_MEMORY; + } + } +#endif + if ((result == VK_SUCCESS) && m_settings.enableAsyncCompile) { void* pMemory = VkInstance()->AllocMem(sizeof(AsyncLayer), VK_SYSTEM_ALLOCATION_SCOPE_DEVICE); @@ -1784,6 +1492,13 @@ void Device::InitDispatchTable() m_pAsyncLayer->OverrideDispatchTable(&m_dispatchTable); } +#if VKI_GPU_DECOMPRESS + if (m_pGpuDecoderLayer != nullptr) + { + m_pGpuDecoderLayer->OverrideDispatchTable(&m_dispatchTable); + } +#endif + } // ===================================================================================================================== @@ -2009,6 +1724,14 @@ VkResult Device::Destroy(const VkAllocationCallbacks* pAllocator) VkInstance()->FreeMem(m_pAsyncLayer); } +#if VKI_GPU_DECOMPRESS + if (m_pGpuDecoderLayer != nullptr) + { + Util::Destructor(m_pGpuDecoderLayer); + VkInstance()->FreeMem(m_pGpuDecoderLayer); + } +#endif + for (uint32_t i = 0; i < Queue::MaxQueueFamilies; ++i) { for (uint32_t j = 0; (j < Queue::MaxQueuesPerFamily) && (m_pQueues[i][j] != nullptr); ++j) @@ -4348,8 +4071,12 @@ VKAPI_ATTR VkResult VKAPI_CALL vkSetGpaDeviceClockModeAMD( if (palResult == Pal::Result::Success) { - pInfo->engineClockRatioToPeak = output.engineClockRatioToPeak; - pInfo->memoryClockRatioToPeak = output.memoryClockRatioToPeak; + const Pal::DeviceProperties& properties = pDevice->VkPhysicalDevice(DefaultDeviceIndex)->PalProperties(); + + pInfo->engineClockRatioToPeak = static_cast(output.engineClockFrequency) / + properties.gfxipProperties.performance.maxGpuClock; + pInfo->memoryClockRatioToPeak = static_cast(output.memoryClockFrequency) / + properties.gpuMemoryProperties.performance.maxMemClock; } } diff --git a/icd/api/vk_formats.cpp b/icd/api/vk_formats.cpp index 3acc3f54..7ac3f5d6 100644 --- a/icd/api/vk_formats.cpp +++ b/icd/api/vk_formats.cpp @@ -32,6 +32,162 @@ #include "include/vk_conv.h" namespace vk { +#if ( VKI_GPU_DECOMPRESS) +// ===================================================================================================================== +// This function should only be called for astc formats +void Formats::GetAstcMappedInfo( + VkFormat format, + AstcMappedInfo* pMapInfo) +{ + switch (format) + { + case VK_FORMAT_ASTC_4x4_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 4; + pMapInfo->hScale = 4; + break; + case VK_FORMAT_ASTC_4x4_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 4; + pMapInfo->hScale = 4; + break; + case VK_FORMAT_ASTC_5x4_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 5; + pMapInfo->hScale = 4; + break; + case VK_FORMAT_ASTC_5x4_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 5; + pMapInfo->hScale = 4; + break; + case VK_FORMAT_ASTC_5x5_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 5; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_5x5_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 5; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_6x5_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 6; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_6x5_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 6; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_6x6_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 6; + pMapInfo->hScale = 6; + break; + case VK_FORMAT_ASTC_6x6_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 6; + pMapInfo->hScale = 6; + break; + case VK_FORMAT_ASTC_8x5_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 8; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_8x5_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 8; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_8x6_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 8; + pMapInfo->hScale = 6; + break; + case VK_FORMAT_ASTC_8x6_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 8; + pMapInfo->hScale = 6; + break; + case VK_FORMAT_ASTC_8x8_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 8; + pMapInfo->hScale = 8; + break; + case VK_FORMAT_ASTC_8x8_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 8; + pMapInfo->hScale = 8; + break; + case VK_FORMAT_ASTC_10x5_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 10; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_10x5_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 10; + pMapInfo->hScale = 5; + break; + case VK_FORMAT_ASTC_10x6_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 10; + pMapInfo->hScale = 6; + break; + case VK_FORMAT_ASTC_10x6_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 10; + pMapInfo->hScale = 6; + break; + case VK_FORMAT_ASTC_10x8_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 10; + pMapInfo->hScale = 8; + break; + case VK_FORMAT_ASTC_10x8_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 10; + pMapInfo->hScale = 8; + break; + case VK_FORMAT_ASTC_10x10_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 10; + pMapInfo->hScale = 10; + break; + case VK_FORMAT_ASTC_10x10_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 10; + pMapInfo->hScale = 10; + break; + case VK_FORMAT_ASTC_12x10_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 12; + pMapInfo->hScale = 10; + break; + case VK_FORMAT_ASTC_12x10_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 12; + pMapInfo->hScale = 10; + break; + case VK_FORMAT_ASTC_12x12_UNORM_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_UNORM; + pMapInfo->wScale = 12; + pMapInfo->hScale = 12; + break; + case VK_FORMAT_ASTC_12x12_SRGB_BLOCK: + pMapInfo->format = VK_FORMAT_R8G8B8A8_SRGB; + pMapInfo->wScale = 12; + pMapInfo->hScale = 12; + break; + default: + VK_ASSERT(IsASTCFormat(format)); + VK_NEVER_CALLED(); + break; + } +} +#endif // ===================================================================================================================== // Helper function to calculate image texels based on whether an image is compressed or not. Element is compatible to diff --git a/icd/api/vk_graphics_pipeline.cpp b/icd/api/vk_graphics_pipeline.cpp index c57135a3..519b8124 100644 --- a/icd/api/vk_graphics_pipeline.cpp +++ b/icd/api/vk_graphics_pipeline.cpp @@ -51,55 +51,24 @@ namespace vk { // ===================================================================================================================== -// Create a graphics pipeline object. -VkResult GraphicsPipeline::Create( - Device* pDevice, - PipelineCache* pPipelineCache, - const VkGraphicsPipelineCreateInfo* pCreateInfo, - const VkAllocationCallbacks* pAllocator, - VkPipeline* pPipeline) +// Create graphics pipeline binaries +VkResult GraphicsPipeline::CreatePipelineBinaries( + Device* pDevice, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + const GraphicsPipelineShaderStageInfo* pShaderInfo, + GraphicsPipelineBinaryCreateInfo* pBinaryCreateInfo, + PipelineCache* pPipelineCache, + const VkPipelineCreationFeedbackCreateInfoEXT* pCreationFeedbackInfo, + Util::MetroHash::Hash* pCacheIds, + size_t* pPipelineBinarySizes, + const void** pPipelineBinaries) { - uint64 startTimeTicks = Util::GetPerfCpuTime(); - - // Parse the create info and build patched AMDIL shaders - GraphicsPipelineObjectCreateInfo objectCreateInfo = {}; - VbBindingInfo vbInfo = {}; - GraphicsPipelineBinaryCreateInfo binaryCreateInfo = {}; - size_t pipelineBinarySizes[MaxPalDevices] = {}; - const void* pPipelineBinaries[MaxPalDevices] = {}; - Util::MetroHash::Hash cacheId[MaxPalDevices] = {}; - Pal::Result palResult = Pal::Result::Success; - PipelineCompiler* pDefaultCompiler = pDevice->GetCompiler(DefaultDeviceIndex); - const RuntimeSettings& settings = pDevice->GetRuntimeSettings(); - Util::MetroHash64 palPipelineHasher; - - const VkPipelineCreationFeedbackCreateInfoEXT* pPipelineCreationFeadbackCreateInfo = nullptr; - - VkResult result = pDefaultCompiler->ConvertGraphicsPipelineInfo( - pDevice, pCreateInfo, &binaryCreateInfo, &vbInfo, &pPipelineCreationFeadbackCreateInfo); - - BuildPipelineObjectCreateInfo(pDevice, pCreateInfo, &vbInfo, &objectCreateInfo); - - // PAL internally disables dual-source blending when the blend func is min or max. In cases when it will be disabled, we should - // overwrite dual source blending option so the pipeline is compiled with the correct value. This avoids a mismatch in how data - // comes out of shaders and how the CB expects to see the data. - // This can be done for all ASICs, but is required for GFX10+ - const bool canEnableDualSourceBlend = pDevice->PalDevice(DefaultDeviceIndex)->CanEnableDualSourceBlend(objectCreateInfo.blend); - - if (canEnableDualSourceBlend == false) - { - objectCreateInfo.pipeline.cbState.dualSourceBlendEnable = false; - binaryCreateInfo.pipelineInfo.cbState.dualSourceBlendEnable = false; - } - - uint64_t apiPsoHash = BuildApiHash(pCreateInfo, &objectCreateInfo, &binaryCreateInfo.basePipelineHash); - - const uint32_t numPalDevices = pDevice->NumPalDevices(); - - uint64_t pipelineHash = Vkgc::IPipelineDumper::GetPipelineHash(&binaryCreateInfo.pipelineInfo); + VkResult result = VK_SUCCESS; + const uint32_t numPalDevices = pDevice->NumPalDevices(); + PipelineCompiler* pDefaultCompiler = pDevice->GetCompiler(DefaultDeviceIndex); for (uint32_t i = 0; (result == VK_SUCCESS) && (i < numPalDevices) - ; ++i) + ; ++i) { if (i == DefaultDeviceIndex) { @@ -107,33 +76,31 @@ VkResult GraphicsPipeline::Create( pDevice, i, pPipelineCache, - &binaryCreateInfo, - &pipelineBinarySizes[i], + pBinaryCreateInfo, + &pPipelineBinarySizes[i], &pPipelineBinaries[i], - objectCreateInfo.rasterizationStream, - &cacheId[i]); + &pCacheIds[i]); } else { GraphicsPipelineBinaryCreateInfo binaryCreateInfoMGPU = {}; VbBindingInfo vbInfoMGPU = {}; pDefaultCompiler->ConvertGraphicsPipelineInfo( - pDevice, pCreateInfo, &binaryCreateInfoMGPU, &vbInfoMGPU, nullptr); + pDevice, pCreateInfo, pShaderInfo, &binaryCreateInfoMGPU, &vbInfoMGPU); result = pDevice->GetCompiler(i)->CreateGraphicsPipelineBinary( pDevice, i, pPipelineCache, &binaryCreateInfoMGPU, - &pipelineBinarySizes[i], + &pPipelineBinarySizes[i], &pPipelineBinaries[i], - objectCreateInfo.rasterizationStream, - &cacheId[i]); + &pCacheIds[i]); if (result == VK_SUCCESS) { pDefaultCompiler->SetPipelineCreationFeedbackInfo( - pPipelineCreationFeadbackCreateInfo, + pCreationFeedbackInfo, pCreateInfo->stageCount, pCreateInfo->pStages, &binaryCreateInfoMGPU.pipelineFeedback, @@ -144,47 +111,59 @@ VkResult GraphicsPipeline::Create( } } - if (result == VK_SUCCESS) - { - pDevice->GetShaderOptimizer()->OverrideGraphicsPipelineCreateInfo( - binaryCreateInfo.pipelineProfileKey, - objectCreateInfo.activeStages, - &objectCreateInfo.pipeline, - &objectCreateInfo.immedInfo.graphicsShaderInfos); + return result; +} - palPipelineHasher.Update(objectCreateInfo.pipeline); - } +// ===================================================================================================================== +// Create graphics pipeline objects +VkResult GraphicsPipeline::CreatePipelineObjects( + Device* pDevice, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + const VkAllocationCallbacks* pAllocator, + const VbBindingInfo* pVbInfo, + const size_t* pPipelineBinarySizes, + const void** pPipelineBinaries, + PipelineCache* pPipelineCache, + const Util::MetroHash::Hash* pCacheIds, + GraphicsPipelineObjectCreateInfo* pObjectCreateInfo, + VkPipeline* pPipeline) +{ + VkResult result = VK_SUCCESS; + Pal::Result palResult = Pal::Result::Success; + const uint32_t numPalDevices = pDevice->NumPalDevices(); + uint64_t apiPsoHash = 0; + Util::MetroHash64 palPipelineHasher; - RenderStateCache* pRSCache = pDevice->GetRenderStateCache(); + apiPsoHash = BuildApiHash(pCreateInfo, pObjectCreateInfo); + palPipelineHasher.Update(pObjectCreateInfo->pipeline); + + // Create the PAL pipeline object. + Pal::IPipeline* pPalPipeline[MaxPalDevices] = {}; + Pal::IMsaaState* pPalMsaa[MaxPalDevices] = {}; + Pal::IColorBlendState* pPalColorBlend[MaxPalDevices] = {}; + Pal::IDepthStencilState* pPalDepthStencil[MaxPalDevices] = {}; // Get the pipeline size from PAL and allocate memory. void* pSystemMem = nullptr; size_t palSize = 0; - if (result == VK_SUCCESS) - { - objectCreateInfo.pipeline.pipelineBinarySize = pipelineBinarySizes[DefaultDeviceIndex]; - objectCreateInfo.pipeline.pPipelineBinary = pPipelineBinaries[DefaultDeviceIndex]; + pObjectCreateInfo->pipeline.pipelineBinarySize = pPipelineBinarySizes[DefaultDeviceIndex]; + pObjectCreateInfo->pipeline.pPipelineBinary = pPipelineBinaries[DefaultDeviceIndex]; - palSize = - pDevice->PalDevice(DefaultDeviceIndex)->GetGraphicsPipelineSize(objectCreateInfo.pipeline, &palResult); - VK_ASSERT(palResult == Pal::Result::Success); + palSize = + pDevice->PalDevice(DefaultDeviceIndex)->GetGraphicsPipelineSize(pObjectCreateInfo->pipeline, &palResult); + VK_ASSERT(palResult == Pal::Result::Success); - pSystemMem = pDevice->AllocApiObject( - pAllocator, - sizeof(GraphicsPipeline) + (palSize * numPalDevices)); + pSystemMem = pDevice->AllocApiObject( + pAllocator, + sizeof(GraphicsPipeline) + (palSize * numPalDevices)); - if (pSystemMem == nullptr) - { - result = VK_ERROR_OUT_OF_HOST_MEMORY; - } + if (pSystemMem == nullptr) + { + result = VK_ERROR_OUT_OF_HOST_MEMORY; } - // Create the PAL pipeline object. - Pal::IPipeline* pPalPipeline[MaxPalDevices] = {}; - Pal::IMsaaState* pPalMsaa[MaxPalDevices] = {}; - Pal::IColorBlendState* pPalColorBlend[MaxPalDevices] = {}; - Pal::IDepthStencilState* pPalDepthStencil[MaxPalDevices] = {}; + RenderStateCache* pRSCache = pDevice->GetRenderStateCache(); if (result == VK_SUCCESS) { @@ -200,12 +179,12 @@ VkResult GraphicsPipeline::Create( // won't be created. Otherwise, like if gl_DeviceIndex is used, they will be. if (pPipelineBinaries[deviceIdx] != nullptr) { - objectCreateInfo.pipeline.pipelineBinarySize = pipelineBinarySizes[deviceIdx]; - objectCreateInfo.pipeline.pPipelineBinary = pPipelineBinaries[deviceIdx]; + pObjectCreateInfo->pipeline.pipelineBinarySize = pPipelineBinarySizes[deviceIdx]; + pObjectCreateInfo->pipeline.pPipelineBinary = pPipelineBinaries[deviceIdx]; } palResult = pPalDevice->CreateGraphicsPipeline( - objectCreateInfo.pipeline, + pObjectCreateInfo->pipeline, Util::VoidPtrInc(pSystemMem, palOffset), &pPalPipeline[deviceIdx]); @@ -220,9 +199,9 @@ VkResult GraphicsPipeline::Create( palResult = pDevice->GetCompiler(deviceIdx)->RegisterAndLoadReinjectionBinary( &info.internalPipelineHash, - &cacheId[deviceIdx], - &objectCreateInfo.pipeline.pipelineBinarySize, - &objectCreateInfo.pipeline.pPipelineBinary, + &pCacheIds[deviceIdx], + &pObjectCreateInfo->pipeline.pipelineBinarySize, + &pObjectCreateInfo->pipeline.pPipelineBinary, pPipelineCache); if (palResult == Util::Result::Success) @@ -230,7 +209,7 @@ VkResult GraphicsPipeline::Create( pPalPipeline[deviceIdx]->Destroy(); palResult = pPalDevice->CreateGraphicsPipeline( - objectCreateInfo.pipeline, + pObjectCreateInfo->pipeline, Util::VoidPtrInc(pSystemMem, palOffset), &pPalPipeline[deviceIdx]); } @@ -242,33 +221,31 @@ VkResult GraphicsPipeline::Create( } #endif - VK_ASSERT(palSize == pPalDevice->GetGraphicsPipelineSize(objectCreateInfo.pipeline, nullptr)); + VK_ASSERT(palSize == pPalDevice->GetGraphicsPipelineSize(pObjectCreateInfo->pipeline, nullptr)); palOffset += palSize; } // Create the PAL MSAA state object if (palResult == Pal::Result::Success) { - const auto& pMs = pCreateInfo->pMultisampleState; - // Force full sample shading if the app didn't enable it, but the shader wants // per-sample shading by the use of SampleId or similar features. - if ((objectCreateInfo.immedInfo.rasterizerDiscardEnable != VK_TRUE) && (pMs != nullptr) && - (pMs->sampleShadingEnable == false)) + if ((pObjectCreateInfo->immedInfo.rasterizerDiscardEnable != VK_TRUE) && + (pObjectCreateInfo->flags.sampleShadingEnable == false)) { const auto& info = pPalPipeline[deviceIdx]->GetInfo(); if (info.ps.flags.perSampleShading == 1) { // Override the shader rate to 1x1 if SampleId used in shader - Force1x1ShaderRate(&objectCreateInfo.immedInfo.vrsRateParams); - objectCreateInfo.flags.force1x1ShaderRate |= true; - objectCreateInfo.msaa.pixelShaderSamples = objectCreateInfo.msaa.coverageSamples; + Force1x1ShaderRate(&pObjectCreateInfo->immedInfo.vrsRateParams); + pObjectCreateInfo->flags.force1x1ShaderRate |= true; + pObjectCreateInfo->msaa.pixelShaderSamples = pObjectCreateInfo->msaa.coverageSamples; } } palResult = pRSCache->CreateMsaaState( - objectCreateInfo.msaa, + pObjectCreateInfo->msaa, pAllocator, VK_SYSTEM_ALLOCATION_SCOPE_OBJECT, pPalMsaa); @@ -278,24 +255,24 @@ VkResult GraphicsPipeline::Create( if (palResult == Pal::Result::Success) { palResult = pRSCache->CreateColorBlendState( - objectCreateInfo.blend, + pObjectCreateInfo->blend, pAllocator, VK_SYSTEM_ALLOCATION_SCOPE_OBJECT, pPalColorBlend); } // Create the PAL depth stencil state object - if ((palResult == Pal::Result::Success) && objectCreateInfo.flags.bindDepthStencilObject) + if ((palResult == Pal::Result::Success) && pObjectCreateInfo->flags.bindDepthStencilObject) { palResult = pRSCache->CreateDepthStencilState( - objectCreateInfo.immedInfo.depthStencilCreateInfo, + pObjectCreateInfo->immedInfo.depthStencilCreateInfo, pAllocator, VK_SYSTEM_ALLOCATION_SCOPE_OBJECT, pPalDepthStencil); } // Reset the PAL stencil maskupdate flags - objectCreateInfo.immedInfo.stencilRefMasks.flags.u8All = 0xff; + pObjectCreateInfo->immedInfo.stencilRefMasks.flags.u8All = 0xff; } result = PalToVkResult(palResult); @@ -309,35 +286,35 @@ VkResult GraphicsPipeline::Create( (result == VK_SUCCESS)) { pBinaryInfo = PipelineBinaryInfo::Create( - pipelineBinarySizes[DefaultDeviceIndex], + pPipelineBinarySizes[DefaultDeviceIndex], pPipelineBinaries[DefaultDeviceIndex], pAllocator); } - const bool viewIndexFromDeviceIndex = Util::TestAnyFlagSet( - pCreateInfo->flags, - VK_PIPELINE_CREATE_VIEW_INDEX_FROM_DEVICE_INDEX_BIT); - // On success, wrap it up in a Vulkan object. if (result == VK_SUCCESS) { + const bool viewIndexFromDeviceIndex = Util::TestAnyFlagSet( + pCreateInfo->flags, + VK_PIPELINE_CREATE_VIEW_INDEX_FROM_DEVICE_INDEX_BIT); + VK_PLACEMENT_NEW(pSystemMem) GraphicsPipeline( pDevice, pPalPipeline, - objectCreateInfo.pLayout, - objectCreateInfo.immedInfo, - objectCreateInfo.staticStateMask, - objectCreateInfo.flags.bindDepthStencilObject, - objectCreateInfo.flags.bindTriangleRasterState, - objectCreateInfo.flags.bindStencilRefMasks, - objectCreateInfo.flags.bindInputAssemblyState, - objectCreateInfo.flags.force1x1ShaderRate, - objectCreateInfo.flags.customSampleLocations, - vbInfo, + pObjectCreateInfo->pLayout, + pObjectCreateInfo->immedInfo, + pObjectCreateInfo->staticStateMask, + pObjectCreateInfo->flags.bindDepthStencilObject, + pObjectCreateInfo->flags.bindTriangleRasterState, + pObjectCreateInfo->flags.bindStencilRefMasks, + pObjectCreateInfo->flags.bindInputAssemblyState, + pObjectCreateInfo->flags.force1x1ShaderRate, + pObjectCreateInfo->flags.customSampleLocations, + *pVbInfo, pPalMsaa, pPalColorBlend, pPalDepthStencil, - objectCreateInfo.sampleCoverage, + pObjectCreateInfo->sampleCoverage, viewIndexFromDeviceIndex, pBinaryInfo, apiPsoHash, @@ -346,17 +323,6 @@ VkResult GraphicsPipeline::Create( *pPipeline = GraphicsPipeline::HandleFromVoidPointer(pSystemMem); } - // Free the created pipeline binaries now that the PAL Pipelines/PipelineBinaryInfo have read them. - for (uint32_t deviceIdx = 0; deviceIdx < pDevice->NumPalDevices(); deviceIdx++) - { - if (pPipelineBinaries[deviceIdx] != nullptr) - { - pDevice->GetCompiler(deviceIdx)->FreeGraphicsPipelineBinary( - &binaryCreateInfo, pPipelineBinaries[deviceIdx], pipelineBinarySizes[deviceIdx]); - } - } - pDefaultCompiler->FreeGraphicsPipelineCreateInfo(&binaryCreateInfo); - if (result != VK_SUCCESS) { pRSCache->DestroyMsaaState(pPalMsaa, pAllocator); @@ -383,6 +349,97 @@ VkResult GraphicsPipeline::Create( pDevice->FreeApiObject(pAllocator, pSystemMem); } + + return result; +} + +// ===================================================================================================================== +// Create a graphics pipeline object. +VkResult GraphicsPipeline::Create( + Device* pDevice, + PipelineCache* pPipelineCache, + const VkGraphicsPipelineCreateInfo* pCreateInfo, + const VkAllocationCallbacks* pAllocator, + VkPipeline* pPipeline) +{ + uint64 startTimeTicks = Util::GetPerfCpuTime(); + + PipelineCompiler* pDefaultCompiler = pDevice->GetCompiler(DefaultDeviceIndex); + + const VkPipelineCreationFeedbackCreateInfoEXT* pPipelineCreationFeedbackCreateInfo = nullptr; + + pDefaultCompiler->GetPipelineCreationFeedback(static_cast(pCreateInfo->pNext), + &pPipelineCreationFeedbackCreateInfo); + + // 1. Build pipeline binary create info + GraphicsPipelineBinaryCreateInfo binaryCreateInfo = {}; + GraphicsPipelineShaderStageInfo shaderStageInfo = {}; + VbBindingInfo vbInfo = {}; + ShaderModuleHandle tempModules[ShaderStage::ShaderStageGfxCount] = {}; + + VkResult result = BuildPipelineBinaryCreateInfo( + pDevice, pCreateInfo, &binaryCreateInfo, &shaderStageInfo, &vbInfo, tempModules); + + // 2. Create pipeine binaries + size_t pipelineBinarySizes[MaxPalDevices] = {}; + const void* pPipelineBinaries[MaxPalDevices] = {}; + Util::MetroHash::Hash cacheId[MaxPalDevices] = {}; + + if (result == VK_SUCCESS) + { + result = CreatePipelineBinaries(pDevice, + pCreateInfo, + &shaderStageInfo, + &binaryCreateInfo, + pPipelineCache, + pPipelineCreationFeedbackCreateInfo, + cacheId, + pipelineBinarySizes, + pPipelineBinaries); + } + + uint64_t pipelineHash = 0; + + if (result == VK_SUCCESS) + { + pipelineHash = Vkgc::IPipelineDumper::GetPipelineHash(&binaryCreateInfo.pipelineInfo); + + // 3. Build pipeline object create info + GraphicsPipelineObjectCreateInfo objectCreateInfo = {}; + GraphicsPipelineBinaryInfo binaryInfo = {}; + binaryInfo.pOptimizerKey = &binaryCreateInfo.pipelineProfileKey; + + BuildPipelineObjectCreateInfo( + pDevice, pCreateInfo, &vbInfo, &binaryInfo, &objectCreateInfo); + + // 4. Create pipeline objects + result = CreatePipelineObjects( + pDevice, + pCreateInfo, + pAllocator, + &vbInfo, + pipelineBinarySizes, + pPipelineBinaries, + pPipelineCache, + cacheId, + &objectCreateInfo, + pPipeline); + } + + // Free the temporary newly-built shader modules + FreeTempModules(pDevice, ShaderStage::ShaderStageGfxCount, tempModules); + + // Free the created pipeline binaries now that the PAL Pipelines/PipelineBinaryInfo have read them. + for (uint32_t deviceIdx = 0; deviceIdx < pDevice->NumPalDevices(); deviceIdx++) + { + if (pPipelineBinaries[deviceIdx] != nullptr) + { + pDevice->GetCompiler(deviceIdx)->FreeGraphicsPipelineBinary( + &binaryCreateInfo, pPipelineBinaries[deviceIdx], pipelineBinarySizes[deviceIdx]); + } + } + pDefaultCompiler->FreeGraphicsPipelineCreateInfo(&binaryCreateInfo); + if (result == VK_SUCCESS) { uint64_t durationTicks = Util::GetPerfCpuTime() - startTimeTicks; @@ -390,14 +447,17 @@ VkResult GraphicsPipeline::Create( binaryCreateInfo.pipelineFeedback.feedbackValid = true; binaryCreateInfo.pipelineFeedback.duration = duration; pDefaultCompiler->SetPipelineCreationFeedbackInfo( - pPipelineCreationFeadbackCreateInfo, + pPipelineCreationFeedbackCreateInfo, pCreateInfo->stageCount, pCreateInfo->pStages, &binaryCreateInfo.pipelineFeedback, binaryCreateInfo.stageFeedback); // The hash is same as pipline dump file name, we can easily analyze further. - AmdvlkLog(settings.logTagIdMask, PipelineCompileTime, "0x%016llX-%llu", pipelineHash, duration); + AmdvlkLog(pDevice->GetRuntimeSettings().logTagIdMask, + PipelineCompileTime, + "0x%016llX-%llu", + pipelineHash, duration); } return result; @@ -426,7 +486,8 @@ GraphicsPipeline::GraphicsPipeline( uint64_t apiHash, Util::MetroHash64* pPalPipelineHasher) : - GraphicsPipelineCommon(pDevice), + GraphicsPipelineCommon( + pDevice), m_info(immedInfo), m_vbInfo(vbInfo), m_flags() @@ -638,7 +699,7 @@ void GraphicsPipeline::BindToCmdBuffer( if (*pViewportCount != m_info.viewportParams.count) { *pViewportCount = m_info.viewportParams.count; - pRenderState->dirty.viewport = 1; + pRenderState->dirtyGraphics.viewport = 1; } } while (deviceGroup.IterateNext()); @@ -661,7 +722,7 @@ void GraphicsPipeline::BindToCmdBuffer( if (*pScissorCount != m_info.scissorRectParams.count) { *pScissorCount = m_info.scissorRectParams.count; - pRenderState->dirty.scissor = 1; + pRenderState->dirtyGraphics.scissor = 1; } } while (deviceGroup.IterateNext()); @@ -676,35 +737,35 @@ void GraphicsPipeline::BindToCmdBuffer( { pDepthStencilCreateInfo->depthEnable = m_info.depthStencilCreateInfo.depthEnable; - pRenderState->dirty.depthStencil = 1; + pRenderState->dirtyGraphics.depthStencil = 1; } if (ContainsStaticState(DynamicStatesInternal::DepthWriteEnableExt) && (pDepthStencilCreateInfo->depthWriteEnable != m_info.depthStencilCreateInfo.depthWriteEnable)) { pDepthStencilCreateInfo->depthWriteEnable = m_info.depthStencilCreateInfo.depthWriteEnable; - pRenderState->dirty.depthStencil = 1; + pRenderState->dirtyGraphics.depthStencil = 1; } if (ContainsStaticState(DynamicStatesInternal::DepthCompareOpExt) && (pDepthStencilCreateInfo->depthFunc != m_info.depthStencilCreateInfo.depthFunc)) { pDepthStencilCreateInfo->depthFunc = m_info.depthStencilCreateInfo.depthFunc; - pRenderState->dirty.depthStencil = 1; + pRenderState->dirtyGraphics.depthStencil = 1; } if (ContainsStaticState(DynamicStatesInternal::DepthBoundsTestEnableExt) && (pDepthStencilCreateInfo->depthBoundsEnable != m_info.depthStencilCreateInfo.depthBoundsEnable)) { pDepthStencilCreateInfo->depthBoundsEnable = m_info.depthStencilCreateInfo.depthBoundsEnable; - pRenderState->dirty.depthStencil = 1; + pRenderState->dirtyGraphics.depthStencil = 1; } if (ContainsStaticState(DynamicStatesInternal::StencilTestEnableExt) && (pDepthStencilCreateInfo->stencilEnable != m_info.depthStencilCreateInfo.stencilEnable)) { pDepthStencilCreateInfo->stencilEnable = m_info.depthStencilCreateInfo.stencilEnable; - pRenderState->dirty.depthStencil = 1; + pRenderState->dirtyGraphics.depthStencil = 1; } if (ContainsStaticState(DynamicStatesInternal::StencilOpExt) && ((pDepthStencilCreateInfo->front.stencilFailOp != m_info.depthStencilCreateInfo.front.stencilFailOp) || @@ -721,7 +782,7 @@ void GraphicsPipeline::BindToCmdBuffer( pDepthStencilCreateInfo->front = m_info.depthStencilCreateInfo.front; pDepthStencilCreateInfo->back = m_info.depthStencilCreateInfo.back; - pRenderState->dirty.depthStencil = 1; + pRenderState->dirtyGraphics.depthStencil = 1; } } else @@ -753,7 +814,7 @@ void GraphicsPipeline::BindToCmdBuffer( pRenderState->triangleRasterState.flags.depthBiasEnable = m_info.triangleRasterState.flags.depthBiasEnable; } - pRenderState->dirty.rasterState = 1; + pRenderState->dirtyGraphics.rasterState = 1; } else { @@ -795,7 +856,7 @@ void GraphicsPipeline::BindToCmdBuffer( // Check whether the dirty bit should be set if (memcmp(&pRenderState->stencilRefMasks, &prevStencilRefMasks, sizeof(Pal::StencilRefMaskParams)) != 0) { - pRenderState->dirty.stencilRef = 1; + pRenderState->dirtyGraphics.stencilRef = 1; } if (m_flags.bindInputAssemblyState == false) @@ -813,7 +874,7 @@ void GraphicsPipeline::BindToCmdBuffer( pRenderState->inputAssemblyState.topology = m_info.inputAssemblyState.topology; } - pRenderState->dirty.inputAssembly = 1; + pRenderState->dirtyGraphics.inputAssembly = 1; } else { @@ -855,19 +916,19 @@ void GraphicsPipeline::BindToCmdBuffer( // is skipped due to matching Pal pipeline hash values and CB_TARGET_MASK has been altered by the // previous pipeline via color write enable. Passing in a count of 0 resets the mask. pRenderState->colorWriteMaskParams.count = 0; - pRenderState->dirty.colorWriteEnable = 1; + pRenderState->dirtyGraphics.colorWriteEnable = 1; } if ((palPipelineBound == false) && ContainsStaticState(DynamicStatesInternal::RasterizerDiscardEnableExt)) { // Need to update static rasterizerDiscardEnable setting if the Pal pipeline bind is skipped pRenderState->rasterizerDiscardEnable = m_info.rasterizerDiscardEnable; - pRenderState->dirty.rasterizerDiscardEnable = 1; + pRenderState->dirtyGraphics.rasterizerDiscardEnable = 1; } else if (ContainsDynamicState(DynamicStatesInternal::RasterizerDiscardEnableExt)) { // Binding a pipeline overwrites the dynamic rasterizerDiscardEnable setting so need to force validation - pRenderState->dirty.rasterizerDiscardEnable = 1; + pRenderState->dirtyGraphics.rasterizerDiscardEnable = 1; } } else @@ -887,7 +948,7 @@ void GraphicsPipeline::BindToCmdBuffer( { pCmdBuffer->PalCmdBindDepthStencilState(pPalCmdBuf, deviceIdx, m_pPalDepthStencil[deviceIdx]); - pRenderState->dirty.depthStencil = 0; + pRenderState->dirtyGraphics.depthStencil = 0; } pCmdBuffer->PalCmdBindColorBlendState(pPalCmdBuf, deviceIdx, m_pPalColorBlend[deviceIdx]); @@ -902,7 +963,7 @@ void GraphicsPipeline::BindToCmdBuffer( pPalCmdBuf->CmdSetInputAssemblyState(m_info.inputAssemblyState); pRenderState->staticTokens.inputAssemblyState = newTokens.inputAssemblyState; - pRenderState->dirty.inputAssembly = 0; + pRenderState->dirtyGraphics.inputAssembly = 0; } if (CmdBuffer::IsStaticStateDifferent(oldTokens.triangleRasterState, newTokens.triangleRasterState) && @@ -911,7 +972,7 @@ void GraphicsPipeline::BindToCmdBuffer( pPalCmdBuf->CmdSetTriangleRasterState(m_info.triangleRasterState); pRenderState->staticTokens.triangleRasterState = newTokens.triangleRasterState; - pRenderState->dirty.rasterState = 0; + pRenderState->dirtyGraphics.rasterState = 0; } if (ContainsStaticState(DynamicStatesInternal::LineWidth) && @@ -965,7 +1026,7 @@ void GraphicsPipeline::BindToCmdBuffer( } else { - pRenderState->dirty.colorWriteEnable = 0; + pRenderState->dirtyGraphics.colorWriteEnable = 0; } } @@ -976,7 +1037,7 @@ void GraphicsPipeline::BindToCmdBuffer( pPalCmdBuf->CmdSetPerDrawVrsRate(m_info.vrsRateParams); pRenderState->staticTokens.fragmentShadingRate = newTokens.fragmentShadingRate; - pRenderState->dirty.vrs = 0; + pRenderState->dirtyGraphics.vrs = 0; } } while (deviceGroup.IterateNext()); diff --git a/icd/api/vk_image.cpp b/icd/api/vk_image.cpp index 36f4425e..9f268e9b 100644 --- a/icd/api/vk_image.cpp +++ b/icd/api/vk_image.cpp @@ -199,7 +199,6 @@ Image::Image( barrierPolicyFormat, extraLayoutUsages), m_pSwapChain(nullptr), - m_pImageMemory(nullptr), m_ResourceKey(resourceKey) { m_internalFlags.u32All = internalFlags.u32All; @@ -809,38 +808,6 @@ VkResult Image::Create( (pCreateInfo->usage & VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT), &imageSharingMode); - if ((result == VK_SUCCESS) && (imageFlags.androidPresentable)) - { - VkDeviceMemory pDeviceMemory = {}; - result = Image::CreatePresentableImage( - pDevice, - &presentImageCreateInfo, - pAllocator, - pCreateInfo->usage, - Pal::PresentMode::Windowed, - pImage, - createInfoFormat, - imageSharingMode, - pCreateInfo->queueFamilyIndexCount, - pCreateInfo->pQueueFamilyIndices, - &pDeviceMemory); - - if (result == VK_SUCCESS) - { - Image* pPresentableImage = Image::ObjectFromHandle(*pImage); - pPresentableImage->m_pImageMemory = Memory::ObjectFromHandle(pDeviceMemory); - - Pal::Result palResult = pDevice->AddMemReference( - pDevice->PalDevice(DefaultDeviceIndex), - pPresentableImage->m_pImageMemory->PalMemory(DefaultDeviceIndex), - false); - - result = PalToVkResult(palResult); - } - - return result; - } - // Calculate required system memory size const size_t apiSize = ObjectSize(pDevice); size_t totalSize = apiSize; @@ -1187,14 +1154,6 @@ VkResult Image::Destroy( pAllocator->pfnFree(pAllocator->pUserData, m_perGpu[0].pPalMemory); } - if (m_pImageMemory != nullptr) - { - pDevice->RemoveMemReference(pDevice->PalDevice(DefaultDeviceIndex), - m_pImageMemory->PalMemory(DefaultDeviceIndex)); - m_pImageMemory->PalMemory(DefaultDeviceIndex)->Destroy(); - pAllocator->pfnFree(pAllocator->pUserData, m_pImageMemory); - } - Util::Destructor(this); pDevice->FreeApiObject(pAllocator, this); diff --git a/icd/api/vk_instance.cpp b/icd/api/vk_instance.cpp index db222005..e1ca79f8 100644 --- a/icd/api/vk_instance.cpp +++ b/icd/api/vk_instance.cpp @@ -711,9 +711,6 @@ VkResult Instance::Destroy(void) // Free memory FreeMem(this); - // __gcov_flush() is used to flush code coverage data to files. It would be called by Android native process when it - // exits. But for Android apk process, it should be called explicitly. - // Cannot fail. return VK_SUCCESS; } diff --git a/icd/api/vk_memory.cpp b/icd/api/vk_memory.cpp index f190bd35..3e4eb5d2 100644 --- a/icd/api/vk_memory.cpp +++ b/icd/api/vk_memory.cpp @@ -69,10 +69,8 @@ VkResult Memory::Create( // indicate whether it is a allocation that supposed to be imported. Pal::OsExternalHandle handle = 0; bool sharedViaNtHandle = false; - bool sharedViaAndroidHwBuf = false; bool isExternal = false; bool isHostMappedForeign = false; - bool isAndroidHardwareBuffer = false; void* pPinnedHostPtr = nullptr; // If non-null, this memory is allocated as pinned system memory bool isCaptureReplay = false; @@ -205,14 +203,8 @@ VkResult Memory::Create( #if defined(__unix__) VK_ASSERT(pExtInfo->handleTypes & (VK_EXTERNAL_MEMORY_HANDLE_TYPE_OPAQUE_FD_BIT | - VK_EXTERNAL_MEMORY_HANDLE_TYPE_DMA_BUF_BIT_EXT | - VK_EXTERNAL_MEMORY_HANDLE_TYPE_ANDROID_HARDWARE_BUFFER_BIT_ANDROID)); - - if (pExtInfo->handleTypes & - VK_EXTERNAL_MEMORY_HANDLE_TYPE_ANDROID_HARDWARE_BUFFER_BIT_ANDROID) - { - sharedViaAndroidHwBuf = true; - } + VK_EXTERNAL_MEMORY_HANDLE_TYPE_DMA_BUF_BIT_EXT + )); #endif createInfo.flags.interprocess = 1; #if PAL_CLIENT_INTERFACE_MAJOR_VERSION >= 657 @@ -324,11 +316,11 @@ VkResult Memory::Create( if (vkResult == VK_SUCCESS) { - if ((isExternal) || (sharedViaAndroidHwBuf)) + if (isExternal + ) { ImportMemoryInfo importInfo = {}; importInfo.handle = handle; - importInfo.isAhbHandle = isAndroidHardwareBuffer || sharedViaAndroidHwBuf; importInfo.isNtHandle = sharedViaNtHandle; if (pBoundImage != nullptr) @@ -779,7 +771,6 @@ VkResult Memory::OpenExternalSharedImage( palOpenInfo.resourceInfo.hExternalResource = importInfo.handle; palOpenInfo.resourceInfo.flags.ntHandle = importInfo.isNtHandle; - palOpenInfo.resourceInfo.flags.androidHwBufHandle = importInfo.isAhbHandle; #if defined(__unix__) palOpenInfo.resourceInfo.handleType = Pal::HandleType::DmaBufFd; #endif @@ -1034,7 +1025,6 @@ VkResult Memory::OpenExternalMemory( } openInfo.resourceInfo.flags.ntHandle = importInfo.isNtHandle; - openInfo.resourceInfo.flags.androidHwBufHandle = importInfo.isAhbHandle; // Get CPU memory requirements for PAL gpuMemorySize = pDevice->PalDevice(DefaultDeviceIndex)->GetExternalSharedGpuMemorySize(&palResult); VK_ASSERT(palResult == Pal::Result::Success); diff --git a/icd/api/vk_physical_device.cpp b/icd/api/vk_physical_device.cpp index e04fdc7a..e9283bc9 100644 --- a/icd/api/vk_physical_device.cpp +++ b/icd/api/vk_physical_device.cpp @@ -956,6 +956,10 @@ VkResult PhysicalDevice::Initialize() (1UL << memoryTypeIndex); m_memoryTypeMask |= 1 << m_memoryProperties.memoryTypeCount; + + m_memoryVkIndexAddRemoteBackupHeap[m_memoryProperties.memoryTypeCount] = + m_memoryVkIndexAddRemoteBackupHeap[memoryTypeIndex]; + ++m_memoryProperties.memoryTypeCount; } } @@ -1339,122 +1343,134 @@ VkResult PhysicalDevice::GetQueueFamilyProperties( // ===================================================================================================================== // Retrieve device feature support. Called in response to vkGetPhysicalDeviceFeatures -VkResult PhysicalDevice::GetFeatures( +size_t PhysicalDevice::GetFeatures( VkPhysicalDeviceFeatures* pFeatures ) const { - const RuntimeSettings& settings = GetRuntimeSettings(); + if (pFeatures != nullptr) + { + + const RuntimeSettings& settings = GetRuntimeSettings(); + + pFeatures->robustBufferAccess = VK_TRUE; + pFeatures->fullDrawIndexUint32 = VK_TRUE; + pFeatures->imageCubeArray = VK_TRUE; + pFeatures->independentBlend = VK_TRUE; + pFeatures->geometryShader = VK_TRUE; + pFeatures->tessellationShader = VK_TRUE; + pFeatures->sampleRateShading = VK_TRUE; + pFeatures->dualSrcBlend = VK_TRUE; + pFeatures->logicOp = VK_TRUE; + + pFeatures->multiDrawIndirect = VK_TRUE; + pFeatures->drawIndirectFirstInstance = VK_TRUE; + + pFeatures->depthClamp = VK_TRUE; + pFeatures->depthBiasClamp = VK_TRUE; + pFeatures->fillModeNonSolid = VK_TRUE; + pFeatures->depthBounds = VK_TRUE; + pFeatures->wideLines = VK_TRUE; + pFeatures->largePoints = VK_TRUE; + pFeatures->alphaToOne = + (PalProperties().gfxipProperties.flags.supportAlphaToOne ? VK_TRUE : VK_FALSE); + pFeatures->multiViewport = VK_TRUE; + pFeatures->samplerAnisotropy = VK_TRUE; + pFeatures->textureCompressionETC2 = VerifyEtc2FormatSupport(*this); + pFeatures->textureCompressionASTC_LDR = VerifyAstcLdrFormatSupport(*this); + + #if VKI_GPU_DECOMPRESS + if (settings.enableShaderDecode) + { + pFeatures->textureCompressionETC2 = VK_TRUE; + pFeatures->textureCompressionASTC_LDR = VK_TRUE; + } + #endif + pFeatures->textureCompressionBC = VerifyBCFormatSupport(*this); + pFeatures->occlusionQueryPrecise = VK_TRUE; + pFeatures->pipelineStatisticsQuery = VK_TRUE; + pFeatures->vertexPipelineStoresAndAtomics = VK_TRUE; + pFeatures->fragmentStoresAndAtomics = VK_TRUE; + + pFeatures->shaderTessellationAndGeometryPointSize = VK_TRUE; + pFeatures->shaderImageGatherExtended = VK_TRUE; + + pFeatures->shaderStorageImageExtendedFormats = VK_TRUE; + pFeatures->shaderStorageImageMultisample = VK_TRUE; + pFeatures->shaderStorageImageReadWithoutFormat = VK_TRUE; + pFeatures->shaderStorageImageWriteWithoutFormat = VK_TRUE; + pFeatures->shaderUniformBufferArrayDynamicIndexing = VK_TRUE; + pFeatures->shaderSampledImageArrayDynamicIndexing = VK_TRUE; + pFeatures->shaderStorageBufferArrayDynamicIndexing = VK_TRUE; + pFeatures->shaderStorageImageArrayDynamicIndexing = VK_TRUE; + pFeatures->shaderClipDistance = VK_TRUE; + pFeatures->shaderCullDistance = VK_TRUE; + pFeatures->shaderFloat64 = + (PalProperties().gfxipProperties.flags.support64BitInstructions ? VK_TRUE : VK_FALSE); + pFeatures->shaderInt64 = + (PalProperties().gfxipProperties.flags.support64BitInstructions ? VK_TRUE : VK_FALSE); + + if ((PalProperties().gfxipProperties.flags.support16BitInstructions) && + ((settings.optOnlyEnableFP16ForGfx9Plus == false) || + (PalProperties().gfxLevel >= Pal::GfxIpLevel::GfxIp9))) + { + pFeatures->shaderInt16 = VK_TRUE; + } + else + { + pFeatures->shaderInt16 = VK_FALSE; + } - pFeatures->robustBufferAccess = VK_TRUE; - pFeatures->fullDrawIndexUint32 = VK_TRUE; - pFeatures->imageCubeArray = VK_TRUE; - pFeatures->independentBlend = VK_TRUE; - pFeatures->geometryShader = VK_TRUE; - pFeatures->tessellationShader = VK_TRUE; - pFeatures->sampleRateShading = VK_TRUE; - pFeatures->dualSrcBlend = VK_TRUE; - pFeatures->logicOp = VK_TRUE; - - pFeatures->multiDrawIndirect = VK_TRUE; - pFeatures->drawIndirectFirstInstance = VK_TRUE; - - pFeatures->depthClamp = VK_TRUE; - pFeatures->depthBiasClamp = VK_TRUE; - pFeatures->fillModeNonSolid = VK_TRUE; - pFeatures->depthBounds = VK_TRUE; - pFeatures->wideLines = VK_TRUE; - pFeatures->largePoints = VK_TRUE; - pFeatures->alphaToOne = - (PalProperties().gfxipProperties.flags.supportAlphaToOne ? VK_TRUE : VK_FALSE); - pFeatures->multiViewport = VK_TRUE; - pFeatures->samplerAnisotropy = VK_TRUE; - pFeatures->textureCompressionETC2 = VerifyEtc2FormatSupport(*this); - pFeatures->textureCompressionASTC_LDR = VerifyAstcLdrFormatSupport(*this); - pFeatures->textureCompressionBC = VerifyBCFormatSupport(*this); - pFeatures->occlusionQueryPrecise = VK_TRUE; - pFeatures->pipelineStatisticsQuery = VK_TRUE; - pFeatures->vertexPipelineStoresAndAtomics = VK_TRUE; - pFeatures->fragmentStoresAndAtomics = VK_TRUE; - - pFeatures->shaderTessellationAndGeometryPointSize = VK_TRUE; - pFeatures->shaderImageGatherExtended = VK_TRUE; - - pFeatures->shaderStorageImageExtendedFormats = VK_TRUE; - pFeatures->shaderStorageImageMultisample = VK_TRUE; - pFeatures->shaderStorageImageReadWithoutFormat = VK_TRUE; - pFeatures->shaderStorageImageWriteWithoutFormat = VK_TRUE; - pFeatures->shaderUniformBufferArrayDynamicIndexing = VK_TRUE; - pFeatures->shaderSampledImageArrayDynamicIndexing = VK_TRUE; - pFeatures->shaderStorageBufferArrayDynamicIndexing = VK_TRUE; - pFeatures->shaderStorageImageArrayDynamicIndexing = VK_TRUE; - pFeatures->shaderClipDistance = VK_TRUE; - pFeatures->shaderCullDistance = VK_TRUE; - pFeatures->shaderFloat64 = - (PalProperties().gfxipProperties.flags.support64BitInstructions ? VK_TRUE : VK_FALSE); - pFeatures->shaderInt64 = - (PalProperties().gfxipProperties.flags.support64BitInstructions ? VK_TRUE : VK_FALSE); - - if ((PalProperties().gfxipProperties.flags.support16BitInstructions) && - ((settings.optOnlyEnableFP16ForGfx9Plus == false) || - (PalProperties().gfxLevel >= Pal::GfxIpLevel::GfxIp9))) - { - pFeatures->shaderInt16 = VK_TRUE; - } - else - { - pFeatures->shaderInt16 = VK_FALSE; - } + if (settings.optEnablePrt) + { + pFeatures->shaderResourceResidency = + GetPrtFeatures() & Pal::PrtFeatureShaderStatus ? VK_TRUE : VK_FALSE; - if (settings.optEnablePrt) - { - pFeatures->shaderResourceResidency = - GetPrtFeatures() & Pal::PrtFeatureShaderStatus ? VK_TRUE : VK_FALSE; + pFeatures->shaderResourceMinLod = + GetPrtFeatures() & Pal::PrtFeatureShaderLodClamp ? VK_TRUE : VK_FALSE; - pFeatures->shaderResourceMinLod = - GetPrtFeatures() & Pal::PrtFeatureShaderLodClamp ? VK_TRUE : VK_FALSE; + pFeatures->sparseBinding = + m_properties.gpuMemoryProperties.flags.virtualRemappingSupport ? VK_TRUE : VK_FALSE; - pFeatures->sparseBinding = - m_properties.gpuMemoryProperties.flags.virtualRemappingSupport ? VK_TRUE : VK_FALSE; + pFeatures->sparseResidencyBuffer = + GetPrtFeatures() & Pal::PrtFeatureBuffer ? VK_TRUE : VK_FALSE; - pFeatures->sparseResidencyBuffer = - GetPrtFeatures() & Pal::PrtFeatureBuffer ? VK_TRUE : VK_FALSE; + pFeatures->sparseResidencyImage2D = + GetPrtFeatures() & Pal::PrtFeatureImage2D ? VK_TRUE : VK_FALSE; - pFeatures->sparseResidencyImage2D = - GetPrtFeatures() & Pal::PrtFeatureImage2D ? VK_TRUE : VK_FALSE; + pFeatures->sparseResidencyImage3D = + (GetPrtFeatures() & (Pal::PrtFeatureImage3D | Pal::PrtFeatureNonStandardImage3D)) != 0 ? VK_TRUE : VK_FALSE; - pFeatures->sparseResidencyImage3D = - (GetPrtFeatures() & (Pal::PrtFeatureImage3D | Pal::PrtFeatureNonStandardImage3D)) != 0 ? VK_TRUE : VK_FALSE; + const VkBool32 sparseMultisampled = + GetPrtFeatures() & Pal::PrtFeatureImageMultisampled ? VK_TRUE : VK_FALSE; - const VkBool32 sparseMultisampled = - GetPrtFeatures() & Pal::PrtFeatureImageMultisampled ? VK_TRUE : VK_FALSE; + pFeatures->sparseResidency2Samples = sparseMultisampled; + pFeatures->sparseResidency4Samples = sparseMultisampled; + pFeatures->sparseResidency8Samples = sparseMultisampled; + pFeatures->sparseResidency16Samples = VK_FALSE; - pFeatures->sparseResidency2Samples = sparseMultisampled; - pFeatures->sparseResidency4Samples = sparseMultisampled; - pFeatures->sparseResidency8Samples = sparseMultisampled; - pFeatures->sparseResidency16Samples = VK_FALSE; + pFeatures->sparseResidencyAliased = + GetPrtFeatures() & Pal::PrtFeatureTileAliasing ? VK_TRUE : VK_FALSE; + } + else + { + pFeatures->shaderResourceResidency = VK_FALSE; + pFeatures->shaderResourceMinLod = VK_FALSE; + pFeatures->sparseBinding = VK_FALSE; + pFeatures->sparseResidencyBuffer = VK_FALSE; + pFeatures->sparseResidencyImage2D = VK_FALSE; + pFeatures->sparseResidencyImage3D = VK_FALSE; + pFeatures->sparseResidency2Samples = VK_FALSE; + pFeatures->sparseResidency4Samples = VK_FALSE; + pFeatures->sparseResidency8Samples = VK_FALSE; + pFeatures->sparseResidency16Samples = VK_FALSE; + pFeatures->sparseResidencyAliased = VK_FALSE; + } - pFeatures->sparseResidencyAliased = - GetPrtFeatures() & Pal::PrtFeatureTileAliasing ? VK_TRUE : VK_FALSE; + pFeatures->variableMultisampleRate = VK_TRUE; + pFeatures->inheritedQueries = VK_TRUE; } - else - { - pFeatures->shaderResourceResidency = VK_FALSE; - pFeatures->shaderResourceMinLod = VK_FALSE; - pFeatures->sparseBinding = VK_FALSE; - pFeatures->sparseResidencyBuffer = VK_FALSE; - pFeatures->sparseResidencyImage2D = VK_FALSE; - pFeatures->sparseResidencyImage3D = VK_FALSE; - pFeatures->sparseResidency2Samples = VK_FALSE; - pFeatures->sparseResidency4Samples = VK_FALSE; - pFeatures->sparseResidency8Samples = VK_FALSE; - pFeatures->sparseResidency16Samples = VK_FALSE; - pFeatures->sparseResidencyAliased = VK_FALSE; - } - - pFeatures->variableMultisampleRate = VK_TRUE; - pFeatures->inheritedQueries = VK_TRUE; - return VK_SUCCESS; + return sizeof(VkPhysicalDeviceFeatures); } // ===================================================================================================================== @@ -1689,6 +1705,11 @@ VkResult PhysicalDevice::GetImageFormatProperties( break; case VK_IMAGE_TYPE_3D: + if (flags & VK_IMAGE_CREATE_2D_ARRAY_COMPATIBLE_BIT) + { + pImageFormatProperties->maxExtent.depth = Util::Min(pImageFormatProperties->maxExtent.depth, + m_limits.maxFramebufferLayers); + } break; default: @@ -2135,11 +2156,10 @@ void PhysicalDevice::PopulateLimits() // of a limit's description that may not have been reflected in the comments. You should double check with the // spec for the true language always if suspecting a particular limit is incorrect. - constexpr uint32_t MaxFramebufferLayers = 2048; - const Pal::DeviceProperties& palProps = PalProperties(); const auto& imageProps = palProps.imageProperties; const RuntimeSettings& settings = GetRuntimeSettings(); + const uint32_t MaxFramebufferLayers = imageProps.maxArraySlices; // Maximum dimension (width) of an image created with an imageType of VK_IMAGE_TYPE_1D. m_limits.maxImageDimension1D = imageProps.maxDimensions.width; @@ -4666,12 +4686,15 @@ void PhysicalDevice::GetPhysicalDeviceVulkanMemoryModelFeatures( // ===================================================================================================================== // Retrieve device feature support. Called in response to vkGetPhysicalDeviceFeatures2 // NOTE: Don't memset here. Otherwise, VerifyRequestedPhysicalDeviceFeatures needs to compare member by member -void PhysicalDevice::GetFeatures2( - VkStructHeaderNonConst* pFeatures +size_t PhysicalDevice::GetFeatures2( + VkStructHeaderNonConst* pFeatures, + bool updateFeatures ) const { VkStructHeaderNonConst* pHeader = pFeatures; + size_t structSize = 0; + while (pHeader) { switch (static_cast(pHeader->sType)) @@ -4679,30 +4702,45 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_FEATURES_2: { auto* pExtInfo = reinterpret_cast(pHeader); - GetFeatures(&pExtInfo->features); + + if (updateFeatures) + { + GetFeatures(&pExtInfo->features); + } + + structSize = sizeof(*pExtInfo); + break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_16BIT_STORAGE_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDevice16BitStorageFeatures( - &pExtInfo->storageBuffer16BitAccess, - &pExtInfo->uniformAndStorageBuffer16BitAccess, - &pExtInfo->storagePushConstant16, - &pExtInfo->storageInputOutput16); + if (updateFeatures) + { + GetPhysicalDevice16BitStorageFeatures( + &pExtInfo->storageBuffer16BitAccess, + &pExtInfo->uniformAndStorageBuffer16BitAccess, + &pExtInfo->storagePushConstant16, + &pExtInfo->storageInputOutput16); + } + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_8BIT_STORAGE_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDevice8BitStorageFeatures( - &pExtInfo->storageBuffer8BitAccess, - &pExtInfo->uniformAndStorageBuffer8BitAccess, - &pExtInfo->storagePushConstant8); + if (updateFeatures) + { + GetPhysicalDevice8BitStorageFeatures( + &pExtInfo->storageBuffer8BitAccess, + &pExtInfo->uniformAndStorageBuffer8BitAccess, + &pExtInfo->storagePushConstant8); + } + structSize = sizeof(*pExtInfo); break; } @@ -4710,10 +4748,14 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceShaderAtomicInt64Features( - &pExtInfo->shaderBufferInt64Atomics, - &pExtInfo->shaderSharedInt64Atomics); + if (updateFeatures) + { + GetPhysicalDeviceShaderAtomicInt64Features( + &pExtInfo->shaderBufferInt64Atomics, + &pExtInfo->shaderSharedInt64Atomics); + } + structSize = sizeof(*pExtInfo); break; } @@ -4721,27 +4763,40 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->clockModes = m_gpaProps.features.clockModes; - pExtInfo->perfCounters = m_gpaProps.features.perfCounters; - pExtInfo->sqThreadTracing = m_gpaProps.features.sqThreadTracing; - pExtInfo->streamingPerfCounters = m_gpaProps.features.streamingPerfCounters; + if (updateFeatures) + { + pExtInfo->clockModes = m_gpaProps.features.clockModes; + pExtInfo->perfCounters = m_gpaProps.features.perfCounters; + pExtInfo->sqThreadTracing = m_gpaProps.features.sqThreadTracing; + pExtInfo->streamingPerfCounters = m_gpaProps.features.streamingPerfCounters; + } + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TIMELINE_SEMAPHORE_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceTimelineSemaphoreFeatures(&pExtInfo->timelineSemaphore); + if (updateFeatures) + { + GetPhysicalDeviceTimelineSemaphoreFeatures(&pExtInfo->timelineSemaphore); + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SAMPLER_YCBCR_CONVERSION_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceSamplerYcbcrConversionFeatures( - &pExtInfo->samplerYcbcrConversion); + if (updateFeatures) + { + GetPhysicalDeviceSamplerYcbcrConversionFeatures( + &pExtInfo->samplerYcbcrConversion); + } + structSize = sizeof(*pExtInfo); break; } @@ -4749,17 +4804,26 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceVariablePointerFeatures( - &pExtInfo->variablePointersStorageBuffer, - &pExtInfo->variablePointers); + if (updateFeatures) + { + GetPhysicalDeviceVariablePointerFeatures( + &pExtInfo->variablePointersStorageBuffer, + &pExtInfo->variablePointers); + } + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PROTECTED_MEMORY_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceProtectedMemoryFeatures(&pExtInfo->protectedMemory); + if (updateFeatures) + { + GetPhysicalDeviceProtectedMemoryFeatures(&pExtInfo->protectedMemory); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4767,11 +4831,15 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceMultiviewFeatures( - &pExtInfo->multiview, - &pExtInfo->multiviewGeometryShader, - &pExtInfo->multiviewTessellationShader); + if (updateFeatures) + { + GetPhysicalDeviceMultiviewFeatures( + &pExtInfo->multiview, + &pExtInfo->multiviewGeometryShader, + &pExtInfo->multiviewTessellationShader); + } + structSize = sizeof(*pExtInfo); break; } @@ -4779,17 +4847,26 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceShaderDrawParameterFeatures( - &pExtInfo->shaderDrawParameters); + if (updateFeatures) + { + GetPhysicalDeviceShaderDrawParameterFeatures( + &pExtInfo->shaderDrawParameters); + } + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_DESCRIPTOR_INDEXING_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceDescriptorIndexingFeatures(pExtInfo); + if (updateFeatures) + { + GetPhysicalDeviceDescriptorIndexingFeatures(pExtInfo); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4797,10 +4874,14 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceFloat16Int8Features( - &pExtInfo->shaderFloat16, - &pExtInfo->shaderInt8); + if (updateFeatures) + { + GetPhysicalDeviceFloat16Int8Features( + &pExtInfo->shaderFloat16, + &pExtInfo->shaderInt8); + } + structSize = sizeof(*pExtInfo); break; } @@ -4808,25 +4889,39 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->inlineUniformBlock = VK_TRUE; - pExtInfo->descriptorBindingInlineUniformBlockUpdateAfterBind = VK_TRUE; + if (updateFeatures) + { + pExtInfo->inlineUniformBlock = VK_TRUE; + pExtInfo->descriptorBindingInlineUniformBlockUpdateAfterBind = VK_TRUE; + } + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SCALAR_BLOCK_LAYOUT_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceScalarBlockLayoutFeatures(&pExtInfo->scalarBlockLayout); + if (updateFeatures) + { + GetPhysicalDeviceScalarBlockLayoutFeatures(&pExtInfo->scalarBlockLayout); + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TRANSFORM_FEEDBACK_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->geometryStreams = VK_TRUE; - pExtInfo->transformFeedback = VK_TRUE; + if (updateFeatures) + { + pExtInfo->geometryStreams = VK_TRUE; + pExtInfo->transformFeedback = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -4835,10 +4930,15 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceVulkanMemoryModelFeatures( - &pExtInfo->vulkanMemoryModel, - &pExtInfo->vulkanMemoryModelDeviceScope, - &pExtInfo->vulkanMemoryModelAvailabilityVisibilityChains); + if (updateFeatures) + { + GetPhysicalDeviceVulkanMemoryModelFeatures( + &pExtInfo->vulkanMemoryModel, + &pExtInfo->vulkanMemoryModelDeviceScope, + &pExtInfo->vulkanMemoryModelAvailabilityVisibilityChains); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4846,49 +4946,92 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_DEMOTE_TO_HELPER_INVOCATION_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->shaderDemoteToHelperInvocation = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->shaderDemoteToHelperInvocation = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); + break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_IMAGE_ATOMIC_INT64_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->shaderImageInt64Atomics = VK_TRUE; - pExtInfo->sparseImageInt64Atomics = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->shaderImageInt64Atomics = VK_TRUE; + pExtInfo->sparseImageInt64Atomics = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_TERMINATE_INVOCATION_FEATURES_KHR: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->shaderTerminateInvocation = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->shaderTerminateInvocation = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PIPELINE_CREATION_CACHE_CONTROL_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->pipelineCreationCacheControl = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->pipelineCreationCacheControl = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_MEMORY_PRIORITY_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->memoryPriority = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->memoryPriority = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_DEPTH_CLIP_ENABLE_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->depthClipEnable = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->depthClipEnable = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_HOST_QUERY_RESET_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceHostQueryResetFeatures(&pExtInfo->hostQueryReset); + + if (updateFeatures) + { + GetPhysicalDeviceHostQueryResetFeatures(&pExtInfo->hostQueryReset); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4897,8 +5040,13 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->vertexAttributeInstanceRateDivisor = VK_TRUE; - pExtInfo->vertexAttributeInstanceRateZeroDivisor = VK_TRUE; + if (updateFeatures) + { + pExtInfo->vertexAttributeInstanceRateDivisor = VK_TRUE; + pExtInfo->vertexAttributeInstanceRateZeroDivisor = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -4907,34 +5055,50 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - bool deviceCoherentMemoryEnabled = false; + if (updateFeatures) + { + bool deviceCoherentMemoryEnabled = false; + + deviceCoherentMemoryEnabled = PalProperties().gfxipProperties.flags.supportGl2Uncached; - deviceCoherentMemoryEnabled = PalProperties().gfxipProperties.flags.supportGl2Uncached; + pExtInfo->deviceCoherentMemory = deviceCoherentMemoryEnabled; + } - pExtInfo->deviceCoherentMemory = deviceCoherentMemoryEnabled; + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_BUFFER_DEVICE_ADDRESS_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceBufferAddressFeatures( - &pExtInfo->bufferDeviceAddress, - &pExtInfo->bufferDeviceAddressCaptureReplay, - &pExtInfo->bufferDeviceAddressMultiDevice); + if (updateFeatures) + { + GetPhysicalDeviceBufferAddressFeatures( + &pExtInfo->bufferDeviceAddress, + &pExtInfo->bufferDeviceAddressCaptureReplay, + &pExtInfo->bufferDeviceAddressMultiDevice); + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_LINE_RASTERIZATION_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->rectangularLines = VK_FALSE; - pExtInfo->bresenhamLines = VK_TRUE; - pExtInfo->smoothLines = VK_FALSE; - pExtInfo->stippledRectangularLines = VK_FALSE; - pExtInfo->stippledBresenhamLines = VK_TRUE; - pExtInfo->stippledSmoothLines = VK_FALSE; + if (updateFeatures) + { + pExtInfo->rectangularLines = VK_FALSE; + pExtInfo->bresenhamLines = VK_TRUE; + pExtInfo->smoothLines = VK_FALSE; + + pExtInfo->stippledRectangularLines = VK_FALSE; + pExtInfo->stippledBresenhamLines = VK_TRUE; + pExtInfo->stippledSmoothLines = VK_FALSE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -4942,7 +5106,13 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_UNIFORM_BUFFER_STANDARD_LAYOUT_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceUniformBufferStandardLayoutFeatures(&pExtInfo->uniformBufferStandardLayout); + + if (updateFeatures) + { + GetPhysicalDeviceUniformBufferStandardLayoutFeatures(&pExtInfo->uniformBufferStandardLayout); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4950,7 +5120,13 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SEPARATE_DEPTH_STENCIL_LAYOUTS_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceSeparateDepthStencilLayoutsFeatures(&pExtInfo->separateDepthStencilLayouts); + + if (updateFeatures) + { + GetPhysicalDeviceSeparateDepthStencilLayoutsFeatures(&pExtInfo->separateDepthStencilLayouts); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4959,8 +5135,13 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->shaderSubgroupClock = PalProperties().gfxipProperties.flags.supportShaderSubgroupClock; - pExtInfo->shaderDeviceClock = PalProperties().gfxipProperties.flags.supportShaderDeviceClock; + if (updateFeatures) + { + pExtInfo->shaderSubgroupClock = PalProperties().gfxipProperties.flags.supportShaderSubgroupClock; + pExtInfo->shaderDeviceClock = PalProperties().gfxipProperties.flags.supportShaderDeviceClock; + } + + structSize = sizeof(*pExtInfo); break; } @@ -4968,7 +5149,13 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SHADER_SUBGROUP_EXTENDED_TYPES_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceSubgroupExtendedTypesFeatures(&pExtInfo->shaderSubgroupExtendedTypes); + + if (updateFeatures) + { + GetPhysicalDeviceSubgroupExtendedTypesFeatures(&pExtInfo->shaderSubgroupExtendedTypes); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4976,15 +5163,27 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SUBGROUP_SIZE_CONTROL_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->subgroupSizeControl = VK_TRUE; - pExtInfo->computeFullSubgroups = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->subgroupSizeControl = VK_TRUE; + pExtInfo->computeFullSubgroups = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGELESS_FRAMEBUFFER_FEATURES: { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDeviceImagelessFramebufferFeatures(&pExtInfo->imagelessFramebuffer); + + if (updateFeatures) + { + GetPhysicalDeviceImagelessFramebufferFeatures(&pExtInfo->imagelessFramebuffer); + } + + structSize = sizeof(*pExtInfo); break; } @@ -4992,7 +5191,14 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PIPELINE_EXECUTABLE_PROPERTIES_FEATURES_KHR: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->pipelineExecutableInfo = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->pipelineExecutableInfo = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); + break; } @@ -5000,26 +5206,31 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDevice16BitStorageFeatures( - &pExtInfo->storageBuffer16BitAccess, - &pExtInfo->uniformAndStorageBuffer16BitAccess, - &pExtInfo->storagePushConstant16, - &pExtInfo->storageInputOutput16); + if (updateFeatures) + { + GetPhysicalDevice16BitStorageFeatures( + &pExtInfo->storageBuffer16BitAccess, + &pExtInfo->uniformAndStorageBuffer16BitAccess, + &pExtInfo->storagePushConstant16, + &pExtInfo->storageInputOutput16); + + GetPhysicalDeviceMultiviewFeatures( + &pExtInfo->multiview, + &pExtInfo->multiviewGeometryShader, + &pExtInfo->multiviewTessellationShader); - GetPhysicalDeviceMultiviewFeatures( - &pExtInfo->multiview, - &pExtInfo->multiviewGeometryShader, - &pExtInfo->multiviewTessellationShader); + GetPhysicalDeviceVariablePointerFeatures( + &pExtInfo->variablePointersStorageBuffer, + &pExtInfo->variablePointers); - GetPhysicalDeviceVariablePointerFeatures( - &pExtInfo->variablePointersStorageBuffer, - &pExtInfo->variablePointers); + GetPhysicalDeviceProtectedMemoryFeatures(&pExtInfo->protectedMemory); - GetPhysicalDeviceProtectedMemoryFeatures(&pExtInfo->protectedMemory); + GetPhysicalDeviceSamplerYcbcrConversionFeatures(&pExtInfo->samplerYcbcrConversion); - GetPhysicalDeviceSamplerYcbcrConversionFeatures(&pExtInfo->samplerYcbcrConversion); + GetPhysicalDeviceShaderDrawParameterFeatures(&pExtInfo->shaderDrawParameters); + } - GetPhysicalDeviceShaderDrawParameterFeatures(&pExtInfo->shaderDrawParameters); + structSize = sizeof(*pExtInfo); break; } @@ -5028,52 +5239,57 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - GetPhysicalDevice8BitStorageFeatures( - &pExtInfo->storageBuffer8BitAccess, - &pExtInfo->uniformAndStorageBuffer8BitAccess, - &pExtInfo->storagePushConstant8); + if (updateFeatures) + { + GetPhysicalDevice8BitStorageFeatures( + &pExtInfo->storageBuffer8BitAccess, + &pExtInfo->uniformAndStorageBuffer8BitAccess, + &pExtInfo->storagePushConstant8); + + GetPhysicalDeviceShaderAtomicInt64Features( + &pExtInfo->shaderBufferInt64Atomics, + &pExtInfo->shaderSharedInt64Atomics); - GetPhysicalDeviceShaderAtomicInt64Features( - &pExtInfo->shaderBufferInt64Atomics, - &pExtInfo->shaderSharedInt64Atomics); + GetPhysicalDeviceFloat16Int8Features(&pExtInfo->shaderFloat16, &pExtInfo->shaderInt8); - GetPhysicalDeviceFloat16Int8Features(&pExtInfo->shaderFloat16, &pExtInfo->shaderInt8); + GetPhysicalDeviceDescriptorIndexingFeatures(pExtInfo); - GetPhysicalDeviceDescriptorIndexingFeatures(pExtInfo); + GetPhysicalDeviceScalarBlockLayoutFeatures(&pExtInfo->scalarBlockLayout); - GetPhysicalDeviceScalarBlockLayoutFeatures(&pExtInfo->scalarBlockLayout); + GetPhysicalDeviceImagelessFramebufferFeatures(&pExtInfo->imagelessFramebuffer); - GetPhysicalDeviceImagelessFramebufferFeatures(&pExtInfo->imagelessFramebuffer); + GetPhysicalDeviceUniformBufferStandardLayoutFeatures(&pExtInfo->uniformBufferStandardLayout); - GetPhysicalDeviceUniformBufferStandardLayoutFeatures(&pExtInfo->uniformBufferStandardLayout); + GetPhysicalDeviceSubgroupExtendedTypesFeatures(&pExtInfo->shaderSubgroupExtendedTypes); - GetPhysicalDeviceSubgroupExtendedTypesFeatures(&pExtInfo->shaderSubgroupExtendedTypes); + GetPhysicalDeviceSeparateDepthStencilLayoutsFeatures(&pExtInfo->separateDepthStencilLayouts); - GetPhysicalDeviceSeparateDepthStencilLayoutsFeatures(&pExtInfo->separateDepthStencilLayouts); + GetPhysicalDeviceHostQueryResetFeatures(&pExtInfo->hostQueryReset); - GetPhysicalDeviceHostQueryResetFeatures(&pExtInfo->hostQueryReset); + GetPhysicalDeviceTimelineSemaphoreFeatures(&pExtInfo->timelineSemaphore); - GetPhysicalDeviceTimelineSemaphoreFeatures(&pExtInfo->timelineSemaphore); + GetPhysicalDeviceBufferAddressFeatures( + &pExtInfo->bufferDeviceAddress, + &pExtInfo->bufferDeviceAddressCaptureReplay, + &pExtInfo->bufferDeviceAddressMultiDevice); - GetPhysicalDeviceBufferAddressFeatures( - &pExtInfo->bufferDeviceAddress, - &pExtInfo->bufferDeviceAddressCaptureReplay, - &pExtInfo->bufferDeviceAddressMultiDevice); + GetPhysicalDeviceVulkanMemoryModelFeatures( + &pExtInfo->vulkanMemoryModel, + &pExtInfo->vulkanMemoryModelDeviceScope, + &pExtInfo->vulkanMemoryModelAvailabilityVisibilityChains); - GetPhysicalDeviceVulkanMemoryModelFeatures( - &pExtInfo->vulkanMemoryModel, - &pExtInfo->vulkanMemoryModelDeviceScope, - &pExtInfo->vulkanMemoryModelAvailabilityVisibilityChains); + // These features aren't new to Vulkan 1.2, but the caps just didn't exist in their original extensions. + pExtInfo->samplerMirrorClampToEdge = VK_TRUE; + pExtInfo->drawIndirectCount = VK_TRUE; + pExtInfo->descriptorIndexing = VK_TRUE; + pExtInfo->samplerFilterMinmax = + IsSingleChannelMinMaxFilteringSupported(this) ? VK_TRUE : VK_FALSE; + pExtInfo->shaderOutputViewportIndex = VK_TRUE; + pExtInfo->shaderOutputLayer = VK_TRUE; + pExtInfo->subgroupBroadcastDynamicId = VK_TRUE; + } - // These features aren't new to Vulkan 1.2, but the caps just didn't exist in their original extensions. - pExtInfo->samplerMirrorClampToEdge = VK_TRUE; - pExtInfo->drawIndirectCount = VK_TRUE; - pExtInfo->descriptorIndexing = VK_TRUE; - pExtInfo->samplerFilterMinmax = - IsSingleChannelMinMaxFilteringSupported(this) ? VK_TRUE : VK_FALSE; - pExtInfo->shaderOutputViewportIndex = VK_TRUE; - pExtInfo->shaderOutputLayer = VK_TRUE; - pExtInfo->subgroupBroadcastDynamicId = VK_TRUE; + structSize = sizeof(*pExtInfo); break; } @@ -5082,12 +5298,17 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - bool vrsSupported = (PalProperties().gfxipProperties.supportedVrsRates > 0); - bool vrsImageSupported = (PalProperties().imageProperties.vrsTileSize.width > 0); + if (updateFeatures) + { + bool vrsSupported = (PalProperties().gfxipProperties.supportedVrsRates > 0); + bool vrsImageSupported = (PalProperties().imageProperties.vrsTileSize.width > 0); + + pExtInfo->attachmentFragmentShadingRate = vrsImageSupported; + pExtInfo->pipelineFragmentShadingRate = vrsSupported; + pExtInfo->primitiveFragmentShadingRate = vrsSupported; + } - pExtInfo->attachmentFragmentShadingRate = vrsImageSupported; - pExtInfo->pipelineFragmentShadingRate = vrsSupported; - pExtInfo->primitiveFragmentShadingRate = vrsSupported; + structSize = sizeof(*pExtInfo); break; } @@ -5096,33 +5317,51 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - if (IsConditionalRenderingSupported(this)) - { - pExtInfo->conditionalRendering = VK_TRUE; - pExtInfo->inheritedConditionalRendering = VK_TRUE; - } - else + if (updateFeatures) { - pExtInfo->conditionalRendering = VK_FALSE; - pExtInfo->inheritedConditionalRendering = VK_FALSE; + if (IsConditionalRenderingSupported(this)) + { + pExtInfo->conditionalRendering = VK_TRUE; + pExtInfo->inheritedConditionalRendering = VK_TRUE; + } + else + { + pExtInfo->conditionalRendering = VK_FALSE; + pExtInfo->inheritedConditionalRendering = VK_FALSE; + } } + structSize = sizeof(*pExtInfo); + break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_TEXEL_BUFFER_ALIGNMENT_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->texelBufferAlignment = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->texelBufferAlignment = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); + break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_ROBUSTNESS_2_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->robustImageAccess2 = VK_TRUE; - pExtInfo->robustBufferAccess2 = VK_TRUE; - pExtInfo->nullDescriptor = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->robustImageAccess2 = VK_TRUE; + pExtInfo->robustBufferAccess2 = VK_TRUE; + pExtInfo->nullDescriptor = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -5130,14 +5369,26 @@ void PhysicalDevice::GetFeatures2( case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_EXTENDED_DYNAMIC_STATE_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->extendedDynamicState = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->extendedDynamicState = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_PRIVATE_DATA_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->privateData = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->privateData = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -5145,44 +5396,80 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->shaderSubgroupUniformControlFlow = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->shaderSubgroupUniformControlFlow = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_ROBUSTNESS_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->robustImageAccess = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->robustImageAccess = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_4444_FORMATS_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->formatA4R4G4B4 = VK_TRUE; - pExtInfo->formatA4B4G4R4 = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->formatA4R4G4B4 = VK_TRUE; + pExtInfo->formatA4B4G4R4 = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SYNCHRONIZATION_2_FEATURES_KHR: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->synchronization2 = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->synchronization2 = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_CUSTOM_BORDER_COLOR_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->customBorderColors = VK_TRUE; - pExtInfo->customBorderColorWithoutFormat = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->customBorderColors = VK_TRUE; + pExtInfo->customBorderColorWithoutFormat = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_COLOR_WRITE_ENABLE_FEATURES_EXT: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->colorWriteEnable = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->colorWriteEnable = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -5190,9 +5477,14 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->extendedDynamicState2 = VK_TRUE; - pExtInfo->extendedDynamicState2LogicOp = VK_FALSE; - pExtInfo->extendedDynamicState2PatchControlPoints = VK_FALSE; + if (updateFeatures) + { + pExtInfo->extendedDynamicState2 = VK_TRUE; + pExtInfo->extendedDynamicState2LogicOp = VK_FALSE; + pExtInfo->extendedDynamicState2PatchControlPoints = VK_FALSE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -5200,15 +5492,25 @@ void PhysicalDevice::GetFeatures2( { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->ycbcrImageArrays = VK_FALSE; + if (updateFeatures) + { + pExtInfo->ycbcrImageArrays = VK_FALSE; + } + structSize = sizeof(*pExtInfo); break; } case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_ZERO_INITIALIZE_WORKGROUP_MEMORY_FEATURES_KHR: { auto* pExtInfo = reinterpret_cast(pHeader); - pExtInfo->shaderZeroInitializeWorkgroupMemory = VK_TRUE; + + if (updateFeatures) + { + pExtInfo->shaderZeroInitializeWorkgroupMemory = VK_TRUE; + } + + structSize = sizeof(*pExtInfo); break; } @@ -5221,6 +5523,8 @@ void PhysicalDevice::GetFeatures2( pHeader = reinterpret_cast(pHeader->pNext); } + + return structSize; } // ===================================================================================================================== @@ -5737,7 +6041,8 @@ void PhysicalDevice::GetDeviceProperties2( pProps->primitiveFragmentShadingRateWithMultipleViewports = VK_TRUE; pProps->layeredShadingRateAttachments = VK_FALSE; pProps->fragmentShadingRateNonTrivialCombinerOps = VK_TRUE; - pProps->maxFragmentSizeAspectRatio = 1; + pProps->maxFragmentSizeAspectRatio = Util::Max(pProps->maxFragmentSize.width, + pProps->maxFragmentSize.height); pProps->fragmentShadingRateWithShaderDepthStencilWrites = PalProperties().gfxipProperties.flags.supportVrsWithDsExports; pProps->fragmentShadingRateWithSampleMask = VK_TRUE; @@ -5746,9 +6051,9 @@ void PhysicalDevice::GetDeviceProperties2( pProps->fragmentShadingRateWithFragmentShaderInterlock = VK_FALSE; pProps->fragmentShadingRateWithCustomSampleLocations = VK_TRUE; pProps->fragmentShadingRateStrictMultiplyCombiner = VK_TRUE; - - pProps->maxFragmentShadingRateCoverageSamples = - (pProps->maxFragmentSize.width * pProps->maxFragmentSize.height); + pProps->maxFragmentShadingRateCoverageSamples = + Util::Min((m_limits.maxSampleMaskWords * 32u), + (pProps->maxFragmentSize.width * pProps->maxFragmentSize.height * Pal::MaxMsaaColorSamples)); pProps->maxFragmentShadingRateRasterizationSamples = static_cast(Pal::MaxMsaaColorSamples); @@ -5798,6 +6103,7 @@ void PhysicalDevice::GetFormatProperties2( { VK_ASSERT(pFormatProperties->sType == VK_STRUCTURE_TYPE_FORMAT_PROPERTIES_2); GetFormatProperties(format, &pFormatProperties->formatProperties); + } // ===================================================================================================================== @@ -6496,7 +6802,7 @@ static void VerifyProperties( VkPhysicalDeviceFeatures features = {}; - VK_ASSERT(device.GetFeatures(&features) == VK_SUCCESS); + device.GetFeatures(&features); VerifyLimits(device, limits, features); @@ -6888,10 +7194,10 @@ VkResult PhysicalDevice::GetFragmentShadingRates( VK_SAMPLE_COUNT_2_BIT | VK_SAMPLE_COUNT_4_BIT; - // Set 8 samples on 1x1 + // For fragmentSize {1,1} the sampleCounts must be ~0, requiriment from spec. if ((fragmentSize.width == 1) && (fragmentSize.height == 1)) { - sampleCounts |= VK_SAMPLE_COUNT_8_BIT; + sampleCounts = ~0u; } pFragmentShadingRates[outputCount].sampleCounts = sampleCounts; @@ -7170,7 +7476,7 @@ VKAPI_ATTR void VKAPI_CALL vkGetPhysicalDeviceFeatures2( VkPhysicalDeviceFeatures2* pFeatures) { ApiPhysicalDevice::ObjectFromHandle(physicalDevice)->GetFeatures2( - reinterpret_cast(pFeatures)); + reinterpret_cast(pFeatures), true); } // ===================================================================================================================== diff --git a/icd/api/vk_pipeline.cpp b/icd/api/vk_pipeline.cpp index 0ea7d349..22f44042 100644 --- a/icd/api/vk_pipeline.cpp +++ b/icd/api/vk_pipeline.cpp @@ -147,6 +147,114 @@ void Pipeline::GenerateHashFromDynamicStateCreateInfo( } } +// ===================================================================================================================== +VkResult Pipeline::BuildShaderStageInfo( + const Device* pDevice, + const uint32_t stageCount, + const VkPipelineShaderStageCreateInfo* pStages, + uint32_t (*pfnGetOutputIdx)(const uint32_t inputIdx, + const uint32_t stageIdx), + ShaderStageInfo* pShaderStageInfo, + ShaderModuleHandle* pTempModules) +{ + VkResult result = VK_SUCCESS; + + PipelineCompiler* pCompiler = pDevice->GetCompiler(DefaultDeviceIndex); + + uint32_t numNewModules = 0; + + for (uint32_t i = 0; i < stageCount; ++i) + { + const VkPipelineShaderStageCreateInfo& stageInfo = pStages[i]; + const ShaderStage stage = ShaderFlagBitToStage(stageInfo.stage); + const uint32_t outIdx = pfnGetOutputIdx(i, stage); + + if (stageInfo.module != VK_NULL_HANDLE) + { + const ShaderModule* pModule = ShaderModule::ObjectFromHandle(stageInfo.module); + + pShaderStageInfo[outIdx].pModuleHandle = pModule->GetShaderModuleHandle(); + pShaderStageInfo[outIdx].codeHash = pModule->GetCodeHash(stageInfo.pName); + pShaderStageInfo[outIdx].codeSize = pModule->GetCodeSize(); + } + else + { + // Caller must make sure that pNewModules should be non-null if shader module may be deprecated. + // Meanwhile, the memory pointed by pNewModules should be initialized to 0 and can take all the + // newly-built modules in the pipeline (at most stageCount entries required). + // Caller should release the newly-built temporary modules set in pNewModules manually after + // creation of pipeline. + VK_ASSERT(pTempModules != nullptr); + + EXTRACT_VK_STRUCTURES_0( + shaderModule, + ShaderModuleCreateInfo, + static_cast(stageInfo.pNext), + SHADER_MODULE_CREATE_INFO); + + VK_ASSERT(pShaderModuleCreateInfo != nullptr); + + const Pal::ShaderHash codeHash = + ShaderModule::BuildCodeHash(pShaderModuleCreateInfo->pCode, pShaderModuleCreateInfo->codeSize); + + result = pCompiler->BuildShaderModule(pDevice, + pShaderModuleCreateInfo->flags, + pShaderModuleCreateInfo->codeSize, + pShaderModuleCreateInfo->pCode, + &pTempModules[numNewModules]); + + if (result != VK_SUCCESS) + { + break; + } + + pShaderStageInfo[outIdx].pModuleHandle = &pTempModules[numNewModules++]; + pShaderStageInfo[outIdx].codeHash = ShaderModule::GetCodeHash(codeHash, stageInfo.pName); + pShaderStageInfo[outIdx].codeSize = pShaderModuleCreateInfo->codeSize; + } + + pShaderStageInfo[outIdx].stage = stage; + pShaderStageInfo[outIdx].pEntryPoint = stageInfo.pName; + pShaderStageInfo[outIdx].flags = stageInfo.flags; + pShaderStageInfo[outIdx].pSpecializationInfo = stageInfo.pSpecializationInfo; + + } + + if (result != VK_SUCCESS) + { + for (uint32_t i = 0; i < numNewModules; ++i) + { + pCompiler->FreeShaderModule(&pTempModules[i]); + } + } + + return result; +} + +// ===================================================================================================================== +void Pipeline::FreeTempModules( + const Device* pDevice, + const uint32_t maxStageCount, + ShaderModuleHandle* pTempModules) +{ + if ((pTempModules != nullptr) && (maxStageCount > 0)) + { + PipelineCompiler* pCompiler = pDevice->GetCompiler(DefaultDeviceIndex); + + for (uint32_t i = 0; i < maxStageCount; ++i) + { + if (pCompiler->IsValidShaderModule(&pTempModules[i])) + { + pCompiler->FreeShaderModule(&pTempModules[i]); + } + else + { + break; + } + } + } +} + // ===================================================================================================================== Pipeline::Pipeline( Device* const pDevice, diff --git a/icd/api/vk_pipeline_layout.cpp b/icd/api/vk_pipeline_layout.cpp index 9b9172a0..4d0b8589 100644 --- a/icd/api/vk_pipeline_layout.cpp +++ b/icd/api/vk_pipeline_layout.cpp @@ -464,71 +464,13 @@ VkResult PipelineLayout::BuildLlpcSetMapping( return VK_SUCCESS; } -// ===================================================================================================================== -// Builds the description of the internal descriptor set used to represent the VB table for SC. Returns the number -// of ResourceMappingNodes consumed by this function. This function does not add the node that describes the top-level -// pointer to this set. -int32_t PipelineLayout::BuildLlpcVertexInputDescriptors( - const VkPipelineVertexInputStateCreateInfo* pInput, - VbBindingInfo* pVbInfo) const -{ - VK_ASSERT(pVbInfo != nullptr); - - const uint32_t srdDwSize = m_pDevice->GetProperties().descriptorSizes.bufferView / sizeof(uint32_t); - uint32_t activeBindings = 0; - - // Sort the strides by binding slot - uint32_t strideByBindingSlot[Pal::MaxVertexBuffers] = {}; - - for (uint32_t recordIndex = 0; recordIndex < pInput->vertexBindingDescriptionCount; ++recordIndex) - { - const VkVertexInputBindingDescription& record = pInput->pVertexBindingDescriptions[recordIndex]; - - strideByBindingSlot[record.binding] = record.stride; - } - - // Build the description of the VB table by inserting all of the active binding slots into it - pVbInfo->bindingCount = 0; - pVbInfo->bindingTableSize = 0; - // Find the set of active vertex buffer bindings by figuring out which vertex attributes are consumed by the - // pipeline. - // - // (Note that this ignores inputs eliminated by whole program optimization, but considering that we have not yet - // compiled the shader and have not performed whole program optimization, this is the best we can do; it's a - // chicken-egg problem). - - for (uint32_t aindex = 0; aindex < pInput->vertexAttributeDescriptionCount; ++aindex) - { - const VkVertexInputAttributeDescription& attrib = pInput->pVertexAttributeDescriptions[aindex]; - - VK_ASSERT(attrib.binding < Pal::MaxVertexBuffers); - - bool isNotActiveBinding = ((1 << attrib.binding) & activeBindings) == 0; - - if (isNotActiveBinding) - { - // Write out the meta information that the VB binding manager needs from pipelines - auto* pOutBinding = &pVbInfo->bindings[pVbInfo->bindingCount++]; - activeBindings |= (1 << attrib.binding); - - pOutBinding->slot = attrib.binding; - pOutBinding->byteStride = strideByBindingSlot[attrib.binding]; - - pVbInfo->bindingTableSize = Util::Max(pVbInfo->bindingTableSize, attrib.binding + 1); - } - } - - return srdDwSize *pVbInfo->bindingTableSize; -} - // ===================================================================================================================== // This function populates the resource mapping node details to the shader-stage specific pipeline info structure. VkResult PipelineLayout::BuildLlpcPipelineMapping( - uint32_t stageMask, - void* pBuffer, - Vkgc::ResourceMappingData* pResourceMapping, - const VkPipelineVertexInputStateCreateInfo* pVertexInput, - VbBindingInfo* pVbInfo + const uint32_t stageMask, + const VbBindingInfo* pVbInfo, + void* pBuffer, + Vkgc::ResourceMappingData* pResourceMapping ) const { VkResult result = VK_SUCCESS; @@ -632,7 +574,7 @@ VkResult PipelineLayout::BuildLlpcPipelineMapping( } } - if ((result == VK_SUCCESS) && (pVertexInput != nullptr)) + if ((result == VK_SUCCESS) && (pVbInfo != nullptr)) { // Build the internal vertex buffer table mapping constexpr uint32_t VbTablePtrRegCount = 1; // PAL requires all indirect user data tables to be 1DW @@ -643,8 +585,8 @@ VkResult PipelineLayout::BuildLlpcPipelineMapping( VK_ASSERT(pVbInfo != nullptr); // Build the table description itself - auto vbTableSize = BuildLlpcVertexInputDescriptors(pVertexInput, - pVbInfo); + const uint32_t srdDwSize = m_pDevice->GetProperties().descriptorSizes.bufferView / sizeof(uint32_t); + uint32_t vbTableSize = pVbInfo->bindingTableSize * srdDwSize; // Add the set pointer node pointing to this table auto pVbTblPtrNode = &pUserDataNodes[userDataNodeCount]; diff --git a/icd/api/vk_queue.cpp b/icd/api/vk_queue.cpp index 75d7153c..04461b66 100644 --- a/icd/api/vk_queue.cpp +++ b/icd/api/vk_queue.cpp @@ -476,7 +476,17 @@ VkResult Queue::Submit( virtStackFrame.AllocArray(cmdBufferCount) : nullptr; - result = ((pPalCmdBuffers != nullptr) || (cmdBufferCount == 0)) ? result : VK_ERROR_OUT_OF_HOST_MEMORY; + Pal::CmdBufInfo* pCmdBufInfos = (cmdBufferCount > 0) ? + virtStackFrame.AllocArray(cmdBufferCount) : + nullptr; + + result = (((pPalCmdBuffers != nullptr) && (pCmdBufInfos != nullptr)) || + (cmdBufferCount == 0)) ? result : VK_ERROR_OUT_OF_HOST_MEMORY; + + if (pCmdBufInfos != nullptr) + { + memset(pCmdBufInfos, 0, sizeof(Pal::CmdBufInfo) * cmdBufferCount); + } bool lastBatch = (submitIdx == submitCount - 1); @@ -485,7 +495,7 @@ VkResult Queue::Submit( perSubQueueInfo.cmdBufferCount = 0; perSubQueueInfo.ppCmdBuffers = pPalCmdBuffers; - perSubQueueInfo.pCmdBufInfoList = nullptr; + perSubQueueInfo.pCmdBufInfoList = pCmdBufInfos; Pal::SubmitInfo palSubmitInfo = {}; @@ -636,6 +646,11 @@ VkResult Queue::Submit( } + if (pCmdBufInfos != nullptr) + { + virtStackFrame.FreeArray(pCmdBufInfos); + } + if (isSynchronization2 && (pCmdBuffers != nullptr)) { virtStackFrame.FreeArray(pCmdBuffers); diff --git a/icd/api/vk_shader.cpp b/icd/api/vk_shader.cpp index 2277648d..07108e59 100644 --- a/icd/api/vk_shader.cpp +++ b/icd/api/vk_shader.cpp @@ -73,14 +73,28 @@ VK_INLINE void MetroHashTo128Bit( static_cast(hash.dwords[3]) << 32; } +// ===================================================================================================================== +// Calculate a 128-bit hash from the SPIRV code. This is used by profile-guided compilation parameter tuning. +Pal::ShaderHash ShaderModule::BuildCodeHash( + const void* pCode, + const size_t codeSize) +{ + Pal::ShaderHash result; + + Util::MetroHash::Hash codeHash = {}; + Util::MetroHash128::Hash(static_cast(pCode), codeSize, codeHash.bytes); + + MetroHashTo128Bit(codeHash, &result.lower, &result.upper); + + return result; +} + // ===================================================================================================================== // Returns a 128-bit hash based on this module's SPIRV code plus an optional entry point combination. Pal::ShaderHash ShaderModule::GetCodeHash( - const char* pEntryPoint - ) const + Pal::ShaderHash codeHash, + const char* pEntryPoint) { - Pal::ShaderHash hash = m_codeHash; - if (pEntryPoint != nullptr) { size_t entryLength = strlen(pEntryPoint); @@ -95,12 +109,12 @@ Pal::ShaderHash ShaderModule::GetCodeHash( MetroHashTo128Bit(entryHash, &entryLower, &entryUpper); - hash.lower ^= entryLower; - hash.upper ^= entryUpper; + codeHash.lower ^= entryLower; + codeHash.upper ^= entryUpper; } } - return hash; + return codeHash; } // ===================================================================================================================== @@ -119,11 +133,11 @@ void* ShaderModule::GetShaderData( // ===================================================================================================================== // Gets first valid shader data. -void* ShaderModule::GetFirstValidShaderData() const +void* ShaderModule::GetFirstValidShaderData(const ShaderModuleHandle* pHandle) { - if (m_handle.pLlpcShaderModule) + if (pHandle->pLlpcShaderModule) { - return m_handle.pLlpcShaderModule; + return pHandle->pLlpcShaderModule; } return nullptr; @@ -136,13 +150,8 @@ ShaderModule::ShaderModule( { m_codeSize = codeSize; m_pCode = pCode; + m_codeHash = BuildCodeHash(pCode, codeSize); - // Calculate a 128-bit hash from the SPIRV code. This is used by profile-guided compilation - // parameter tuning. - Util::MetroHash::Hash codeHash = {}; - Util::MetroHash128::Hash(static_cast(pCode), codeSize, codeHash.bytes); - - MetroHashTo128Bit(codeHash, &m_codeHash.lower, &m_codeHash.upper); memset(&m_handle, 0, sizeof(m_handle)); } @@ -186,8 +195,7 @@ VkResult ShaderModule::Init(const Device* pDevice, VkShaderModuleCreateFlags fla flags, m_codeSize, m_pCode, - &m_handle - ); + &m_handle); } // ===================================================================================================================== diff --git a/icd/imported/gputexdecoder/CMakeLists.txt b/icd/imported/gputexdecoder/CMakeLists.txt new file mode 100644 index 00000000..376ec67d --- /dev/null +++ b/icd/imported/gputexdecoder/CMakeLists.txt @@ -0,0 +1,38 @@ +## + ####################################################################################################################### + # + # Copyright (c) 2021 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"), to deal + # in the Software without restriction, including without limitation the rights + # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + # copies of the Software, and to permit persons to whom the Software is + # furnished to do so, subject to the following conditions: + # + # The above copyright notice and this permission notice shall be included in all + # copies or substantial portions of the Software. + # + # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + # SOFTWARE. + # + ####################################################################################################################### +project(GPU_TEX_DECODER + LANGUAGES "CXX" +) + +add_library(gputexdecoder STATIC) +add_library(AMD::gputexdecoder ALIAS gputexdecoder) + +# add PAL dependency +target_link_libraries(gputexdecoder PUBLIC pal) + +### Add Source Directories +target_include_directories(gputexdecoder PUBLIC ${CMAKE_CURRENT_LIST_DIR}) +target_sources(gputexdecoder PRIVATE ${CMAKE_CURRENT_LIST_DIR}/gpuTexDecoder.cpp) + diff --git a/icd/imported/gputexdecoder/gpuTexDecoder.cpp b/icd/imported/gputexdecoder/gpuTexDecoder.cpp new file mode 100755 index 00000000..5ff7541a --- /dev/null +++ b/icd/imported/gputexdecoder/gpuTexDecoder.cpp @@ -0,0 +1,753 @@ +/* + *********************************************************************************************************************** + * + * Copyright (c) 2021 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"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + **********************************************************************************************************************/ +/** + *********************************************************************************************************************** + * @file gpuTexDecoder.cpp + * @brief Contains implementation of gpuTexDecoder object. + *********************************************************************************************************************** + */ +#include "gpuTexDecoder.h" +#include "shaders.h" + +namespace GpuTexDecoder +{ +struct TritsQuintsTable +{ + const int TritsOfInteger[256][5] = + { + {0, 0, 0, 0, 0}, {1, 0, 0, 0, 0}, {2, 0, 0, 0, 0}, {0, 0, 2, 0, 0}, + {0, 1, 0, 0, 0}, {1, 1, 0, 0, 0}, {2, 1, 0, 0, 0}, {1, 0, 2, 0, 0}, + {0, 2, 0, 0, 0}, {1, 2, 0, 0, 0}, {2, 2, 0, 0, 0}, {2, 0, 2, 0, 0}, + {0, 2, 2, 0, 0}, {1, 2, 2, 0, 0}, {2, 2, 2, 0, 0}, {2, 0, 2, 0, 0}, + {0, 0, 1, 0, 0}, {1, 0, 1, 0, 0}, {2, 0, 1, 0, 0}, {0, 1, 2, 0, 0}, + {0, 1, 1, 0, 0}, {1, 1, 1, 0, 0}, {2, 1, 1, 0, 0}, {1, 1, 2, 0, 0}, + {0, 2, 1, 0, 0}, {1, 2, 1, 0, 0}, {2, 2, 1, 0, 0}, {2, 1, 2, 0, 0}, + {0, 0, 0, 2, 2}, {1, 0, 0, 2, 2}, {2, 0, 0, 2, 2}, {0, 0, 2, 2, 2}, + {0, 0, 0, 1, 0}, {1, 0, 0, 1, 0}, {2, 0, 0, 1, 0}, {0, 0, 2, 1, 0}, + {0, 1, 0, 1, 0}, {1, 1, 0, 1, 0}, {2, 1, 0, 1, 0}, {1, 0, 2, 1, 0}, + {0, 2, 0, 1, 0}, {1, 2, 0, 1, 0}, {2, 2, 0, 1, 0}, {2, 0, 2, 1, 0}, + {0, 2, 2, 1, 0}, {1, 2, 2, 1, 0}, {2, 2, 2, 1, 0}, {2, 0, 2, 1, 0}, + {0, 0, 1, 1, 0}, {1, 0, 1, 1, 0}, {2, 0, 1, 1, 0}, {0, 1, 2, 1, 0}, + {0, 1, 1, 1, 0}, {1, 1, 1, 1, 0}, {2, 1, 1, 1, 0}, {1, 1, 2, 1, 0}, + {0, 2, 1, 1, 0}, {1, 2, 1, 1, 0}, {2, 2, 1, 1, 0}, {2, 1, 2, 1, 0}, + {0, 1, 0, 2, 2}, {1, 1, 0, 2, 2}, {2, 1, 0, 2, 2}, {1, 0, 2, 2, 2}, + {0, 0, 0, 2, 0}, {1, 0, 0, 2, 0}, {2, 0, 0, 2, 0}, {0, 0, 2, 2, 0}, + {0, 1, 0, 2, 0}, {1, 1, 0, 2, 0}, {2, 1, 0, 2, 0}, {1, 0, 2, 2, 0}, + {0, 2, 0, 2, 0}, {1, 2, 0, 2, 0}, {2, 2, 0, 2, 0}, {2, 0, 2, 2, 0}, + {0, 2, 2, 2, 0}, {1, 2, 2, 2, 0}, {2, 2, 2, 2, 0}, {2, 0, 2, 2, 0}, + {0, 0, 1, 2, 0}, {1, 0, 1, 2, 0}, {2, 0, 1, 2, 0}, {0, 1, 2, 2, 0}, + {0, 1, 1, 2, 0}, {1, 1, 1, 2, 0}, {2, 1, 1, 2, 0}, {1, 1, 2, 2, 0}, + {0, 2, 1, 2, 0}, {1, 2, 1, 2, 0}, {2, 2, 1, 2, 0}, {2, 1, 2, 2, 0}, + {0, 2, 0, 2, 2}, {1, 2, 0, 2, 2}, {2, 2, 0, 2, 2}, {2, 0, 2, 2, 2}, + {0, 0, 0, 0, 2}, {1, 0, 0, 0, 2}, {2, 0, 0, 0, 2}, {0, 0, 2, 0, 2}, + {0, 1, 0, 0, 2}, {1, 1, 0, 0, 2}, {2, 1, 0, 0, 2}, {1, 0, 2, 0, 2}, + {0, 2, 0, 0, 2}, {1, 2, 0, 0, 2}, {2, 2, 0, 0, 2}, {2, 0, 2, 0, 2}, + {0, 2, 2, 0, 2}, {1, 2, 2, 0, 2}, {2, 2, 2, 0, 2}, {2, 0, 2, 0, 2}, + {0, 0, 1, 0, 2}, {1, 0, 1, 0, 2}, {2, 0, 1, 0, 2}, {0, 1, 2, 0, 2}, + {0, 1, 1, 0, 2}, {1, 1, 1, 0, 2}, {2, 1, 1, 0, 2}, {1, 1, 2, 0, 2}, + {0, 2, 1, 0, 2}, {1, 2, 1, 0, 2}, {2, 2, 1, 0, 2}, {2, 1, 2, 0, 2}, + {0, 2, 2, 2, 2}, {1, 2, 2, 2, 2}, {2, 2, 2, 2, 2}, {2, 0, 2, 2, 2}, + {0, 0, 0, 0, 1}, {1, 0, 0, 0, 1}, {2, 0, 0, 0, 1}, {0, 0, 2, 0, 1}, + {0, 1, 0, 0, 1}, {1, 1, 0, 0, 1}, {2, 1, 0, 0, 1}, {1, 0, 2, 0, 1}, + {0, 2, 0, 0, 1}, {1, 2, 0, 0, 1}, {2, 2, 0, 0, 1}, {2, 0, 2, 0, 1}, + {0, 2, 2, 0, 1}, {1, 2, 2, 0, 1}, {2, 2, 2, 0, 1}, {2, 0, 2, 0, 1}, + {0, 0, 1, 0, 1}, {1, 0, 1, 0, 1}, {2, 0, 1, 0, 1}, {0, 1, 2, 0, 1}, + {0, 1, 1, 0, 1}, {1, 1, 1, 0, 1}, {2, 1, 1, 0, 1}, {1, 1, 2, 0, 1}, + {0, 2, 1, 0, 1}, {1, 2, 1, 0, 1}, {2, 2, 1, 0, 1}, {2, 1, 2, 0, 1}, + {0, 0, 1, 2, 2}, {1, 0, 1, 2, 2}, {2, 0, 1, 2, 2}, {0, 1, 2, 2, 2}, + {0, 0, 0, 1, 1}, {1, 0, 0, 1, 1}, {2, 0, 0, 1, 1}, {0, 0, 2, 1, 1}, + {0, 1, 0, 1, 1}, {1, 1, 0, 1, 1}, {2, 1, 0, 1, 1}, {1, 0, 2, 1, 1}, + {0, 2, 0, 1, 1}, {1, 2, 0, 1, 1}, {2, 2, 0, 1, 1}, {2, 0, 2, 1, 1}, + {0, 2, 2, 1, 1}, {1, 2, 2, 1, 1}, {2, 2, 2, 1, 1}, {2, 0, 2, 1, 1}, + {0, 0, 1, 1, 1}, {1, 0, 1, 1, 1}, {2, 0, 1, 1, 1}, {0, 1, 2, 1, 1}, + {0, 1, 1, 1, 1}, {1, 1, 1, 1, 1}, {2, 1, 1, 1, 1}, {1, 1, 2, 1, 1}, + {0, 2, 1, 1, 1}, {1, 2, 1, 1, 1}, {2, 2, 1, 1, 1}, {2, 1, 2, 1, 1}, + {0, 1, 1, 2, 2}, {1, 1, 1, 2, 2}, {2, 1, 1, 2, 2}, {1, 1, 2, 2, 2}, + {0, 0, 0, 2, 1}, {1, 0, 0, 2, 1}, {2, 0, 0, 2, 1}, {0, 0, 2, 2, 1}, + {0, 1, 0, 2, 1}, {1, 1, 0, 2, 1}, {2, 1, 0, 2, 1}, {1, 0, 2, 2, 1}, + {0, 2, 0, 2, 1}, {1, 2, 0, 2, 1}, {2, 2, 0, 2, 1}, {2, 0, 2, 2, 1}, + {0, 2, 2, 2, 1}, {1, 2, 2, 2, 1}, {2, 2, 2, 2, 1}, {2, 0, 2, 2, 1}, + {0, 0, 1, 2, 1}, {1, 0, 1, 2, 1}, {2, 0, 1, 2, 1}, {0, 1, 2, 2, 1}, + {0, 1, 1, 2, 1}, {1, 1, 1, 2, 1}, {2, 1, 1, 2, 1}, {1, 1, 2, 2, 1}, + {0, 2, 1, 2, 1}, {1, 2, 1, 2, 1}, {2, 2, 1, 2, 1}, {2, 1, 2, 2, 1}, + {0, 2, 1, 2, 2}, {1, 2, 1, 2, 2}, {2, 2, 1, 2, 2}, {2, 1, 2, 2, 2}, + {0, 0, 0, 1, 2}, {1, 0, 0, 1, 2}, {2, 0, 0, 1, 2}, {0, 0, 2, 1, 2}, + {0, 1, 0, 1, 2}, {1, 1, 0, 1, 2}, {2, 1, 0, 1, 2}, {1, 0, 2, 1, 2}, + {0, 2, 0, 1, 2}, {1, 2, 0, 1, 2}, {2, 2, 0, 1, 2}, {2, 0, 2, 1, 2}, + {0, 2, 2, 1, 2}, {1, 2, 2, 1, 2}, {2, 2, 2, 1, 2}, {2, 0, 2, 1, 2}, + {0, 0, 1, 1, 2}, {1, 0, 1, 1, 2}, {2, 0, 1, 1, 2}, {0, 1, 2, 1, 2}, + {0, 1, 1, 1, 2}, {1, 1, 1, 1, 2}, {2, 1, 1, 1, 2}, {1, 1, 2, 1, 2}, + {0, 2, 1, 1, 2}, {1, 2, 1, 1, 2}, {2, 2, 1, 1, 2}, {2, 1, 2, 1, 2}, + {0, 2, 2, 2, 2}, {1, 2, 2, 2, 2}, {2, 2, 2, 2, 2}, {2, 1, 2, 2, 2} + }; + const int QuintsOfInteger[128][3] = + { + {0, 0, 0}, {1, 0, 0}, {2, 0, 0}, {3, 0, 0}, + {4, 0, 0}, {0, 4, 0}, {4, 4, 0}, {4, 4, 4}, + {0, 1, 0}, {1, 1, 0}, {2, 1, 0}, {3, 1, 0}, + {4, 1, 0}, {1, 4, 0}, {4, 4, 1}, {4, 4, 4}, + {0, 2, 0}, {1, 2, 0}, {2, 2, 0}, {3, 2, 0}, + {4, 2, 0}, {2, 4, 0}, {4, 4, 2}, {4, 4, 4}, + {0, 3, 0}, {1, 3, 0}, {2, 3, 0}, {3, 3, 0}, + {4, 3, 0}, {3, 4, 0}, {4, 4, 3}, {4, 4, 4}, + {0, 0, 1}, {1, 0, 1}, {2, 0, 1}, {3, 0, 1}, + {4, 0, 1}, {0, 4, 1}, {4, 0, 4}, {0, 4, 4}, + {0, 1, 1}, {1, 1, 1}, {2, 1, 1}, {3, 1, 1}, + {4, 1, 1}, {1, 4, 1}, {4, 1, 4}, {1, 4, 4}, + {0, 2, 1}, {1, 2, 1}, {2, 2, 1}, {3, 2, 1}, + {4, 2, 1}, {2, 4, 1}, {4, 2, 4}, {2, 4, 4}, + {0, 3, 1}, {1, 3, 1}, {2, 3, 1}, {3, 3, 1}, + {4, 3, 1}, {3, 4, 1}, {4, 3, 4}, {3, 4, 4}, + {0, 0, 2}, {1, 0, 2}, {2, 0, 2}, {3, 0, 2}, + {4, 0, 2}, {0, 4, 2}, {2, 0, 4}, {3, 0, 4}, + {0, 1, 2}, {1, 1, 2}, {2, 1, 2}, {3, 1, 2}, + {4, 1, 2}, {1, 4, 2}, {2, 1, 4}, {3, 1, 4}, + {0, 2, 2}, {1, 2, 2}, {2, 2, 2}, {3, 2, 2}, + {4, 2, 2}, {2, 4, 2}, {2, 2, 4}, {3, 2, 4}, + {0, 3, 2}, {1, 3, 2}, {2, 3, 2}, {3, 3, 2}, + {4, 3, 2}, {3, 4, 2}, {2, 3, 4}, {3, 3, 4}, + {0, 0, 3}, {1, 0, 3}, {2, 0, 3}, {3, 0, 3}, + {4, 0, 3}, {0, 4, 3}, {0, 0, 4}, {1, 0, 4}, + {0, 1, 3}, {1, 1, 3}, {2, 1, 3}, {3, 1, 3}, + {4, 1, 3}, {1, 4, 3}, {0, 1, 4}, {1, 1, 4}, + {0, 2, 3}, {1, 2, 3}, {2, 2, 3}, {3, 2, 3}, + {4, 2, 3}, {2, 4, 3}, {0, 2, 4}, {1, 2, 4}, + {0, 3, 3}, {1, 3, 3}, {2, 3, 3}, {3, 3, 3}, + {4, 3, 3}, {3, 4, 3}, {0, 3, 4}, {1, 3, 4} + }; +}; + +struct ColorQuantizationModeInfo +{ + const uint32 ColorUnquantizationTables[1206] = + { + + 0, 255 //2 + , + 0, 128, 255 //3 + + , + 0, 85, 170, 255 //4 + + , + 0, 64, 128, 192, 255 //5 + + , + 0, 255, 51, 204, 102, 153 //6 + + , + 0, 36, 73, 109, 146, 182, 219, 255 //8 + + , + 0, 255, 28, 227, 56, 199, 84, 171, 113, 142 //10 + + , + 0, 255, 69, 186, 23, 232, 92, 163, 46, 209, 116, 139 //12 + + , + 0, 17, 34, 51, 68, 85, 102, 119, 136, 153, 170, 187, 204, 221, 238, 255 //16 + + , + 0, 255, 67, 188, 13, 242, 80, 175, 27, 228, 94, 161, 40, 215, 107, 148, //20 + 54, 201, 121, 134 + + , + 0, 255, 33, 222, 66, 189, 99, 156, 11, 244, 44, 211, 77, 178, 110, 145, //24 + 22, 233, 55, 200, 88, 167, 121, 134 + + , + 0, 8, 16, 24, 33, 41, 49, 57, 66, 74, 82, 90, 99, 107, 115, 123, + 132, 140, 148, 156, 165, 173, 181, 189, 198, 206, 214, 222, 231, 239, 247, 255 //32 + + , + 0, 255, 32, 223, 65, 190, 97, 158, 6, 249, 39, 216, 71, 184, 104, 151, + 13, 242, 45, 210, 78, 177, 110, 145, 19, 236, 52, 203, 84, 171, 117, 138, //40 + 26, 229, 58, 197, 91, 164, 123, 132 + + , + 0, 255, 16, 239, 32, 223, 48, 207, 65, 190, 81, 174, 97, 158, 113, 142, + 5, 250, 21, 234, 38, 217, 54, 201, 70, 185, 86, 169, 103, 152, 119, 136, //48 + 11, 244, 27, 228, 43, 212, 59, 196, 76, 179, 92, 163, 108, 147, 124, 131 + + , + 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40, 44, 48, 52, 56, 60, + 65, 69, 73, 77, 81, 85, 89, 93, 97, 101, 105, 109, 113, 117, 121, 125, //64 + 130, 134, 138, 142, 146, 150, 154, 158, 162, 166, 170, 174, 178, 182, 186, 190, + 195, 199, 203, 207, 211, 215, 219, 223, 227, 231, 235, 239, 243, 247, 251, 255 + + , + 0, 255, 16, 239, 32, 223, 48, 207, 64, 191, 80, 175, 96, 159, 112, 143, //80 + 3, 252, 19, 236, 35, 220, 51, 204, 67, 188, 83, 172, 100, 155, 116, 139, + 6, 249, 22, 233, 38, 217, 54, 201, 71, 184, 87, 168, 103, 152, 119, 136, + 9, 246, 25, 230, 42, 213, 58, 197, 74, 181, 90, 165, 106, 149, 122, 133, + 13, 242, 29, 226, 45, 210, 61, 194, 77, 178, 93, 162, 109, 146, 125, 130 + + , + 0, 255, 8, 247, 16, 239, 24, 231, 32, 223, 40, 215, 48, 207, 56, 199, //96 + 64, 191, 72, 183, 80, 175, 88, 167, 96, 159, 104, 151, 112, 143, 120, 135, + 2, 253, 10, 245, 18, 237, 26, 229, 35, 220, 43, 212, 51, 204, 59, 196, + 67, 188, 75, 180, 83, 172, 91, 164, 99, 156, 107, 148, 115, 140, 123, 132, + 5, 250, 13, 242, 21, 234, 29, 226, 37, 218, 45, 210, 53, 202, 61, 194, + 70, 185, 78, 177, 86, 169, 94, 161, 102, 153, 110, 145, 118, 137, 126, 129 + + , + 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, //128 + 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60, 62, + 64, 66, 68, 70, 72, 74, 76, 78, 80, 82, 84, 86, 88, 90, 92, 94, + 96, 98, 100, 102, 104, 106, 108, 110, 112, 114, 116, 118, 120, 122, 124, 126, + 129, 131, 133, 135, 137, 139, 141, 143, 145, 147, 149, 151, 153, 155, 157, 159, + 161, 163, 165, 167, 169, 171, 173, 175, 177, 179, 181, 183, 185, 187, 189, 191, + 193, 195, 197, 199, 201, 203, 205, 207, 209, 211, 213, 215, 217, 219, 221, 223, + 225, 227, 229, 231, 233, 235, 237, 239, 241, 243, 245, 247, 249, 251, 253, 255 + + , + 0, 255, 8, 247, 16, 239, 24, 231, 32, 223, 40, 215, 48, 207, 56, 199, //160 + 64, 191, 72, 183, 80, 175, 88, 167, 96, 159, 104, 151, 112, 143, 120, 135, + 1, 254, 9, 246, 17, 238, 25, 230, 33, 222, 41, 214, 49, 206, 57, 198, + 65, 190, 73, 182, 81, 174, 89, 166, 97, 158, 105, 150, 113, 142, 121, 134, + 3, 252, 11, 244, 19, 236, 27, 228, 35, 220, 43, 212, 51, 204, 59, 196, + 67, 188, 75, 180, 83, 172, 91, 164, 99, 156, 107, 148, 115, 140, 123, 132, + 4, 251, 12, 243, 20, 235, 28, 227, 36, 219, 44, 211, 52, 203, 60, 195, + 68, 187, 76, 179, 84, 171, 92, 163, 100, 155, 108, 147, 116, 139, 124, 131, + 6, 249, 14, 241, 22, 233, 30, 225, 38, 217, 46, 209, 54, 201, 62, 193, + 70, 185, 78, 177, 86, 169, 94, 161, 102, 153, 110, 145, 118, 137, 126, 129 + + , + 0, 255, 4, 251, 8, 247, 12, 243, 16, 239, 20, 235, 24, 231, 28, 227, //192 + 32, 223, 36, 219, 40, 215, 44, 211, 48, 207, 52, 203, 56, 199, 60, 195, + 64, 191, 68, 187, 72, 183, 76, 179, 80, 175, 84, 171, 88, 167, 92, 163, + 96, 159, 100, 155, 104, 151, 108, 147, 112, 143, 116, 139, 120, 135, 124, 131, + 1, 254, 5, 250, 9, 246, 13, 242, 17, 238, 21, 234, 25, 230, 29, 226, + 33, 222, 37, 218, 41, 214, 45, 210, 49, 206, 53, 202, 57, 198, 61, 194, + 65, 190, 69, 186, 73, 182, 77, 178, 81, 174, 85, 170, 89, 166, 93, 162, + 97, 158, 101, 154, 105, 150, 109, 146, 113, 142, 117, 138, 121, 134, 125, 130, + 2, 253, 6, 249, 10, 245, 14, 241, 18, 237, 22, 233, 26, 229, 30, 225, + 34, 221, 38, 217, 42, 213, 46, 209, 50, 205, 54, 201, 58, 197, 62, 193, + 66, 189, 70, 185, 74, 181, 78, 177, 82, 173, 86, 169, 90, 165, 94, 161, + 98, 157, 102, 153, 106, 149, 110, 145, 114, 141, 118, 137, 122, 133, 126, 129 + + , //256 + 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, + 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, + 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, + 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, + 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, + 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, + 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, + 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, + 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, + 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, 175, + 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, 190, 191, + 192, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 207, + 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, + 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, + 240, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, 251, 252, 253, 254, 255, + + }; + const int QuantizationModeTable[2176] = + { + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + -1, -1, 0, 0, 2, 3, 5, 6, 8, 9, 11, 12, 14, 15, 17, 18, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, 0, 0, 0, 1, 2, 2, 3, 4, 5, 5, 6, 7, 8, 8, 9, 10, 11, 11, 12, 13, 14, 14, 15, 16, 17, 17, 18, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 14, 14, 15, 15, 16, 16, 17, 17, 18, 18, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 7, 7, 7, 8, 8, 8, 9, 9, 10, 10, 10, 11, 11, 11, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 16, 16, 16, 17, 17, 17, 18, 18, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 9, 9, 10, 10, 10, 10, 11, 11, 11, 11, 12, 12, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 14, 14, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 19, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, 20, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 17, 17, 18, 18, 18, 18, 19, 19, 19, 19, 19, 19, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 17, 17, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 15, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, + }; +}; + +const int QuantAndXferTables[142] = +{ + 0, 64, + 0, 32, 64, + 0, 21, 43, 64, + 0, 16, 32, 48, 64, + 0, 64, 12, 52, 25, 39, + 0, 9, 18, 27, 37, 46, 55, 64, + 0, 64, 7, 57, 14, 50, 21, 43, 28, 36, + 0, 64, 17, 47, 5, 59, 23, 41, 11, 53, 28, 36, + 0, 4, 8, 12, 17, 21, 25, 29, 35, 39, 43, 47, 52, 56, 60, 64, + 0, 64, 16, 48, 3, 61, 19, 45, 6, 58, 23, 41, 9, 55, 26, 38, 13, 51, 29, 35, + 0, 64, 8, 56, 16, 48, 24, 40, 2, 62, 11, 53, 19, 45, 27, 37, 5, 59, 13, 51, 22, 42, 30, 34, + 0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60, 62, 64, +}; + +static const ColorQuantizationModeInfo g_ColorQuantizationInfo; +static const TritsQuintsTable g_TritsQuintsTbl; + +// ===================================================================================================================== +static void GetSpvCode( + InternalTexConvertCsType type, + const void** pCode, + uint32* pSize) +{ + if (type == InternalTexConvertCsType::ConvertASTCToRGBA8) + { + *pCode = AstcDecoder; + *pSize = sizeof(AstcDecoder); + } + else + { + // TODO: Etc code + } + +} + +// ===================================================================================================================== +Device::Device() + : + m_info({}), + m_pTableMemory(nullptr), + m_pPalCmdBuffer (nullptr) +{ +} + +// ===================================================================================================================== +Device::~Device() +{ + if (m_pTableMemory != nullptr) + { + m_info.pPalDevice->RemoveGpuMemoryReferences(1, &m_pTableMemory, nullptr); + m_pTableMemory->Destroy(); + PAL_SAFE_FREE(m_pTableMemory, m_info.pPlatform); + } +} + +// ===================================================================================================================== +void Device::Init( + const DeviceInitInfo& info) +{ + m_info = info; + m_imageViewSizeInDwords = m_info.pDeviceProperties->gfxipProperties.srdSizes.imageView / sizeof(uint32); + m_bufferViewSizeInDwords = m_info.pDeviceProperties->gfxipProperties.srdSizes.bufferView / sizeof(uint32); + + // 3 Table and 1 TexBuffer, and 2 Image resource. + m_srdDwords = (3 + 1) * m_bufferViewSizeInDwords + 2 * m_imageViewSizeInDwords; +} + +// ===================================================================================================================== +Pal::Result Device::GpuDecodeImage( + InternalTexConvertCsType type, + Pal::ICmdBuffer* pCmdBuffer, + const Pal::IImage* pSrcImage, + const Pal::IImage* pDstImage, + uint32 regionCount, + Pal::ImageCopyRegion* pPalImageRegions, + const CompileTimeConstants& constInfo) +{ + m_pPalCmdBuffer = pCmdBuffer; + m_pPalCmdBuffer->CmdSaveComputeState(Pal::ComputeStateAll); + + if (type == InternalTexConvertCsType::ConvertASTCToRGBA8) + { + uint32* pUserData = nullptr; + CreateAstcUserData(InternalTexConvertCsType::ConvertASTCToRGBA8, &pUserData, m_srdDwords); + BindPipeline(type, constInfo); + + // Image To Image + if (pSrcImage != nullptr) + { + uint32 astcX = pSrcImage->GetImageCreateInfo().extent.width; + uint32 astcY = pSrcImage->GetImageCreateInfo().extent.height; + // Skip the texture buffer view + pUserData += 4; + for (uint32 idx = 0; idx < regionCount; ++idx) + { + Pal::ImageCopyRegion copyRegion = pPalImageRegions[idx]; + uint32 mips = copyRegion.srcSubres.mipLevel; + Pal::SubresId palSrcSubResId = copyRegion.srcSubres; + Pal::SubresId palDstSubResId = copyRegion.dstSubres; + + Pal::SwizzledFormat dstFormat = pDstImage->GetImageCreateInfo().swizzledFormat; + Pal::SwizzledFormat srcFormat = pSrcImage->GetImageCreateInfo().swizzledFormat; + + Pal::ImageViewInfo imageView[2] = {}; + + BuildImageViewInfo(&imageView[0], pDstImage, palDstSubResId, dstFormat, true); + BuildImageViewInfo(&imageView[1], pSrcImage, palSrcSubResId, srcFormat, false); + + m_info.pPalDevice->CreateImageViewSrds(2, imageView, pUserData); + + uint32 threadGroupsX = (astcX >> mips > 1) ? (astcX >> mips) : 1; + uint32 threadGroupsY = (astcY >> mips > 1) ? (astcY >> mips) : 1; + uint32 threadGroupsZ = 1; + + m_pPalCmdBuffer->CmdDispatch(threadGroupsX, threadGroupsY, threadGroupsZ); + } + } + } + else // for ETC Decode + { + // TODO: ETC2 Decode + } + + return Pal::Result::Success; +} + +// ===================================================================================================================== +Pal::Result Device::GpuDecodeBuffer( + InternalTexConvertCsType type, + Pal::ICmdBuffer* pCmdBuffer, + const Pal::IGpuMemory* pSrcBufferMem, + Pal::IImage* pDstImage, + uint32 regionCount, + Pal::MemoryImageCopyRegion* pPalBufferRegionsIn, + const CompileTimeConstants& constInfo) +{ + m_pPalCmdBuffer = pCmdBuffer; + m_pPalCmdBuffer->CmdSaveComputeState(Pal::ComputeStateAll); + + if (type == InternalTexConvertCsType::ConvertASTCToRGBA8) + { + uint32* pUserData = nullptr; + CreateAstcUserData(InternalTexConvertCsType::ConvertASTCToRGBA8, &pUserData, m_srdDwords); + BindPipeline(type, constInfo); + + // Buffer To Image + if (pSrcBufferMem != nullptr) + { + // TODO: Copy Buffer To Image + for (size_t i = 0; i < regionCount; i++) + { + + } + } + } + else // for ETC Decode + { + // TODO: ETC2 Decode + } + return Pal::Result::Success; +} + +// ===================================================================================================================== +void Device::CreateAstcUserData( + InternalTexConvertCsType type, + uint32** ppUserData, + uint32 srdDwords) +{ + *ppUserData = CreateAndBindEmbeddedUserData(m_pPalCmdBuffer, srdDwords, 0, 1); + memset(*ppUserData, 0, srdDwords * sizeof(uint32)); + + if (m_pTableMemory == nullptr) + { + CreateTableMemory(); + } + SetupInternalTables(type, ppUserData); +} + +// ===================================================================================================================== +void Device::BindPipeline( + InternalTexConvertCsType type, + const CompileTimeConstants& constInfo) +{ + const Pal::IPipeline* pPipeline = GetInternalPipeline(type, constInfo); + + Pal::PipelineBindParams bindParam = {}; + bindParam.pipelineBindPoint = Pal::PipelineBindPoint::Compute; + bindParam.pPipeline = pPipeline; + bindParam.apiPsoHash = Pal::InternalApiPsoHash; + + m_pPalCmdBuffer->CmdBindPipeline(bindParam); +} + +// ===================================================================================================================== +Pal::Result Device::CreateGpuMemory( + Pal::GpuMemoryRequirements* pMemReqs, + Pal::IGpuMemory** ppGpuMemory, + Pal::gpusize* pOffset) +{ + Pal::GpuMemoryCreateInfo createInfo = {}; + createInfo.size = pMemReqs->size; + createInfo.alignment = pMemReqs->alignment; + createInfo.vaRange = Pal::VaRange::Default; + createInfo.priority = Pal::GpuMemPriority::VeryLow; + createInfo.heapCount = pMemReqs->heapCount; + + for (uint32 i = 0; i < createInfo.heapCount; i++) + { + createInfo.heaps[i] = pMemReqs->heaps[i]; + } + + Pal::Result result = Pal::Result::Success; + const size_t objectSize = m_info.pPalDevice->GetGpuMemorySize(createInfo, &result); + + if (result == Pal::Result::Success) + { + void* pMemory = PAL_MALLOC(objectSize, m_info.pPlatform, Util::SystemAllocType::AllocInternal); + if (pMemory != nullptr) + { + result = m_info.pPalDevice->CreateGpuMemory(createInfo, pMemory, reinterpret_cast(ppGpuMemory)); + if (result != Pal::Result::Success) + { + PAL_SAFE_FREE(pMemory, m_info.pPlatform); + } + } + else + { + result = Pal::Result::ErrorOutOfMemory; + } + } + return result; +} + +// ===================================================================================================================== +void Device::CreateMemoryReqs( + uint32 bytesSize, + uint32 alignment, + Pal::GpuMemoryRequirements* pMemReqs) +{ + pMemReqs->size = bytesSize; + pMemReqs->alignment = alignment; + pMemReqs->heapCount = 2; + pMemReqs->heaps[0] = Pal::GpuHeapLocal; + pMemReqs->heaps[1] = Pal::GpuHeapGartUswc; +} + +// ===================================================================================================================== +uint32* Device::CreateAndBindEmbeddedUserData( + Pal::ICmdBuffer* pCmdBuffer, + uint32 sizeInDwords, + uint32 entryToBind, + uint32 bindNum) const +{ + Pal::gpusize gpuVirtAddr = 0; + uint32* const pCmdSpace = pCmdBuffer->CmdAllocateEmbeddedData(sizeInDwords, 8, &gpuVirtAddr); + PAL_ASSERT(pCmdSpace != nullptr); + + const uint32 gpuVirtAddrLo = Util::LowPart(gpuVirtAddr); + pCmdBuffer->CmdSetUserData(Pal::PipelineBindPoint::Compute, entryToBind, bindNum, &gpuVirtAddrLo); + + return pCmdSpace; +} + +// ===================================================================================================================== +Pal::IPipeline* Device::GetInternalPipeline( + InternalTexConvertCsType type, + const CompileTimeConstants& constInfo) const +{ + Pal::IPipeline* pPipeline = nullptr; + void* pMemory = nullptr; + PipelineBuildInfo buildInfo = {}; + GpuDecodeMappingNode astcResourceNodes[AstcInternalPipelineNodes]; + + if (type == InternalTexConvertCsType::ConvertASTCToRGBA8) + { + uint32 offset = 0; + buildInfo.nodeCount = 1; + + // 1.Color UnQuantization Buffer View + astcResourceNodes[0].nodeType = NodeType::Buffer; + astcResourceNodes[0].sizeInDwords = m_bufferViewSizeInDwords; + astcResourceNodes[0].offsetInDwords = 0; + astcResourceNodes[0].binding = 0; + astcResourceNodes[0].set = 0; + + // 2.Trits Quints Buffer View + astcResourceNodes[1].nodeType = NodeType::Buffer; + astcResourceNodes[1].sizeInDwords = m_bufferViewSizeInDwords; + astcResourceNodes[1].offsetInDwords = 1 * m_bufferViewSizeInDwords; + astcResourceNodes[1].binding = 1; + astcResourceNodes[1].set = 0; + + // 3.Quant and Transfer Buffer View + astcResourceNodes[2].nodeType = NodeType::Buffer; + astcResourceNodes[2].sizeInDwords = m_bufferViewSizeInDwords; + astcResourceNodes[2].offsetInDwords = 2 * m_bufferViewSizeInDwords; + astcResourceNodes[2].binding = 2; + astcResourceNodes[2].set = 0; + + // 4. TexBuffer View for Src Image Buffer + astcResourceNodes[3].nodeType = NodeType::TexBuffer; + astcResourceNodes[3].sizeInDwords = m_bufferViewSizeInDwords; + astcResourceNodes[3].offsetInDwords = 3 * m_bufferViewSizeInDwords; + astcResourceNodes[3].binding = 3; + astcResourceNodes[3].set = 0; + + // 5. Image View for Src Image + astcResourceNodes[4].nodeType = NodeType::Image; + astcResourceNodes[4].sizeInDwords = m_imageViewSizeInDwords; + astcResourceNodes[4].offsetInDwords = 4 * m_bufferViewSizeInDwords; + astcResourceNodes[4].binding = 4; + astcResourceNodes[4].set = 0; + + // 6. Image View for Dst Image + astcResourceNodes[5].nodeType = NodeType::Image; + astcResourceNodes[5].sizeInDwords = m_imageViewSizeInDwords; + astcResourceNodes[5].offsetInDwords = 4 * m_bufferViewSizeInDwords + m_imageViewSizeInDwords; + astcResourceNodes[5].binding = 5; + astcResourceNodes[5].set = 0; + + buildInfo.pUserDataNodes = astcResourceNodes; + buildInfo.shaderType = InternalTexConvertCsType::ConvertASTCToRGBA8; + GetSpvCode(buildInfo.shaderType, &(buildInfo.code.pSpvCode), &(buildInfo.code.spvSize)); + } + + ClientCreateInternalComputePipeline(m_info, constInfo, buildInfo, &pPipeline, &pMemory); + return pPipeline; +} + +// ===================================================================================================================== +void Device::BuildBufferViewInfo( + uint32* pData, + uint8 count, + Pal::gpusize addr, + Pal::gpusize dataBytes, + uint8 stride, + Pal::SwizzledFormat swizzleFormat) const +{ + Pal::BufferViewInfo tableDataView = {}; + tableDataView.gpuAddr = addr; + tableDataView.range = dataBytes; + tableDataView.stride = stride; + tableDataView.swizzledFormat = swizzleFormat; + + m_info.pPalDevice->CreateUntypedBufferViewSrds(count, &tableDataView, pData); +} + +// ===================================================================================================================== +void Device::BuildImageViewInfo( + Pal::ImageViewInfo* pInfo, + const Pal::IImage* pImage, + const Pal::SubresId& subresId, + Pal::SwizzledFormat swizzledFormat, + bool isShaderWriteable) const +{ + const Pal::ImageType imageType = pImage->GetImageCreateInfo().imageType; + + pInfo->pImage = pImage; + pInfo->viewType = static_cast(imageType); + pInfo->subresRange.startSubres = subresId; +#if PAL_CLIENT_INTERFACE_MAJOR_VERSION >= 642 + pInfo->subresRange.numPlanes = 1; +#endif + pInfo->subresRange.numMips = 1; + pInfo->subresRange.numSlices = 1; + pInfo->swizzledFormat = swizzledFormat; + + // ASTC/ETC only uses compute shaders, where the write-out surface is assumed to be write-only. + pInfo->possibleLayouts = { (isShaderWriteable ? Pal::LayoutShaderWrite : Pal::LayoutShaderRead), + Pal::EngineTypeUniversal | Pal::EngineTypeCompute }; + +} + +// ===================================================================================================================== +Pal::Result Device::CreateTableMemory() +{ + Pal::Result result = Pal::Result::Success; + uint32 colorUnquantiSize = sizeof(ColorQuantizationModeInfo); + uint32 triSize = sizeof(TritsQuintsTable); + uint32 quantiModesize = sizeof(QuantAndXferTables); + uint32 totalSize = colorUnquantiSize + triSize + quantiModesize; + + // Create gpu memory for all table + Pal::GpuMemoryRequirements memReqs = {}; + CreateMemoryReqs(totalSize, sizeof(uint32), &memReqs); + Pal::GpuMemoryRef memRef; + + Pal::gpusize offset = 0; + uint8* pData = nullptr; + result = CreateGpuMemory(&memReqs, &m_pTableMemory, &offset); + + if (result == Pal::Result::Success) + { + memRef.pGpuMemory = m_pTableMemory; + result = m_info.pPalDevice->AddGpuMemoryReferences(1, &memRef, nullptr, Pal::GpuMemoryRefCantTrim); + } + + if (result == Pal::Result::Success) + { + result = m_pTableMemory->Map(reinterpret_cast(&pData)); + } + + if ((result == Pal::Result::Success) && (pData != nullptr)) + { + // 1.Color UnQuantization Buffer View + memcpy(pData, &g_ColorQuantizationInfo, colorUnquantiSize); + offset += colorUnquantiSize; + + // 2.Trits Quints Buffer View + memcpy(pData + offset, &g_TritsQuintsTbl, triSize); + offset += triSize; + + // 3.Quant and Transfer Buffer View + memcpy(pData + offset, &QuantAndXferTables, quantiModesize); + } + + if (result == Pal::Result::Success) + { + m_pTableMemory->Unmap(); + } + + return result; +} + +// ===================================================================================================================== +Pal::Result Device::SetupInternalTables( + InternalTexConvertCsType type, + uint32** ppUserData) +{ + // Only Astc need table data + Pal::Result result = Pal::Result::Success; + + if (type == InternalTexConvertCsType::ConvertASTCToRGBA8) + { + if (result == Pal::Result::Success) + { + uint32 offset = 0; + uint32 colorUnquantiSize = sizeof(ColorQuantizationModeInfo); + uint32 triSize = sizeof(TritsQuintsTable); + uint32 quantiModesize = sizeof(QuantAndXferTables); + + // 1.Color UnQuantization + BuildBufferViewInfo(*ppUserData, 1, m_pTableMemory->Desc().gpuVirtAddr, colorUnquantiSize, 1, Pal::UndefinedSwizzledFormat); + offset += colorUnquantiSize; + *ppUserData += m_bufferViewSizeInDwords; + + // 2.Trits Quints + BuildBufferViewInfo(*ppUserData, 1, m_pTableMemory->Desc().gpuVirtAddr + offset, triSize, 1, Pal::UndefinedSwizzledFormat); + offset += triSize; + *ppUserData += m_bufferViewSizeInDwords; + + // 3.Quant and Transfer + BuildBufferViewInfo(*ppUserData, 1, m_pTableMemory->Desc().gpuVirtAddr + offset, quantiModesize, 1, Pal::UndefinedSwizzledFormat); + *ppUserData += m_bufferViewSizeInDwords; + } + } + return result; +} + +} diff --git a/icd/imported/gputexdecoder/gpuTexDecoder.h b/icd/imported/gputexdecoder/gpuTexDecoder.h new file mode 100755 index 00000000..5e21913d --- /dev/null +++ b/icd/imported/gputexdecoder/gpuTexDecoder.h @@ -0,0 +1,222 @@ +/* + *********************************************************************************************************************** + * + * Copyright (c) 2021 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"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + **********************************************************************************************************************/ +/** + *********************************************************************************************************************** + * @file gpuTexDecoder.h + * @brief Contains declaration of gpuTexDecoder classes. + *********************************************************************************************************************** + */ +#pragma once +#include "pal.h" +#include "palSysMemory.h" +#include "palGpuMemory.h" +#include "palDevice.h" +#include "palPipeline.h" +#include "palMutex.h" +#include "palCmdBuffer.h" +#include "palPlatform.h" + +namespace Pal +{ +class IDevice; +class IPipeline; +class ICmdBuffer; +class IPlatform; +struct DeviceProperties; +}; + +namespace GpuTexDecoder +{ +using Pal::uint8; +using Pal::uint16; +using Pal::uint32; +using Pal::uint64; + +constexpr uint32 AstcInternalPipelineNodes = 6; + +// Enum for internal texture format convert type +enum class InternalTexConvertCsType : uint32 +{ + ConvertASTCToRGBA8, + ConvertETC2ToRGBA8, + Count +}; + +// Information to initialize a gpuTexDecoder device +struct DeviceInitInfo +{ + uint32 gpuIdx; // Client GPU index associated with this gpurt device + void* pClientUserData; // User data pointer passed to internal pipeline create/destroy callbacks + Pal::IDevice* pPalDevice; + Pal::IPlatform* pPlatform; + const Pal::DeviceProperties* pDeviceProperties; // Pointer to host PAL device properties + // (this pointer is retained). +}; + +struct CompileTimeConstants +{ + const uint32* pConstants; + uint32 numConstants; +}; + +struct PipelineShaderCode +{ + const void* pSpvCode; // Code in SPIR-V form + uint32 spvSize; // Size in bytes of SPIR-V code +}; + +enum class NodeType : uint32 +{ + Buffer, + TexBuffer, + Image, + Count +}; + +struct GpuDecodeMappingNode +{ + NodeType nodeType; + uint32 binding; + uint32 set; + uint32 offsetInDwords; + uint32 sizeInDwords; +}; + +struct PipelineBuildInfo +{ + GpuDecodeMappingNode* pUserDataNodes; + uint32 nodeCount; + PipelineShaderCode code; + InternalTexConvertCsType shaderType; +}; + +// Client-provided callback to build an internal compute pipeline. This is called by gpuTexDecoder during initialization +// of a gpuTexDecoder device. +// +// The client must implement this function to successfully initialize gpuTexDecoder. +// +// @param initInfo [in] Information about the host device +// @param ppResultPipeline [out] Result PAL pipeline object pointer +// @param ppResultMemory [out] Result PAL pipeline memory if different from pipeline pointer. Optional. +// +// @returns Compilation success result. +extern Pal::Result ClientCreateInternalComputePipeline( + const DeviceInitInfo& initInfo, // Information about the host device + const CompileTimeConstants& constInfo, // CompileTime Specialization params + const PipelineBuildInfo& buildInfo, // Pipeline Layout, shader code.. + Pal::IPipeline** ppResultPipeline, // Result PAL pipeline object pointer + void** ppResultMemory); // (Optional) Result PAL pipeline memory, if different from obj + +// ===================================================================================================================== +// GPUTEXDECODER device +// +class Device +{ +public: + Device(); + ~Device(); + + // Initializes the device + // + // @param info [in] Information required to initialize the device + void Init(const DeviceInitInfo& info); + + Pal::Result GpuDecodeImage( + InternalTexConvertCsType type, + Pal::ICmdBuffer* pCmdBuffer, + const Pal::IImage* pSrcImage, + const Pal::IImage* pDstImage, + uint32 regionCount, + Pal::ImageCopyRegion* pPalImageRegions, + const CompileTimeConstants& constInfo); + + Pal::Result GpuDecodeBuffer( + InternalTexConvertCsType type, + Pal::ICmdBuffer* pCmdBuffer, + const Pal::IGpuMemory* pSrcBufferMem, + Pal::IImage* pDstImage, + uint32 regionCount, + Pal::MemoryImageCopyRegion* pPalBufferRegionsIn, + const CompileTimeConstants& constInfo); + +private: + void CreateAstcUserData( + InternalTexConvertCsType type, + uint32** ppUserData, + uint32 srdDwords); + + void BindPipeline( + InternalTexConvertCsType type, + const CompileTimeConstants& constInfo); + + Pal::Result CreateTableMemory(); + + Pal::Result SetupInternalTables( + InternalTexConvertCsType type, + uint32** ppUserData); + + Pal::Result CreateGpuMemory( + Pal::GpuMemoryRequirements* pMemReqs, + Pal::IGpuMemory** ppGpuMemory, + Pal::gpusize* pOffset); + + void CreateMemoryReqs( + uint32 bytesSize, + uint32 alignment, + Pal::GpuMemoryRequirements* pMemReqs); + + uint32* CreateAndBindEmbeddedUserData( + Pal::ICmdBuffer* pCmdBuffer, + uint32 sizeInDwords, + uint32 entryToBind, + uint32 bindNum) const; + + void BuildBufferViewInfo( + uint32* pData, + uint8 count, + Pal::gpusize addr, + Pal::gpusize dataBytes, + uint8 stride, + Pal::SwizzledFormat swizzleFormat) const; + + void BuildImageViewInfo( + Pal::ImageViewInfo* pInfo, + const Pal::IImage* pImage, + const Pal::SubresId& subresId, + Pal::SwizzledFormat swizzledFormat, + bool isShaderWriteable) const; + + Pal::IPipeline* GetInternalPipeline( + InternalTexConvertCsType type, + const CompileTimeConstants& constInfo) const; + + DeviceInitInfo m_info; + Pal::IGpuMemory* m_pTableMemory; + Pal::ICmdBuffer* m_pPalCmdBuffer; // The associated PAL cmdbuffer + uint32 m_bufferViewSizeInDwords{0}; + uint32 m_imageViewSizeInDwords{0}; + uint32 m_srdDwords; +}; +} diff --git a/icd/imported/gputexdecoder/shaders.h b/icd/imported/gputexdecoder/shaders.h new file mode 100644 index 00000000..e91f815a --- /dev/null +++ b/icd/imported/gputexdecoder/shaders.h @@ -0,0 +1,25 @@ +/* + *********************************************************************************************************************** + * + * Copyright (c) 2021 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"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + **********************************************************************************************************************/ +#include "shaders/AstcDecode.h" diff --git a/icd/imported/gputexdecoder/shaders/AstcDecode.comp b/icd/imported/gputexdecoder/shaders/AstcDecode.comp new file mode 100644 index 00000000..0859ffa1 --- /dev/null +++ b/icd/imported/gputexdecoder/shaders/AstcDecode.comp @@ -0,0 +1,1118 @@ +/* Copyright (c) 2021 Advanced Micro Devices, Inc. All rights reserved.*/ + +// This ASTC Decode Algorithm is impelmented according to the spec: +// https://www.khronos.org/registry/DataFormat/specs/1.3/dataformat.1.3.html#ASTC +// This impelmention generate many ALU Ops instead of Memory lookup table. +//# If you have any question, feel free to contact yuhachen@amd.com + +#version 450 +#extension GL_EXT_scalar_block_layout : enable +#extension GL_EXT_samplerless_texture_functions : enable + +// color Format +#define FMT_LUMINANCE 0 +#define FMT_LUMINANCE_DELTA 1 +#define FMT_HDR_LUMINANCE_LARGE_RANGE 2 +#define FMT_HDR_LUMINANCE_SMALL_RANGE 3 +#define FMT_LUMINANCE_ALPHA 4 +#define FMT_LUMINANCE_ALPHA_DELTA 5 +#define FMT_RGB_SCALE 6 +#define FMT_HDR_RGB_SCALE 7 +#define FMT_RGB 8 +#define FMT_RGB_DELTA 9 +#define FMT_RGB_SCALE_ALPHA 10 +#define FMT_HDR_RGB 11 +#define FMT_RGBA 12 +#define FMT_RGBA_DELTA 13 +#define FMT_HDR_RGB_LDR_ALPHA 14 +#define FMT_HDR_RGBA 15 + + +// Block Define +#define PARTITION_IDX_BITS 10 +#define PARTITION_CNT_BITS 2 +#define PARTITION_START_BITS 13 +#define CEM_BITS_COUNT 6 +#define BOLCK_BITS_COUNT 128 +#define BLOCK_MODE_BITS_COUNT 11 + +#define COLOR_ENDPOINT_START_BITS_FOR_ONE_PARTITIONS \ + (128 - BLOCK_MODE_BITS_COUNT - PARTITION_CNT_BITS - 4) + +#define COLOR_ENDPOINT_START_BITS_FOR_OTHER_PARTITIONS \ + (128 - BLOCK_MODE_BITS_COUNT - PARTITION_CNT_BITS - PARTITION_IDX_BITS - CEM_BITS_COUNT) + +struct BlockMode +{ + uint weightWidth; + uint weightHeight; + uint weightCnt; + uint quantizationMode; + uint partitionCnt; + uint isDualWeightPlane; + bool isErrorBlock; +}; + +struct BitPair +{ + uint bitToRead; + uint bitToShift; + uint inPutIdx; +}; + +struct QuantModeInfo +{ + uint trits; + uint bits; + uint quints; + uint offset; +}; + +layout(std430, binding = 0) uniform ColorUnquantizationTables +{ + uint color_unquantization_tables[1206]; + int quantization_mode_table[17][128]; +}; + +layout(std430, binding = 1) uniform QuintTritsInteger +{ + uint tritsInteger[256][5]; + uint quintsInteger[128][3]; + +}; + +layout(std430, binding = 2) uniform QuantizationTransferTable +{ + uint quantization_and_transfer_table[142]; +}; + + +layout(set = 0, binding = 3) uniform utextureBuffer astcSrcBuffer2D; +layout(set = 0, binding = 4) writeonly uniform image2D outputImage; +layout(rgba32ui,binding = 5) readonly uniform uimage2D astcSrcImage2D; + + +layout(local_size_x_id = 0, local_size_y_id = 1, local_size_z = 1) in; +layout(constant_id = 2) const bool isSrgb = false; +layout(constant_id = 3) const bool isBufferCopy = false; +shared BlockMode blockInfo; +shared uvec4 blockData; +shared uint bitsOfWeight; +shared uint blockMode; +shared uint partitionIdx; +shared uint cem; +shared uvec4 bitsSwapped; +uvec4 numOfBitsTrits[21] = +{ + uvec4(1,0,0,0), + uvec4(0,1,0,2), + uvec4(2,0,0,5), + uvec4(0,0,1,9), + uvec4(1,1,0,14), + uvec4(3,0,0,20), + uvec4(1,0,1,28), + uvec4(2,1,0,38), + uvec4(4,0,0,50), + uvec4(2,0,1,66), + uvec4(3,1,0,86), + uvec4(5,0,0,110), + uvec4(3,0,1,142), + uvec4(4,1,0,182), + uvec4(6,0,0,230), + uvec4(4,0,1,294), + uvec4(5,1,0,374), + uvec4(7,0,0,470), + uvec4(5,0,1,598), + uvec4(6,1,0,758), + uvec4(8,0,0,950) +}; + +uint ReadVecBits32(const in uvec4 src, uint bitCnt, uint bitOffset) +{ + uint offset = bitOffset % 32; + uint start = bitOffset >> 5; + uint res = 0; + int sum = int(32 - offset - bitCnt); + if (sum < 0) + { + uint reslow = 0; + uint resHigh = 0; + uint bitCntLow = 32 - offset; + uint bitCntHigh = bitCnt - bitCntLow; + + uint maskLow = (1 << bitCntLow) - 1; + uint maskHigh = (1 << bitCntHigh) - 1; + reslow = src[start] >> offset; + reslow &= maskLow; + + resHigh = src[start + 1] & maskHigh; + res = (resHigh << bitCntLow) | reslow; + } + else + { + uint mask = (1 << bitCnt) - 1; + res = src[start] >> (bitOffset & 0x1F); + res &= mask; + } + return res; +} + + +uint ReadBits32(const in uint src ,uint bitCnt, uint bitOffset) +{ + uint mask = (1 << bitCnt) - 1; + uint value = src >> (bitOffset & 0x1F); + return value & mask; +} + +// *****Those Utility Func is for ColorEndPoint UnPack*****START + +uvec4 blue_contract(uint r, uint g, uint b, uint a) +{ + uvec4 ret; + ret.r = (r + b) >> 1; + ret.g = (g + b) >> 1; + ret.b = b; + ret.a = a; + return ret; +} + +void luminance_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1) +{ + ep0 = uvec4(uvec3(v0), 0xff); + ep1 = uvec4(uvec3(v1), 0xff); +} + +void luminance_delta_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1) +{ + uint l0 = (v0 >> 2) | (v1 & 0xc0); + uint l1 = l0 + (v1 & 0x3f); + l1 = min(l1, 0xff); + ep0 = uvec4(uvec3(l0), 0xff); + ep1 = uvec4(uvec3(l1), 0xff); +} + +void luminance_alpha_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3) +{ + ep0 = uvec4(uvec3(v0), v2); + ep1 = uvec4(uvec3(v1), v3); +} + +void luminance_alpha_delta_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3) +{ + uint ul0, ul1, ua0, ua1; + int lum0 = int(v0); + int lum1 = int(v1); + int alpha0 = int(v2); + int alpha1 = int(v3); + + lum0 |= (lum1 & 0x80) << 1; + alpha0 |= (alpha1 & 0x80) << 1; + lum1 &= 0x7F; + alpha1 &= 0x7F; + lum1 = (lum1 & 0x40) > 0?(lum1 - 0x80):lum1; + alpha1 = (alpha1 & 0x40) > 0?(alpha1 - 0x80):alpha1; + + lum0 >>= 1; + lum1 >>= 1; + alpha0 >>= 1; + alpha1 >>= 1; + lum1 += lum0; + alpha1 += alpha0; + ul1 = clamp(lum1, 0, 255); + ua1 = clamp(alpha1, 0, 255); + ul0 = uint(lum0); + ua0 = uint(alpha0);; + + uint v0_v1 = clamp(v0 + v1, 0, 0xff); + uint v2_v3 = clamp(v2 + v3, 0, 0xff); + ep0 = uvec4(ul0, ul0, ul0, alpha0); + ep1 = uvec4(ul1, ul1, ul1, alpha1); +} + +void rgb_scale_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3) +{ + ep0 = uvec4((uvec3(v0, v1, v2) * v3) >> 8, 0xff); + ep1 = uvec4(v0, v1, v2, 0xff); +} + +void rgb_scale_alpha_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3, uint v4, uint v5) +{ + ep0 = uvec4((uvec3(v0, v1, v2) * v3) >> 8, v4); + ep1 = uvec4(v0, v1, v2, v5); +} + +void rgb_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3, uint v4, uint v5) +{ + uint s0 = v0 + v2 + v4; + uint s1 = v1 + v3 + v5; + if (s1 >= s0) + { + ep0 = uvec4(v0, v2, v4, 0xff); + ep1 = uvec4(v1, v3, v5, 0xff); + } + else + { + ep0 = blue_contract(v1, v3, v5, 0xff); + ep1 = blue_contract(v0, v2, v4, 0xff); + } +} + +void rgb_delta_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3, uint v4, uint v5) +{ + ivec4 color[2] = ivec4[]( ivec4(255), ivec4(255) ); + color[0].x = int(v0); + color[0].y = int(v2); + color[0].z = int(v4); + + color[1].x = int(v1); + color[1].y = int(v3); + color[1].z = int(v5); + + // perform the bit-transfer procedure + color[0].x |= (color[1].x & 0x80) << 1; + color[0].y |= (color[1].y & 0x80) << 1; + color[0].z |= (color[1].z & 0x80) << 1; + color[1].x &= 0x7F; + color[1].y &= 0x7F; + color[1].z &= 0x7F; + + color[1].x = (color[1].x & 0x40) >0?(color[1].x - 0x80):color[1].x; + color[1].y = (color[1].y & 0x40) >0?(color[1].y - 0x80):color[1].y; + color[1].z = (color[1].z & 0x40) >0?(color[1].z - 0x80):color[1].z; + + color[0].x >>= 1; + color[0].y >>= 1; + color[0].z >>= 1; + color[1].x >>= 1; + color[1].y >>= 1; + color[1].z >>= 1; + + int rgbsum = (color[1].x + color[1].y + color[1].z)>=0?1:0; + + color[1].x += color[0].x; + color[1].y += color[0].y; + color[1].z += color[0].z; + + color[0].x = rgbsum == 0? ((color[0].x + color[0].z) >> 1):color[0].x ; + color[0].y = rgbsum == 0? ((color[0].y + color[0].z) >> 1):color[0].y ; + color[1].x = rgbsum == 0? ((color[1].x + color[1].z) >> 1):color[1].x ; + color[1].y = rgbsum == 0? ((color[1].y + color[1].z) >> 1):color[1].y ; + + ivec3 icolor0 = clamp(color[1 - rgbsum].xyz,ivec3(0), ivec3(255)); + ivec3 icolor1 = clamp(color[rgbsum].xyz,ivec3(0), ivec3(255)); + ep0.xyz = uvec3(icolor0); + ep0.w = 255; + + ep1.xyz = uvec3(icolor1); + ep1.w = 255; +} + +void rgba_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3, + uint v4, uint v5, uint v6, uint v7) +{ + uint s0 = v0 + v2 + v4; + uint s1 = v1 + v3 + v5; + if (s1 >= s0) + { + ep0 = uvec4(v0, v2, v4, v6); + ep1 = uvec4(v1, v3, v5, v7); + } + else + { + ep0 = blue_contract(v1, v3, v5, v7); + ep1 = blue_contract(v0, v2, v4, v6); + } +} + +void rgba_delta_unpack(out uvec4 ep0, out uvec4 ep1, + uint v0, uint v1, uint v2, uint v3, uint v4, uint v5, uint v6, uint v7) +{ + ivec4 color[2] = ivec4[]( ivec4(255), ivec4(255) ); + color[0].x = int(v0); + color[0].y = int(v2); + color[0].z = int(v4); + color[0].w = int(v6); + + color[1].x = int(v1); + color[1].y = int(v3); + color[1].z = int(v5); + color[1].w = int(v7); + + // perform the bit-transfer procedure + color[0].x |= (color[1].x & 0x80) << 1; + color[0].y |= (color[1].y & 0x80) << 1; + color[0].z |= (color[1].z & 0x80) << 1; + color[0].w |= (color[1].w & 0x80) << 1; + + color[1].x &= 0x7F; + color[1].y &= 0x7F; + color[1].z &= 0x7F; + color[1].w &= 0x7F; + + color[1].x = (color[1].x & 0x40) >0?(color[1].x - 0x80):color[1].x; + color[1].y = (color[1].y & 0x40) >0?(color[1].y - 0x80):color[1].y; + color[1].z = (color[1].z & 0x40) >0?(color[1].z - 0x80):color[1].z; + color[1].w = (color[1].w & 0x40) >0?(color[1].w - 0x80):color[1].w; + + color[0].x >>= 1; + color[0].y >>= 1; + color[0].z >>= 1; + color[0].w >>= 1; + + color[1].x >>= 1; + color[1].y >>= 1; + color[1].z >>= 1; + color[1].w >>= 1; + + int rgbsum = (color[1].x + color[1].y + color[1].z)>=0?1:0; + + color[1].x += color[0].x; + color[1].y += color[0].y; + color[1].z += color[0].z; + color[1].w += color[0].w; + + color[0].x = rgbsum == 0? ((color[0].x + color[0].z) >> 1):color[0].x ; + color[0].y = rgbsum == 0? ((color[0].y + color[0].z) >> 1):color[0].y ; + color[1].x = rgbsum == 0? ((color[1].x + color[1].z) >> 1):color[1].x ; + color[1].y = rgbsum == 0? ((color[1].y + color[1].z) >> 1):color[1].y ; + + ivec4 icolor0 = clamp(color[1 - rgbsum],ivec4(0), ivec4(255)); + ivec4 icolor1 = clamp(color[rgbsum],ivec4(0), ivec4(255)); + + ep0 = uvec4(icolor0); + ep1 = uvec4(icolor1); +} + +// *****Those Utility Func is for ColorEndPoint UnPack*****END + +uint Hash52(uint inp) +{ + uint tmp = inp; + tmp ^= tmp >> 15; + tmp *= 0xEEDE0891; // (2^4+1)*(2^7+1)*(2^17-1) + tmp ^= tmp >> 5; + tmp += tmp << 16; + tmp ^= tmp >> 7; + tmp ^= tmp >> 3; + tmp ^= tmp << 6; + tmp ^= tmp >> 17; + return tmp; +} + +uint SelectPartition(uint seed, uint x, uint y, uint z, uint partitionCnt) +{ + seed += (partitionCnt - 1) * 1024; + uint rnum = Hash52(seed); + + uint seed1 = rnum & 0xF; + uint seed2 = (rnum >> 4) & 0xF; + uint seed3 = (rnum >> 8) & 0xF; + uint seed4 = (rnum >> 12) & 0xF; + uint seed5 = (rnum >> 16) & 0xF; + uint seed6 = (rnum >> 20) & 0xF; + uint seed7 = (rnum >> 24) & 0xF; + uint seed8 = (rnum >> 28) & 0xF; + uint seed9 = (rnum >> 18) & 0xF; + uint seed10 = (rnum >> 22) & 0xF; + uint seed11 = (rnum >> 26) & 0xF; + uint seed12 = ((rnum >> 30) | (rnum << 2)) & 0xF; + + // squaring all the seeds in order to bias their distribution + // towards lower values. + seed1 *= seed1; + seed2 *= seed2; + seed3 *= seed3; + seed4 *= seed4; + seed5 *= seed5; + seed6 *= seed6; + seed7 *= seed7; + seed8 *= seed8; + seed9 *= seed9; + seed10 *= seed10; + seed11 *= seed11; + seed12 *= seed12; + + uint sh1, sh2, sh3; + if ((seed & 1) == 1u) + { + sh1 = ((seed & 2) != 0u) ? 4 : 5; + sh2 = (partitionCnt == 3 ? 6 : 5); + } + else + { + sh1 = (partitionCnt == 3 ? 6 : 5); + sh2 = ((seed & 2) != 0u) ? 4 : 5; + } + sh3 = ((seed & 0x10) != 0u) ? sh1 : sh2; + + seed1 >>= sh1; + seed2 >>= sh2; + seed3 >>= sh1; + seed4 >>= sh2; + seed5 >>= sh1; + seed6 >>= sh2; + seed7 >>= sh1; + seed8 >>= sh2; + + seed9 >>= sh3; + seed10 >>= sh3; + seed11 >>= sh3; + seed12 >>= sh3; + + uint a = seed1 * x + seed2 * y + seed11 * z + (rnum >> 14); + uint b = seed3 * x + seed4 * y + seed12 * z + (rnum >> 10); + uint c = seed5 * x + seed6 * y + seed9 * z + (rnum >> 6); + uint d = seed7 * x + seed8 * y + seed10 * z + (rnum >> 2); + + // apply the saw + a &= 0x3F; + b &= 0x3F; + c &= 0x3F; + d &= 0x3F; + + // remove some of the components if we are to output < 4 partitions. + if (partitionCnt <= 3) + d = 0; + if (partitionCnt <= 2) + c = 0; + if (partitionCnt <= 1) + b = 0; + + + uint resPartition; + if (a >= b && a >= c && a >= d) + resPartition = 0; + else if (b >= c && b >= d) + resPartition = 1; + else if (c >= d) + resPartition = 2; + else + resPartition = 3; + + return resPartition; +} + +uint ComputeTexelPartition(uint partitionCnt, uint partitionIdx, uint xCoord, uint yCoord, uint zCoord) +{ + if(gl_WorkGroupSize.x * gl_WorkGroupSize.y * gl_WorkGroupSize.z < 32) + { + xCoord <<= 1; + yCoord <<= 1; + zCoord <<= 1; + } + uint resPartition = SelectPartition(partitionIdx, xCoord, yCoord, zCoord, partitionCnt); + return resPartition; +} + +void ReserveWeightData(const in uvec4 blockData, uint threadId) +{ + if(threadId < 16u) + { + uint lidy_read = threadId / 4; + uint lidx_read = threadId % 4; + lowp uint p = (blockData[lidy_read]& (0xffu << (lidx_read * 8u)))>>(lidx_read * 8u); + p = ((p & 0xfu) << 4) | ((p >> 4u) & 0xfu); + p = ((p & 0x33u) << 2) | ((p >> 2u) & 0x33u); + p = ((p & 0x55u) << 1) | ((p >> 1u) & 0x55u); + atomicOr(bitsSwapped[3u - lidy_read], p<<((3u - lidx_read) * 8u)); + } +} + +// Extract WeightCnt,QuantizationMode, DualPlaneMode +void ParseDecodeBlockMode2D(const in uint blockMode, inout BlockMode blockInfo) +{ + uint quantMode = (blockMode >> 4) & 1; + uint p = (blockMode >> 9) & 1; + uint Dp = (blockMode >> 10) & 1; + uint Wh1 = ((blockMode >> 5) & 0x3); + + // p1, p2 in low bits + if ((blockMode & 0x3) != 0u) + { + quantMode |= (blockMode & 3) << 1; + uint Wh2 = (blockMode >> 7) & 0x3; + uint mode = (blockMode >> 2) & 0x3; + + if(mode == 0u) + { + blockInfo.weightWidth = Wh2 + 4; + blockInfo.weightHeight = Wh1 + 2; + } + else if(mode == 1u) + { + blockInfo.weightWidth = Wh2 + 8; + blockInfo.weightHeight = Wh1 + 2; + } + else if(mode == 2u) + { + blockInfo.weightWidth = Wh1 + 2; + blockInfo.weightHeight = Wh2 + 8; + } + else if(mode == 3u) + { + Wh2 &= 1; + if ((blockMode & 0x100) != 0u) + { + blockInfo.weightWidth = Wh2 + 2; + blockInfo.weightHeight = Wh1 + 2; + } + else + { + blockInfo.weightWidth = Wh1 + 2; + blockInfo.weightHeight = Wh2 + 6; + } + } + } + else + { + quantMode |= ((blockMode >> 2) & 3) << 1; + if (((blockMode >> 2) & 3) == 0u) + { + blockInfo.isErrorBlock = true; + } + uint Wh2 = (blockMode >> 9) & 0x3; + uint mode2 = (blockMode >> 7) & 0x3; + if(mode2 == 0u) + { + blockInfo.weightWidth = 12; + blockInfo.weightHeight = Wh1 + 2; + } + else if(mode2 == 1u) + { + blockInfo.weightHeight = Wh1 + 2; + blockInfo.weightWidth = 12; + } + else if(mode2 == 2u) + { + blockInfo.weightWidth = Wh1 + 6; + blockInfo.weightHeight = Wh2 + 6; + Dp = 0; + p = 0; + } + else if(mode2 == 3u) + { + switch ((blockMode >> 5) & 3) + { + case 0: + blockInfo.weightWidth = 6; + blockInfo.weightHeight = 10; + break; + case 1: + blockInfo.weightWidth = 10; + blockInfo.weightHeight = 6; + break; + case 2: + case 3: + blockInfo.isErrorBlock = true; + break; + } + } + } + blockInfo.isDualWeightPlane = Dp; + blockInfo.quantizationMode = (quantMode - 2) + 6 * p; + uint weightCount = blockInfo.weightWidth * blockInfo.weightHeight; + blockInfo.weightCnt = (blockInfo.isDualWeightPlane == 1u) ? 2 * weightCount : weightCount; + return; +} + +uint ComputeIseBitCnt(uint weightCnt, QuantModeInfo quantInfo) +{ + return quantInfo.bits * weightCnt + + ((weightCnt * quantInfo.trits * 8 + 4) / 5) + + ((weightCnt * quantInfo.quints * 7 + 2) / 3); +} + +void FindNumOfBitsTritsQuints(uint quantMode, out QuantModeInfo quantInfo) +{ + uvec4 info = numOfBitsTrits[quantMode]; + quantInfo.bits = info.x; + quantInfo.trits = info.y; + quantInfo.quints = info.z; + quantInfo.offset = info.w; + return; +} + +uint DecodeIse(const QuantModeInfo quantMode, uint weightIntIdx, const in uvec4 blockData, uint bitOffset, uint weightCnt) +{ + uint res; + if(quantMode.trits > 0) + { + uint step = weightIntIdx / 5; + uint offset = weightIntIdx - 5 * step; + bitOffset += (step * 8 + step * 5 * quantMode.bits); + uint loopCnt = weightCnt / 5; + uint tritsHightBits = 0; + if(bitOffset + 7 > weightCnt) + { + uint readBits = weightCnt - bitOffset; + if(readBits >= 6) + { + tritsHightBits = ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 1 + 0) << 0 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 2 + 2) << 2 | + ReadVecBits32(blockData, 1, bitOffset + quantMode.bits * 3 + 4) << 4 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 4 + 5) << 5; + } + else if(readBits >= 5) + { + tritsHightBits = ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 1 + 0) << 0 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 2 + 2) << 2 | + ReadVecBits32(blockData, 1, bitOffset + quantMode.bits * 3 + 4) << 4; + } + else if(readBits > 2) + { + tritsHightBits = ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 1 + 0) << 0 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 2 + 2) << 2; + } + else + { + tritsHightBits = ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 1 + 0) << 0; + } + } + else + { + tritsHightBits = ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 1 + 0) << 0 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 2 + 2) << 2 | + ReadVecBits32(blockData, 1, bitOffset + quantMode.bits * 3 + 4) << 4 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 4 + 5) << 5 | + ReadVecBits32(blockData, 1, bitOffset + quantMode.bits * 5 + 7) << 7; + } + + uint index = tritsInteger[tritsHightBits][offset]; + if(quantMode.bits > 0) + { + uint bitsStart = (offset * quantMode.bits) + ((offset * 8 + 4) / 5); + uint bitsVal = ReadVecBits32(blockData, quantMode.bits, bitsStart + bitOffset); + res = (index << quantMode.bits) | bitsVal; + } + else + { + res = index; + } + } + else if(quantMode.quints > 0) + { + uint step = weightIntIdx / 3; + uint offset = weightIntIdx - 3 * step; + uint tritsHightBits = 0; + bitOffset += (step * 7 + step * 3 * quantMode.bits); + if(bitOffset + 6 > weightCnt) + { + uint readBits = weightCnt - bitOffset; + if(readBits < 5) + { + tritsHightBits = ReadVecBits32(blockData, 3, bitOffset + quantMode.bits * 1 + 0); + } + else + { + tritsHightBits = ReadVecBits32(blockData, 3, bitOffset + quantMode.bits * 1 + 0) << 0 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 2 + 3) << 3; + } + } + else + { + tritsHightBits = ReadVecBits32(blockData, 3, bitOffset + quantMode.bits * 1 + 0) << 0 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 2 + 3) << 3 | + ReadVecBits32(blockData, 2, bitOffset + quantMode.bits * 3 + 5) << 5; + } + + uint index = quintsInteger[tritsHightBits][offset]; + + if(quantMode.bits > 0) + { + uint bitsStart = (offset * quantMode.bits) + ((offset * 7 + 2) / 3); + uint bitsVal = ReadVecBits32(blockData, quantMode.bits, bitsStart + bitOffset); + res = (index << quantMode.bits) | bitsVal; + } + else + { + res = index; + } + } + else + { + bitOffset += (weightIntIdx * quantMode.bits); + res = ReadVecBits32(blockData, quantMode.bits, bitOffset); + } + + return res; +} + +uint DecodeWeight(const in uvec4 blockData, uint weight_index, const QuantModeInfo quantMode, uint weightCnt) +{ + uint weight = DecodeIse(quantMode, weight_index, blockData, 0, weightCnt); + return quantization_and_transfer_table[weight + quantMode.offset]; +} + +uint Compute2DTexelWight(const in uvec4 blockData, +const in BlockMode blockInfo, QuantModeInfo quantMode, uint offset, uvec2 pixelCoord, uint weightCnt) +{ + // normalize Coord + const uvec2 DsDt = uvec2((1024 + (uvec2(gl_WorkGroupSize.xy) >> 1))) / uvec2(gl_WorkGroupSize.xy - 1); + + uvec2 CsCt = DsDt * pixelCoord; + uvec2 WeightWH = uvec2(blockInfo.weightWidth, blockInfo.weightHeight); + uvec2 GsGt = uvec2((CsCt * (WeightWH.xy - 1) + 32) >> 6); + + uvec2 jsjt = uvec2(GsGt.xy >> 4); + uvec2 fsft = uvec2(GsGt.xy & 0X0F); + + uint v0 = jsjt.x + jsjt.y * WeightWH.x; + uint stride = 1 << blockInfo.isDualWeightPlane; + uint p00 = DecodeWeight(blockData, stride * v0 + offset, quantMode,weightCnt); + uint p10, p01, p11; + + p01 = DecodeWeight(blockData, stride * (v0 + 1) + offset, quantMode,weightCnt); + p10 = DecodeWeight(blockData, stride * (v0 + WeightWH.x) + offset, quantMode,weightCnt); + p11 = DecodeWeight(blockData, stride * (v0 + WeightWH.x + 1) + offset, quantMode,weightCnt); + + uint w11 = (fsft.x * fsft.y + 8) >> 4; + uint w10 = fsft.y - w11; + uint w01 = fsft.x - w11; + uint w00 = 16 - fsft.x - fsft.y + w11; + uint res = (p00 * w00 + p01 * w01 + p10 * w10 + p11 * w11 + 8) >> 4; + return res; +} + +uvec4 GetTheWeights(const in uvec4 blockData, const in uvec4 swappedData, +const in BlockMode blockInfo, QuantModeInfo quantMode, uint bitsOfWeight, uvec2 pixelCoord, uint cem, uint weightCnt) +{ + // Extract Plane2 Component 2bit which between the Color EndPoint and More Config bits. + uint plane2Component = 0; + if(blockInfo.isDualWeightPlane == 1u) + { + uint encodeTypeModeBits = 0; + if((cem & 3) != 0) + encodeTypeModeBits = max(0, int(3 * blockInfo.partitionCnt - 4)); + + // Read Plane Component + plane2Component = ReadVecBits32(blockData, 2, + BOLCK_BITS_COUNT - bitsOfWeight - encodeTypeModeBits - 2); + } + + uvec4 resWeights; + uint plane1Weight = Compute2DTexelWight(swappedData, blockInfo, quantMode, 0, pixelCoord, weightCnt); + if(blockInfo.isDualWeightPlane == 1u) + { + uint plane2Weight = Compute2DTexelWight(swappedData, blockInfo, quantMode, 1, pixelCoord, weightCnt); + + // this weight replace the weight in plane2Component. + // x * (1 - a) + y * a + resWeights = + mix(uvec4(plane1Weight), uvec4(plane2Weight), equal(uvec4(plane2Component), uvec4(0, 1, 2, 3))); + } + else + { + resWeights = uvec4(plane1Weight); + } + + return resWeights; +} + +uint ComputeColorIseBitCnt(uint partitionCnt, uint cem) +{ + uint ret; + if (partitionCnt > 1) + { + bool sameClass = ((cem & 3) == 0); + + // all 4bits decide the color format(HDR,LDR,LUMA) + if (sameClass) + ret = ((cem >> 4) + 1) * partitionCnt; + else + ret = (cem & 3) * partitionCnt + bitCount(ReadBits32(uint(cem), partitionCnt, 2)); + } + else + { + ret = (cem >> 2) + 1; + } + return ret * 2; +} + +uvec2 GetColorFormatAndOffset(const in uvec4 blockData, uint encodeType, uint partitionCnt, uint endPointIdx) +{ + uvec2 colorFmtAndOffset; + // partitionCnt is 1 + if(partitionCnt == 1u) + { + colorFmtAndOffset.x = ReadVecBits32(blockData, CEM_BITS_COUNT - 2, PARTITION_START_BITS); + colorFmtAndOffset.y = 0; + } + else + { + uint baseClass = encodeType & 0x3; + if(baseClass != 0) + { + baseClass--; + uint ciBits = ((encodeType >> (2 + endPointIdx)) & 1); + colorFmtAndOffset.x = (ciBits + baseClass) << 2; + colorFmtAndOffset.x |= (encodeType >> (2 + partitionCnt + 2 * endPointIdx)) & 0x3; + if(endPointIdx != 0) + { + colorFmtAndOffset.y = (encodeType & 0x3) * endPointIdx + bitCount(ReadBits32(encodeType, endPointIdx, 2)); + } + else + { + colorFmtAndOffset.y = 0; + } + } + else + { + colorFmtAndOffset.x = (encodeType >> 2) & 0xF; + colorFmtAndOffset.y = ((colorFmtAndOffset.x >> 2) + 1) * endPointIdx; + } + } + colorFmtAndOffset.y *= 2; + return colorFmtAndOffset; +} + +uint GetColorEndPointWeight(const in uvec4 blockData, QuantModeInfo quantMode, uint colorIdx, uint channelIdx, uint bitOffset) +{ + uint res = 0; + res = DecodeIse(quantMode, (channelIdx + colorIdx), blockData, bitOffset, 128); + return res; +} + +void UnpackColorEndPoint(const in uvec4 blockData, uint bitOffset, +QuantModeInfo quantInfo, uint colorFmt, uint colorIdx, out uvec4 ep0, out uvec4 ep1) +{ + +// Get Specific Channel of Color. +#define GetUnpackedColorChannelVal(i) \ + color_unquantization_tables[quantInfo.offset + \ + GetColorEndPointWeight(blockData, quantInfo, colorIdx, i, bitOffset)] + + uint v0, v1, v2, v3, v4, v5, v6, v7; + v0 = GetUnpackedColorChannelVal(0); + v1 = GetUnpackedColorChannelVal(1); + uint colorMode = colorFmt >> 2; + + if(colorMode >= 1u) + { + v2 = GetUnpackedColorChannelVal(2); + v3 = GetUnpackedColorChannelVal(3); + } + + if(colorMode >= 2u) + { + v4 = GetUnpackedColorChannelVal(4); + v5 = GetUnpackedColorChannelVal(5); + } + if(colorMode >= 3u) + { + v6 = GetUnpackedColorChannelVal(6); + v7 = GetUnpackedColorChannelVal(7); + } + + switch(colorFmt) + { + case FMT_LUMINANCE: + luminance_unpack(ep0, ep1, v0, v1); + break; + case FMT_LUMINANCE_DELTA: + luminance_delta_unpack(ep0, ep1, v0, v1); + break; + case FMT_LUMINANCE_ALPHA: + luminance_alpha_unpack(ep0, ep1, v0, v1, v2, v3); + break; + case FMT_LUMINANCE_ALPHA_DELTA: + luminance_alpha_delta_unpack(ep0, ep1, v0, v1, v2, v3); + break; + case FMT_RGB_SCALE: + rgb_scale_unpack(ep0, ep1, v0, v1, v2, v3); + break; + case FMT_RGB_SCALE_ALPHA: + rgb_scale_alpha_unpack(ep0, ep1, v0, v1, v2, v3, v4, v5); + break; + case FMT_RGB: + rgb_unpack(ep0, ep1, v0, v1, v2, v3, v4, v5); + break; + case FMT_RGB_DELTA: + rgb_delta_unpack(ep0, ep1, v0, v1, v2, v3, v4, v5); + break; + case FMT_RGBA: + rgba_unpack(ep0, ep1, v0, v1, v2, v3, v4, v5, v6, v7); + break; + case FMT_RGBA_DELTA: + rgba_delta_unpack(ep0, ep1, v0, v1, v2, v3, v4, v5, v6, v7); + break; + } + + ep0 *= 257; + ep1 *= 257; +} + +uvec4 ProcessSrgbColor(uvec4 color) +{ + float r = float(color.r); + float g = float(color.g); + float b = float(color.b); + if (r <= 0.0031308f) + r = r * 12.92f; + else if (r <= 1) + r = 1.055f * pow(r, (1.0f / 2.4f)) - 0.055f; + + if (g <= 0.0031308f) + g = g * 12.92f; + else if (g <= 1) + g = 1.055f * pow(g, (1.0f / 2.4f)) - 0.055f; + + if (b <= 0.0031308f) + b = b * 12.92f; + else if (b <= 1) + b = 1.055f * pow(b, (1.0f / 2.4f)) - 0.055f; + return uvec4(r, g, b, color.w); +} + +uvec4 InterpolateEndpoint(uvec4 ep0, uvec4 ep1, uvec4 weight) +{ + // Lerp the Color + uvec4 ecolor0 = ep0; + uvec4 ecolor1 = ep1; + if(isSrgb) + { + ecolor0 = ep0 >> 8; + ecolor1 = ep1 >> 8; + } + uvec4 color = (ecolor0 * (64 - weight) + ecolor1 * weight + 32) >> 6; + uvec4 finalColor = color; + if(isSrgb) + { + color = color | (color << 8); + finalColor = ProcessSrgbColor(color); + } + return finalColor; +} + +void main() +{ + // Load Image Block + ivec3 globalcoord = ivec3(gl_GlobalInvocationID.x, gl_GlobalInvocationID.y, gl_GlobalInvocationID.z); + uint threadId = gl_LocalInvocationIndex; + uvec2 pixelCoord = uvec2(gl_LocalInvocationID.xy); + ivec2 blockCoord = ivec2(gl_WorkGroupID.x, gl_WorkGroupID.y); + + if(threadId == 0u) + { //uint(blockCoord.y * gl_WorkGroupSize.x * gl_WorkGroupSize.y * gl_NumWorkGroups.x + blockCoord.x * gl_WorkGroupSize.x) + bitsSwapped = uvec4(0); + if(isBufferCopy == true) + { + blockData = uvec4(texelFetch(astcSrcBuffer2D, int(blockCoord.y * gl_NumWorkGroups.x + blockCoord.x)).xyzw); + } + else + { + blockData = imageLoad(astcSrcImage2D, blockCoord); + } + + blockMode = ReadVecBits32(blockData, BLOCK_MODE_BITS_COUNT, 0); + //BlockMode blockInfo; + ParseDecodeBlockMode2D(blockMode, blockInfo); + + // Extract the partitionCnt + blockInfo.partitionCnt = ReadVecBits32(blockData, PARTITION_CNT_BITS, BLOCK_MODE_BITS_COUNT) + 1; + + // Extract the partitionIndex(seed) + partitionIdx = 0; + if(blockInfo.partitionCnt > 1) + { + partitionIdx = ReadVecBits32(blockData, PARTITION_IDX_BITS, PARTITION_START_BITS); + } + + // Get CEM bits + cem = 0; + if(blockInfo.partitionCnt > 1) + { + cem = ReadVecBits32(blockData, CEM_BITS_COUNT, + BLOCK_MODE_BITS_COUNT + PARTITION_CNT_BITS + PARTITION_IDX_BITS); + } + else + { + cem =ReadVecBits32(blockData, CEM_BITS_COUNT - 2, PARTITION_START_BITS); + } + } + barrier(); + + // WeightBit to Read, and Bits expect Weight. + QuantModeInfo quantInfo, colorInfo; + FindNumOfBitsTritsQuints(blockInfo.quantizationMode, quantInfo); + bitsOfWeight = ComputeIseBitCnt(blockInfo.weightCnt, quantInfo); + + if((blockMode & 0x1FF) == 0x1FC) + { + // Process the void block + uvec4 returncolor = uvec4(blockData[2]&0xffffu, blockData[2]>>16u, blockData[3]&0xffffu, blockData[3]>>16u); + vec4 returnpixels = vec4(returncolor) / 65536.0f; + imageStore(outputImage, globalcoord.xy, returnpixels); + return; + } + + ReserveWeightData(blockData,threadId); + barrier(); + + uvec4 weights = GetTheWeights(blockData, bitsSwapped, blockInfo, quantInfo, bitsOfWeight, pixelCoord.xy, cem, bitsOfWeight); + + // Get Color EndPoint. + uint encodeTypeModeBits = max(0, int(3 * blockInfo.partitionCnt - 4)); + uint baseClassBits = ((cem & 0x3) != 0u) ? encodeTypeModeBits : 0; + uint colorEndPointBits = blockInfo.partitionCnt > 1 ? + COLOR_ENDPOINT_START_BITS_FOR_OTHER_PARTITIONS - bitsOfWeight - baseClassBits : + COLOR_ENDPOINT_START_BITS_FOR_ONE_PARTITIONS - bitsOfWeight; + + // Get partition + uint endpointIdx = ComputeTexelPartition(blockInfo.partitionCnt, partitionIdx, + gl_LocalInvocationID.x, gl_LocalInvocationID.y, 0); + + uint colorIseBitsCnt = ComputeColorIseBitCnt(blockInfo.partitionCnt, cem); + + if(colorIseBitsCnt > 18) + { + // error block + } + + // Get Color Quant Mode and Decode Color Data + colorEndPointBits = (blockInfo.isDualWeightPlane == 1u)? colorEndPointBits - 2 : colorEndPointBits; + int colorQuantizationMode = quantization_mode_table[colorIseBitsCnt / 2][colorEndPointBits]; + + if(colorQuantizationMode < 4) + { + // error block + } + + // Get Color EndPoint Mode info and Offset. + FindNumOfBitsTritsQuints(colorQuantizationMode, colorInfo); + + // Get Color Format and EndPoint Index + uvec2 colorFmtAndOffset; + uint encodeType = 0; + if(blockInfo.partitionCnt > 1) + { + // Get More Config Data + uint moreConfig = ReadVecBits32(blockData, encodeTypeModeBits, BOLCK_BITS_COUNT - bitsOfWeight - encodeTypeModeBits); + encodeType = (moreConfig << CEM_BITS_COUNT) | cem; + colorFmtAndOffset = GetColorFormatAndOffset(blockData, encodeType, blockInfo.partitionCnt, endpointIdx); + } + else + { + colorFmtAndOffset = GetColorFormatAndOffset(blockData, 0, blockInfo.partitionCnt, 0); + } + + // UnPack EndPoint + uvec4 ep0, ep1; + uint colorEndPointStartOffset = (blockInfo.partitionCnt > 1) ? PARTITION_IDX_BITS + 19: 17; + UnpackColorEndPoint(blockData, colorEndPointStartOffset, + colorInfo, colorFmtAndOffset.x, colorFmtAndOffset.y, ep0, ep1); + + // Interpolate the Final Color + uvec4 color = InterpolateEndpoint(ep0, ep1, weights); + vec4 outColor = vec4(color) / 65536.0f; + imageStore(outputImage, globalcoord.xy, outColor); +} diff --git a/icd/imported/gputexdecoder/shaders/AstcDecode.h b/icd/imported/gputexdecoder/shaders/AstcDecode.h new file mode 100644 index 00000000..2b1f41c7 --- /dev/null +++ b/icd/imported/gputexdecoder/shaders/AstcDecode.h @@ -0,0 +1,2668 @@ +/* + *********************************************************************************************************************** + * + * Copyright (c) 2021 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"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + **********************************************************************************************************************/ +// 1011.4.0 + #pragma once +const uint32_t AstcDecoder[] = { + 0x07230203,0x00010000,0x0008000a,0x00000d55,0x00000000,0x00020011,0x00000001,0x00020011, + 0x0000002e,0x00020011,0x00000038,0x0006000b,0x00000001,0x4c534c47,0x6474732e,0x3035342e, + 0x00000000,0x0003000e,0x00000000,0x00000001,0x000a000f,0x00000005,0x00000004,0x6e69616d, + 0x00000000,0x00000bf3,0x00000c00,0x00000c03,0x00000c0b,0x00000c24,0x00060010,0x00000004, + 0x00000011,0x00000001,0x00000001,0x00000001,0x00030003,0x00000002,0x000001c2,0x000b0004, + 0x455f4c47,0x735f5458,0x6c706d61,0x656c7265,0x745f7373,0x75747865,0x665f6572,0x74636e75, + 0x736e6f69,0x00000000,0x00080004,0x455f4c47,0x735f5458,0x616c6163,0x6c625f72,0x5f6b636f, + 0x6f79616c,0x00007475,0x00040005,0x00000004,0x6e69616d,0x00000000,0x00090005,0x0000000d, + 0x64616552,0x42636556,0x33737469,0x75762832,0x31753b34,0x3b31753b,0x00000000,0x00030005, + 0x0000000a,0x00637273,0x00040005,0x0000000b,0x43746962,0x0000746e,0x00050005,0x0000000c, + 0x4f746962,0x65736666,0x00000074,0x00080005,0x00000013,0x64616552,0x73746942,0x75283233, + 0x31753b31,0x3b31753b,0x00000000,0x00030005,0x00000010,0x00637273,0x00040005,0x00000011, + 0x43746962,0x0000746e,0x00050005,0x00000012,0x4f746962,0x65736666,0x00000074,0x00090005, + 0x0000001a,0x65756c62,0x6e6f635f,0x63617274,0x31752874,0x3b31753b,0x753b3175,0x00003b31, + 0x00030005,0x00000016,0x00000072,0x00030005,0x00000017,0x00000067,0x00030005,0x00000018, + 0x00000062,0x00030005,0x00000019,0x00000061,0x000a0005,0x00000022,0x696d756c,0x636e616e, + 0x6e755f65,0x6b636170,0x34757628,0x3475763b,0x3b31753b,0x003b3175,0x00030005,0x0000001e, + 0x00307065,0x00030005,0x0000001f,0x00317065,0x00030005,0x00000020,0x00003076,0x00030005, + 0x00000021,0x00003176,0x000c0005,0x00000028,0x696d756c,0x636e616e,0x65645f65,0x5f61746c, + 0x61706e75,0x76286b63,0x763b3475,0x753b3475,0x31753b31,0x0000003b,0x00030005,0x00000024, + 0x00307065,0x00030005,0x00000025,0x00317065,0x00030005,0x00000026,0x00003076,0x00030005, + 0x00000027,0x00003176,0x000d0005,0x00000031,0x696d756c,0x636e616e,0x6c615f65,0x5f616870, + 0x61706e75,0x76286b63,0x763b3475,0x753b3475,0x31753b31,0x3b31753b,0x003b3175,0x00030005, + 0x0000002b,0x00307065,0x00030005,0x0000002c,0x00317065,0x00030005,0x0000002d,0x00003076, + 0x00030005,0x0000002e,0x00003176,0x00030005,0x0000002f,0x00003276,0x00030005,0x00000030, + 0x00003376,0x000f0005,0x00000039,0x696d756c,0x636e616e,0x6c615f65,0x5f616870,0x746c6564, + 0x6e755f61,0x6b636170,0x34757628,0x3475763b,0x3b31753b,0x753b3175,0x31753b31,0x0000003b, + 0x00030005,0x00000033,0x00307065,0x00030005,0x00000034,0x00317065,0x00030005,0x00000035, + 0x00003076,0x00030005,0x00000036,0x00003176,0x00030005,0x00000037,0x00003276,0x00030005, + 0x00000038,0x00003376,0x000c0005,0x00000041,0x5f626772,0x6c616373,0x6e755f65,0x6b636170, + 0x34757628,0x3475763b,0x3b31753b,0x753b3175,0x31753b31,0x0000003b,0x00030005,0x0000003b, + 0x00307065,0x00030005,0x0000003c,0x00317065,0x00030005,0x0000003d,0x00003076,0x00030005, + 0x0000003e,0x00003176,0x00030005,0x0000003f,0x00003276,0x00030005,0x00000040,0x00003376, + 0x000f0005,0x0000004c,0x5f626772,0x6c616373,0x6c615f65,0x5f616870,0x61706e75,0x76286b63, + 0x763b3475,0x753b3475,0x31753b31,0x3b31753b,0x753b3175,0x31753b31,0x0000003b,0x00030005, + 0x00000044,0x00307065,0x00030005,0x00000045,0x00317065,0x00030005,0x00000046,0x00003076, + 0x00030005,0x00000047,0x00003176,0x00030005,0x00000048,0x00003276,0x00030005,0x00000049, + 0x00003376,0x00030005,0x0000004a,0x00003476,0x00030005,0x0000004b,0x00003576,0x000c0005, + 0x00000056,0x5f626772,0x61706e75,0x76286b63,0x763b3475,0x753b3475,0x31753b31,0x3b31753b, + 0x753b3175,0x31753b31,0x0000003b,0x00030005,0x0000004e,0x00307065,0x00030005,0x0000004f, + 0x00317065,0x00030005,0x00000050,0x00003076,0x00030005,0x00000051,0x00003176,0x00030005, + 0x00000052,0x00003276,0x00030005,0x00000053,0x00003376,0x00030005,0x00000054,0x00003476, + 0x00030005,0x00000055,0x00003576,0x000d0005,0x00000060,0x5f626772,0x746c6564,0x6e755f61, + 0x6b636170,0x34757628,0x3475763b,0x3b31753b,0x753b3175,0x31753b31,0x3b31753b,0x003b3175, + 0x00030005,0x00000058,0x00307065,0x00030005,0x00000059,0x00317065,0x00030005,0x0000005a, + 0x00003076,0x00030005,0x0000005b,0x00003176,0x00030005,0x0000005c,0x00003276,0x00030005, + 0x0000005d,0x00003376,0x00030005,0x0000005e,0x00003476,0x00030005,0x0000005f,0x00003576, + 0x000e0005,0x0000006d,0x61626772,0x706e755f,0x286b6361,0x3b347576,0x3b347576,0x753b3175, + 0x31753b31,0x3b31753b,0x753b3175,0x31753b31,0x3b31753b,0x00000000,0x00030005,0x00000063, + 0x00307065,0x00030005,0x00000064,0x00317065,0x00030005,0x00000065,0x00003076,0x00030005, + 0x00000066,0x00003176,0x00030005,0x00000067,0x00003276,0x00030005,0x00000068,0x00003376, + 0x00030005,0x00000069,0x00003476,0x00030005,0x0000006a,0x00003576,0x00030005,0x0000006b, + 0x00003676,0x00030005,0x0000006c,0x00003776,0x000f0005,0x00000079,0x61626772,0x6c65645f, + 0x755f6174,0x6361706e,0x7576286b,0x75763b34,0x31753b34,0x3b31753b,0x753b3175,0x31753b31, + 0x3b31753b,0x753b3175,0x00003b31,0x00030005,0x0000006f,0x00307065,0x00030005,0x00000070, + 0x00317065,0x00030005,0x00000071,0x00003076,0x00030005,0x00000072,0x00003176,0x00030005, + 0x00000073,0x00003276,0x00030005,0x00000074,0x00003376,0x00030005,0x00000075,0x00003476, + 0x00030005,0x00000076,0x00003576,0x00030005,0x00000077,0x00003676,0x00030005,0x00000078, + 0x00003776,0x00050005,0x0000007d,0x68736148,0x75283235,0x00003b31,0x00030005,0x0000007c, + 0x00706e69,0x000a0005,0x00000085,0x656c6553,0x61507463,0x74697472,0x286e6f69,0x753b3175, + 0x31753b31,0x3b31753b,0x003b3175,0x00040005,0x00000080,0x64656573,0x00000000,0x00030005, + 0x00000081,0x00000078,0x00030005,0x00000082,0x00000079,0x00030005,0x00000083,0x0000007a, + 0x00060005,0x00000084,0x74726170,0x6f697469,0x746e436e,0x00000000,0x000c0005,0x0000008c, + 0x706d6f43,0x54657475,0x6c657865,0x74726150,0x6f697469,0x3175286e,0x3b31753b,0x753b3175, + 0x31753b31,0x0000003b,0x00060005,0x00000087,0x74726170,0x6f697469,0x746e436e,0x00000000, + 0x00060005,0x00000088,0x74726170,0x6f697469,0x7864496e,0x00000000,0x00040005,0x00000089, + 0x6f6f4378,0x00006472,0x00040005,0x0000008a,0x6f6f4379,0x00006472,0x00040005,0x0000008b, + 0x6f6f437a,0x00006472,0x00090005,0x00000091,0x65736552,0x57657672,0x68676965,0x74614474, + 0x75762861,0x31753b34,0x0000003b,0x00050005,0x0000008f,0x636f6c62,0x7461446b,0x00000061, + 0x00050005,0x00000090,0x65726874,0x64496461,0x00000000,0x00050005,0x00000094,0x636f6c42, + 0x646f4d6b,0x00000065,0x00060006,0x00000094,0x00000000,0x67696577,0x69577468,0x00687464, + 0x00070006,0x00000094,0x00000001,0x67696577,0x65487468,0x74686769,0x00000000,0x00060006, + 0x00000094,0x00000002,0x67696577,0x6e437468,0x00000074,0x00080006,0x00000094,0x00000003, + 0x6e617571,0x617a6974,0x6e6f6974,0x65646f4d,0x00000000,0x00070006,0x00000094,0x00000004, + 0x74726170,0x6f697469,0x746e436e,0x00000000,0x00080006,0x00000094,0x00000005,0x75447369, + 0x65576c61,0x74686769,0x6e616c50,0x00000065,0x00070006,0x00000094,0x00000006,0x72457369, + 0x42726f72,0x6b636f6c,0x00000000,0x00130005,0x00000099,0x73726150,0x63654465,0x4265646f, + 0x6b636f6c,0x65646f4d,0x75284432,0x74733b31,0x74637572,0x6f6c422d,0x6f4d6b63,0x752d6564, + 0x31752d31,0x2d31752d,0x752d3175,0x31752d31,0x3131622d,0x0000003b,0x00050005,0x00000097, + 0x636f6c62,0x646f4d6b,0x00000065,0x00050005,0x00000098,0x636f6c62,0x666e496b,0x0000006f, + 0x00060005,0x0000009b,0x6e617551,0x646f4d74,0x666e4965,0x0000006f,0x00050006,0x0000009b, + 0x00000000,0x74697274,0x00000073,0x00050006,0x0000009b,0x00000001,0x73746962,0x00000000, + 0x00050006,0x0000009b,0x00000002,0x6e697571,0x00007374,0x00050006,0x0000009b,0x00000003, + 0x7366666f,0x00007465,0x00100005,0x000000a0,0x706d6f43,0x49657475,0x69426573,0x746e4374, + 0x3b317528,0x75727473,0x512d7463,0x746e6175,0x65646f4d,0x6f666e49,0x2d31752d,0x752d3175, + 0x31752d31,0x00003b31,0x00050005,0x0000009e,0x67696577,0x6e437468,0x00000074,0x00050005, + 0x0000009f,0x6e617571,0x666e4974,0x0000006f,0x00120005,0x000000a5,0x646e6946,0x4f6d754e, + 0x74694266,0x69725473,0x75517374,0x73746e69,0x3b317528,0x75727473,0x512d7463,0x746e6175, + 0x65646f4d,0x6f666e49,0x2d31752d,0x752d3175,0x31752d31,0x00003b31,0x00050005,0x000000a3, + 0x6e617571,0x646f4d74,0x00000065,0x00050005,0x000000a4,0x6e617571,0x666e4974,0x0000006f, + 0x00110005,0x000000ad,0x6f636544,0x73496564,0x74732865,0x74637572,0x6175512d,0x6f4d746e, + 0x6e496564,0x752d6f66,0x31752d31,0x2d31752d,0x3b313175,0x763b3175,0x753b3475,0x31753b31, + 0x0000003b,0x00050005,0x000000a8,0x6e617571,0x646f4d74,0x00000065,0x00060005,0x000000a9, + 0x67696577,0x6e497468,0x78644974,0x00000000,0x00050005,0x000000aa,0x636f6c62,0x7461446b, + 0x00000061,0x00050005,0x000000ab,0x4f746962,0x65736666,0x00000074,0x00050005,0x000000ac, + 0x67696577,0x6e437468,0x00000074,0x00110005,0x000000b4,0x6f636544,0x65576564,0x74686769, + 0x34757628,0x3b31753b,0x75727473,0x512d7463,0x746e6175,0x65646f4d,0x6f666e49,0x2d31752d, + 0x752d3175,0x31752d31,0x31753b31,0x0000003b,0x00050005,0x000000b0,0x636f6c62,0x7461446b, + 0x00000061,0x00060005,0x000000b1,0x67696577,0x695f7468,0x7865646e,0x00000000,0x00050005, + 0x000000b2,0x6e617571,0x646f4d74,0x00000065,0x00050005,0x000000b3,0x67696577,0x6e437468, + 0x00000074,0x001d0005,0x000000bf,0x706d6f43,0x32657475,0x78655444,0x69576c65,0x28746867, + 0x3b347576,0x75727473,0x422d7463,0x6b636f6c,0x65646f4d,0x2d31752d,0x752d3175,0x31752d31, + 0x2d31752d,0x622d3175,0x733b3131,0x63757274,0x75512d74,0x4d746e61,0x4965646f,0x2d6f666e, + 0x752d3175,0x31752d31,0x3131752d,0x3b31753b,0x3b327576,0x003b3175,0x00050005,0x000000b9, + 0x636f6c62,0x7461446b,0x00000061,0x00050005,0x000000ba,0x636f6c62,0x666e496b,0x0000006f, + 0x00050005,0x000000bb,0x6e617571,0x646f4d74,0x00000065,0x00040005,0x000000bc,0x7366666f, + 0x00007465,0x00050005,0x000000bd,0x65786970,0x6f6f436c,0x00006472,0x00050005,0x000000be, + 0x67696577,0x6e437468,0x00000074,0x001e0005,0x000000ca,0x54746547,0x65576568,0x74686769, + 0x75762873,0x75763b34,0x74733b34,0x74637572,0x6f6c422d,0x6f4d6b63,0x752d6564,0x31752d31, + 0x2d31752d,0x752d3175,0x31752d31,0x3131622d,0x7274733b,0x2d746375,0x6e617551,0x646f4d74, + 0x666e4965,0x31752d6f,0x2d31752d,0x752d3175,0x753b3131,0x75763b31,0x31753b32,0x3b31753b, + 0x00000000,0x00050005,0x000000c2,0x636f6c62,0x7461446b,0x00000061,0x00050005,0x000000c3, + 0x70617773,0x44646570,0x00617461,0x00050005,0x000000c4,0x636f6c62,0x666e496b,0x0000006f, + 0x00050005,0x000000c5,0x6e617571,0x646f4d74,0x00000065,0x00060005,0x000000c6,0x73746962, + 0x6557664f,0x74686769,0x00000000,0x00050005,0x000000c7,0x65786970,0x6f6f436c,0x00006472, + 0x00030005,0x000000c8,0x006d6563,0x00050005,0x000000c9,0x67696577,0x6e437468,0x00000074, + 0x000a0005,0x000000cf,0x706d6f43,0x43657475,0x726f6c6f,0x42657349,0x6e437469,0x31752874, + 0x3b31753b,0x00000000,0x00060005,0x000000cd,0x74726170,0x6f697469,0x746e436e,0x00000000, + 0x00030005,0x000000ce,0x006d6563,0x000c0005,0x000000d6,0x43746547,0x726f6c6f,0x6d726f46, + 0x6e417461,0x66664f64,0x28746573,0x3b347576,0x753b3175,0x31753b31,0x0000003b,0x00050005, + 0x000000d2,0x636f6c62,0x7461446b,0x00000061,0x00050005,0x000000d3,0x6f636e65,0x79546564, + 0x00006570,0x00060005,0x000000d4,0x74726170,0x6f697469,0x746e436e,0x00000000,0x00050005, + 0x000000d5,0x50646e65,0x746e696f,0x00786449,0x00140005,0x000000de,0x43746547,0x726f6c6f, + 0x50646e45,0x746e696f,0x67696557,0x76287468,0x733b3475,0x63757274,0x75512d74,0x4d746e61, + 0x4965646f,0x2d6f666e,0x752d3175,0x31752d31,0x3131752d,0x3b31753b,0x753b3175,0x00003b31, + 0x00050005,0x000000d9,0x636f6c62,0x7461446b,0x00000061,0x00050005,0x000000da,0x6e617571, + 0x646f4d74,0x00000065,0x00050005,0x000000db,0x6f6c6f63,0x78644972,0x00000000,0x00050005, + 0x000000dc,0x6e616863,0x496c656e,0x00007864,0x00050005,0x000000dd,0x4f746962,0x65736666, + 0x00000074,0x00150005,0x000000e8,0x61706e55,0x6f436b63,0x45726f6c,0x6f50646e,0x28746e69, + 0x3b347576,0x733b3175,0x63757274,0x75512d74,0x4d746e61,0x4965646f,0x2d6f666e,0x752d3175, + 0x31752d31,0x3131752d,0x3b31753b,0x763b3175,0x763b3475,0x003b3475,0x00050005,0x000000e1, + 0x636f6c62,0x7461446b,0x00000061,0x00050005,0x000000e2,0x4f746962,0x65736666,0x00000074, + 0x00050005,0x000000e3,0x6e617571,0x666e4974,0x0000006f,0x00050005,0x000000e4,0x6f6c6f63, + 0x746d4672,0x00000000,0x00050005,0x000000e5,0x6f6c6f63,0x78644972,0x00000000,0x00030005, + 0x000000e6,0x00307065,0x00030005,0x000000e7,0x00317065,0x00080005,0x000000ec,0x636f7250, + 0x53737365,0x43626772,0x726f6c6f,0x34757628,0x0000003b,0x00040005,0x000000eb,0x6f6c6f63, + 0x00000072,0x000b0005,0x000000f2,0x65746e49,0x6c6f7072,0x45657461,0x6f70646e,0x28746e69, + 0x3b347576,0x3b347576,0x3b347576,0x00000000,0x00030005,0x000000ef,0x00307065,0x00030005, + 0x000000f0,0x00317065,0x00040005,0x000000f1,0x67696577,0x00007468,0x00060005,0x000000f7, + 0x4f6d756e,0x74694266,0x69725473,0x00007374,0x00040005,0x00000129,0x7366666f,0x00007465, + 0x00040005,0x0000012d,0x72617473,0x00000074,0x00030005,0x00000132,0x00736572,0x00030005, + 0x00000134,0x006d7573,0x00040005,0x0000013f,0x6c736572,0x0000776f,0x00040005,0x00000140, + 0x48736572,0x00686769,0x00050005,0x00000141,0x43746962,0x6f4c746e,0x00000077,0x00050005, + 0x00000144,0x43746962,0x6948746e,0x00006867,0x00040005,0x00000148,0x6b73616d,0x00776f4c, + 0x00050005,0x0000014e,0x6b73616d,0x68676948,0x00000000,0x00040005,0x00000165,0x6b73616d, + 0x00000000,0x00040005,0x00000176,0x6b73616d,0x00000000,0x00040005,0x0000017b,0x756c6176, + 0x00000065,0x00030005,0x00000184,0x00746572,0x00030005,0x000001a4,0x0000306c,0x00030005, + 0x000001ac,0x0000316c,0x00040005,0x000001ce,0x306d756c,0x00000000,0x00040005,0x000001d1, + 0x316d756c,0x00000000,0x00040005,0x000001d4,0x68706c61,0x00003061,0x00040005,0x000001d7, + 0x68706c61,0x00003161,0x00030005,0x0000020f,0x00316c75,0x00030005,0x00000214,0x00316175, + 0x00030005,0x00000218,0x00306c75,0x00030005,0x0000021b,0x00306175,0x00040005,0x0000021e, + 0x765f3076,0x00000031,0x00040005,0x00000223,0x765f3276,0x00000033,0x00030005,0x0000025a, + 0x00003073,0x00030005,0x00000260,0x00003173,0x00040005,0x00000274,0x61726170,0x0000006d, + 0x00040005,0x00000276,0x61726170,0x0000006d,0x00040005,0x00000278,0x61726170,0x0000006d, + 0x00040005,0x0000027a,0x61726170,0x0000006d,0x00040005,0x0000027c,0x61726170,0x0000006d, + 0x00040005,0x0000027e,0x61726170,0x0000006d,0x00040005,0x00000280,0x61726170,0x0000006d, + 0x00040005,0x00000282,0x61726170,0x0000006d,0x00040005,0x00000287,0x6f6c6f63,0x00000072, + 0x00040005,0x00000305,0x73626772,0x00006d75,0x00040005,0x00000363,0x6c6f6369,0x0030726f, + 0x00040005,0x0000036d,0x6c6f6369,0x0031726f,0x00030005,0x0000037d,0x00003073,0x00030005, + 0x00000383,0x00003173,0x00040005,0x00000399,0x61726170,0x0000006d,0x00040005,0x0000039b, + 0x61726170,0x0000006d,0x00040005,0x0000039d,0x61726170,0x0000006d,0x00040005,0x0000039f, + 0x61726170,0x0000006d,0x00040005,0x000003a2,0x61726170,0x0000006d,0x00040005,0x000003a4, + 0x61726170,0x0000006d,0x00040005,0x000003a6,0x61726170,0x0000006d,0x00040005,0x000003a8, + 0x61726170,0x0000006d,0x00040005,0x000003ab,0x6f6c6f63,0x00000072,0x00040005,0x00000450, + 0x73626772,0x00006d75,0x00040005,0x000004b3,0x6c6f6369,0x0030726f,0x00040005,0x000004ba, + 0x6c6f6369,0x0031726f,0x00030005,0x000004c3,0x00706d74,0x00040005,0x000004f3,0x6d756e72, + 0x00000000,0x00040005,0x000004f4,0x61726170,0x0000006d,0x00040005,0x000004f7,0x64656573, + 0x00000031,0x00040005,0x000004fb,0x64656573,0x00000032,0x00040005,0x00000500,0x64656573, + 0x00000033,0x00040005,0x00000504,0x64656573,0x00000034,0x00040005,0x00000509,0x64656573, + 0x00000035,0x00040005,0x0000050d,0x64656573,0x00000036,0x00040005,0x00000512,0x64656573, + 0x00000037,0x00040005,0x00000517,0x64656573,0x00000038,0x00040005,0x0000051c,0x64656573, + 0x00000039,0x00040005,0x00000521,0x64656573,0x00003031,0x00040005,0x00000526,0x64656573, + 0x00003131,0x00040005,0x0000052b,0x64656573,0x00003231,0x00030005,0x0000055c,0x00316873, + 0x00030005,0x00000562,0x00326873,0x00030005,0x00000571,0x00336873,0x00030005,0x0000059d, + 0x00000061,0x00030005,0x000005ad,0x00000062,0x00030005,0x000005bd,0x00000063,0x00030005, + 0x000005cc,0x00000064,0x00060005,0x000005fc,0x50736572,0x69747261,0x6e6f6974,0x00000000, + 0x00060005,0x00000622,0x50736572,0x69747261,0x6e6f6974,0x00000000,0x00040005,0x00000623, + 0x61726170,0x0000006d,0x00040005,0x00000625,0x61726170,0x0000006d,0x00040005,0x00000627, + 0x61726170,0x0000006d,0x00040005,0x00000629,0x61726170,0x0000006d,0x00040005,0x0000062b, + 0x61726170,0x0000006d,0x00050005,0x00000635,0x7964696c,0x6165725f,0x00000064,0x00050005, + 0x00000638,0x7864696c,0x6165725f,0x00000064,0x00030005,0x0000063b,0x00000070,0x00050005, + 0x0000065d,0x73746962,0x70617753,0x00646570,0x00050005,0x00000668,0x6e617571,0x646f4d74, + 0x00000065,0x00030005,0x0000066b,0x00000070,0x00030005,0x0000066f,0x00007044,0x00030005, + 0x00000672,0x00316857,0x00030005,0x0000067d,0x00326857,0x00040005,0x00000680,0x65646f6d, + 0x00000000,0x00030005,0x000006ca,0x00326857,0x00040005,0x000006cd,0x65646f6d,0x00000032, + 0x00050005,0x0000070a,0x67696577,0x6f437468,0x00746e75,0x00040005,0x00000733,0x6f666e69, + 0x00000000,0x00040005,0x00000749,0x70657473,0x00000000,0x00040005,0x0000074c,0x7366666f, + 0x00007465,0x00040005,0x0000075a,0x706f6f6c,0x00746e43,0x00060005,0x0000075d,0x74697274, + 0x67694873,0x69427468,0x00007374,0x00050005,0x00000764,0x64616572,0x73746942,0x00000000, + 0x00040005,0x00000771,0x61726170,0x0000006d,0x00040005,0x00000772,0x61726170,0x0000006d, + 0x00040005,0x0000077a,0x61726170,0x0000006d,0x00040005,0x0000077b,0x61726170,0x0000006d, + 0x00040005,0x00000784,0x61726170,0x0000006d,0x00040005,0x00000785,0x61726170,0x0000006d, + 0x00040005,0x0000078e,0x61726170,0x0000006d,0x00040005,0x0000078f,0x61726170,0x0000006d, + 0x00040005,0x0000079d,0x61726170,0x0000006d,0x00040005,0x0000079e,0x61726170,0x0000006d, + 0x00040005,0x000007a6,0x61726170,0x0000006d,0x00040005,0x000007a7,0x61726170,0x0000006d, + 0x00040005,0x000007b0,0x61726170,0x0000006d,0x00040005,0x000007b1,0x61726170,0x0000006d, + 0x00040005,0x000007bf,0x61726170,0x0000006d,0x00040005,0x000007c0,0x61726170,0x0000006d, + 0x00040005,0x000007c8,0x61726170,0x0000006d,0x00040005,0x000007c9,0x61726170,0x0000006d, + 0x00040005,0x000007d3,0x61726170,0x0000006d,0x00040005,0x000007d4,0x61726170,0x0000006d, + 0x00040005,0x000007dd,0x61726170,0x0000006d,0x00040005,0x000007de,0x61726170,0x0000006d, + 0x00040005,0x000007e6,0x61726170,0x0000006d,0x00040005,0x000007e7,0x61726170,0x0000006d, + 0x00040005,0x000007f0,0x61726170,0x0000006d,0x00040005,0x000007f1,0x61726170,0x0000006d, + 0x00040005,0x000007fa,0x61726170,0x0000006d,0x00040005,0x000007fb,0x61726170,0x0000006d, + 0x00040005,0x00000804,0x61726170,0x0000006d,0x00040005,0x00000805,0x61726170,0x0000006d, + 0x00040005,0x00000809,0x65646e69,0x00000078,0x00070005,0x0000080f,0x6e697551,0x69725474, + 0x6e497374,0x65676574,0x00000072,0x00070006,0x0000080f,0x00000000,0x74697274,0x746e4973, + 0x72656765,0x00000000,0x00070006,0x0000080f,0x00000001,0x6e697571,0x6e497374,0x65676574, + 0x00000072,0x00030005,0x00000811,0x00000000,0x00050005,0x0000081b,0x73746962,0x72617453, + 0x00000074,0x00040005,0x00000824,0x73746962,0x006c6156,0x00040005,0x00000828,0x61726170, + 0x0000006d,0x00040005,0x0000082a,0x61726170,0x0000006d,0x00030005,0x0000082c,0x00736572, + 0x00040005,0x00000839,0x70657473,0x00000000,0x00040005,0x0000083c,0x7366666f,0x00007465, + 0x00060005,0x00000841,0x74697274,0x67694873,0x69427468,0x00007374,0x00050005,0x00000851, + 0x64616572,0x73746942,0x00000000,0x00040005,0x0000085e,0x61726170,0x0000006d,0x00040005, + 0x0000085f,0x61726170,0x0000006d,0x00040005,0x00000867,0x61726170,0x0000006d,0x00040005, + 0x00000868,0x61726170,0x0000006d,0x00040005,0x00000870,0x61726170,0x0000006d,0x00040005, + 0x00000871,0x61726170,0x0000006d,0x00040005,0x0000087b,0x61726170,0x0000006d,0x00040005, + 0x0000087c,0x61726170,0x0000006d,0x00040005,0x00000884,0x61726170,0x0000006d,0x00040005, + 0x00000885,0x61726170,0x0000006d,0x00040005,0x0000088e,0x61726170,0x0000006d,0x00040005, + 0x0000088f,0x61726170,0x0000006d,0x00040005,0x00000893,0x65646e69,0x00000078,0x00050005, + 0x0000089c,0x73746962,0x72617453,0x00000074,0x00040005,0x000008a5,0x73746962,0x006c6156, + 0x00040005,0x000008a9,0x61726170,0x0000006d,0x00040005,0x000008ab,0x61726170,0x0000006d, + 0x00040005,0x000008ba,0x61726170,0x0000006d,0x00040005,0x000008bc,0x61726170,0x0000006d, + 0x00040005,0x000008c2,0x67696577,0x00007468,0x00040005,0x000008c3,0x61726170,0x0000006d, + 0x00040005,0x000008c5,0x61726170,0x0000006d,0x00040005,0x000008c6,0x61726170,0x0000006d, + 0x00090005,0x000008ca,0x6e617551,0x617a6974,0x6e6f6974,0x6e617254,0x72656673,0x6c626154, + 0x00000065,0x000b0006,0x000008ca,0x00000000,0x6e617571,0x617a6974,0x6e6f6974,0x646e615f, + 0x6172745f,0x6566736e,0x61745f72,0x00656c62,0x00030005,0x000008cc,0x00000000,0x00040005, + 0x000008d4,0x74437343,0x00000000,0x00040005,0x000008e7,0x74447344,0x00000000,0x00050005, + 0x000008ea,0x67696557,0x48577468,0x00000000,0x00040005,0x000008ee,0x74477347,0x00000000, + 0x00040005,0x000008fb,0x746a736a,0x00000000,0x00040005,0x00000902,0x74667366,0x00000000, + 0x00030005,0x00000909,0x00003076,0x00040005,0x00000912,0x69727473,0x00006564,0x00030005, + 0x00000916,0x00303070,0x00040005,0x0000091d,0x61726170,0x0000006d,0x00040005,0x0000091e, + 0x61726170,0x0000006d,0x00030005,0x00000921,0x00313070,0x00040005,0x00000929,0x61726170, + 0x0000006d,0x00040005,0x0000092a,0x61726170,0x0000006d,0x00030005,0x0000092d,0x00303170, + 0x00040005,0x00000937,0x61726170,0x0000006d,0x00040005,0x00000938,0x61726170,0x0000006d, + 0x00030005,0x0000093b,0x00313170,0x00040005,0x00000946,0x61726170,0x0000006d,0x00040005, + 0x00000947,0x61726170,0x0000006d,0x00030005,0x0000094a,0x00313177,0x00030005,0x00000952, + 0x00303177,0x00030005,0x00000957,0x00313077,0x00030005,0x0000095c,0x00303077,0x00030005, + 0x00000965,0x00736572,0x00060005,0x0000097a,0x6e616c70,0x6f433265,0x6e6f706d,0x00746e65, + 0x00070005,0x0000097f,0x6f636e65,0x79546564,0x6f4d6570,0x69426564,0x00007374,0x00040005, + 0x00000990,0x61726170,0x0000006d,0x00040005,0x00000991,0x61726170,0x0000006d,0x00060005, + 0x00000993,0x6e616c70,0x65573165,0x74686769,0x00000000,0x00040005,0x00000994,0x61726170, + 0x0000006d,0x00040005,0x00000996,0x61726170,0x0000006d,0x00040005,0x00000997,0x61726170, + 0x0000006d,0x00040005,0x00000999,0x61726170,0x0000006d,0x00060005,0x000009a0,0x6e616c70, + 0x65573265,0x74686769,0x00000000,0x00040005,0x000009a1,0x61726170,0x0000006d,0x00040005, + 0x000009a3,0x61726170,0x0000006d,0x00040005,0x000009a4,0x61726170,0x0000006d,0x00040005, + 0x000009a6,0x61726170,0x0000006d,0x00050005,0x000009a9,0x57736572,0x68676965,0x00007374, + 0x00050005,0x000009be,0x656d6173,0x73616c43,0x00000073,0x00030005,0x000009c5,0x00746572, + 0x00040005,0x000009d1,0x61726170,0x0000006d,0x00040005,0x000009d3,0x61726170,0x0000006d, + 0x00070005,0x000009e4,0x6f6c6f63,0x746d4672,0x4f646e41,0x65736666,0x00000074,0x00040005, + 0x000009e6,0x61726170,0x0000006d,0x00040005,0x000009e7,0x61726170,0x0000006d,0x00050005, + 0x000009ec,0x65736162,0x73616c43,0x00000073,0x00040005,0x000009f5,0x69426963,0x00007374, + 0x00040005,0x00000a15,0x61726170,0x0000006d,0x00040005,0x00000a17,0x61726170,0x0000006d, + 0x00030005,0x00000a32,0x00736572,0x00040005,0x00000a37,0x61726170,0x0000006d,0x00040005, + 0x00000a38,0x61726170,0x0000006d,0x00040005,0x00000a3a,0x61726170,0x0000006d,0x00030005, + 0x00000a3f,0x00003076,0x00090005,0x00000a45,0x6f6c6f43,0x716e5572,0x746e6175,0x74617a69, + 0x546e6f69,0x656c6261,0x00000073,0x000a0006,0x00000a45,0x00000000,0x6f6c6f63,0x6e755f72, + 0x6e617571,0x617a6974,0x6e6f6974,0x6261745f,0x0073656c,0x00090006,0x00000a45,0x00000001, + 0x6e617571,0x617a6974,0x6e6f6974,0x646f6d5f,0x61745f65,0x00656c62,0x00030005,0x00000a47, + 0x00000000,0x00040005,0x00000a4a,0x61726170,0x0000006d,0x00040005,0x00000a4c,0x61726170, + 0x0000006d,0x00040005,0x00000a4e,0x61726170,0x0000006d,0x00040005,0x00000a4f,0x61726170, + 0x0000006d,0x00030005,0x00000a55,0x00003176,0x00040005,0x00000a58,0x61726170,0x0000006d, + 0x00040005,0x00000a5a,0x61726170,0x0000006d,0x00040005,0x00000a5c,0x61726170,0x0000006d, + 0x00040005,0x00000a5d,0x61726170,0x0000006d,0x00050005,0x00000a63,0x6f6c6f63,0x646f4d72, + 0x00000065,0x00030005,0x00000a6a,0x00003276,0x00040005,0x00000a6d,0x61726170,0x0000006d, + 0x00040005,0x00000a6f,0x61726170,0x0000006d,0x00040005,0x00000a71,0x61726170,0x0000006d, + 0x00040005,0x00000a72,0x61726170,0x0000006d,0x00030005,0x00000a78,0x00003376,0x00040005, + 0x00000a7b,0x61726170,0x0000006d,0x00040005,0x00000a7d,0x61726170,0x0000006d,0x00040005, + 0x00000a7f,0x61726170,0x0000006d,0x00040005,0x00000a80,0x61726170,0x0000006d,0x00030005, + 0x00000a8a,0x00003476,0x00040005,0x00000a8d,0x61726170,0x0000006d,0x00040005,0x00000a8f, + 0x61726170,0x0000006d,0x00040005,0x00000a91,0x61726170,0x0000006d,0x00040005,0x00000a92, + 0x61726170,0x0000006d,0x00030005,0x00000a98,0x00003576,0x00040005,0x00000a9b,0x61726170, + 0x0000006d,0x00040005,0x00000a9d,0x61726170,0x0000006d,0x00040005,0x00000a9f,0x61726170, + 0x0000006d,0x00040005,0x00000aa0,0x61726170,0x0000006d,0x00030005,0x00000aaa,0x00003676, + 0x00040005,0x00000aad,0x61726170,0x0000006d,0x00040005,0x00000aaf,0x61726170,0x0000006d, + 0x00040005,0x00000ab1,0x61726170,0x0000006d,0x00040005,0x00000ab2,0x61726170,0x0000006d, + 0x00030005,0x00000ab8,0x00003776,0x00040005,0x00000abb,0x61726170,0x0000006d,0x00040005, + 0x00000abd,0x61726170,0x0000006d,0x00040005,0x00000abf,0x61726170,0x0000006d,0x00040005, + 0x00000ac0,0x61726170,0x0000006d,0x00040005,0x00000ad2,0x61726170,0x0000006d,0x00040005, + 0x00000ad3,0x61726170,0x0000006d,0x00040005,0x00000ad4,0x61726170,0x0000006d,0x00040005, + 0x00000ad6,0x61726170,0x0000006d,0x00040005,0x00000adc,0x61726170,0x0000006d,0x00040005, + 0x00000add,0x61726170,0x0000006d,0x00040005,0x00000ade,0x61726170,0x0000006d,0x00040005, + 0x00000ae0,0x61726170,0x0000006d,0x00040005,0x00000ae6,0x61726170,0x0000006d,0x00040005, + 0x00000ae7,0x61726170,0x0000006d,0x00040005,0x00000ae8,0x61726170,0x0000006d,0x00040005, + 0x00000aea,0x61726170,0x0000006d,0x00040005,0x00000aec,0x61726170,0x0000006d,0x00040005, + 0x00000aee,0x61726170,0x0000006d,0x00040005,0x00000af4,0x61726170,0x0000006d,0x00040005, + 0x00000af5,0x61726170,0x0000006d,0x00040005,0x00000af6,0x61726170,0x0000006d,0x00040005, + 0x00000af8,0x61726170,0x0000006d,0x00040005,0x00000afa,0x61726170,0x0000006d,0x00040005, + 0x00000afc,0x61726170,0x0000006d,0x00040005,0x00000b02,0x61726170,0x0000006d,0x00040005, + 0x00000b03,0x61726170,0x0000006d,0x00040005,0x00000b04,0x61726170,0x0000006d,0x00040005, + 0x00000b06,0x61726170,0x0000006d,0x00040005,0x00000b08,0x61726170,0x0000006d,0x00040005, + 0x00000b0a,0x61726170,0x0000006d,0x00040005,0x00000b10,0x61726170,0x0000006d,0x00040005, + 0x00000b11,0x61726170,0x0000006d,0x00040005,0x00000b12,0x61726170,0x0000006d,0x00040005, + 0x00000b14,0x61726170,0x0000006d,0x00040005,0x00000b16,0x61726170,0x0000006d,0x00040005, + 0x00000b18,0x61726170,0x0000006d,0x00040005,0x00000b1a,0x61726170,0x0000006d,0x00040005, + 0x00000b1c,0x61726170,0x0000006d,0x00040005,0x00000b22,0x61726170,0x0000006d,0x00040005, + 0x00000b23,0x61726170,0x0000006d,0x00040005,0x00000b24,0x61726170,0x0000006d,0x00040005, + 0x00000b26,0x61726170,0x0000006d,0x00040005,0x00000b28,0x61726170,0x0000006d,0x00040005, + 0x00000b2a,0x61726170,0x0000006d,0x00040005,0x00000b2c,0x61726170,0x0000006d,0x00040005, + 0x00000b2e,0x61726170,0x0000006d,0x00040005,0x00000b34,0x61726170,0x0000006d,0x00040005, + 0x00000b35,0x61726170,0x0000006d,0x00040005,0x00000b36,0x61726170,0x0000006d,0x00040005, + 0x00000b38,0x61726170,0x0000006d,0x00040005,0x00000b3a,0x61726170,0x0000006d,0x00040005, + 0x00000b3c,0x61726170,0x0000006d,0x00040005,0x00000b3e,0x61726170,0x0000006d,0x00040005, + 0x00000b40,0x61726170,0x0000006d,0x00040005,0x00000b46,0x61726170,0x0000006d,0x00040005, + 0x00000b47,0x61726170,0x0000006d,0x00040005,0x00000b48,0x61726170,0x0000006d,0x00040005, + 0x00000b4a,0x61726170,0x0000006d,0x00040005,0x00000b4c,0x61726170,0x0000006d,0x00040005, + 0x00000b4e,0x61726170,0x0000006d,0x00040005,0x00000b50,0x61726170,0x0000006d,0x00040005, + 0x00000b52,0x61726170,0x0000006d,0x00040005,0x00000b54,0x61726170,0x0000006d,0x00040005, + 0x00000b56,0x61726170,0x0000006d,0x00040005,0x00000b5c,0x61726170,0x0000006d,0x00040005, + 0x00000b5d,0x61726170,0x0000006d,0x00040005,0x00000b5e,0x61726170,0x0000006d,0x00040005, + 0x00000b60,0x61726170,0x0000006d,0x00040005,0x00000b62,0x61726170,0x0000006d,0x00040005, + 0x00000b64,0x61726170,0x0000006d,0x00040005,0x00000b66,0x61726170,0x0000006d,0x00040005, + 0x00000b68,0x61726170,0x0000006d,0x00040005,0x00000b6a,0x61726170,0x0000006d,0x00040005, + 0x00000b6c,0x61726170,0x0000006d,0x00030005,0x00000b7c,0x00000072,0x00030005,0x00000b80, + 0x00000067,0x00030005,0x00000b84,0x00000062,0x00040005,0x00000bc6,0x6c6f6365,0x0030726f, + 0x00040005,0x00000bc8,0x6c6f6365,0x0031726f,0x00040005,0x00000bca,0x72537369,0x00006267, + 0x00040005,0x00000bd3,0x6f6c6f63,0x00000072,0x00050005,0x00000be2,0x616e6966,0x6c6f436c, + 0x0000726f,0x00040005,0x00000beb,0x61726170,0x0000006d,0x00050005,0x00000bf1,0x626f6c67, + 0x6f636c61,0x0064726f,0x00080005,0x00000bf3,0x475f6c67,0x61626f6c,0x766e496c,0x7461636f, + 0x496e6f69,0x00000044,0x00050005,0x00000bff,0x65726874,0x64496461,0x00000000,0x00080005, + 0x00000c00,0x4c5f6c67,0x6c61636f,0x6f766e49,0x69746163,0x6e496e6f,0x00786564,0x00050005, + 0x00000c02,0x65786970,0x6f6f436c,0x00006472,0x00080005,0x00000c03,0x4c5f6c67,0x6c61636f, + 0x6f766e49,0x69746163,0x44496e6f,0x00000000,0x00050005,0x00000c0a,0x636f6c62,0x6f6f436b, + 0x00006472,0x00060005,0x00000c0b,0x575f6c67,0x476b726f,0x70756f72,0x00004449,0x00060005, + 0x00000c18,0x75427369,0x72656666,0x79706f43,0x00000000,0x00050005,0x00000c1c,0x636f6c62, + 0x7461446b,0x00000061,0x00060005,0x00000c1f,0x63747361,0x42637253,0x65666675,0x00443272, + 0x00070005,0x00000c24,0x4e5f6c67,0x6f576d75,0x72476b72,0x7370756f,0x00000000,0x00060005, + 0x00000c36,0x63747361,0x49637253,0x6567616d,0x00004432,0x00050005,0x00000c3a,0x636f6c62, + 0x646f4d6b,0x00000065,0x00040005,0x00000c3d,0x61726170,0x0000006d,0x00040005,0x00000c3e, + 0x61726170,0x0000006d,0x00050005,0x00000c42,0x636f6c62,0x666e496b,0x0000006f,0x00040005, + 0x00000c43,0x61726170,0x0000006d,0x00040005,0x00000c48,0x61726170,0x0000006d,0x00040005, + 0x00000c49,0x61726170,0x0000006d,0x00060005,0x00000c4d,0x74726170,0x6f697469,0x7864496e, + 0x00000000,0x00040005,0x00000c54,0x61726170,0x0000006d,0x00040005,0x00000c55,0x61726170, + 0x0000006d,0x00030005,0x00000c57,0x006d6563,0x00040005,0x00000c5f,0x61726170,0x0000006d, + 0x00040005,0x00000c60,0x61726170,0x0000006d,0x00040005,0x00000c64,0x61726170,0x0000006d, + 0x00040005,0x00000c65,0x61726170,0x0000006d,0x00050005,0x00000c68,0x6e617571,0x666e4974, + 0x0000006f,0x00040005,0x00000c69,0x61726170,0x0000006d,0x00040005,0x00000c6c,0x61726170, + 0x0000006d,0x00060005,0x00000c6f,0x73746962,0x6557664f,0x74686769,0x00000000,0x00040005, + 0x00000c70,0x61726170,0x0000006d,0x00040005,0x00000c73,0x61726170,0x0000006d,0x00050005, + 0x00000c7d,0x75746572,0x6f636e72,0x00726f6c,0x00060005,0x00000c8e,0x75746572,0x69706e72, + 0x736c6578,0x00000000,0x00050005,0x00000c96,0x7074756f,0x6d497475,0x00656761,0x00040005, + 0x00000c9d,0x61726170,0x0000006d,0x00040005,0x00000ca0,0x67696577,0x00737468,0x00040005, + 0x00000ca4,0x61726170,0x0000006d,0x00040005,0x00000ca6,0x61726170,0x0000006d,0x00040005, + 0x00000ca8,0x61726170,0x0000006d,0x00040005,0x00000caa,0x61726170,0x0000006d,0x00040005, + 0x00000cac,0x61726170,0x0000006d,0x00070005,0x00000caf,0x6f636e65,0x79546564,0x6f4d6570, + 0x69426564,0x00007374,0x00060005,0x00000cb7,0x65736162,0x73616c43,0x74694273,0x00000073, + 0x00070005,0x00000cbd,0x6f6c6f63,0x646e4572,0x6e696f50,0x74694274,0x00000073,0x00050005, + 0x00000cce,0x70646e65,0x746e696f,0x00786449,0x00040005,0x00000ccf,0x61726170,0x0000006d, + 0x00040005,0x00000cd2,0x61726170,0x0000006d,0x00040005,0x00000cd4,0x61726170,0x0000006d, + 0x00040005,0x00000cd7,0x61726170,0x0000006d,0x00040005,0x00000cda,0x61726170,0x0000006d, + 0x00060005,0x00000cdc,0x6f6c6f63,0x65734972,0x73746942,0x00746e43,0x00040005,0x00000cdd, + 0x61726170,0x0000006d,0x00040005,0x00000ce0,0x61726170,0x0000006d,0x00080005,0x00000cf3, + 0x6f6c6f63,0x61755172,0x7a69746e,0x6f697461,0x646f4d6e,0x00000065,0x00050005,0x00000d00, + 0x6f6c6f63,0x666e4972,0x0000006f,0x00040005,0x00000d01,0x61726170,0x0000006d,0x00040005, + 0x00000d02,0x61726170,0x0000006d,0x00050005,0x00000d05,0x6f636e65,0x79546564,0x00006570, + 0x00050005,0x00000d0b,0x65726f6d,0x666e6f43,0x00006769,0x00040005,0x00000d11,0x61726170, + 0x0000006d,0x00040005,0x00000d13,0x61726170,0x0000006d,0x00070005,0x00000d19,0x6f6c6f63, + 0x746d4672,0x4f646e41,0x65736666,0x00000074,0x00040005,0x00000d1b,0x61726170,0x0000006d, + 0x00040005,0x00000d1d,0x61726170,0x0000006d,0x00040005,0x00000d20,0x61726170,0x0000006d, + 0x00040005,0x00000d25,0x61726170,0x0000006d,0x00040005,0x00000d26,0x61726170,0x0000006d, + 0x00040005,0x00000d29,0x61726170,0x0000006d,0x00090005,0x00000d2b,0x6f6c6f63,0x646e4572, + 0x6e696f50,0x61745374,0x664f7472,0x74657366,0x00000000,0x00030005,0x00000d33,0x00307065, + 0x00030005,0x00000d34,0x00317065,0x00040005,0x00000d35,0x61726170,0x0000006d,0x00040005, + 0x00000d37,0x61726170,0x0000006d,0x00040005,0x00000d39,0x61726170,0x0000006d,0x00040005, + 0x00000d3c,0x61726170,0x0000006d,0x00040005,0x00000d3f,0x61726170,0x0000006d,0x00040005, + 0x00000d40,0x61726170,0x0000006d,0x00040005,0x00000d44,0x6f6c6f63,0x00000072,0x00040005, + 0x00000d45,0x61726170,0x0000006d,0x00040005,0x00000d47,0x61726170,0x0000006d,0x00040005, + 0x00000d49,0x61726170,0x0000006d,0x00050005,0x00000d4c,0x4374756f,0x726f6c6f,0x00000000, + 0x00040047,0x00000611,0x00000001,0x00000000,0x00040047,0x00000612,0x00000001,0x00000001, + 0x00040047,0x00000613,0x0000000b,0x00000019,0x00030047,0x0000063b,0x00000000,0x00030047, + 0x00000645,0x00000000,0x00030047,0x00000646,0x00000000,0x00030047,0x00000647,0x00000000, + 0x00030047,0x00000648,0x00000000,0x00030047,0x00000649,0x00000000,0x00030047,0x0000064a, + 0x00000000,0x00030047,0x0000064b,0x00000000,0x00030047,0x0000064c,0x00000000,0x00030047, + 0x0000064e,0x00000000,0x00030047,0x0000064f,0x00000000,0x00030047,0x00000650,0x00000000, + 0x00030047,0x00000651,0x00000000,0x00030047,0x00000652,0x00000000,0x00030047,0x00000653, + 0x00000000,0x00030047,0x00000654,0x00000000,0x00030047,0x00000656,0x00000000,0x00030047, + 0x00000657,0x00000000,0x00030047,0x00000658,0x00000000,0x00030047,0x00000659,0x00000000, + 0x00030047,0x0000065a,0x00000000,0x00030047,0x0000065b,0x00000000,0x00030047,0x00000662, + 0x00000000,0x00030047,0x00000666,0x00000000,0x00040047,0x0000080a,0x00000006,0x00000004, + 0x00040047,0x0000080b,0x00000006,0x00000014,0x00040047,0x0000080c,0x00000006,0x00000004, + 0x00040047,0x0000080e,0x00000006,0x0000000c,0x00050048,0x0000080f,0x00000000,0x00000023, + 0x00000000,0x00050048,0x0000080f,0x00000001,0x00000023,0x00001400,0x00030047,0x0000080f, + 0x00000002,0x00040047,0x00000811,0x00000022,0x00000000,0x00040047,0x00000811,0x00000021, + 0x00000001,0x00040047,0x000008c9,0x00000006,0x00000004,0x00050048,0x000008ca,0x00000000, + 0x00000023,0x00000000,0x00030047,0x000008ca,0x00000002,0x00040047,0x000008cc,0x00000022, + 0x00000000,0x00040047,0x000008cc,0x00000021,0x00000002,0x00040047,0x00000a41,0x00000006, + 0x00000004,0x00040047,0x00000a42,0x00000006,0x00000004,0x00040047,0x00000a44,0x00000006, + 0x00000200,0x00050048,0x00000a45,0x00000000,0x00000023,0x00000000,0x00050048,0x00000a45, + 0x00000001,0x00000023,0x000012d8,0x00030047,0x00000a45,0x00000002,0x00040047,0x00000a47, + 0x00000022,0x00000000,0x00040047,0x00000a47,0x00000021,0x00000000,0x00040047,0x00000bca, + 0x00000001,0x00000002,0x00040047,0x00000bf3,0x0000000b,0x0000001c,0x00040047,0x00000c00, + 0x0000000b,0x0000001d,0x00040047,0x00000c03,0x0000000b,0x0000001b,0x00040047,0x00000c0b, + 0x0000000b,0x0000001a,0x00040047,0x00000c18,0x00000001,0x00000003,0x00040047,0x00000c1f, + 0x00000022,0x00000000,0x00040047,0x00000c1f,0x00000021,0x00000003,0x00040047,0x00000c24, + 0x0000000b,0x00000018,0x00040047,0x00000c36,0x00000022,0x00000000,0x00040047,0x00000c36, + 0x00000021,0x00000005,0x00030047,0x00000c36,0x00000018,0x00040047,0x00000c96,0x00000022, + 0x00000000,0x00040047,0x00000c96,0x00000021,0x00000004,0x00030047,0x00000c96,0x00000019, + 0x00020013,0x00000002,0x00030021,0x00000003,0x00000002,0x00040015,0x00000006,0x00000020, + 0x00000000,0x00040017,0x00000007,0x00000006,0x00000004,0x00040020,0x00000008,0x00000007, + 0x00000006,0x00060021,0x00000009,0x00000006,0x00000007,0x00000008,0x00000008,0x00060021, + 0x0000000f,0x00000006,0x00000006,0x00000008,0x00000008,0x00070021,0x00000015,0x00000007, + 0x00000008,0x00000008,0x00000008,0x00000008,0x00040020,0x0000001c,0x00000007,0x00000007, + 0x00070021,0x0000001d,0x00000002,0x0000001c,0x0000001c,0x00000008,0x00000008,0x00090021, + 0x0000002a,0x00000002,0x0000001c,0x0000001c,0x00000008,0x00000008,0x00000008,0x00000008, + 0x000b0021,0x00000043,0x00000002,0x0000001c,0x0000001c,0x00000008,0x00000008,0x00000008, + 0x00000008,0x00000008,0x00000008,0x000d0021,0x00000062,0x00000002,0x0000001c,0x0000001c, + 0x00000008,0x00000008,0x00000008,0x00000008,0x00000008,0x00000008,0x00000008,0x00000008, + 0x00040021,0x0000007b,0x00000006,0x00000008,0x00080021,0x0000007f,0x00000006,0x00000008, + 0x00000008,0x00000008,0x00000008,0x00000008,0x00050021,0x0000008e,0x00000002,0x00000007, + 0x00000008,0x00020014,0x00000093,0x0009001e,0x00000094,0x00000006,0x00000006,0x00000006, + 0x00000006,0x00000006,0x00000006,0x00000093,0x00040020,0x00000095,0x00000007,0x00000094, + 0x00050021,0x00000096,0x00000002,0x00000006,0x00000095,0x0006001e,0x0000009b,0x00000006, + 0x00000006,0x00000006,0x00000006,0x00040020,0x0000009c,0x00000007,0x0000009b,0x00050021, + 0x0000009d,0x00000006,0x00000008,0x0000009c,0x00050021,0x000000a2,0x00000002,0x00000008, + 0x0000009c,0x00080021,0x000000a7,0x00000006,0x0000009b,0x00000008,0x00000007,0x00000008, + 0x00000008,0x00070021,0x000000af,0x00000006,0x00000007,0x00000008,0x0000009b,0x00000008, + 0x00040017,0x000000b6,0x00000006,0x00000002,0x00040020,0x000000b7,0x00000007,0x000000b6, + 0x00090021,0x000000b8,0x00000006,0x00000007,0x00000094,0x0000009c,0x00000008,0x000000b7, + 0x00000008,0x000b0021,0x000000c1,0x00000007,0x00000007,0x00000007,0x00000094,0x0000009c, + 0x00000008,0x000000b7,0x00000008,0x00000008,0x00050021,0x000000cc,0x00000006,0x00000008, + 0x00000008,0x00070021,0x000000d1,0x000000b6,0x00000007,0x00000008,0x00000008,0x00000008, + 0x00080021,0x000000d8,0x00000006,0x00000007,0x0000009c,0x00000008,0x00000008,0x00000008, + 0x000a0021,0x000000e0,0x00000002,0x00000007,0x00000008,0x0000009c,0x00000008,0x00000008, + 0x0000001c,0x0000001c,0x00040021,0x000000ea,0x00000007,0x0000001c,0x00060021,0x000000ee, + 0x00000007,0x0000001c,0x0000001c,0x0000001c,0x0004002b,0x00000006,0x000000f4,0x00000015, + 0x0004001c,0x000000f5,0x00000007,0x000000f4,0x00040020,0x000000f6,0x00000006,0x000000f5, + 0x0004003b,0x000000f6,0x000000f7,0x00000006,0x0004002b,0x00000006,0x000000f8,0x00000001, + 0x0004002b,0x00000006,0x000000f9,0x00000000,0x0007002c,0x00000007,0x000000fa,0x000000f8, + 0x000000f9,0x000000f9,0x000000f9,0x0004002b,0x00000006,0x000000fb,0x00000002,0x0007002c, + 0x00000007,0x000000fc,0x000000f9,0x000000f8,0x000000f9,0x000000fb,0x0004002b,0x00000006, + 0x000000fd,0x00000005,0x0007002c,0x00000007,0x000000fe,0x000000fb,0x000000f9,0x000000f9, + 0x000000fd,0x0004002b,0x00000006,0x000000ff,0x00000009,0x0007002c,0x00000007,0x00000100, + 0x000000f9,0x000000f9,0x000000f8,0x000000ff,0x0004002b,0x00000006,0x00000101,0x0000000e, + 0x0007002c,0x00000007,0x00000102,0x000000f8,0x000000f8,0x000000f9,0x00000101,0x0004002b, + 0x00000006,0x00000103,0x00000003,0x0004002b,0x00000006,0x00000104,0x00000014,0x0007002c, + 0x00000007,0x00000105,0x00000103,0x000000f9,0x000000f9,0x00000104,0x0004002b,0x00000006, + 0x00000106,0x0000001c,0x0007002c,0x00000007,0x00000107,0x000000f8,0x000000f9,0x000000f8, + 0x00000106,0x0004002b,0x00000006,0x00000108,0x00000026,0x0007002c,0x00000007,0x00000109, + 0x000000fb,0x000000f8,0x000000f9,0x00000108,0x0004002b,0x00000006,0x0000010a,0x00000004, + 0x0004002b,0x00000006,0x0000010b,0x00000032,0x0007002c,0x00000007,0x0000010c,0x0000010a, + 0x000000f9,0x000000f9,0x0000010b,0x0004002b,0x00000006,0x0000010d,0x00000042,0x0007002c, + 0x00000007,0x0000010e,0x000000fb,0x000000f9,0x000000f8,0x0000010d,0x0004002b,0x00000006, + 0x0000010f,0x00000056,0x0007002c,0x00000007,0x00000110,0x00000103,0x000000f8,0x000000f9, + 0x0000010f,0x0004002b,0x00000006,0x00000111,0x0000006e,0x0007002c,0x00000007,0x00000112, + 0x000000fd,0x000000f9,0x000000f9,0x00000111,0x0004002b,0x00000006,0x00000113,0x0000008e, + 0x0007002c,0x00000007,0x00000114,0x00000103,0x000000f9,0x000000f8,0x00000113,0x0004002b, + 0x00000006,0x00000115,0x000000b6,0x0007002c,0x00000007,0x00000116,0x0000010a,0x000000f8, + 0x000000f9,0x00000115,0x0004002b,0x00000006,0x00000117,0x00000006,0x0004002b,0x00000006, + 0x00000118,0x000000e6,0x0007002c,0x00000007,0x00000119,0x00000117,0x000000f9,0x000000f9, + 0x00000118,0x0004002b,0x00000006,0x0000011a,0x00000126,0x0007002c,0x00000007,0x0000011b, + 0x0000010a,0x000000f9,0x000000f8,0x0000011a,0x0004002b,0x00000006,0x0000011c,0x00000176, + 0x0007002c,0x00000007,0x0000011d,0x000000fd,0x000000f8,0x000000f9,0x0000011c,0x0004002b, + 0x00000006,0x0000011e,0x00000007,0x0004002b,0x00000006,0x0000011f,0x000001d6,0x0007002c, + 0x00000007,0x00000120,0x0000011e,0x000000f9,0x000000f9,0x0000011f,0x0004002b,0x00000006, + 0x00000121,0x00000256,0x0007002c,0x00000007,0x00000122,0x000000fd,0x000000f9,0x000000f8, + 0x00000121,0x0004002b,0x00000006,0x00000123,0x000002f6,0x0007002c,0x00000007,0x00000124, + 0x00000117,0x000000f8,0x000000f9,0x00000123,0x0004002b,0x00000006,0x00000125,0x00000008, + 0x0004002b,0x00000006,0x00000126,0x000003b6,0x0007002c,0x00000007,0x00000127,0x00000125, + 0x000000f9,0x000000f9,0x00000126,0x0018002c,0x000000f5,0x00000128,0x000000fa,0x000000fc, + 0x000000fe,0x00000100,0x00000102,0x00000105,0x00000107,0x00000109,0x0000010c,0x0000010e, + 0x00000110,0x00000112,0x00000114,0x00000116,0x00000119,0x0000011b,0x0000011d,0x00000120, + 0x00000122,0x00000124,0x00000127,0x0004002b,0x00000006,0x0000012b,0x00000020,0x00040015, + 0x0000012f,0x00000020,0x00000001,0x0004002b,0x0000012f,0x00000130,0x00000005,0x00040020, + 0x00000133,0x00000007,0x0000012f,0x0004002b,0x0000012f,0x0000013b,0x00000000,0x0004002b, + 0x0000012f,0x00000149,0x00000001,0x0004002b,0x00000006,0x0000016d,0x0000001f,0x00040017, + 0x00000197,0x00000006,0x00000003,0x0004002b,0x00000006,0x00000199,0x000000ff,0x0004002b, + 0x0000012f,0x000001a6,0x00000002,0x0004002b,0x00000006,0x000001a9,0x000000c0,0x0004002b, + 0x00000006,0x000001af,0x0000003f,0x0004002b,0x0000012f,0x000001db,0x00000080,0x0004002b, + 0x0000012f,0x000001e5,0x0000007f,0x0004002b,0x0000012f,0x000001eb,0x00000040,0x0004002b, + 0x0000012f,0x00000211,0x000000ff,0x0004002b,0x0000012f,0x0000023b,0x00000008,0x00040017, + 0x0000023c,0x0000012f,0x00000003,0x00040017,0x00000284,0x0000012f,0x00000004,0x0004001c, + 0x00000285,0x00000284,0x000000fb,0x00040020,0x00000286,0x00000007,0x00000285,0x0007002c, + 0x00000284,0x00000288,0x00000211,0x00000211,0x00000211,0x00000211,0x0005002c,0x00000285, + 0x00000289,0x00000288,0x00000288,0x00040020,0x00000362,0x00000007,0x0000023c,0x00040020, + 0x00000366,0x00000007,0x00000284,0x0006002c,0x0000023c,0x0000036a,0x0000013b,0x0000013b, + 0x0000013b,0x0006002c,0x0000023c,0x0000036b,0x00000211,0x00000211,0x00000211,0x0007002c, + 0x00000284,0x000004b8,0x0000013b,0x0000013b,0x0000013b,0x0000013b,0x0004002b,0x0000012f, + 0x000004c6,0x0000000f,0x0004002b,0x00000006,0x000004ca,0xeede0891,0x0004002b,0x0000012f, + 0x000004d2,0x00000010,0x0004002b,0x0000012f,0x000004d7,0x00000007,0x0004002b,0x0000012f, + 0x000004dc,0x00000003,0x0004002b,0x0000012f,0x000004e1,0x00000006,0x0004002b,0x0000012f, + 0x000004e6,0x00000011,0x0004002b,0x00000006,0x000004ef,0x00000400,0x0004002b,0x00000006, + 0x000004f9,0x0000000f,0x0004002b,0x0000012f,0x000004fd,0x00000004,0x0004002b,0x0000012f, + 0x00000506,0x0000000c,0x0004002b,0x0000012f,0x0000050f,0x00000014,0x0004002b,0x0000012f, + 0x00000514,0x00000018,0x0004002b,0x0000012f,0x00000519,0x0000001c,0x0004002b,0x0000012f, + 0x0000051e,0x00000012,0x0004002b,0x0000012f,0x00000523,0x00000016,0x0004002b,0x0000012f, + 0x00000528,0x0000001a,0x0004002b,0x0000012f,0x0000052d,0x0000001e,0x0004002b,0x00000006, + 0x00000573,0x00000010,0x0004002b,0x0000012f,0x000005aa,0x0000000e,0x0004002b,0x0000012f, + 0x000005ba,0x0000000a,0x00040032,0x00000006,0x00000611,0x00000001,0x00040032,0x00000006, + 0x00000612,0x00000001,0x00060033,0x00000197,0x00000613,0x00000611,0x00000612,0x000000f8, + 0x00060034,0x00000006,0x00000614,0x00000051,0x00000613,0x00000000,0x00060034,0x00000006, + 0x00000615,0x00000051,0x00000613,0x00000001,0x00060034,0x00000006,0x00000616,0x00000084, + 0x00000614,0x00000615,0x00060034,0x00000006,0x00000617,0x00000051,0x00000613,0x00000002, + 0x00060034,0x00000006,0x00000618,0x00000084,0x00000616,0x00000617,0x00060034,0x00000093, + 0x00000619,0x000000b0,0x00000618,0x0000012b,0x0004002b,0x00000006,0x0000064d,0x00000033, + 0x0004002b,0x00000006,0x00000655,0x00000055,0x00040020,0x0000065c,0x00000004,0x00000007, + 0x0004003b,0x0000065c,0x0000065d,0x00000004,0x00040020,0x00000660,0x00000004,0x00000006, + 0x0004002b,0x0000012f,0x0000066c,0x00000009,0x0004002b,0x00000006,0x000006aa,0x00000100, + 0x00030029,0x00000093,0x000006c7,0x00040020,0x000006c8,0x00000007,0x00000093,0x0004002b, + 0x00000006,0x000006d4,0x0000000c,0x0004002b,0x00000006,0x000006f9,0x0000000a,0x00040020, + 0x00000735,0x00000006,0x00000007,0x0004001c,0x0000080a,0x00000006,0x000000fd,0x0004001c, + 0x0000080b,0x0000080a,0x000006aa,0x0004001c,0x0000080c,0x00000006,0x00000103,0x0004002b, + 0x00000006,0x0000080d,0x00000080,0x0004001c,0x0000080e,0x0000080c,0x0000080d,0x0004001e, + 0x0000080f,0x0000080b,0x0000080e,0x00040020,0x00000810,0x00000002,0x0000080f,0x0004003b, + 0x00000810,0x00000811,0x00000002,0x00040020,0x00000814,0x00000002,0x00000006,0x0004001c, + 0x000008c9,0x00000006,0x00000113,0x0003001e,0x000008ca,0x000008c9,0x00040020,0x000008cb, + 0x00000002,0x000008ca,0x0004003b,0x000008cb,0x000008cc,0x00000002,0x00080034,0x000000b6, + 0x000008d5,0x0000004f,0x00000613,0x00000613,0x00000000,0x00000001,0x00060034,0x00000006, + 0x000008d6,0x00000051,0x000008d5,0x00000000,0x00060034,0x00000006,0x000008d7,0x00000051, + 0x000008d5,0x00000001,0x00050033,0x000000b6,0x000008d8,0x000008d6,0x000008d7,0x00040017, + 0x000008d9,0x0000012f,0x00000002,0x0005002c,0x000008d9,0x000008da,0x00000149,0x00000149, + 0x00060034,0x000000b6,0x000008db,0x000000c2,0x000008d8,0x000008da,0x0005002c,0x000000b6, + 0x000008dc,0x000004ef,0x000004ef,0x00060034,0x000000b6,0x000008dd,0x00000080,0x000008dc, + 0x000008db,0x00060034,0x00000006,0x000008de,0x00000051,0x000008dd,0x00000000,0x00060034, + 0x00000006,0x000008df,0x00000051,0x000008dd,0x00000001,0x00050033,0x000000b6,0x000008e0, + 0x000008de,0x000008df,0x00080034,0x000000b6,0x000008e1,0x0000004f,0x00000613,0x00000613, + 0x00000000,0x00000001,0x0005002c,0x000000b6,0x000008e2,0x000000f8,0x000000f8,0x00060034, + 0x000000b6,0x000008e3,0x00000082,0x000008e1,0x000008e2,0x00060034,0x00000006,0x000008e4, + 0x00000051,0x000008e3,0x00000000,0x00060034,0x00000006,0x000008e5,0x00000051,0x000008e3, + 0x00000001,0x00050033,0x000000b6,0x000008e6,0x000008e4,0x000008e5,0x00060034,0x000000b6, + 0x000008e7,0x00000086,0x000008e0,0x000008e6,0x0007002c,0x00000007,0x000009b0,0x000000f9, + 0x000000f8,0x000000fb,0x00000103,0x00040017,0x000009b1,0x00000093,0x00000004,0x0004002b, + 0x00000006,0x000009e5,0x0000000d,0x0004002b,0x00000006,0x00000a40,0x000004b6,0x0004001c, + 0x00000a41,0x00000006,0x00000a40,0x0004001c,0x00000a42,0x0000012f,0x0000080d,0x0004002b, + 0x00000006,0x00000a43,0x00000011,0x0004001c,0x00000a44,0x00000a42,0x00000a43,0x0004001e, + 0x00000a45,0x00000a41,0x00000a44,0x00040020,0x00000a46,0x00000002,0x00000a45,0x0004003b, + 0x00000a46,0x00000a47,0x00000002,0x0004002b,0x00000006,0x00000b73,0x00000101,0x00030016, + 0x00000b7a,0x00000020,0x00040020,0x00000b7b,0x00000007,0x00000b7a,0x0004002b,0x00000b7a, + 0x00000b89,0x3b4d2e1c,0x0004002b,0x00000b7a,0x00000b8e,0x414eb852,0x0004002b,0x00000b7a, + 0x00000b92,0x3f800000,0x0004002b,0x00000b7a,0x00000b96,0x3f870a3d,0x0004002b,0x00000b7a, + 0x00000b98,0x3ed55555,0x0004002b,0x00000b7a,0x00000b9b,0x3d6147ae,0x00030031,0x00000093, + 0x00000bca,0x0004002b,0x00000006,0x00000bd5,0x00000040,0x00040020,0x00000bf2,0x00000001, + 0x00000197,0x0004003b,0x00000bf2,0x00000bf3,0x00000001,0x00040020,0x00000bf4,0x00000001, + 0x00000006,0x0004003b,0x00000bf4,0x00000c00,0x00000001,0x0004003b,0x00000bf2,0x00000c03, + 0x00000001,0x00040020,0x00000c09,0x00000007,0x000008d9,0x0004003b,0x00000bf2,0x00000c0b, + 0x00000001,0x0007002c,0x00000007,0x00000c17,0x000000f9,0x000000f9,0x000000f9,0x000000f9, + 0x00030031,0x00000093,0x00000c18,0x00060034,0x00000093,0x00000c19,0x000000a4,0x00000c18, + 0x000006c7,0x0004003b,0x0000065c,0x00000c1c,0x00000004,0x00090019,0x00000c1d,0x00000006, + 0x00000005,0x00000000,0x00000000,0x00000000,0x00000001,0x00000000,0x00040020,0x00000c1e, + 0x00000000,0x00000c1d,0x0004003b,0x00000c1e,0x00000c1f,0x00000000,0x0004003b,0x00000bf2, + 0x00000c24,0x00000001,0x00090019,0x00000c34,0x00000006,0x00000001,0x00000000,0x00000000, + 0x00000000,0x00000002,0x0000001e,0x00040020,0x00000c35,0x00000000,0x00000c34,0x0004003b, + 0x00000c35,0x00000c36,0x00000000,0x0004003b,0x00000660,0x00000c3a,0x00000004,0x0004002b, + 0x00000006,0x00000c3c,0x0000000b,0x00040020,0x00000c41,0x00000004,0x00000094,0x0004003b, + 0x00000c41,0x00000c42,0x00000004,0x0004003b,0x00000660,0x00000c4d,0x00000004,0x0004003b, + 0x00000660,0x00000c57,0x00000004,0x0004002b,0x00000006,0x00000c5e,0x00000017,0x0004002b, + 0x00000006,0x00000c67,0x00000108,0x0004003b,0x00000660,0x00000c6f,0x00000004,0x0004002b, + 0x00000006,0x00000c77,0x000001ff,0x0004002b,0x00000006,0x00000c79,0x000001fc,0x0004002b, + 0x00000006,0x00000c80,0x0000ffff,0x00040017,0x00000c8c,0x00000b7a,0x00000004,0x00040020, + 0x00000c8d,0x00000007,0x00000c8c,0x0004002b,0x00000b7a,0x00000c91,0x47800000,0x00090019, + 0x00000c94,0x00000b7a,0x00000001,0x00000000,0x00000000,0x00000000,0x00000002,0x00000000, + 0x00040020,0x00000c95,0x00000000,0x00000c94,0x0004003b,0x00000c95,0x00000c96,0x00000000, + 0x0004002b,0x00000006,0x00000cc4,0x00000063,0x0004002b,0x00000006,0x00000cca,0x0000006f, + 0x0004002b,0x00000006,0x00000ce4,0x00000012,0x00040020,0x00000cf7,0x00000002,0x0000012f, + 0x0004002b,0x0000012f,0x00000d2f,0x0000001d,0x00050036,0x00000002,0x00000004,0x00000000, + 0x00000003,0x000200f8,0x00000005,0x0004003b,0x00000362,0x00000bf1,0x00000007,0x0004003b, + 0x00000008,0x00000bff,0x00000007,0x0004003b,0x000000b7,0x00000c02,0x00000007,0x0004003b, + 0x00000c09,0x00000c0a,0x00000007,0x0004003b,0x00000008,0x00000c3d,0x00000007,0x0004003b, + 0x00000008,0x00000c3e,0x00000007,0x0004003b,0x00000095,0x00000c43,0x00000007,0x0004003b, + 0x00000008,0x00000c48,0x00000007,0x0004003b,0x00000008,0x00000c49,0x00000007,0x0004003b, + 0x00000008,0x00000c54,0x00000007,0x0004003b,0x00000008,0x00000c55,0x00000007,0x0004003b, + 0x00000008,0x00000c5f,0x00000007,0x0004003b,0x00000008,0x00000c60,0x00000007,0x0004003b, + 0x00000008,0x00000c64,0x00000007,0x0004003b,0x00000008,0x00000c65,0x00000007,0x0004003b, + 0x0000009c,0x00000c68,0x00000007,0x0004003b,0x00000008,0x00000c69,0x00000007,0x0004003b, + 0x0000009c,0x00000c6c,0x00000007,0x0004003b,0x00000008,0x00000c70,0x00000007,0x0004003b, + 0x0000009c,0x00000c73,0x00000007,0x0004003b,0x0000001c,0x00000c7d,0x00000007,0x0004003b, + 0x00000c8d,0x00000c8e,0x00000007,0x0004003b,0x00000008,0x00000c9d,0x00000007,0x0004003b, + 0x0000001c,0x00000ca0,0x00000007,0x0004003b,0x0000009c,0x00000ca4,0x00000007,0x0004003b, + 0x00000008,0x00000ca6,0x00000007,0x0004003b,0x000000b7,0x00000ca8,0x00000007,0x0004003b, + 0x00000008,0x00000caa,0x00000007,0x0004003b,0x00000008,0x00000cac,0x00000007,0x0004003b, + 0x00000008,0x00000caf,0x00000007,0x0004003b,0x00000008,0x00000cb7,0x00000007,0x0004003b, + 0x00000008,0x00000cbd,0x00000007,0x0004003b,0x00000008,0x00000cc1,0x00000007,0x0004003b, + 0x00000008,0x00000cce,0x00000007,0x0004003b,0x00000008,0x00000ccf,0x00000007,0x0004003b, + 0x00000008,0x00000cd2,0x00000007,0x0004003b,0x00000008,0x00000cd4,0x00000007,0x0004003b, + 0x00000008,0x00000cd7,0x00000007,0x0004003b,0x00000008,0x00000cda,0x00000007,0x0004003b, + 0x00000008,0x00000cdc,0x00000007,0x0004003b,0x00000008,0x00000cdd,0x00000007,0x0004003b, + 0x00000008,0x00000ce0,0x00000007,0x0004003b,0x00000008,0x00000ceb,0x00000007,0x0004003b, + 0x00000133,0x00000cf3,0x00000007,0x0004003b,0x0000009c,0x00000d00,0x00000007,0x0004003b, + 0x00000008,0x00000d01,0x00000007,0x0004003b,0x0000009c,0x00000d02,0x00000007,0x0004003b, + 0x00000008,0x00000d05,0x00000007,0x0004003b,0x00000008,0x00000d0b,0x00000007,0x0004003b, + 0x00000008,0x00000d11,0x00000007,0x0004003b,0x00000008,0x00000d13,0x00000007,0x0004003b, + 0x000000b7,0x00000d19,0x00000007,0x0004003b,0x00000008,0x00000d1b,0x00000007,0x0004003b, + 0x00000008,0x00000d1d,0x00000007,0x0004003b,0x00000008,0x00000d20,0x00000007,0x0004003b, + 0x00000008,0x00000d25,0x00000007,0x0004003b,0x00000008,0x00000d26,0x00000007,0x0004003b, + 0x00000008,0x00000d29,0x00000007,0x0004003b,0x00000008,0x00000d2b,0x00000007,0x0004003b, + 0x0000001c,0x00000d33,0x00000007,0x0004003b,0x0000001c,0x00000d34,0x00000007,0x0004003b, + 0x00000008,0x00000d35,0x00000007,0x0004003b,0x0000009c,0x00000d37,0x00000007,0x0004003b, + 0x00000008,0x00000d39,0x00000007,0x0004003b,0x00000008,0x00000d3c,0x00000007,0x0004003b, + 0x0000001c,0x00000d3f,0x00000007,0x0004003b,0x0000001c,0x00000d40,0x00000007,0x0004003b, + 0x0000001c,0x00000d44,0x00000007,0x0004003b,0x0000001c,0x00000d45,0x00000007,0x0004003b, + 0x0000001c,0x00000d47,0x00000007,0x0004003b,0x0000001c,0x00000d49,0x00000007,0x0004003b, + 0x00000c8d,0x00000d4c,0x00000007,0x0003003e,0x000000f7,0x00000128,0x00050041,0x00000bf4, + 0x00000bf5,0x00000bf3,0x000000f9,0x0004003d,0x00000006,0x00000bf6,0x00000bf5,0x0004007c, + 0x0000012f,0x00000bf7,0x00000bf6,0x00050041,0x00000bf4,0x00000bf8,0x00000bf3,0x000000f8, + 0x0004003d,0x00000006,0x00000bf9,0x00000bf8,0x0004007c,0x0000012f,0x00000bfa,0x00000bf9, + 0x00050041,0x00000bf4,0x00000bfb,0x00000bf3,0x000000fb,0x0004003d,0x00000006,0x00000bfc, + 0x00000bfb,0x0004007c,0x0000012f,0x00000bfd,0x00000bfc,0x00060050,0x0000023c,0x00000bfe, + 0x00000bf7,0x00000bfa,0x00000bfd,0x0003003e,0x00000bf1,0x00000bfe,0x0004003d,0x00000006, + 0x00000c01,0x00000c00,0x0003003e,0x00000bff,0x00000c01,0x0004003d,0x00000197,0x00000c04, + 0x00000c03,0x0007004f,0x000000b6,0x00000c05,0x00000c04,0x00000c04,0x00000000,0x00000001, + 0x00050051,0x00000006,0x00000c06,0x00000c05,0x00000000,0x00050051,0x00000006,0x00000c07, + 0x00000c05,0x00000001,0x00050050,0x000000b6,0x00000c08,0x00000c06,0x00000c07,0x0003003e, + 0x00000c02,0x00000c08,0x00050041,0x00000bf4,0x00000c0c,0x00000c0b,0x000000f9,0x0004003d, + 0x00000006,0x00000c0d,0x00000c0c,0x0004007c,0x0000012f,0x00000c0e,0x00000c0d,0x00050041, + 0x00000bf4,0x00000c0f,0x00000c0b,0x000000f8,0x0004003d,0x00000006,0x00000c10,0x00000c0f, + 0x0004007c,0x0000012f,0x00000c11,0x00000c10,0x00050050,0x000008d9,0x00000c12,0x00000c0e, + 0x00000c11,0x0003003e,0x00000c0a,0x00000c12,0x0004003d,0x00000006,0x00000c13,0x00000bff, + 0x000500aa,0x00000093,0x00000c14,0x00000c13,0x000000f9,0x000300f7,0x00000c16,0x00000000, + 0x000400fa,0x00000c14,0x00000c15,0x00000c16,0x000200f8,0x00000c15,0x0003003e,0x0000065d, + 0x00000c17,0x000300f7,0x00000c1b,0x00000000,0x000400fa,0x00000c19,0x00000c1a,0x00000c33, + 0x000200f8,0x00000c1a,0x0004003d,0x00000c1d,0x00000c20,0x00000c1f,0x00050041,0x00000133, + 0x00000c21,0x00000c0a,0x000000f8,0x0004003d,0x0000012f,0x00000c22,0x00000c21,0x0004007c, + 0x00000006,0x00000c23,0x00000c22,0x00050041,0x00000bf4,0x00000c25,0x00000c24,0x000000f9, + 0x0004003d,0x00000006,0x00000c26,0x00000c25,0x00050084,0x00000006,0x00000c27,0x00000c23, + 0x00000c26,0x00050041,0x00000133,0x00000c28,0x00000c0a,0x000000f9,0x0004003d,0x0000012f, + 0x00000c29,0x00000c28,0x0004007c,0x00000006,0x00000c2a,0x00000c29,0x00050080,0x00000006, + 0x00000c2b,0x00000c27,0x00000c2a,0x0004007c,0x0000012f,0x00000c2c,0x00000c2b,0x0005005f, + 0x00000007,0x00000c2d,0x00000c20,0x00000c2c,0x00050051,0x00000006,0x00000c2e,0x00000c2d, + 0x00000000,0x00050051,0x00000006,0x00000c2f,0x00000c2d,0x00000001,0x00050051,0x00000006, + 0x00000c30,0x00000c2d,0x00000002,0x00050051,0x00000006,0x00000c31,0x00000c2d,0x00000003, + 0x00070050,0x00000007,0x00000c32,0x00000c2e,0x00000c2f,0x00000c30,0x00000c31,0x0003003e, + 0x00000c1c,0x00000c32,0x000200f9,0x00000c1b,0x000200f8,0x00000c33,0x0004003d,0x00000c34, + 0x00000c37,0x00000c36,0x0004003d,0x000008d9,0x00000c38,0x00000c0a,0x00050062,0x00000007, + 0x00000c39,0x00000c37,0x00000c38,0x0003003e,0x00000c1c,0x00000c39,0x000200f9,0x00000c1b, + 0x000200f8,0x00000c1b,0x0004003d,0x00000007,0x00000c3b,0x00000c1c,0x0003003e,0x00000c3d, + 0x00000c3c,0x0003003e,0x00000c3e,0x000000f9,0x00070039,0x00000006,0x00000c3f,0x0000000d, + 0x00000c3b,0x00000c3d,0x00000c3e,0x0003003e,0x00000c3a,0x00000c3f,0x0004003d,0x00000006, + 0x00000c40,0x00000c3a,0x0004003d,0x00000094,0x00000c44,0x00000c42,0x0003003e,0x00000c43, + 0x00000c44,0x00060039,0x00000002,0x00000c45,0x00000099,0x00000c40,0x00000c43,0x0004003d, + 0x00000094,0x00000c46,0x00000c43,0x0003003e,0x00000c42,0x00000c46,0x0004003d,0x00000007, + 0x00000c47,0x00000c1c,0x0003003e,0x00000c48,0x000000fb,0x0003003e,0x00000c49,0x00000c3c, + 0x00070039,0x00000006,0x00000c4a,0x0000000d,0x00000c47,0x00000c48,0x00000c49,0x00050080, + 0x00000006,0x00000c4b,0x00000c4a,0x000000f8,0x00050041,0x00000660,0x00000c4c,0x00000c42, + 0x000004fd,0x0003003e,0x00000c4c,0x00000c4b,0x0003003e,0x00000c4d,0x000000f9,0x00050041, + 0x00000660,0x00000c4e,0x00000c42,0x000004fd,0x0004003d,0x00000006,0x00000c4f,0x00000c4e, + 0x000500ac,0x00000093,0x00000c50,0x00000c4f,0x000000f8,0x000300f7,0x00000c52,0x00000000, + 0x000400fa,0x00000c50,0x00000c51,0x00000c52,0x000200f8,0x00000c51,0x0004003d,0x00000007, + 0x00000c53,0x00000c1c,0x0003003e,0x00000c54,0x000006f9,0x0003003e,0x00000c55,0x000009e5, + 0x00070039,0x00000006,0x00000c56,0x0000000d,0x00000c53,0x00000c54,0x00000c55,0x0003003e, + 0x00000c4d,0x00000c56,0x000200f9,0x00000c52,0x000200f8,0x00000c52,0x0003003e,0x00000c57, + 0x000000f9,0x00050041,0x00000660,0x00000c58,0x00000c42,0x000004fd,0x0004003d,0x00000006, + 0x00000c59,0x00000c58,0x000500ac,0x00000093,0x00000c5a,0x00000c59,0x000000f8,0x000300f7, + 0x00000c5c,0x00000000,0x000400fa,0x00000c5a,0x00000c5b,0x00000c62,0x000200f8,0x00000c5b, + 0x0004003d,0x00000007,0x00000c5d,0x00000c1c,0x0003003e,0x00000c5f,0x00000117,0x0003003e, + 0x00000c60,0x00000c5e,0x00070039,0x00000006,0x00000c61,0x0000000d,0x00000c5d,0x00000c5f, + 0x00000c60,0x0003003e,0x00000c57,0x00000c61,0x000200f9,0x00000c5c,0x000200f8,0x00000c62, + 0x0004003d,0x00000007,0x00000c63,0x00000c1c,0x0003003e,0x00000c64,0x0000010a,0x0003003e, + 0x00000c65,0x000009e5,0x00070039,0x00000006,0x00000c66,0x0000000d,0x00000c63,0x00000c64, + 0x00000c65,0x0003003e,0x00000c57,0x00000c66,0x000200f9,0x00000c5c,0x000200f8,0x00000c5c, + 0x000200f9,0x00000c16,0x000200f8,0x00000c16,0x000400e0,0x000000fb,0x000000fb,0x00000c67, + 0x00050041,0x00000660,0x00000c6a,0x00000c42,0x000004dc,0x0004003d,0x00000006,0x00000c6b, + 0x00000c6a,0x0003003e,0x00000c69,0x00000c6b,0x00060039,0x00000002,0x00000c6d,0x000000a5, + 0x00000c69,0x00000c6c,0x0004003d,0x0000009b,0x00000c6e,0x00000c6c,0x0003003e,0x00000c68, + 0x00000c6e,0x00050041,0x00000660,0x00000c71,0x00000c42,0x000001a6,0x0004003d,0x00000006, + 0x00000c72,0x00000c71,0x0003003e,0x00000c70,0x00000c72,0x0004003d,0x0000009b,0x00000c74, + 0x00000c68,0x0003003e,0x00000c73,0x00000c74,0x00060039,0x00000006,0x00000c75,0x000000a0, + 0x00000c70,0x00000c73,0x0003003e,0x00000c6f,0x00000c75,0x0004003d,0x00000006,0x00000c76, + 0x00000c3a,0x000500c7,0x00000006,0x00000c78,0x00000c76,0x00000c77,0x000500aa,0x00000093, + 0x00000c7a,0x00000c78,0x00000c79,0x000300f7,0x00000c7c,0x00000000,0x000400fa,0x00000c7a, + 0x00000c7b,0x00000c7c,0x000200f8,0x00000c7b,0x00050041,0x00000660,0x00000c7e,0x00000c1c, + 0x000000fb,0x0004003d,0x00000006,0x00000c7f,0x00000c7e,0x000500c7,0x00000006,0x00000c81, + 0x00000c7f,0x00000c80,0x00050041,0x00000660,0x00000c82,0x00000c1c,0x000000fb,0x0004003d, + 0x00000006,0x00000c83,0x00000c82,0x000500c2,0x00000006,0x00000c84,0x00000c83,0x00000573, + 0x00050041,0x00000660,0x00000c85,0x00000c1c,0x00000103,0x0004003d,0x00000006,0x00000c86, + 0x00000c85,0x000500c7,0x00000006,0x00000c87,0x00000c86,0x00000c80,0x00050041,0x00000660, + 0x00000c88,0x00000c1c,0x00000103,0x0004003d,0x00000006,0x00000c89,0x00000c88,0x000500c2, + 0x00000006,0x00000c8a,0x00000c89,0x00000573,0x00070050,0x00000007,0x00000c8b,0x00000c81, + 0x00000c84,0x00000c87,0x00000c8a,0x0003003e,0x00000c7d,0x00000c8b,0x0004003d,0x00000007, + 0x00000c8f,0x00000c7d,0x00040070,0x00000c8c,0x00000c90,0x00000c8f,0x00070050,0x00000c8c, + 0x00000c92,0x00000c91,0x00000c91,0x00000c91,0x00000c91,0x00050088,0x00000c8c,0x00000c93, + 0x00000c90,0x00000c92,0x0003003e,0x00000c8e,0x00000c93,0x0004003d,0x00000c94,0x00000c97, + 0x00000c96,0x0004003d,0x0000023c,0x00000c98,0x00000bf1,0x0007004f,0x000008d9,0x00000c99, + 0x00000c98,0x00000c98,0x00000000,0x00000001,0x0004003d,0x00000c8c,0x00000c9a,0x00000c8e, + 0x00040063,0x00000c97,0x00000c99,0x00000c9a,0x000100fd,0x000200f8,0x00000c7c,0x0004003d, + 0x00000007,0x00000c9c,0x00000c1c,0x0004003d,0x00000006,0x00000c9e,0x00000bff,0x0003003e, + 0x00000c9d,0x00000c9e,0x00060039,0x00000002,0x00000c9f,0x00000091,0x00000c9c,0x00000c9d, + 0x000400e0,0x000000fb,0x000000fb,0x00000c67,0x0004003d,0x00000007,0x00000ca1,0x00000c1c, + 0x0004003d,0x00000007,0x00000ca2,0x0000065d,0x0004003d,0x00000094,0x00000ca3,0x00000c42, + 0x0004003d,0x0000009b,0x00000ca5,0x00000c68,0x0003003e,0x00000ca4,0x00000ca5,0x0004003d, + 0x00000006,0x00000ca7,0x00000c6f,0x0003003e,0x00000ca6,0x00000ca7,0x0004003d,0x000000b6, + 0x00000ca9,0x00000c02,0x0003003e,0x00000ca8,0x00000ca9,0x0004003d,0x00000006,0x00000cab, + 0x00000c57,0x0003003e,0x00000caa,0x00000cab,0x0004003d,0x00000006,0x00000cad,0x00000c6f, + 0x0003003e,0x00000cac,0x00000cad,0x000c0039,0x00000007,0x00000cae,0x000000ca,0x00000ca1, + 0x00000ca2,0x00000ca3,0x00000ca4,0x00000ca6,0x00000ca8,0x00000caa,0x00000cac,0x0003003e, + 0x00000ca0,0x00000cae,0x00050041,0x00000660,0x00000cb0,0x00000c42,0x000004fd,0x0004003d, + 0x00000006,0x00000cb1,0x00000cb0,0x00050084,0x00000006,0x00000cb2,0x00000103,0x00000cb1, + 0x00050082,0x00000006,0x00000cb3,0x00000cb2,0x0000010a,0x0004007c,0x0000012f,0x00000cb4, + 0x00000cb3,0x0007000c,0x0000012f,0x00000cb5,0x00000001,0x0000002a,0x0000013b,0x00000cb4, + 0x0004007c,0x00000006,0x00000cb6,0x00000cb5,0x0003003e,0x00000caf,0x00000cb6,0x0004003d, + 0x00000006,0x00000cb8,0x00000c57,0x000500c7,0x00000006,0x00000cb9,0x00000cb8,0x00000103, + 0x000500ab,0x00000093,0x00000cba,0x00000cb9,0x000000f9,0x0004003d,0x00000006,0x00000cbb, + 0x00000caf,0x000600a9,0x00000006,0x00000cbc,0x00000cba,0x00000cbb,0x000000f9,0x0003003e, + 0x00000cb7,0x00000cbc,0x00050041,0x00000660,0x00000cbe,0x00000c42,0x000004fd,0x0004003d, + 0x00000006,0x00000cbf,0x00000cbe,0x000500ac,0x00000093,0x00000cc0,0x00000cbf,0x000000f8, + 0x000300f7,0x00000cc3,0x00000000,0x000400fa,0x00000cc0,0x00000cc2,0x00000cc9,0x000200f8, + 0x00000cc2,0x0004003d,0x00000006,0x00000cc5,0x00000c6f,0x00050082,0x00000006,0x00000cc6, + 0x00000cc4,0x00000cc5,0x0004003d,0x00000006,0x00000cc7,0x00000cb7,0x00050082,0x00000006, + 0x00000cc8,0x00000cc6,0x00000cc7,0x0003003e,0x00000cc1,0x00000cc8,0x000200f9,0x00000cc3, + 0x000200f8,0x00000cc9,0x0004003d,0x00000006,0x00000ccb,0x00000c6f,0x00050082,0x00000006, + 0x00000ccc,0x00000cca,0x00000ccb,0x0003003e,0x00000cc1,0x00000ccc,0x000200f9,0x00000cc3, + 0x000200f8,0x00000cc3,0x0004003d,0x00000006,0x00000ccd,0x00000cc1,0x0003003e,0x00000cbd, + 0x00000ccd,0x00050041,0x00000660,0x00000cd0,0x00000c42,0x000004fd,0x0004003d,0x00000006, + 0x00000cd1,0x00000cd0,0x0003003e,0x00000ccf,0x00000cd1,0x0004003d,0x00000006,0x00000cd3, + 0x00000c4d,0x0003003e,0x00000cd2,0x00000cd3,0x00050041,0x00000bf4,0x00000cd5,0x00000c03, + 0x000000f9,0x0004003d,0x00000006,0x00000cd6,0x00000cd5,0x0003003e,0x00000cd4,0x00000cd6, + 0x00050041,0x00000bf4,0x00000cd8,0x00000c03,0x000000f8,0x0004003d,0x00000006,0x00000cd9, + 0x00000cd8,0x0003003e,0x00000cd7,0x00000cd9,0x0003003e,0x00000cda,0x000000f9,0x00090039, + 0x00000006,0x00000cdb,0x0000008c,0x00000ccf,0x00000cd2,0x00000cd4,0x00000cd7,0x00000cda, + 0x0003003e,0x00000cce,0x00000cdb,0x00050041,0x00000660,0x00000cde,0x00000c42,0x000004fd, + 0x0004003d,0x00000006,0x00000cdf,0x00000cde,0x0003003e,0x00000cdd,0x00000cdf,0x0004003d, + 0x00000006,0x00000ce1,0x00000c57,0x0003003e,0x00000ce0,0x00000ce1,0x00060039,0x00000006, + 0x00000ce2,0x000000cf,0x00000cdd,0x00000ce0,0x0003003e,0x00000cdc,0x00000ce2,0x0004003d, + 0x00000006,0x00000ce3,0x00000cdc,0x000500ac,0x00000093,0x00000ce5,0x00000ce3,0x00000ce4, + 0x000300f7,0x00000ce7,0x00000000,0x000400fa,0x00000ce5,0x00000ce6,0x00000ce7,0x000200f8, + 0x00000ce6,0x000200f9,0x00000ce7,0x000200f8,0x00000ce7,0x00050041,0x00000660,0x00000ce8, + 0x00000c42,0x00000130,0x0004003d,0x00000006,0x00000ce9,0x00000ce8,0x000500aa,0x00000093, + 0x00000cea,0x00000ce9,0x000000f8,0x000300f7,0x00000ced,0x00000000,0x000400fa,0x00000cea, + 0x00000cec,0x00000cf0,0x000200f8,0x00000cec,0x0004003d,0x00000006,0x00000cee,0x00000cbd, + 0x00050082,0x00000006,0x00000cef,0x00000cee,0x000000fb,0x0003003e,0x00000ceb,0x00000cef, + 0x000200f9,0x00000ced,0x000200f8,0x00000cf0,0x0004003d,0x00000006,0x00000cf1,0x00000cbd, + 0x0003003e,0x00000ceb,0x00000cf1,0x000200f9,0x00000ced,0x000200f8,0x00000ced,0x0004003d, + 0x00000006,0x00000cf2,0x00000ceb,0x0003003e,0x00000cbd,0x00000cf2,0x0004003d,0x00000006, + 0x00000cf4,0x00000cdc,0x00050086,0x00000006,0x00000cf5,0x00000cf4,0x000000fb,0x0004003d, + 0x00000006,0x00000cf6,0x00000cbd,0x00070041,0x00000cf7,0x00000cf8,0x00000a47,0x00000149, + 0x00000cf5,0x00000cf6,0x0004003d,0x0000012f,0x00000cf9,0x00000cf8,0x0003003e,0x00000cf3, + 0x00000cf9,0x0004003d,0x0000012f,0x00000cfa,0x00000cf3,0x000500b1,0x00000093,0x00000cfb, + 0x00000cfa,0x000004fd,0x000300f7,0x00000cfd,0x00000000,0x000400fa,0x00000cfb,0x00000cfc, + 0x00000cfd,0x000200f8,0x00000cfc,0x000200f9,0x00000cfd,0x000200f8,0x00000cfd,0x0004003d, + 0x0000012f,0x00000cfe,0x00000cf3,0x0004007c,0x00000006,0x00000cff,0x00000cfe,0x0003003e, + 0x00000d01,0x00000cff,0x00060039,0x00000002,0x00000d03,0x000000a5,0x00000d01,0x00000d02, + 0x0004003d,0x0000009b,0x00000d04,0x00000d02,0x0003003e,0x00000d00,0x00000d04,0x0003003e, + 0x00000d05,0x000000f9,0x00050041,0x00000660,0x00000d06,0x00000c42,0x000004fd,0x0004003d, + 0x00000006,0x00000d07,0x00000d06,0x000500ac,0x00000093,0x00000d08,0x00000d07,0x000000f8, + 0x000300f7,0x00000d0a,0x00000000,0x000400fa,0x00000d08,0x00000d09,0x00000d23,0x000200f8, + 0x00000d09,0x0004003d,0x00000007,0x00000d0c,0x00000c1c,0x0004003d,0x00000006,0x00000d0d, + 0x00000c6f,0x00050082,0x00000006,0x00000d0e,0x0000080d,0x00000d0d,0x0004003d,0x00000006, + 0x00000d0f,0x00000caf,0x00050082,0x00000006,0x00000d10,0x00000d0e,0x00000d0f,0x0004003d, + 0x00000006,0x00000d12,0x00000caf,0x0003003e,0x00000d11,0x00000d12,0x0003003e,0x00000d13, + 0x00000d10,0x00070039,0x00000006,0x00000d14,0x0000000d,0x00000d0c,0x00000d11,0x00000d13, + 0x0003003e,0x00000d0b,0x00000d14,0x0004003d,0x00000006,0x00000d15,0x00000d0b,0x000500c4, + 0x00000006,0x00000d16,0x00000d15,0x000004e1,0x0004003d,0x00000006,0x00000d17,0x00000c57, + 0x000500c5,0x00000006,0x00000d18,0x00000d16,0x00000d17,0x0003003e,0x00000d05,0x00000d18, + 0x0004003d,0x00000007,0x00000d1a,0x00000c1c,0x0004003d,0x00000006,0x00000d1c,0x00000d05, + 0x0003003e,0x00000d1b,0x00000d1c,0x00050041,0x00000660,0x00000d1e,0x00000c42,0x000004fd, + 0x0004003d,0x00000006,0x00000d1f,0x00000d1e,0x0003003e,0x00000d1d,0x00000d1f,0x0004003d, + 0x00000006,0x00000d21,0x00000cce,0x0003003e,0x00000d20,0x00000d21,0x00080039,0x000000b6, + 0x00000d22,0x000000d6,0x00000d1a,0x00000d1b,0x00000d1d,0x00000d20,0x0003003e,0x00000d19, + 0x00000d22,0x000200f9,0x00000d0a,0x000200f8,0x00000d23,0x0004003d,0x00000007,0x00000d24, + 0x00000c1c,0x0003003e,0x00000d25,0x000000f9,0x00050041,0x00000660,0x00000d27,0x00000c42, + 0x000004fd,0x0004003d,0x00000006,0x00000d28,0x00000d27,0x0003003e,0x00000d26,0x00000d28, + 0x0003003e,0x00000d29,0x000000f9,0x00080039,0x000000b6,0x00000d2a,0x000000d6,0x00000d24, + 0x00000d25,0x00000d26,0x00000d29,0x0003003e,0x00000d19,0x00000d2a,0x000200f9,0x00000d0a, + 0x000200f8,0x00000d0a,0x00050041,0x00000660,0x00000d2c,0x00000c42,0x000004fd,0x0004003d, + 0x00000006,0x00000d2d,0x00000d2c,0x000500ac,0x00000093,0x00000d2e,0x00000d2d,0x000000f8, + 0x000600a9,0x0000012f,0x00000d30,0x00000d2e,0x00000d2f,0x000004e6,0x0004007c,0x00000006, + 0x00000d31,0x00000d30,0x0003003e,0x00000d2b,0x00000d31,0x0004003d,0x00000007,0x00000d32, + 0x00000c1c,0x0004003d,0x00000006,0x00000d36,0x00000d2b,0x0003003e,0x00000d35,0x00000d36, + 0x0004003d,0x0000009b,0x00000d38,0x00000d00,0x0003003e,0x00000d37,0x00000d38,0x00050041, + 0x00000008,0x00000d3a,0x00000d19,0x000000f9,0x0004003d,0x00000006,0x00000d3b,0x00000d3a, + 0x0003003e,0x00000d39,0x00000d3b,0x00050041,0x00000008,0x00000d3d,0x00000d19,0x000000f8, + 0x0004003d,0x00000006,0x00000d3e,0x00000d3d,0x0003003e,0x00000d3c,0x00000d3e,0x000b0039, + 0x00000002,0x00000d41,0x000000e8,0x00000d32,0x00000d35,0x00000d37,0x00000d39,0x00000d3c, + 0x00000d3f,0x00000d40,0x0004003d,0x00000007,0x00000d42,0x00000d3f,0x0003003e,0x00000d33, + 0x00000d42,0x0004003d,0x00000007,0x00000d43,0x00000d40,0x0003003e,0x00000d34,0x00000d43, + 0x0004003d,0x00000007,0x00000d46,0x00000d33,0x0003003e,0x00000d45,0x00000d46,0x0004003d, + 0x00000007,0x00000d48,0x00000d34,0x0003003e,0x00000d47,0x00000d48,0x0004003d,0x00000007, + 0x00000d4a,0x00000ca0,0x0003003e,0x00000d49,0x00000d4a,0x00070039,0x00000007,0x00000d4b, + 0x000000f2,0x00000d45,0x00000d47,0x00000d49,0x0003003e,0x00000d44,0x00000d4b,0x0004003d, + 0x00000007,0x00000d4d,0x00000d44,0x00040070,0x00000c8c,0x00000d4e,0x00000d4d,0x00070050, + 0x00000c8c,0x00000d4f,0x00000c91,0x00000c91,0x00000c91,0x00000c91,0x00050088,0x00000c8c, + 0x00000d50,0x00000d4e,0x00000d4f,0x0003003e,0x00000d4c,0x00000d50,0x0004003d,0x00000c94, + 0x00000d51,0x00000c96,0x0004003d,0x0000023c,0x00000d52,0x00000bf1,0x0007004f,0x000008d9, + 0x00000d53,0x00000d52,0x00000d52,0x00000000,0x00000001,0x0004003d,0x00000c8c,0x00000d54, + 0x00000d4c,0x00040063,0x00000d51,0x00000d53,0x00000d54,0x000100fd,0x00010038,0x00050036, + 0x00000006,0x0000000d,0x00000000,0x00000009,0x00030037,0x00000007,0x0000000a,0x00030037, + 0x00000008,0x0000000b,0x00030037,0x00000008,0x0000000c,0x000200f8,0x0000000e,0x0004003b, + 0x00000008,0x00000129,0x00000007,0x0004003b,0x00000008,0x0000012d,0x00000007,0x0004003b, + 0x00000008,0x00000132,0x00000007,0x0004003b,0x00000133,0x00000134,0x00000007,0x0004003b, + 0x00000008,0x0000013f,0x00000007,0x0004003b,0x00000008,0x00000140,0x00000007,0x0004003b, + 0x00000008,0x00000141,0x00000007,0x0004003b,0x00000008,0x00000144,0x00000007,0x0004003b, + 0x00000008,0x00000148,0x00000007,0x0004003b,0x00000008,0x0000014e,0x00000007,0x0004003b, + 0x00000008,0x00000165,0x00000007,0x0004003d,0x00000006,0x0000012a,0x0000000c,0x00050089, + 0x00000006,0x0000012c,0x0000012a,0x0000012b,0x0003003e,0x00000129,0x0000012c,0x0004003d, + 0x00000006,0x0000012e,0x0000000c,0x000500c2,0x00000006,0x00000131,0x0000012e,0x00000130, + 0x0003003e,0x0000012d,0x00000131,0x0003003e,0x00000132,0x000000f9,0x0004003d,0x00000006, + 0x00000135,0x00000129,0x00050082,0x00000006,0x00000136,0x0000012b,0x00000135,0x0004003d, + 0x00000006,0x00000137,0x0000000b,0x00050082,0x00000006,0x00000138,0x00000136,0x00000137, + 0x0004007c,0x0000012f,0x00000139,0x00000138,0x0003003e,0x00000134,0x00000139,0x0004003d, + 0x0000012f,0x0000013a,0x00000134,0x000500b1,0x00000093,0x0000013c,0x0000013a,0x0000013b, + 0x000300f7,0x0000013e,0x00000000,0x000400fa,0x0000013c,0x0000013d,0x00000164,0x000200f8, + 0x0000013d,0x0003003e,0x0000013f,0x000000f9,0x0003003e,0x00000140,0x000000f9,0x0004003d, + 0x00000006,0x00000142,0x00000129,0x00050082,0x00000006,0x00000143,0x0000012b,0x00000142, + 0x0003003e,0x00000141,0x00000143,0x0004003d,0x00000006,0x00000145,0x0000000b,0x0004003d, + 0x00000006,0x00000146,0x00000141,0x00050082,0x00000006,0x00000147,0x00000145,0x00000146, + 0x0003003e,0x00000144,0x00000147,0x0004003d,0x00000006,0x0000014a,0x00000141,0x000500c4, + 0x0000012f,0x0000014b,0x00000149,0x0000014a,0x00050082,0x0000012f,0x0000014c,0x0000014b, + 0x00000149,0x0004007c,0x00000006,0x0000014d,0x0000014c,0x0003003e,0x00000148,0x0000014d, + 0x0004003d,0x00000006,0x0000014f,0x00000144,0x000500c4,0x0000012f,0x00000150,0x00000149, + 0x0000014f,0x00050082,0x0000012f,0x00000151,0x00000150,0x00000149,0x0004007c,0x00000006, + 0x00000152,0x00000151,0x0003003e,0x0000014e,0x00000152,0x0004003d,0x00000006,0x00000153, + 0x0000012d,0x0005004d,0x00000006,0x00000154,0x0000000a,0x00000153,0x0004003d,0x00000006, + 0x00000155,0x00000129,0x000500c2,0x00000006,0x00000156,0x00000154,0x00000155,0x0003003e, + 0x0000013f,0x00000156,0x0004003d,0x00000006,0x00000157,0x00000148,0x0004003d,0x00000006, + 0x00000158,0x0000013f,0x000500c7,0x00000006,0x00000159,0x00000158,0x00000157,0x0003003e, + 0x0000013f,0x00000159,0x0004003d,0x00000006,0x0000015a,0x0000012d,0x00050080,0x00000006, + 0x0000015b,0x0000015a,0x000000f8,0x0005004d,0x00000006,0x0000015c,0x0000000a,0x0000015b, + 0x0004003d,0x00000006,0x0000015d,0x0000014e,0x000500c7,0x00000006,0x0000015e,0x0000015c, + 0x0000015d,0x0003003e,0x00000140,0x0000015e,0x0004003d,0x00000006,0x0000015f,0x00000140, + 0x0004003d,0x00000006,0x00000160,0x00000141,0x000500c4,0x00000006,0x00000161,0x0000015f, + 0x00000160,0x0004003d,0x00000006,0x00000162,0x0000013f,0x000500c5,0x00000006,0x00000163, + 0x00000161,0x00000162,0x0003003e,0x00000132,0x00000163,0x000200f9,0x0000013e,0x000200f8, + 0x00000164,0x0004003d,0x00000006,0x00000166,0x0000000b,0x000500c4,0x0000012f,0x00000167, + 0x00000149,0x00000166,0x00050082,0x0000012f,0x00000168,0x00000167,0x00000149,0x0004007c, + 0x00000006,0x00000169,0x00000168,0x0003003e,0x00000165,0x00000169,0x0004003d,0x00000006, + 0x0000016a,0x0000012d,0x0005004d,0x00000006,0x0000016b,0x0000000a,0x0000016a,0x0004003d, + 0x00000006,0x0000016c,0x0000000c,0x000500c7,0x00000006,0x0000016e,0x0000016c,0x0000016d, + 0x000500c2,0x00000006,0x0000016f,0x0000016b,0x0000016e,0x0003003e,0x00000132,0x0000016f, + 0x0004003d,0x00000006,0x00000170,0x00000165,0x0004003d,0x00000006,0x00000171,0x00000132, + 0x000500c7,0x00000006,0x00000172,0x00000171,0x00000170,0x0003003e,0x00000132,0x00000172, + 0x000200f9,0x0000013e,0x000200f8,0x0000013e,0x0004003d,0x00000006,0x00000173,0x00000132, + 0x000200fe,0x00000173,0x00010038,0x00050036,0x00000006,0x00000013,0x00000000,0x0000000f, + 0x00030037,0x00000006,0x00000010,0x00030037,0x00000008,0x00000011,0x00030037,0x00000008, + 0x00000012,0x000200f8,0x00000014,0x0004003b,0x00000008,0x00000176,0x00000007,0x0004003b, + 0x00000008,0x0000017b,0x00000007,0x0004003d,0x00000006,0x00000177,0x00000011,0x000500c4, + 0x0000012f,0x00000178,0x00000149,0x00000177,0x00050082,0x0000012f,0x00000179,0x00000178, + 0x00000149,0x0004007c,0x00000006,0x0000017a,0x00000179,0x0003003e,0x00000176,0x0000017a, + 0x0004003d,0x00000006,0x0000017c,0x00000012,0x000500c7,0x00000006,0x0000017d,0x0000017c, + 0x0000016d,0x000500c2,0x00000006,0x0000017e,0x00000010,0x0000017d,0x0003003e,0x0000017b, + 0x0000017e,0x0004003d,0x00000006,0x0000017f,0x0000017b,0x0004003d,0x00000006,0x00000180, + 0x00000176,0x000500c7,0x00000006,0x00000181,0x0000017f,0x00000180,0x000200fe,0x00000181, + 0x00010038,0x00050036,0x00000007,0x0000001a,0x00000000,0x00000015,0x00030037,0x00000008, + 0x00000016,0x00030037,0x00000008,0x00000017,0x00030037,0x00000008,0x00000018,0x00030037, + 0x00000008,0x00000019,0x000200f8,0x0000001b,0x0004003b,0x0000001c,0x00000184,0x00000007, + 0x0004003d,0x00000006,0x00000185,0x00000016,0x0004003d,0x00000006,0x00000186,0x00000018, + 0x00050080,0x00000006,0x00000187,0x00000185,0x00000186,0x000500c2,0x00000006,0x00000188, + 0x00000187,0x00000149,0x00050041,0x00000008,0x00000189,0x00000184,0x000000f9,0x0003003e, + 0x00000189,0x00000188,0x0004003d,0x00000006,0x0000018a,0x00000017,0x0004003d,0x00000006, + 0x0000018b,0x00000018,0x00050080,0x00000006,0x0000018c,0x0000018a,0x0000018b,0x000500c2, + 0x00000006,0x0000018d,0x0000018c,0x00000149,0x00050041,0x00000008,0x0000018e,0x00000184, + 0x000000f8,0x0003003e,0x0000018e,0x0000018d,0x0004003d,0x00000006,0x0000018f,0x00000018, + 0x00050041,0x00000008,0x00000190,0x00000184,0x000000fb,0x0003003e,0x00000190,0x0000018f, + 0x0004003d,0x00000006,0x00000191,0x00000019,0x00050041,0x00000008,0x00000192,0x00000184, + 0x00000103,0x0003003e,0x00000192,0x00000191,0x0004003d,0x00000007,0x00000193,0x00000184, + 0x000200fe,0x00000193,0x00010038,0x00050036,0x00000002,0x00000022,0x00000000,0x0000001d, + 0x00030037,0x0000001c,0x0000001e,0x00030037,0x0000001c,0x0000001f,0x00030037,0x00000008, + 0x00000020,0x00030037,0x00000008,0x00000021,0x000200f8,0x00000023,0x0004003d,0x00000006, + 0x00000196,0x00000020,0x00060050,0x00000197,0x00000198,0x00000196,0x00000196,0x00000196, + 0x00050051,0x00000006,0x0000019a,0x00000198,0x00000000,0x00050051,0x00000006,0x0000019b, + 0x00000198,0x00000001,0x00050051,0x00000006,0x0000019c,0x00000198,0x00000002,0x00070050, + 0x00000007,0x0000019d,0x0000019a,0x0000019b,0x0000019c,0x00000199,0x0003003e,0x0000001e, + 0x0000019d,0x0004003d,0x00000006,0x0000019e,0x00000021,0x00060050,0x00000197,0x0000019f, + 0x0000019e,0x0000019e,0x0000019e,0x00050051,0x00000006,0x000001a0,0x0000019f,0x00000000, + 0x00050051,0x00000006,0x000001a1,0x0000019f,0x00000001,0x00050051,0x00000006,0x000001a2, + 0x0000019f,0x00000002,0x00070050,0x00000007,0x000001a3,0x000001a0,0x000001a1,0x000001a2, + 0x00000199,0x0003003e,0x0000001f,0x000001a3,0x000100fd,0x00010038,0x00050036,0x00000002, + 0x00000028,0x00000000,0x0000001d,0x00030037,0x0000001c,0x00000024,0x00030037,0x0000001c, + 0x00000025,0x00030037,0x00000008,0x00000026,0x00030037,0x00000008,0x00000027,0x000200f8, + 0x00000029,0x0004003b,0x00000008,0x000001a4,0x00000007,0x0004003b,0x00000008,0x000001ac, + 0x00000007,0x0004003d,0x00000006,0x000001a5,0x00000026,0x000500c2,0x00000006,0x000001a7, + 0x000001a5,0x000001a6,0x0004003d,0x00000006,0x000001a8,0x00000027,0x000500c7,0x00000006, + 0x000001aa,0x000001a8,0x000001a9,0x000500c5,0x00000006,0x000001ab,0x000001a7,0x000001aa, + 0x0003003e,0x000001a4,0x000001ab,0x0004003d,0x00000006,0x000001ad,0x000001a4,0x0004003d, + 0x00000006,0x000001ae,0x00000027,0x000500c7,0x00000006,0x000001b0,0x000001ae,0x000001af, + 0x00050080,0x00000006,0x000001b1,0x000001ad,0x000001b0,0x0003003e,0x000001ac,0x000001b1, + 0x0004003d,0x00000006,0x000001b2,0x000001ac,0x0007000c,0x00000006,0x000001b3,0x00000001, + 0x00000026,0x000001b2,0x00000199,0x0003003e,0x000001ac,0x000001b3,0x0004003d,0x00000006, + 0x000001b4,0x000001a4,0x00060050,0x00000197,0x000001b5,0x000001b4,0x000001b4,0x000001b4, + 0x00050051,0x00000006,0x000001b6,0x000001b5,0x00000000,0x00050051,0x00000006,0x000001b7, + 0x000001b5,0x00000001,0x00050051,0x00000006,0x000001b8,0x000001b5,0x00000002,0x00070050, + 0x00000007,0x000001b9,0x000001b6,0x000001b7,0x000001b8,0x00000199,0x0003003e,0x00000024, + 0x000001b9,0x0004003d,0x00000006,0x000001ba,0x000001ac,0x00060050,0x00000197,0x000001bb, + 0x000001ba,0x000001ba,0x000001ba,0x00050051,0x00000006,0x000001bc,0x000001bb,0x00000000, + 0x00050051,0x00000006,0x000001bd,0x000001bb,0x00000001,0x00050051,0x00000006,0x000001be, + 0x000001bb,0x00000002,0x00070050,0x00000007,0x000001bf,0x000001bc,0x000001bd,0x000001be, + 0x00000199,0x0003003e,0x00000025,0x000001bf,0x000100fd,0x00010038,0x00050036,0x00000002, + 0x00000031,0x00000000,0x0000002a,0x00030037,0x0000001c,0x0000002b,0x00030037,0x0000001c, + 0x0000002c,0x00030037,0x00000008,0x0000002d,0x00030037,0x00000008,0x0000002e,0x00030037, + 0x00000008,0x0000002f,0x00030037,0x00000008,0x00000030,0x000200f8,0x00000032,0x0004003d, + 0x00000006,0x000001c0,0x0000002d,0x00060050,0x00000197,0x000001c1,0x000001c0,0x000001c0, + 0x000001c0,0x0004003d,0x00000006,0x000001c2,0x0000002f,0x00050051,0x00000006,0x000001c3, + 0x000001c1,0x00000000,0x00050051,0x00000006,0x000001c4,0x000001c1,0x00000001,0x00050051, + 0x00000006,0x000001c5,0x000001c1,0x00000002,0x00070050,0x00000007,0x000001c6,0x000001c3, + 0x000001c4,0x000001c5,0x000001c2,0x0003003e,0x0000002b,0x000001c6,0x0004003d,0x00000006, + 0x000001c7,0x0000002e,0x00060050,0x00000197,0x000001c8,0x000001c7,0x000001c7,0x000001c7, + 0x0004003d,0x00000006,0x000001c9,0x00000030,0x00050051,0x00000006,0x000001ca,0x000001c8, + 0x00000000,0x00050051,0x00000006,0x000001cb,0x000001c8,0x00000001,0x00050051,0x00000006, + 0x000001cc,0x000001c8,0x00000002,0x00070050,0x00000007,0x000001cd,0x000001ca,0x000001cb, + 0x000001cc,0x000001c9,0x0003003e,0x0000002c,0x000001cd,0x000100fd,0x00010038,0x00050036, + 0x00000002,0x00000039,0x00000000,0x0000002a,0x00030037,0x0000001c,0x00000033,0x00030037, + 0x0000001c,0x00000034,0x00030037,0x00000008,0x00000035,0x00030037,0x00000008,0x00000036, + 0x00030037,0x00000008,0x00000037,0x00030037,0x00000008,0x00000038,0x000200f8,0x0000003a, + 0x0004003b,0x00000133,0x000001ce,0x00000007,0x0004003b,0x00000133,0x000001d1,0x00000007, + 0x0004003b,0x00000133,0x000001d4,0x00000007,0x0004003b,0x00000133,0x000001d7,0x00000007, + 0x0004003b,0x00000133,0x000001ee,0x00000007,0x0004003b,0x00000133,0x000001f9,0x00000007, + 0x0004003b,0x00000008,0x0000020f,0x00000007,0x0004003b,0x00000008,0x00000214,0x00000007, + 0x0004003b,0x00000008,0x00000218,0x00000007,0x0004003b,0x00000008,0x0000021b,0x00000007, + 0x0004003b,0x00000008,0x0000021e,0x00000007,0x0004003b,0x00000008,0x00000223,0x00000007, + 0x0004003d,0x00000006,0x000001cf,0x00000035,0x0004007c,0x0000012f,0x000001d0,0x000001cf, + 0x0003003e,0x000001ce,0x000001d0,0x0004003d,0x00000006,0x000001d2,0x00000036,0x0004007c, + 0x0000012f,0x000001d3,0x000001d2,0x0003003e,0x000001d1,0x000001d3,0x0004003d,0x00000006, + 0x000001d5,0x00000037,0x0004007c,0x0000012f,0x000001d6,0x000001d5,0x0003003e,0x000001d4, + 0x000001d6,0x0004003d,0x00000006,0x000001d8,0x00000038,0x0004007c,0x0000012f,0x000001d9, + 0x000001d8,0x0003003e,0x000001d7,0x000001d9,0x0004003d,0x0000012f,0x000001da,0x000001d1, + 0x000500c7,0x0000012f,0x000001dc,0x000001da,0x000001db,0x000500c4,0x0000012f,0x000001dd, + 0x000001dc,0x00000149,0x0004003d,0x0000012f,0x000001de,0x000001ce,0x000500c5,0x0000012f, + 0x000001df,0x000001de,0x000001dd,0x0003003e,0x000001ce,0x000001df,0x0004003d,0x0000012f, + 0x000001e0,0x000001d7,0x000500c7,0x0000012f,0x000001e1,0x000001e0,0x000001db,0x000500c4, + 0x0000012f,0x000001e2,0x000001e1,0x00000149,0x0004003d,0x0000012f,0x000001e3,0x000001d4, + 0x000500c5,0x0000012f,0x000001e4,0x000001e3,0x000001e2,0x0003003e,0x000001d4,0x000001e4, + 0x0004003d,0x0000012f,0x000001e6,0x000001d1,0x000500c7,0x0000012f,0x000001e7,0x000001e6, + 0x000001e5,0x0003003e,0x000001d1,0x000001e7,0x0004003d,0x0000012f,0x000001e8,0x000001d7, + 0x000500c7,0x0000012f,0x000001e9,0x000001e8,0x000001e5,0x0003003e,0x000001d7,0x000001e9, + 0x0004003d,0x0000012f,0x000001ea,0x000001d1,0x000500c7,0x0000012f,0x000001ec,0x000001ea, + 0x000001eb,0x000500ad,0x00000093,0x000001ed,0x000001ec,0x0000013b,0x000300f7,0x000001f0, + 0x00000000,0x000400fa,0x000001ed,0x000001ef,0x000001f3,0x000200f8,0x000001ef,0x0004003d, + 0x0000012f,0x000001f1,0x000001d1,0x00050082,0x0000012f,0x000001f2,0x000001f1,0x000001db, + 0x0003003e,0x000001ee,0x000001f2,0x000200f9,0x000001f0,0x000200f8,0x000001f3,0x0004003d, + 0x0000012f,0x000001f4,0x000001d1,0x0003003e,0x000001ee,0x000001f4,0x000200f9,0x000001f0, + 0x000200f8,0x000001f0,0x0004003d,0x0000012f,0x000001f5,0x000001ee,0x0003003e,0x000001d1, + 0x000001f5,0x0004003d,0x0000012f,0x000001f6,0x000001d7,0x000500c7,0x0000012f,0x000001f7, + 0x000001f6,0x000001eb,0x000500ad,0x00000093,0x000001f8,0x000001f7,0x0000013b,0x000300f7, + 0x000001fb,0x00000000,0x000400fa,0x000001f8,0x000001fa,0x000001fe,0x000200f8,0x000001fa, + 0x0004003d,0x0000012f,0x000001fc,0x000001d7,0x00050082,0x0000012f,0x000001fd,0x000001fc, + 0x000001db,0x0003003e,0x000001f9,0x000001fd,0x000200f9,0x000001fb,0x000200f8,0x000001fe, + 0x0004003d,0x0000012f,0x000001ff,0x000001d7,0x0003003e,0x000001f9,0x000001ff,0x000200f9, + 0x000001fb,0x000200f8,0x000001fb,0x0004003d,0x0000012f,0x00000200,0x000001f9,0x0003003e, + 0x000001d7,0x00000200,0x0004003d,0x0000012f,0x00000201,0x000001ce,0x000500c3,0x0000012f, + 0x00000202,0x00000201,0x00000149,0x0003003e,0x000001ce,0x00000202,0x0004003d,0x0000012f, + 0x00000203,0x000001d1,0x000500c3,0x0000012f,0x00000204,0x00000203,0x00000149,0x0003003e, + 0x000001d1,0x00000204,0x0004003d,0x0000012f,0x00000205,0x000001d4,0x000500c3,0x0000012f, + 0x00000206,0x00000205,0x00000149,0x0003003e,0x000001d4,0x00000206,0x0004003d,0x0000012f, + 0x00000207,0x000001d7,0x000500c3,0x0000012f,0x00000208,0x00000207,0x00000149,0x0003003e, + 0x000001d7,0x00000208,0x0004003d,0x0000012f,0x00000209,0x000001ce,0x0004003d,0x0000012f, + 0x0000020a,0x000001d1,0x00050080,0x0000012f,0x0000020b,0x0000020a,0x00000209,0x0003003e, + 0x000001d1,0x0000020b,0x0004003d,0x0000012f,0x0000020c,0x000001d4,0x0004003d,0x0000012f, + 0x0000020d,0x000001d7,0x00050080,0x0000012f,0x0000020e,0x0000020d,0x0000020c,0x0003003e, + 0x000001d7,0x0000020e,0x0004003d,0x0000012f,0x00000210,0x000001d1,0x0008000c,0x0000012f, + 0x00000212,0x00000001,0x0000002d,0x00000210,0x0000013b,0x00000211,0x0004007c,0x00000006, + 0x00000213,0x00000212,0x0003003e,0x0000020f,0x00000213,0x0004003d,0x0000012f,0x00000215, + 0x000001d7,0x0008000c,0x0000012f,0x00000216,0x00000001,0x0000002d,0x00000215,0x0000013b, + 0x00000211,0x0004007c,0x00000006,0x00000217,0x00000216,0x0003003e,0x00000214,0x00000217, + 0x0004003d,0x0000012f,0x00000219,0x000001ce,0x0004007c,0x00000006,0x0000021a,0x00000219, + 0x0003003e,0x00000218,0x0000021a,0x0004003d,0x0000012f,0x0000021c,0x000001d4,0x0004007c, + 0x00000006,0x0000021d,0x0000021c,0x0003003e,0x0000021b,0x0000021d,0x0004003d,0x00000006, + 0x0000021f,0x00000035,0x0004003d,0x00000006,0x00000220,0x00000036,0x00050080,0x00000006, + 0x00000221,0x0000021f,0x00000220,0x0008000c,0x00000006,0x00000222,0x00000001,0x0000002c, + 0x00000221,0x000000f9,0x00000199,0x0003003e,0x0000021e,0x00000222,0x0004003d,0x00000006, + 0x00000224,0x00000037,0x0004003d,0x00000006,0x00000225,0x00000038,0x00050080,0x00000006, + 0x00000226,0x00000224,0x00000225,0x0008000c,0x00000006,0x00000227,0x00000001,0x0000002c, + 0x00000226,0x000000f9,0x00000199,0x0003003e,0x00000223,0x00000227,0x0004003d,0x00000006, + 0x00000228,0x00000218,0x0004003d,0x00000006,0x00000229,0x00000218,0x0004003d,0x00000006, + 0x0000022a,0x00000218,0x0004003d,0x0000012f,0x0000022b,0x000001d4,0x0004007c,0x00000006, + 0x0000022c,0x0000022b,0x00070050,0x00000007,0x0000022d,0x00000228,0x00000229,0x0000022a, + 0x0000022c,0x0003003e,0x00000033,0x0000022d,0x0004003d,0x00000006,0x0000022e,0x0000020f, + 0x0004003d,0x00000006,0x0000022f,0x0000020f,0x0004003d,0x00000006,0x00000230,0x0000020f, + 0x0004003d,0x0000012f,0x00000231,0x000001d7,0x0004007c,0x00000006,0x00000232,0x00000231, + 0x00070050,0x00000007,0x00000233,0x0000022e,0x0000022f,0x00000230,0x00000232,0x0003003e, + 0x00000034,0x00000233,0x000100fd,0x00010038,0x00050036,0x00000002,0x00000041,0x00000000, + 0x0000002a,0x00030037,0x0000001c,0x0000003b,0x00030037,0x0000001c,0x0000003c,0x00030037, + 0x00000008,0x0000003d,0x00030037,0x00000008,0x0000003e,0x00030037,0x00000008,0x0000003f, + 0x00030037,0x00000008,0x00000040,0x000200f8,0x00000042,0x0004003d,0x00000006,0x00000234, + 0x0000003d,0x0004003d,0x00000006,0x00000235,0x0000003e,0x0004003d,0x00000006,0x00000236, + 0x0000003f,0x00060050,0x00000197,0x00000237,0x00000234,0x00000235,0x00000236,0x0004003d, + 0x00000006,0x00000238,0x00000040,0x00060050,0x00000197,0x00000239,0x00000238,0x00000238, + 0x00000238,0x00050084,0x00000197,0x0000023a,0x00000237,0x00000239,0x00060050,0x0000023c, + 0x0000023d,0x0000023b,0x0000023b,0x0000023b,0x000500c2,0x00000197,0x0000023e,0x0000023a, + 0x0000023d,0x00050051,0x00000006,0x0000023f,0x0000023e,0x00000000,0x00050051,0x00000006, + 0x00000240,0x0000023e,0x00000001,0x00050051,0x00000006,0x00000241,0x0000023e,0x00000002, + 0x00070050,0x00000007,0x00000242,0x0000023f,0x00000240,0x00000241,0x00000199,0x0003003e, + 0x0000003b,0x00000242,0x0004003d,0x00000006,0x00000243,0x0000003d,0x0004003d,0x00000006, + 0x00000244,0x0000003e,0x0004003d,0x00000006,0x00000245,0x0000003f,0x00070050,0x00000007, + 0x00000246,0x00000243,0x00000244,0x00000245,0x00000199,0x0003003e,0x0000003c,0x00000246, + 0x000100fd,0x00010038,0x00050036,0x00000002,0x0000004c,0x00000000,0x00000043,0x00030037, + 0x0000001c,0x00000044,0x00030037,0x0000001c,0x00000045,0x00030037,0x00000008,0x00000046, + 0x00030037,0x00000008,0x00000047,0x00030037,0x00000008,0x00000048,0x00030037,0x00000008, + 0x00000049,0x00030037,0x00000008,0x0000004a,0x00030037,0x00000008,0x0000004b,0x000200f8, + 0x0000004d,0x0004003d,0x00000006,0x00000247,0x00000046,0x0004003d,0x00000006,0x00000248, + 0x00000047,0x0004003d,0x00000006,0x00000249,0x00000048,0x00060050,0x00000197,0x0000024a, + 0x00000247,0x00000248,0x00000249,0x0004003d,0x00000006,0x0000024b,0x00000049,0x00060050, + 0x00000197,0x0000024c,0x0000024b,0x0000024b,0x0000024b,0x00050084,0x00000197,0x0000024d, + 0x0000024a,0x0000024c,0x00060050,0x0000023c,0x0000024e,0x0000023b,0x0000023b,0x0000023b, + 0x000500c2,0x00000197,0x0000024f,0x0000024d,0x0000024e,0x0004003d,0x00000006,0x00000250, + 0x0000004a,0x00050051,0x00000006,0x00000251,0x0000024f,0x00000000,0x00050051,0x00000006, + 0x00000252,0x0000024f,0x00000001,0x00050051,0x00000006,0x00000253,0x0000024f,0x00000002, + 0x00070050,0x00000007,0x00000254,0x00000251,0x00000252,0x00000253,0x00000250,0x0003003e, + 0x00000044,0x00000254,0x0004003d,0x00000006,0x00000255,0x00000046,0x0004003d,0x00000006, + 0x00000256,0x00000047,0x0004003d,0x00000006,0x00000257,0x00000048,0x0004003d,0x00000006, + 0x00000258,0x0000004b,0x00070050,0x00000007,0x00000259,0x00000255,0x00000256,0x00000257, + 0x00000258,0x0003003e,0x00000045,0x00000259,0x000100fd,0x00010038,0x00050036,0x00000002, + 0x00000056,0x00000000,0x00000043,0x00030037,0x0000001c,0x0000004e,0x00030037,0x0000001c, + 0x0000004f,0x00030037,0x00000008,0x00000050,0x00030037,0x00000008,0x00000051,0x00030037, + 0x00000008,0x00000052,0x00030037,0x00000008,0x00000053,0x00030037,0x00000008,0x00000054, + 0x00030037,0x00000008,0x00000055,0x000200f8,0x00000057,0x0004003b,0x00000008,0x0000025a, + 0x00000007,0x0004003b,0x00000008,0x00000260,0x00000007,0x0004003b,0x00000008,0x00000274, + 0x00000007,0x0004003b,0x00000008,0x00000276,0x00000007,0x0004003b,0x00000008,0x00000278, + 0x00000007,0x0004003b,0x00000008,0x0000027a,0x00000007,0x0004003b,0x00000008,0x0000027c, + 0x00000007,0x0004003b,0x00000008,0x0000027e,0x00000007,0x0004003b,0x00000008,0x00000280, + 0x00000007,0x0004003b,0x00000008,0x00000282,0x00000007,0x0004003d,0x00000006,0x0000025b, + 0x00000050,0x0004003d,0x00000006,0x0000025c,0x00000052,0x00050080,0x00000006,0x0000025d, + 0x0000025b,0x0000025c,0x0004003d,0x00000006,0x0000025e,0x00000054,0x00050080,0x00000006, + 0x0000025f,0x0000025d,0x0000025e,0x0003003e,0x0000025a,0x0000025f,0x0004003d,0x00000006, + 0x00000261,0x00000051,0x0004003d,0x00000006,0x00000262,0x00000053,0x00050080,0x00000006, + 0x00000263,0x00000261,0x00000262,0x0004003d,0x00000006,0x00000264,0x00000055,0x00050080, + 0x00000006,0x00000265,0x00000263,0x00000264,0x0003003e,0x00000260,0x00000265,0x0004003d, + 0x00000006,0x00000266,0x00000260,0x0004003d,0x00000006,0x00000267,0x0000025a,0x000500ae, + 0x00000093,0x00000268,0x00000266,0x00000267,0x000300f7,0x0000026a,0x00000000,0x000400fa, + 0x00000268,0x00000269,0x00000273,0x000200f8,0x00000269,0x0004003d,0x00000006,0x0000026b, + 0x00000050,0x0004003d,0x00000006,0x0000026c,0x00000052,0x0004003d,0x00000006,0x0000026d, + 0x00000054,0x00070050,0x00000007,0x0000026e,0x0000026b,0x0000026c,0x0000026d,0x00000199, + 0x0003003e,0x0000004e,0x0000026e,0x0004003d,0x00000006,0x0000026f,0x00000051,0x0004003d, + 0x00000006,0x00000270,0x00000053,0x0004003d,0x00000006,0x00000271,0x00000055,0x00070050, + 0x00000007,0x00000272,0x0000026f,0x00000270,0x00000271,0x00000199,0x0003003e,0x0000004f, + 0x00000272,0x000200f9,0x0000026a,0x000200f8,0x00000273,0x0004003d,0x00000006,0x00000275, + 0x00000051,0x0003003e,0x00000274,0x00000275,0x0004003d,0x00000006,0x00000277,0x00000053, + 0x0003003e,0x00000276,0x00000277,0x0004003d,0x00000006,0x00000279,0x00000055,0x0003003e, + 0x00000278,0x00000279,0x0003003e,0x0000027a,0x00000199,0x00080039,0x00000007,0x0000027b, + 0x0000001a,0x00000274,0x00000276,0x00000278,0x0000027a,0x0003003e,0x0000004e,0x0000027b, + 0x0004003d,0x00000006,0x0000027d,0x00000050,0x0003003e,0x0000027c,0x0000027d,0x0004003d, + 0x00000006,0x0000027f,0x00000052,0x0003003e,0x0000027e,0x0000027f,0x0004003d,0x00000006, + 0x00000281,0x00000054,0x0003003e,0x00000280,0x00000281,0x0003003e,0x00000282,0x00000199, + 0x00080039,0x00000007,0x00000283,0x0000001a,0x0000027c,0x0000027e,0x00000280,0x00000282, + 0x0003003e,0x0000004f,0x00000283,0x000200f9,0x0000026a,0x000200f8,0x0000026a,0x000100fd, + 0x00010038,0x00050036,0x00000002,0x00000060,0x00000000,0x00000043,0x00030037,0x0000001c, + 0x00000058,0x00030037,0x0000001c,0x00000059,0x00030037,0x00000008,0x0000005a,0x00030037, + 0x00000008,0x0000005b,0x00030037,0x00000008,0x0000005c,0x00030037,0x00000008,0x0000005d, + 0x00030037,0x00000008,0x0000005e,0x00030037,0x00000008,0x0000005f,0x000200f8,0x00000061, + 0x0004003b,0x00000286,0x00000287,0x00000007,0x0004003b,0x00000133,0x000002c4,0x00000007, + 0x0004003b,0x00000133,0x000002d3,0x00000007,0x0004003b,0x00000133,0x000002e2,0x00000007, + 0x0004003b,0x00000133,0x00000305,0x00000007,0x0004003b,0x00000133,0x00000324,0x00000007, + 0x0004003b,0x00000133,0x00000334,0x00000007,0x0004003b,0x00000133,0x00000344,0x00000007, + 0x0004003b,0x00000133,0x00000354,0x00000007,0x0004003b,0x00000362,0x00000363,0x00000007, + 0x0004003b,0x00000362,0x0000036d,0x00000007,0x0003003e,0x00000287,0x00000289,0x0004003d, + 0x00000006,0x0000028a,0x0000005a,0x0004007c,0x0000012f,0x0000028b,0x0000028a,0x00060041, + 0x00000133,0x0000028c,0x00000287,0x0000013b,0x000000f9,0x0003003e,0x0000028c,0x0000028b, + 0x0004003d,0x00000006,0x0000028d,0x0000005c,0x0004007c,0x0000012f,0x0000028e,0x0000028d, + 0x00060041,0x00000133,0x0000028f,0x00000287,0x0000013b,0x000000f8,0x0003003e,0x0000028f, + 0x0000028e,0x0004003d,0x00000006,0x00000290,0x0000005e,0x0004007c,0x0000012f,0x00000291, + 0x00000290,0x00060041,0x00000133,0x00000292,0x00000287,0x0000013b,0x000000fb,0x0003003e, + 0x00000292,0x00000291,0x0004003d,0x00000006,0x00000293,0x0000005b,0x0004007c,0x0000012f, + 0x00000294,0x00000293,0x00060041,0x00000133,0x00000295,0x00000287,0x00000149,0x000000f9, + 0x0003003e,0x00000295,0x00000294,0x0004003d,0x00000006,0x00000296,0x0000005d,0x0004007c, + 0x0000012f,0x00000297,0x00000296,0x00060041,0x00000133,0x00000298,0x00000287,0x00000149, + 0x000000f8,0x0003003e,0x00000298,0x00000297,0x0004003d,0x00000006,0x00000299,0x0000005f, + 0x0004007c,0x0000012f,0x0000029a,0x00000299,0x00060041,0x00000133,0x0000029b,0x00000287, + 0x00000149,0x000000fb,0x0003003e,0x0000029b,0x0000029a,0x00060041,0x00000133,0x0000029c, + 0x00000287,0x00000149,0x000000f9,0x0004003d,0x0000012f,0x0000029d,0x0000029c,0x000500c7, + 0x0000012f,0x0000029e,0x0000029d,0x000001db,0x000500c4,0x0000012f,0x0000029f,0x0000029e, + 0x00000149,0x00060041,0x00000133,0x000002a0,0x00000287,0x0000013b,0x000000f9,0x0004003d, + 0x0000012f,0x000002a1,0x000002a0,0x000500c5,0x0000012f,0x000002a2,0x000002a1,0x0000029f, + 0x00060041,0x00000133,0x000002a3,0x00000287,0x0000013b,0x000000f9,0x0003003e,0x000002a3, + 0x000002a2,0x00060041,0x00000133,0x000002a4,0x00000287,0x00000149,0x000000f8,0x0004003d, + 0x0000012f,0x000002a5,0x000002a4,0x000500c7,0x0000012f,0x000002a6,0x000002a5,0x000001db, + 0x000500c4,0x0000012f,0x000002a7,0x000002a6,0x00000149,0x00060041,0x00000133,0x000002a8, + 0x00000287,0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x000002a9,0x000002a8,0x000500c5, + 0x0000012f,0x000002aa,0x000002a9,0x000002a7,0x00060041,0x00000133,0x000002ab,0x00000287, + 0x0000013b,0x000000f8,0x0003003e,0x000002ab,0x000002aa,0x00060041,0x00000133,0x000002ac, + 0x00000287,0x00000149,0x000000fb,0x0004003d,0x0000012f,0x000002ad,0x000002ac,0x000500c7, + 0x0000012f,0x000002ae,0x000002ad,0x000001db,0x000500c4,0x0000012f,0x000002af,0x000002ae, + 0x00000149,0x00060041,0x00000133,0x000002b0,0x00000287,0x0000013b,0x000000fb,0x0004003d, + 0x0000012f,0x000002b1,0x000002b0,0x000500c5,0x0000012f,0x000002b2,0x000002b1,0x000002af, + 0x00060041,0x00000133,0x000002b3,0x00000287,0x0000013b,0x000000fb,0x0003003e,0x000002b3, + 0x000002b2,0x00060041,0x00000133,0x000002b4,0x00000287,0x00000149,0x000000f9,0x0004003d, + 0x0000012f,0x000002b5,0x000002b4,0x000500c7,0x0000012f,0x000002b6,0x000002b5,0x000001e5, + 0x00060041,0x00000133,0x000002b7,0x00000287,0x00000149,0x000000f9,0x0003003e,0x000002b7, + 0x000002b6,0x00060041,0x00000133,0x000002b8,0x00000287,0x00000149,0x000000f8,0x0004003d, + 0x0000012f,0x000002b9,0x000002b8,0x000500c7,0x0000012f,0x000002ba,0x000002b9,0x000001e5, + 0x00060041,0x00000133,0x000002bb,0x00000287,0x00000149,0x000000f8,0x0003003e,0x000002bb, + 0x000002ba,0x00060041,0x00000133,0x000002bc,0x00000287,0x00000149,0x000000fb,0x0004003d, + 0x0000012f,0x000002bd,0x000002bc,0x000500c7,0x0000012f,0x000002be,0x000002bd,0x000001e5, + 0x00060041,0x00000133,0x000002bf,0x00000287,0x00000149,0x000000fb,0x0003003e,0x000002bf, + 0x000002be,0x00060041,0x00000133,0x000002c0,0x00000287,0x00000149,0x000000f9,0x0004003d, + 0x0000012f,0x000002c1,0x000002c0,0x000500c7,0x0000012f,0x000002c2,0x000002c1,0x000001eb, + 0x000500ad,0x00000093,0x000002c3,0x000002c2,0x0000013b,0x000300f7,0x000002c6,0x00000000, + 0x000400fa,0x000002c3,0x000002c5,0x000002ca,0x000200f8,0x000002c5,0x00060041,0x00000133, + 0x000002c7,0x00000287,0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000002c8,0x000002c7, + 0x00050082,0x0000012f,0x000002c9,0x000002c8,0x000001db,0x0003003e,0x000002c4,0x000002c9, + 0x000200f9,0x000002c6,0x000200f8,0x000002ca,0x00060041,0x00000133,0x000002cb,0x00000287, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000002cc,0x000002cb,0x0003003e,0x000002c4, + 0x000002cc,0x000200f9,0x000002c6,0x000200f8,0x000002c6,0x0004003d,0x0000012f,0x000002cd, + 0x000002c4,0x00060041,0x00000133,0x000002ce,0x00000287,0x00000149,0x000000f9,0x0003003e, + 0x000002ce,0x000002cd,0x00060041,0x00000133,0x000002cf,0x00000287,0x00000149,0x000000f8, + 0x0004003d,0x0000012f,0x000002d0,0x000002cf,0x000500c7,0x0000012f,0x000002d1,0x000002d0, + 0x000001eb,0x000500ad,0x00000093,0x000002d2,0x000002d1,0x0000013b,0x000300f7,0x000002d5, + 0x00000000,0x000400fa,0x000002d2,0x000002d4,0x000002d9,0x000200f8,0x000002d4,0x00060041, + 0x00000133,0x000002d6,0x00000287,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x000002d7, + 0x000002d6,0x00050082,0x0000012f,0x000002d8,0x000002d7,0x000001db,0x0003003e,0x000002d3, + 0x000002d8,0x000200f9,0x000002d5,0x000200f8,0x000002d9,0x00060041,0x00000133,0x000002da, + 0x00000287,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x000002db,0x000002da,0x0003003e, + 0x000002d3,0x000002db,0x000200f9,0x000002d5,0x000200f8,0x000002d5,0x0004003d,0x0000012f, + 0x000002dc,0x000002d3,0x00060041,0x00000133,0x000002dd,0x00000287,0x00000149,0x000000f8, + 0x0003003e,0x000002dd,0x000002dc,0x00060041,0x00000133,0x000002de,0x00000287,0x00000149, + 0x000000fb,0x0004003d,0x0000012f,0x000002df,0x000002de,0x000500c7,0x0000012f,0x000002e0, + 0x000002df,0x000001eb,0x000500ad,0x00000093,0x000002e1,0x000002e0,0x0000013b,0x000300f7, + 0x000002e4,0x00000000,0x000400fa,0x000002e1,0x000002e3,0x000002e8,0x000200f8,0x000002e3, + 0x00060041,0x00000133,0x000002e5,0x00000287,0x00000149,0x000000fb,0x0004003d,0x0000012f, + 0x000002e6,0x000002e5,0x00050082,0x0000012f,0x000002e7,0x000002e6,0x000001db,0x0003003e, + 0x000002e2,0x000002e7,0x000200f9,0x000002e4,0x000200f8,0x000002e8,0x00060041,0x00000133, + 0x000002e9,0x00000287,0x00000149,0x000000fb,0x0004003d,0x0000012f,0x000002ea,0x000002e9, + 0x0003003e,0x000002e2,0x000002ea,0x000200f9,0x000002e4,0x000200f8,0x000002e4,0x0004003d, + 0x0000012f,0x000002eb,0x000002e2,0x00060041,0x00000133,0x000002ec,0x00000287,0x00000149, + 0x000000fb,0x0003003e,0x000002ec,0x000002eb,0x00060041,0x00000133,0x000002ed,0x00000287, + 0x0000013b,0x000000f9,0x0004003d,0x0000012f,0x000002ee,0x000002ed,0x000500c3,0x0000012f, + 0x000002ef,0x000002ee,0x00000149,0x00060041,0x00000133,0x000002f0,0x00000287,0x0000013b, + 0x000000f9,0x0003003e,0x000002f0,0x000002ef,0x00060041,0x00000133,0x000002f1,0x00000287, + 0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x000002f2,0x000002f1,0x000500c3,0x0000012f, + 0x000002f3,0x000002f2,0x00000149,0x00060041,0x00000133,0x000002f4,0x00000287,0x0000013b, + 0x000000f8,0x0003003e,0x000002f4,0x000002f3,0x00060041,0x00000133,0x000002f5,0x00000287, + 0x0000013b,0x000000fb,0x0004003d,0x0000012f,0x000002f6,0x000002f5,0x000500c3,0x0000012f, + 0x000002f7,0x000002f6,0x00000149,0x00060041,0x00000133,0x000002f8,0x00000287,0x0000013b, + 0x000000fb,0x0003003e,0x000002f8,0x000002f7,0x00060041,0x00000133,0x000002f9,0x00000287, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000002fa,0x000002f9,0x000500c3,0x0000012f, + 0x000002fb,0x000002fa,0x00000149,0x00060041,0x00000133,0x000002fc,0x00000287,0x00000149, + 0x000000f9,0x0003003e,0x000002fc,0x000002fb,0x00060041,0x00000133,0x000002fd,0x00000287, + 0x00000149,0x000000f8,0x0004003d,0x0000012f,0x000002fe,0x000002fd,0x000500c3,0x0000012f, + 0x000002ff,0x000002fe,0x00000149,0x00060041,0x00000133,0x00000300,0x00000287,0x00000149, + 0x000000f8,0x0003003e,0x00000300,0x000002ff,0x00060041,0x00000133,0x00000301,0x00000287, + 0x00000149,0x000000fb,0x0004003d,0x0000012f,0x00000302,0x00000301,0x000500c3,0x0000012f, + 0x00000303,0x00000302,0x00000149,0x00060041,0x00000133,0x00000304,0x00000287,0x00000149, + 0x000000fb,0x0003003e,0x00000304,0x00000303,0x00060041,0x00000133,0x00000306,0x00000287, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x00000307,0x00000306,0x00060041,0x00000133, + 0x00000308,0x00000287,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x00000309,0x00000308, + 0x00050080,0x0000012f,0x0000030a,0x00000307,0x00000309,0x00060041,0x00000133,0x0000030b, + 0x00000287,0x00000149,0x000000fb,0x0004003d,0x0000012f,0x0000030c,0x0000030b,0x00050080, + 0x0000012f,0x0000030d,0x0000030a,0x0000030c,0x000500af,0x00000093,0x0000030e,0x0000030d, + 0x0000013b,0x000600a9,0x0000012f,0x0000030f,0x0000030e,0x00000149,0x0000013b,0x0003003e, + 0x00000305,0x0000030f,0x00060041,0x00000133,0x00000310,0x00000287,0x0000013b,0x000000f9, + 0x0004003d,0x0000012f,0x00000311,0x00000310,0x00060041,0x00000133,0x00000312,0x00000287, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x00000313,0x00000312,0x00050080,0x0000012f, + 0x00000314,0x00000313,0x00000311,0x00060041,0x00000133,0x00000315,0x00000287,0x00000149, + 0x000000f9,0x0003003e,0x00000315,0x00000314,0x00060041,0x00000133,0x00000316,0x00000287, + 0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x00000317,0x00000316,0x00060041,0x00000133, + 0x00000318,0x00000287,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x00000319,0x00000318, + 0x00050080,0x0000012f,0x0000031a,0x00000319,0x00000317,0x00060041,0x00000133,0x0000031b, + 0x00000287,0x00000149,0x000000f8,0x0003003e,0x0000031b,0x0000031a,0x00060041,0x00000133, + 0x0000031c,0x00000287,0x0000013b,0x000000fb,0x0004003d,0x0000012f,0x0000031d,0x0000031c, + 0x00060041,0x00000133,0x0000031e,0x00000287,0x00000149,0x000000fb,0x0004003d,0x0000012f, + 0x0000031f,0x0000031e,0x00050080,0x0000012f,0x00000320,0x0000031f,0x0000031d,0x00060041, + 0x00000133,0x00000321,0x00000287,0x00000149,0x000000fb,0x0003003e,0x00000321,0x00000320, + 0x0004003d,0x0000012f,0x00000322,0x00000305,0x000500aa,0x00000093,0x00000323,0x00000322, + 0x0000013b,0x000300f7,0x00000326,0x00000000,0x000400fa,0x00000323,0x00000325,0x0000032d, + 0x000200f8,0x00000325,0x00060041,0x00000133,0x00000327,0x00000287,0x0000013b,0x000000f9, + 0x0004003d,0x0000012f,0x00000328,0x00000327,0x00060041,0x00000133,0x00000329,0x00000287, + 0x0000013b,0x000000fb,0x0004003d,0x0000012f,0x0000032a,0x00000329,0x00050080,0x0000012f, + 0x0000032b,0x00000328,0x0000032a,0x000500c3,0x0000012f,0x0000032c,0x0000032b,0x00000149, + 0x0003003e,0x00000324,0x0000032c,0x000200f9,0x00000326,0x000200f8,0x0000032d,0x00060041, + 0x00000133,0x0000032e,0x00000287,0x0000013b,0x000000f9,0x0004003d,0x0000012f,0x0000032f, + 0x0000032e,0x0003003e,0x00000324,0x0000032f,0x000200f9,0x00000326,0x000200f8,0x00000326, + 0x0004003d,0x0000012f,0x00000330,0x00000324,0x00060041,0x00000133,0x00000331,0x00000287, + 0x0000013b,0x000000f9,0x0003003e,0x00000331,0x00000330,0x0004003d,0x0000012f,0x00000332, + 0x00000305,0x000500aa,0x00000093,0x00000333,0x00000332,0x0000013b,0x000300f7,0x00000336, + 0x00000000,0x000400fa,0x00000333,0x00000335,0x0000033d,0x000200f8,0x00000335,0x00060041, + 0x00000133,0x00000337,0x00000287,0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x00000338, + 0x00000337,0x00060041,0x00000133,0x00000339,0x00000287,0x0000013b,0x000000fb,0x0004003d, + 0x0000012f,0x0000033a,0x00000339,0x00050080,0x0000012f,0x0000033b,0x00000338,0x0000033a, + 0x000500c3,0x0000012f,0x0000033c,0x0000033b,0x00000149,0x0003003e,0x00000334,0x0000033c, + 0x000200f9,0x00000336,0x000200f8,0x0000033d,0x00060041,0x00000133,0x0000033e,0x00000287, + 0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x0000033f,0x0000033e,0x0003003e,0x00000334, + 0x0000033f,0x000200f9,0x00000336,0x000200f8,0x00000336,0x0004003d,0x0000012f,0x00000340, + 0x00000334,0x00060041,0x00000133,0x00000341,0x00000287,0x0000013b,0x000000f8,0x0003003e, + 0x00000341,0x00000340,0x0004003d,0x0000012f,0x00000342,0x00000305,0x000500aa,0x00000093, + 0x00000343,0x00000342,0x0000013b,0x000300f7,0x00000346,0x00000000,0x000400fa,0x00000343, + 0x00000345,0x0000034d,0x000200f8,0x00000345,0x00060041,0x00000133,0x00000347,0x00000287, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x00000348,0x00000347,0x00060041,0x00000133, + 0x00000349,0x00000287,0x00000149,0x000000fb,0x0004003d,0x0000012f,0x0000034a,0x00000349, + 0x00050080,0x0000012f,0x0000034b,0x00000348,0x0000034a,0x000500c3,0x0000012f,0x0000034c, + 0x0000034b,0x00000149,0x0003003e,0x00000344,0x0000034c,0x000200f9,0x00000346,0x000200f8, + 0x0000034d,0x00060041,0x00000133,0x0000034e,0x00000287,0x00000149,0x000000f9,0x0004003d, + 0x0000012f,0x0000034f,0x0000034e,0x0003003e,0x00000344,0x0000034f,0x000200f9,0x00000346, + 0x000200f8,0x00000346,0x0004003d,0x0000012f,0x00000350,0x00000344,0x00060041,0x00000133, + 0x00000351,0x00000287,0x00000149,0x000000f9,0x0003003e,0x00000351,0x00000350,0x0004003d, + 0x0000012f,0x00000352,0x00000305,0x000500aa,0x00000093,0x00000353,0x00000352,0x0000013b, + 0x000300f7,0x00000356,0x00000000,0x000400fa,0x00000353,0x00000355,0x0000035d,0x000200f8, + 0x00000355,0x00060041,0x00000133,0x00000357,0x00000287,0x00000149,0x000000f8,0x0004003d, + 0x0000012f,0x00000358,0x00000357,0x00060041,0x00000133,0x00000359,0x00000287,0x00000149, + 0x000000fb,0x0004003d,0x0000012f,0x0000035a,0x00000359,0x00050080,0x0000012f,0x0000035b, + 0x00000358,0x0000035a,0x000500c3,0x0000012f,0x0000035c,0x0000035b,0x00000149,0x0003003e, + 0x00000354,0x0000035c,0x000200f9,0x00000356,0x000200f8,0x0000035d,0x00060041,0x00000133, + 0x0000035e,0x00000287,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x0000035f,0x0000035e, + 0x0003003e,0x00000354,0x0000035f,0x000200f9,0x00000356,0x000200f8,0x00000356,0x0004003d, + 0x0000012f,0x00000360,0x00000354,0x00060041,0x00000133,0x00000361,0x00000287,0x00000149, + 0x000000f8,0x0003003e,0x00000361,0x00000360,0x0004003d,0x0000012f,0x00000364,0x00000305, + 0x00050082,0x0000012f,0x00000365,0x00000149,0x00000364,0x00050041,0x00000366,0x00000367, + 0x00000287,0x00000365,0x0004003d,0x00000284,0x00000368,0x00000367,0x0008004f,0x0000023c, + 0x00000369,0x00000368,0x00000368,0x00000000,0x00000001,0x00000002,0x0008000c,0x0000023c, + 0x0000036c,0x00000001,0x0000002d,0x00000369,0x0000036a,0x0000036b,0x0003003e,0x00000363, + 0x0000036c,0x0004003d,0x0000012f,0x0000036e,0x00000305,0x00050041,0x00000366,0x0000036f, + 0x00000287,0x0000036e,0x0004003d,0x00000284,0x00000370,0x0000036f,0x0008004f,0x0000023c, + 0x00000371,0x00000370,0x00000370,0x00000000,0x00000001,0x00000002,0x0008000c,0x0000023c, + 0x00000372,0x00000001,0x0000002d,0x00000371,0x0000036a,0x0000036b,0x0003003e,0x0000036d, + 0x00000372,0x0004003d,0x0000023c,0x00000373,0x00000363,0x0004007c,0x00000197,0x00000374, + 0x00000373,0x0004003d,0x00000007,0x00000375,0x00000058,0x0009004f,0x00000007,0x00000376, + 0x00000375,0x00000374,0x00000004,0x00000005,0x00000006,0x00000003,0x0003003e,0x00000058, + 0x00000376,0x00050041,0x00000008,0x00000377,0x00000058,0x00000103,0x0003003e,0x00000377, + 0x00000199,0x0004003d,0x0000023c,0x00000378,0x0000036d,0x0004007c,0x00000197,0x00000379, + 0x00000378,0x0004003d,0x00000007,0x0000037a,0x00000059,0x0009004f,0x00000007,0x0000037b, + 0x0000037a,0x00000379,0x00000004,0x00000005,0x00000006,0x00000003,0x0003003e,0x00000059, + 0x0000037b,0x00050041,0x00000008,0x0000037c,0x00000059,0x00000103,0x0003003e,0x0000037c, + 0x00000199,0x000100fd,0x00010038,0x00050036,0x00000002,0x0000006d,0x00000000,0x00000062, + 0x00030037,0x0000001c,0x00000063,0x00030037,0x0000001c,0x00000064,0x00030037,0x00000008, + 0x00000065,0x00030037,0x00000008,0x00000066,0x00030037,0x00000008,0x00000067,0x00030037, + 0x00000008,0x00000068,0x00030037,0x00000008,0x00000069,0x00030037,0x00000008,0x0000006a, + 0x00030037,0x00000008,0x0000006b,0x00030037,0x00000008,0x0000006c,0x000200f8,0x0000006e, + 0x0004003b,0x00000008,0x0000037d,0x00000007,0x0004003b,0x00000008,0x00000383,0x00000007, + 0x0004003b,0x00000008,0x00000399,0x00000007,0x0004003b,0x00000008,0x0000039b,0x00000007, + 0x0004003b,0x00000008,0x0000039d,0x00000007,0x0004003b,0x00000008,0x0000039f,0x00000007, + 0x0004003b,0x00000008,0x000003a2,0x00000007,0x0004003b,0x00000008,0x000003a4,0x00000007, + 0x0004003b,0x00000008,0x000003a6,0x00000007,0x0004003b,0x00000008,0x000003a8,0x00000007, + 0x0004003d,0x00000006,0x0000037e,0x00000065,0x0004003d,0x00000006,0x0000037f,0x00000067, + 0x00050080,0x00000006,0x00000380,0x0000037e,0x0000037f,0x0004003d,0x00000006,0x00000381, + 0x00000069,0x00050080,0x00000006,0x00000382,0x00000380,0x00000381,0x0003003e,0x0000037d, + 0x00000382,0x0004003d,0x00000006,0x00000384,0x00000066,0x0004003d,0x00000006,0x00000385, + 0x00000068,0x00050080,0x00000006,0x00000386,0x00000384,0x00000385,0x0004003d,0x00000006, + 0x00000387,0x0000006a,0x00050080,0x00000006,0x00000388,0x00000386,0x00000387,0x0003003e, + 0x00000383,0x00000388,0x0004003d,0x00000006,0x00000389,0x00000383,0x0004003d,0x00000006, + 0x0000038a,0x0000037d,0x000500ae,0x00000093,0x0000038b,0x00000389,0x0000038a,0x000300f7, + 0x0000038d,0x00000000,0x000400fa,0x0000038b,0x0000038c,0x00000398,0x000200f8,0x0000038c, + 0x0004003d,0x00000006,0x0000038e,0x00000065,0x0004003d,0x00000006,0x0000038f,0x00000067, + 0x0004003d,0x00000006,0x00000390,0x00000069,0x0004003d,0x00000006,0x00000391,0x0000006b, + 0x00070050,0x00000007,0x00000392,0x0000038e,0x0000038f,0x00000390,0x00000391,0x0003003e, + 0x00000063,0x00000392,0x0004003d,0x00000006,0x00000393,0x00000066,0x0004003d,0x00000006, + 0x00000394,0x00000068,0x0004003d,0x00000006,0x00000395,0x0000006a,0x0004003d,0x00000006, + 0x00000396,0x0000006c,0x00070050,0x00000007,0x00000397,0x00000393,0x00000394,0x00000395, + 0x00000396,0x0003003e,0x00000064,0x00000397,0x000200f9,0x0000038d,0x000200f8,0x00000398, + 0x0004003d,0x00000006,0x0000039a,0x00000066,0x0003003e,0x00000399,0x0000039a,0x0004003d, + 0x00000006,0x0000039c,0x00000068,0x0003003e,0x0000039b,0x0000039c,0x0004003d,0x00000006, + 0x0000039e,0x0000006a,0x0003003e,0x0000039d,0x0000039e,0x0004003d,0x00000006,0x000003a0, + 0x0000006c,0x0003003e,0x0000039f,0x000003a0,0x00080039,0x00000007,0x000003a1,0x0000001a, + 0x00000399,0x0000039b,0x0000039d,0x0000039f,0x0003003e,0x00000063,0x000003a1,0x0004003d, + 0x00000006,0x000003a3,0x00000065,0x0003003e,0x000003a2,0x000003a3,0x0004003d,0x00000006, + 0x000003a5,0x00000067,0x0003003e,0x000003a4,0x000003a5,0x0004003d,0x00000006,0x000003a7, + 0x00000069,0x0003003e,0x000003a6,0x000003a7,0x0004003d,0x00000006,0x000003a9,0x0000006b, + 0x0003003e,0x000003a8,0x000003a9,0x00080039,0x00000007,0x000003aa,0x0000001a,0x000003a2, + 0x000003a4,0x000003a6,0x000003a8,0x0003003e,0x00000064,0x000003aa,0x000200f9,0x0000038d, + 0x000200f8,0x0000038d,0x000100fd,0x00010038,0x00050036,0x00000002,0x00000079,0x00000000, + 0x00000062,0x00030037,0x0000001c,0x0000006f,0x00030037,0x0000001c,0x00000070,0x00030037, + 0x00000008,0x00000071,0x00030037,0x00000008,0x00000072,0x00030037,0x00000008,0x00000073, + 0x00030037,0x00000008,0x00000074,0x00030037,0x00000008,0x00000075,0x00030037,0x00000008, + 0x00000076,0x00030037,0x00000008,0x00000077,0x00030037,0x00000008,0x00000078,0x000200f8, + 0x0000007a,0x0004003b,0x00000286,0x000003ab,0x00000007,0x0004003b,0x00000133,0x000003f8, + 0x00000007,0x0004003b,0x00000133,0x00000407,0x00000007,0x0004003b,0x00000133,0x00000416, + 0x00000007,0x0004003b,0x00000133,0x00000425,0x00000007,0x0004003b,0x00000133,0x00000450, + 0x00000007,0x0004003b,0x00000133,0x00000475,0x00000007,0x0004003b,0x00000133,0x00000485, + 0x00000007,0x0004003b,0x00000133,0x00000495,0x00000007,0x0004003b,0x00000133,0x000004a5, + 0x00000007,0x0004003b,0x00000366,0x000004b3,0x00000007,0x0004003b,0x00000366,0x000004ba, + 0x00000007,0x0003003e,0x000003ab,0x00000289,0x0004003d,0x00000006,0x000003ac,0x00000071, + 0x0004007c,0x0000012f,0x000003ad,0x000003ac,0x00060041,0x00000133,0x000003ae,0x000003ab, + 0x0000013b,0x000000f9,0x0003003e,0x000003ae,0x000003ad,0x0004003d,0x00000006,0x000003af, + 0x00000073,0x0004007c,0x0000012f,0x000003b0,0x000003af,0x00060041,0x00000133,0x000003b1, + 0x000003ab,0x0000013b,0x000000f8,0x0003003e,0x000003b1,0x000003b0,0x0004003d,0x00000006, + 0x000003b2,0x00000075,0x0004007c,0x0000012f,0x000003b3,0x000003b2,0x00060041,0x00000133, + 0x000003b4,0x000003ab,0x0000013b,0x000000fb,0x0003003e,0x000003b4,0x000003b3,0x0004003d, + 0x00000006,0x000003b5,0x00000077,0x0004007c,0x0000012f,0x000003b6,0x000003b5,0x00060041, + 0x00000133,0x000003b7,0x000003ab,0x0000013b,0x00000103,0x0003003e,0x000003b7,0x000003b6, + 0x0004003d,0x00000006,0x000003b8,0x00000072,0x0004007c,0x0000012f,0x000003b9,0x000003b8, + 0x00060041,0x00000133,0x000003ba,0x000003ab,0x00000149,0x000000f9,0x0003003e,0x000003ba, + 0x000003b9,0x0004003d,0x00000006,0x000003bb,0x00000074,0x0004007c,0x0000012f,0x000003bc, + 0x000003bb,0x00060041,0x00000133,0x000003bd,0x000003ab,0x00000149,0x000000f8,0x0003003e, + 0x000003bd,0x000003bc,0x0004003d,0x00000006,0x000003be,0x00000076,0x0004007c,0x0000012f, + 0x000003bf,0x000003be,0x00060041,0x00000133,0x000003c0,0x000003ab,0x00000149,0x000000fb, + 0x0003003e,0x000003c0,0x000003bf,0x0004003d,0x00000006,0x000003c1,0x00000078,0x0004007c, + 0x0000012f,0x000003c2,0x000003c1,0x00060041,0x00000133,0x000003c3,0x000003ab,0x00000149, + 0x00000103,0x0003003e,0x000003c3,0x000003c2,0x00060041,0x00000133,0x000003c4,0x000003ab, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000003c5,0x000003c4,0x000500c7,0x0000012f, + 0x000003c6,0x000003c5,0x000001db,0x000500c4,0x0000012f,0x000003c7,0x000003c6,0x00000149, + 0x00060041,0x00000133,0x000003c8,0x000003ab,0x0000013b,0x000000f9,0x0004003d,0x0000012f, + 0x000003c9,0x000003c8,0x000500c5,0x0000012f,0x000003ca,0x000003c9,0x000003c7,0x00060041, + 0x00000133,0x000003cb,0x000003ab,0x0000013b,0x000000f9,0x0003003e,0x000003cb,0x000003ca, + 0x00060041,0x00000133,0x000003cc,0x000003ab,0x00000149,0x000000f8,0x0004003d,0x0000012f, + 0x000003cd,0x000003cc,0x000500c7,0x0000012f,0x000003ce,0x000003cd,0x000001db,0x000500c4, + 0x0000012f,0x000003cf,0x000003ce,0x00000149,0x00060041,0x00000133,0x000003d0,0x000003ab, + 0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x000003d1,0x000003d0,0x000500c5,0x0000012f, + 0x000003d2,0x000003d1,0x000003cf,0x00060041,0x00000133,0x000003d3,0x000003ab,0x0000013b, + 0x000000f8,0x0003003e,0x000003d3,0x000003d2,0x00060041,0x00000133,0x000003d4,0x000003ab, + 0x00000149,0x000000fb,0x0004003d,0x0000012f,0x000003d5,0x000003d4,0x000500c7,0x0000012f, + 0x000003d6,0x000003d5,0x000001db,0x000500c4,0x0000012f,0x000003d7,0x000003d6,0x00000149, + 0x00060041,0x00000133,0x000003d8,0x000003ab,0x0000013b,0x000000fb,0x0004003d,0x0000012f, + 0x000003d9,0x000003d8,0x000500c5,0x0000012f,0x000003da,0x000003d9,0x000003d7,0x00060041, + 0x00000133,0x000003db,0x000003ab,0x0000013b,0x000000fb,0x0003003e,0x000003db,0x000003da, + 0x00060041,0x00000133,0x000003dc,0x000003ab,0x00000149,0x00000103,0x0004003d,0x0000012f, + 0x000003dd,0x000003dc,0x000500c7,0x0000012f,0x000003de,0x000003dd,0x000001db,0x000500c4, + 0x0000012f,0x000003df,0x000003de,0x00000149,0x00060041,0x00000133,0x000003e0,0x000003ab, + 0x0000013b,0x00000103,0x0004003d,0x0000012f,0x000003e1,0x000003e0,0x000500c5,0x0000012f, + 0x000003e2,0x000003e1,0x000003df,0x00060041,0x00000133,0x000003e3,0x000003ab,0x0000013b, + 0x00000103,0x0003003e,0x000003e3,0x000003e2,0x00060041,0x00000133,0x000003e4,0x000003ab, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000003e5,0x000003e4,0x000500c7,0x0000012f, + 0x000003e6,0x000003e5,0x000001e5,0x00060041,0x00000133,0x000003e7,0x000003ab,0x00000149, + 0x000000f9,0x0003003e,0x000003e7,0x000003e6,0x00060041,0x00000133,0x000003e8,0x000003ab, + 0x00000149,0x000000f8,0x0004003d,0x0000012f,0x000003e9,0x000003e8,0x000500c7,0x0000012f, + 0x000003ea,0x000003e9,0x000001e5,0x00060041,0x00000133,0x000003eb,0x000003ab,0x00000149, + 0x000000f8,0x0003003e,0x000003eb,0x000003ea,0x00060041,0x00000133,0x000003ec,0x000003ab, + 0x00000149,0x000000fb,0x0004003d,0x0000012f,0x000003ed,0x000003ec,0x000500c7,0x0000012f, + 0x000003ee,0x000003ed,0x000001e5,0x00060041,0x00000133,0x000003ef,0x000003ab,0x00000149, + 0x000000fb,0x0003003e,0x000003ef,0x000003ee,0x00060041,0x00000133,0x000003f0,0x000003ab, + 0x00000149,0x00000103,0x0004003d,0x0000012f,0x000003f1,0x000003f0,0x000500c7,0x0000012f, + 0x000003f2,0x000003f1,0x000001e5,0x00060041,0x00000133,0x000003f3,0x000003ab,0x00000149, + 0x00000103,0x0003003e,0x000003f3,0x000003f2,0x00060041,0x00000133,0x000003f4,0x000003ab, + 0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000003f5,0x000003f4,0x000500c7,0x0000012f, + 0x000003f6,0x000003f5,0x000001eb,0x000500ad,0x00000093,0x000003f7,0x000003f6,0x0000013b, + 0x000300f7,0x000003fa,0x00000000,0x000400fa,0x000003f7,0x000003f9,0x000003fe,0x000200f8, + 0x000003f9,0x00060041,0x00000133,0x000003fb,0x000003ab,0x00000149,0x000000f9,0x0004003d, + 0x0000012f,0x000003fc,0x000003fb,0x00050082,0x0000012f,0x000003fd,0x000003fc,0x000001db, + 0x0003003e,0x000003f8,0x000003fd,0x000200f9,0x000003fa,0x000200f8,0x000003fe,0x00060041, + 0x00000133,0x000003ff,0x000003ab,0x00000149,0x000000f9,0x0004003d,0x0000012f,0x00000400, + 0x000003ff,0x0003003e,0x000003f8,0x00000400,0x000200f9,0x000003fa,0x000200f8,0x000003fa, + 0x0004003d,0x0000012f,0x00000401,0x000003f8,0x00060041,0x00000133,0x00000402,0x000003ab, + 0x00000149,0x000000f9,0x0003003e,0x00000402,0x00000401,0x00060041,0x00000133,0x00000403, + 0x000003ab,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x00000404,0x00000403,0x000500c7, + 0x0000012f,0x00000405,0x00000404,0x000001eb,0x000500ad,0x00000093,0x00000406,0x00000405, + 0x0000013b,0x000300f7,0x00000409,0x00000000,0x000400fa,0x00000406,0x00000408,0x0000040d, + 0x000200f8,0x00000408,0x00060041,0x00000133,0x0000040a,0x000003ab,0x00000149,0x000000f8, + 0x0004003d,0x0000012f,0x0000040b,0x0000040a,0x00050082,0x0000012f,0x0000040c,0x0000040b, + 0x000001db,0x0003003e,0x00000407,0x0000040c,0x000200f9,0x00000409,0x000200f8,0x0000040d, + 0x00060041,0x00000133,0x0000040e,0x000003ab,0x00000149,0x000000f8,0x0004003d,0x0000012f, + 0x0000040f,0x0000040e,0x0003003e,0x00000407,0x0000040f,0x000200f9,0x00000409,0x000200f8, + 0x00000409,0x0004003d,0x0000012f,0x00000410,0x00000407,0x00060041,0x00000133,0x00000411, + 0x000003ab,0x00000149,0x000000f8,0x0003003e,0x00000411,0x00000410,0x00060041,0x00000133, + 0x00000412,0x000003ab,0x00000149,0x000000fb,0x0004003d,0x0000012f,0x00000413,0x00000412, + 0x000500c7,0x0000012f,0x00000414,0x00000413,0x000001eb,0x000500ad,0x00000093,0x00000415, + 0x00000414,0x0000013b,0x000300f7,0x00000418,0x00000000,0x000400fa,0x00000415,0x00000417, + 0x0000041c,0x000200f8,0x00000417,0x00060041,0x00000133,0x00000419,0x000003ab,0x00000149, + 0x000000fb,0x0004003d,0x0000012f,0x0000041a,0x00000419,0x00050082,0x0000012f,0x0000041b, + 0x0000041a,0x000001db,0x0003003e,0x00000416,0x0000041b,0x000200f9,0x00000418,0x000200f8, + 0x0000041c,0x00060041,0x00000133,0x0000041d,0x000003ab,0x00000149,0x000000fb,0x0004003d, + 0x0000012f,0x0000041e,0x0000041d,0x0003003e,0x00000416,0x0000041e,0x000200f9,0x00000418, + 0x000200f8,0x00000418,0x0004003d,0x0000012f,0x0000041f,0x00000416,0x00060041,0x00000133, + 0x00000420,0x000003ab,0x00000149,0x000000fb,0x0003003e,0x00000420,0x0000041f,0x00060041, + 0x00000133,0x00000421,0x000003ab,0x00000149,0x00000103,0x0004003d,0x0000012f,0x00000422, + 0x00000421,0x000500c7,0x0000012f,0x00000423,0x00000422,0x000001eb,0x000500ad,0x00000093, + 0x00000424,0x00000423,0x0000013b,0x000300f7,0x00000427,0x00000000,0x000400fa,0x00000424, + 0x00000426,0x0000042b,0x000200f8,0x00000426,0x00060041,0x00000133,0x00000428,0x000003ab, + 0x00000149,0x00000103,0x0004003d,0x0000012f,0x00000429,0x00000428,0x00050082,0x0000012f, + 0x0000042a,0x00000429,0x000001db,0x0003003e,0x00000425,0x0000042a,0x000200f9,0x00000427, + 0x000200f8,0x0000042b,0x00060041,0x00000133,0x0000042c,0x000003ab,0x00000149,0x00000103, + 0x0004003d,0x0000012f,0x0000042d,0x0000042c,0x0003003e,0x00000425,0x0000042d,0x000200f9, + 0x00000427,0x000200f8,0x00000427,0x0004003d,0x0000012f,0x0000042e,0x00000425,0x00060041, + 0x00000133,0x0000042f,0x000003ab,0x00000149,0x00000103,0x0003003e,0x0000042f,0x0000042e, + 0x00060041,0x00000133,0x00000430,0x000003ab,0x0000013b,0x000000f9,0x0004003d,0x0000012f, + 0x00000431,0x00000430,0x000500c3,0x0000012f,0x00000432,0x00000431,0x00000149,0x00060041, + 0x00000133,0x00000433,0x000003ab,0x0000013b,0x000000f9,0x0003003e,0x00000433,0x00000432, + 0x00060041,0x00000133,0x00000434,0x000003ab,0x0000013b,0x000000f8,0x0004003d,0x0000012f, + 0x00000435,0x00000434,0x000500c3,0x0000012f,0x00000436,0x00000435,0x00000149,0x00060041, + 0x00000133,0x00000437,0x000003ab,0x0000013b,0x000000f8,0x0003003e,0x00000437,0x00000436, + 0x00060041,0x00000133,0x00000438,0x000003ab,0x0000013b,0x000000fb,0x0004003d,0x0000012f, + 0x00000439,0x00000438,0x000500c3,0x0000012f,0x0000043a,0x00000439,0x00000149,0x00060041, + 0x00000133,0x0000043b,0x000003ab,0x0000013b,0x000000fb,0x0003003e,0x0000043b,0x0000043a, + 0x00060041,0x00000133,0x0000043c,0x000003ab,0x0000013b,0x00000103,0x0004003d,0x0000012f, + 0x0000043d,0x0000043c,0x000500c3,0x0000012f,0x0000043e,0x0000043d,0x00000149,0x00060041, + 0x00000133,0x0000043f,0x000003ab,0x0000013b,0x00000103,0x0003003e,0x0000043f,0x0000043e, + 0x00060041,0x00000133,0x00000440,0x000003ab,0x00000149,0x000000f9,0x0004003d,0x0000012f, + 0x00000441,0x00000440,0x000500c3,0x0000012f,0x00000442,0x00000441,0x00000149,0x00060041, + 0x00000133,0x00000443,0x000003ab,0x00000149,0x000000f9,0x0003003e,0x00000443,0x00000442, + 0x00060041,0x00000133,0x00000444,0x000003ab,0x00000149,0x000000f8,0x0004003d,0x0000012f, + 0x00000445,0x00000444,0x000500c3,0x0000012f,0x00000446,0x00000445,0x00000149,0x00060041, + 0x00000133,0x00000447,0x000003ab,0x00000149,0x000000f8,0x0003003e,0x00000447,0x00000446, + 0x00060041,0x00000133,0x00000448,0x000003ab,0x00000149,0x000000fb,0x0004003d,0x0000012f, + 0x00000449,0x00000448,0x000500c3,0x0000012f,0x0000044a,0x00000449,0x00000149,0x00060041, + 0x00000133,0x0000044b,0x000003ab,0x00000149,0x000000fb,0x0003003e,0x0000044b,0x0000044a, + 0x00060041,0x00000133,0x0000044c,0x000003ab,0x00000149,0x00000103,0x0004003d,0x0000012f, + 0x0000044d,0x0000044c,0x000500c3,0x0000012f,0x0000044e,0x0000044d,0x00000149,0x00060041, + 0x00000133,0x0000044f,0x000003ab,0x00000149,0x00000103,0x0003003e,0x0000044f,0x0000044e, + 0x00060041,0x00000133,0x00000451,0x000003ab,0x00000149,0x000000f9,0x0004003d,0x0000012f, + 0x00000452,0x00000451,0x00060041,0x00000133,0x00000453,0x000003ab,0x00000149,0x000000f8, + 0x0004003d,0x0000012f,0x00000454,0x00000453,0x00050080,0x0000012f,0x00000455,0x00000452, + 0x00000454,0x00060041,0x00000133,0x00000456,0x000003ab,0x00000149,0x000000fb,0x0004003d, + 0x0000012f,0x00000457,0x00000456,0x00050080,0x0000012f,0x00000458,0x00000455,0x00000457, + 0x000500af,0x00000093,0x00000459,0x00000458,0x0000013b,0x000600a9,0x0000012f,0x0000045a, + 0x00000459,0x00000149,0x0000013b,0x0003003e,0x00000450,0x0000045a,0x00060041,0x00000133, + 0x0000045b,0x000003ab,0x0000013b,0x000000f9,0x0004003d,0x0000012f,0x0000045c,0x0000045b, + 0x00060041,0x00000133,0x0000045d,0x000003ab,0x00000149,0x000000f9,0x0004003d,0x0000012f, + 0x0000045e,0x0000045d,0x00050080,0x0000012f,0x0000045f,0x0000045e,0x0000045c,0x00060041, + 0x00000133,0x00000460,0x000003ab,0x00000149,0x000000f9,0x0003003e,0x00000460,0x0000045f, + 0x00060041,0x00000133,0x00000461,0x000003ab,0x0000013b,0x000000f8,0x0004003d,0x0000012f, + 0x00000462,0x00000461,0x00060041,0x00000133,0x00000463,0x000003ab,0x00000149,0x000000f8, + 0x0004003d,0x0000012f,0x00000464,0x00000463,0x00050080,0x0000012f,0x00000465,0x00000464, + 0x00000462,0x00060041,0x00000133,0x00000466,0x000003ab,0x00000149,0x000000f8,0x0003003e, + 0x00000466,0x00000465,0x00060041,0x00000133,0x00000467,0x000003ab,0x0000013b,0x000000fb, + 0x0004003d,0x0000012f,0x00000468,0x00000467,0x00060041,0x00000133,0x00000469,0x000003ab, + 0x00000149,0x000000fb,0x0004003d,0x0000012f,0x0000046a,0x00000469,0x00050080,0x0000012f, + 0x0000046b,0x0000046a,0x00000468,0x00060041,0x00000133,0x0000046c,0x000003ab,0x00000149, + 0x000000fb,0x0003003e,0x0000046c,0x0000046b,0x00060041,0x00000133,0x0000046d,0x000003ab, + 0x0000013b,0x00000103,0x0004003d,0x0000012f,0x0000046e,0x0000046d,0x00060041,0x00000133, + 0x0000046f,0x000003ab,0x00000149,0x00000103,0x0004003d,0x0000012f,0x00000470,0x0000046f, + 0x00050080,0x0000012f,0x00000471,0x00000470,0x0000046e,0x00060041,0x00000133,0x00000472, + 0x000003ab,0x00000149,0x00000103,0x0003003e,0x00000472,0x00000471,0x0004003d,0x0000012f, + 0x00000473,0x00000450,0x000500aa,0x00000093,0x00000474,0x00000473,0x0000013b,0x000300f7, + 0x00000477,0x00000000,0x000400fa,0x00000474,0x00000476,0x0000047e,0x000200f8,0x00000476, + 0x00060041,0x00000133,0x00000478,0x000003ab,0x0000013b,0x000000f9,0x0004003d,0x0000012f, + 0x00000479,0x00000478,0x00060041,0x00000133,0x0000047a,0x000003ab,0x0000013b,0x000000fb, + 0x0004003d,0x0000012f,0x0000047b,0x0000047a,0x00050080,0x0000012f,0x0000047c,0x00000479, + 0x0000047b,0x000500c3,0x0000012f,0x0000047d,0x0000047c,0x00000149,0x0003003e,0x00000475, + 0x0000047d,0x000200f9,0x00000477,0x000200f8,0x0000047e,0x00060041,0x00000133,0x0000047f, + 0x000003ab,0x0000013b,0x000000f9,0x0004003d,0x0000012f,0x00000480,0x0000047f,0x0003003e, + 0x00000475,0x00000480,0x000200f9,0x00000477,0x000200f8,0x00000477,0x0004003d,0x0000012f, + 0x00000481,0x00000475,0x00060041,0x00000133,0x00000482,0x000003ab,0x0000013b,0x000000f9, + 0x0003003e,0x00000482,0x00000481,0x0004003d,0x0000012f,0x00000483,0x00000450,0x000500aa, + 0x00000093,0x00000484,0x00000483,0x0000013b,0x000300f7,0x00000487,0x00000000,0x000400fa, + 0x00000484,0x00000486,0x0000048e,0x000200f8,0x00000486,0x00060041,0x00000133,0x00000488, + 0x000003ab,0x0000013b,0x000000f8,0x0004003d,0x0000012f,0x00000489,0x00000488,0x00060041, + 0x00000133,0x0000048a,0x000003ab,0x0000013b,0x000000fb,0x0004003d,0x0000012f,0x0000048b, + 0x0000048a,0x00050080,0x0000012f,0x0000048c,0x00000489,0x0000048b,0x000500c3,0x0000012f, + 0x0000048d,0x0000048c,0x00000149,0x0003003e,0x00000485,0x0000048d,0x000200f9,0x00000487, + 0x000200f8,0x0000048e,0x00060041,0x00000133,0x0000048f,0x000003ab,0x0000013b,0x000000f8, + 0x0004003d,0x0000012f,0x00000490,0x0000048f,0x0003003e,0x00000485,0x00000490,0x000200f9, + 0x00000487,0x000200f8,0x00000487,0x0004003d,0x0000012f,0x00000491,0x00000485,0x00060041, + 0x00000133,0x00000492,0x000003ab,0x0000013b,0x000000f8,0x0003003e,0x00000492,0x00000491, + 0x0004003d,0x0000012f,0x00000493,0x00000450,0x000500aa,0x00000093,0x00000494,0x00000493, + 0x0000013b,0x000300f7,0x00000497,0x00000000,0x000400fa,0x00000494,0x00000496,0x0000049e, + 0x000200f8,0x00000496,0x00060041,0x00000133,0x00000498,0x000003ab,0x00000149,0x000000f9, + 0x0004003d,0x0000012f,0x00000499,0x00000498,0x00060041,0x00000133,0x0000049a,0x000003ab, + 0x00000149,0x000000fb,0x0004003d,0x0000012f,0x0000049b,0x0000049a,0x00050080,0x0000012f, + 0x0000049c,0x00000499,0x0000049b,0x000500c3,0x0000012f,0x0000049d,0x0000049c,0x00000149, + 0x0003003e,0x00000495,0x0000049d,0x000200f9,0x00000497,0x000200f8,0x0000049e,0x00060041, + 0x00000133,0x0000049f,0x000003ab,0x00000149,0x000000f9,0x0004003d,0x0000012f,0x000004a0, + 0x0000049f,0x0003003e,0x00000495,0x000004a0,0x000200f9,0x00000497,0x000200f8,0x00000497, + 0x0004003d,0x0000012f,0x000004a1,0x00000495,0x00060041,0x00000133,0x000004a2,0x000003ab, + 0x00000149,0x000000f9,0x0003003e,0x000004a2,0x000004a1,0x0004003d,0x0000012f,0x000004a3, + 0x00000450,0x000500aa,0x00000093,0x000004a4,0x000004a3,0x0000013b,0x000300f7,0x000004a7, + 0x00000000,0x000400fa,0x000004a4,0x000004a6,0x000004ae,0x000200f8,0x000004a6,0x00060041, + 0x00000133,0x000004a8,0x000003ab,0x00000149,0x000000f8,0x0004003d,0x0000012f,0x000004a9, + 0x000004a8,0x00060041,0x00000133,0x000004aa,0x000003ab,0x00000149,0x000000fb,0x0004003d, + 0x0000012f,0x000004ab,0x000004aa,0x00050080,0x0000012f,0x000004ac,0x000004a9,0x000004ab, + 0x000500c3,0x0000012f,0x000004ad,0x000004ac,0x00000149,0x0003003e,0x000004a5,0x000004ad, + 0x000200f9,0x000004a7,0x000200f8,0x000004ae,0x00060041,0x00000133,0x000004af,0x000003ab, + 0x00000149,0x000000f8,0x0004003d,0x0000012f,0x000004b0,0x000004af,0x0003003e,0x000004a5, + 0x000004b0,0x000200f9,0x000004a7,0x000200f8,0x000004a7,0x0004003d,0x0000012f,0x000004b1, + 0x000004a5,0x00060041,0x00000133,0x000004b2,0x000003ab,0x00000149,0x000000f8,0x0003003e, + 0x000004b2,0x000004b1,0x0004003d,0x0000012f,0x000004b4,0x00000450,0x00050082,0x0000012f, + 0x000004b5,0x00000149,0x000004b4,0x00050041,0x00000366,0x000004b6,0x000003ab,0x000004b5, + 0x0004003d,0x00000284,0x000004b7,0x000004b6,0x0008000c,0x00000284,0x000004b9,0x00000001, + 0x0000002d,0x000004b7,0x000004b8,0x00000288,0x0003003e,0x000004b3,0x000004b9,0x0004003d, + 0x0000012f,0x000004bb,0x00000450,0x00050041,0x00000366,0x000004bc,0x000003ab,0x000004bb, + 0x0004003d,0x00000284,0x000004bd,0x000004bc,0x0008000c,0x00000284,0x000004be,0x00000001, + 0x0000002d,0x000004bd,0x000004b8,0x00000288,0x0003003e,0x000004ba,0x000004be,0x0004003d, + 0x00000284,0x000004bf,0x000004b3,0x0004007c,0x00000007,0x000004c0,0x000004bf,0x0003003e, + 0x0000006f,0x000004c0,0x0004003d,0x00000284,0x000004c1,0x000004ba,0x0004007c,0x00000007, + 0x000004c2,0x000004c1,0x0003003e,0x00000070,0x000004c2,0x000100fd,0x00010038,0x00050036, + 0x00000006,0x0000007d,0x00000000,0x0000007b,0x00030037,0x00000008,0x0000007c,0x000200f8, + 0x0000007e,0x0004003b,0x00000008,0x000004c3,0x00000007,0x0004003d,0x00000006,0x000004c4, + 0x0000007c,0x0003003e,0x000004c3,0x000004c4,0x0004003d,0x00000006,0x000004c5,0x000004c3, + 0x000500c2,0x00000006,0x000004c7,0x000004c5,0x000004c6,0x0004003d,0x00000006,0x000004c8, + 0x000004c3,0x000500c6,0x00000006,0x000004c9,0x000004c8,0x000004c7,0x0003003e,0x000004c3, + 0x000004c9,0x0004003d,0x00000006,0x000004cb,0x000004c3,0x00050084,0x00000006,0x000004cc, + 0x000004cb,0x000004ca,0x0003003e,0x000004c3,0x000004cc,0x0004003d,0x00000006,0x000004cd, + 0x000004c3,0x000500c2,0x00000006,0x000004ce,0x000004cd,0x00000130,0x0004003d,0x00000006, + 0x000004cf,0x000004c3,0x000500c6,0x00000006,0x000004d0,0x000004cf,0x000004ce,0x0003003e, + 0x000004c3,0x000004d0,0x0004003d,0x00000006,0x000004d1,0x000004c3,0x000500c4,0x00000006, + 0x000004d3,0x000004d1,0x000004d2,0x0004003d,0x00000006,0x000004d4,0x000004c3,0x00050080, + 0x00000006,0x000004d5,0x000004d4,0x000004d3,0x0003003e,0x000004c3,0x000004d5,0x0004003d, + 0x00000006,0x000004d6,0x000004c3,0x000500c2,0x00000006,0x000004d8,0x000004d6,0x000004d7, + 0x0004003d,0x00000006,0x000004d9,0x000004c3,0x000500c6,0x00000006,0x000004da,0x000004d9, + 0x000004d8,0x0003003e,0x000004c3,0x000004da,0x0004003d,0x00000006,0x000004db,0x000004c3, + 0x000500c2,0x00000006,0x000004dd,0x000004db,0x000004dc,0x0004003d,0x00000006,0x000004de, + 0x000004c3,0x000500c6,0x00000006,0x000004df,0x000004de,0x000004dd,0x0003003e,0x000004c3, + 0x000004df,0x0004003d,0x00000006,0x000004e0,0x000004c3,0x000500c4,0x00000006,0x000004e2, + 0x000004e0,0x000004e1,0x0004003d,0x00000006,0x000004e3,0x000004c3,0x000500c6,0x00000006, + 0x000004e4,0x000004e3,0x000004e2,0x0003003e,0x000004c3,0x000004e4,0x0004003d,0x00000006, + 0x000004e5,0x000004c3,0x000500c2,0x00000006,0x000004e7,0x000004e5,0x000004e6,0x0004003d, + 0x00000006,0x000004e8,0x000004c3,0x000500c6,0x00000006,0x000004e9,0x000004e8,0x000004e7, + 0x0003003e,0x000004c3,0x000004e9,0x0004003d,0x00000006,0x000004ea,0x000004c3,0x000200fe, + 0x000004ea,0x00010038,0x00050036,0x00000006,0x00000085,0x00000000,0x0000007f,0x00030037, + 0x00000008,0x00000080,0x00030037,0x00000008,0x00000081,0x00030037,0x00000008,0x00000082, + 0x00030037,0x00000008,0x00000083,0x00030037,0x00000008,0x00000084,0x000200f8,0x00000086, + 0x0004003b,0x00000008,0x000004f3,0x00000007,0x0004003b,0x00000008,0x000004f4,0x00000007, + 0x0004003b,0x00000008,0x000004f7,0x00000007,0x0004003b,0x00000008,0x000004fb,0x00000007, + 0x0004003b,0x00000008,0x00000500,0x00000007,0x0004003b,0x00000008,0x00000504,0x00000007, + 0x0004003b,0x00000008,0x00000509,0x00000007,0x0004003b,0x00000008,0x0000050d,0x00000007, + 0x0004003b,0x00000008,0x00000512,0x00000007,0x0004003b,0x00000008,0x00000517,0x00000007, + 0x0004003b,0x00000008,0x0000051c,0x00000007,0x0004003b,0x00000008,0x00000521,0x00000007, + 0x0004003b,0x00000008,0x00000526,0x00000007,0x0004003b,0x00000008,0x0000052b,0x00000007, + 0x0004003b,0x00000008,0x0000055c,0x00000007,0x0004003b,0x00000008,0x00000562,0x00000007, + 0x0004003b,0x00000008,0x00000571,0x00000007,0x0004003b,0x00000008,0x0000059d,0x00000007, + 0x0004003b,0x00000008,0x000005ad,0x00000007,0x0004003b,0x00000008,0x000005bd,0x00000007, + 0x0004003b,0x00000008,0x000005cc,0x00000007,0x0004003b,0x00000008,0x000005fc,0x00000007, + 0x0004003d,0x00000006,0x000004ed,0x00000084,0x00050082,0x00000006,0x000004ee,0x000004ed, + 0x000000f8,0x00050084,0x00000006,0x000004f0,0x000004ee,0x000004ef,0x0004003d,0x00000006, + 0x000004f1,0x00000080,0x00050080,0x00000006,0x000004f2,0x000004f1,0x000004f0,0x0003003e, + 0x00000080,0x000004f2,0x0004003d,0x00000006,0x000004f5,0x00000080,0x0003003e,0x000004f4, + 0x000004f5,0x00050039,0x00000006,0x000004f6,0x0000007d,0x000004f4,0x0003003e,0x000004f3, + 0x000004f6,0x0004003d,0x00000006,0x000004f8,0x000004f3,0x000500c7,0x00000006,0x000004fa, + 0x000004f8,0x000004f9,0x0003003e,0x000004f7,0x000004fa,0x0004003d,0x00000006,0x000004fc, + 0x000004f3,0x000500c2,0x00000006,0x000004fe,0x000004fc,0x000004fd,0x000500c7,0x00000006, + 0x000004ff,0x000004fe,0x000004f9,0x0003003e,0x000004fb,0x000004ff,0x0004003d,0x00000006, + 0x00000501,0x000004f3,0x000500c2,0x00000006,0x00000502,0x00000501,0x0000023b,0x000500c7, + 0x00000006,0x00000503,0x00000502,0x000004f9,0x0003003e,0x00000500,0x00000503,0x0004003d, + 0x00000006,0x00000505,0x000004f3,0x000500c2,0x00000006,0x00000507,0x00000505,0x00000506, + 0x000500c7,0x00000006,0x00000508,0x00000507,0x000004f9,0x0003003e,0x00000504,0x00000508, + 0x0004003d,0x00000006,0x0000050a,0x000004f3,0x000500c2,0x00000006,0x0000050b,0x0000050a, + 0x000004d2,0x000500c7,0x00000006,0x0000050c,0x0000050b,0x000004f9,0x0003003e,0x00000509, + 0x0000050c,0x0004003d,0x00000006,0x0000050e,0x000004f3,0x000500c2,0x00000006,0x00000510, + 0x0000050e,0x0000050f,0x000500c7,0x00000006,0x00000511,0x00000510,0x000004f9,0x0003003e, + 0x0000050d,0x00000511,0x0004003d,0x00000006,0x00000513,0x000004f3,0x000500c2,0x00000006, + 0x00000515,0x00000513,0x00000514,0x000500c7,0x00000006,0x00000516,0x00000515,0x000004f9, + 0x0003003e,0x00000512,0x00000516,0x0004003d,0x00000006,0x00000518,0x000004f3,0x000500c2, + 0x00000006,0x0000051a,0x00000518,0x00000519,0x000500c7,0x00000006,0x0000051b,0x0000051a, + 0x000004f9,0x0003003e,0x00000517,0x0000051b,0x0004003d,0x00000006,0x0000051d,0x000004f3, + 0x000500c2,0x00000006,0x0000051f,0x0000051d,0x0000051e,0x000500c7,0x00000006,0x00000520, + 0x0000051f,0x000004f9,0x0003003e,0x0000051c,0x00000520,0x0004003d,0x00000006,0x00000522, + 0x000004f3,0x000500c2,0x00000006,0x00000524,0x00000522,0x00000523,0x000500c7,0x00000006, + 0x00000525,0x00000524,0x000004f9,0x0003003e,0x00000521,0x00000525,0x0004003d,0x00000006, + 0x00000527,0x000004f3,0x000500c2,0x00000006,0x00000529,0x00000527,0x00000528,0x000500c7, + 0x00000006,0x0000052a,0x00000529,0x000004f9,0x0003003e,0x00000526,0x0000052a,0x0004003d, + 0x00000006,0x0000052c,0x000004f3,0x000500c2,0x00000006,0x0000052e,0x0000052c,0x0000052d, + 0x0004003d,0x00000006,0x0000052f,0x000004f3,0x000500c4,0x00000006,0x00000530,0x0000052f, + 0x000001a6,0x000500c5,0x00000006,0x00000531,0x0000052e,0x00000530,0x000500c7,0x00000006, + 0x00000532,0x00000531,0x000004f9,0x0003003e,0x0000052b,0x00000532,0x0004003d,0x00000006, + 0x00000533,0x000004f7,0x0004003d,0x00000006,0x00000534,0x000004f7,0x00050084,0x00000006, + 0x00000535,0x00000534,0x00000533,0x0003003e,0x000004f7,0x00000535,0x0004003d,0x00000006, + 0x00000536,0x000004fb,0x0004003d,0x00000006,0x00000537,0x000004fb,0x00050084,0x00000006, + 0x00000538,0x00000537,0x00000536,0x0003003e,0x000004fb,0x00000538,0x0004003d,0x00000006, + 0x00000539,0x00000500,0x0004003d,0x00000006,0x0000053a,0x00000500,0x00050084,0x00000006, + 0x0000053b,0x0000053a,0x00000539,0x0003003e,0x00000500,0x0000053b,0x0004003d,0x00000006, + 0x0000053c,0x00000504,0x0004003d,0x00000006,0x0000053d,0x00000504,0x00050084,0x00000006, + 0x0000053e,0x0000053d,0x0000053c,0x0003003e,0x00000504,0x0000053e,0x0004003d,0x00000006, + 0x0000053f,0x00000509,0x0004003d,0x00000006,0x00000540,0x00000509,0x00050084,0x00000006, + 0x00000541,0x00000540,0x0000053f,0x0003003e,0x00000509,0x00000541,0x0004003d,0x00000006, + 0x00000542,0x0000050d,0x0004003d,0x00000006,0x00000543,0x0000050d,0x00050084,0x00000006, + 0x00000544,0x00000543,0x00000542,0x0003003e,0x0000050d,0x00000544,0x0004003d,0x00000006, + 0x00000545,0x00000512,0x0004003d,0x00000006,0x00000546,0x00000512,0x00050084,0x00000006, + 0x00000547,0x00000546,0x00000545,0x0003003e,0x00000512,0x00000547,0x0004003d,0x00000006, + 0x00000548,0x00000517,0x0004003d,0x00000006,0x00000549,0x00000517,0x00050084,0x00000006, + 0x0000054a,0x00000549,0x00000548,0x0003003e,0x00000517,0x0000054a,0x0004003d,0x00000006, + 0x0000054b,0x0000051c,0x0004003d,0x00000006,0x0000054c,0x0000051c,0x00050084,0x00000006, + 0x0000054d,0x0000054c,0x0000054b,0x0003003e,0x0000051c,0x0000054d,0x0004003d,0x00000006, + 0x0000054e,0x00000521,0x0004003d,0x00000006,0x0000054f,0x00000521,0x00050084,0x00000006, + 0x00000550,0x0000054f,0x0000054e,0x0003003e,0x00000521,0x00000550,0x0004003d,0x00000006, + 0x00000551,0x00000526,0x0004003d,0x00000006,0x00000552,0x00000526,0x00050084,0x00000006, + 0x00000553,0x00000552,0x00000551,0x0003003e,0x00000526,0x00000553,0x0004003d,0x00000006, + 0x00000554,0x0000052b,0x0004003d,0x00000006,0x00000555,0x0000052b,0x00050084,0x00000006, + 0x00000556,0x00000555,0x00000554,0x0003003e,0x0000052b,0x00000556,0x0004003d,0x00000006, + 0x00000557,0x00000080,0x000500c7,0x00000006,0x00000558,0x00000557,0x000000f8,0x000500aa, + 0x00000093,0x00000559,0x00000558,0x000000f8,0x000300f7,0x0000055b,0x00000000,0x000400fa, + 0x00000559,0x0000055a,0x00000567,0x000200f8,0x0000055a,0x0004003d,0x00000006,0x0000055d, + 0x00000080,0x000500c7,0x00000006,0x0000055e,0x0000055d,0x000000fb,0x000500ab,0x00000093, + 0x0000055f,0x0000055e,0x000000f9,0x000600a9,0x0000012f,0x00000560,0x0000055f,0x000004fd, + 0x00000130,0x0004007c,0x00000006,0x00000561,0x00000560,0x0003003e,0x0000055c,0x00000561, + 0x0004003d,0x00000006,0x00000563,0x00000084,0x000500aa,0x00000093,0x00000564,0x00000563, + 0x00000103,0x000600a9,0x0000012f,0x00000565,0x00000564,0x000004e1,0x00000130,0x0004007c, + 0x00000006,0x00000566,0x00000565,0x0003003e,0x00000562,0x00000566,0x000200f9,0x0000055b, + 0x000200f8,0x00000567,0x0004003d,0x00000006,0x00000568,0x00000084,0x000500aa,0x00000093, + 0x00000569,0x00000568,0x00000103,0x000600a9,0x0000012f,0x0000056a,0x00000569,0x000004e1, + 0x00000130,0x0004007c,0x00000006,0x0000056b,0x0000056a,0x0003003e,0x0000055c,0x0000056b, + 0x0004003d,0x00000006,0x0000056c,0x00000080,0x000500c7,0x00000006,0x0000056d,0x0000056c, + 0x000000fb,0x000500ab,0x00000093,0x0000056e,0x0000056d,0x000000f9,0x000600a9,0x0000012f, + 0x0000056f,0x0000056e,0x000004fd,0x00000130,0x0004007c,0x00000006,0x00000570,0x0000056f, + 0x0003003e,0x00000562,0x00000570,0x000200f9,0x0000055b,0x000200f8,0x0000055b,0x0004003d, + 0x00000006,0x00000572,0x00000080,0x000500c7,0x00000006,0x00000574,0x00000572,0x00000573, + 0x000500ab,0x00000093,0x00000575,0x00000574,0x000000f9,0x0004003d,0x00000006,0x00000576, + 0x0000055c,0x0004003d,0x00000006,0x00000577,0x00000562,0x000600a9,0x00000006,0x00000578, + 0x00000575,0x00000576,0x00000577,0x0003003e,0x00000571,0x00000578,0x0004003d,0x00000006, + 0x00000579,0x0000055c,0x0004003d,0x00000006,0x0000057a,0x000004f7,0x000500c2,0x00000006, + 0x0000057b,0x0000057a,0x00000579,0x0003003e,0x000004f7,0x0000057b,0x0004003d,0x00000006, + 0x0000057c,0x00000562,0x0004003d,0x00000006,0x0000057d,0x000004fb,0x000500c2,0x00000006, + 0x0000057e,0x0000057d,0x0000057c,0x0003003e,0x000004fb,0x0000057e,0x0004003d,0x00000006, + 0x0000057f,0x0000055c,0x0004003d,0x00000006,0x00000580,0x00000500,0x000500c2,0x00000006, + 0x00000581,0x00000580,0x0000057f,0x0003003e,0x00000500,0x00000581,0x0004003d,0x00000006, + 0x00000582,0x00000562,0x0004003d,0x00000006,0x00000583,0x00000504,0x000500c2,0x00000006, + 0x00000584,0x00000583,0x00000582,0x0003003e,0x00000504,0x00000584,0x0004003d,0x00000006, + 0x00000585,0x0000055c,0x0004003d,0x00000006,0x00000586,0x00000509,0x000500c2,0x00000006, + 0x00000587,0x00000586,0x00000585,0x0003003e,0x00000509,0x00000587,0x0004003d,0x00000006, + 0x00000588,0x00000562,0x0004003d,0x00000006,0x00000589,0x0000050d,0x000500c2,0x00000006, + 0x0000058a,0x00000589,0x00000588,0x0003003e,0x0000050d,0x0000058a,0x0004003d,0x00000006, + 0x0000058b,0x0000055c,0x0004003d,0x00000006,0x0000058c,0x00000512,0x000500c2,0x00000006, + 0x0000058d,0x0000058c,0x0000058b,0x0003003e,0x00000512,0x0000058d,0x0004003d,0x00000006, + 0x0000058e,0x00000562,0x0004003d,0x00000006,0x0000058f,0x00000517,0x000500c2,0x00000006, + 0x00000590,0x0000058f,0x0000058e,0x0003003e,0x00000517,0x00000590,0x0004003d,0x00000006, + 0x00000591,0x00000571,0x0004003d,0x00000006,0x00000592,0x0000051c,0x000500c2,0x00000006, + 0x00000593,0x00000592,0x00000591,0x0003003e,0x0000051c,0x00000593,0x0004003d,0x00000006, + 0x00000594,0x00000571,0x0004003d,0x00000006,0x00000595,0x00000521,0x000500c2,0x00000006, + 0x00000596,0x00000595,0x00000594,0x0003003e,0x00000521,0x00000596,0x0004003d,0x00000006, + 0x00000597,0x00000571,0x0004003d,0x00000006,0x00000598,0x00000526,0x000500c2,0x00000006, + 0x00000599,0x00000598,0x00000597,0x0003003e,0x00000526,0x00000599,0x0004003d,0x00000006, + 0x0000059a,0x00000571,0x0004003d,0x00000006,0x0000059b,0x0000052b,0x000500c2,0x00000006, + 0x0000059c,0x0000059b,0x0000059a,0x0003003e,0x0000052b,0x0000059c,0x0004003d,0x00000006, + 0x0000059e,0x000004f7,0x0004003d,0x00000006,0x0000059f,0x00000081,0x00050084,0x00000006, + 0x000005a0,0x0000059e,0x0000059f,0x0004003d,0x00000006,0x000005a1,0x000004fb,0x0004003d, + 0x00000006,0x000005a2,0x00000082,0x00050084,0x00000006,0x000005a3,0x000005a1,0x000005a2, + 0x00050080,0x00000006,0x000005a4,0x000005a0,0x000005a3,0x0004003d,0x00000006,0x000005a5, + 0x00000526,0x0004003d,0x00000006,0x000005a6,0x00000083,0x00050084,0x00000006,0x000005a7, + 0x000005a5,0x000005a6,0x00050080,0x00000006,0x000005a8,0x000005a4,0x000005a7,0x0004003d, + 0x00000006,0x000005a9,0x000004f3,0x000500c2,0x00000006,0x000005ab,0x000005a9,0x000005aa, + 0x00050080,0x00000006,0x000005ac,0x000005a8,0x000005ab,0x0003003e,0x0000059d,0x000005ac, + 0x0004003d,0x00000006,0x000005ae,0x00000500,0x0004003d,0x00000006,0x000005af,0x00000081, + 0x00050084,0x00000006,0x000005b0,0x000005ae,0x000005af,0x0004003d,0x00000006,0x000005b1, + 0x00000504,0x0004003d,0x00000006,0x000005b2,0x00000082,0x00050084,0x00000006,0x000005b3, + 0x000005b1,0x000005b2,0x00050080,0x00000006,0x000005b4,0x000005b0,0x000005b3,0x0004003d, + 0x00000006,0x000005b5,0x0000052b,0x0004003d,0x00000006,0x000005b6,0x00000083,0x00050084, + 0x00000006,0x000005b7,0x000005b5,0x000005b6,0x00050080,0x00000006,0x000005b8,0x000005b4, + 0x000005b7,0x0004003d,0x00000006,0x000005b9,0x000004f3,0x000500c2,0x00000006,0x000005bb, + 0x000005b9,0x000005ba,0x00050080,0x00000006,0x000005bc,0x000005b8,0x000005bb,0x0003003e, + 0x000005ad,0x000005bc,0x0004003d,0x00000006,0x000005be,0x00000509,0x0004003d,0x00000006, + 0x000005bf,0x00000081,0x00050084,0x00000006,0x000005c0,0x000005be,0x000005bf,0x0004003d, + 0x00000006,0x000005c1,0x0000050d,0x0004003d,0x00000006,0x000005c2,0x00000082,0x00050084, + 0x00000006,0x000005c3,0x000005c1,0x000005c2,0x00050080,0x00000006,0x000005c4,0x000005c0, + 0x000005c3,0x0004003d,0x00000006,0x000005c5,0x0000051c,0x0004003d,0x00000006,0x000005c6, + 0x00000083,0x00050084,0x00000006,0x000005c7,0x000005c5,0x000005c6,0x00050080,0x00000006, + 0x000005c8,0x000005c4,0x000005c7,0x0004003d,0x00000006,0x000005c9,0x000004f3,0x000500c2, + 0x00000006,0x000005ca,0x000005c9,0x000004e1,0x00050080,0x00000006,0x000005cb,0x000005c8, + 0x000005ca,0x0003003e,0x000005bd,0x000005cb,0x0004003d,0x00000006,0x000005cd,0x00000512, + 0x0004003d,0x00000006,0x000005ce,0x00000081,0x00050084,0x00000006,0x000005cf,0x000005cd, + 0x000005ce,0x0004003d,0x00000006,0x000005d0,0x00000517,0x0004003d,0x00000006,0x000005d1, + 0x00000082,0x00050084,0x00000006,0x000005d2,0x000005d0,0x000005d1,0x00050080,0x00000006, + 0x000005d3,0x000005cf,0x000005d2,0x0004003d,0x00000006,0x000005d4,0x00000521,0x0004003d, + 0x00000006,0x000005d5,0x00000083,0x00050084,0x00000006,0x000005d6,0x000005d4,0x000005d5, + 0x00050080,0x00000006,0x000005d7,0x000005d3,0x000005d6,0x0004003d,0x00000006,0x000005d8, + 0x000004f3,0x000500c2,0x00000006,0x000005d9,0x000005d8,0x000001a6,0x00050080,0x00000006, + 0x000005da,0x000005d7,0x000005d9,0x0003003e,0x000005cc,0x000005da,0x0004003d,0x00000006, + 0x000005db,0x0000059d,0x000500c7,0x00000006,0x000005dc,0x000005db,0x000001af,0x0003003e, + 0x0000059d,0x000005dc,0x0004003d,0x00000006,0x000005dd,0x000005ad,0x000500c7,0x00000006, + 0x000005de,0x000005dd,0x000001af,0x0003003e,0x000005ad,0x000005de,0x0004003d,0x00000006, + 0x000005df,0x000005bd,0x000500c7,0x00000006,0x000005e0,0x000005df,0x000001af,0x0003003e, + 0x000005bd,0x000005e0,0x0004003d,0x00000006,0x000005e1,0x000005cc,0x000500c7,0x00000006, + 0x000005e2,0x000005e1,0x000001af,0x0003003e,0x000005cc,0x000005e2,0x0004003d,0x00000006, + 0x000005e3,0x00000084,0x000500b2,0x00000093,0x000005e4,0x000005e3,0x00000103,0x000300f7, + 0x000005e6,0x00000000,0x000400fa,0x000005e4,0x000005e5,0x000005e6,0x000200f8,0x000005e5, + 0x0003003e,0x000005cc,0x000000f9,0x000200f9,0x000005e6,0x000200f8,0x000005e6,0x0004003d, + 0x00000006,0x000005e7,0x00000084,0x000500b2,0x00000093,0x000005e8,0x000005e7,0x000000fb, + 0x000300f7,0x000005ea,0x00000000,0x000400fa,0x000005e8,0x000005e9,0x000005ea,0x000200f8, + 0x000005e9,0x0003003e,0x000005bd,0x000000f9,0x000200f9,0x000005ea,0x000200f8,0x000005ea, + 0x0004003d,0x00000006,0x000005eb,0x00000084,0x000500b2,0x00000093,0x000005ec,0x000005eb, + 0x000000f8,0x000300f7,0x000005ee,0x00000000,0x000400fa,0x000005ec,0x000005ed,0x000005ee, + 0x000200f8,0x000005ed,0x0003003e,0x000005ad,0x000000f9,0x000200f9,0x000005ee,0x000200f8, + 0x000005ee,0x0004003d,0x00000006,0x000005ef,0x0000059d,0x0004003d,0x00000006,0x000005f0, + 0x000005ad,0x000500ae,0x00000093,0x000005f1,0x000005ef,0x000005f0,0x0004003d,0x00000006, + 0x000005f2,0x0000059d,0x0004003d,0x00000006,0x000005f3,0x000005bd,0x000500ae,0x00000093, + 0x000005f4,0x000005f2,0x000005f3,0x000500a7,0x00000093,0x000005f5,0x000005f1,0x000005f4, + 0x0004003d,0x00000006,0x000005f6,0x0000059d,0x0004003d,0x00000006,0x000005f7,0x000005cc, + 0x000500ae,0x00000093,0x000005f8,0x000005f6,0x000005f7,0x000500a7,0x00000093,0x000005f9, + 0x000005f5,0x000005f8,0x000300f7,0x000005fb,0x00000000,0x000400fa,0x000005f9,0x000005fa, + 0x000005fd,0x000200f8,0x000005fa,0x0003003e,0x000005fc,0x000000f9,0x000200f9,0x000005fb, + 0x000200f8,0x000005fd,0x0004003d,0x00000006,0x000005fe,0x000005ad,0x0004003d,0x00000006, + 0x000005ff,0x000005bd,0x000500ae,0x00000093,0x00000600,0x000005fe,0x000005ff,0x0004003d, + 0x00000006,0x00000601,0x000005ad,0x0004003d,0x00000006,0x00000602,0x000005cc,0x000500ae, + 0x00000093,0x00000603,0x00000601,0x00000602,0x000500a7,0x00000093,0x00000604,0x00000600, + 0x00000603,0x000300f7,0x00000606,0x00000000,0x000400fa,0x00000604,0x00000605,0x00000607, + 0x000200f8,0x00000605,0x0003003e,0x000005fc,0x000000f8,0x000200f9,0x00000606,0x000200f8, + 0x00000607,0x0004003d,0x00000006,0x00000608,0x000005bd,0x0004003d,0x00000006,0x00000609, + 0x000005cc,0x000500ae,0x00000093,0x0000060a,0x00000608,0x00000609,0x000300f7,0x0000060c, + 0x00000000,0x000400fa,0x0000060a,0x0000060b,0x0000060d,0x000200f8,0x0000060b,0x0003003e, + 0x000005fc,0x000000fb,0x000200f9,0x0000060c,0x000200f8,0x0000060d,0x0003003e,0x000005fc, + 0x00000103,0x000200f9,0x0000060c,0x000200f8,0x0000060c,0x000200f9,0x00000606,0x000200f8, + 0x00000606,0x000200f9,0x000005fb,0x000200f8,0x000005fb,0x0004003d,0x00000006,0x0000060e, + 0x000005fc,0x000200fe,0x0000060e,0x00010038,0x00050036,0x00000006,0x0000008c,0x00000000, + 0x0000007f,0x00030037,0x00000008,0x00000087,0x00030037,0x00000008,0x00000088,0x00030037, + 0x00000008,0x00000089,0x00030037,0x00000008,0x0000008a,0x00030037,0x00000008,0x0000008b, + 0x000200f8,0x0000008d,0x0004003b,0x00000008,0x00000622,0x00000007,0x0004003b,0x00000008, + 0x00000623,0x00000007,0x0004003b,0x00000008,0x00000625,0x00000007,0x0004003b,0x00000008, + 0x00000627,0x00000007,0x0004003b,0x00000008,0x00000629,0x00000007,0x0004003b,0x00000008, + 0x0000062b,0x00000007,0x000300f7,0x0000061b,0x00000000,0x000400fa,0x00000619,0x0000061a, + 0x0000061b,0x000200f8,0x0000061a,0x0004003d,0x00000006,0x0000061c,0x00000089,0x000500c4, + 0x00000006,0x0000061d,0x0000061c,0x00000149,0x0003003e,0x00000089,0x0000061d,0x0004003d, + 0x00000006,0x0000061e,0x0000008a,0x000500c4,0x00000006,0x0000061f,0x0000061e,0x00000149, + 0x0003003e,0x0000008a,0x0000061f,0x0004003d,0x00000006,0x00000620,0x0000008b,0x000500c4, + 0x00000006,0x00000621,0x00000620,0x00000149,0x0003003e,0x0000008b,0x00000621,0x000200f9, + 0x0000061b,0x000200f8,0x0000061b,0x0004003d,0x00000006,0x00000624,0x00000088,0x0003003e, + 0x00000623,0x00000624,0x0004003d,0x00000006,0x00000626,0x00000089,0x0003003e,0x00000625, + 0x00000626,0x0004003d,0x00000006,0x00000628,0x0000008a,0x0003003e,0x00000627,0x00000628, + 0x0004003d,0x00000006,0x0000062a,0x0000008b,0x0003003e,0x00000629,0x0000062a,0x0004003d, + 0x00000006,0x0000062c,0x00000087,0x0003003e,0x0000062b,0x0000062c,0x00090039,0x00000006, + 0x0000062d,0x00000085,0x00000623,0x00000625,0x00000627,0x00000629,0x0000062b,0x0003003e, + 0x00000622,0x0000062d,0x0004003d,0x00000006,0x0000062e,0x00000622,0x000200fe,0x0000062e, + 0x00010038,0x00050036,0x00000002,0x00000091,0x00000000,0x0000008e,0x00030037,0x00000007, + 0x0000008f,0x00030037,0x00000008,0x00000090,0x000200f8,0x00000092,0x0004003b,0x00000008, + 0x00000635,0x00000007,0x0004003b,0x00000008,0x00000638,0x00000007,0x0004003b,0x00000008, + 0x0000063b,0x00000007,0x0004003d,0x00000006,0x00000631,0x00000090,0x000500b0,0x00000093, + 0x00000632,0x00000631,0x00000573,0x000300f7,0x00000634,0x00000000,0x000400fa,0x00000632, + 0x00000633,0x00000634,0x000200f8,0x00000633,0x0004003d,0x00000006,0x00000636,0x00000090, + 0x00050086,0x00000006,0x00000637,0x00000636,0x0000010a,0x0003003e,0x00000635,0x00000637, + 0x0004003d,0x00000006,0x00000639,0x00000090,0x00050089,0x00000006,0x0000063a,0x00000639, + 0x0000010a,0x0003003e,0x00000638,0x0000063a,0x0004003d,0x00000006,0x0000063c,0x00000635, + 0x0005004d,0x00000006,0x0000063d,0x0000008f,0x0000063c,0x0004003d,0x00000006,0x0000063e, + 0x00000638,0x00050084,0x00000006,0x0000063f,0x0000063e,0x00000125,0x000500c4,0x00000006, + 0x00000640,0x00000199,0x0000063f,0x000500c7,0x00000006,0x00000641,0x0000063d,0x00000640, + 0x0004003d,0x00000006,0x00000642,0x00000638,0x00050084,0x00000006,0x00000643,0x00000642, + 0x00000125,0x000500c2,0x00000006,0x00000644,0x00000641,0x00000643,0x0003003e,0x0000063b, + 0x00000644,0x0004003d,0x00000006,0x00000645,0x0000063b,0x000500c7,0x00000006,0x00000646, + 0x00000645,0x000004f9,0x000500c4,0x00000006,0x00000647,0x00000646,0x000004fd,0x0004003d, + 0x00000006,0x00000648,0x0000063b,0x000500c2,0x00000006,0x00000649,0x00000648,0x0000010a, + 0x000500c7,0x00000006,0x0000064a,0x00000649,0x000004f9,0x000500c5,0x00000006,0x0000064b, + 0x00000647,0x0000064a,0x0003003e,0x0000063b,0x0000064b,0x0004003d,0x00000006,0x0000064c, + 0x0000063b,0x000500c7,0x00000006,0x0000064e,0x0000064c,0x0000064d,0x000500c4,0x00000006, + 0x0000064f,0x0000064e,0x000001a6,0x0004003d,0x00000006,0x00000650,0x0000063b,0x000500c2, + 0x00000006,0x00000651,0x00000650,0x000000fb,0x000500c7,0x00000006,0x00000652,0x00000651, + 0x0000064d,0x000500c5,0x00000006,0x00000653,0x0000064f,0x00000652,0x0003003e,0x0000063b, + 0x00000653,0x0004003d,0x00000006,0x00000654,0x0000063b,0x000500c7,0x00000006,0x00000656, + 0x00000654,0x00000655,0x000500c4,0x00000006,0x00000657,0x00000656,0x00000149,0x0004003d, + 0x00000006,0x00000658,0x0000063b,0x000500c2,0x00000006,0x00000659,0x00000658,0x000000f8, + 0x000500c7,0x00000006,0x0000065a,0x00000659,0x00000655,0x000500c5,0x00000006,0x0000065b, + 0x00000657,0x0000065a,0x0003003e,0x0000063b,0x0000065b,0x0004003d,0x00000006,0x0000065e, + 0x00000635,0x00050082,0x00000006,0x0000065f,0x00000103,0x0000065e,0x00050041,0x00000660, + 0x00000661,0x0000065d,0x0000065f,0x0004003d,0x00000006,0x00000662,0x0000063b,0x0004003d, + 0x00000006,0x00000663,0x00000638,0x00050082,0x00000006,0x00000664,0x00000103,0x00000663, + 0x00050084,0x00000006,0x00000665,0x00000664,0x00000125,0x000500c4,0x00000006,0x00000666, + 0x00000662,0x00000665,0x000700f1,0x00000006,0x00000667,0x00000661,0x000000f8,0x000000f9, + 0x00000666,0x000200f9,0x00000634,0x000200f8,0x00000634,0x000100fd,0x00010038,0x00050036, + 0x00000002,0x00000099,0x00000000,0x00000096,0x00030037,0x00000006,0x00000097,0x00030037, + 0x00000095,0x00000098,0x000200f8,0x0000009a,0x0004003b,0x00000008,0x00000668,0x00000007, + 0x0004003b,0x00000008,0x0000066b,0x00000007,0x0004003b,0x00000008,0x0000066f,0x00000007, + 0x0004003b,0x00000008,0x00000672,0x00000007,0x0004003b,0x00000008,0x0000067d,0x00000007, + 0x0004003b,0x00000008,0x00000680,0x00000007,0x0004003b,0x00000008,0x000006ca,0x00000007, + 0x0004003b,0x00000008,0x000006cd,0x00000007,0x0004003b,0x00000008,0x0000070a,0x00000007, + 0x0004003b,0x00000008,0x00000713,0x00000007,0x000500c2,0x00000006,0x00000669,0x00000097, + 0x000004fd,0x000500c7,0x00000006,0x0000066a,0x00000669,0x000000f8,0x0003003e,0x00000668, + 0x0000066a,0x000500c2,0x00000006,0x0000066d,0x00000097,0x0000066c,0x000500c7,0x00000006, + 0x0000066e,0x0000066d,0x000000f8,0x0003003e,0x0000066b,0x0000066e,0x000500c2,0x00000006, + 0x00000670,0x00000097,0x000005ba,0x000500c7,0x00000006,0x00000671,0x00000670,0x000000f8, + 0x0003003e,0x0000066f,0x00000671,0x000500c2,0x00000006,0x00000673,0x00000097,0x00000130, + 0x000500c7,0x00000006,0x00000674,0x00000673,0x00000103,0x0003003e,0x00000672,0x00000674, + 0x000500c7,0x00000006,0x00000675,0x00000097,0x00000103,0x000500ab,0x00000093,0x00000676, + 0x00000675,0x000000f9,0x000300f7,0x00000678,0x00000000,0x000400fa,0x00000676,0x00000677, + 0x000006bc,0x000200f8,0x00000677,0x000500c7,0x00000006,0x00000679,0x00000097,0x00000103, + 0x000500c4,0x00000006,0x0000067a,0x00000679,0x00000149,0x0004003d,0x00000006,0x0000067b, + 0x00000668,0x000500c5,0x00000006,0x0000067c,0x0000067b,0x0000067a,0x0003003e,0x00000668, + 0x0000067c,0x000500c2,0x00000006,0x0000067e,0x00000097,0x000004d7,0x000500c7,0x00000006, + 0x0000067f,0x0000067e,0x00000103,0x0003003e,0x0000067d,0x0000067f,0x000500c2,0x00000006, + 0x00000681,0x00000097,0x000001a6,0x000500c7,0x00000006,0x00000682,0x00000681,0x00000103, + 0x0003003e,0x00000680,0x00000682,0x0004003d,0x00000006,0x00000683,0x00000680,0x000500aa, + 0x00000093,0x00000684,0x00000683,0x000000f9,0x000300f7,0x00000686,0x00000000,0x000400fa, + 0x00000684,0x00000685,0x0000068d,0x000200f8,0x00000685,0x0004003d,0x00000006,0x00000687, + 0x0000067d,0x00050080,0x00000006,0x00000688,0x00000687,0x0000010a,0x00050041,0x00000008, + 0x00000689,0x00000098,0x0000013b,0x0003003e,0x00000689,0x00000688,0x0004003d,0x00000006, + 0x0000068a,0x00000672,0x00050080,0x00000006,0x0000068b,0x0000068a,0x000000fb,0x00050041, + 0x00000008,0x0000068c,0x00000098,0x00000149,0x0003003e,0x0000068c,0x0000068b,0x000200f9, + 0x00000686,0x000200f8,0x0000068d,0x0004003d,0x00000006,0x0000068e,0x00000680,0x000500aa, + 0x00000093,0x0000068f,0x0000068e,0x000000f8,0x000300f7,0x00000691,0x00000000,0x000400fa, + 0x0000068f,0x00000690,0x00000698,0x000200f8,0x00000690,0x0004003d,0x00000006,0x00000692, + 0x0000067d,0x00050080,0x00000006,0x00000693,0x00000692,0x00000125,0x00050041,0x00000008, + 0x00000694,0x00000098,0x0000013b,0x0003003e,0x00000694,0x00000693,0x0004003d,0x00000006, + 0x00000695,0x00000672,0x00050080,0x00000006,0x00000696,0x00000695,0x000000fb,0x00050041, + 0x00000008,0x00000697,0x00000098,0x00000149,0x0003003e,0x00000697,0x00000696,0x000200f9, + 0x00000691,0x000200f8,0x00000698,0x0004003d,0x00000006,0x00000699,0x00000680,0x000500aa, + 0x00000093,0x0000069a,0x00000699,0x000000fb,0x000300f7,0x0000069c,0x00000000,0x000400fa, + 0x0000069a,0x0000069b,0x000006a3,0x000200f8,0x0000069b,0x0004003d,0x00000006,0x0000069d, + 0x00000672,0x00050080,0x00000006,0x0000069e,0x0000069d,0x000000fb,0x00050041,0x00000008, + 0x0000069f,0x00000098,0x0000013b,0x0003003e,0x0000069f,0x0000069e,0x0004003d,0x00000006, + 0x000006a0,0x0000067d,0x00050080,0x00000006,0x000006a1,0x000006a0,0x00000125,0x00050041, + 0x00000008,0x000006a2,0x00000098,0x00000149,0x0003003e,0x000006a2,0x000006a1,0x000200f9, + 0x0000069c,0x000200f8,0x000006a3,0x0004003d,0x00000006,0x000006a4,0x00000680,0x000500aa, + 0x00000093,0x000006a5,0x000006a4,0x00000103,0x000300f7,0x000006a7,0x00000000,0x000400fa, + 0x000006a5,0x000006a6,0x000006a7,0x000200f8,0x000006a6,0x0004003d,0x00000006,0x000006a8, + 0x0000067d,0x000500c7,0x00000006,0x000006a9,0x000006a8,0x000000f8,0x0003003e,0x0000067d, + 0x000006a9,0x000500c7,0x00000006,0x000006ab,0x00000097,0x000006aa,0x000500ab,0x00000093, + 0x000006ac,0x000006ab,0x000000f9,0x000300f7,0x000006ae,0x00000000,0x000400fa,0x000006ac, + 0x000006ad,0x000006b5,0x000200f8,0x000006ad,0x0004003d,0x00000006,0x000006af,0x0000067d, + 0x00050080,0x00000006,0x000006b0,0x000006af,0x000000fb,0x00050041,0x00000008,0x000006b1, + 0x00000098,0x0000013b,0x0003003e,0x000006b1,0x000006b0,0x0004003d,0x00000006,0x000006b2, + 0x00000672,0x00050080,0x00000006,0x000006b3,0x000006b2,0x000000fb,0x00050041,0x00000008, + 0x000006b4,0x00000098,0x00000149,0x0003003e,0x000006b4,0x000006b3,0x000200f9,0x000006ae, + 0x000200f8,0x000006b5,0x0004003d,0x00000006,0x000006b6,0x00000672,0x00050080,0x00000006, + 0x000006b7,0x000006b6,0x000000fb,0x00050041,0x00000008,0x000006b8,0x00000098,0x0000013b, + 0x0003003e,0x000006b8,0x000006b7,0x0004003d,0x00000006,0x000006b9,0x0000067d,0x00050080, + 0x00000006,0x000006ba,0x000006b9,0x00000117,0x00050041,0x00000008,0x000006bb,0x00000098, + 0x00000149,0x0003003e,0x000006bb,0x000006ba,0x000200f9,0x000006ae,0x000200f8,0x000006ae, + 0x000200f9,0x000006a7,0x000200f8,0x000006a7,0x000200f9,0x0000069c,0x000200f8,0x0000069c, + 0x000200f9,0x00000691,0x000200f8,0x00000691,0x000200f9,0x00000686,0x000200f8,0x00000686, + 0x000200f9,0x00000678,0x000200f8,0x000006bc,0x000500c2,0x00000006,0x000006bd,0x00000097, + 0x000001a6,0x000500c7,0x00000006,0x000006be,0x000006bd,0x00000103,0x000500c4,0x00000006, + 0x000006bf,0x000006be,0x00000149,0x0004003d,0x00000006,0x000006c0,0x00000668,0x000500c5, + 0x00000006,0x000006c1,0x000006c0,0x000006bf,0x0003003e,0x00000668,0x000006c1,0x000500c2, + 0x00000006,0x000006c2,0x00000097,0x000001a6,0x000500c7,0x00000006,0x000006c3,0x000006c2, + 0x00000103,0x000500aa,0x00000093,0x000006c4,0x000006c3,0x000000f9,0x000300f7,0x000006c6, + 0x00000000,0x000400fa,0x000006c4,0x000006c5,0x000006c6,0x000200f8,0x000006c5,0x00050041, + 0x000006c8,0x000006c9,0x00000098,0x000004e1,0x0003003e,0x000006c9,0x000006c7,0x000200f9, + 0x000006c6,0x000200f8,0x000006c6,0x000500c2,0x00000006,0x000006cb,0x00000097,0x0000066c, + 0x000500c7,0x00000006,0x000006cc,0x000006cb,0x00000103,0x0003003e,0x000006ca,0x000006cc, + 0x000500c2,0x00000006,0x000006ce,0x00000097,0x000004d7,0x000500c7,0x00000006,0x000006cf, + 0x000006ce,0x00000103,0x0003003e,0x000006cd,0x000006cf,0x0004003d,0x00000006,0x000006d0, + 0x000006cd,0x000500aa,0x00000093,0x000006d1,0x000006d0,0x000000f9,0x000300f7,0x000006d3, + 0x00000000,0x000400fa,0x000006d1,0x000006d2,0x000006d9,0x000200f8,0x000006d2,0x00050041, + 0x00000008,0x000006d5,0x00000098,0x0000013b,0x0003003e,0x000006d5,0x000006d4,0x0004003d, + 0x00000006,0x000006d6,0x00000672,0x00050080,0x00000006,0x000006d7,0x000006d6,0x000000fb, + 0x00050041,0x00000008,0x000006d8,0x00000098,0x00000149,0x0003003e,0x000006d8,0x000006d7, + 0x000200f9,0x000006d3,0x000200f8,0x000006d9,0x0004003d,0x00000006,0x000006da,0x000006cd, + 0x000500aa,0x00000093,0x000006db,0x000006da,0x000000f8,0x000300f7,0x000006dd,0x00000000, + 0x000400fa,0x000006db,0x000006dc,0x000006e2,0x000200f8,0x000006dc,0x0004003d,0x00000006, + 0x000006de,0x00000672,0x00050080,0x00000006,0x000006df,0x000006de,0x000000fb,0x00050041, + 0x00000008,0x000006e0,0x00000098,0x00000149,0x0003003e,0x000006e0,0x000006df,0x00050041, + 0x00000008,0x000006e1,0x00000098,0x0000013b,0x0003003e,0x000006e1,0x000006d4,0x000200f9, + 0x000006dd,0x000200f8,0x000006e2,0x0004003d,0x00000006,0x000006e3,0x000006cd,0x000500aa, + 0x00000093,0x000006e4,0x000006e3,0x000000fb,0x000300f7,0x000006e6,0x00000000,0x000400fa, + 0x000006e4,0x000006e5,0x000006ed,0x000200f8,0x000006e5,0x0004003d,0x00000006,0x000006e7, + 0x00000672,0x00050080,0x00000006,0x000006e8,0x000006e7,0x00000117,0x00050041,0x00000008, + 0x000006e9,0x00000098,0x0000013b,0x0003003e,0x000006e9,0x000006e8,0x0004003d,0x00000006, + 0x000006ea,0x000006ca,0x00050080,0x00000006,0x000006eb,0x000006ea,0x00000117,0x00050041, + 0x00000008,0x000006ec,0x00000098,0x00000149,0x0003003e,0x000006ec,0x000006eb,0x0003003e, + 0x0000066f,0x000000f9,0x0003003e,0x0000066b,0x000000f9,0x000200f9,0x000006e6,0x000200f8, + 0x000006ed,0x0004003d,0x00000006,0x000006ee,0x000006cd,0x000500aa,0x00000093,0x000006ef, + 0x000006ee,0x00000103,0x000300f7,0x000006f1,0x00000000,0x000400fa,0x000006ef,0x000006f0, + 0x000006f1,0x000200f8,0x000006f0,0x000500c2,0x00000006,0x000006f2,0x00000097,0x00000130, + 0x000500c7,0x00000006,0x000006f3,0x000006f2,0x00000103,0x000300f7,0x000006f7,0x00000000, + 0x000b00fb,0x000006f3,0x000006f7,0x00000000,0x000006f4,0x00000001,0x000006f5,0x00000002, + 0x000006f6,0x00000003,0x000006f6,0x000200f8,0x000006f4,0x00050041,0x00000008,0x000006f8, + 0x00000098,0x0000013b,0x0003003e,0x000006f8,0x00000117,0x00050041,0x00000008,0x000006fa, + 0x00000098,0x00000149,0x0003003e,0x000006fa,0x000006f9,0x000200f9,0x000006f7,0x000200f8, + 0x000006f5,0x00050041,0x00000008,0x000006fc,0x00000098,0x0000013b,0x0003003e,0x000006fc, + 0x000006f9,0x00050041,0x00000008,0x000006fd,0x00000098,0x00000149,0x0003003e,0x000006fd, + 0x00000117,0x000200f9,0x000006f7,0x000200f8,0x000006f6,0x00050041,0x000006c8,0x000006ff, + 0x00000098,0x000004e1,0x0003003e,0x000006ff,0x000006c7,0x000200f9,0x000006f7,0x000200f8, + 0x000006f7,0x000200f9,0x000006f1,0x000200f8,0x000006f1,0x000200f9,0x000006e6,0x000200f8, + 0x000006e6,0x000200f9,0x000006dd,0x000200f8,0x000006dd,0x000200f9,0x000006d3,0x000200f8, + 0x000006d3,0x000200f9,0x00000678,0x000200f8,0x00000678,0x0004003d,0x00000006,0x00000702, + 0x0000066f,0x00050041,0x00000008,0x00000703,0x00000098,0x00000130,0x0003003e,0x00000703, + 0x00000702,0x0004003d,0x00000006,0x00000704,0x00000668,0x00050082,0x00000006,0x00000705, + 0x00000704,0x000000fb,0x0004003d,0x00000006,0x00000706,0x0000066b,0x00050084,0x00000006, + 0x00000707,0x00000117,0x00000706,0x00050080,0x00000006,0x00000708,0x00000705,0x00000707, + 0x00050041,0x00000008,0x00000709,0x00000098,0x000004dc,0x0003003e,0x00000709,0x00000708, + 0x00050041,0x00000008,0x0000070b,0x00000098,0x0000013b,0x0004003d,0x00000006,0x0000070c, + 0x0000070b,0x00050041,0x00000008,0x0000070d,0x00000098,0x00000149,0x0004003d,0x00000006, + 0x0000070e,0x0000070d,0x00050084,0x00000006,0x0000070f,0x0000070c,0x0000070e,0x0003003e, + 0x0000070a,0x0000070f,0x00050041,0x00000008,0x00000710,0x00000098,0x00000130,0x0004003d, + 0x00000006,0x00000711,0x00000710,0x000500aa,0x00000093,0x00000712,0x00000711,0x000000f8, + 0x000300f7,0x00000715,0x00000000,0x000400fa,0x00000712,0x00000714,0x00000718,0x000200f8, + 0x00000714,0x0004003d,0x00000006,0x00000716,0x0000070a,0x00050084,0x00000006,0x00000717, + 0x000000fb,0x00000716,0x0003003e,0x00000713,0x00000717,0x000200f9,0x00000715,0x000200f8, + 0x00000718,0x0004003d,0x00000006,0x00000719,0x0000070a,0x0003003e,0x00000713,0x00000719, + 0x000200f9,0x00000715,0x000200f8,0x00000715,0x0004003d,0x00000006,0x0000071a,0x00000713, + 0x00050041,0x00000008,0x0000071b,0x00000098,0x000001a6,0x0003003e,0x0000071b,0x0000071a, + 0x000100fd,0x00010038,0x00050036,0x00000006,0x000000a0,0x00000000,0x0000009d,0x00030037, + 0x00000008,0x0000009e,0x00030037,0x0000009c,0x0000009f,0x000200f8,0x000000a1,0x00050041, + 0x00000008,0x0000071d,0x0000009f,0x00000149,0x0004003d,0x00000006,0x0000071e,0x0000071d, + 0x0004003d,0x00000006,0x0000071f,0x0000009e,0x00050084,0x00000006,0x00000720,0x0000071e, + 0x0000071f,0x0004003d,0x00000006,0x00000721,0x0000009e,0x00050041,0x00000008,0x00000722, + 0x0000009f,0x0000013b,0x0004003d,0x00000006,0x00000723,0x00000722,0x00050084,0x00000006, + 0x00000724,0x00000721,0x00000723,0x00050084,0x00000006,0x00000725,0x00000724,0x00000125, + 0x00050080,0x00000006,0x00000726,0x00000725,0x0000010a,0x00050086,0x00000006,0x00000727, + 0x00000726,0x000000fd,0x00050080,0x00000006,0x00000728,0x00000720,0x00000727,0x0004003d, + 0x00000006,0x00000729,0x0000009e,0x00050041,0x00000008,0x0000072a,0x0000009f,0x000001a6, + 0x0004003d,0x00000006,0x0000072b,0x0000072a,0x00050084,0x00000006,0x0000072c,0x00000729, + 0x0000072b,0x00050084,0x00000006,0x0000072d,0x0000072c,0x0000011e,0x00050080,0x00000006, + 0x0000072e,0x0000072d,0x000000fb,0x00050086,0x00000006,0x0000072f,0x0000072e,0x00000103, + 0x00050080,0x00000006,0x00000730,0x00000728,0x0000072f,0x000200fe,0x00000730,0x00010038, + 0x00050036,0x00000002,0x000000a5,0x00000000,0x000000a2,0x00030037,0x00000008,0x000000a3, + 0x00030037,0x0000009c,0x000000a4,0x000200f8,0x000000a6,0x0004003b,0x0000001c,0x00000733, + 0x00000007,0x0004003d,0x00000006,0x00000734,0x000000a3,0x00050041,0x00000735,0x00000736, + 0x000000f7,0x00000734,0x0004003d,0x00000007,0x00000737,0x00000736,0x0003003e,0x00000733, + 0x00000737,0x00050041,0x00000008,0x00000738,0x00000733,0x000000f9,0x0004003d,0x00000006, + 0x00000739,0x00000738,0x00050041,0x00000008,0x0000073a,0x000000a4,0x00000149,0x0003003e, + 0x0000073a,0x00000739,0x00050041,0x00000008,0x0000073b,0x00000733,0x000000f8,0x0004003d, + 0x00000006,0x0000073c,0x0000073b,0x00050041,0x00000008,0x0000073d,0x000000a4,0x0000013b, + 0x0003003e,0x0000073d,0x0000073c,0x00050041,0x00000008,0x0000073e,0x00000733,0x000000fb, + 0x0004003d,0x00000006,0x0000073f,0x0000073e,0x00050041,0x00000008,0x00000740,0x000000a4, + 0x000001a6,0x0003003e,0x00000740,0x0000073f,0x00050041,0x00000008,0x00000741,0x00000733, + 0x00000103,0x0004003d,0x00000006,0x00000742,0x00000741,0x00050041,0x00000008,0x00000743, + 0x000000a4,0x000004dc,0x0003003e,0x00000743,0x00000742,0x000100fd,0x00010038,0x00050036, + 0x00000006,0x000000ad,0x00000000,0x000000a7,0x00030037,0x0000009b,0x000000a8,0x00030037, + 0x00000008,0x000000a9,0x00030037,0x00000007,0x000000aa,0x00030037,0x00000008,0x000000ab, + 0x00030037,0x00000008,0x000000ac,0x000200f8,0x000000ae,0x0004003b,0x00000008,0x00000749, + 0x00000007,0x0004003b,0x00000008,0x0000074c,0x00000007,0x0004003b,0x00000008,0x0000075a, + 0x00000007,0x0004003b,0x00000008,0x0000075d,0x00000007,0x0004003b,0x00000008,0x00000764, + 0x00000007,0x0004003b,0x00000008,0x00000771,0x00000007,0x0004003b,0x00000008,0x00000772, + 0x00000007,0x0004003b,0x00000008,0x0000077a,0x00000007,0x0004003b,0x00000008,0x0000077b, + 0x00000007,0x0004003b,0x00000008,0x00000784,0x00000007,0x0004003b,0x00000008,0x00000785, + 0x00000007,0x0004003b,0x00000008,0x0000078e,0x00000007,0x0004003b,0x00000008,0x0000078f, + 0x00000007,0x0004003b,0x00000008,0x0000079d,0x00000007,0x0004003b,0x00000008,0x0000079e, + 0x00000007,0x0004003b,0x00000008,0x000007a6,0x00000007,0x0004003b,0x00000008,0x000007a7, + 0x00000007,0x0004003b,0x00000008,0x000007b0,0x00000007,0x0004003b,0x00000008,0x000007b1, + 0x00000007,0x0004003b,0x00000008,0x000007bf,0x00000007,0x0004003b,0x00000008,0x000007c0, + 0x00000007,0x0004003b,0x00000008,0x000007c8,0x00000007,0x0004003b,0x00000008,0x000007c9, + 0x00000007,0x0004003b,0x00000008,0x000007d3,0x00000007,0x0004003b,0x00000008,0x000007d4, + 0x00000007,0x0004003b,0x00000008,0x000007dd,0x00000007,0x0004003b,0x00000008,0x000007de, + 0x00000007,0x0004003b,0x00000008,0x000007e6,0x00000007,0x0004003b,0x00000008,0x000007e7, + 0x00000007,0x0004003b,0x00000008,0x000007f0,0x00000007,0x0004003b,0x00000008,0x000007f1, + 0x00000007,0x0004003b,0x00000008,0x000007fa,0x00000007,0x0004003b,0x00000008,0x000007fb, + 0x00000007,0x0004003b,0x00000008,0x00000804,0x00000007,0x0004003b,0x00000008,0x00000805, + 0x00000007,0x0004003b,0x00000008,0x00000809,0x00000007,0x0004003b,0x00000008,0x0000081b, + 0x00000007,0x0004003b,0x00000008,0x00000824,0x00000007,0x0004003b,0x00000008,0x00000828, + 0x00000007,0x0004003b,0x00000008,0x0000082a,0x00000007,0x0004003b,0x00000008,0x0000082c, + 0x00000007,0x0004003b,0x00000008,0x00000839,0x00000007,0x0004003b,0x00000008,0x0000083c, + 0x00000007,0x0004003b,0x00000008,0x00000841,0x00000007,0x0004003b,0x00000008,0x00000851, + 0x00000007,0x0004003b,0x00000008,0x0000085e,0x00000007,0x0004003b,0x00000008,0x0000085f, + 0x00000007,0x0004003b,0x00000008,0x00000867,0x00000007,0x0004003b,0x00000008,0x00000868, + 0x00000007,0x0004003b,0x00000008,0x00000870,0x00000007,0x0004003b,0x00000008,0x00000871, + 0x00000007,0x0004003b,0x00000008,0x0000087b,0x00000007,0x0004003b,0x00000008,0x0000087c, + 0x00000007,0x0004003b,0x00000008,0x00000884,0x00000007,0x0004003b,0x00000008,0x00000885, + 0x00000007,0x0004003b,0x00000008,0x0000088e,0x00000007,0x0004003b,0x00000008,0x0000088f, + 0x00000007,0x0004003b,0x00000008,0x00000893,0x00000007,0x0004003b,0x00000008,0x0000089c, + 0x00000007,0x0004003b,0x00000008,0x000008a5,0x00000007,0x0004003b,0x00000008,0x000008a9, + 0x00000007,0x0004003b,0x00000008,0x000008ab,0x00000007,0x0004003b,0x00000008,0x000008ba, + 0x00000007,0x0004003b,0x00000008,0x000008bc,0x00000007,0x00050051,0x00000006,0x00000745, + 0x000000a8,0x00000000,0x000500ac,0x00000093,0x00000746,0x00000745,0x000000f9,0x000300f7, + 0x00000748,0x00000000,0x000400fa,0x00000746,0x00000747,0x00000834,0x000200f8,0x00000747, + 0x0004003d,0x00000006,0x0000074a,0x000000a9,0x00050086,0x00000006,0x0000074b,0x0000074a, + 0x000000fd,0x0003003e,0x00000749,0x0000074b,0x0004003d,0x00000006,0x0000074d,0x000000a9, + 0x0004003d,0x00000006,0x0000074e,0x00000749,0x00050084,0x00000006,0x0000074f,0x000000fd, + 0x0000074e,0x00050082,0x00000006,0x00000750,0x0000074d,0x0000074f,0x0003003e,0x0000074c, + 0x00000750,0x0004003d,0x00000006,0x00000751,0x00000749,0x00050084,0x00000006,0x00000752, + 0x00000751,0x00000125,0x0004003d,0x00000006,0x00000753,0x00000749,0x00050084,0x00000006, + 0x00000754,0x00000753,0x000000fd,0x00050051,0x00000006,0x00000755,0x000000a8,0x00000001, + 0x00050084,0x00000006,0x00000756,0x00000754,0x00000755,0x00050080,0x00000006,0x00000757, + 0x00000752,0x00000756,0x0004003d,0x00000006,0x00000758,0x000000ab,0x00050080,0x00000006, + 0x00000759,0x00000758,0x00000757,0x0003003e,0x000000ab,0x00000759,0x0004003d,0x00000006, + 0x0000075b,0x000000ac,0x00050086,0x00000006,0x0000075c,0x0000075b,0x000000fd,0x0003003e, + 0x0000075a,0x0000075c,0x0003003e,0x0000075d,0x000000f9,0x0004003d,0x00000006,0x0000075e, + 0x000000ab,0x00050080,0x00000006,0x0000075f,0x0000075e,0x0000011e,0x0004003d,0x00000006, + 0x00000760,0x000000ac,0x000500ac,0x00000093,0x00000761,0x0000075f,0x00000760,0x000300f7, + 0x00000763,0x00000000,0x000400fa,0x00000761,0x00000762,0x000007d7,0x000200f8,0x00000762, + 0x0004003d,0x00000006,0x00000765,0x000000ac,0x0004003d,0x00000006,0x00000766,0x000000ab, + 0x00050082,0x00000006,0x00000767,0x00000765,0x00000766,0x0003003e,0x00000764,0x00000767, + 0x0004003d,0x00000006,0x00000768,0x00000764,0x000500ae,0x00000093,0x00000769,0x00000768, + 0x00000117,0x000300f7,0x0000076b,0x00000000,0x000400fa,0x00000769,0x0000076a,0x00000793, + 0x000200f8,0x0000076a,0x0004003d,0x00000006,0x0000076c,0x000000ab,0x00050051,0x00000006, + 0x0000076d,0x000000a8,0x00000001,0x00050084,0x00000006,0x0000076e,0x0000076d,0x000000f8, + 0x00050080,0x00000006,0x0000076f,0x0000076c,0x0000076e,0x00050080,0x00000006,0x00000770, + 0x0000076f,0x000000f9,0x0003003e,0x00000771,0x000000fb,0x0003003e,0x00000772,0x00000770, + 0x00070039,0x00000006,0x00000773,0x0000000d,0x000000aa,0x00000771,0x00000772,0x000500c4, + 0x00000006,0x00000774,0x00000773,0x0000013b,0x0004003d,0x00000006,0x00000775,0x000000ab, + 0x00050051,0x00000006,0x00000776,0x000000a8,0x00000001,0x00050084,0x00000006,0x00000777, + 0x00000776,0x000000fb,0x00050080,0x00000006,0x00000778,0x00000775,0x00000777,0x00050080, + 0x00000006,0x00000779,0x00000778,0x000000fb,0x0003003e,0x0000077a,0x000000fb,0x0003003e, + 0x0000077b,0x00000779,0x00070039,0x00000006,0x0000077c,0x0000000d,0x000000aa,0x0000077a, + 0x0000077b,0x000500c4,0x00000006,0x0000077d,0x0000077c,0x000001a6,0x000500c5,0x00000006, + 0x0000077e,0x00000774,0x0000077d,0x0004003d,0x00000006,0x0000077f,0x000000ab,0x00050051, + 0x00000006,0x00000780,0x000000a8,0x00000001,0x00050084,0x00000006,0x00000781,0x00000780, + 0x00000103,0x00050080,0x00000006,0x00000782,0x0000077f,0x00000781,0x00050080,0x00000006, + 0x00000783,0x00000782,0x0000010a,0x0003003e,0x00000784,0x000000f8,0x0003003e,0x00000785, + 0x00000783,0x00070039,0x00000006,0x00000786,0x0000000d,0x000000aa,0x00000784,0x00000785, + 0x000500c4,0x00000006,0x00000787,0x00000786,0x000004fd,0x000500c5,0x00000006,0x00000788, + 0x0000077e,0x00000787,0x0004003d,0x00000006,0x00000789,0x000000ab,0x00050051,0x00000006, + 0x0000078a,0x000000a8,0x00000001,0x00050084,0x00000006,0x0000078b,0x0000078a,0x0000010a, + 0x00050080,0x00000006,0x0000078c,0x00000789,0x0000078b,0x00050080,0x00000006,0x0000078d, + 0x0000078c,0x000000fd,0x0003003e,0x0000078e,0x000000fb,0x0003003e,0x0000078f,0x0000078d, + 0x00070039,0x00000006,0x00000790,0x0000000d,0x000000aa,0x0000078e,0x0000078f,0x000500c4, + 0x00000006,0x00000791,0x00000790,0x00000130,0x000500c5,0x00000006,0x00000792,0x00000788, + 0x00000791,0x0003003e,0x0000075d,0x00000792,0x000200f9,0x0000076b,0x000200f8,0x00000793, + 0x0004003d,0x00000006,0x00000794,0x00000764,0x000500ae,0x00000093,0x00000795,0x00000794, + 0x000000fd,0x000300f7,0x00000797,0x00000000,0x000400fa,0x00000795,0x00000796,0x000007b5, + 0x000200f8,0x00000796,0x0004003d,0x00000006,0x00000798,0x000000ab,0x00050051,0x00000006, + 0x00000799,0x000000a8,0x00000001,0x00050084,0x00000006,0x0000079a,0x00000799,0x000000f8, + 0x00050080,0x00000006,0x0000079b,0x00000798,0x0000079a,0x00050080,0x00000006,0x0000079c, + 0x0000079b,0x000000f9,0x0003003e,0x0000079d,0x000000fb,0x0003003e,0x0000079e,0x0000079c, + 0x00070039,0x00000006,0x0000079f,0x0000000d,0x000000aa,0x0000079d,0x0000079e,0x000500c4, + 0x00000006,0x000007a0,0x0000079f,0x0000013b,0x0004003d,0x00000006,0x000007a1,0x000000ab, + 0x00050051,0x00000006,0x000007a2,0x000000a8,0x00000001,0x00050084,0x00000006,0x000007a3, + 0x000007a2,0x000000fb,0x00050080,0x00000006,0x000007a4,0x000007a1,0x000007a3,0x00050080, + 0x00000006,0x000007a5,0x000007a4,0x000000fb,0x0003003e,0x000007a6,0x000000fb,0x0003003e, + 0x000007a7,0x000007a5,0x00070039,0x00000006,0x000007a8,0x0000000d,0x000000aa,0x000007a6, + 0x000007a7,0x000500c4,0x00000006,0x000007a9,0x000007a8,0x000001a6,0x000500c5,0x00000006, + 0x000007aa,0x000007a0,0x000007a9,0x0004003d,0x00000006,0x000007ab,0x000000ab,0x00050051, + 0x00000006,0x000007ac,0x000000a8,0x00000001,0x00050084,0x00000006,0x000007ad,0x000007ac, + 0x00000103,0x00050080,0x00000006,0x000007ae,0x000007ab,0x000007ad,0x00050080,0x00000006, + 0x000007af,0x000007ae,0x0000010a,0x0003003e,0x000007b0,0x000000f8,0x0003003e,0x000007b1, + 0x000007af,0x00070039,0x00000006,0x000007b2,0x0000000d,0x000000aa,0x000007b0,0x000007b1, + 0x000500c4,0x00000006,0x000007b3,0x000007b2,0x000004fd,0x000500c5,0x00000006,0x000007b4, + 0x000007aa,0x000007b3,0x0003003e,0x0000075d,0x000007b4,0x000200f9,0x00000797,0x000200f8, + 0x000007b5,0x0004003d,0x00000006,0x000007b6,0x00000764,0x000500ac,0x00000093,0x000007b7, + 0x000007b6,0x000000fb,0x000300f7,0x000007b9,0x00000000,0x000400fa,0x000007b7,0x000007b8, + 0x000007cd,0x000200f8,0x000007b8,0x0004003d,0x00000006,0x000007ba,0x000000ab,0x00050051, + 0x00000006,0x000007bb,0x000000a8,0x00000001,0x00050084,0x00000006,0x000007bc,0x000007bb, + 0x000000f8,0x00050080,0x00000006,0x000007bd,0x000007ba,0x000007bc,0x00050080,0x00000006, + 0x000007be,0x000007bd,0x000000f9,0x0003003e,0x000007bf,0x000000fb,0x0003003e,0x000007c0, + 0x000007be,0x00070039,0x00000006,0x000007c1,0x0000000d,0x000000aa,0x000007bf,0x000007c0, + 0x000500c4,0x00000006,0x000007c2,0x000007c1,0x0000013b,0x0004003d,0x00000006,0x000007c3, + 0x000000ab,0x00050051,0x00000006,0x000007c4,0x000000a8,0x00000001,0x00050084,0x00000006, + 0x000007c5,0x000007c4,0x000000fb,0x00050080,0x00000006,0x000007c6,0x000007c3,0x000007c5, + 0x00050080,0x00000006,0x000007c7,0x000007c6,0x000000fb,0x0003003e,0x000007c8,0x000000fb, + 0x0003003e,0x000007c9,0x000007c7,0x00070039,0x00000006,0x000007ca,0x0000000d,0x000000aa, + 0x000007c8,0x000007c9,0x000500c4,0x00000006,0x000007cb,0x000007ca,0x000001a6,0x000500c5, + 0x00000006,0x000007cc,0x000007c2,0x000007cb,0x0003003e,0x0000075d,0x000007cc,0x000200f9, + 0x000007b9,0x000200f8,0x000007cd,0x0004003d,0x00000006,0x000007ce,0x000000ab,0x00050051, + 0x00000006,0x000007cf,0x000000a8,0x00000001,0x00050084,0x00000006,0x000007d0,0x000007cf, + 0x000000f8,0x00050080,0x00000006,0x000007d1,0x000007ce,0x000007d0,0x00050080,0x00000006, + 0x000007d2,0x000007d1,0x000000f9,0x0003003e,0x000007d3,0x000000fb,0x0003003e,0x000007d4, + 0x000007d2,0x00070039,0x00000006,0x000007d5,0x0000000d,0x000000aa,0x000007d3,0x000007d4, + 0x000500c4,0x00000006,0x000007d6,0x000007d5,0x0000013b,0x0003003e,0x0000075d,0x000007d6, + 0x000200f9,0x000007b9,0x000200f8,0x000007b9,0x000200f9,0x00000797,0x000200f8,0x00000797, + 0x000200f9,0x0000076b,0x000200f8,0x0000076b,0x000200f9,0x00000763,0x000200f8,0x000007d7, + 0x0004003d,0x00000006,0x000007d8,0x000000ab,0x00050051,0x00000006,0x000007d9,0x000000a8, + 0x00000001,0x00050084,0x00000006,0x000007da,0x000007d9,0x000000f8,0x00050080,0x00000006, + 0x000007db,0x000007d8,0x000007da,0x00050080,0x00000006,0x000007dc,0x000007db,0x000000f9, + 0x0003003e,0x000007dd,0x000000fb,0x0003003e,0x000007de,0x000007dc,0x00070039,0x00000006, + 0x000007df,0x0000000d,0x000000aa,0x000007dd,0x000007de,0x000500c4,0x00000006,0x000007e0, + 0x000007df,0x0000013b,0x0004003d,0x00000006,0x000007e1,0x000000ab,0x00050051,0x00000006, + 0x000007e2,0x000000a8,0x00000001,0x00050084,0x00000006,0x000007e3,0x000007e2,0x000000fb, + 0x00050080,0x00000006,0x000007e4,0x000007e1,0x000007e3,0x00050080,0x00000006,0x000007e5, + 0x000007e4,0x000000fb,0x0003003e,0x000007e6,0x000000fb,0x0003003e,0x000007e7,0x000007e5, + 0x00070039,0x00000006,0x000007e8,0x0000000d,0x000000aa,0x000007e6,0x000007e7,0x000500c4, + 0x00000006,0x000007e9,0x000007e8,0x000001a6,0x000500c5,0x00000006,0x000007ea,0x000007e0, + 0x000007e9,0x0004003d,0x00000006,0x000007eb,0x000000ab,0x00050051,0x00000006,0x000007ec, + 0x000000a8,0x00000001,0x00050084,0x00000006,0x000007ed,0x000007ec,0x00000103,0x00050080, + 0x00000006,0x000007ee,0x000007eb,0x000007ed,0x00050080,0x00000006,0x000007ef,0x000007ee, + 0x0000010a,0x0003003e,0x000007f0,0x000000f8,0x0003003e,0x000007f1,0x000007ef,0x00070039, + 0x00000006,0x000007f2,0x0000000d,0x000000aa,0x000007f0,0x000007f1,0x000500c4,0x00000006, + 0x000007f3,0x000007f2,0x000004fd,0x000500c5,0x00000006,0x000007f4,0x000007ea,0x000007f3, + 0x0004003d,0x00000006,0x000007f5,0x000000ab,0x00050051,0x00000006,0x000007f6,0x000000a8, + 0x00000001,0x00050084,0x00000006,0x000007f7,0x000007f6,0x0000010a,0x00050080,0x00000006, + 0x000007f8,0x000007f5,0x000007f7,0x00050080,0x00000006,0x000007f9,0x000007f8,0x000000fd, + 0x0003003e,0x000007fa,0x000000fb,0x0003003e,0x000007fb,0x000007f9,0x00070039,0x00000006, + 0x000007fc,0x0000000d,0x000000aa,0x000007fa,0x000007fb,0x000500c4,0x00000006,0x000007fd, + 0x000007fc,0x00000130,0x000500c5,0x00000006,0x000007fe,0x000007f4,0x000007fd,0x0004003d, + 0x00000006,0x000007ff,0x000000ab,0x00050051,0x00000006,0x00000800,0x000000a8,0x00000001, + 0x00050084,0x00000006,0x00000801,0x00000800,0x000000fd,0x00050080,0x00000006,0x00000802, + 0x000007ff,0x00000801,0x00050080,0x00000006,0x00000803,0x00000802,0x0000011e,0x0003003e, + 0x00000804,0x000000f8,0x0003003e,0x00000805,0x00000803,0x00070039,0x00000006,0x00000806, + 0x0000000d,0x000000aa,0x00000804,0x00000805,0x000500c4,0x00000006,0x00000807,0x00000806, + 0x000004d7,0x000500c5,0x00000006,0x00000808,0x000007fe,0x00000807,0x0003003e,0x0000075d, + 0x00000808,0x000200f9,0x00000763,0x000200f8,0x00000763,0x0004003d,0x00000006,0x00000812, + 0x0000075d,0x0004003d,0x00000006,0x00000813,0x0000074c,0x00070041,0x00000814,0x00000815, + 0x00000811,0x0000013b,0x00000812,0x00000813,0x0004003d,0x00000006,0x00000816,0x00000815, + 0x0003003e,0x00000809,0x00000816,0x00050051,0x00000006,0x00000817,0x000000a8,0x00000001, + 0x000500ac,0x00000093,0x00000818,0x00000817,0x000000f9,0x000300f7,0x0000081a,0x00000000, + 0x000400fa,0x00000818,0x00000819,0x00000832,0x000200f8,0x00000819,0x0004003d,0x00000006, + 0x0000081c,0x0000074c,0x00050051,0x00000006,0x0000081d,0x000000a8,0x00000001,0x00050084, + 0x00000006,0x0000081e,0x0000081c,0x0000081d,0x0004003d,0x00000006,0x0000081f,0x0000074c, + 0x00050084,0x00000006,0x00000820,0x0000081f,0x00000125,0x00050080,0x00000006,0x00000821, + 0x00000820,0x0000010a,0x00050086,0x00000006,0x00000822,0x00000821,0x000000fd,0x00050080, + 0x00000006,0x00000823,0x0000081e,0x00000822,0x0003003e,0x0000081b,0x00000823,0x0004003d, + 0x00000006,0x00000825,0x0000081b,0x0004003d,0x00000006,0x00000826,0x000000ab,0x00050080, + 0x00000006,0x00000827,0x00000825,0x00000826,0x00050051,0x00000006,0x00000829,0x000000a8, + 0x00000001,0x0003003e,0x00000828,0x00000829,0x0003003e,0x0000082a,0x00000827,0x00070039, + 0x00000006,0x0000082b,0x0000000d,0x000000aa,0x00000828,0x0000082a,0x0003003e,0x00000824, + 0x0000082b,0x0004003d,0x00000006,0x0000082d,0x00000809,0x00050051,0x00000006,0x0000082e, + 0x000000a8,0x00000001,0x000500c4,0x00000006,0x0000082f,0x0000082d,0x0000082e,0x0004003d, + 0x00000006,0x00000830,0x00000824,0x000500c5,0x00000006,0x00000831,0x0000082f,0x00000830, + 0x0003003e,0x0000082c,0x00000831,0x000200f9,0x0000081a,0x000200f8,0x00000832,0x0004003d, + 0x00000006,0x00000833,0x00000809,0x0003003e,0x0000082c,0x00000833,0x000200f9,0x0000081a, + 0x000200f8,0x0000081a,0x000200f9,0x00000748,0x000200f8,0x00000834,0x00050051,0x00000006, + 0x00000835,0x000000a8,0x00000002,0x000500ac,0x00000093,0x00000836,0x00000835,0x000000f9, + 0x000300f7,0x00000838,0x00000000,0x000400fa,0x00000836,0x00000837,0x000008b4,0x000200f8, + 0x00000837,0x0004003d,0x00000006,0x0000083a,0x000000a9,0x00050086,0x00000006,0x0000083b, + 0x0000083a,0x00000103,0x0003003e,0x00000839,0x0000083b,0x0004003d,0x00000006,0x0000083d, + 0x000000a9,0x0004003d,0x00000006,0x0000083e,0x00000839,0x00050084,0x00000006,0x0000083f, + 0x00000103,0x0000083e,0x00050082,0x00000006,0x00000840,0x0000083d,0x0000083f,0x0003003e, + 0x0000083c,0x00000840,0x0003003e,0x00000841,0x000000f9,0x0004003d,0x00000006,0x00000842, + 0x00000839,0x00050084,0x00000006,0x00000843,0x00000842,0x0000011e,0x0004003d,0x00000006, + 0x00000844,0x00000839,0x00050084,0x00000006,0x00000845,0x00000844,0x00000103,0x00050051, + 0x00000006,0x00000846,0x000000a8,0x00000001,0x00050084,0x00000006,0x00000847,0x00000845, + 0x00000846,0x00050080,0x00000006,0x00000848,0x00000843,0x00000847,0x0004003d,0x00000006, + 0x00000849,0x000000ab,0x00050080,0x00000006,0x0000084a,0x00000849,0x00000848,0x0003003e, + 0x000000ab,0x0000084a,0x0004003d,0x00000006,0x0000084b,0x000000ab,0x00050080,0x00000006, + 0x0000084c,0x0000084b,0x00000117,0x0004003d,0x00000006,0x0000084d,0x000000ac,0x000500ac, + 0x00000093,0x0000084e,0x0000084c,0x0000084d,0x000300f7,0x00000850,0x00000000,0x000400fa, + 0x0000084e,0x0000084f,0x00000875,0x000200f8,0x0000084f,0x0004003d,0x00000006,0x00000852, + 0x000000ac,0x0004003d,0x00000006,0x00000853,0x000000ab,0x00050082,0x00000006,0x00000854, + 0x00000852,0x00000853,0x0003003e,0x00000851,0x00000854,0x0004003d,0x00000006,0x00000855, + 0x00000851,0x000500b0,0x00000093,0x00000856,0x00000855,0x000000fd,0x000300f7,0x00000858, + 0x00000000,0x000400fa,0x00000856,0x00000857,0x00000861,0x000200f8,0x00000857,0x0004003d, + 0x00000006,0x00000859,0x000000ab,0x00050051,0x00000006,0x0000085a,0x000000a8,0x00000001, + 0x00050084,0x00000006,0x0000085b,0x0000085a,0x000000f8,0x00050080,0x00000006,0x0000085c, + 0x00000859,0x0000085b,0x00050080,0x00000006,0x0000085d,0x0000085c,0x000000f9,0x0003003e, + 0x0000085e,0x00000103,0x0003003e,0x0000085f,0x0000085d,0x00070039,0x00000006,0x00000860, + 0x0000000d,0x000000aa,0x0000085e,0x0000085f,0x0003003e,0x00000841,0x00000860,0x000200f9, + 0x00000858,0x000200f8,0x00000861,0x0004003d,0x00000006,0x00000862,0x000000ab,0x00050051, + 0x00000006,0x00000863,0x000000a8,0x00000001,0x00050084,0x00000006,0x00000864,0x00000863, + 0x000000f8,0x00050080,0x00000006,0x00000865,0x00000862,0x00000864,0x00050080,0x00000006, + 0x00000866,0x00000865,0x000000f9,0x0003003e,0x00000867,0x00000103,0x0003003e,0x00000868, + 0x00000866,0x00070039,0x00000006,0x00000869,0x0000000d,0x000000aa,0x00000867,0x00000868, + 0x000500c4,0x00000006,0x0000086a,0x00000869,0x0000013b,0x0004003d,0x00000006,0x0000086b, + 0x000000ab,0x00050051,0x00000006,0x0000086c,0x000000a8,0x00000001,0x00050084,0x00000006, + 0x0000086d,0x0000086c,0x000000fb,0x00050080,0x00000006,0x0000086e,0x0000086b,0x0000086d, + 0x00050080,0x00000006,0x0000086f,0x0000086e,0x00000103,0x0003003e,0x00000870,0x000000fb, + 0x0003003e,0x00000871,0x0000086f,0x00070039,0x00000006,0x00000872,0x0000000d,0x000000aa, + 0x00000870,0x00000871,0x000500c4,0x00000006,0x00000873,0x00000872,0x000004dc,0x000500c5, + 0x00000006,0x00000874,0x0000086a,0x00000873,0x0003003e,0x00000841,0x00000874,0x000200f9, + 0x00000858,0x000200f8,0x00000858,0x000200f9,0x00000850,0x000200f8,0x00000875,0x0004003d, + 0x00000006,0x00000876,0x000000ab,0x00050051,0x00000006,0x00000877,0x000000a8,0x00000001, + 0x00050084,0x00000006,0x00000878,0x00000877,0x000000f8,0x00050080,0x00000006,0x00000879, + 0x00000876,0x00000878,0x00050080,0x00000006,0x0000087a,0x00000879,0x000000f9,0x0003003e, + 0x0000087b,0x00000103,0x0003003e,0x0000087c,0x0000087a,0x00070039,0x00000006,0x0000087d, + 0x0000000d,0x000000aa,0x0000087b,0x0000087c,0x000500c4,0x00000006,0x0000087e,0x0000087d, + 0x0000013b,0x0004003d,0x00000006,0x0000087f,0x000000ab,0x00050051,0x00000006,0x00000880, + 0x000000a8,0x00000001,0x00050084,0x00000006,0x00000881,0x00000880,0x000000fb,0x00050080, + 0x00000006,0x00000882,0x0000087f,0x00000881,0x00050080,0x00000006,0x00000883,0x00000882, + 0x00000103,0x0003003e,0x00000884,0x000000fb,0x0003003e,0x00000885,0x00000883,0x00070039, + 0x00000006,0x00000886,0x0000000d,0x000000aa,0x00000884,0x00000885,0x000500c4,0x00000006, + 0x00000887,0x00000886,0x000004dc,0x000500c5,0x00000006,0x00000888,0x0000087e,0x00000887, + 0x0004003d,0x00000006,0x00000889,0x000000ab,0x00050051,0x00000006,0x0000088a,0x000000a8, + 0x00000001,0x00050084,0x00000006,0x0000088b,0x0000088a,0x00000103,0x00050080,0x00000006, + 0x0000088c,0x00000889,0x0000088b,0x00050080,0x00000006,0x0000088d,0x0000088c,0x000000fd, + 0x0003003e,0x0000088e,0x000000fb,0x0003003e,0x0000088f,0x0000088d,0x00070039,0x00000006, + 0x00000890,0x0000000d,0x000000aa,0x0000088e,0x0000088f,0x000500c4,0x00000006,0x00000891, + 0x00000890,0x00000130,0x000500c5,0x00000006,0x00000892,0x00000888,0x00000891,0x0003003e, + 0x00000841,0x00000892,0x000200f9,0x00000850,0x000200f8,0x00000850,0x0004003d,0x00000006, + 0x00000894,0x00000841,0x0004003d,0x00000006,0x00000895,0x0000083c,0x00070041,0x00000814, + 0x00000896,0x00000811,0x00000149,0x00000894,0x00000895,0x0004003d,0x00000006,0x00000897, + 0x00000896,0x0003003e,0x00000893,0x00000897,0x00050051,0x00000006,0x00000898,0x000000a8, + 0x00000001,0x000500ac,0x00000093,0x00000899,0x00000898,0x000000f9,0x000300f7,0x0000089b, + 0x00000000,0x000400fa,0x00000899,0x0000089a,0x000008b2,0x000200f8,0x0000089a,0x0004003d, + 0x00000006,0x0000089d,0x0000083c,0x00050051,0x00000006,0x0000089e,0x000000a8,0x00000001, + 0x00050084,0x00000006,0x0000089f,0x0000089d,0x0000089e,0x0004003d,0x00000006,0x000008a0, + 0x0000083c,0x00050084,0x00000006,0x000008a1,0x000008a0,0x0000011e,0x00050080,0x00000006, + 0x000008a2,0x000008a1,0x000000fb,0x00050086,0x00000006,0x000008a3,0x000008a2,0x00000103, + 0x00050080,0x00000006,0x000008a4,0x0000089f,0x000008a3,0x0003003e,0x0000089c,0x000008a4, + 0x0004003d,0x00000006,0x000008a6,0x0000089c,0x0004003d,0x00000006,0x000008a7,0x000000ab, + 0x00050080,0x00000006,0x000008a8,0x000008a6,0x000008a7,0x00050051,0x00000006,0x000008aa, + 0x000000a8,0x00000001,0x0003003e,0x000008a9,0x000008aa,0x0003003e,0x000008ab,0x000008a8, + 0x00070039,0x00000006,0x000008ac,0x0000000d,0x000000aa,0x000008a9,0x000008ab,0x0003003e, + 0x000008a5,0x000008ac,0x0004003d,0x00000006,0x000008ad,0x00000893,0x00050051,0x00000006, + 0x000008ae,0x000000a8,0x00000001,0x000500c4,0x00000006,0x000008af,0x000008ad,0x000008ae, + 0x0004003d,0x00000006,0x000008b0,0x000008a5,0x000500c5,0x00000006,0x000008b1,0x000008af, + 0x000008b0,0x0003003e,0x0000082c,0x000008b1,0x000200f9,0x0000089b,0x000200f8,0x000008b2, + 0x0004003d,0x00000006,0x000008b3,0x00000893,0x0003003e,0x0000082c,0x000008b3,0x000200f9, + 0x0000089b,0x000200f8,0x0000089b,0x000200f9,0x00000838,0x000200f8,0x000008b4,0x0004003d, + 0x00000006,0x000008b5,0x000000a9,0x00050051,0x00000006,0x000008b6,0x000000a8,0x00000001, + 0x00050084,0x00000006,0x000008b7,0x000008b5,0x000008b6,0x0004003d,0x00000006,0x000008b8, + 0x000000ab,0x00050080,0x00000006,0x000008b9,0x000008b8,0x000008b7,0x0003003e,0x000000ab, + 0x000008b9,0x00050051,0x00000006,0x000008bb,0x000000a8,0x00000001,0x0003003e,0x000008ba, + 0x000008bb,0x0004003d,0x00000006,0x000008bd,0x000000ab,0x0003003e,0x000008bc,0x000008bd, + 0x00070039,0x00000006,0x000008be,0x0000000d,0x000000aa,0x000008ba,0x000008bc,0x0003003e, + 0x0000082c,0x000008be,0x000200f9,0x00000838,0x000200f8,0x00000838,0x000200f9,0x00000748, + 0x000200f8,0x00000748,0x0004003d,0x00000006,0x000008bf,0x0000082c,0x000200fe,0x000008bf, + 0x00010038,0x00050036,0x00000006,0x000000b4,0x00000000,0x000000af,0x00030037,0x00000007, + 0x000000b0,0x00030037,0x00000008,0x000000b1,0x00030037,0x0000009b,0x000000b2,0x00030037, + 0x00000008,0x000000b3,0x000200f8,0x000000b5,0x0004003b,0x00000008,0x000008c2,0x00000007, + 0x0004003b,0x00000008,0x000008c3,0x00000007,0x0004003b,0x00000008,0x000008c5,0x00000007, + 0x0004003b,0x00000008,0x000008c6,0x00000007,0x0004003d,0x00000006,0x000008c4,0x000000b1, + 0x0003003e,0x000008c3,0x000008c4,0x0003003e,0x000008c5,0x000000f9,0x0004003d,0x00000006, + 0x000008c7,0x000000b3,0x0003003e,0x000008c6,0x000008c7,0x00090039,0x00000006,0x000008c8, + 0x000000ad,0x000000b2,0x000008c3,0x000000b0,0x000008c5,0x000008c6,0x0003003e,0x000008c2, + 0x000008c8,0x0004003d,0x00000006,0x000008cd,0x000008c2,0x00050051,0x00000006,0x000008ce, + 0x000000b2,0x00000003,0x00050080,0x00000006,0x000008cf,0x000008cd,0x000008ce,0x00060041, + 0x00000814,0x000008d0,0x000008cc,0x0000013b,0x000008cf,0x0004003d,0x00000006,0x000008d1, + 0x000008d0,0x000200fe,0x000008d1,0x00010038,0x00050036,0x00000006,0x000000bf,0x00000000, + 0x000000b8,0x00030037,0x00000007,0x000000b9,0x00030037,0x00000094,0x000000ba,0x00030037, + 0x0000009c,0x000000bb,0x00030037,0x00000008,0x000000bc,0x00030037,0x000000b7,0x000000bd, + 0x00030037,0x00000008,0x000000be,0x000200f8,0x000000c0,0x0004003b,0x000000b7,0x000008d4, + 0x00000007,0x0004003b,0x000000b7,0x000008ea,0x00000007,0x0004003b,0x000000b7,0x000008ee, + 0x00000007,0x0004003b,0x000000b7,0x000008fb,0x00000007,0x0004003b,0x000000b7,0x00000902, + 0x00000007,0x0004003b,0x00000008,0x00000909,0x00000007,0x0004003b,0x00000008,0x00000912, + 0x00000007,0x0004003b,0x00000008,0x00000916,0x00000007,0x0004003b,0x00000008,0x0000091d, + 0x00000007,0x0004003b,0x00000008,0x0000091e,0x00000007,0x0004003b,0x00000008,0x00000921, + 0x00000007,0x0004003b,0x00000008,0x00000929,0x00000007,0x0004003b,0x00000008,0x0000092a, + 0x00000007,0x0004003b,0x00000008,0x0000092d,0x00000007,0x0004003b,0x00000008,0x00000937, + 0x00000007,0x0004003b,0x00000008,0x00000938,0x00000007,0x0004003b,0x00000008,0x0000093b, + 0x00000007,0x0004003b,0x00000008,0x00000946,0x00000007,0x0004003b,0x00000008,0x00000947, + 0x00000007,0x0004003b,0x00000008,0x0000094a,0x00000007,0x0004003b,0x00000008,0x00000952, + 0x00000007,0x0004003b,0x00000008,0x00000957,0x00000007,0x0004003b,0x00000008,0x0000095c, + 0x00000007,0x0004003b,0x00000008,0x00000965,0x00000007,0x0004003d,0x000000b6,0x000008e8, + 0x000000bd,0x00050084,0x000000b6,0x000008e9,0x000008e7,0x000008e8,0x0003003e,0x000008d4, + 0x000008e9,0x00050051,0x00000006,0x000008eb,0x000000ba,0x00000000,0x00050051,0x00000006, + 0x000008ec,0x000000ba,0x00000001,0x00050050,0x000000b6,0x000008ed,0x000008eb,0x000008ec, + 0x0003003e,0x000008ea,0x000008ed,0x0004003d,0x000000b6,0x000008ef,0x000008d4,0x0004003d, + 0x000000b6,0x000008f0,0x000008ea,0x00050050,0x000000b6,0x000008f1,0x000000f8,0x000000f8, + 0x00050082,0x000000b6,0x000008f2,0x000008f0,0x000008f1,0x00050084,0x000000b6,0x000008f3, + 0x000008ef,0x000008f2,0x00050050,0x000000b6,0x000008f4,0x0000012b,0x0000012b,0x00050080, + 0x000000b6,0x000008f5,0x000008f3,0x000008f4,0x00050050,0x000008d9,0x000008f6,0x000004e1, + 0x000004e1,0x000500c2,0x000000b6,0x000008f7,0x000008f5,0x000008f6,0x00050051,0x00000006, + 0x000008f8,0x000008f7,0x00000000,0x00050051,0x00000006,0x000008f9,0x000008f7,0x00000001, + 0x00050050,0x000000b6,0x000008fa,0x000008f8,0x000008f9,0x0003003e,0x000008ee,0x000008fa, + 0x0004003d,0x000000b6,0x000008fc,0x000008ee,0x00050050,0x000008d9,0x000008fd,0x000004fd, + 0x000004fd,0x000500c2,0x000000b6,0x000008fe,0x000008fc,0x000008fd,0x00050051,0x00000006, + 0x000008ff,0x000008fe,0x00000000,0x00050051,0x00000006,0x00000900,0x000008fe,0x00000001, + 0x00050050,0x000000b6,0x00000901,0x000008ff,0x00000900,0x0003003e,0x000008fb,0x00000901, + 0x0004003d,0x000000b6,0x00000903,0x000008ee,0x00050050,0x000000b6,0x00000904,0x000004f9, + 0x000004f9,0x000500c7,0x000000b6,0x00000905,0x00000903,0x00000904,0x00050051,0x00000006, + 0x00000906,0x00000905,0x00000000,0x00050051,0x00000006,0x00000907,0x00000905,0x00000001, + 0x00050050,0x000000b6,0x00000908,0x00000906,0x00000907,0x0003003e,0x00000902,0x00000908, + 0x00050041,0x00000008,0x0000090a,0x000008fb,0x000000f9,0x0004003d,0x00000006,0x0000090b, + 0x0000090a,0x00050041,0x00000008,0x0000090c,0x000008fb,0x000000f8,0x0004003d,0x00000006, + 0x0000090d,0x0000090c,0x00050041,0x00000008,0x0000090e,0x000008ea,0x000000f9,0x0004003d, + 0x00000006,0x0000090f,0x0000090e,0x00050084,0x00000006,0x00000910,0x0000090d,0x0000090f, + 0x00050080,0x00000006,0x00000911,0x0000090b,0x00000910,0x0003003e,0x00000909,0x00000911, + 0x00050051,0x00000006,0x00000913,0x000000ba,0x00000005,0x000500c4,0x0000012f,0x00000914, + 0x00000149,0x00000913,0x0004007c,0x00000006,0x00000915,0x00000914,0x0003003e,0x00000912, + 0x00000915,0x0004003d,0x00000006,0x00000917,0x00000912,0x0004003d,0x00000006,0x00000918, + 0x00000909,0x00050084,0x00000006,0x00000919,0x00000917,0x00000918,0x0004003d,0x00000006, + 0x0000091a,0x000000bc,0x00050080,0x00000006,0x0000091b,0x00000919,0x0000091a,0x0004003d, + 0x0000009b,0x0000091c,0x000000bb,0x0003003e,0x0000091d,0x0000091b,0x0004003d,0x00000006, + 0x0000091f,0x000000be,0x0003003e,0x0000091e,0x0000091f,0x00080039,0x00000006,0x00000920, + 0x000000b4,0x000000b9,0x0000091d,0x0000091c,0x0000091e,0x0003003e,0x00000916,0x00000920, + 0x0004003d,0x00000006,0x00000922,0x00000912,0x0004003d,0x00000006,0x00000923,0x00000909, + 0x00050080,0x00000006,0x00000924,0x00000923,0x000000f8,0x00050084,0x00000006,0x00000925, + 0x00000922,0x00000924,0x0004003d,0x00000006,0x00000926,0x000000bc,0x00050080,0x00000006, + 0x00000927,0x00000925,0x00000926,0x0004003d,0x0000009b,0x00000928,0x000000bb,0x0003003e, + 0x00000929,0x00000927,0x0004003d,0x00000006,0x0000092b,0x000000be,0x0003003e,0x0000092a, + 0x0000092b,0x00080039,0x00000006,0x0000092c,0x000000b4,0x000000b9,0x00000929,0x00000928, + 0x0000092a,0x0003003e,0x00000921,0x0000092c,0x0004003d,0x00000006,0x0000092e,0x00000912, + 0x0004003d,0x00000006,0x0000092f,0x00000909,0x00050041,0x00000008,0x00000930,0x000008ea, + 0x000000f9,0x0004003d,0x00000006,0x00000931,0x00000930,0x00050080,0x00000006,0x00000932, + 0x0000092f,0x00000931,0x00050084,0x00000006,0x00000933,0x0000092e,0x00000932,0x0004003d, + 0x00000006,0x00000934,0x000000bc,0x00050080,0x00000006,0x00000935,0x00000933,0x00000934, + 0x0004003d,0x0000009b,0x00000936,0x000000bb,0x0003003e,0x00000937,0x00000935,0x0004003d, + 0x00000006,0x00000939,0x000000be,0x0003003e,0x00000938,0x00000939,0x00080039,0x00000006, + 0x0000093a,0x000000b4,0x000000b9,0x00000937,0x00000936,0x00000938,0x0003003e,0x0000092d, + 0x0000093a,0x0004003d,0x00000006,0x0000093c,0x00000912,0x0004003d,0x00000006,0x0000093d, + 0x00000909,0x00050041,0x00000008,0x0000093e,0x000008ea,0x000000f9,0x0004003d,0x00000006, + 0x0000093f,0x0000093e,0x00050080,0x00000006,0x00000940,0x0000093d,0x0000093f,0x00050080, + 0x00000006,0x00000941,0x00000940,0x000000f8,0x00050084,0x00000006,0x00000942,0x0000093c, + 0x00000941,0x0004003d,0x00000006,0x00000943,0x000000bc,0x00050080,0x00000006,0x00000944, + 0x00000942,0x00000943,0x0004003d,0x0000009b,0x00000945,0x000000bb,0x0003003e,0x00000946, + 0x00000944,0x0004003d,0x00000006,0x00000948,0x000000be,0x0003003e,0x00000947,0x00000948, + 0x00080039,0x00000006,0x00000949,0x000000b4,0x000000b9,0x00000946,0x00000945,0x00000947, + 0x0003003e,0x0000093b,0x00000949,0x00050041,0x00000008,0x0000094b,0x00000902,0x000000f9, + 0x0004003d,0x00000006,0x0000094c,0x0000094b,0x00050041,0x00000008,0x0000094d,0x00000902, + 0x000000f8,0x0004003d,0x00000006,0x0000094e,0x0000094d,0x00050084,0x00000006,0x0000094f, + 0x0000094c,0x0000094e,0x00050080,0x00000006,0x00000950,0x0000094f,0x00000125,0x000500c2, + 0x00000006,0x00000951,0x00000950,0x000004fd,0x0003003e,0x0000094a,0x00000951,0x00050041, + 0x00000008,0x00000953,0x00000902,0x000000f8,0x0004003d,0x00000006,0x00000954,0x00000953, + 0x0004003d,0x00000006,0x00000955,0x0000094a,0x00050082,0x00000006,0x00000956,0x00000954, + 0x00000955,0x0003003e,0x00000952,0x00000956,0x00050041,0x00000008,0x00000958,0x00000902, + 0x000000f9,0x0004003d,0x00000006,0x00000959,0x00000958,0x0004003d,0x00000006,0x0000095a, + 0x0000094a,0x00050082,0x00000006,0x0000095b,0x00000959,0x0000095a,0x0003003e,0x00000957, + 0x0000095b,0x00050041,0x00000008,0x0000095d,0x00000902,0x000000f9,0x0004003d,0x00000006, + 0x0000095e,0x0000095d,0x00050082,0x00000006,0x0000095f,0x00000573,0x0000095e,0x00050041, + 0x00000008,0x00000960,0x00000902,0x000000f8,0x0004003d,0x00000006,0x00000961,0x00000960, + 0x00050082,0x00000006,0x00000962,0x0000095f,0x00000961,0x0004003d,0x00000006,0x00000963, + 0x0000094a,0x00050080,0x00000006,0x00000964,0x00000962,0x00000963,0x0003003e,0x0000095c, + 0x00000964,0x0004003d,0x00000006,0x00000966,0x00000916,0x0004003d,0x00000006,0x00000967, + 0x0000095c,0x00050084,0x00000006,0x00000968,0x00000966,0x00000967,0x0004003d,0x00000006, + 0x00000969,0x00000921,0x0004003d,0x00000006,0x0000096a,0x00000957,0x00050084,0x00000006, + 0x0000096b,0x00000969,0x0000096a,0x00050080,0x00000006,0x0000096c,0x00000968,0x0000096b, + 0x0004003d,0x00000006,0x0000096d,0x0000092d,0x0004003d,0x00000006,0x0000096e,0x00000952, + 0x00050084,0x00000006,0x0000096f,0x0000096d,0x0000096e,0x00050080,0x00000006,0x00000970, + 0x0000096c,0x0000096f,0x0004003d,0x00000006,0x00000971,0x0000093b,0x0004003d,0x00000006, + 0x00000972,0x0000094a,0x00050084,0x00000006,0x00000973,0x00000971,0x00000972,0x00050080, + 0x00000006,0x00000974,0x00000970,0x00000973,0x00050080,0x00000006,0x00000975,0x00000974, + 0x00000125,0x000500c2,0x00000006,0x00000976,0x00000975,0x000004fd,0x0003003e,0x00000965, + 0x00000976,0x0004003d,0x00000006,0x00000977,0x00000965,0x000200fe,0x00000977,0x00010038, + 0x00050036,0x00000007,0x000000ca,0x00000000,0x000000c1,0x00030037,0x00000007,0x000000c2, + 0x00030037,0x00000007,0x000000c3,0x00030037,0x00000094,0x000000c4,0x00030037,0x0000009c, + 0x000000c5,0x00030037,0x00000008,0x000000c6,0x00030037,0x000000b7,0x000000c7,0x00030037, + 0x00000008,0x000000c8,0x00030037,0x00000008,0x000000c9,0x000200f8,0x000000cb,0x0004003b, + 0x00000008,0x0000097a,0x00000007,0x0004003b,0x00000008,0x0000097f,0x00000007,0x0004003b, + 0x00000008,0x00000990,0x00000007,0x0004003b,0x00000008,0x00000991,0x00000007,0x0004003b, + 0x00000008,0x00000993,0x00000007,0x0004003b,0x0000009c,0x00000994,0x00000007,0x0004003b, + 0x00000008,0x00000996,0x00000007,0x0004003b,0x000000b7,0x00000997,0x00000007,0x0004003b, + 0x00000008,0x00000999,0x00000007,0x0004003b,0x00000008,0x000009a0,0x00000007,0x0004003b, + 0x0000009c,0x000009a1,0x00000007,0x0004003b,0x00000008,0x000009a3,0x00000007,0x0004003b, + 0x000000b7,0x000009a4,0x00000007,0x0004003b,0x00000008,0x000009a6,0x00000007,0x0004003b, + 0x0000001c,0x000009a9,0x00000007,0x0003003e,0x0000097a,0x000000f9,0x00050051,0x00000006, + 0x0000097b,0x000000c4,0x00000005,0x000500aa,0x00000093,0x0000097c,0x0000097b,0x000000f8, + 0x000300f7,0x0000097e,0x00000000,0x000400fa,0x0000097c,0x0000097d,0x0000097e,0x000200f8, + 0x0000097d,0x0003003e,0x0000097f,0x000000f9,0x0004003d,0x00000006,0x00000980,0x000000c8, + 0x000500c7,0x00000006,0x00000981,0x00000980,0x00000103,0x000500ab,0x00000093,0x00000982, + 0x00000981,0x000000f9,0x000300f7,0x00000984,0x00000000,0x000400fa,0x00000982,0x00000983, + 0x00000984,0x000200f8,0x00000983,0x00050051,0x00000006,0x00000985,0x000000c4,0x00000004, + 0x00050084,0x00000006,0x00000986,0x00000103,0x00000985,0x00050082,0x00000006,0x00000987, + 0x00000986,0x0000010a,0x0004007c,0x0000012f,0x00000988,0x00000987,0x0007000c,0x0000012f, + 0x00000989,0x00000001,0x0000002a,0x0000013b,0x00000988,0x0004007c,0x00000006,0x0000098a, + 0x00000989,0x0003003e,0x0000097f,0x0000098a,0x000200f9,0x00000984,0x000200f8,0x00000984, + 0x0004003d,0x00000006,0x0000098b,0x000000c6,0x00050082,0x00000006,0x0000098c,0x0000080d, + 0x0000098b,0x0004003d,0x00000006,0x0000098d,0x0000097f,0x00050082,0x00000006,0x0000098e, + 0x0000098c,0x0000098d,0x00050082,0x00000006,0x0000098f,0x0000098e,0x000000fb,0x0003003e, + 0x00000990,0x000000fb,0x0003003e,0x00000991,0x0000098f,0x00070039,0x00000006,0x00000992, + 0x0000000d,0x000000c2,0x00000990,0x00000991,0x0003003e,0x0000097a,0x00000992,0x000200f9, + 0x0000097e,0x000200f8,0x0000097e,0x0004003d,0x0000009b,0x00000995,0x000000c5,0x0003003e, + 0x00000994,0x00000995,0x0003003e,0x00000996,0x000000f9,0x0004003d,0x000000b6,0x00000998, + 0x000000c7,0x0003003e,0x00000997,0x00000998,0x0004003d,0x00000006,0x0000099a,0x000000c9, + 0x0003003e,0x00000999,0x0000099a,0x000a0039,0x00000006,0x0000099b,0x000000bf,0x000000c3, + 0x000000c4,0x00000994,0x00000996,0x00000997,0x00000999,0x0003003e,0x00000993,0x0000099b, + 0x00050051,0x00000006,0x0000099c,0x000000c4,0x00000005,0x000500aa,0x00000093,0x0000099d, + 0x0000099c,0x000000f8,0x000300f7,0x0000099f,0x00000000,0x000400fa,0x0000099d,0x0000099e, + 0x000009b4,0x000200f8,0x0000099e,0x0004003d,0x0000009b,0x000009a2,0x000000c5,0x0003003e, + 0x000009a1,0x000009a2,0x0003003e,0x000009a3,0x000000f8,0x0004003d,0x000000b6,0x000009a5, + 0x000000c7,0x0003003e,0x000009a4,0x000009a5,0x0004003d,0x00000006,0x000009a7,0x000000c9, + 0x0003003e,0x000009a6,0x000009a7,0x000a0039,0x00000006,0x000009a8,0x000000bf,0x000000c3, + 0x000000c4,0x000009a1,0x000009a3,0x000009a4,0x000009a6,0x0003003e,0x000009a0,0x000009a8, + 0x0004003d,0x00000006,0x000009aa,0x00000993,0x00070050,0x00000007,0x000009ab,0x000009aa, + 0x000009aa,0x000009aa,0x000009aa,0x0004003d,0x00000006,0x000009ac,0x000009a0,0x00070050, + 0x00000007,0x000009ad,0x000009ac,0x000009ac,0x000009ac,0x000009ac,0x0004003d,0x00000006, + 0x000009ae,0x0000097a,0x00070050,0x00000007,0x000009af,0x000009ae,0x000009ae,0x000009ae, + 0x000009ae,0x000500aa,0x000009b1,0x000009b2,0x000009af,0x000009b0,0x000600a9,0x00000007, + 0x000009b3,0x000009b2,0x000009ad,0x000009ab,0x0003003e,0x000009a9,0x000009b3,0x000200f9, + 0x0000099f,0x000200f8,0x000009b4,0x0004003d,0x00000006,0x000009b5,0x00000993,0x00070050, + 0x00000007,0x000009b6,0x000009b5,0x000009b5,0x000009b5,0x000009b5,0x0003003e,0x000009a9, + 0x000009b6,0x000200f9,0x0000099f,0x000200f8,0x0000099f,0x0004003d,0x00000007,0x000009b7, + 0x000009a9,0x000200fe,0x000009b7,0x00010038,0x00050036,0x00000006,0x000000cf,0x00000000, + 0x000000cc,0x00030037,0x00000008,0x000000cd,0x00030037,0x00000008,0x000000ce,0x000200f8, + 0x000000d0,0x0004003b,0x000006c8,0x000009be,0x00000007,0x0004003b,0x00000008,0x000009c5, + 0x00000007,0x0004003b,0x00000008,0x000009d1,0x00000007,0x0004003b,0x00000008,0x000009d3, + 0x00000007,0x0004003d,0x00000006,0x000009ba,0x000000cd,0x000500ac,0x00000093,0x000009bb, + 0x000009ba,0x000000f8,0x000300f7,0x000009bd,0x00000000,0x000400fa,0x000009bb,0x000009bc, + 0x000009d8,0x000200f8,0x000009bc,0x0004003d,0x00000006,0x000009bf,0x000000ce,0x000500c7, + 0x00000006,0x000009c0,0x000009bf,0x00000103,0x000500aa,0x00000093,0x000009c1,0x000009c0, + 0x000000f9,0x0003003e,0x000009be,0x000009c1,0x0004003d,0x00000093,0x000009c2,0x000009be, + 0x000300f7,0x000009c4,0x00000000,0x000400fa,0x000009c2,0x000009c3,0x000009cb,0x000200f8, + 0x000009c3,0x0004003d,0x00000006,0x000009c6,0x000000ce,0x000500c2,0x00000006,0x000009c7, + 0x000009c6,0x000004fd,0x00050080,0x00000006,0x000009c8,0x000009c7,0x000000f8,0x0004003d, + 0x00000006,0x000009c9,0x000000cd,0x00050084,0x00000006,0x000009ca,0x000009c8,0x000009c9, + 0x0003003e,0x000009c5,0x000009ca,0x000200f9,0x000009c4,0x000200f8,0x000009cb,0x0004003d, + 0x00000006,0x000009cc,0x000000ce,0x000500c7,0x00000006,0x000009cd,0x000009cc,0x00000103, + 0x0004003d,0x00000006,0x000009ce,0x000000cd,0x00050084,0x00000006,0x000009cf,0x000009cd, + 0x000009ce,0x0004003d,0x00000006,0x000009d0,0x000000ce,0x0004003d,0x00000006,0x000009d2, + 0x000000cd,0x0003003e,0x000009d1,0x000009d2,0x0003003e,0x000009d3,0x000000fb,0x00070039, + 0x00000006,0x000009d4,0x00000013,0x000009d0,0x000009d1,0x000009d3,0x000400cd,0x0000012f, + 0x000009d5,0x000009d4,0x0004007c,0x00000006,0x000009d6,0x000009d5,0x00050080,0x00000006, + 0x000009d7,0x000009cf,0x000009d6,0x0003003e,0x000009c5,0x000009d7,0x000200f9,0x000009c4, + 0x000200f8,0x000009c4,0x000200f9,0x000009bd,0x000200f8,0x000009d8,0x0004003d,0x00000006, + 0x000009d9,0x000000ce,0x000500c2,0x00000006,0x000009da,0x000009d9,0x000001a6,0x00050080, + 0x00000006,0x000009db,0x000009da,0x000000f8,0x0003003e,0x000009c5,0x000009db,0x000200f9, + 0x000009bd,0x000200f8,0x000009bd,0x0004003d,0x00000006,0x000009dc,0x000009c5,0x00050084, + 0x00000006,0x000009dd,0x000009dc,0x000000fb,0x000200fe,0x000009dd,0x00010038,0x00050036, + 0x000000b6,0x000000d6,0x00000000,0x000000d1,0x00030037,0x00000007,0x000000d2,0x00030037, + 0x00000008,0x000000d3,0x00030037,0x00000008,0x000000d4,0x00030037,0x00000008,0x000000d5, + 0x000200f8,0x000000d7,0x0004003b,0x000000b7,0x000009e4,0x00000007,0x0004003b,0x00000008, + 0x000009e6,0x00000007,0x0004003b,0x00000008,0x000009e7,0x00000007,0x0004003b,0x00000008, + 0x000009ec,0x00000007,0x0004003b,0x00000008,0x000009f5,0x00000007,0x0004003b,0x00000008, + 0x00000a15,0x00000007,0x0004003b,0x00000008,0x00000a17,0x00000007,0x0004003d,0x00000006, + 0x000009e0,0x000000d4,0x000500aa,0x00000093,0x000009e1,0x000009e0,0x000000f8,0x000300f7, + 0x000009e3,0x00000000,0x000400fa,0x000009e1,0x000009e2,0x000009eb,0x000200f8,0x000009e2, + 0x0003003e,0x000009e6,0x0000010a,0x0003003e,0x000009e7,0x000009e5,0x00070039,0x00000006, + 0x000009e8,0x0000000d,0x000000d2,0x000009e6,0x000009e7,0x00050041,0x00000008,0x000009e9, + 0x000009e4,0x000000f9,0x0003003e,0x000009e9,0x000009e8,0x00050041,0x00000008,0x000009ea, + 0x000009e4,0x000000f8,0x0003003e,0x000009ea,0x000000f9,0x000200f9,0x000009e3,0x000200f8, + 0x000009eb,0x0004003d,0x00000006,0x000009ed,0x000000d3,0x000500c7,0x00000006,0x000009ee, + 0x000009ed,0x00000103,0x0003003e,0x000009ec,0x000009ee,0x0004003d,0x00000006,0x000009ef, + 0x000009ec,0x000500ab,0x00000093,0x000009f0,0x000009ef,0x000000f9,0x000300f7,0x000009f2, + 0x00000000,0x000400fa,0x000009f0,0x000009f1,0x00000a1f,0x000200f8,0x000009f1,0x0004003d, + 0x00000006,0x000009f3,0x000009ec,0x00050082,0x00000006,0x000009f4,0x000009f3,0x00000149, + 0x0003003e,0x000009ec,0x000009f4,0x0004003d,0x00000006,0x000009f6,0x000000d3,0x0004003d, + 0x00000006,0x000009f7,0x000000d5,0x00050080,0x00000006,0x000009f8,0x000000fb,0x000009f7, + 0x000500c2,0x00000006,0x000009f9,0x000009f6,0x000009f8,0x000500c7,0x00000006,0x000009fa, + 0x000009f9,0x000000f8,0x0003003e,0x000009f5,0x000009fa,0x0004003d,0x00000006,0x000009fb, + 0x000009f5,0x0004003d,0x00000006,0x000009fc,0x000009ec,0x00050080,0x00000006,0x000009fd, + 0x000009fb,0x000009fc,0x000500c4,0x00000006,0x000009fe,0x000009fd,0x000001a6,0x00050041, + 0x00000008,0x000009ff,0x000009e4,0x000000f9,0x0003003e,0x000009ff,0x000009fe,0x0004003d, + 0x00000006,0x00000a00,0x000000d3,0x0004003d,0x00000006,0x00000a01,0x000000d4,0x00050080, + 0x00000006,0x00000a02,0x000000fb,0x00000a01,0x0004003d,0x00000006,0x00000a03,0x000000d5, + 0x00050084,0x00000006,0x00000a04,0x000000fb,0x00000a03,0x00050080,0x00000006,0x00000a05, + 0x00000a02,0x00000a04,0x000500c2,0x00000006,0x00000a06,0x00000a00,0x00000a05,0x000500c7, + 0x00000006,0x00000a07,0x00000a06,0x00000103,0x00050041,0x00000008,0x00000a08,0x000009e4, + 0x000000f9,0x0004003d,0x00000006,0x00000a09,0x00000a08,0x000500c5,0x00000006,0x00000a0a, + 0x00000a09,0x00000a07,0x00050041,0x00000008,0x00000a0b,0x000009e4,0x000000f9,0x0003003e, + 0x00000a0b,0x00000a0a,0x0004003d,0x00000006,0x00000a0c,0x000000d5,0x000500ab,0x00000093, + 0x00000a0d,0x00000a0c,0x000000f9,0x000300f7,0x00000a0f,0x00000000,0x000400fa,0x00000a0d, + 0x00000a0e,0x00000a1d,0x000200f8,0x00000a0e,0x0004003d,0x00000006,0x00000a10,0x000000d3, + 0x000500c7,0x00000006,0x00000a11,0x00000a10,0x00000103,0x0004003d,0x00000006,0x00000a12, + 0x000000d5,0x00050084,0x00000006,0x00000a13,0x00000a11,0x00000a12,0x0004003d,0x00000006, + 0x00000a14,0x000000d3,0x0004003d,0x00000006,0x00000a16,0x000000d5,0x0003003e,0x00000a15, + 0x00000a16,0x0003003e,0x00000a17,0x000000fb,0x00070039,0x00000006,0x00000a18,0x00000013, + 0x00000a14,0x00000a15,0x00000a17,0x000400cd,0x0000012f,0x00000a19,0x00000a18,0x0004007c, + 0x00000006,0x00000a1a,0x00000a19,0x00050080,0x00000006,0x00000a1b,0x00000a13,0x00000a1a, + 0x00050041,0x00000008,0x00000a1c,0x000009e4,0x000000f8,0x0003003e,0x00000a1c,0x00000a1b, + 0x000200f9,0x00000a0f,0x000200f8,0x00000a1d,0x00050041,0x00000008,0x00000a1e,0x000009e4, + 0x000000f8,0x0003003e,0x00000a1e,0x000000f9,0x000200f9,0x00000a0f,0x000200f8,0x00000a0f, + 0x000200f9,0x000009f2,0x000200f8,0x00000a1f,0x0004003d,0x00000006,0x00000a20,0x000000d3, + 0x000500c2,0x00000006,0x00000a21,0x00000a20,0x000001a6,0x000500c7,0x00000006,0x00000a22, + 0x00000a21,0x000004f9,0x00050041,0x00000008,0x00000a23,0x000009e4,0x000000f9,0x0003003e, + 0x00000a23,0x00000a22,0x00050041,0x00000008,0x00000a24,0x000009e4,0x000000f9,0x0004003d, + 0x00000006,0x00000a25,0x00000a24,0x000500c2,0x00000006,0x00000a26,0x00000a25,0x000001a6, + 0x00050080,0x00000006,0x00000a27,0x00000a26,0x000000f8,0x0004003d,0x00000006,0x00000a28, + 0x000000d5,0x00050084,0x00000006,0x00000a29,0x00000a27,0x00000a28,0x00050041,0x00000008, + 0x00000a2a,0x000009e4,0x000000f8,0x0003003e,0x00000a2a,0x00000a29,0x000200f9,0x000009f2, + 0x000200f8,0x000009f2,0x000200f9,0x000009e3,0x000200f8,0x000009e3,0x00050041,0x00000008, + 0x00000a2b,0x000009e4,0x000000f8,0x0004003d,0x00000006,0x00000a2c,0x00000a2b,0x00050084, + 0x00000006,0x00000a2d,0x00000a2c,0x000000fb,0x00050041,0x00000008,0x00000a2e,0x000009e4, + 0x000000f8,0x0003003e,0x00000a2e,0x00000a2d,0x0004003d,0x000000b6,0x00000a2f,0x000009e4, + 0x000200fe,0x00000a2f,0x00010038,0x00050036,0x00000006,0x000000de,0x00000000,0x000000d8, + 0x00030037,0x00000007,0x000000d9,0x00030037,0x0000009c,0x000000da,0x00030037,0x00000008, + 0x000000db,0x00030037,0x00000008,0x000000dc,0x00030037,0x00000008,0x000000dd,0x000200f8, + 0x000000df,0x0004003b,0x00000008,0x00000a32,0x00000007,0x0004003b,0x00000008,0x00000a37, + 0x00000007,0x0004003b,0x00000008,0x00000a38,0x00000007,0x0004003b,0x00000008,0x00000a3a, + 0x00000007,0x0003003e,0x00000a32,0x000000f9,0x0004003d,0x0000009b,0x00000a33,0x000000da, + 0x0004003d,0x00000006,0x00000a34,0x000000dc,0x0004003d,0x00000006,0x00000a35,0x000000db, + 0x00050080,0x00000006,0x00000a36,0x00000a34,0x00000a35,0x0003003e,0x00000a37,0x00000a36, + 0x0004003d,0x00000006,0x00000a39,0x000000dd,0x0003003e,0x00000a38,0x00000a39,0x0003003e, + 0x00000a3a,0x0000080d,0x00090039,0x00000006,0x00000a3b,0x000000ad,0x00000a33,0x00000a37, + 0x000000d9,0x00000a38,0x00000a3a,0x0003003e,0x00000a32,0x00000a3b,0x0004003d,0x00000006, + 0x00000a3c,0x00000a32,0x000200fe,0x00000a3c,0x00010038,0x00050036,0x00000002,0x000000e8, + 0x00000000,0x000000e0,0x00030037,0x00000007,0x000000e1,0x00030037,0x00000008,0x000000e2, + 0x00030037,0x0000009c,0x000000e3,0x00030037,0x00000008,0x000000e4,0x00030037,0x00000008, + 0x000000e5,0x00030037,0x0000001c,0x000000e6,0x00030037,0x0000001c,0x000000e7,0x000200f8, + 0x000000e9,0x0004003b,0x00000008,0x00000a3f,0x00000007,0x0004003b,0x0000009c,0x00000a4a, + 0x00000007,0x0004003b,0x00000008,0x00000a4c,0x00000007,0x0004003b,0x00000008,0x00000a4e, + 0x00000007,0x0004003b,0x00000008,0x00000a4f,0x00000007,0x0004003b,0x00000008,0x00000a55, + 0x00000007,0x0004003b,0x0000009c,0x00000a58,0x00000007,0x0004003b,0x00000008,0x00000a5a, + 0x00000007,0x0004003b,0x00000008,0x00000a5c,0x00000007,0x0004003b,0x00000008,0x00000a5d, + 0x00000007,0x0004003b,0x00000008,0x00000a63,0x00000007,0x0004003b,0x00000008,0x00000a6a, + 0x00000007,0x0004003b,0x0000009c,0x00000a6d,0x00000007,0x0004003b,0x00000008,0x00000a6f, + 0x00000007,0x0004003b,0x00000008,0x00000a71,0x00000007,0x0004003b,0x00000008,0x00000a72, + 0x00000007,0x0004003b,0x00000008,0x00000a78,0x00000007,0x0004003b,0x0000009c,0x00000a7b, + 0x00000007,0x0004003b,0x00000008,0x00000a7d,0x00000007,0x0004003b,0x00000008,0x00000a7f, + 0x00000007,0x0004003b,0x00000008,0x00000a80,0x00000007,0x0004003b,0x00000008,0x00000a8a, + 0x00000007,0x0004003b,0x0000009c,0x00000a8d,0x00000007,0x0004003b,0x00000008,0x00000a8f, + 0x00000007,0x0004003b,0x00000008,0x00000a91,0x00000007,0x0004003b,0x00000008,0x00000a92, + 0x00000007,0x0004003b,0x00000008,0x00000a98,0x00000007,0x0004003b,0x0000009c,0x00000a9b, + 0x00000007,0x0004003b,0x00000008,0x00000a9d,0x00000007,0x0004003b,0x00000008,0x00000a9f, + 0x00000007,0x0004003b,0x00000008,0x00000aa0,0x00000007,0x0004003b,0x00000008,0x00000aaa, + 0x00000007,0x0004003b,0x0000009c,0x00000aad,0x00000007,0x0004003b,0x00000008,0x00000aaf, + 0x00000007,0x0004003b,0x00000008,0x00000ab1,0x00000007,0x0004003b,0x00000008,0x00000ab2, + 0x00000007,0x0004003b,0x00000008,0x00000ab8,0x00000007,0x0004003b,0x0000009c,0x00000abb, + 0x00000007,0x0004003b,0x00000008,0x00000abd,0x00000007,0x0004003b,0x00000008,0x00000abf, + 0x00000007,0x0004003b,0x00000008,0x00000ac0,0x00000007,0x0004003b,0x0000001c,0x00000ad2, + 0x00000007,0x0004003b,0x0000001c,0x00000ad3,0x00000007,0x0004003b,0x00000008,0x00000ad4, + 0x00000007,0x0004003b,0x00000008,0x00000ad6,0x00000007,0x0004003b,0x0000001c,0x00000adc, + 0x00000007,0x0004003b,0x0000001c,0x00000add,0x00000007,0x0004003b,0x00000008,0x00000ade, + 0x00000007,0x0004003b,0x00000008,0x00000ae0,0x00000007,0x0004003b,0x0000001c,0x00000ae6, + 0x00000007,0x0004003b,0x0000001c,0x00000ae7,0x00000007,0x0004003b,0x00000008,0x00000ae8, + 0x00000007,0x0004003b,0x00000008,0x00000aea,0x00000007,0x0004003b,0x00000008,0x00000aec, + 0x00000007,0x0004003b,0x00000008,0x00000aee,0x00000007,0x0004003b,0x0000001c,0x00000af4, + 0x00000007,0x0004003b,0x0000001c,0x00000af5,0x00000007,0x0004003b,0x00000008,0x00000af6, + 0x00000007,0x0004003b,0x00000008,0x00000af8,0x00000007,0x0004003b,0x00000008,0x00000afa, + 0x00000007,0x0004003b,0x00000008,0x00000afc,0x00000007,0x0004003b,0x0000001c,0x00000b02, + 0x00000007,0x0004003b,0x0000001c,0x00000b03,0x00000007,0x0004003b,0x00000008,0x00000b04, + 0x00000007,0x0004003b,0x00000008,0x00000b06,0x00000007,0x0004003b,0x00000008,0x00000b08, + 0x00000007,0x0004003b,0x00000008,0x00000b0a,0x00000007,0x0004003b,0x0000001c,0x00000b10, + 0x00000007,0x0004003b,0x0000001c,0x00000b11,0x00000007,0x0004003b,0x00000008,0x00000b12, + 0x00000007,0x0004003b,0x00000008,0x00000b14,0x00000007,0x0004003b,0x00000008,0x00000b16, + 0x00000007,0x0004003b,0x00000008,0x00000b18,0x00000007,0x0004003b,0x00000008,0x00000b1a, + 0x00000007,0x0004003b,0x00000008,0x00000b1c,0x00000007,0x0004003b,0x0000001c,0x00000b22, + 0x00000007,0x0004003b,0x0000001c,0x00000b23,0x00000007,0x0004003b,0x00000008,0x00000b24, + 0x00000007,0x0004003b,0x00000008,0x00000b26,0x00000007,0x0004003b,0x00000008,0x00000b28, + 0x00000007,0x0004003b,0x00000008,0x00000b2a,0x00000007,0x0004003b,0x00000008,0x00000b2c, + 0x00000007,0x0004003b,0x00000008,0x00000b2e,0x00000007,0x0004003b,0x0000001c,0x00000b34, + 0x00000007,0x0004003b,0x0000001c,0x00000b35,0x00000007,0x0004003b,0x00000008,0x00000b36, + 0x00000007,0x0004003b,0x00000008,0x00000b38,0x00000007,0x0004003b,0x00000008,0x00000b3a, + 0x00000007,0x0004003b,0x00000008,0x00000b3c,0x00000007,0x0004003b,0x00000008,0x00000b3e, + 0x00000007,0x0004003b,0x00000008,0x00000b40,0x00000007,0x0004003b,0x0000001c,0x00000b46, + 0x00000007,0x0004003b,0x0000001c,0x00000b47,0x00000007,0x0004003b,0x00000008,0x00000b48, + 0x00000007,0x0004003b,0x00000008,0x00000b4a,0x00000007,0x0004003b,0x00000008,0x00000b4c, + 0x00000007,0x0004003b,0x00000008,0x00000b4e,0x00000007,0x0004003b,0x00000008,0x00000b50, + 0x00000007,0x0004003b,0x00000008,0x00000b52,0x00000007,0x0004003b,0x00000008,0x00000b54, + 0x00000007,0x0004003b,0x00000008,0x00000b56,0x00000007,0x0004003b,0x0000001c,0x00000b5c, + 0x00000007,0x0004003b,0x0000001c,0x00000b5d,0x00000007,0x0004003b,0x00000008,0x00000b5e, + 0x00000007,0x0004003b,0x00000008,0x00000b60,0x00000007,0x0004003b,0x00000008,0x00000b62, + 0x00000007,0x0004003b,0x00000008,0x00000b64,0x00000007,0x0004003b,0x00000008,0x00000b66, + 0x00000007,0x0004003b,0x00000008,0x00000b68,0x00000007,0x0004003b,0x00000008,0x00000b6a, + 0x00000007,0x0004003b,0x00000008,0x00000b6c,0x00000007,0x00050041,0x00000008,0x00000a48, + 0x000000e3,0x000004dc,0x0004003d,0x00000006,0x00000a49,0x00000a48,0x0004003d,0x0000009b, + 0x00000a4b,0x000000e3,0x0003003e,0x00000a4a,0x00000a4b,0x0004003d,0x00000006,0x00000a4d, + 0x000000e5,0x0003003e,0x00000a4c,0x00000a4d,0x0003003e,0x00000a4e,0x000000f9,0x0004003d, + 0x00000006,0x00000a50,0x000000e2,0x0003003e,0x00000a4f,0x00000a50,0x00090039,0x00000006, + 0x00000a51,0x000000de,0x000000e1,0x00000a4a,0x00000a4c,0x00000a4e,0x00000a4f,0x00050080, + 0x00000006,0x00000a52,0x00000a49,0x00000a51,0x00060041,0x00000814,0x00000a53,0x00000a47, + 0x0000013b,0x00000a52,0x0004003d,0x00000006,0x00000a54,0x00000a53,0x0003003e,0x00000a3f, + 0x00000a54,0x00050041,0x00000008,0x00000a56,0x000000e3,0x000004dc,0x0004003d,0x00000006, + 0x00000a57,0x00000a56,0x0004003d,0x0000009b,0x00000a59,0x000000e3,0x0003003e,0x00000a58, + 0x00000a59,0x0004003d,0x00000006,0x00000a5b,0x000000e5,0x0003003e,0x00000a5a,0x00000a5b, + 0x0003003e,0x00000a5c,0x000000f8,0x0004003d,0x00000006,0x00000a5e,0x000000e2,0x0003003e, + 0x00000a5d,0x00000a5e,0x00090039,0x00000006,0x00000a5f,0x000000de,0x000000e1,0x00000a58, + 0x00000a5a,0x00000a5c,0x00000a5d,0x00050080,0x00000006,0x00000a60,0x00000a57,0x00000a5f, + 0x00060041,0x00000814,0x00000a61,0x00000a47,0x0000013b,0x00000a60,0x0004003d,0x00000006, + 0x00000a62,0x00000a61,0x0003003e,0x00000a55,0x00000a62,0x0004003d,0x00000006,0x00000a64, + 0x000000e4,0x000500c2,0x00000006,0x00000a65,0x00000a64,0x000001a6,0x0003003e,0x00000a63, + 0x00000a65,0x0004003d,0x00000006,0x00000a66,0x00000a63,0x000500ae,0x00000093,0x00000a67, + 0x00000a66,0x000000f8,0x000300f7,0x00000a69,0x00000000,0x000400fa,0x00000a67,0x00000a68, + 0x00000a69,0x000200f8,0x00000a68,0x00050041,0x00000008,0x00000a6b,0x000000e3,0x000004dc, + 0x0004003d,0x00000006,0x00000a6c,0x00000a6b,0x0004003d,0x0000009b,0x00000a6e,0x000000e3, + 0x0003003e,0x00000a6d,0x00000a6e,0x0004003d,0x00000006,0x00000a70,0x000000e5,0x0003003e, + 0x00000a6f,0x00000a70,0x0003003e,0x00000a71,0x000000fb,0x0004003d,0x00000006,0x00000a73, + 0x000000e2,0x0003003e,0x00000a72,0x00000a73,0x00090039,0x00000006,0x00000a74,0x000000de, + 0x000000e1,0x00000a6d,0x00000a6f,0x00000a71,0x00000a72,0x00050080,0x00000006,0x00000a75, + 0x00000a6c,0x00000a74,0x00060041,0x00000814,0x00000a76,0x00000a47,0x0000013b,0x00000a75, + 0x0004003d,0x00000006,0x00000a77,0x00000a76,0x0003003e,0x00000a6a,0x00000a77,0x00050041, + 0x00000008,0x00000a79,0x000000e3,0x000004dc,0x0004003d,0x00000006,0x00000a7a,0x00000a79, + 0x0004003d,0x0000009b,0x00000a7c,0x000000e3,0x0003003e,0x00000a7b,0x00000a7c,0x0004003d, + 0x00000006,0x00000a7e,0x000000e5,0x0003003e,0x00000a7d,0x00000a7e,0x0003003e,0x00000a7f, + 0x00000103,0x0004003d,0x00000006,0x00000a81,0x000000e2,0x0003003e,0x00000a80,0x00000a81, + 0x00090039,0x00000006,0x00000a82,0x000000de,0x000000e1,0x00000a7b,0x00000a7d,0x00000a7f, + 0x00000a80,0x00050080,0x00000006,0x00000a83,0x00000a7a,0x00000a82,0x00060041,0x00000814, + 0x00000a84,0x00000a47,0x0000013b,0x00000a83,0x0004003d,0x00000006,0x00000a85,0x00000a84, + 0x0003003e,0x00000a78,0x00000a85,0x000200f9,0x00000a69,0x000200f8,0x00000a69,0x0004003d, + 0x00000006,0x00000a86,0x00000a63,0x000500ae,0x00000093,0x00000a87,0x00000a86,0x000000fb, + 0x000300f7,0x00000a89,0x00000000,0x000400fa,0x00000a87,0x00000a88,0x00000a89,0x000200f8, + 0x00000a88,0x00050041,0x00000008,0x00000a8b,0x000000e3,0x000004dc,0x0004003d,0x00000006, + 0x00000a8c,0x00000a8b,0x0004003d,0x0000009b,0x00000a8e,0x000000e3,0x0003003e,0x00000a8d, + 0x00000a8e,0x0004003d,0x00000006,0x00000a90,0x000000e5,0x0003003e,0x00000a8f,0x00000a90, + 0x0003003e,0x00000a91,0x0000010a,0x0004003d,0x00000006,0x00000a93,0x000000e2,0x0003003e, + 0x00000a92,0x00000a93,0x00090039,0x00000006,0x00000a94,0x000000de,0x000000e1,0x00000a8d, + 0x00000a8f,0x00000a91,0x00000a92,0x00050080,0x00000006,0x00000a95,0x00000a8c,0x00000a94, + 0x00060041,0x00000814,0x00000a96,0x00000a47,0x0000013b,0x00000a95,0x0004003d,0x00000006, + 0x00000a97,0x00000a96,0x0003003e,0x00000a8a,0x00000a97,0x00050041,0x00000008,0x00000a99, + 0x000000e3,0x000004dc,0x0004003d,0x00000006,0x00000a9a,0x00000a99,0x0004003d,0x0000009b, + 0x00000a9c,0x000000e3,0x0003003e,0x00000a9b,0x00000a9c,0x0004003d,0x00000006,0x00000a9e, + 0x000000e5,0x0003003e,0x00000a9d,0x00000a9e,0x0003003e,0x00000a9f,0x000000fd,0x0004003d, + 0x00000006,0x00000aa1,0x000000e2,0x0003003e,0x00000aa0,0x00000aa1,0x00090039,0x00000006, + 0x00000aa2,0x000000de,0x000000e1,0x00000a9b,0x00000a9d,0x00000a9f,0x00000aa0,0x00050080, + 0x00000006,0x00000aa3,0x00000a9a,0x00000aa2,0x00060041,0x00000814,0x00000aa4,0x00000a47, + 0x0000013b,0x00000aa3,0x0004003d,0x00000006,0x00000aa5,0x00000aa4,0x0003003e,0x00000a98, + 0x00000aa5,0x000200f9,0x00000a89,0x000200f8,0x00000a89,0x0004003d,0x00000006,0x00000aa6, + 0x00000a63,0x000500ae,0x00000093,0x00000aa7,0x00000aa6,0x00000103,0x000300f7,0x00000aa9, + 0x00000000,0x000400fa,0x00000aa7,0x00000aa8,0x00000aa9,0x000200f8,0x00000aa8,0x00050041, + 0x00000008,0x00000aab,0x000000e3,0x000004dc,0x0004003d,0x00000006,0x00000aac,0x00000aab, + 0x0004003d,0x0000009b,0x00000aae,0x000000e3,0x0003003e,0x00000aad,0x00000aae,0x0004003d, + 0x00000006,0x00000ab0,0x000000e5,0x0003003e,0x00000aaf,0x00000ab0,0x0003003e,0x00000ab1, + 0x00000117,0x0004003d,0x00000006,0x00000ab3,0x000000e2,0x0003003e,0x00000ab2,0x00000ab3, + 0x00090039,0x00000006,0x00000ab4,0x000000de,0x000000e1,0x00000aad,0x00000aaf,0x00000ab1, + 0x00000ab2,0x00050080,0x00000006,0x00000ab5,0x00000aac,0x00000ab4,0x00060041,0x00000814, + 0x00000ab6,0x00000a47,0x0000013b,0x00000ab5,0x0004003d,0x00000006,0x00000ab7,0x00000ab6, + 0x0003003e,0x00000aaa,0x00000ab7,0x00050041,0x00000008,0x00000ab9,0x000000e3,0x000004dc, + 0x0004003d,0x00000006,0x00000aba,0x00000ab9,0x0004003d,0x0000009b,0x00000abc,0x000000e3, + 0x0003003e,0x00000abb,0x00000abc,0x0004003d,0x00000006,0x00000abe,0x000000e5,0x0003003e, + 0x00000abd,0x00000abe,0x0003003e,0x00000abf,0x0000011e,0x0004003d,0x00000006,0x00000ac1, + 0x000000e2,0x0003003e,0x00000ac0,0x00000ac1,0x00090039,0x00000006,0x00000ac2,0x000000de, + 0x000000e1,0x00000abb,0x00000abd,0x00000abf,0x00000ac0,0x00050080,0x00000006,0x00000ac3, + 0x00000aba,0x00000ac2,0x00060041,0x00000814,0x00000ac4,0x00000a47,0x0000013b,0x00000ac3, + 0x0004003d,0x00000006,0x00000ac5,0x00000ac4,0x0003003e,0x00000ab8,0x00000ac5,0x000200f9, + 0x00000aa9,0x000200f8,0x00000aa9,0x0004003d,0x00000006,0x00000ac6,0x000000e4,0x000300f7, + 0x00000ad1,0x00000000,0x001700fb,0x00000ac6,0x00000ad1,0x00000000,0x00000ac7,0x00000001, + 0x00000ac8,0x00000004,0x00000ac9,0x00000005,0x00000aca,0x00000006,0x00000acb,0x0000000a, + 0x00000acc,0x00000008,0x00000acd,0x00000009,0x00000ace,0x0000000c,0x00000acf,0x0000000d, + 0x00000ad0,0x000200f8,0x00000ac7,0x0004003d,0x00000006,0x00000ad5,0x00000a3f,0x0003003e, + 0x00000ad4,0x00000ad5,0x0004003d,0x00000006,0x00000ad7,0x00000a55,0x0003003e,0x00000ad6, + 0x00000ad7,0x00080039,0x00000002,0x00000ad8,0x00000022,0x00000ad2,0x00000ad3,0x00000ad4, + 0x00000ad6,0x0004003d,0x00000007,0x00000ad9,0x00000ad2,0x0003003e,0x000000e6,0x00000ad9, + 0x0004003d,0x00000007,0x00000ada,0x00000ad3,0x0003003e,0x000000e7,0x00000ada,0x000200f9, + 0x00000ad1,0x000200f8,0x00000ac8,0x0004003d,0x00000006,0x00000adf,0x00000a3f,0x0003003e, + 0x00000ade,0x00000adf,0x0004003d,0x00000006,0x00000ae1,0x00000a55,0x0003003e,0x00000ae0, + 0x00000ae1,0x00080039,0x00000002,0x00000ae2,0x00000028,0x00000adc,0x00000add,0x00000ade, + 0x00000ae0,0x0004003d,0x00000007,0x00000ae3,0x00000adc,0x0003003e,0x000000e6,0x00000ae3, + 0x0004003d,0x00000007,0x00000ae4,0x00000add,0x0003003e,0x000000e7,0x00000ae4,0x000200f9, + 0x00000ad1,0x000200f8,0x00000ac9,0x0004003d,0x00000006,0x00000ae9,0x00000a3f,0x0003003e, + 0x00000ae8,0x00000ae9,0x0004003d,0x00000006,0x00000aeb,0x00000a55,0x0003003e,0x00000aea, + 0x00000aeb,0x0004003d,0x00000006,0x00000aed,0x00000a6a,0x0003003e,0x00000aec,0x00000aed, + 0x0004003d,0x00000006,0x00000aef,0x00000a78,0x0003003e,0x00000aee,0x00000aef,0x000a0039, + 0x00000002,0x00000af0,0x00000031,0x00000ae6,0x00000ae7,0x00000ae8,0x00000aea,0x00000aec, + 0x00000aee,0x0004003d,0x00000007,0x00000af1,0x00000ae6,0x0003003e,0x000000e6,0x00000af1, + 0x0004003d,0x00000007,0x00000af2,0x00000ae7,0x0003003e,0x000000e7,0x00000af2,0x000200f9, + 0x00000ad1,0x000200f8,0x00000aca,0x0004003d,0x00000006,0x00000af7,0x00000a3f,0x0003003e, + 0x00000af6,0x00000af7,0x0004003d,0x00000006,0x00000af9,0x00000a55,0x0003003e,0x00000af8, + 0x00000af9,0x0004003d,0x00000006,0x00000afb,0x00000a6a,0x0003003e,0x00000afa,0x00000afb, + 0x0004003d,0x00000006,0x00000afd,0x00000a78,0x0003003e,0x00000afc,0x00000afd,0x000a0039, + 0x00000002,0x00000afe,0x00000039,0x00000af4,0x00000af5,0x00000af6,0x00000af8,0x00000afa, + 0x00000afc,0x0004003d,0x00000007,0x00000aff,0x00000af4,0x0003003e,0x000000e6,0x00000aff, + 0x0004003d,0x00000007,0x00000b00,0x00000af5,0x0003003e,0x000000e7,0x00000b00,0x000200f9, + 0x00000ad1,0x000200f8,0x00000acb,0x0004003d,0x00000006,0x00000b05,0x00000a3f,0x0003003e, + 0x00000b04,0x00000b05,0x0004003d,0x00000006,0x00000b07,0x00000a55,0x0003003e,0x00000b06, + 0x00000b07,0x0004003d,0x00000006,0x00000b09,0x00000a6a,0x0003003e,0x00000b08,0x00000b09, + 0x0004003d,0x00000006,0x00000b0b,0x00000a78,0x0003003e,0x00000b0a,0x00000b0b,0x000a0039, + 0x00000002,0x00000b0c,0x00000041,0x00000b02,0x00000b03,0x00000b04,0x00000b06,0x00000b08, + 0x00000b0a,0x0004003d,0x00000007,0x00000b0d,0x00000b02,0x0003003e,0x000000e6,0x00000b0d, + 0x0004003d,0x00000007,0x00000b0e,0x00000b03,0x0003003e,0x000000e7,0x00000b0e,0x000200f9, + 0x00000ad1,0x000200f8,0x00000acc,0x0004003d,0x00000006,0x00000b13,0x00000a3f,0x0003003e, + 0x00000b12,0x00000b13,0x0004003d,0x00000006,0x00000b15,0x00000a55,0x0003003e,0x00000b14, + 0x00000b15,0x0004003d,0x00000006,0x00000b17,0x00000a6a,0x0003003e,0x00000b16,0x00000b17, + 0x0004003d,0x00000006,0x00000b19,0x00000a78,0x0003003e,0x00000b18,0x00000b19,0x0004003d, + 0x00000006,0x00000b1b,0x00000a8a,0x0003003e,0x00000b1a,0x00000b1b,0x0004003d,0x00000006, + 0x00000b1d,0x00000a98,0x0003003e,0x00000b1c,0x00000b1d,0x000c0039,0x00000002,0x00000b1e, + 0x0000004c,0x00000b10,0x00000b11,0x00000b12,0x00000b14,0x00000b16,0x00000b18,0x00000b1a, + 0x00000b1c,0x0004003d,0x00000007,0x00000b1f,0x00000b10,0x0003003e,0x000000e6,0x00000b1f, + 0x0004003d,0x00000007,0x00000b20,0x00000b11,0x0003003e,0x000000e7,0x00000b20,0x000200f9, + 0x00000ad1,0x000200f8,0x00000acd,0x0004003d,0x00000006,0x00000b25,0x00000a3f,0x0003003e, + 0x00000b24,0x00000b25,0x0004003d,0x00000006,0x00000b27,0x00000a55,0x0003003e,0x00000b26, + 0x00000b27,0x0004003d,0x00000006,0x00000b29,0x00000a6a,0x0003003e,0x00000b28,0x00000b29, + 0x0004003d,0x00000006,0x00000b2b,0x00000a78,0x0003003e,0x00000b2a,0x00000b2b,0x0004003d, + 0x00000006,0x00000b2d,0x00000a8a,0x0003003e,0x00000b2c,0x00000b2d,0x0004003d,0x00000006, + 0x00000b2f,0x00000a98,0x0003003e,0x00000b2e,0x00000b2f,0x000c0039,0x00000002,0x00000b30, + 0x00000056,0x00000b22,0x00000b23,0x00000b24,0x00000b26,0x00000b28,0x00000b2a,0x00000b2c, + 0x00000b2e,0x0004003d,0x00000007,0x00000b31,0x00000b22,0x0003003e,0x000000e6,0x00000b31, + 0x0004003d,0x00000007,0x00000b32,0x00000b23,0x0003003e,0x000000e7,0x00000b32,0x000200f9, + 0x00000ad1,0x000200f8,0x00000ace,0x0004003d,0x00000006,0x00000b37,0x00000a3f,0x0003003e, + 0x00000b36,0x00000b37,0x0004003d,0x00000006,0x00000b39,0x00000a55,0x0003003e,0x00000b38, + 0x00000b39,0x0004003d,0x00000006,0x00000b3b,0x00000a6a,0x0003003e,0x00000b3a,0x00000b3b, + 0x0004003d,0x00000006,0x00000b3d,0x00000a78,0x0003003e,0x00000b3c,0x00000b3d,0x0004003d, + 0x00000006,0x00000b3f,0x00000a8a,0x0003003e,0x00000b3e,0x00000b3f,0x0004003d,0x00000006, + 0x00000b41,0x00000a98,0x0003003e,0x00000b40,0x00000b41,0x000c0039,0x00000002,0x00000b42, + 0x00000060,0x00000b34,0x00000b35,0x00000b36,0x00000b38,0x00000b3a,0x00000b3c,0x00000b3e, + 0x00000b40,0x0004003d,0x00000007,0x00000b43,0x00000b34,0x0003003e,0x000000e6,0x00000b43, + 0x0004003d,0x00000007,0x00000b44,0x00000b35,0x0003003e,0x000000e7,0x00000b44,0x000200f9, + 0x00000ad1,0x000200f8,0x00000acf,0x0004003d,0x00000006,0x00000b49,0x00000a3f,0x0003003e, + 0x00000b48,0x00000b49,0x0004003d,0x00000006,0x00000b4b,0x00000a55,0x0003003e,0x00000b4a, + 0x00000b4b,0x0004003d,0x00000006,0x00000b4d,0x00000a6a,0x0003003e,0x00000b4c,0x00000b4d, + 0x0004003d,0x00000006,0x00000b4f,0x00000a78,0x0003003e,0x00000b4e,0x00000b4f,0x0004003d, + 0x00000006,0x00000b51,0x00000a8a,0x0003003e,0x00000b50,0x00000b51,0x0004003d,0x00000006, + 0x00000b53,0x00000a98,0x0003003e,0x00000b52,0x00000b53,0x0004003d,0x00000006,0x00000b55, + 0x00000aaa,0x0003003e,0x00000b54,0x00000b55,0x0004003d,0x00000006,0x00000b57,0x00000ab8, + 0x0003003e,0x00000b56,0x00000b57,0x000e0039,0x00000002,0x00000b58,0x0000006d,0x00000b46, + 0x00000b47,0x00000b48,0x00000b4a,0x00000b4c,0x00000b4e,0x00000b50,0x00000b52,0x00000b54, + 0x00000b56,0x0004003d,0x00000007,0x00000b59,0x00000b46,0x0003003e,0x000000e6,0x00000b59, + 0x0004003d,0x00000007,0x00000b5a,0x00000b47,0x0003003e,0x000000e7,0x00000b5a,0x000200f9, + 0x00000ad1,0x000200f8,0x00000ad0,0x0004003d,0x00000006,0x00000b5f,0x00000a3f,0x0003003e, + 0x00000b5e,0x00000b5f,0x0004003d,0x00000006,0x00000b61,0x00000a55,0x0003003e,0x00000b60, + 0x00000b61,0x0004003d,0x00000006,0x00000b63,0x00000a6a,0x0003003e,0x00000b62,0x00000b63, + 0x0004003d,0x00000006,0x00000b65,0x00000a78,0x0003003e,0x00000b64,0x00000b65,0x0004003d, + 0x00000006,0x00000b67,0x00000a8a,0x0003003e,0x00000b66,0x00000b67,0x0004003d,0x00000006, + 0x00000b69,0x00000a98,0x0003003e,0x00000b68,0x00000b69,0x0004003d,0x00000006,0x00000b6b, + 0x00000aaa,0x0003003e,0x00000b6a,0x00000b6b,0x0004003d,0x00000006,0x00000b6d,0x00000ab8, + 0x0003003e,0x00000b6c,0x00000b6d,0x000e0039,0x00000002,0x00000b6e,0x00000079,0x00000b5c, + 0x00000b5d,0x00000b5e,0x00000b60,0x00000b62,0x00000b64,0x00000b66,0x00000b68,0x00000b6a, + 0x00000b6c,0x0004003d,0x00000007,0x00000b6f,0x00000b5c,0x0003003e,0x000000e6,0x00000b6f, + 0x0004003d,0x00000007,0x00000b70,0x00000b5d,0x0003003e,0x000000e7,0x00000b70,0x000200f9, + 0x00000ad1,0x000200f8,0x00000ad1,0x0004003d,0x00000007,0x00000b74,0x000000e6,0x00070050, + 0x00000007,0x00000b75,0x00000b73,0x00000b73,0x00000b73,0x00000b73,0x00050084,0x00000007, + 0x00000b76,0x00000b74,0x00000b75,0x0003003e,0x000000e6,0x00000b76,0x0004003d,0x00000007, + 0x00000b77,0x000000e7,0x00070050,0x00000007,0x00000b78,0x00000b73,0x00000b73,0x00000b73, + 0x00000b73,0x00050084,0x00000007,0x00000b79,0x00000b77,0x00000b78,0x0003003e,0x000000e7, + 0x00000b79,0x000100fd,0x00010038,0x00050036,0x00000007,0x000000ec,0x00000000,0x000000ea, + 0x00030037,0x0000001c,0x000000eb,0x000200f8,0x000000ed,0x0004003b,0x00000b7b,0x00000b7c, + 0x00000007,0x0004003b,0x00000b7b,0x00000b80,0x00000007,0x0004003b,0x00000b7b,0x00000b84, + 0x00000007,0x00050041,0x00000008,0x00000b7d,0x000000eb,0x000000f9,0x0004003d,0x00000006, + 0x00000b7e,0x00000b7d,0x00040070,0x00000b7a,0x00000b7f,0x00000b7e,0x0003003e,0x00000b7c, + 0x00000b7f,0x00050041,0x00000008,0x00000b81,0x000000eb,0x000000f8,0x0004003d,0x00000006, + 0x00000b82,0x00000b81,0x00040070,0x00000b7a,0x00000b83,0x00000b82,0x0003003e,0x00000b80, + 0x00000b83,0x00050041,0x00000008,0x00000b85,0x000000eb,0x000000fb,0x0004003d,0x00000006, + 0x00000b86,0x00000b85,0x00040070,0x00000b7a,0x00000b87,0x00000b86,0x0003003e,0x00000b84, + 0x00000b87,0x0004003d,0x00000b7a,0x00000b88,0x00000b7c,0x000500bc,0x00000093,0x00000b8a, + 0x00000b88,0x00000b89,0x000300f7,0x00000b8c,0x00000000,0x000400fa,0x00000b8a,0x00000b8b, + 0x00000b90,0x000200f8,0x00000b8b,0x0004003d,0x00000b7a,0x00000b8d,0x00000b7c,0x00050085, + 0x00000b7a,0x00000b8f,0x00000b8d,0x00000b8e,0x0003003e,0x00000b7c,0x00000b8f,0x000200f9, + 0x00000b8c,0x000200f8,0x00000b90,0x0004003d,0x00000b7a,0x00000b91,0x00000b7c,0x000500bc, + 0x00000093,0x00000b93,0x00000b91,0x00000b92,0x000300f7,0x00000b95,0x00000000,0x000400fa, + 0x00000b93,0x00000b94,0x00000b95,0x000200f8,0x00000b94,0x0004003d,0x00000b7a,0x00000b97, + 0x00000b7c,0x0007000c,0x00000b7a,0x00000b99,0x00000001,0x0000001a,0x00000b97,0x00000b98, + 0x00050085,0x00000b7a,0x00000b9a,0x00000b96,0x00000b99,0x00050083,0x00000b7a,0x00000b9c, + 0x00000b9a,0x00000b9b,0x0003003e,0x00000b7c,0x00000b9c,0x000200f9,0x00000b95,0x000200f8, + 0x00000b95,0x000200f9,0x00000b8c,0x000200f8,0x00000b8c,0x0004003d,0x00000b7a,0x00000b9d, + 0x00000b80,0x000500bc,0x00000093,0x00000b9e,0x00000b9d,0x00000b89,0x000300f7,0x00000ba0, + 0x00000000,0x000400fa,0x00000b9e,0x00000b9f,0x00000ba3,0x000200f8,0x00000b9f,0x0004003d, + 0x00000b7a,0x00000ba1,0x00000b80,0x00050085,0x00000b7a,0x00000ba2,0x00000ba1,0x00000b8e, + 0x0003003e,0x00000b80,0x00000ba2,0x000200f9,0x00000ba0,0x000200f8,0x00000ba3,0x0004003d, + 0x00000b7a,0x00000ba4,0x00000b80,0x000500bc,0x00000093,0x00000ba5,0x00000ba4,0x00000b92, + 0x000300f7,0x00000ba7,0x00000000,0x000400fa,0x00000ba5,0x00000ba6,0x00000ba7,0x000200f8, + 0x00000ba6,0x0004003d,0x00000b7a,0x00000ba8,0x00000b80,0x0007000c,0x00000b7a,0x00000ba9, + 0x00000001,0x0000001a,0x00000ba8,0x00000b98,0x00050085,0x00000b7a,0x00000baa,0x00000b96, + 0x00000ba9,0x00050083,0x00000b7a,0x00000bab,0x00000baa,0x00000b9b,0x0003003e,0x00000b80, + 0x00000bab,0x000200f9,0x00000ba7,0x000200f8,0x00000ba7,0x000200f9,0x00000ba0,0x000200f8, + 0x00000ba0,0x0004003d,0x00000b7a,0x00000bac,0x00000b84,0x000500bc,0x00000093,0x00000bad, + 0x00000bac,0x00000b89,0x000300f7,0x00000baf,0x00000000,0x000400fa,0x00000bad,0x00000bae, + 0x00000bb2,0x000200f8,0x00000bae,0x0004003d,0x00000b7a,0x00000bb0,0x00000b84,0x00050085, + 0x00000b7a,0x00000bb1,0x00000bb0,0x00000b8e,0x0003003e,0x00000b84,0x00000bb1,0x000200f9, + 0x00000baf,0x000200f8,0x00000bb2,0x0004003d,0x00000b7a,0x00000bb3,0x00000b84,0x000500bc, + 0x00000093,0x00000bb4,0x00000bb3,0x00000b92,0x000300f7,0x00000bb6,0x00000000,0x000400fa, + 0x00000bb4,0x00000bb5,0x00000bb6,0x000200f8,0x00000bb5,0x0004003d,0x00000b7a,0x00000bb7, + 0x00000b84,0x0007000c,0x00000b7a,0x00000bb8,0x00000001,0x0000001a,0x00000bb7,0x00000b98, + 0x00050085,0x00000b7a,0x00000bb9,0x00000b96,0x00000bb8,0x00050083,0x00000b7a,0x00000bba, + 0x00000bb9,0x00000b9b,0x0003003e,0x00000b84,0x00000bba,0x000200f9,0x00000bb6,0x000200f8, + 0x00000bb6,0x000200f9,0x00000baf,0x000200f8,0x00000baf,0x0004003d,0x00000b7a,0x00000bbb, + 0x00000b7c,0x0004006d,0x00000006,0x00000bbc,0x00000bbb,0x0004003d,0x00000b7a,0x00000bbd, + 0x00000b80,0x0004006d,0x00000006,0x00000bbe,0x00000bbd,0x0004003d,0x00000b7a,0x00000bbf, + 0x00000b84,0x0004006d,0x00000006,0x00000bc0,0x00000bbf,0x00050041,0x00000008,0x00000bc1, + 0x000000eb,0x00000103,0x0004003d,0x00000006,0x00000bc2,0x00000bc1,0x00070050,0x00000007, + 0x00000bc3,0x00000bbc,0x00000bbe,0x00000bc0,0x00000bc2,0x000200fe,0x00000bc3,0x00010038, + 0x00050036,0x00000007,0x000000f2,0x00000000,0x000000ee,0x00030037,0x0000001c,0x000000ef, + 0x00030037,0x0000001c,0x000000f0,0x00030037,0x0000001c,0x000000f1,0x000200f8,0x000000f3, + 0x0004003b,0x0000001c,0x00000bc6,0x00000007,0x0004003b,0x0000001c,0x00000bc8,0x00000007, + 0x0004003b,0x0000001c,0x00000bd3,0x00000007,0x0004003b,0x0000001c,0x00000be2,0x00000007, + 0x0004003b,0x0000001c,0x00000beb,0x00000007,0x0004003d,0x00000007,0x00000bc7,0x000000ef, + 0x0003003e,0x00000bc6,0x00000bc7,0x0004003d,0x00000007,0x00000bc9,0x000000f0,0x0003003e, + 0x00000bc8,0x00000bc9,0x000300f7,0x00000bcc,0x00000000,0x000400fa,0x00000bca,0x00000bcb, + 0x00000bcc,0x000200f8,0x00000bcb,0x0004003d,0x00000007,0x00000bcd,0x000000ef,0x00070050, + 0x00000284,0x00000bce,0x0000023b,0x0000023b,0x0000023b,0x0000023b,0x000500c2,0x00000007, + 0x00000bcf,0x00000bcd,0x00000bce,0x0003003e,0x00000bc6,0x00000bcf,0x0004003d,0x00000007, + 0x00000bd0,0x000000f0,0x00070050,0x00000284,0x00000bd1,0x0000023b,0x0000023b,0x0000023b, + 0x0000023b,0x000500c2,0x00000007,0x00000bd2,0x00000bd0,0x00000bd1,0x0003003e,0x00000bc8, + 0x00000bd2,0x000200f9,0x00000bcc,0x000200f8,0x00000bcc,0x0004003d,0x00000007,0x00000bd4, + 0x00000bc6,0x0004003d,0x00000007,0x00000bd6,0x000000f1,0x00070050,0x00000007,0x00000bd7, + 0x00000bd5,0x00000bd5,0x00000bd5,0x00000bd5,0x00050082,0x00000007,0x00000bd8,0x00000bd7, + 0x00000bd6,0x00050084,0x00000007,0x00000bd9,0x00000bd4,0x00000bd8,0x0004003d,0x00000007, + 0x00000bda,0x00000bc8,0x0004003d,0x00000007,0x00000bdb,0x000000f1,0x00050084,0x00000007, + 0x00000bdc,0x00000bda,0x00000bdb,0x00050080,0x00000007,0x00000bdd,0x00000bd9,0x00000bdc, + 0x00070050,0x00000007,0x00000bde,0x0000012b,0x0000012b,0x0000012b,0x0000012b,0x00050080, + 0x00000007,0x00000bdf,0x00000bdd,0x00000bde,0x00070050,0x00000284,0x00000be0,0x000004e1, + 0x000004e1,0x000004e1,0x000004e1,0x000500c2,0x00000007,0x00000be1,0x00000bdf,0x00000be0, + 0x0003003e,0x00000bd3,0x00000be1,0x0004003d,0x00000007,0x00000be3,0x00000bd3,0x0003003e, + 0x00000be2,0x00000be3,0x000300f7,0x00000be5,0x00000000,0x000400fa,0x00000bca,0x00000be4, + 0x00000be5,0x000200f8,0x00000be4,0x0004003d,0x00000007,0x00000be6,0x00000bd3,0x0004003d, + 0x00000007,0x00000be7,0x00000bd3,0x00070050,0x00000284,0x00000be8,0x0000023b,0x0000023b, + 0x0000023b,0x0000023b,0x000500c4,0x00000007,0x00000be9,0x00000be7,0x00000be8,0x000500c5, + 0x00000007,0x00000bea,0x00000be6,0x00000be9,0x0003003e,0x00000bd3,0x00000bea,0x0004003d, + 0x00000007,0x00000bec,0x00000bd3,0x0003003e,0x00000beb,0x00000bec,0x00050039,0x00000007, + 0x00000bed,0x000000ec,0x00000beb,0x0003003e,0x00000be2,0x00000bed,0x000200f9,0x00000be5, + 0x000200f8,0x00000be5,0x0004003d,0x00000007,0x00000bee,0x00000be2,0x000200fe,0x00000bee, + 0x00010038 +}; diff --git a/icd/make/importdefs b/icd/make/importdefs index 86b9f9cb..da10b171 100644 --- a/icd/make/importdefs +++ b/icd/make/importdefs @@ -26,7 +26,7 @@ # This will become the value of PAL_CLIENT_INTERFACE_MAJOR_VERSION. It describes the version of the PAL interface # that the ICD supports. PAL uses this value to enable backwards-compatibility for older interface versions. It must # be updated on each PAL promotion after handling all of the interface changes described in palLib.h. -ICD_PAL_CLIENT_MAJOR_VERSION = 673 +ICD_PAL_CLIENT_MAJOR_VERSION = 674 ICD_PAL_CLIENT_MINOR_VERSION = 0 # This will become the value of GPUOPEN_CLIENT_INTERFACE_MAJOR_VERSION if ICD_GPUOPEN_DEVMODE_BUILD=1. It describes diff --git a/icd/res/ver.h b/icd/res/ver.h index 27bcdc55..2cf2235d 100644 --- a/icd/res/ver.h +++ b/icd/res/ver.h @@ -36,7 +36,7 @@ #define VERSION_MAJOR_STR MAKE_VERSION_STRING(VULKAN_ICD_MAJOR_VERSION) "\0" // Bump up after each promotion to mainline -#define VULKAN_ICD_BUILD_VERSION 193 +#define VULKAN_ICD_BUILD_VERSION 195 // String version is needed with leading zeros and extra termination (unicode) #define VERSION_NUMBER_MINOR VULKAN_ICD_BUILD_VERSION diff --git a/icd/settings/settings.cpp b/icd/settings/settings.cpp index 9662d546..13625766 100644 --- a/icd/settings/settings.cpp +++ b/icd/settings/settings.cpp @@ -620,9 +620,8 @@ VkResult VulkanSettingsLoader::OverrideProfiledSettings( if (pInfo->gfxLevel == Pal::GfxIpLevel::GfxIp10_3) { - // Forcing these DCC settings prevents extreme corruption due to DCC for color attachments and provides an additional - // gain of 2-4% over what is achieved from the above force image sharing mode optimization. m_settings.forceEnableDcc = (ForceDccForNonColorAttachmentShaderStorage | + ForceDccForColorAttachments | ForceDccFor2DShaderStorage | ForceDccFor3DShaderStorage | ForceDccFor32BppShaderStorage | @@ -663,6 +662,8 @@ VkResult VulkanSettingsLoader::OverrideProfiledSettings( ForceDccForNonColorAttachmentShaderStorage | ForceDccFor64BppShaderStorage); } + + m_settings.implicitExternalSynchronization = false; } if (appProfile == AppProfile::GhostReconBreakpoint) @@ -679,6 +680,8 @@ VkResult VulkanSettingsLoader::OverrideProfiledSettings( ForceDccForNonColorAttachmentShaderStorage | ForceDccFor64BppShaderStorage); } + + m_settings.implicitExternalSynchronization = false; } if (appProfile == AppProfile::DoomEternal) diff --git a/icd/settings/settings_xgl.json b/icd/settings/settings_xgl.json index 2205cf8d..a770b0ac 100644 --- a/icd/settings/settings_xgl.json +++ b/icd/settings/settings_xgl.json @@ -9,7 +9,6 @@ "Pipeline Options", "Present", "SPIRV Options", - "Ray Tracing", "Debugging", "General", "Memory", @@ -1237,18 +1236,6 @@ "Name": "CsWaveSize", "Scope": "Driver" }, - { - "Description": "Force ray tracing shaders to run with a particular wave size. This is ignored if subgroup operations are used by the shader, see SubgroupSize. 0 - Let compiler choose Wave32 vs Wave64 mode (default) 32 - Run in Wave32 mode 64 - Run in Wave64 mode ", - "Tags": [ - "SPIRV Options" - ], - "Defaults": { - "Default": 32 - }, - "Type": "uint32", - "Name": "RtWaveSize", - "Scope": "Driver" - }, { "Description": "Enable NGG mode, use an implicit primitive shader on a per-pipeline type basis. Use this instead of PAL setting, NggEnableMode.", "Tags": [ @@ -2043,82 +2030,6 @@ "Type": "bool", "Name": "DumpDuplicatePipelines" }, - { - "Description": "Mask for enabling SPIR-V pass for internal ray tracing pipelines. The bit is corresponding to the enum defined in gpurt header.", - "Tags": [ - "Ray Tracing" - ], - "Defaults": { - "Default": "0xffffffffffffffff" - }, - "Flags": { - "IsHex": true, - "IsBitmask": true - }, - "Scope": "Driver", - "Type": "uint64", - "Name": "RtInternalPipelineSpvPassMask" - }, - { - "Description": "Box sorting heuristic", - "Tags": [ - "Ray Tracing" - ], - "Defaults": { - "Default": "BoxSortingClosest" - }, - "ValidValues": { - "IsEnum": true, - "Name": "BoxSortingMode", - "Values": [ - { - "Name": "BoxSortingClosest", - "Value": 0, - "Description": "Traversal is ordered to enter the children that intersect the ray closer to the ray origin first." - }, - { - "Name": "BoxSortingLargest", - "Value": 1, - "Description": "Traversal is ordered to enter the children that have the largest interval where the box intersects the ray first." - }, - { - "Name": "BoxSortingMidPoint", - "Value": 2, - "Description": "Traversal is ordered to enter the children that have a midpoint in the interval where the box intersects that has the lowest intersection time before clamping." - }, - { - "Name": "BoxSortingDisabled", - "Value": 3, - "Description": "Disable box sorting heuristic." - }, - { - "Name": "BoxSortingLargestFirstAndClosest", - "Value": 4, - "Description": "Auto select box sort mode. If rayFlag indicates RAY_FLAG_ACCEPT_FIRST_HIT_AND_END_SEARCH, choose BoxSortLargest. Otherwise choose BoxSortClosest." - }, - { - "Name": "BoxSortingLargestFirstAndClosestMidpoint", - "Value": 5, - "Description": "Auto select box sort mode. If rayFlag indicates RAY_FLAG_ACCEPT_FIRST_HIT_AND_END_SEARCH, choose BoxSortLargest. Otherwise choose BoxSortMidPoint." - } - ] - }, - "Type": "enum", - "Name": "BoxSortingHeuristic", - "Scope": "Driver" - }, - { - "Description": "Enable Variable Bits Morton Codes - Selects the largest axis per bit rather than rotating xyzxyz", - "Tags": [ - "Ray Tracing" - ], - "Defaults": { - "Default": false - }, - "Type": "bool", - "Name": "EnableVariableBitsMortonCodes", - "Scope": "Driver" - }, { "Name": "DbgBarrierPostCmdEnable", "Description": "Triggers a CmdBarrier call after any command in the given mask. The barrier behavior is controlled by the other DbgBarrierPost* settings in this category. Requires VK_ENABLE_DEBUG_BARRIERS=1 to take effect. 0x8FFFFFFF: All commands (heavyweight option)", @@ -2270,21 +2181,6 @@ "Value": 67108864, "Description": "Any video operations" }, - { - "Name": "DbgBuildAccelerationStructureTLAS", - "Value": 134217728, - "Description": "Build ray tracing operations" - }, - { - "Name": "DbgBuildAccelerationStructureBLAS", - "Value": 268435456, - "Description": "Build ray tracing operations" - }, - { - "Name": "DbgTraceRays", - "Value": 536870912, - "Description": "Trace ray tracing operations" - }, { "Name": "DbgBarrierBeginRendering", "Value": 1073741824, @@ -4522,19 +4418,16 @@ "Name": "ForceCsThreadGroupSwizzleMode" }, { - "Description": "Force all ray tracing shaders compiled in unified mode to have swizzled thread groups.", + "Description": "Enable GPU decompress pass for astc/etc image, it is on the vkCopyBufferToImage, and not safe depending on application.", "Tags": [ - "Optimization" + "Developer Mode" ], - "ValidValues": { - "Name": "ThreadGroupSwizzleMode" - }, "Defaults": { - "Default": "ThreadGroupSwizzleModeDefault" + "Default": false }, "Scope": "Driver", - "Type": "enum", - "Name": "ForceRtThreadGroupSwizzleMode" + "Type": "bool", + "Name": "EnableShaderDecode" }, { "Description": "Determines the string that's used to trigger a start-frame delimiter via vkQueueInsertDebugUtilsLabelEXT. This string is \"AmdFrameBegin\" by default.", diff --git a/icd/tools/generate/vulkanSettingsCodeTemplates.py b/icd/tools/generate/vulkanSettingsCodeTemplates.py index f3ca3028..d8980027 100644 --- a/icd/tools/generate/vulkanSettingsCodeTemplates.py +++ b/icd/tools/generate/vulkanSettingsCodeTemplates.py @@ -125,7 +125,6 @@ WinIfDef = "defined(_WIN32)\n" LnxIfDef = "(__unix__)\n" -AndroidIfDef = "defined(__ANDROID__)\n" ReadSettingsFunc = "\n\ // =====================================================================================================================\n\