[PATCH] drm: Inject a cond_resched() into long drm_clflush_sg()
David Laight
David.Laight at ACULAB.COM
Thu Jan 16 14:40:43 UTC 2020
> I'll do some measurements later this afternoon.
This is an Ivy bridge cpu, so clflush (not clflushopt).
With a cond_resched for every page I get:
(Note these calls are every 10 seconds....)
# tracer: function_graph
#
# CPU DURATION FUNCTION CALLS
# | | | | | | |
0) # 3155.126 us | drm_clflush_sg [drm]();
1) # 3067.382 us | drm_clflush_sg [drm]();
2) # 3063.766 us | drm_clflush_sg [drm]();
3) # 3092.302 us | drm_clflush_sg [drm]();
0) # 3209.486 us | drm_clflush_sg [drm]();
------------------------------------------
0) kworker-7 => kworker-319
------------------------------------------
0) # 3633.803 us | drm_clflush_sg [drm]();
------------------------------------------
1) kworker-7 => kworker-319
------------------------------------------
1) # 3090.278 us | drm_clflush_sg [drm]();
2) # 3828.108 us | drm_clflush_sg [drm]();
3) # 3049.836 us | drm_clflush_sg [drm]();
------------------------------------------
3) kworker-319 => kworker-7
------------------------------------------
3) # 3295.017 us | drm_clflush_sg [drm]();
3) # 3064.077 us | drm_clflush_sg [drm]();
------------------------------------------
0) kworker-319 => kworker-7
------------------------------------------
0) # 3182.034 us | drm_clflush_sg [drm]();
------------------------------------------
3) kworker-7 => kworker-319
------------------------------------------
3) # 3065.754 us | drm_clflush_sg [drm]();
------------------------------------------
2) kworker-319 => kworker-7
------------------------------------------
2) # 3562.513 us | drm_clflush_sg [drm]();
------------------------------------------
3) kworker-319 => kworker-7
------------------------------------------
3) # 3048.914 us | drm_clflush_sg [drm]();
3) # 3062.469 us | drm_clflush_sg [drm]();
3) # 3055.727 us | drm_clflush_sg [drm]();
------------------------------------------
0) kworker-7 => kworker-319
------------------------------------------
Without the cond_sched I suspect more of them are 3.0ms.
Not really a significant difference.
I guess the longer times are the scheduler looking for work?
I don't understand the extra traces - I'm guessing they are process switch related.
David
-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)
More information about the dri-devel
mailing list