From: "Thomas Hellström" <thomas.hellstrom@linux.intel.com>
To: intel-xe@lists.freedesktop.org
Cc: "Thomas Hellström" <thomas.hellstrom@linux.intel.com>,
"Matthew Brost" <matthew.brost@intel.com>,
"Somalapuram Amaranath" <Amaranath.Somalapuram@amd.com>,
"Christian König" <christian.koenig@amd.com>,
"Paulo Zanoni" <paulo.r.zanoni@intel.com>,
"Simona Vetter" <simona.vetter@ffwll.ch>,
dri-devel@lists.freedesktop.org
Subject: [PATCH v14 8/8] drm/xe: Increase the XE_PL_TT watermark
Date: Fri, 15 Nov 2024 16:01:20 +0100 [thread overview]
Message-ID: <20241115150120.3280-9-thomas.hellstrom@linux.intel.com> (raw)
In-Reply-To: <20241115150120.3280-1-thomas.hellstrom@linux.intel.com>
The XE_PL_TT watermark was set to 50% of system memory.
The idea behind that was unclear since the net effect is that
TT memory will be evicted to TTM_PL_SYSTEM memory if that
watermark is exceeded, requiring PPGTT rebinds and dma
remapping. But there is no similar watermark for TTM_PL_1SYSTEM
memory.
The TTM functionality that tries to swap out system memory to
shmem objects if a 50% limit of total system memory is reached
is orthogonal to this, and with the shrinker added, it's no
longer in effect.
Replace the 50% TTM_PL_TT limit with a 100% limit, in effect
allowing all graphics memory to be bound to the device unless it
has been swapped out by the shrinker.
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
---
drivers/gpu/drm/xe/xe_ttm_sys_mgr.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/xe/xe_ttm_sys_mgr.c b/drivers/gpu/drm/xe/xe_ttm_sys_mgr.c
index 9844a8edbfe1..d38b91872da3 100644
--- a/drivers/gpu/drm/xe/xe_ttm_sys_mgr.c
+++ b/drivers/gpu/drm/xe/xe_ttm_sys_mgr.c
@@ -108,9 +108,8 @@ int xe_ttm_sys_mgr_init(struct xe_device *xe)
u64 gtt_size;
si_meminfo(&si);
+ /* Potentially restrict amount of TT memory here. */
gtt_size = (u64)si.totalram * si.mem_unit;
- /* TTM limits allocation of all TTM devices by 50% of system memory */
- gtt_size /= 2;
man->use_tt = true;
man->func = &xe_ttm_sys_mgr_func;
--
2.46.2
next prev parent reply other threads:[~2024-11-15 15:01 UTC|newest]
Thread overview: 54+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-15 15:01 [PATCH v14 0/8] TTM shrinker helpers and xe buffer object shrinker Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 1/8] drm/ttm: Balance ttm_resource_cursor_init() and ttm_resource_cursor_fini() Thomas Hellström
2024-11-20 10:51 ` Christian König
2024-11-21 15:54 ` Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 2/8] drm/ttm: Provide a shmem backup implementation Thomas Hellström
2024-11-19 13:40 ` Christian König
2024-11-20 7:58 ` Thomas Hellström
2024-11-20 9:24 ` Christian König
2024-11-20 10:34 ` Thomas Hellström
2024-11-20 10:50 ` Christian König
2024-11-20 11:07 ` Thomas Hellström
2024-11-20 11:20 ` Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 3/8] drm/ttm/pool: Provide a helper to shrink pages Thomas Hellström
2024-12-03 13:12 ` Christian König
2024-12-03 13:42 ` Thomas Hellström
2024-12-03 14:51 ` Christian König
2024-12-03 15:50 ` Thomas Hellström
2024-12-03 16:20 ` Christian König
2024-12-03 16:31 ` Thomas Hellström
2024-12-03 16:39 ` Christian König
2024-12-03 16:43 ` Thomas Hellström
2024-12-03 16:46 ` Christian König
2024-12-03 17:44 ` Thomas Hellström
2024-12-04 9:16 ` Christian König
2024-12-04 9:56 ` Thomas Hellström
2024-12-04 10:56 ` Christian König
2024-12-04 11:09 ` Thomas Hellström
2024-12-04 11:24 ` Christian König
2024-12-04 12:24 ` Thomas Hellström
2024-12-18 10:07 ` Thomas Hellström
2024-12-18 10:15 ` Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 4/8] drm/ttm: Use fault-injection to test error paths Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 5/8] drm/ttm: Add a macro to perform LRU iteration Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 6/8] drm/ttm: Add helpers for shrinking Thomas Hellström
2024-11-15 15:01 ` [PATCH v14 7/8] drm/xe: Add a shrinker for xe bos Thomas Hellström
2024-11-15 15:01 ` Thomas Hellström [this message]
2024-11-15 15:06 ` ✓ CI.Patch_applied: success for TTM shrinker helpers and xe buffer object shrinker (rev13) Patchwork
2024-11-15 15:07 ` ✗ CI.checkpatch: warning " Patchwork
2024-11-15 15:08 ` ✓ CI.KUnit: success " Patchwork
2024-11-15 15:17 ` ✗ CI.Build: failure " Patchwork
2024-11-16 11:26 ` ✓ CI.Patch_applied: success for TTM shrinker helpers and xe buffer object shrinker (rev14) Patchwork
2024-11-16 11:26 ` ✗ CI.checkpatch: warning " Patchwork
2024-11-16 11:28 ` ✓ CI.KUnit: success " Patchwork
2024-11-16 11:46 ` ✓ CI.Build: " Patchwork
2024-11-16 11:46 ` ✗ CI.Hooks: failure " Patchwork
2024-11-16 11:47 ` ✗ CI.checksparse: warning " Patchwork
2024-11-18 12:37 ` ✓ CI.Patch_applied: success for TTM shrinker helpers and xe buffer object shrinker (rev15) Patchwork
2024-11-18 12:37 ` ✗ CI.checkpatch: warning " Patchwork
2024-11-18 12:38 ` ✓ CI.KUnit: success " Patchwork
2024-11-18 12:56 ` ✓ CI.Build: " Patchwork
2024-11-18 12:56 ` ✗ CI.Hooks: failure " Patchwork
2024-11-18 12:58 ` ✗ CI.checksparse: warning " Patchwork
2024-11-18 13:16 ` ✓ CI.BAT: success " Patchwork
2024-11-18 16:29 ` ✗ CI.FULL: failure " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241115150120.3280-9-thomas.hellstrom@linux.intel.com \
--to=thomas.hellstrom@linux.intel.com \
--cc=Amaranath.Somalapuram@amd.com \
--cc=christian.koenig@amd.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-xe@lists.freedesktop.org \
--cc=matthew.brost@intel.com \
--cc=paulo.r.zanoni@intel.com \
--cc=simona.vetter@ffwll.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.