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
ae257fee
Commit
ae257fee
authored
4 months ago
by
Cécile Ruet-Cros
Browse files
Options
Downloads
Patches
Plain Diff
[region] footprint
parent
2d7c68c8
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/region/Region.mli
+1
-1
1 addition, 1 deletion
src/plugins/region/Region.mli
src/plugins/region/memory.ml
+5
-5
5 additions, 5 deletions
src/plugins/region/memory.ml
with
6 additions
and
6 deletions
src/plugins/region/Region.mli
+
1
−
1
View file @
ae257fee
...
...
@@ -137,5 +137,5 @@ val field : map -> node -> fieldinfo -> node
(** Unormalized. @raises Not_found *)
val
index
:
map
->
node
->
typ
->
node
(**
Un
ormalized. *)
(**
N
ormalized
list of leaf nodes
. *)
val
footprint
:
map
->
node
->
node
list
This diff is collapsed.
Click to expand it.
src/plugins/region/memory.ml
+
5
−
5
View file @
ae257fee
...
...
@@ -468,17 +468,17 @@ let field (m: map) (r: node) (fd: fieldinfo) : node =
let
footprint
(
m
:
map
)
(
r
:
node
)
:
node
list
=
try
let
visited
=
ref
SNode
.
empty
(* set of visited
&
normalized nodes *)
in
let
lea
f
s
=
ref
[]
(*
lsit of
lea
f
s *)
in
let
visited
=
ref
SNode
.
empty
(* set of visited
&
normalized nodes *)
in
let
lea
ve
s
=
ref
[]
(*
returned
lea
ve
s *)
in
let
rec
visit
(
r
:
node
)
:
unit
=
let
n
=
node
m
r
in
(* normalized node *)
if
SNode
.
mem
n
!
visited
then
()
else
let
_
=
visited
:=
SNode
.
add
n
!
visited
in
let
()
=
visited
:=
SNode
.
add
n
!
visited
in
let
rg
=
(* raises Not_found *)
Ufind
.
get
m
.
store
n
in
match
rg
.
clayout
with
|
Compound
(
_
,
_
,
range
)
->
Ranges
.
iter
visit
range
|
Blob
|
Cell
(
_
,_
)
->
lea
f
s
:=
n
::
!
lea
f
s
in
visit
r
;
!
lea
f
s
|
Blob
|
Cell
(
_
,_
)
->
lea
ve
s
:=
n
::
!
lea
ve
s
in
visit
r
;
!
lea
ve
s
with
Not_found
->
[]
let
index
(
m
:
map
)
(
r
:
node
)
(
ty
:
typ
)
:
node
=
...
...
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