]> granicus.if.org Git - gc/commitdiff
Fix assertion in GC_mark_from for non-heap regions
authorGabor Drescher <gabor.drescher@cs.fau.de>
Tue, 5 Jul 2016 07:51:50 +0000 (09:51 +0200)
committerIvan Maidanski <ivmai@mail.ru>
Thu, 10 Nov 2016 17:59:11 +0000 (20:59 +0300)
* mark.c (GC_mark_from): Relax assertion condition for descr and
GC_least/greatest_plausible_heap_addr values.

mark.c

diff --git a/mark.c b/mark.c
index c376a9aad593316e4fa177e079df6df1b645e662..8a97276e5841f87934cd7ada06eb850f1b3f4f8b 100644 (file)
--- a/mark.c
+++ b/mark.c
@@ -655,7 +655,10 @@ GC_INNER mse * GC_mark_from(mse *mark_stack_top, mse *mark_stack,
           /* Process part of the range to avoid pushing too much on the */
           /* stack.                                                     */
           GC_ASSERT(descr < (word)GC_greatest_plausible_heap_addr
-                            - (word)GC_least_plausible_heap_addr);
+                            - (word)GC_least_plausible_heap_addr
+                || (word)(current_p + descr)
+                            <= (word)GC_least_plausible_heap_addr
+                || (word)current_p >= (word)GC_greatest_plausible_heap_addr);
 #         ifdef ENABLE_TRACE
             if (GC_trace_addr >= current_p
                 && GC_trace_addr < current_p + descr) {