mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
fix: pass additional adapter info caps to gmmlib for wddm windows
Related-To: HSD-18041684792 Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
48917f14cc
commit
72e1ec3b42
@@ -183,6 +183,8 @@ struct ADAPTER_INFO_KMD : ADAPTER_INFO_GMM { // NOLINT(readability-identifier-na
|
||||
GMM_GFX_PARTITIONING GfxPartition; // NOLINT(readability-identifier-naming)
|
||||
ADAPTER_BDF stAdapterBDF;
|
||||
PLATFORM_KMD GfxPlatform; // NOLINT(readability-identifier-naming)
|
||||
uint64_t LMemBarSize; // NOLINT(readability-identifier-naming)
|
||||
uint8_t SegmentId[3]; // NOLINT(readability-identifier-naming)
|
||||
};
|
||||
|
||||
static constexpr COMMAND_BUFFER_HEADER initCommandBufferHeader(uint32_t umdContextType, uint32_t umdPatchList, uint32_t usesResourceStreamer, uint32_t perfTag) {
|
||||
|
||||
@@ -46,6 +46,9 @@ bool Wddm::configureDeviceAddressSpace() {
|
||||
GMM_DEVICE_INFO deviceInfo{};
|
||||
deviceInfo.pGfxPartition = &gfxPartition;
|
||||
deviceInfo.pDeviceCb = &deviceCallbacks;
|
||||
memcpy_s(deviceInfo.MsSegId, sizeof(deviceInfo.MsSegId), segmentId, sizeof(segmentId));
|
||||
deviceInfo.AdapterLocalMemory = dedicatedVideoMemory;
|
||||
deviceInfo.AdapterCpuVisibleLocalMemory = lmemBarSize;
|
||||
if (!gmmMemory->setDeviceInfo(&deviceInfo)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -306,11 +306,13 @@ bool Wddm::queryAdapterInfo() {
|
||||
|
||||
memcpy_s(&gfxPartition, sizeof(gfxPartition), &adapterInfo.GfxPartition, sizeof(GMM_GFX_PARTITIONING));
|
||||
memcpy_s(&adapterBDF, sizeof(adapterBDF), &adapterInfo.stAdapterBDF, sizeof(ADAPTER_BDF));
|
||||
memcpy_s(segmentId, sizeof(segmentId), adapterInfo.SegmentId, sizeof(adapterInfo.SegmentId));
|
||||
|
||||
deviceRegistryPath = std::string(adapterInfo.DeviceRegistryPath, sizeof(adapterInfo.DeviceRegistryPath)).c_str();
|
||||
|
||||
systemSharedMemory = adapterInfo.SystemSharedMemory;
|
||||
dedicatedVideoMemory = adapterInfo.DedicatedVideoMemory;
|
||||
lmemBarSize = adapterInfo.LMemBarSize;
|
||||
maxRenderFrequency = adapterInfo.MaxRenderFreq;
|
||||
timestampFrequency = adapterInfo.GfxTimeStampFreq;
|
||||
instrumentationEnabled = adapterInfo.Caps.InstrumentationIsEnabled != 0;
|
||||
|
||||
@@ -271,6 +271,7 @@ class Wddm : public DriverModel {
|
||||
|
||||
uint64_t systemSharedMemory = 0;
|
||||
uint64_t dedicatedVideoMemory = 0;
|
||||
uint64_t lmemBarSize = 0;
|
||||
|
||||
// Adapter information
|
||||
std::unique_ptr<PLATFORM_KMD> gfxPlatform;
|
||||
@@ -309,6 +310,8 @@ class Wddm : public DriverModel {
|
||||
uint32_t additionalAdapterInfoOptions = 0u;
|
||||
int32_t forceEvictOnlyIfNecessary = -1;
|
||||
|
||||
uint8_t segmentId[3]{};
|
||||
|
||||
unsigned int enablePreemptionRegValue = 1;
|
||||
|
||||
bool platformSupportsEvictIfNecessary = false;
|
||||
|
||||
Reference in New Issue
Block a user