Closed sim642 closed 2 months ago
I think the solution to get availability on OS X back is to simply skip these if the machine is not x86 and produce a warning when float domains are enabled on a non-x86 machine. Otherwise, we are probably excluding too many potential users or making it difficult for them without reason.
I have checked analyzer
just now (latest commit), it does not fail any test on M2 (Apple M2 Pro, MBP 16" 2023):
kromanov1@MM2M0W0HWL analyzer % make test
No errors :)
I had to pin cil
to the latest commit.
It is very possible that I did something wrong, so please let me know how to test properly.
The failures were in unit tests, not regression tests. dune runtest
should run them all.
kromanov1@MM2M0W0HWL analyzer % dune runtest
In file included from goblint.c:1:
../include/goblint.h:5:6: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C2x, conflicting with a subsequent definition [-Wdeprecated-non-prototype]
void __goblint_assume_join(/* pthread_t thread */); // undeclared argument to avoid pthread.h interfering with Linux kernel headers
^
goblint.c:19:6: note: conflicting prototype is here
void __goblint_assume_join(pthread_t thread) {
^
1 warning generated.
..........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................
Ran: 2986 tests in: 32.63 seconds.
OK
No errors :)2 tutorials/first-extendturnitrnt-maineaded-betterpivnt-0ccessble
Ran just right now. System:
kromanov1@MM2M0W0HWL analyzer % uname -a
Darwin MM2M0W0HWL 23.3.0 Darwin Kernel Version 23.3.0: Wed Dec 20 21:31:00 PST 2023; root:xnu-10002.81.5~7/RELEASE_ARM64_T6020 arm64
Somehow these didn't seem to be an issue for the 2.4.0 release. Although maybe they only were for Linux arm64, not MacOS, and we fail there for other reasons.
Version 2.0.0 release on opam reveals the following float domain test failures on arm64:
Full log
``` # ============================================================================== # Error: :1:floatDomainTest:3:float_interval_qcheck64:6:test_FI_lt_xor_ge. # # File "/home/opam/.opam/4.14/.opam-switch/build/goblint.2.0.0/_build/default/unittest/oUnit--builder#01.log", line 181, characters 1-1: # Error: :1:floatDomainTest:3:float_interval_qcheck64:6:test_FI_lt_xor_ge (in the log). # # File "src/core/QCheck2.ml", line 1815, characters 1-1: # Error: :1:floatDomainTest:3:float_interval_qcheck64:6:test_FI_lt_xor_ge (in the code). # # # test `test_FI_lt_xor_ge` failed on ≥ 1 cases:Thus, I have disabled Goblint on arm64, but that's quite bad since it means we cannot run on Apple M1.
My hypothesis is that our fabulous float domain C stubs are the reason for these qcheck failures on
double
. Using MPFR for float abstraction would avoid such architecture-dependent floating-point issues that we have no control over. Longer discussion in https://github.com/goblint/analyzer/pull/761#discussion_r899993066.