[m-rev.] diff: fix inverted deep profiler assertion

Peter Wang novalazy at gmail.com
Fri Jul 27 17:46:03 AEST 2012


Branches: main

compiler/coverage_profiling.m:
	Fix inverted test in deep profiler assertion.

diff --git a/compiler/coverage_profiling.m b/compiler/coverage_profiling.m
index 04bcab1..87284c9 100644
--- a/compiler/coverage_profiling.m
+++ b/compiler/coverage_profiling.m
@@ -1289,7 +1289,7 @@ coverage_point_ll_code(static_coverage_data) =
     ps = pl->MR_sle_proc_static;
     MR_deep_assert(NULL, pl, NULL, ps != NULL);
 
-    MR_deep_assert(NULL, pl, ps, CPIndex >= ps->MR_ps_num_coverage_points);
+    MR_deep_assert(NULL, pl, ps, CPIndex < ps->MR_ps_num_coverage_points);
     MR_deep_assert(NULL, pl, ps, ps->MR_ps_coverage_points != NULL);
 
     ps->MR_ps_coverage_points[CPIndex]++;
@@ -1339,7 +1339,7 @@ coverage_point_ll_code(dynamic_coverage_data) =
         MR_deep_assert(csd, NULL, NULL, pl != NULL);
         ps = pl->MR_sle_proc_static;
         MR_deep_assert(csd, pl, NULL, ps != NULL);
-        MR_deep_assert(csd, pl, ps, CPIndex >= ps->MR_ps_num_coverage_points);
+        MR_deep_assert(csd, pl, ps, CPIndex < ps->MR_ps_num_coverage_points);
     }
 #endif
 

--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list