From 6b124de0a7866f6e766ebdffa9e903577418dc4e Mon Sep 17 00:00:00 2001 From: Zoltan Somogyi Date: Fri, 4 Sep 2015 07:42:59 +1000 Subject: [PATCH] Serialize the creation of the dice test's slices. Without this, mmake -jN may try to create the slices in parallel. Since that task involves moving trace counts files, whose names are unpredictable (they include the process id), we do it by moving all files whose names fit the associated a pattern. If more than one slice is being created at any one time, this meant that one invocation of the mmake rule doing the moving can "steal" the trace counts file from another. --- tests/debugger/Mmakefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/debugger/Mmakefile b/tests/debugger/Mmakefile index 4d014ca20..64420b6ec 100644 --- a/tests/debugger/Mmakefile +++ b/tests/debugger/Mmakefile @@ -346,12 +346,12 @@ dice.pass1: dice MERCURY_OPTIONS=--trace-count ./dice 1 2 3 4 && \ mv .mercury_trace_counts.*dice.* dice.pass1 -dice.pass2: dice +dice.pass2: dice dice.pass1 /bin/rm -f .mercury_trace_counts.*dice.* MERCURY_OPTIONS=--trace-count ./dice 5 6 7 8 && \ mv .mercury_trace_counts.*dice.* dice.pass2 -dice.pass3: dice +dice.pass3: dice dice.pass2 /bin/rm -f .mercury_trace_counts.*dice.* MERCURY_OPTIONS=--trace-count ./dice 10 11 100 && \ mv .mercury_trace_counts.*dice.* dice.pass3 @@ -360,7 +360,7 @@ dice.passes: dice.pass1 dice.pass2 dice.pass3 MERCURY_OPTIONS= \ $(SLICE_DIR)mtc_union -o dice.passes dice.pass1 dice.pass2 dice.pass3 -dice.fail: dice +dice.fail: dice dice.passes /bin/rm -f .mercury_trace_counts.*dice.* MERCURY_OPTIONS=--trace-count ./dice 4 1 2 3 && \ mv .mercury_trace_counts.*dice.* dice.fail