1 # This program is free software; you can redistribute it and/or modify
2 # it under the terms of the GNU General Public License as published by
3 # the Free Software Foundation; either version 2 of the License, or
4 # (at your option) any later version.
6 # This program is distributed in the hope that it will be useful,
7 # but WITHOUT ANY WARRANTY; without even the implied warranty of
8 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 # GNU General Public License for more details.
11 # You should have received a copy of the GNU General Public License
12 # along with this program; if not, write to the Free Software
13 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
15 # Copyright (C) Mathieu Desnoyers, 2009
17 # Authors: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
20 #for multi-core verif, 15.5GB shared mem, use files if full
21 #CFLAGS=-DHASH64 -DMEMLIM=15500 -DNCORE=2
22 #CFLAGS=-DHASH64 -DCOLLAPSE -DMA=88 -DMEMLIM=15500 -DNCORE=8
25 #CFLAGS=-DHASH64 -DCOLLAPSE -DMA=88
31 make urcu_free | tee urcu_free.log
32 #nested useless with signal test.
33 #make urcu_free_nested | tee urcu_free_nested.log
34 make urcu_free_no_rmb | tee urcu_free_no_rmb.log
35 make urcu_free_no_wmb | tee urcu_free_no_wmb.log
36 make urcu_free_no_mb | tee urcu_free_no_mb.log
37 make urcu_free_single_flip | tee urcu_free_single_flip.log
38 make urcu_progress_writer | tee urcu_progress_writer.log
39 make urcu_progress_reader | tee urcu_progress_reader.log
40 make urcu_progress_writer_error | tee urcu_progress_writer_error.log
41 make asserts | tee asserts.log
44 #show trail : spin -v -t -N pan.ltl input.spin
45 # after each individual make.
49 @echo
"Verification summary"
53 cat DEFINES
> .input.spin
54 cat
${SPINFILE} >> .input.spin
55 rm -f .input.spin.trail
56 spin
-a
-X .input.spin
57 gcc
-O2
-w
${CFLAGS} -DSAFETY
-o pan pan.c
58 .
/pan
-v
-c1
-X
-m10000000
-w20
59 cp .input.spin
$@.spin.input
60 -cp .input.spin.trail
$@.spin.input.trail
62 urcu_free
: clean urcu_free_ltl run
63 cp .input.spin
$@.spin.input
64 -cp .input.spin.trail
$@.spin.input.trail
66 urcu_free_nested
: clean urcu_free_ltl urcu_free_nested_define run
67 cp .input.spin
$@.spin.input
68 -cp .input.spin.trail
$@.spin.input.trail
70 urcu_free_nested_define
:
71 cp urcu_free_nested.
define .input.
define
73 urcu_free_no_rmb
: clean urcu_free_ltl urcu_free_no_rmb_define run
74 cp .input.spin
$@.spin.input
75 -cp .input.spin.trail
$@.spin.input.trail
77 urcu_free_no_rmb_define
:
78 cp urcu_free_no_rmb.
define .input.
define
80 urcu_free_no_wmb
: clean urcu_free_ltl urcu_free_no_wmb_define run
81 cp .input.spin
$@.spin.input
82 -cp .input.spin.trail
$@.spin.input.trail
84 urcu_free_no_wmb_define
:
85 cp urcu_free_no_wmb.
define .input.
define
87 urcu_free_no_mb
: clean urcu_free_ltl urcu_free_no_mb_define run
88 cp .input.spin
$@.spin.input
89 -cp .input.spin.trail
$@.spin.input.trail
91 urcu_free_no_mb_define
:
92 cp urcu_free_no_mb.
define .input.
define
94 urcu_free_single_flip
: clean urcu_free_ltl urcu_free_single_flip_define run
95 cp .input.spin
$@.spin.input
96 -cp .input.spin.trail
$@.spin.input.trail
98 urcu_free_single_flip_define
:
99 cp urcu_free_single_flip.
define .input.
define
103 cat .input.
define >> pan.ltl
104 cat DEFINES
>> pan.ltl
105 spin
-f
"!(`cat urcu_free.ltl | grep -v ^//`)" >> pan.ltl
109 urcu_progress_writer
: clean urcu_progress_writer_ltl \
110 urcu_progress_writer_define run_weak_fair
111 cp .input.spin
$@.spin.input
112 -cp .input.spin.trail
$@.spin.input.trail
114 urcu_progress_writer_define
:
115 cp urcu_progress_writer.
define .input.
define
117 urcu_progress_writer_ltl
:
119 cat .input.
define > pan.ltl
120 cat DEFINES
>> pan.ltl
121 spin
-f
"!(`cat urcu_progress.ltl | grep -v ^//`)" >> pan.ltl
123 urcu_progress_reader
: clean urcu_progress_reader_ltl \
124 urcu_progress_reader_define run_weak_fair
125 cp .input.spin
$@.spin.input
126 -cp .input.spin.trail
$@.spin.input.trail
128 urcu_progress_reader_define
:
129 cp urcu_progress_reader.
define .input.
define
131 urcu_progress_reader_ltl
:
133 cat .input.
define > pan.ltl
134 cat DEFINES
>> pan.ltl
135 spin
-f
"!(`cat urcu_progress.ltl | grep -v ^//`)" >> pan.ltl
137 urcu_progress_writer_error
: clean urcu_progress_writer_error_ltl \
138 urcu_progress_writer_error_define run_weak_fair
139 cp .input.spin
$@.spin.input
140 -cp .input.spin.trail
$@.spin.input.trail
142 urcu_progress_writer_error_define
:
143 cp urcu_progress_writer_error.
define .input.
define
145 urcu_progress_writer_error_ltl
:
147 cat .input.
define > pan.ltl
148 cat DEFINES
>> pan.ltl
149 spin
-f
"!(`cat urcu_progress.ltl | grep -v ^//`)" >> pan.ltl
153 .
/pan
-a
-f
-v
-c1
-X
-m10000000
-w20
156 .
/pan
-a
-v
-c1
-X
-m10000000
-w20
159 gcc
-O2
-w
${CFLAGS} -o pan pan.c
161 pan.c
: pan.ltl
${SPINFILE}
162 cat .input.
define > .input.spin
163 cat DEFINES
>> .input.spin
164 cat
${SPINFILE} >> .input.spin
165 rm -f .input.spin.trail
166 spin
-a
-X
-N pan.ltl .input.spin
168 .PHONY
: clean default
distclean summary
170 rm -f pan
* trail.out .input.spin
* *.spin.trail .input.
define
172 rm -f
*.trail
*.input
*.log