summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowwin32.cpp
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2025-05-29 11:54:56 +0800
committerErik Kundiman <erik@megapahit.org>2025-05-29 11:54:56 +0800
commit11d75418fce8372e9976b069070d9d0506766d0d (patch)
treed0fc6b405dbcffefcd85f3ba52a8248c0128acde /indra/llwindow/llwindowwin32.cpp
parentb6c3d47c007c59cbd3c9913a0b99f9d42bdb8d75 (diff)
parent0421e7b846b03d316740d759348c3aaa723d0b14 (diff)
Merge branch '2025.04'
Diffstat (limited to 'indra/llwindow/llwindowwin32.cpp')
-rw-r--r--indra/llwindow/llwindowwin32.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/indra/llwindow/llwindowwin32.cpp b/indra/llwindow/llwindowwin32.cpp
index 730e658c6a..a781e638ee 100644
--- a/indra/llwindow/llwindowwin32.cpp
+++ b/indra/llwindow/llwindowwin32.cpp
@@ -4681,9 +4681,18 @@ void LLWindowWin32::LLWindowWin32Thread::checkDXMem()
if (phys_mb > 0)
{
- // Intel uses 'shared' vram, cap it to 25% of total memory
- // Todo: consider caping all adapters at least to 50% ram
- budget_mb = llmin(budget_mb, (UINT64)(phys_mb * 0.25));
+ if (gGLManager.mIsIntel)
+ {
+ // Intel uses 'shared' vram, cap it to 25% of total memory
+ // Todo: consider a way of detecting integrated Intel and AMD
+ budget_mb = llmin(budget_mb, (UINT64)(phys_mb * 0.25));
+ }
+ else
+ {
+ // More budget is generally better, but the way viewer
+ // utilizes even dedicated VRAM leaves a footprint in RAM
+ budget_mb = llmin(budget_mb, (UINT64)(phys_mb * 0.75));
+ }
}
else
{