Software Tuning, Performance Optimization & Platform Monitoring
Discussion regarding monitoring and software tuning methodologies, Performance Monitoring Unit (PMU) of Intel microprocessors, and platform updating.

How to get GPU memory usage.

Artur_M_
Beginner
1,295 Views

Hi,

Setup Info:
CPU: i7 4770K
OS: Windows 10
GPU: Intel HD 4600

I have been directed here to as question regardig Intel® Metrics Framework (MF) and Intel® Platform Analysis Library (PAL).

I have a service that needs to retrieve the intel GPU memory and usage numbers. In the MF we have found the property "com.intel.gpu.gpu_busy" but there seems not to be an equivalent for the memory. So here are my questions:

1 - Do i have to have the GM_Server component running on the system to be able to read the counters? Or can i obtain the numbers without external process.
2 - I have found the "com.intel.gpu.gpu_busy" property that gives the GPU usage, however i must run in Admin context before the numbers are correct. is this a must?
3 - I can not find any property that can give me the GPU memory usage number, is it possible to have this metric as well?
4 - If the memory usage is possible to get, is it possible to get the usage pr process or is it only system wide?

Thank you,

BR,

Artur.

0 Kudos
5 Replies
Artur_M_
Beginner
1,295 Views

Hi,

 

Is there any news on this topic?

Br,

Artur

0 Kudos
Wei_W_Intel
Employee
1,295 Views

Hi, Arthur

thank you for contacting us on Metrics Framework of Intel PAL library, answer to your questions:

1 - Do I have to have the GM_Server component running on the system to be able to read the counters? Or can i obtain the numbers without external process.

 

Metrics can be obtained locally without running GM_Server by creating a consumer (or embedding one in an existing app) that loads the appropriate publisher and subscribes to the desired metrics. 


2 - I have found the "com.intel.gpu.gpu_busy" property that gives the GPU usage, however i must run in Admin context before the numbers are correct. is this a must?

Admin right should not be required. In GPA we run System View (which uses GfxDrvSampledPublisher) in non-admin mode.


3 - I cannot find any property that can give me the GPU memory usage number, is it possible to have this metric as well?

 

% of GPU memory usage is not available, though memory GPU read/write bandwidth are here:  GtiReadThroughput,  GtiWriteThroughput.


4 - If the memory usage is possible to get, is it possible to get the usage process or is it only system wide?

GfxDrvSampledPublisher provides system wide metrics. GfxDrvInProcPublisher could provide per process metrics but it required target process instrumentation.

 

Please contact us if you have more questions.

Thank you!

-Wei

 

 

 

 

0 Kudos
Artur_M_
Beginner
1,295 Views

Hello Wei,

Sorry for late reply .. had some technical issues :D.

Thank you for the replies, very useful. 

However can you elaborate a bit more on:

"% of GPU memory usage is not available, though memory GPU read/write bandwidth are here:  GtiReadThroughput,  GtiWriteThroughput."

Isn't this the current usage, meaning this second. and if so, assuming that we decode a constant amount this may be useful. However is there any way to find what is the total possible memory usage. And especially taking the CPU model and OS into consideration as for example Windows 10 allows GPU to use system memory (up to ½ of total). So even if i detect the throughput is 20 i still lack the 20 out of what. Hope i explained it well :)

 

BR,

Artur.

0 Kudos
STANISLAV_V_Intel
1,295 Views

Hi Artur,

Unfortunately there is no way to get number for peak throughput to calculate % of bandwidth usage.

- Stas.

0 Kudos
Artur_M_
Beginner
1,295 Views

Hi Stanislav,

Thank you for the info. I hope you will add this functionality to MediaSDK/PAL as this is very needed thing i believe :),

BR,

Artur.

0 Kudos
Reply