Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
bclement-ocp committed Jun 13, 2024
1 parent d4eeae8 commit 55b910f
Show file tree
Hide file tree
Showing 7 changed files with 1,674 additions and 1,067 deletions.
6 changes: 3 additions & 3 deletions src/lib/reasoners/adt_rel.ml
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ module Domains = struct
with Not_found ->
Domain.unknown (X.type_info r)

let add r t =
let init r t =
match Th.embed r with
| Alien _ when not (MX.mem r t.domains) ->
(* We have to add a default domain if the key `r` is not in map in order
Expand Down Expand Up @@ -226,7 +226,7 @@ module Domains = struct
let t = remove r t in
tighten nr nd t

| exception Not_found -> add nr t
| exception Not_found -> init nr t

(* [propagate f a t] iterates on all the changed domains of [t] since the
last call of [propagate]. The list of changed domains is flushed after
Expand Down Expand Up @@ -421,7 +421,7 @@ let add r uf domains =
| Ty.Tadt _ ->
Debug.add r;
let rr, _ = Uf.find_r uf r in
Domains.add rr domains
Domains.init rr domains
| _ ->
domains

Expand Down
2 changes: 1 addition & 1 deletion src/lib/reasoners/bitlist.ml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ let pp ppf { bits_set; bits_unk; ex } =
Fmt.pf ppf "(0)"
end;
let width = Z.numbits bits_unk in
for i = width - 1 downto 0 do
for i = width downto 0 do
if Z.testbit bits_set i then
Fmt.pf ppf "1"
else if Z.testbit bits_unk i then
Expand Down
Loading

0 comments on commit 55b910f

Please sign in to comment.