Skip to content

Commit 868636f

Browse files
committed
Merge branch 'topic/fsf_merge_269/20250903' into 'fsf'
Synchronize with GNAT Issue: eng/spark/spark2014#269 See merge request eng/spark/why3!96
2 parents 9c197b9 + f2505af commit 868636f

File tree

2,781 files changed

+112348
-85552
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,781 files changed

+112348
-85552
lines changed

.gitattributes

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,13 @@ src/config.sh.in binary
1818
/.gitlab-ci.yml export-ignore
1919
/.mailmap export-ignore
2020
/check.sh export-ignore
21-
/DEVELOPER.readme export-ignore
22-
/ROADMAP export-ignore
23-
/TODO export-ignore
2421

2522
/bench/encoding/ export-ignore
2623
/examples_in_progress/ export-ignore
2724
/misc/ export-ignore
2825
/opam/ export-ignore
2926
/tests/ export-ignore
3027

31-
/src/trywhy3/Makefile export-ignore
32-
3328
why3session.xml merge=ours
3429
why3shapes.gz merge=ours
3530
*.png diff=image

.github/workflows/workflow.yml

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: Main workflow
22

3-
43
on:
54
pull_request:
65
push:
6+
workflow_dispatch:
77
schedule:
88
# Prime the caches every Monday
99
- cron: 0 1 * * MON
@@ -16,25 +16,27 @@ jobs:
1616
fail-fast: false
1717
matrix:
1818
os:
19-
- macos-latest
20-
- ubuntu-latest
21-
- windows-latest
19+
- macos-13
20+
- macos-14
21+
- ubuntu-22.04
22+
- windows-2019
23+
- ubuntu-22.04-arm
2224
ocaml-compiler:
23-
- "4.11.2"
25+
- "4.13.1"
2426

2527
runs-on: ${{ matrix.os }}
2628

2729
steps:
2830
- name: Checkout tree
29-
uses: actions/checkout@v3
31+
uses: actions/checkout@v4
3032

31-
- name: Set up Python 3.10
33+
- name: Set up Python 3.12
3234
uses: actions/setup-python@v4
3335
with:
34-
python-version: "3.10"
36+
python-version: "3.12"
3537

3638
- name: Set-up OCaml ${{ matrix.ocaml-compiler }}
37-
uses: ocaml/setup-ocaml@v2
39+
uses: ocaml/setup-ocaml@v3
3840
with:
3941
ocaml-compiler: ${{ matrix.ocaml-compiler }}
4042

@@ -43,7 +45,7 @@ jobs:
4345
opam exec -- bash ./fsf_build.sh staging
4446
4547
- name: Upload package
46-
uses: actions/upload-artifact@v3
48+
uses: actions/upload-artifact@v4
4749
with:
4850
name: why3pack-${{matrix.os}}
4951
path: staging

.gitignore

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@ why3.conf
4747
/src/jessie/.merlin
4848
/_build
4949
/public
50-
/bench/z3_nombqi/sessions
51-
/bench/alt_ergo_smt/sessions
5250

