Skip to content

Commit

Permalink
Update xgl from commit 1e4dcb9f
Browse files Browse the repository at this point in the history
Update Khronos Vulkan Headers to 1.3.279
Add a setting for EnableRemapScratchBuffer
Add a setting for enabling the thread safe PAL functionality for
Add a setting for GpuRtGpuDebugFlags
Add a setting for IFHRayTracing
Add a setting for issuing a (queue) wait-idle following each submit call
Add a setting to enable ColorClearAutoSync in vkCmdColorImage
Add a setting to enable/disable VRS support corresponding to a driver experiment
Add a settings for disabling mesh shaders
Add the EnableNative16BitTypes setting for disabling 16-bit float and int support
Change the name of panel key 'LbvhBuildThreshold'
command buffer allocators
Create function CreateCacheId for both compute and graphics pipelines
Create PipelineExtStructs
Enable 3D linear image support without BCn format support
Hooks up EnableRayTracingSupport setting to actually enable/disable raytracing support
Refine rsState initiailziation in BuildRasterizationState
Remove enum ShaderObjectStage in shader object layer
Replace some EXTRACT_VK_STRUCTURES_* macros with HandleExtensionStructs
Set enableColorExportShader to false when enabling linkTimeOptimization
Support single dword address in uber-fetch shader constant buffer
Bump Gpurt Version to 46
Bump LLPC version to 70
Update PAL Version to 856
Fix dEQP-VK.api.Maintenance3_check tests failures
Fix dEQP-VK.pipeline.* reporting 20+ warnings
Fix indirect scheme of pipeline layout when enabling DebugPrintf
Fix Quake 2 RTX performance loss in previous release
Fix segmented lines in some apps
Fix undefined HMI symbol
  • Loading branch information
qiaojbao committed Mar 21, 2024
1 parent a68e7f2 commit b7100c1
Show file tree
Hide file tree
Showing 47 changed files with 1,355 additions and 534 deletions.
6 changes: 3 additions & 3 deletions cmake/XglVersions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ include_guard()
# 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.
set(ICD_PAL_CLIENT_MAJOR_VERSION "846")
set(ICD_PAL_CLIENT_MAJOR_VERSION "856")

# This will become the value of GPUOPEN_CLIENT_INTERFACE_MAJOR_VERSION if ICD_GPUOPEN_DEVMODE_BUILD=1.
# It describes the interface version of the gpuopen shared module (part of PAL) that the ICD supports.
Expand All @@ -37,9 +37,9 @@ set(ICD_GPUOPEN_CLIENT_MAJOR_VERSION "42")
#if VKI_RAY_TRACING
# This will become the value of GPURT_CLIENT_INTERFACE_MAJOR_VERSION if VKI_RAY_TRACING=1.
# It describes the interface version of the GpuRT shared module that the ICD supports.
set(ICD_GPURT_CLIENT_MAJOR_VERSION "43")
set(ICD_GPURT_CLIENT_MAJOR_VERSION "46")
#endif

# This will become the value of LLPC_CLIENT_INTERFACE_MAJOR_VERSION if ICD_BUILD_LLPC=1.
# It describes the version of the interface version of LLPC that the ICD supports.
set(ICD_LLPC_CLIENT_MAJOR_VERSION "69")
set(ICD_LLPC_CLIENT_MAJOR_VERSION "70")
3 changes: 2 additions & 1 deletion icd/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -351,11 +351,12 @@ if (UNIX)
target_link_options(xgl PRIVATE
-Wl,-Bdynamic
-Wl,-z,noexecstack
-Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/make/amdicd.so.def
-Wl,-Map=$<TARGET_FILE_DIR:xgl>/${ICD_TARGET}.map
-Wl,-soname=${ICD_TARGET}.so.1
)

target_link_options(xgl PRIVATE -Wl,--version-script=${CMAKE_CURRENT_SOURCE_DIR}/make/amdicd.so.def)

