Pass hwInfo to appendMiFlushDw

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
Filip Hazubski
2021-12-21 18:13:53 +00:00
committed by Compute-Runtime-Automation
parent 15f102a7cb
commit 9a450d1b74
24 changed files with 103 additions and 73 deletions

View File

@@ -25,7 +25,7 @@ class BlitterDispatcher : public Dispatcher<GfxFamily> {
static size_t getSizeMonitorFence(const HardwareInfo &hwInfo);
static void dispatchCacheFlush(LinearStream &cmdBuffer, const HardwareInfo &hwInfo, uint64_t address);
static void dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address);
static void dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address, const HardwareInfo &hwInfo);
static size_t getSizeCacheFlush(const HardwareInfo &hwInfo);
static size_t getSizeTlbFlush();
static bool isMultiTileSynchronizationSupported() {

View File

@@ -32,7 +32,7 @@ inline void BlitterDispatcher<GfxFamily>::dispatchMonitorFence(LinearStream &cmd
MiFlushArgs args;
args.commandWithPostSync = true;
args.notifyEnable = useNotifyEnable;
EncodeMiFlushDW<GfxFamily>::programMiFlushDw(cmdBuffer, gpuAddress, immediateData, args);
EncodeMiFlushDW<GfxFamily>::programMiFlushDw(cmdBuffer, gpuAddress, immediateData, args, hwInfo);
}
template <typename GfxFamily>
@@ -43,15 +43,15 @@ inline size_t BlitterDispatcher<GfxFamily>::getSizeMonitorFence(const HardwareIn
template <typename GfxFamily>
inline void BlitterDispatcher<GfxFamily>::dispatchCacheFlush(LinearStream &cmdBuffer, const HardwareInfo &hwInfo, uint64_t address) {
dispatchTlbFlush(cmdBuffer, address);
dispatchTlbFlush(cmdBuffer, address, hwInfo);
}
template <typename GfxFamily>
inline void BlitterDispatcher<GfxFamily>::dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address) {
inline void BlitterDispatcher<GfxFamily>::dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address, const HardwareInfo &hwInfo) {
MiFlushArgs args;
args.tlbFlush = true;
args.commandWithPostSync = true;
EncodeMiFlushDW<GfxFamily>::programMiFlushDw(cmdBuffer, address, 0ull, args);
EncodeMiFlushDW<GfxFamily>::programMiFlushDw(cmdBuffer, address, 0ull, args, hwInfo);
}
template <typename GfxFamily>

View File

@@ -25,7 +25,7 @@ class RenderDispatcher : public Dispatcher<GfxFamily> {
static size_t getSizeMonitorFence(const HardwareInfo &hwInfo);
static void dispatchCacheFlush(LinearStream &cmdBuffer, const HardwareInfo &hwInfo, uint64_t address);
static void dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address);
static void dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address, const HardwareInfo &hwInfo);
static size_t getSizeCacheFlush(const HardwareInfo &hwInfo);
static size_t getSizeTlbFlush();
static bool isMultiTileSynchronizationSupported() {

View File

@@ -57,7 +57,7 @@ inline void RenderDispatcher<GfxFamily>::dispatchCacheFlush(LinearStream &cmdBuf
}
template <typename GfxFamily>
inline void RenderDispatcher<GfxFamily>::dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address) {
inline void RenderDispatcher<GfxFamily>::dispatchTlbFlush(LinearStream &cmdBuffer, uint64_t address, const HardwareInfo &hwInfo) {
PipeControlArgs args;
args.tlbInvalidation = true;
args.pipeControlFlushEnable = true;

View File

@@ -123,7 +123,7 @@ bool DrmDirectSubmission<GfxFamily, Dispatcher>::isNewResourceHandleNeeded() {
template <typename GfxFamily, typename Dispatcher>
void DrmDirectSubmission<GfxFamily, Dispatcher>::handleNewResourcesSubmission() {
if (isNewResourceHandleNeeded()) {
Dispatcher::dispatchTlbFlush(this->ringCommandStream, this->gpuVaForMiFlush);
Dispatcher::dispatchTlbFlush(this->ringCommandStream, this->gpuVaForMiFlush, *this->hwInfo);
}
auto osContextLinux = static_cast<OsContextLinux *>(&this->osContext);