5351
# /bench/
5452
/bench/extraction/test/test.*
5553
/bench/extraction/test/main.opt
54+
/bench/extraction/interface1/interface1.*
55+
/bench/extraction/interface1/main.opt
5656
/bench/programs/good/booleans/
5757
/bench/programs/good/exceptions/
5858
/bench/programs/good/for/
@@ -68,12 +68,21 @@ why3.conf
6868
/bench/check-ce/petiot2018/*.out
6969
/bench/check-ce/petiot2018/experiments/
7070
/bench/parsing/bad/*.out
71+
#/bench/alt_ergo_smt/sessions
72+
/bench/alt_ergo_smt2/sessions
73+
/bench_z3_computerdiv
74+
/bench/z3_nombqi/bench_z3_nombqi/sessions
75+
76+
7177
/examples/tests/*.out
78+
/bench/java/Makefile
79+
/bench/java/generated
7280

7381
# /bin/
7482
/bin/why3.byte
7583
/bin/why3.opt
7684
/bin/why3
85+
/bin/why3.exe
7786
/bin/isabelle_client.opt
7887
/bin/isabelle_client.byte
7988
/bin/isabelle_client
@@ -92,6 +101,7 @@ why3.conf
92101
/doc/stdlibdoc/
93102
/doc/_build
94103
/doc/.doctrees/
104+
/doc/javaexamples/Makefile
95105

96106
/public/
97107

@@ -177,6 +187,7 @@ pvsbin/
177187
/src/util/mlmpfr_wrapper.ml
178188
/src/util/mysexplib.ml
179189
/src/util/ppx_debug_optim
190+
/src/util/ppx_debug_optim.exe
180191

181192
# /src/session
182193
/src/session/xml.ml
@@ -217,6 +228,12 @@ pvsbin/
217228
/plugins/ada_terms/ada_lexer.ml
218229
/plugins/ada_terms/ada_parser.ml
219230
/plugins/ada_terms/ada_parser.mli
231+
/plugins/ada_terms/ada_parser.conflicts
232+
# /plugins/coma/
233+
/plugins/coma/coma_lexer.ml
234+
/plugins/coma/coma_parser.ml
235+
/plugins/coma/coma_parser.mli
236+
/plugins/coma/coma_parser.conflicts
220237

221238
# /plugins/cfg/
222239
/plugins/cfg/cfg_lexer.ml
@@ -270,6 +287,7 @@ pvsbin/
270287
/examples/*/*/*.tex
271288
/examples/*/*/*/*.tex
272289
/examples/split_string/split_string.ml
290+
/examples/residual/residual.ml
273291
/examples/vstte10_max_sum/vstte10_max_sum.ml
274292
/examples/euler001/euler001.ml
275293
/examples/sudoku/sudoku.ml

.gitlab-ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ stages:
66
- deploy
77

88
variables:
9-
BUILD_IMAGE: "$CI_REGISTRY_IMAGE:ci-master-2023-11-13"
9+
BUILD_IMAGE: "$CI_REGISTRY_IMAGE:ci-master-2025-05-20"
1010
SPHINX_IMAGE: "$CI_REGISTRY_IMAGE:ci-sphinx"
1111
GIT_CLEAN_FLAGS: "-ffdxq"
1212

@@ -15,13 +15,13 @@ build-image:
1515
image: docker
1616
script:
1717
- docker login -u "$CI_REGISTRY_USER" -p "$CI_JOB_TOKEN" "$CI_REGISTRY"
18-
- if docker pull "$BUILD_IMAGE"; then echo "Image already exists!"; exit 1; fi
18+
- if docker manifest inspect "$BUILD_IMAGE"; then echo "Image already exists!"; exit 0; fi
1919
- docker build --force-rm -t "$BUILD_IMAGE" - < misc/Dockerfile.build
2020
- docker push "$BUILD_IMAGE"
2121
- docker rmi "$BUILD_IMAGE"
22-
only:
23-
variables:
24-
- $NEW_BUILD_IMAGE
22+
rules:
23+
- changes:
24+
- misc/Dockerfile.build
2525
tags:
2626
- large
2727

.mailmap

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ Paul Bonnot <[email protected]> <[email protected]>
1111
1212
Martin Clochard <[email protected]> <martin@pc-stagiaire.(none)>
1313
Martin Clochard <[email protected]> <clochard@MC-MacBook.(none)>
14+
Loïc Correnson <[email protected]>
1415
Sylvain Dailler <[email protected]>
1516
Sylvain Dailler <[email protected]> <sdailler@[email protected]>
1617
@@ -19,12 +20,13 @@ Sylvain Dailler <[email protected]> <[email protected]>
1920
2021
2122
Diego Diverio <[email protected]>
22-
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
23-
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
24-
Jean-Christophe Filliâtre <[email protected]> <jc@evariste.(none)>
25-
Jean-Christophe Filliâtre <[email protected]> <jc@gemini.(none)>
26-
Jean-Christophe Filliâtre <[email protected]> <filliatr@balrog.(none)>
27-
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
23+
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
24+
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
25+
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
26+
Jean-Christophe Filliâtre <[email protected]> <jc@evariste.(none)>
27+
Jean-Christophe Filliâtre <[email protected]> <jc@gemini.(none)>
28+
Jean-Christophe Filliâtre <[email protected]> <filliatr@balrog.(none)>
29+
Jean-Christophe Filliâtre <[email protected]> <[email protected]>
2830
2931
3032
Léon Gondelman <[email protected]>
@@ -53,7 +55,10 @@ Thi-Minh-Tuyen Nguyen <[email protected]> <nguyenthiminhtuyen@minht
5355
Thi-Minh-Tuyen Nguyen <[email protected]> <[email protected]>
5456
5557
56-
Paul Patault <[email protected]>
58+
Paul Patault <[email protected]>
59+
60+
61+
5762
5863
5964

.merlin.in

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ S plugins/transform
2222
S plugins/tptp
2323
S plugins/python
2424
S plugins/gnat_json
25+
S plugins/coma
2526

2627
B src/util
2728
B src/core
@@ -47,6 +48,7 @@ B plugins/transform
4748
B plugins/tptp
4849
B plugins/python
4950
B plugins/gnat_json
51+
B plugins/coma
5052
B lib/why3
5153

52-
PKG @RELIB@ unix num dynlink yojson @ZIPLIB@ @LABLGTKPKG@ @META_OCAMLGRAPH@ @JSOFOCAMLPKG@ @MLMPFR@ @INFERPKG@ @SEXPLIB@
54+
PKG @RELIB@ unix zarith dynlink @ZIPLIB@ @LABLGTKPKG@ @META_OCAMLGRAPH@ @JSOFOCAMLPKG@ @MLMPFR@ @INFERPKG@ @SEXPLIB@

CHANGES.md

Lines changed: 56 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,67 @@
11
:x: marks a potential source of incompatibility
22

3+
Version 1.8.0, December 11, 2024
4+
--------------------------------
5+
36
Standard library
47
* new library `ufloat`: unbounded floating-point numbers
8+
* new library `coma`: standard library of the plugin Coma
9+
* additional operators in library `fmap`
10+
* added 16-bit integers in `mach/int`
11+
* added a program equality in `bool`
12+
* added meta annotations for "unused dependencies", which usually
13+
improve proof automation but very rarely may lose some proofs :x:
14+
* made most `(==)` operators trigger the `extensionality` transformation :x:
515

616
Core
7-
* extended notion of strategies: goal-oriented strategies
17+
* records and range types now have some predefined symbol `foo'eq`
18+
and some axiom `foo'inj` to express injectivity. See manual
19+
Section "The WhyML Language Reference/Record Types".
20+
21+
Transformations
22+
* new transformation `extensionality` to help with equality proofs
823

924
Plugins
10-
* new goal-oriented strategy `forward_propagation` to automatically
11-
propagate rounding errors in formulas involving unbounded
12-
floats. See examples in `examples/numeric`
25+
* new task-oriented strategy `forward_propagation` to automatically
26+
propagate rounding errors
27+
* new frontend plugin "Coma"
28+
29+
Provers
30+
* Alt-Ergo FPA requires Alt-Ergo >= 2.5.4
31+
* drop support for versions of Coq < 8.16
32+
* support for Coq 8.19 (released Jan 24, 2024)
33+
* support for Z3 4.13 (released Mar 7, 2024)
34+
* support for CVC5 1.2 (released Aug 8, 2024)
35+
* support for Coq 8.20 (released Sep 11, 2024)
36+
* support for Alt-Ergo 2.6 (released Sep 24, 2024)
37+
38+
Tools
39+
* `why3 prove`: dropped option `--json-model-values` :x:
40+
* `why3 execute`: added option `--rac-memlimit`;
41+
the `--rac-prover` option no longer supports specifying a time limit
42+
and memory limit :x:
43+
* `why3 pp`: the LaTeX output now shows algebraic types and logic definitions
44+
* `why3 pp`: dropped option `--kind` :x:
45+
46+
Extraction
47+
* added support for Java, see Manual, Section "Executing WhyML Programs"
48+
* improved extraction to C: floating-point numbers, global variables
49+
50+
API
51+
* changed how resource limits are specified :x
52+
* renamed type `effect` to `effekt` for compatibility with OCaml 5.3 :x
53+
54+
Miscellaneous
55+
* dependency on OCaml library `num` was replaced by `zarith`
56+
57+
Version 1.7.2, April 18, 2024
58+
-----------------------------
59+
60+
Bug fixes
61+
* restored the legacy shortcut for Alt-Ergo 2.5
62+
* fixed various bugs in the lexer of `why3 doc`
63+
* made prover detection more reliable when paths need escaping
64+
1365

1466
Version 1.7.1, January 20, 2024
1567
-------------------------------

CONTRIBUTING.md

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -16,22 +16,21 @@ Contributing to Why3
1616

1717
Welcome, contributor, to the Why3 verification platform!
1818

19-
If you wish to contribute, open an issue or otherwise interact with our [Gitlab](https://gitlab.inria.fr/why3/why3), you will need to have an INRIA account.
20-
External users can file bug reports using our [mailing list](mailto:why3-club@lists.gforge.inria.fr). We're sorry for the inconvenience.
19+
If you wish to contribute, open an issue or otherwise interact with our [Gitlab](https://gitlab.inria.fr/why3/why3), you will need to have an Inria account.
20+
External users can file bug reports using our [mailing list](mailto:why3-club@groupes.renater.fr). We are sorry for the inconvenience.
2121

2222
# Building
2323

24-
To build Why3 locally you will need a functional installation of OCaml (at least 4.08), `menhir`, `num` and `autoconf`. You can set up your developer build using the following commands:
24+
To build Why3 locally you will need a functional installation of OCaml (at
25+
least 4.09), `menhir`, `zarith`, and `autoconf`. You can set up your developer
26+
build using the following commands:
2527

2628
```
2729
autoconf
2830
./configure --enable-local # stores the built binaries under ./bin
2931
make
3032
```
3133

32-
Note: there can be issues around Num, recall and document those.
33-
34-
3534
## Building Documentation
3635

3736
Building the Why3 documentation requires an installation of Sphinx, as well as the `sphinxcontrib-bibtex` package. If your package manager does not have up to date versions of these packages, or they otherwise fail to install, you can install them using `pip3` as follows:
@@ -52,12 +51,13 @@ To execute the Why3 tests run:
5251

5352
## Running specific tests
5453

55-
You may run specific classes of tests through the `-only` flag, the full listing of classes can be obtained from `-help`.
54+
You may run specific classes of tests by specifying them on the command line.
55+
The full listing of classes can be obtained from `-help`.
5656

57-
For example to run the 'good file' tests, use:
57+
For example to run the 'good file' and 'bad file' tests, use:
5858

5959
```
60-
./bench/bench -only goodfiles
60+
./bench/bench goodfiles badfiles
6161
```
6262

6363
## Gitlab CI
@@ -91,6 +91,7 @@ While code review is not strictly enforced it is *highly* encouraged.
9191
## Commits
9292

9393
Every commit should:
94+
9495
- Compile, and pass CI.
9596
- Be stripped of trailing whitespace.
9697
- Use appropriate indentation.
@@ -118,6 +119,7 @@ So, as mentioned above, an example of a `raw_model_parser`, for SMTv2
118119
solvers, is `Smtv2_model_parser.parse`, which makes use of another
119120
data type `Smtv2_model_defs.function_def`. This specific
120121
`Smtv2_model_parser.parse` function proceeds in 2 main phases:
122+
121123
- first transforms the textual output into an S-expression,
122124
- then the latter S-expression is transformed into a
123125
`Model_parser.model_element list`.
@@ -130,7 +132,7 @@ function that recovers the original Why3 name from the
130132
type `Printer.printer_args`. The field `printing_info` is supposed to
131133
be modified in place by printers.
132134

133-
# profiling
135+
# Profiling
134136

135137
Profiling execution of Why3 can be performed out-of-the-box using
136138
under Linux using `perf`. A typical usage is
@@ -139,12 +141,18 @@ under Linux using `perf`. A typical usage is
139141
perf record --call-graph=dwarf -- why3 command <options> <arguments>
140142
perf report
141143
```
142-
Note that perf may complain you don't have enough priviledges. A typical configuration change required is, for the session only, execute
144+
145+
Note that `perf` may complain you don't have enough privileges. To change
146+
your configuration for the current session only, execute
147+
143148
```
144149
sysctl kernel.perf_event_paranoid=2
145150
```
151+
146152
or, to make this setting permanent, add the line
153+
147154
```
148155
kernel.perf_event_paranoid = 2
149156
```
150-
to `sys/sysctl.conf`.
157+
158+
to `/etc/sysctl.conf`.

0 commit comments

Comments
 (0)