if(NOT BUILD_SHARED_LIBS)
# Link libstdc++ statically, so that symbols from libstdc++ do not cause conflicts
target_link_options(xgl PRIVATE -static-libgcc -static-libstdc++)
Expand Down
4 changes: 2 additions & 2 deletions icd/Loader/LunarG/Lnx/amd-icd.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
"file_format_version": "1.0.0",
"ICD": {
"library_path": "@AMDVLK_INSTALL_PATH@/amdvlk@[email protected]",
"api_version": "1.3.277"
"api_version": "1.3.279"
},
"layer": {
"name": "VK_LAYER_AMD_switchable_graphics_@ISABITS@",
"type": "GLOBAL",
"library_path": "@AMDVLK_INSTALL_PATH@/amdvlk@[email protected]",
"api_version": "1.3.277",
"api_version": "1.3.279",
"implementation_version": "1",
"description": "AMD switchable graphics layer",
"functions": {
Expand Down
7 changes: 6 additions & 1 deletion icd/api/barrier_policy.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,8 @@ class LayoutUsageHelper
InitEntry(VK_IMAGE_LAYOUT_ATTACHMENT_FEEDBACK_LOOP_OPTIMAL_EXT,
Pal::LayoutShaderRead | Pal::LayoutShaderWrite);

InitEntry(VK_IMAGE_LAYOUT_RENDERING_LOCAL_READ_KHR,
Pal::LayoutShaderRead);
}

// Return layout usage index corresponding to the specified layout.
Expand Down Expand Up @@ -204,6 +206,9 @@ class LayoutUsageHelper
case VK_IMAGE_LAYOUT_ATTACHMENT_FEEDBACK_LOOP_OPTIMAL_EXT:
index = VK_IMAGE_LAYOUT_RANGE_SIZE + 16;
break;
case VK_IMAGE_LAYOUT_RENDERING_LOCAL_READ_KHR:
index = VK_IMAGE_LAYOUT_RANGE_SIZE + 17;
break;
default:
VK_NEVER_CALLED();
break;
Expand Down Expand Up @@ -240,7 +245,7 @@ class LayoutUsageHelper
m_layoutUsageTable[2][usageIndex] = layoutUsage1;
}

enum { LayoutUsageTableSize = VK_IMAGE_LAYOUT_RANGE_SIZE + 17 };
enum { LayoutUsageTableSize = VK_IMAGE_LAYOUT_RANGE_SIZE + 18 };

uint32_t m_layoutUsageTable[MaxPalAspectsPerMask][LayoutUsageTableSize];
};
Expand Down
2 changes: 1 addition & 1 deletion icd/api/cmd_buffer_ring.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ VkResult CmdBufferRing::SubmitCmdBuffer(
palSubmitInfo.ppFences = &pCmdBufState->pFence;
palSubmitInfo.fenceCount = 1;

result = pPalQueue->Submit(palSubmitInfo);
result = Queue::PalQueueSubmit(pDevice, pPalQueue, palSubmitInfo);
}
}

Expand Down
44 changes: 39 additions & 5 deletions icd/api/compiler_solution_llpc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -478,18 +478,53 @@ VkResult CompilerSolutionLlpc::CreateGraphicsShaderBinary(

if (elfReplace == false)
{
const uint32_t gplStageMask = (gplType == GraphicsLibraryPreRaster) ?
PrsShaderMask : FgsShaderMask;
const Vkgc::PipelineShaderInfo* pShadersInfo[ShaderStage::ShaderStageGfxCount] =
{
&pCreateInfo->pipelineInfo.task,
&pCreateInfo->pipelineInfo.vs,
&pCreateInfo->pipelineInfo.tcs,
&pCreateInfo->pipelineInfo.tes,
&pCreateInfo->pipelineInfo.gs,
&pCreateInfo->pipelineInfo.mesh,
&pCreateInfo->pipelineInfo.fs
};
LoadShaderBinaryFromCache(pPipelineCache, &cacheId, &shaderLibraryBinary, &hitCache, &hitAppCache);
if (pPipelineCache != nullptr)
{
// Update the shader feedback
PipelineCreationFeedback* pStageFeedBack = &pCreateInfo->stageFeedback[pModuleState->stage];
pStageFeedBack->feedbackValid = true;
pStageFeedBack->hitApplicationCache = hitAppCache;
for (uint32_t stage = 0; stage < ShaderStage::ShaderStageGfxCount; stage++)
{
if (Util::TestAnyFlagSet(gplStageMask, 1 << stage) &&
((pShadersInfo[stage]->options.clientHash.lower != 0) ||
(pShadersInfo[stage]->options.clientHash.upper != 0)))
{
PipelineCreationFeedback* pStageFeedBack = &pCreateInfo->stageFeedback[stage];
pStageFeedBack->feedbackValid = true;
pStageFeedBack->hitApplicationCache = hitAppCache;
}
}
}

if (hitCache == false)
{
for (uint32_t stage = 0; stage < ShaderStage::ShaderStageGfxCount; stage++)
{
if (Util::TestAnyFlagSet(gplStageMask, 1 << stage) &&
(pShadersInfo[stage]->pModuleData == nullptr) &&
((pShadersInfo[stage]->options.clientHash.lower != 0) ||
(pShadersInfo[stage]->options.clientHash.upper != 0)))
{
result = VK_PIPELINE_COMPILE_REQUIRED_EXT;
break;
}
}
}
}

ShaderLibraryBlobHeader blobHeader = {};
if ((hitCache == false) || elfReplace)
if ((result == VK_SUCCESS) && ((hitCache == false) || elfReplace))
{
// Build the LLPC pipeline
Vkgc::UnlinkedShaderStage unlinkedStage = UnlinkedStageCount;
Expand Down Expand Up @@ -525,7 +560,6 @@ VkResult CompilerSolutionLlpc::CreateGraphicsShaderBinary(
result = (llpcResult == Vkgc::Result::ErrorOutOfMemory) ? VK_ERROR_OUT_OF_HOST_MEMORY :
VK_ERROR_INITIALIZATION_FAILED;
}

}

if (result == VK_SUCCESS)
Expand Down
13 changes: 7 additions & 6 deletions icd/api/devmode/devmode_mgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1167,7 +1167,7 @@ Pal::Result DevModeMgr::TracePendingToPreparingStep(
submitInfo.perSubQueueInfoCount = 1;
submitInfo.fenceCount = 0;

result = pQueue->PalQueue(DefaultDeviceIndex)->Submit(submitInfo);
result = Queue::PalQueueSubmit(pDevice, pQueue->PalQueue(DefaultDeviceIndex), submitInfo);
}
}

