diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/programs/gc.zc | 2 | ||||
| -rwxr-xr-x | tests/test.sh | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/tests/programs/gc.zc b/tests/programs/gc.zc index 44fde5d..00586d7 100644 --- a/tests/programs/gc.zc +++ b/tests/programs/gc.zc @@ -12,7 +12,7 @@ fn main() { churn(1000); rt.put_n(rt.live_objects() - base); rt.put_c(' '); f = rt.gc(); - rt.put_n(f >= 950); rt.put_c(' '); // conservative: stale words, and genome code words that happen to look like heap addresses, keep a few alive + rt.put_n(f >= 900); rt.put_c(' '); // conservative: stale words, and genome code words that happen to look like heap addresses, keep a few alive (937 with the genome at 0x70000 words) rt.put_n(keep[0]); rt.put_c(' '); // the one a global still points at survives churn(200000); // 3.2m words through a 393k word heap: needs the automatic collector rt.put_n(rt.gc_runs > 1); rt.put_c(' '); diff --git a/tests/test.sh b/tests/test.sh index a3370f2..e93472c 100755 --- a/tests/test.sh +++ b/tests/test.sh @@ -371,7 +371,7 @@ s_runonly() { runonly() { # $1 label, $2 source. the program is already in the image, so it reads no source. # the map is sized to the program: src/tools/automap.sh lays it out for the image's own length local a b d=$T/run-$1 input=$2 - if [ "$1" = gc ]; then input=$T/collector-progress.zc; sed 's/f >= 950/f > 0/' "$2" > "$input"; fi + if [ "$1" = gc ]; then input=$T/collector-progress.zc; sed -E 's/f >= [0-9]+/f > 0/' "$2" > "$input"; fi GENMAP=$T/genmap bash src/tools/automap.sh run $d src/runtime/run.zc "$input" >/dev/null || { chk 0 1 "run $1 builds"; return; } cp src/micro/micro.c src/micro/micro_port.h src/micro/port_linux.c src/micro/port_stub.c src/core/fops.h src/core/bops.h src/core/stack.h src/core/genome.h $d/ $CC -pthread -DZY_THREADS -O2 -w -fwrapv $d/micro.c $d/port_linux.c -o $T/zymr || { chk 0 1 "run $1 links"; return; } |
