mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 07:14:10 +08:00
Add MI_FLUSH_DW command estimation
Change-Id: I71d966209ce1a9996bfe3f48f3d8da00156211a3 Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
a748d7ccf5
commit
24c6a1ed96
@@ -5,6 +5,7 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/source/command_container/command_encoder.h"
|
||||
#include "shared/source/helpers/blit_commands_helper.h"
|
||||
#include "shared/source/helpers/hw_helper.h"
|
||||
#include "shared/source/helpers/timestamp_packet.h"
|
||||
@@ -34,7 +35,7 @@ size_t BlitCommandsHelper<GfxFamily>::estimateBlitCommandsSize(uint64_t copySize
|
||||
|
||||
return TimestampPacketHelper::getRequiredCmdStreamSize<GfxFamily>(csrDependencies) +
|
||||
(sizeof(typename GfxFamily::XY_COPY_BLT) * numberOfBlits) +
|
||||
(sizeof(typename GfxFamily::MI_FLUSH_DW) * static_cast<size_t>(updateTimestampPacket));
|
||||
(EncodeMiFlushDW<GfxFamily>::getMiFlushDwCmdSizeForDataWrite() * static_cast<size_t>(updateTimestampPacket));
|
||||
}
|
||||
|
||||
template <typename GfxFamily>
|
||||
@@ -45,7 +46,7 @@ size_t BlitCommandsHelper<GfxFamily>::estimateBlitCommandsSize(const BlitPropert
|
||||
blitProperties.outputTimestampPacket != nullptr);
|
||||
}
|
||||
size += MemorySynchronizationCommands<GfxFamily>::getSizeForAdditonalSynchronization(hwInfo);
|
||||
size += sizeof(typename GfxFamily::MI_FLUSH_DW) + sizeof(typename GfxFamily::MI_BATCH_BUFFER_END);
|
||||
size += EncodeMiFlushDW<GfxFamily>::getMiFlushDwCmdSizeForDataWrite() + sizeof(typename GfxFamily::MI_BATCH_BUFFER_END);
|
||||
|
||||
return alignUp(size, MemoryConstants::cacheLineSize);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user