Expand Down Expand Up @@ -1268,7 +1268,7 @@ Pal::Result DevModeMgr::TracePreparingToRunningStep(
submitInfo.ppFences = &pState->pBeginFence;
submitInfo.fenceCount = 1;

result = pQueue->PalQueue(DefaultDeviceIndex)->Submit(submitInfo);
result = Queue::PalQueueSubmit(pState->pDevice, pQueue->PalQueue(DefaultDeviceIndex), submitInfo);
}

// Make the trace active and remember which queue started it
Expand Down Expand Up @@ -1312,7 +1312,8 @@ Pal::Result DevModeMgr::TracePreparingToRunningStep(
submitInfo.perSubQueueInfoCount = 1;
submitInfo.fenceCount = 0;

result = pQueueState->pQueue->PalQueue(DefaultDeviceIndex)->Submit(submitInfo);
result = Queue::PalQueueSubmit(
pState->pDevice, pQueueState->pQueue->PalQueue(DefaultDeviceIndex), submitInfo);

break;
}
Expand Down Expand Up @@ -1423,7 +1424,7 @@ Pal::Result DevModeMgr::TraceRunningToWaitingForSqttStep(
submitInfo.ppFences = &pState->pEndSqttFence;
submitInfo.fenceCount = 1;

result = pQueue->PalQueue(DefaultDeviceIndex)->Submit(submitInfo);
result = Queue::PalQueueSubmit(pState->pDevice, pQueue->PalQueue(DefaultDeviceIndex), submitInfo);
}

// Optionally execute a device wait idle if panel says so
Expand Down Expand Up @@ -1540,7 +1541,7 @@ Pal::Result DevModeMgr::TraceWaitingForSqttToEndingStep(
submitInfo.ppFences = &pState->pEndFence;
submitInfo.fenceCount = 1;

result = pQueue->PalQueue(DefaultDeviceIndex)->Submit(submitInfo);
result = Queue::PalQueueSubmit(pState->pDevice, pQueue->PalQueue(DefaultDeviceIndex), submitInfo);
}

if (result == Pal::Result::Success)
Expand Down Expand Up @@ -2448,7 +2449,7 @@ Pal::Result DevModeMgr::TimedQueueSubmit(
// Punt to non-timed submit if a timed submit fails (or is not supported)
if (result != Pal::Result::Success)
{
result = pPalQueue->Submit(submitInfo);
result = Queue::PalQueueSubmit(pQueue->VkDevice(), pPalQueue, submitInfo);
}

if (pApiCmdBufIds != nullptr)
Expand Down
16 changes: 16 additions & 0 deletions icd/api/entry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1805,6 +1805,22 @@ VKAPI_ATTR void VKAPI_CALL vkCmdSetVertexInputEXT(

}

// =====================================================================================================================
VKAPI_ATTR void VKAPI_CALL vkCmdSetRenderingAttachmentLocationsKHR(
VkCommandBuffer commandBuffer,
const VkRenderingAttachmentLocationInfoKHR* pLocationInfo)
{
ApiCmdBuffer::ObjectFromHandle(commandBuffer)->SetRenderingAttachmentLocations(pLocationInfo);
}

// =====================================================================================================================
VKAPI_ATTR void VKAPI_CALL vkCmdSetRenderingInputAttachmentIndicesKHR(
VkCommandBuffer commandBuffer,
const VkRenderingInputAttachmentIndexInfoKHR* pLocationInfo)
{
ApiCmdBuffer::ObjectFromHandle(commandBuffer)->SetRenderingInputAttachmentIndices(pLocationInfo);
}

} // namespace entry

} // namespace vk
Loading

0 comments on commit b7100c1

Please sign in to comment.