OpenVINO™ is an open source toolkit for optimizing and deploying AI inference
C++ aicomputer-visiondeep-learningdeploy-aidiffusion-modelsgenerative-aigood-first-issueinferencellm-inferencenatural-language-processingnlpopenvinooptimize-aiperformance-boostrecommendation-systemspeech-recognitionstable-diffusiontransformersyolo
[intel-npu] max memalloc quickfix for grext 1.8 windows drivers (#27317)
Attila Csok70e214de0ba0
diff --git a/src/plugins/intel_npu/src/backend/src/zero_device.cpp b/src/plugins/intel_npu/src/backend/src/zero_device.cppindex 439b5fbd59f..58bcd0eb7cc 100644--- a/src/plugins/intel_npu/src/backend/src/zero_device.cpp+++ b/src/plugins/intel_npu/src/backend/src/zero_device.cpp@@ -175,6 +175,14 @@ uint64_t ZeroDevice::getTotalMemSize() const {// we are safe here, can return the value directly from driverreturn query.total;}+#if defined(_WIN32) || defined(__CYGWIN__)+ // Special case for windows drivers with graph_extension v 1.8+ if (_initStructs->isExtensionSupported(std::string("ZE_extension_graph_1_8"), ZE_MAKE_VERSION(1, 8))) {+ // query here returns total system memory in KB, which we need to+ // divide by 2 (OS limitation) and convert to bytes+ return (query.total << 9);+ }+#endif// Default for older drivers: return 2GBreturn LEGACY_MAX_MEM_ALLOC_SIZE_BYTES;