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
e6c234b9
Commit
e6c234b9
authored
3 years ago
by
David Bühler
Browse files
Options
Downloads
Patches
Plain Diff
[Scope] Minor simplifications.
parent
32566403
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
src/plugins/scope/datascope.ml
+1
-4
1 addition, 4 deletions
src/plugins/scope/datascope.ml
src/plugins/scope/zones.ml
+1
-2
1 addition, 2 deletions
src/plugins/scope/zones.ml
with
2 additions
and
6 deletions
src/plugins/scope/datascope.ml
+
1
−
4
View file @
e6c234b9
...
@@ -85,9 +85,6 @@ let get_writes stmt lval =
...
@@ -85,9 +85,6 @@ let get_writes stmt lval =
before
stmt
|>
eval_address
lval
|>
as_zone
~
access
:
Write
|>
before
stmt
|>
eval_address
lval
|>
as_zone
~
access
:
Write
|>
default
Locations
.
Zone
.
bottom
)
default
Locations
.
Zone
.
bottom
)
let
get_reads
stmt
lval
=
Eva
.
Results
.(
before
stmt
|>
lval_deps
lval
)
(** Add to [stmt] to [lmap] for all the locations modified by the statement.
(** Add to [stmt] to [lmap] for all the locations modified by the statement.
* Something to do only for calls and assignments.
* Something to do only for calls and assignments.
* *)
* *)
...
@@ -410,7 +407,7 @@ let is_modified_by_edge kf z s1 s2 =
...
@@ -410,7 +407,7 @@ let is_modified_by_edge kf z s1 s2 =
* @raise Kernel_function.No_Definition if [kf] has no definition
* @raise Kernel_function.No_Definition if [kf] has no definition
*)
*)
let
get_data_scope_at_stmt
kf
stmt
lval
=
let
get_data_scope_at_stmt
kf
stmt
lval
=
let
zone
=
get_reads
stmt
lval
in
let
zone
=
Eva
.
Results
.(
before
stmt
|>
lval
_deps
lval
)
in
let
allstmts
,
info
=
compute
kf
in
let
allstmts
,
info
=
compute
kf
in
let
modif_stmts
=
InitSid
.
find
info
zone
in
let
modif_stmts
=
InitSid
.
find
info
zone
in
let
modifs_edge
=
is_modified_by_edge
kf
zone
in
let
modifs_edge
=
is_modified_by_edge
kf
zone
in
...
...
This diff is collapsed.
Click to expand it.
src/plugins/scope/zones.ml
+
1
−
2
View file @
e6c234b9
...
@@ -154,8 +154,7 @@ let process_one_call data stmt lvaloption froms =
...
@@ -154,8 +154,7 @@ let process_one_call data stmt lvaloption froms =
let
process_call
data_after
stmt
lvaloption
funcexp
args
_loc
=
let
process_call
data_after
stmt
lvaloption
funcexp
args
_loc
=
let
funcexp_dpds
=
Eva
.
Results
.(
before
stmt
|>
expr_deps
funcexp
)
let
funcexp_dpds
=
Eva
.
Results
.(
before
stmt
|>
expr_deps
funcexp
)
and
called_functions
=
and
called_functions
=
Eva
.
Results
.(
before
stmt
|>
eval_callee
funcexp
)
|>
Eva
.
Results
.(
before
stmt
|>
eval_callee
funcexp
|>
default
[]
)
Result
.
value
~
default
:
[]
in
in
let
used
,
data
=
let
used
,
data
=
try
try
...
...
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