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>,
dri-devel@lists.freedesktop.org
Subject: [PATCH v6 12/12] drm/xe: Increase the XE_PL_TT watermark
Date: Wed, 3 Jul 2024 17:38:13 +0200 [thread overview]
Message-ID: <20240703153813.182001-13-thomas.hellstrom@linux.intel.com> (raw)
In-Reply-To: <20240703153813.182001-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_SYSTEM
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>
---
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.44.0
next prev parent reply other threads:[~2024-07-03 15:38 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-03 15:38 [PATCH v6 00/12] TTM shrinker helpers and xe buffer object shrinker Thomas Hellström
2024-07-03 15:38 ` [PATCH v6 01/12] drm/ttm: Allow TTM LRU list nodes of different types Thomas Hellström
2024-07-03 15:38 ` [PATCH v6 02/12] drm/ttm: Slightly clean up LRU list iteration Thomas Hellström
2024-07-03 15:38 ` [PATCH v6 03/12] drm/ttm: Use LRU hitches Thomas Hellström
2024-07-04 9:05 ` Christian König
2024-07-03 15:38 ` [PATCH v6 04/12] drm/ttm, drm/amdgpu, drm/xe: Consider hitch moves within bulk sublist moves Thomas Hellström
2024-07-03 17:53 ` Matthew Brost
2024-07-04 9:21 ` Christian König
2024-07-04 12:41 ` Thomas Hellström
2024-07-04 13:13 ` Christian König
2024-07-04 13:53 ` Thomas Hellström
2024-07-04 14:32 ` Christian König
2024-07-03 15:38 ` [PATCH v6 05/12] drm/ttm: Provide a generic LRU walker helper Thomas Hellström
2024-07-03 15:38 ` [PATCH v6 06/12] drm/ttm: Use the LRU walker helper for swapping Thomas Hellström
2024-07-03 18:24 ` Matthew Brost
2024-07-03 15:38 ` [PATCH v6 07/12] drm/ttm: Use the LRU walker for eviction Thomas Hellström
2024-07-03 19:20 ` Matthew Brost
2024-07-03 15:38 ` [PATCH v6 08/12] drm/ttm: Add a virtual base class for graphics memory backup Thomas Hellström
2024-07-03 19:47 ` Matthew Brost
2024-07-04 11:57 ` Christian König
2024-07-03 15:38 ` [PATCH v6 09/12] drm/ttm/pool: Provide a helper to shrink pages Thomas Hellström
2024-08-07 23:38 ` Matthew Brost
2024-08-16 9:47 ` Thomas Hellström
2024-07-03 15:38 ` [PATCH v6 10/12] drm/ttm: Use fault-injection to test error paths Thomas Hellström
2024-08-07 23:43 ` Matthew Brost
2024-08-09 13:53 ` Thomas Hellström
2024-08-09 16:40 ` Matthew Brost
2024-07-03 15:38 ` [PATCH v6 11/12] drm/ttm, drm/xe: Add a shrinker for xe bos Thomas Hellström
2024-08-08 1:37 ` Matthew Brost
2024-08-09 14:31 ` Thomas Hellström
2024-08-09 17:22 ` Matthew Brost
2024-08-09 16:05 ` Matthew Auld
2024-07-03 15:38 ` Thomas Hellström [this message]
2024-08-05 18:35 ` [PATCH v6 12/12] drm/xe: Increase the XE_PL_TT watermark Souza, Jose
2024-08-07 23:13 ` Matthew Brost
2024-08-09 12:22 ` Thomas Hellström
2024-08-07 23:44 ` Matthew Brost
2024-08-09 13:53 ` Thomas Hellström
2024-07-03 17:35 ` ✓ CI.Patch_applied: success for TTM shrinker helpers and xe buffer object shrinker (rev6) Patchwork
2024-07-03 17:35 ` ✗ CI.checkpatch: warning " Patchwork
2024-07-03 17:36 ` ✗ CI.KUnit: 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=20240703153813.182001-13-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 \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).