Commits

camlspotter committed c7d5914

debug

  • Participants
  • Parent commits e916202

Comments (0)

Files changed (1)

     fun (v : unit m) ->
       incr cntr;
       let name = Printf.sprintf "lbuilder.exec%d" !cntr in
+      Format.eprintf "Executing %s...!?!?!?@." name;
       let f : (unit -> void) pointer v =
         let proto = function_ void Type.c0 in
         match Module.Function.lookup name with
         | Some _ -> failwithf "function %s is defined more than once" name
         | None -> Module.Function.declare name proto
       in
-
+      prerr_endline "proto done";
       (* Create a new basic block to start insertion into. *)
       Monad.run (perform
         let bb = Block.append ~name:"entry" f in
         v; (* create the code *)
         ret_void);
       (* Optimize the function *)
+      Value.dump f;
       Module.PassManager.run_function_if_opt f;
       Analysis.assert_valid_function f;
       Format.eprintf "Now running %s@." name;