Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] tests/intel/xe_vm: Always have at least 2 pages bound in mmap hammer sections
@ 2024-04-24 21:39 Jagmeet Randhawa
  2024-04-24 21:42 ` [PATCH i-g-t, v2] " Jagmeet Randhawa
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Jagmeet Randhawa @ 2024-04-24 21:39 UTC (permalink / raw)
  Cc: igt-dev, jonathan.cavitt, matthew.brost, Jagmeet Randhawa

This patch extends the recent improvements made
to the munmap hammer sections by applying a similar
fix to the mmap hammer sections.

If the prefetch buffer is 2k or larger the munmap hammer sections will
prefetch the next page, if the page is unbound a fault will occur.
Account for larger prefetchs by always having at least 2 pages bound for
the hammer thread.

Cc: Jonathan Cavitt <jonathan.cavitt@intel.com>
Suggested-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Jagmeet Randhawa <jagmeet.randhawa@intel.com>
---
 tests/intel/xe_vm.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/tests/intel/xe_vm.c b/tests/intel/xe_vm.c
index de2b1a813..9872df832 100644
--- a/tests/intel/xe_vm.c
+++ b/tests/intel/xe_vm.c
@@ -1913,12 +1913,12 @@ igt_main
 		{ "one-partial", 4, 1, 1, 2, 0 },
 		{ "either-side-partial", 4, 2, 1, 2, 0 },
 		{ "either-side-full", 4, 4, 1, 2, 0 },
-		{ "either-side-partial-hammer", 4, 2, 1, 2,
+		{ "either-side-partial-hammer", 6, 2, 2, 2,
 			MAP_FLAG_HAMMER_FIRST_PAGE },
-		{ "either-side-partial-split-page-hammer", 4, 2, 1, 2,
+		{ "either-side-partial-split-page-hammer", 6, 2, 2, 2,
 			MAP_FLAG_HAMMER_FIRST_PAGE |
 			MAP_FLAG_LARGE_PAGE },
-		{ "either-side-partial-large-page-hammer", 4, 2, 1, 2,
+		{ "either-side-partial-large-page-hammer", 6, 2, 2, 2,
 			MAP_FLAG_HAMMER_FIRST_PAGE |
 			MAP_FLAG_LARGE_PAGE |
 			MAP_FLAG_LARGE_PAGE_NO_SPLIT },
@@ -1926,7 +1926,7 @@ igt_main
 		{ "front", 4, 2, 1, 3, 0 },
 		{ "many-all", 4 * 8, 2 * 8, 0 * 8, 4 * 8, 0 },
 		{ "many-either-side-partial", 4 * 8, 2 * 8, 1, 4 * 8 - 2, 0 },
-		{ "many-either-side-partial-hammer", 4 * 8, 2 * 8, 1, 4 * 8 - 2,
+		{ "many-either-side-partial-hammer", 4 * 8, 2 * 8, 2, 4 * 8 - 4,
 			MAP_FLAG_HAMMER_FIRST_PAGE },
 		{ "userptr-all", 4, 2, 0, 4, MAP_FLAG_USERPTR },
 		{ "userptr-one-partial", 4, 1, 1, 2, MAP_FLAG_USERPTR },
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread
* [PATCH i-g-t, v2] tests/intel/xe_vm: Always have at least 2 pages bound in mmap hammer sections
@ 2024-04-24 21:47 Jagmeet Randhawa
  0 siblings, 0 replies; 8+ messages in thread
From: Jagmeet Randhawa @ 2024-04-24 21:47 UTC (permalink / raw)
  Cc: igt-dev, jonathan.cavitt, matthew.brost, Jagmeet Randhawa

Fixes: ee0a9c8e30f6 ("tests/intel/xe_vm: Always have at
least 2 pages bound in munmap hammer sections")

This patch extends the recent improvements made
to the munmap hammer sections by applying a similar
fix to the mmap hammer sections.

If the prefetch buffer is 2k or larger the munmap hammer sections will
prefetch the next page, if the page is unbound a fault will occur.
Account for larger prefetchs by always having at least 2 pages bound for
the hammer thread.

Suggested-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Jagmeet Randhawa <jagmeet.randhawa@intel.com>
---
 tests/intel/xe_vm.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/tests/intel/xe_vm.c b/tests/intel/xe_vm.c
index de2b1a813..9872df832 100644
--- a/tests/intel/xe_vm.c
+++ b/tests/intel/xe_vm.c
@@ -1913,12 +1913,12 @@ igt_main
 		{ "one-partial", 4, 1, 1, 2, 0 },
 		{ "either-side-partial", 4, 2, 1, 2, 0 },
 		{ "either-side-full", 4, 4, 1, 2, 0 },
-		{ "either-side-partial-hammer", 4, 2, 1, 2,
+		{ "either-side-partial-hammer", 6, 2, 2, 2,
 			MAP_FLAG_HAMMER_FIRST_PAGE },
-		{ "either-side-partial-split-page-hammer", 4, 2, 1, 2,
+		{ "either-side-partial-split-page-hammer", 6, 2, 2, 2,
 			MAP_FLAG_HAMMER_FIRST_PAGE |
 			MAP_FLAG_LARGE_PAGE },
-		{ "either-side-partial-large-page-hammer", 4, 2, 1, 2,
+		{ "either-side-partial-large-page-hammer", 6, 2, 2, 2,
 			MAP_FLAG_HAMMER_FIRST_PAGE |
 			MAP_FLAG_LARGE_PAGE |
 			MAP_FLAG_LARGE_PAGE_NO_SPLIT },
@@ -1926,7 +1926,7 @@ igt_main
 		{ "front", 4, 2, 1, 3, 0 },
 		{ "many-all", 4 * 8, 2 * 8, 0 * 8, 4 * 8, 0 },
 		{ "many-either-side-partial", 4 * 8, 2 * 8, 1, 4 * 8 - 2, 0 },
-		{ "many-either-side-partial-hammer", 4 * 8, 2 * 8, 1, 4 * 8 - 2,
+		{ "many-either-side-partial-hammer", 4 * 8, 2 * 8, 2, 4 * 8 - 4,
 			MAP_FLAG_HAMMER_FIRST_PAGE },
 		{ "userptr-all", 4, 2, 0, 4, MAP_FLAG_USERPTR },
 		{ "userptr-one-partial", 4, 1, 1, 2, MAP_FLAG_USERPTR },
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2024-04-25 15:18 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-24 21:39 [PATCH i-g-t] tests/intel/xe_vm: Always have at least 2 pages bound in mmap hammer sections Jagmeet Randhawa
2024-04-24 21:42 ` [PATCH i-g-t, v2] " Jagmeet Randhawa
2024-04-24 21:56 ` Cavitt, Jonathan
2024-04-24 22:26   ` Matthew Brost
2024-04-24 22:16 ` ✗ Fi.CI.BAT: failure for " Patchwork
2024-04-24 22:18 ` ✓ CI.xeBAT: success " Patchwork
2024-04-25 15:18 ` ✗ CI.xeFULL: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2024-04-24 21:47 [PATCH i-g-t, v2] " Jagmeet Randhawa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox