From fe2a2cb34148e46e32cdcfbf100e38d9986082cd Mon Sep 17 00:00:00 2001 From: Son Ho Date: Fri, 8 Mar 2024 16:06:35 +0100 Subject: Make progress on propagating the changes --- compiler/ReorderDecls.ml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'compiler/ReorderDecls.ml') diff --git a/compiler/ReorderDecls.ml b/compiler/ReorderDecls.ml index 53c94ff4..f5443e03 100644 --- a/compiler/ReorderDecls.ml +++ b/compiler/ReorderDecls.ml @@ -5,11 +5,7 @@ open Pure (** The local logger *) let log = Logging.reorder_decls_log -type fun_id = { - def_id : FunDeclId.id; - lp_id : LoopId.id option; - rg_id : T.RegionGroupId.id option; -} +type fun_id = { def_id : FunDeclId.id; lp_id : LoopId.id option } [@@deriving show, ord] module FunIdOrderedType : OrderedType with type t = fun_id = struct @@ -43,11 +39,11 @@ let compute_body_fun_deps (e : texpression) : FunIdSet.t = | FunOrOp (Fun fid) -> ( match fid with | Pure _ -> () - | FromLlbc (fid, lp_id, rg_id) -> ( + | FromLlbc (fid, lp_id) -> ( match fid with | FunId (FAssumed _) -> () | TraitMethod (_, _, fid) | FunId (FRegular fid) -> - let id = { def_id = fid; lp_id; rg_id } in + let id = { def_id = fid; lp_id } in ids := FunIdSet.add id !ids)) end in @@ -71,7 +67,7 @@ let group_reorder_fun_decls (decls : fun_decl list) : (bool * fun_decl list) list = let module IntMap = MakeMap (OrderedInt) in let get_fun_id (decl : fun_decl) : fun_id = - { def_id = decl.def_id; lp_id = decl.loop_id; rg_id = decl.back_id } + { def_id = decl.def_id; lp_id = decl.loop_id } in (* Compute the list/set of identifiers *) let idl = List.map get_fun_id decls in -- cgit v1.2.3