Skip to content

Commit

Permalink
[VP] Remove Compute/Render GPU context creation in PipeSM
Browse files Browse the repository at this point in the history
KMD changed some logic in PipeSM  Render/Conpute GPU context creation, and media component needs to remove the creation call when there is no GT IP.
  • Loading branch information
LhGu authored and intel-mediadev committed Jan 3, 2025
1 parent 48bc50e commit 7d929f6
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions media_softlet/agnostic/common/vp/hal/pipeline/vp_pipeline.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -417,13 +417,15 @@ MOS_STATUS VpPipeline::Init(void *mhwInterface)
VP_PUBLIC_CHK_STATUS_RETURN(PacketPipe::SwitchContext(VP_PIPELINE_PACKET_VEBOX, m_scalability,
m_mediaContext, MOS_VE_SUPPORTED(m_osInterface), m_numVebox));
}

bool computeContextEnabled = m_userFeatureControl->IsComputeContextEnabled();
auto packetId = computeContextEnabled ? VP_PIPELINE_PACKET_COMPUTE : VP_PIPELINE_PACKET_RENDER;
VP_PUBLIC_NORMALMESSAGE("Create GpuContext for Compute/Render (PacketId: %d).", packetId);
VP_PUBLIC_CHK_STATUS_RETURN(PacketPipe::SwitchContext(packetId, m_scalability,
m_mediaContext, MOS_VE_SUPPORTED(m_osInterface), m_numVebox));

// If the environment is SA media in which there are no GT IP, we could not create/use Render or Compute GPU context.
if (!(m_skuTable && MEDIA_IS_SKU(m_skuTable, FtrDisableGtIpSubmissions)))
{
bool computeContextEnabled = m_userFeatureControl->IsComputeContextEnabled();
auto packetId = computeContextEnabled ? VP_PIPELINE_PACKET_COMPUTE : VP_PIPELINE_PACKET_RENDER;
VP_PUBLIC_NORMALMESSAGE("Create GpuContext for Compute/Render (PacketId: %d).", packetId);
VP_PUBLIC_CHK_STATUS_RETURN(PacketPipe::SwitchContext(packetId, m_scalability,
m_mediaContext, MOS_VE_SUPPORTED(m_osInterface), m_numVebox));
}
// create SinglePipe GpuContext for multi Vebox system to avoid first frame long latency issue
if (m_numVebox > 1 && !(m_vpSettings && m_vpSettings->clearVideoViewMode))
{
Expand Down

0 comments on commit 7d929f6

Please sign in to comment.