Skip to content

Allow analyses to not have their own bottom element but rely on Deadcode for that #1978

@michael-schwarz

Description

@michael-schwarz

For #1977, we would have liked for threadJoins to not have its own bottom element, as all threads being must-joined is equivalent to unreachability, which should be represented by the bottom element of the DeadcodeLifter.

However, MCP explicitly creates S.D.bot () abstract elements when an analysis does raise Deadcode, which means any analysis that raises deadcode has to have it's own bottom element.

let map_deadcode f xs =
let dead = ref false in
let one_el xs (n,(module S:MCPSpec),d) = try f xs (n,(module S:MCPSpec),d) :: xs with Deadcode -> dead:=true; (n,Obj.repr @@ S.D.bot ()) :: xs in
let ys = fold_left one_el [] xs in
List.rev ys, !dead

Getting rid of this would allow us to do some more simplications to the domain of the locals in threadJoins and potentially elsewhere.

Metadata

Metadata

Assignees

No one assigned

    Labels

    cleanupRefactoring, clean-up

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions