From 2408dd1aecf8d8c3bfd3b24a65f7f57cf602cb10 Mon Sep 17 00:00:00 2001 From: Léo Gourdin Date: Thu, 20 May 2021 11:58:40 +0200 Subject: Changing to an opaq record in BTL info, this is a broken commit --- scheduling/PrintBTL.ml | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'scheduling/PrintBTL.ml') diff --git a/scheduling/PrintBTL.ml b/scheduling/PrintBTL.ml index 4b14d28e..23ad91f6 100644 --- a/scheduling/PrintBTL.ml +++ b/scheduling/PrintBTL.ml @@ -5,6 +5,7 @@ open Maps open AST open BTL open PrintAST +open BTLaux (* Printing of BTL code *) @@ -43,24 +44,24 @@ let rec print_iblock pp is_rec pref ib = fprintf pp "Bstore: %s[%a] = %a\n" (name_of_chunk chunk) (PrintOp.print_addressing reg) (addr, args) reg src - | BF (Bcall (sg, fn, args, res, s, _)) -> + | BF (Bcall (sg, fn, args, res, s), _) -> print_pref pp pref; fprintf pp "Bcall: %a = %a(%a)\n" reg res ros fn regs args; print_succ pp s - | BF (Btailcall (sg, fn, args, _)) -> + | BF (Btailcall (sg, fn, args), _) -> print_pref pp pref; fprintf pp "Btailcall: %a(%a)\n" ros fn regs args - | BF (Bbuiltin (ef, args, res, s, _)) -> + | BF (Bbuiltin (ef, args, res, s), _) -> print_pref pp pref; fprintf pp "Bbuiltin: %a = %s(%a)\n" (print_builtin_res reg) res (name_of_external ef) (print_builtin_args reg) args; print_succ pp s - | Bcond (cond, args, ib1, ib2, info, _) -> + | Bcond (cond, args, ib1, ib2, iinfo) -> print_pref pp pref; fprintf pp "Bcond: (%a) (prediction: %s)\n" (PrintOp.print_condition reg) (cond, args) - (match info with + (match iinfo.pcond with | None -> "none" | Some true -> "branch" | Some false -> "fallthrough"); @@ -71,20 +72,20 @@ let rec print_iblock pp is_rec pref ib = fprintf pp "%sifnot = [\n" pref; if is_rec then print_iblock pp is_rec pref' ib2 else fprintf pp "...\n"; fprintf pp "%s]\n" pref - | BF (Bjumptable (arg, tbl, _)) -> + | BF (Bjumptable (arg, tbl), _) -> let tbl = Array.of_list tbl in print_pref pp pref; fprintf pp "Bjumptable: (%a)\n" reg arg; for i = 0 to Array.length tbl - 1 do fprintf pp "\t\tcase %d: goto %d\n" i (P.to_int tbl.(i)) done - | BF (Breturn (None, _)) -> + | BF (Breturn None, _) -> print_pref pp pref; fprintf pp "Breturn\n" - | BF (Breturn (Some arg, _)) -> + | BF (Breturn (Some arg), _) -> print_pref pp pref; fprintf pp "Breturn: %a\n" reg arg - | BF (Bgoto s) -> + | BF (Bgoto s, _) -> print_pref pp pref; fprintf pp "Bgoto: %d\n" (P.to_int s) | Bseq (ib1, ib2) -> -- cgit