Skip to contentSkip to conversation

Video memory reported by GLX_MESA_query_renderer differs between amdgpu and radeon

DISCUSSION Kai Wasserbäch 3 participants 6 messages Dec 9, 2016 – Dec 11, 2016 5 messages not in the archive

lore
Share & tools
lore
#0 lore raw

[Please CC me on all replies, I'm not subscribed to this list.]

Hey,
I've been noticing that GLX_MESA_query_renderer reports less video memory when I use amdgpu for my Hawaii PRO GPU, than when I use radeon. Since I'm pretty happy with amdgpu (as I do not use HDMI audio) and it's the code, that gets active improvements, I'd like to stay with it, but having 40 MB of video memory "vanish" is not nice.
With radeon GLX_MESA_query_renderer reports 4096 MB RAM (as expected, the R9 290 was sold/advertised with that), while I'm seeing 4056 MB with amdgpu (last tested kernel: 4.8.13).

As I'm not sure, whether this is a bug or rather some always reserved memory area, which gets subtracted before reporting the available memory, I didn't file a bug report and rather am writing this e-mail. If it's a bug I'm happy to file the report against amdgpu.

Cheers,
Kai

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): dfe0d8dd-81fb-8703-61c8-e1a17ba7c9c4-1ZKVMVCtJ2dx9oSEVPI0kiST3g8Odh+X@public.gmane.org

#2 lore raw
Quoted 12 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Hey,
I've been noticing that GLX_MESA_query_renderer reports less video memory when I use amdgpu for my Hawaii PRO GPU, than when I use radeon. Since I'm pretty happy with amdgpu (as I do not use HDMI audio) and it's the code, that gets active improvements, I'd like to stay with it, but having 40 MB of video memory "vanish" is not nice.
With radeon GLX_MESA_query_renderer reports 4096 MB RAM (as expected, the R9 290 was sold/advertised with that), while I'm seeing 4056 MB with amdgpu (last tested kernel: 4.8.13).

Quoted 4 lines

As I'm not sure, whether this is a bug or rather some always reserved memory area, which gets subtracted before reporting the available memory, I didn't file a bug report and rather am writing this e-mail. If it's a bug I'm happy to file the report against amdgpu.

IIRC, the driver interfaces used to get the information exposed via that extension are slightly different. radeon exposes the total amount of vram while amdgpu reports the total amount of free vram. The actual amount of free vram is probably pretty close.

Alex
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): CADnq5_MTiL3GhPMWU8pjFxLaj+2xFtbT9+_vL6zkLhswQgDTnQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org

#4 lore raw

[Please CC me on all replies, I'm not subscribed to this list.]

Dear Alex,
Alex Deucher wrote on 10.12.2016 22:40:

Quoted 19 lines
Quoted 12 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Hey,
I've been noticing that GLX_MESA_query_renderer reports less video memory when I use amdgpu for my Hawaii PRO GPU, than when I use radeon. Since I'm pretty happy with amdgpu (as I do not use HDMI audio) and it's the code, that gets active improvements, I'd like to stay with it, but having 40 MB of video memory "vanish" is not nice.
With radeon GLX_MESA_query_renderer reports 4096 MB RAM (as expected, the R9 290 was sold/advertised with that), while I'm seeing 4056 MB with amdgpu (last tested kernel: 4.8.13).

Quoted 4 lines

As I'm not sure, whether this is a bug or rather some always reserved memory area, which gets subtracted before reporting the available memory, I didn't file a bug report and rather am writing this e-mail. If it's a bug I'm happy to file the report against amdgpu.

Quoted 4 lines

IIRC, the driver interfaces used to get the information exposed via that extension are slightly different. radeon exposes the total amount of vram while amdgpu reports the total amount of free vram. The actual amount of free vram is probably pretty close.

thanks for the explanation!

But I'd like to point out that some of the automatic configuration tools shipped with games (and probably other programs) are deciding upon the reported values to which quality level they should default. Maybe reporting the theoretical VRAM might be better (you could always report the actual values through sysfs or some other channel)?

Cheers,
Kai

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 559285e9-390b-9a09-6a31-ab8163a79dd9-1ZKVMVCtJ2dx9oSEVPI0kiST3g8Odh+X@public.gmane.org

#6 lore raw
Quoted 28 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Dear Alex,
Alex Deucher wrote on 10.12.2016 22:40:

Quoted 19 lines
Quoted 12 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Hey,
I've been noticing that GLX_MESA_query_renderer reports less video memory when I use amdgpu for my Hawaii PRO GPU, than when I use radeon. Since I'm pretty happy with amdgpu (as I do not use HDMI audio) and it's the code, that gets active improvements, I'd like to stay with it, but having 40 MB of video memory "vanish" is not nice.
With radeon GLX_MESA_query_renderer reports 4096 MB RAM (as expected, the R9 290 was sold/advertised with that), while I'm seeing 4056 MB with amdgpu (last tested kernel: 4.8.13).

Quoted 4 lines

As I'm not sure, whether this is a bug or rather some always reserved memory area, which gets subtracted before reporting the available memory, I didn't file a bug report and rather am writing this e-mail. If it's a bug I'm happy to file the report against amdgpu.

Quoted 4 lines

IIRC, the driver interfaces used to get the information exposed via that extension are slightly different. radeon exposes the total amount of vram while amdgpu reports the total amount of free vram. The actual amount of free vram is probably pretty close.

Quoted 7 lines

thanks for the explanation!

But I'd like to point out that some of the automatic configuration tools shipped with games (and probably other programs) are deciding upon the reported values to which quality level they should default. Maybe reporting the theoretical VRAM might be better (you could always report the actual values through sysfs or some other channel)?

I think all of the relevant info is available already, we'd just need to update mesa to make both drivers report something consistent. The extension isn't clear on whether it should be free memory or total memory. The extension says:

GLX_RENDERER_VIDEO_MEMORY_MESA 1 Number of megabytes of video
memory available to the renderer

That sort of implies free memory, but I guess most apps probably care more about the overall memory size.

Alex
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): CADnq5_O=S8Rp0Rk=j2UDtwGSK5Wv=Mi6PkFSV1gfFyDhti97Vw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org

