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
663b963b
Commit
663b963b
authored
1 year ago
by
Loïc Correnson
Committed by
David Bühler
3 months ago
Browse files
Options
Downloads
Patches
Plain Diff
[eva] fix sparse sets & unspecified seq.
parent
b8c7e1d4
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/plugins/eva/utils/annot.ml
+12
-11
12 additions, 11 deletions
src/plugins/eva/utils/annot.ml
with
12 additions
and
11 deletions
src/plugins/eva/utils/annot.ml
+
12
−
11
View file @
663b963b
...
@@ -97,17 +97,18 @@ let imax (exp : Exp.exp) (ival : Ival.t) : pred =
...
@@ -97,17 +97,18 @@ let imax (exp : Exp.exp) (ival : Ival.t) : pred =
|
None
->
True
|
None
->
True
|
Some
k
->
Eval
Exp
.(
exp
<=
of_integer
k
)
|
Some
k
->
Eval
Exp
.(
exp
<=
of_integer
k
)
let
irange
=
function
let
sparse
=
function
|
[
_
]
|
[]
->
false
|
[]
->
false
|
[
_
]
->
true
|
x
::
xs
->
|
x
::
xs
->
let
rec
continuous
x
=
function
let
rec
continuous
x
=
function
|
[]
->
true
|
[]
->
true
|
y
::
ys
->
Z
.
equal
(
Z
.
succ
x
)
y
&&
continuous
y
ys
|
y
::
ys
->
Z
.
equal
(
Z
.
succ
x
)
y
&&
continuous
y
ys
in
continuous
x
xs
in
not
@@
continuous
x
xs
let
ival
(
exp
:
Exp
.
exp
)
(
ival
:
Ival
.
t
)
:
pred
=
let
ival
(
exp
:
Exp
.
exp
)
(
ival
:
Ival
.
t
)
:
pred
=
match
Ival
.
project_small_set
ival
with
match
Ival
.
project_small_set
ival
with
|
Some
vs
when
not
@@
irang
e
vs
->
|
Some
vs
when
spars
e
vs
->
List
.
fold_left
(
fun
w
v
->
por
w
(
iequal
exp
v
))
False
vs
List
.
fold_left
(
fun
w
v
->
por
w
(
iequal
exp
v
))
False
vs
|
_
->
pand
(
imin
exp
ival
)
(
imax
exp
ival
)
|
_
->
pand
(
imin
exp
ival
)
(
imax
exp
ival
)
...
@@ -231,14 +232,14 @@ class evaluator request =
...
@@ -231,14 +232,14 @@ class evaluator request =
method
!
vstmt_aux
stmt
=
method
!
vstmt_aux
stmt
=
match
stmt
.
skind
with
match
stmt
.
skind
with
(* Branching expressions *)
|
If
(
e
,_,_,_
)
|
Switch
(
e
,_,_,_
)
->
self
#
visit_expr
e
;
SkipChildren
(* Instructions *)
(* Instructions *)
|
Instr
_
|
Return
_
|
Goto
_
|
Break
_
|
Continue
_
|
Instr
_
|
Return
_
->
DoChildren
|
UnspecifiedSequence
_
->
DoChildren
(* Branching expressions *)
(* Blocks *)
|
If
(
e
,_,_,_
)
|
Switch
(
e
,_,_,_
)
->
self
#
visit_expr
e
;
SkipChildren
|
Loop
_
|
Block
_
|
Throw
_
|
TryCatch
_
|
TryFinally
_
|
TryExcept
_
(* Blocks & Jumps *)
|
Goto
_
|
Break
_
|
Continue
_
|
Loop
_
|
Block
_
|
UnspecifiedSequence
_
|
Throw
_
|
TryCatch
_
|
TryFinally
_
|
TryExcept
_
->
SkipChildren
->
SkipChildren
end
end
...
...
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