search for: pod2text_memo

Displaying 5 results from an estimated 5 matches for "pod2text_memo".

2019 Aug 13
5
[PATCH 0/3] generator: pod2text-related improvements
- refactor memoization code - pass pod as stdin rather than files Pino Toscano (3): generator: isolate memoized cache in own module generator: adjust variable names generator: improve pod2text invocation generator/Makefile.am | 3 ++ generator/memoized_cache.ml | 62 +++++++++++++++++++++ generator/memoized_cache.mli | 29 ++++++++++ generator/utils.ml | 101
2015 Mar 12
1
[PATCH] generator: small optimization of pod2text cache memoization
...ces a bit the disk usage during generator run. --- generator/utils.ml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/generator/utils.ml b/generator/utils.ml index 3a62084..1b00ce5 100644 --- a/generator/utils.ml +++ b/generator/utils.ml @@ -291,10 +291,22 @@ let pod2text_memo : (memo_key, memo_value) Hashtbl.t = v with _ -> Hashtbl.create 13 -let pod2text_memo_updated () = +let pod2text_memo_unsaved_count = ref 0 +let pod2text_memo_atexit = ref false +let pod2text_memo_save () = let chan = open_out pod2text_memo_filename in output_value chan pod2te...
2017 Nov 05
3
[PATCH 1/2] common/mlstdutils: Add with_open_in and with_open_out functions.
...h End_of_file -> ()); + ) + in dump "bindtests" diff --git a/generator/utils.ml b/generator/utils.ml index b818a0b3c..e91fed577 100644 --- a/generator/utils.ml +++ b/generator/utils.ml @@ -179,19 +179,13 @@ type memo_value = string list (* list of lines of POD file *) let pod2text_memo_filename = "generator/.pod2text.data.version.2" let pod2text_memo : (memo_key, memo_value) Hashtbl.t = - try - let chan = open_in pod2text_memo_filename in - let v = input_value chan in - close_in chan; - v - with - _ -> Hashtbl.create 13 + try with_open_in pod2text_...
2019 Aug 13
0
[PATCH 3/3] generator: improve pod2text invocation
...losing the process --- generator/utils.ml | 35 ++++++++++++++++------------------- 1 file changed, 16 insertions(+), 19 deletions(-) diff --git a/generator/utils.ml b/generator/utils.ml index bcbac8d2c..f8837ed3c 100644 --- a/generator/utils.ml +++ b/generator/utils.ml @@ -177,36 +177,33 @@ type pod2text_memo_key = int option * bool * bool * string * string (* width, trim, discard, name, longdesc *) type pod2text_memo_value = string list (* list of lines of POD file *) let run_pod2text (width, trim, discard, name, longdesc) = - let filename, chan = Filename.open_temp_fi...
2009 Aug 03
1
[PATCH 1/2] Convert all TABs-as-indentation to spaces.
...t;pod2text: process exited with non-zero status (%d)" i | Unix.WSIGNALED i | Unix.WSTOPPED i -> - failwithf "pod2text: process signalled or stopped by signal %d" i + failwithf "pod2text: process signalled or stopped by signal %d" i ); Hashtbl.add pod2text_memo key lines; let chan = open_out pod2text_memo_filename in @@ -7737,55 +7737,55 @@ static VALUE ruby_guestfs_close (VALUE gv) pr " Data_Get_Struct (gv, guestfs_h, g);\n"; pr " if (!g)\n"; pr " rb_raise (rb_eArgError, \"%%s: used handle afte...