#8 lore raw

Alex Deucher wrote on 10.12.2016 23:03:

Quoted 38 lines
Quoted 28 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Dear Alex,
Alex Deucher wrote on 10.12.2016 22:40:

Quoted 19 lines
Quoted 12 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Hey,
I've been noticing that GLX_MESA_query_renderer reports less video memory when I use amdgpu for my Hawaii PRO GPU, than when I use radeon. Since I'm pretty happy with amdgpu (as I do not use HDMI audio) and it's the code, that gets active improvements, I'd like to stay with it, but having 40 MB of video memory "vanish" is not nice.
With radeon GLX_MESA_query_renderer reports 4096 MB RAM (as expected, the R9 290 was sold/advertised with that), while I'm seeing 4056 MB with amdgpu (last tested kernel: 4.8.13).

Quoted 4 lines

As I'm not sure, whether this is a bug or rather some always reserved memory area, which gets subtracted before reporting the available memory, I didn't file a bug report and rather am writing this e-mail. If it's a bug I'm happy to file the report against amdgpu.

Quoted 4 lines

IIRC, the driver interfaces used to get the information exposed via that extension are slightly different. radeon exposes the total amount of vram while amdgpu reports the total amount of free vram. The actual amount of free vram is probably pretty close.

Quoted 7 lines

thanks for the explanation!

But I'd like to point out that some of the automatic configuration tools shipped with games (and probably other programs) are deciding upon the reported values to which quality level they should default. Maybe reporting the theoretical VRAM might be better (you could always report the actual values through sysfs or some other channel)?

Quoted 7 lines

I think all of the relevant info is available already, we'd just need to update mesa to make both drivers report something consistent. The extension isn't clear on whether it should be free memory or total memory. The extension says:

GLX_RENDERER_VIDEO_MEMORY_MESA 1 Number of megabytes of video
memory available to the renderer

I agree, that the language of the spec isn't explicit in what should be reported.

Quoted 2 lines

That sort of implies free memory, but I guess most apps probably care more about the overall memory size.

From what I've seen, that seems the case (no matter through which extension this value is queried). It seems like this is how it's handled on Windows: if you have 4 GB of VRAM, we default to high level textures, if you have 8 GB, we default to ultra, etc.

Cheers,
Kai

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 28572378-d439-dcb6-5df6-f7d5f53d2798-1ZKVMVCtJ2dx9oSEVPI0kiST3g8Odh+X@public.gmane.org

#10 lore raw

I think that pinned VRAM memory (memory that's reserved for kernel use only) is subtracted from the total VRAM size.

amdgpu DRM 3.9.0 has a new query that returns both the total physical and total usable VRAM, but Mesa doesn't use it.

Marek

Quoted 57 lines · Kai Wasserbäch

Alex Deucher wrote on 10.12.2016 23:03:

Quoted 38 lines
Quoted 28 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Dear Alex,
Alex Deucher wrote on 10.12.2016 22:40:

Quoted 19 lines
Quoted 12 lines · Kai Wasserbäch

[Please CC me on all replies, I'm not subscribed to this list.]

Hey,
I've been noticing that GLX_MESA_query_renderer reports less video memory when I use amdgpu for my Hawaii PRO GPU, than when I use radeon. Since I'm pretty happy with amdgpu (as I do not use HDMI audio) and it's the code, that gets active improvements, I'd like to stay with it, but having 40 MB of video memory "vanish" is not nice.
With radeon GLX_MESA_query_renderer reports 4096 MB RAM (as expected, the R9 290 was sold/advertised with that), while I'm seeing 4056 MB with amdgpu (last tested kernel: 4.8.13).

Quoted 4 lines

As I'm not sure, whether this is a bug or rather some always reserved memory area, which gets subtracted before reporting the available memory, I didn't file a bug report and rather am writing this e-mail. If it's a bug I'm happy to file the report against amdgpu.

Quoted 4 lines

IIRC, the driver interfaces used to get the information exposed via that extension are slightly different. radeon exposes the total amount of vram while amdgpu reports the total amount of free vram. The actual amount of free vram is probably pretty close.

Quoted 7 lines

thanks for the explanation!

But I'd like to point out that some of the automatic configuration tools shipped with games (and probably other programs) are deciding upon the reported values to which quality level they should default. Maybe reporting the theoretical VRAM might be better (you could always report the actual values through sysfs or some other channel)?

Quoted 7 lines

I think all of the relevant info is available already, we'd just need to update mesa to make both drivers report something consistent. The extension isn't clear on whether it should be free memory or total memory. The extension says:

GLX_RENDERER_VIDEO_MEMORY_MESA 1 Number of megabytes of video
memory available to the renderer

I agree, that the language of the spec isn't explicit in what should be reported.

Quoted 2 lines

That sort of implies free memory, but I guess most apps probably care more about the overall memory size.

From what I've seen, that seems the case (no matter through which extension this value is queried). It seems like this is how it's handled on Windows: if you have 4 GB of VRAM, we default to high level textures, if you have 8 GB, we default to ultra, etc.

Quoted 9 lines

Cheers,
Kai

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx