* [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting
@ 2018-02-07 18:47 Antonio Argenziano
2018-02-07 18:53 ` Chris Wilson
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Antonio Argenziano @ 2018-02-07 18:47 UTC (permalink / raw)
To: igt-dev; +Cc: Tvrtko Ursulin
The tests that do mlocked evictions sometimes fail because a child they
spawn would map a lot of memory and get killed by OOM. This patch does
not consider this a fail since it is a requirement of the test to be
able to mlock the memory.
As a result of this patch some gem_userptr_blits@mlocked* tests might
start skipping instead of failing.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=95427
Signed-off-by: Antonio Argenziano <antonio.argenziano@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
lib/igt_core.c | 40 ++++++++++++++++++++++++----------------
lib/igt_core.h | 1 +
tests/eviction_common.c | 5 ++++-
3 files changed, 29 insertions(+), 17 deletions(-)
diff --git a/lib/igt_core.c b/lib/igt_core.c
index 558a538d..86072761 100644
--- a/lib/igt_core.c
+++ b/lib/igt_core.c
@@ -1687,20 +1687,7 @@ void igt_child_done(pid_t pid)
test_children[i] = test_children[i + 1];
}
-/**
- * igt_waitchildren:
- *
- * Wait for all children forked with igt_fork.
- *
- * The magic here is that exit codes from children will be correctly propagated
- * to the main thread, including the relevant exit code if a child thread failed.
- * Of course if multiple children failed with different exit codes the resulting
- * exit code will be non-deterministic.
- *
- * Note that igt_skip() will not be forwarded, feature tests need to be done
- * before spawning threads with igt_fork().
- */
-void igt_waitchildren(void)
+int __igt_waitchildren(void)
{
int err = 0;
int count;
@@ -1746,8 +1733,29 @@ void igt_waitchildren(void)
}
num_test_children = 0;
- if (err)
- igt_fail(err);
+
+ return err;
+}
+
+/**
+ * igt_waitchildren:
+ *
+ * Wait for all children forked with igt_fork.
+ *
+ * The magic here is that exit codes from children will be correctly propagated
+ * to the main thread, including the relevant exit code if a child thread failed.
+ * Of course if multiple children failed with different exit codes the resulting
+ * exit code will be non-deterministic.
+ *
+ * Note that igt_skip() will not be forwarded, feature tests need to be done
+ * before spawning threads with igt_fork().
+ */
+void igt_waitchildren(void)
+{
+ int ret = __igt_waitchildren();
+
+ if (ret)
+ igt_fail(ret);
}
/**
diff --git a/lib/igt_core.h b/lib/igt_core.h
index f8543d65..049edb5c 100644
--- a/lib/igt_core.h
+++ b/lib/igt_core.h
@@ -689,6 +689,7 @@ bool __igt_fork(void);
for (int child = 0; child < (num_children); child++) \
for (; __igt_fork(); exit(0))
void igt_child_done(pid_t pid);
+int __igt_waitchildren(void);
void igt_waitchildren(void);
void igt_waitchildren_timeout(int seconds, const char *reason);
diff --git a/tests/eviction_common.c b/tests/eviction_common.c
index 300eb03d..655ea0bd 100644
--- a/tests/eviction_common.c
+++ b/tests/eviction_common.c
@@ -135,6 +135,7 @@ static void mlocked_evictions(int fd, struct igt_eviction_test_ops *ops,
{
unsigned int *can_mlock;
uint64_t sz, pin;
+ int child_ret;
intel_require_memory(surface_count, surface_size, CHECK_RAM);
@@ -158,8 +159,10 @@ static void mlocked_evictions(int fd, struct igt_eviction_test_ops *ops,
if (locked != NULL && !mlock(locked, pin + sz))
*can_mlock = 1;
}
- igt_waitchildren();
+ child_ret = __igt_waitchildren();
igt_require(*can_mlock);
+ igt_assert(child_ret == 0);
+
munmap(can_mlock, 4096);
igt_fork(child, 1) {
--
2.14.2
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting
2018-02-07 18:47 [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting Antonio Argenziano
@ 2018-02-07 18:53 ` Chris Wilson
2018-02-08 20:59 ` Antonio Argenziano
2018-02-07 19:09 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2018-02-08 1:26 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2 siblings, 1 reply; 5+ messages in thread
From: Chris Wilson @ 2018-02-07 18:53 UTC (permalink / raw)
To: Antonio Argenziano, igt-dev; +Cc: Tvrtko Ursulin
Quoting Antonio Argenziano (2018-02-07 18:47:23)
> The tests that do mlocked evictions sometimes fail because a child they
> spawn would map a lot of memory and get killed by OOM. This patch does
> not consider this a fail since it is a requirement of the test to be
> able to mlock the memory.
They die after we confirm that there is enough available memory to
satisfy the request. It's a bug somewhere.
-Chris
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
* [igt-dev] ✓ Fi.CI.BAT: success for igt/gem_userptr_blits: Check mlock requirement before asserting
2018-02-07 18:47 [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting Antonio Argenziano
2018-02-07 18:53 ` Chris Wilson
@ 2018-02-07 19:09 ` Patchwork
2018-02-08 1:26 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2018-02-07 19:09 UTC (permalink / raw)
To: Antonio Argenziano; +Cc: igt-dev
== Series Details ==
Series: igt/gem_userptr_blits: Check mlock requirement before asserting
URL : https://patchwork.freedesktop.org/series/37831/
State : success
== Summary ==
IGT patchset tested on top of latest successful build
c0c5a10a4a7bf81614179002beb8cc945180c920 tests/perf_pmu: Test RC6 during runtime suspend
with latest DRM-Tip kernel build CI_DRM_3736
e4fe439facdf drm-tip: 2018y-02m-07d-17h-08m-01s UTC integration manifest
No testlist changes.
Test prime_vgem:
Subgroup basic-fence-flip:
fail -> PASS (fi-skl-6770hq)
fi-bdw-5557u total:288 pass:267 dwarn:0 dfail:0 fail:0 skip:21 time:422s
fi-bdw-gvtdvm total:288 pass:264 dwarn:0 dfail:0 fail:0 skip:24 time:423s
fi-blb-e6850 total:288 pass:223 dwarn:1 dfail:0 fail:0 skip:64 time:376s
fi-bsw-n3050 total:288 pass:242 dwarn:0 dfail:0 fail:0 skip:46 time:487s
fi-bwr-2160 total:288 pass:183 dwarn:0 dfail:0 fail:0 skip:105 time:288s
fi-bxt-dsi total:288 pass:258 dwarn:0 dfail:0 fail:0 skip:30 time:484s
fi-bxt-j4205 total:288 pass:259 dwarn:0 dfail:0 fail:0 skip:29 time:484s
fi-byt-j1900 total:288 pass:253 dwarn:0 dfail:0 fail:0 skip:35 time:474s
fi-byt-n2820 total:288 pass:249 dwarn:0 dfail:0 fail:0 skip:39 time:462s
fi-cfl-s2 total:288 pass:262 dwarn:0 dfail:0 fail:0 skip:26 time:570s
fi-cnl-y3 total:288 pass:262 dwarn:0 dfail:0 fail:0 skip:26 time:581s
fi-elk-e7500 total:288 pass:229 dwarn:0 dfail:0 fail:0 skip:59 time:420s
fi-gdg-551 total:288 pass:179 dwarn:0 dfail:0 fail:1 skip:108 time:287s
fi-glk-1 total:288 pass:260 dwarn:0 dfail:0 fail:0 skip:28 time:512s
fi-hsw-4770 total:288 pass:261 dwarn:0 dfail:0 fail:0 skip:27 time:393s
fi-ilk-650 total:288 pass:228 dwarn:0 dfail:0 fail:0 skip:60 time:414s
fi-ivb-3520m total:288 pass:259 dwarn:0 dfail:0 fail:0 skip:29 time:449s
fi-ivb-3770 total:288 pass:255 dwarn:0 dfail:0 fail:0 skip:33 time:418s
fi-kbl-7500u total:288 pass:263 dwarn:1 dfail:0 fail:0 skip:24 time:459s
fi-kbl-7560u total:288 pass:269 dwarn:0 dfail:0 fail:0 skip:19 time:495s
fi-kbl-7567u total:288 pass:268 dwarn:0 dfail:0 fail:0 skip:20 time:453s
fi-kbl-r total:288 pass:261 dwarn:0 dfail:0 fail:0 skip:27 time:499s
fi-pnv-d510 total:288 pass:222 dwarn:1 dfail:0 fail:0 skip:65 time:598s
fi-skl-6260u total:288 pass:268 dwarn:0 dfail:0 fail:0 skip:20 time:437s
fi-skl-6600u total:288 pass:261 dwarn:0 dfail:0 fail:0 skip:27 time:507s
fi-skl-6700hq total:288 pass:262 dwarn:0 dfail:0 fail:0 skip:26 time:525s
fi-skl-6700k2 total:288 pass:264 dwarn:0 dfail:0 fail:0 skip:24 time:490s
fi-skl-6770hq total:288 pass:268 dwarn:0 dfail:0 fail:0 skip:20 time:488s
fi-skl-guc total:288 pass:260 dwarn:0 dfail:0 fail:0 skip:28 time:420s
fi-skl-gvtdvm total:288 pass:265 dwarn:0 dfail:0 fail:0 skip:23 time:431s
fi-snb-2520m total:288 pass:248 dwarn:0 dfail:0 fail:0 skip:40 time:525s
fi-snb-2600 total:288 pass:248 dwarn:0 dfail:0 fail:0 skip:40 time:399s
Blacklisted hosts:
fi-glk-dsi total:288 pass:258 dwarn:0 dfail:0 fail:0 skip:30 time:469s
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_886/issues.html
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
* [igt-dev] ✓ Fi.CI.IGT: success for igt/gem_userptr_blits: Check mlock requirement before asserting
2018-02-07 18:47 [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting Antonio Argenziano
2018-02-07 18:53 ` Chris Wilson
2018-02-07 19:09 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
@ 2018-02-08 1:26 ` Patchwork
2 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2018-02-08 1:26 UTC (permalink / raw)
To: Antonio Argenziano; +Cc: igt-dev
== Series Details ==
Series: igt/gem_userptr_blits: Check mlock requirement before asserting
URL : https://patchwork.freedesktop.org/series/37831/
State : success
== Summary ==
Test perf:
Subgroup buffer-fill:
pass -> FAIL (shard-apl) fdo#103755
Subgroup oa-exponents:
fail -> PASS (shard-apl) fdo#102254
Test kms_frontbuffer_tracking:
Subgroup fbc-1p-primscrn-cur-indfb-draw-render:
pass -> FAIL (shard-apl) fdo#101623
Test kms_flip:
Subgroup modeset-vs-vblank-race-interruptible:
pass -> FAIL (shard-hsw) fdo#103060 +1
Subgroup flip-vs-absolute-wf_vblank:
pass -> FAIL (shard-hsw) fdo#100368
Test kms_pipe_crc_basic:
Subgroup nonblocking-crc-pipe-b-frame-sequence:
pass -> FAIL (shard-apl) fdo#103481
Test gem_eio:
Subgroup in-flight-suspend:
pass -> FAIL (shard-hsw) fdo#104676
fdo#103755 https://bugs.freedesktop.org/show_bug.cgi?id=103755
fdo#102254 https://bugs.freedesktop.org/show_bug.cgi?id=102254
fdo#101623 https://bugs.freedesktop.org/show_bug.cgi?id=101623
fdo#103060 https://bugs.freedesktop.org/show_bug.cgi?id=103060
fdo#100368 https://bugs.freedesktop.org/show_bug.cgi?id=100368
fdo#103481 https://bugs.freedesktop.org/show_bug.cgi?id=103481
fdo#104676 https://bugs.freedesktop.org/show_bug.cgi?id=104676
shard-apl total:3388 pass:1754 dwarn:1 dfail:0 fail:24 skip:1608 time:12248s
shard-hsw total:3444 pass:1758 dwarn:1 dfail:0 fail:13 skip:1671 time:11804s
shard-snb total:3444 pass:1351 dwarn:1 dfail:0 fail:10 skip:2082 time:6689s
Blacklisted hosts:
shard-kbl total:3444 pass:1913 dwarn:1 dfail:0 fail:21 skip:1509 time:9542s
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_886/shards.html
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting
2018-02-07 18:53 ` Chris Wilson
@ 2018-02-08 20:59 ` Antonio Argenziano
0 siblings, 0 replies; 5+ messages in thread
From: Antonio Argenziano @ 2018-02-08 20:59 UTC (permalink / raw)
To: Chris Wilson, igt-dev; +Cc: Tvrtko Ursulin
On 07/02/18 10:53, Chris Wilson wrote:
> Quoting Antonio Argenziano (2018-02-07 18:47:23)
>> The tests that do mlocked evictions sometimes fail because a child they
>> spawn would map a lot of memory and get killed by OOM. This patch does
>> not consider this a fail since it is a requirement of the test to be
>> able to mlock the memory.
>
> They die after we confirm that there is enough available memory to
> satisfy the request. It's a bug somewhere.
hmmm, OK. My thinking was: since it is not i915's doing consider it a
requirement, but I see your point.
Thanks,
Antonio
> -Chris
>
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-02-08 20:59 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-07 18:47 [igt-dev] [PATCH i-g-t] igt/gem_userptr_blits: Check mlock requirement before asserting Antonio Argenziano
2018-02-07 18:53 ` Chris Wilson
2018-02-08 20:59 ` Antonio Argenziano
2018-02-07 19:09 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2018-02-08 1:26 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
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.