mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 07:14:10 +08:00
Add getGpuTimeStampInNS helper
Change-Id: I9170c773d1424ad69523d9a5c3b733299774c194 Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
This commit is contained in:
@@ -85,6 +85,7 @@ class HwHelper {
|
||||
virtual bool is3DPipelineSelectWARequired(const HardwareInfo &hwInfo) const = 0;
|
||||
virtual bool isFusedEuDispatchEnabled(const HardwareInfo &hwInfo) const = 0;
|
||||
virtual bool isIndependentForwardProgressSupported() = 0;
|
||||
virtual uint64_t getGpuTimeStampInNS(uint64_t timeStamp, double frequency) const = 0;
|
||||
|
||||
static uint32_t getSubDevicesCount(const HardwareInfo *pHwInfo);
|
||||
static uint32_t getEnginesCount(const HardwareInfo &hwInfo);
|
||||
@@ -220,6 +221,8 @@ class HwHelperHw : public HwHelper {
|
||||
|
||||
bool isIndependentForwardProgressSupported() override;
|
||||
|
||||
uint64_t getGpuTimeStampInNS(uint64_t timeStamp, double frequency) const override;
|
||||
|
||||
protected:
|
||||
static const AuxTranslationMode defaultAuxTranslationMode;
|
||||
HwHelperHw() = default;
|
||||
|
||||
@@ -70,6 +70,10 @@ template <typename GfxFamily>
|
||||
bool HwHelperHw<GfxFamily>::isIndependentForwardProgressSupported() {
|
||||
return true;
|
||||
}
|
||||
template <typename GfxFamily>
|
||||
uint64_t HwHelperHw<GfxFamily>::getGpuTimeStampInNS(uint64_t timeStamp, double frequency) const {
|
||||
return static_cast<uint64_t>(timeStamp * frequency);
|
||||
}
|
||||
|
||||
template <typename GfxFamily>
|
||||
void MemorySynchronizationCommands<GfxFamily>::addPipeControlWA(LinearStream &commandStream, uint64_t gpuAddress, const HardwareInfo &hwInfo) {
|
||||
|
||||
Reference in New Issue
Block a user