The timing measurements take into account threads creation and
joining which are performed at SCHED_OTHER priority. This introduce
latency artifacts in what we intend to measure.
To minimize this effect, bump the main thread priority to just above the
matrixmult_thread threads priority (i.e. PRIO + 1).
These effects are particularly visible from the concurrent runs as well as
the Sequential/Concurrent ratios which exhibit large discrepancies between
min, max and average values.
- without patch:
Sequential:
Min: 297858 us
Max: 298181 us
Avg: 297920.9688 us
StdDev: 54.9808
Concurrent (8x):
Min: 38137 us
Max: 75575 us
Avg: 53347.6719 us
StdDev: 17647.2676
Seq/Conc Ratios:
Min: 7.8102
Max: 3.9455
Avg: 5.5845
- with patch:
Sequential:
Min: 297850 us
Max: 298106 us
Avg: 297916.9375 us
StdDev: 42.2170 us
Concurrent (8x):
Min: 38128 us
Max: 39023 us
Avg: 38211.1992 us
StdDev: 91.1165 us
Seq/Conc Ratios:
Min: 7.8118
Max: 7.6392
Avg: 7.7966
Signed-off-by: Sebastien Dugue <[EMAIL PROTECTED]>
Cc: Darren Hart <[EMAIL PROTECTED]>
Cc: Tim Chavez <[EMAIL PROTECTED]>
---
testcases/realtime/func/matrix_mult/matrix_mult.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/testcases/realtime/func/matrix_mult/matrix_mult.c
b/testcases/realtime/func/matrix_mult/matrix_mult.c
index 5577a51..6611653 100644
--- a/testcases/realtime/func/matrix_mult/matrix_mult.c
+++ b/testcases/realtime/func/matrix_mult/matrix_mult.c
@@ -165,6 +165,9 @@ int main(int argc, char *argv[])
stats_container_init(&cdat, ITERATIONS);
stats_container_init(&chist, HIST_BUCKETS);
+ if (set_priority(PRIO + 1))
+ return -1;
+
// run matrix mult operation sequentially
printf("\nSequential:\n");
for (i = 0; i < ITERATIONS; i++) {
--
1.5.4.rc2.84.gf85fd-dirty
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list