src/HOL/Mutabelle/mutabelle_extra.ML
changeset 42012 2c3fe3cbebae
parent 41999 3c029ef9e0f2
child 42014 75417ef605ba
equal deleted inserted replaced
42011:dee23d63d466 42012:2c3fe3cbebae
   330       (* andalso is_executable_thm thy th *))
   330       (* andalso is_executable_thm thy th *))
   331     (map snd (filter_out is_forbidden_theorem (Mutabelle.all_unconcealed_thms_of thy)))
   331     (map snd (filter_out is_forbidden_theorem (Mutabelle.all_unconcealed_thms_of thy)))
   332 
   332 
   333 fun count x = (length oo filter o equal) x
   333 fun count x = (length oo filter o equal) x
   334 
   334 
   335 fun cpu_time description f =
   335 fun cpu_time description f =  (* FIXME !? *)
   336   let
   336   let
   337     val start = start_timing ()
   337     val start = Timing.start ()
   338     val result = Exn.capture f ()
   338     val result = Exn.capture f ()
   339     val time = Time.toMilliseconds (#cpu (end_timing start))
   339     val time = Time.toMilliseconds (#cpu (Timing.result start))
   340   in (Exn.release result, (description, time)) end
   340   in (Exn.release result, (description, time)) end
   341 (*
   341 (*
   342 fun unsafe_invoke_mtd thy (mtd_name, invoke_mtd) t =
   342 fun unsafe_invoke_mtd thy (mtd_name, invoke_mtd) t =
   343   let
   343   let
   344     val _ = Output.urgent_message ("Invoking " ^ mtd_name)
   344     val _ = Output.urgent_message ("Invoking " ^ mtd_name)