Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frama-c
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pub
frama-c
Commits
2b82140b
Commit
2b82140b
authored
5 years ago
by
David Bühler
Committed by
Andre Maroneze
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[Eva] Adds a test of global variables initialized to INFINITY and NAN.
parent
c57e6016
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/float/oracle/special_floats.res.oracle
+12
-10
12 additions, 10 deletions
tests/float/oracle/special_floats.res.oracle
tests/float/special_floats.c
+3
-0
3 additions, 0 deletions
tests/float/special_floats.c
with
15 additions
and
10 deletions
tests/float/oracle/special_floats.res.oracle
+
12
−
10
View file @
2b82140b
...
...
@@ -5,12 +5,14 @@
[eva:initial-state] Values of globals at initialization
rand ∈ [--..--]
any_double ∈ [--..--]
global_infinity ∈ {inf}
global_nan ∈ NaN
[eva] computing for function nan_comparisons <- main.
Called from tests/float/special_floats.c:9
1
.
Called from tests/float/special_floats.c:9
4
.
[eva] Recording results for nan_comparisons
[eva] Done for function nan_comparisons
[eva] computing for function is_infinite <- main.
Called from tests/float/special_floats.c:9
2
.
Called from tests/float/special_floats.c:9
5
.
[eva] tests/float/special_floats.c:29: check 'true' got status valid.
[eva:alarm] tests/float/special_floats.c:30: Warning:
check 'false' got status invalid.
...
...
@@ -54,17 +56,17 @@
[eva] Recording results for is_infinite
[eva] Done for function is_infinite
[eva] computing for function macro_infinity <- main.
Called from tests/float/special_floats.c:9
3
.
[eva] tests/float/special_floats.c:7
1
: Frama_C_show_each_infinity: {inf}
[eva] tests/float/special_floats.c:7
2
: assertion got status valid.
Called from tests/float/special_floats.c:9
6
.
[eva] tests/float/special_floats.c:7
4
: Frama_C_show_each_infinity: {inf}
[eva] tests/float/special_floats.c:7
5
: assertion got status valid.
[eva] Recording results for macro_infinity
[eva] Done for function macro_infinity
[eva] computing for function macro_nan <- main.
Called from tests/float/special_floats.c:9
4
.
[eva] tests/float/special_floats.c:8
1
: Frama_C_show_each_nan: NaN
[eva] tests/float/special_floats.c:8
2
: assertion got status valid.
[eva] tests/float/special_floats.c:8
3
: assertion got status valid.
[eva] tests/float/special_floats.c:8
4
: assertion got status valid.
Called from tests/float/special_floats.c:9
7
.
[eva] tests/float/special_floats.c:8
4
: Frama_C_show_each_nan: NaN
[eva] tests/float/special_floats.c:8
5
: assertion got status valid.
[eva] tests/float/special_floats.c:8
6
: assertion got status valid.
[eva] tests/float/special_floats.c:8
7
: assertion got status valid.
[eva] Recording results for macro_nan
[eva] Done for function macro_nan
[eva] Recording results for main
...
...
This diff is collapsed.
Click to expand it.
tests/float/special_floats.c
+
3
−
0
View file @
2b82140b
...
...
@@ -65,6 +65,9 @@ void is_infinite () {
}
}
float
global_infinity
=
INFINITY
;
float
global_nan
=
NAN
;
/* Tests the C and logic macros INFINITY and HUGE_VAL. */
void
macro_infinity
()
{
float
infinity_f
=
INFINITY
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment