SWDEV-300515 - Apply CU granularity on the CU count
Report granularity for possible app query
Change-Id: I98857c6f4cc7ae590927ea35ce57d181abe7860b
[ROCm/clr commit: f613831471]
This commit is contained in:
committed by
Saleel Kudchadker
parent
aac7266191
commit
c759986e28
@@ -521,6 +521,8 @@ struct Info : public amd::EmbeddedObject {
|
||||
uint32_t numRTQueues_;
|
||||
//! Number of available real time compute units
|
||||
uint32_t numRTCUs_;
|
||||
//! The granularity at which compute units can be dedicated to a queue
|
||||
uint32_t granularityRTCUs_;
|
||||
//! Thread trace enable
|
||||
uint32_t threadTraceEnable_;
|
||||
|
||||
|
||||
@@ -596,7 +596,10 @@ void NullDevice::fillDeviceInfo(const Pal::DeviceProperties& palProp,
|
||||
info_.numAsyncQueues_ = numComputeRings;
|
||||
|
||||
info_.numRTQueues_ = numExclusiveComputeRings;
|
||||
info_.numRTCUs_ = palProp.engineProperties[Pal::EngineTypeCompute].maxNumDedicatedCu;
|
||||
|
||||
const auto& engineProp = palProp.engineProperties[Pal::EngineTypeCompute];
|
||||
info_.numRTCUs_ = engineProp.maxNumDedicatedCu;
|
||||
info_.granularityRTCUs_ = engineProp.dedicatedCuGranularity;
|
||||
|
||||
info_.threadTraceEnable_ = settings().threadTraceEnable_;
|
||||
|
||||
|
||||
@@ -87,7 +87,8 @@ VirtualGPU::Queue* VirtualGPU::Queue::Create(const VirtualGPU& gpu, Pal::QueueTy
|
||||
cmdCreateInfo.engineType = qCreateInfo.engineType = Pal::EngineTypeCompute;
|
||||
qCreateInfo.priority = Pal::QueuePriority::Medium;
|
||||
} else if (amd::CommandQueue::RealTimeDisabled != rtCU) {
|
||||
qCreateInfo.numReservedCu = rtCU;
|
||||
qCreateInfo.numReservedCu = amd::alignDown(rtCU,
|
||||
gpu.dev().properties().engineProperties[Pal::EngineTypeCompute].dedicatedCuGranularity);
|
||||
if ((priority == amd::CommandQueue::Priority::Medium) &&
|
||||
// If Windows HWS is enabled, then the both real time queues are allocated
|
||||
// on the same engine
|
||||
|
||||
Reference in New Issue
Block a user