From daaf0cb524081cf26dee5eb0e68d2e1d86dfdfd5 Mon Sep 17 00:00:00 2001 From: Pekka Pirinen Date: Tue, 1 Aug 2000 17:03:53 +0100 Subject: [PATCH] No assert Copied from Perforce Change: 21400 ServerID: perforce.ravenbrook.com --- mps/src/amsss.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/mps/src/amsss.c b/mps/src/amsss.c index 67bebdc630d..6ce7a493298 100644 --- a/mps/src/amsss.c +++ b/mps/src/amsss.c @@ -1,7 +1,7 @@ /* impl.c.amsss: POOL CLASS AMS STRESS TEST * - * $HopeName: MMsrc!amsss.c(trunk.9) $ - * Copyright (C) 1998. Harlequin Group plc. All rights reserved. + * $HopeName: MMsrc!amsss.c(trunk.10) $ + * Copyright (C) 1998 Harlequin Limited. All rights reserved. * * .design: Adapted from amcss.c, but not counting collections, just * total size of objects allocated (because epoch doesn't increment @@ -21,7 +21,6 @@ #include #include #include -#include #define exactRootsCOUNT 50 @@ -109,15 +108,15 @@ static void *test(void *arg, size_t s) (unsigned long)totalSize, objs); fflush(stdout); for(i = 0; i < exactRootsCOUNT; ++i) - assert(exactRoots[i] == objNULL || - dylan_check(exactRoots[i])); + cdie(exactRoots[i] == objNULL || dylan_check(exactRoots[i]), + "all roots check"); } r = (size_t)rnd(); if(r & 1) { i = (r >> 1) % exactRootsCOUNT; if(exactRoots[i] != objNULL) - assert(dylan_check(exactRoots[i])); + cdie(dylan_check(exactRoots[i]), "dying root check"); exactRoots[i] = make(); if(exactRoots[(exactRootsCOUNT-1) - i] != objNULL) dylan_write(exactRoots[(exactRootsCOUNT-1) - i], @@ -151,11 +150,13 @@ static void *test(void *arg, size_t s) } -int main(void) +int main(int argc, char **argv) { mps_arena_t arena; mps_thr_t thread; void *r; + + randomize(argc, argv); die(mps_arena_create(&arena, mps_arena_class_vm(), testArenaSIZE), "arena_create");