Quellcodebibliothek Statistik Leitseite products/sources/formale Sprachen/Isabelle/Pure/ML/   (Beweissystem Isabelle Version 2025-1©)  Datei vom 16.11.2025 mit Größe 914 B image not shown  

Quelle  ml_heap.ML   Sprache: SML

 
(*  Title:      Pure/ML/ml_heap.ML
    Author:     Makarius

ML heap operations.
*)


signature ML_HEAP =
sig
  val obj_size: 'a -> int
  val sizeof1: 'a -> int
  val sizeof_list: 'a list -> int
  val sizeof: 'a list -> int
  val full_gc: unit -> unit
  val gc_now: unit -> Time.time
  val share_common_data: unit -> unit
  val save_child: string -> unit
end;

structure ML_Heap: ML_HEAP =
struct

val obj_size = PolyML.objSize;

fun sizeof1 x = obj_size x * ML_System.platform_obj_size;

fun sizeof_list xs = 3 * length xs * ML_System.platform_obj_size;
fun sizeof xs = obj_size xs * ML_System.platform_obj_size - sizeof_list xs;

val full_gc = PolyML.fullGC;

fun gc_now () = #timeGCReal (PolyML.Statistics.getLocalStats ());

fun share_common_data () = PolyML.shareCommonData PolyML.rootFunction;

fun save_child name =
  PolyML.SaveState.saveChild (name, List.length (PolyML.SaveState.showHierarchy ()));

end;

100%


¤ Dauer der Verarbeitung: 0.11 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung ist noch experimentell.