hash table comment fix.
[urcu.git] / formal-model / urcu-nosched-model / result-signal-over-writer / result-signal-over-writer / Makefile
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.
5 #
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.
10 #
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.
14 #
15 # Copyright (C) Mathieu Desnoyers, 2009
16 #
17 # Authors: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
18
19 #CFLAGS=-DSAFETY
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
23
24 #liveness
25 #CFLAGS=-DHASH64 -DCOLLAPSE -DMA=88
26 CFLAGS=-DHASH64
27
28 SPINFILE=urcu.spin
29
30 default:
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
42 make summary
43
44 #show trail : spin -v -t -N pan.ltl input.spin
45 # after each individual make.
46
47 summary:
48 @echo
49 @echo "Verification summary"
50 @grep errors: *.log
51
52 asserts: clean
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
61
62 urcu_free: clean urcu_free_ltl run
63 cp .input.spin $@.spin.input
64 -cp .input.spin.trail $@.spin.input.trail
65
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
69
70 urcu_free_nested_define:
71 cp urcu_free_nested.define .input.define
72
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
76
77 urcu_free_no_rmb_define:
78 cp urcu_free_no_rmb.define .input.define
79
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
83
84 urcu_free_no_wmb_define:
85 cp urcu_free_no_wmb.define .input.define
86
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
90
91 urcu_free_no_mb_define:
92 cp urcu_free_no_mb.define .input.define
93
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
97
98 urcu_free_single_flip_define:
99 cp urcu_free_single_flip.define .input.define
100
101 urcu_free_ltl:
102 touch .input.define
103 cat .input.define >> pan.ltl
104 cat DEFINES >> pan.ltl
105 spin -f "!(`cat urcu_free.ltl | grep -v ^//`)" >> pan.ltl
106
107 # Progress checks
108
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
113
114 urcu_progress_writer_define:
115 cp urcu_progress_writer.define .input.define
116
117 urcu_progress_writer_ltl:
118 touch .input.define
119 cat .input.define > pan.ltl
120 cat DEFINES >> pan.ltl
121 spin -f "!(`cat urcu_progress.ltl | grep -v ^//`)" >> pan.ltl
122
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
127
128 urcu_progress_reader_define:
129 cp urcu_progress_reader.define .input.define
130
131 urcu_progress_reader_ltl:
132 touch .input.define
133 cat .input.define > pan.ltl
134 cat DEFINES >> pan.ltl
135 spin -f "!(`cat urcu_progress.ltl | grep -v ^//`)" >> pan.ltl
136
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
141
142 urcu_progress_writer_error_define:
143 cp urcu_progress_writer_error.define .input.define
144
145 urcu_progress_writer_error_ltl:
146 touch .input.define
147 cat .input.define > pan.ltl
148 cat DEFINES >> pan.ltl
149 spin -f "!(`cat urcu_progress.ltl | grep -v ^//`)" >> pan.ltl
150
151
152 run_weak_fair: pan
153 ./pan -a -f -v -c1 -X -m10000000 -w20
154
155 run: pan
156 ./pan -a -v -c1 -X -m10000000 -w20
157
158 pan: pan.c
159 gcc -O2 -w ${CFLAGS} -o pan pan.c
160
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
167
168 .PHONY: clean default distclean summary
169 clean:
170 rm -f pan* trail.out .input.spin* *.spin.trail .input.define
171 distclean:
172 rm -f *.trail *.input *.log
This page took 0.031834 seconds and 4 git commands to generate.