Diff of /tests/finalize.test.sh [732ad8] .. [04d819]  Maximize  Restore

Switch to unified view

a/tests/finalize.test.sh b/tests/finalize.test.sh
...
...
17
  nil)
17
  nil)
18
18
19
(let ((junk (mapcar (lambda (_)
19
(let ((junk (mapcar (lambda (_)
20
                      (declare (ignore _))
20
                      (declare (ignore _))
21
                      (let ((x (gensym)))
21
                      (let ((x (gensym)))
22
            (finalize x (lambda ()
22
                          (finalize x (lambda ()
23
                  ;; cons in finalizer
23
                                        ;; cons in finalizer
24
                                        (setf *tmp* (make-list 10000))
24
                                        (setf *tmp* (make-list 10000))
25
                  (incf *count*)))
25
                                        (incf *count*)))
26
            x))
26
                          x))
27
           (make-list 10000))))
27
                     (make-list 10000))))
28
    (setf junk (foo junk))
28
    (setf junk (foo junk))
29
    (foo junk))
29
    (foo junk))
30
30
31
(gc :full t)
31
(gc :full t)
32
(gc :full t)
32
(gc :full t)
...
...
44
WAITED=0
44
WAITED=0
45
45
46
echo "Waiting for SBCL to finish stress-testing finalizers"
46
echo "Waiting for SBCL to finish stress-testing finalizers"
47
while true; do
47
while true; do
48
    if [ -f finalize-test-passed ]; then
48
    if [ -f finalize-test-passed ]; then
49
  echo "OK"
49
        echo "OK"
50
  rm finalize-test-passed
50
        rm finalize-test-passed
51
  exit 104 # Success
51
        exit 104 # Success
52
    elif [ -f finalize-test-failed ]; then
52
    elif [ -f finalize-test-failed ]; then
53
  echo "Failed"
53
        echo "Failed"
54
  rm finalize-test-failed
54
        rm finalize-test-failed
55
  exit 1 # Failure
55
        exit 1 # Failure
56
    fi
56
    fi
57
    sleep 1
57
    sleep 1
58
    WAITED=$(($WAITED+1))
58
    WAITED=$(($WAITED+1))
59
    if (($WAITED>60)); then
59
    if (($WAITED>60)); then
60
  echo
60
        echo
61
  echo "timeout, killing SBCL"
61
        echo "timeout, killing SBCL"
62
  kill -9 $SBCL_PID
62
        kill -9 $SBCL_PID
63
  exit 1 # Failure, SBCL probably hanging in GC
63
        exit 1 # Failure, SBCL probably hanging in GC
64
    fi
64
    fi
65
done
65
done
66
66

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks