- (* run the query top_down *)
-
- if !Options.bottom_up then
- Printf.eprintf "Cannot run the query in bottom-up mode, using top-down evaluator\n%!";
-
- if !Options.count_only then
- let module R = ResJIT.Count in
- let module M = Runtime.Make(R) in
- (* mk_runtime run auto doc arg count print outfile *)
- mk_runtime M.top_down_run auto v Tree.root R.NS.length R.NS.serialize None
+ (* run the query top_down *)
+
+ if !Config.bottom_up then
+ Logger.verbose Format.err_formatter "Cannot run the query in bottom-up mode, using top-down evaluator@\n@?";
+ if !Config.count_only then
+ let module R = ResJIT.Count in
+ let module M = Runtime.Make(R) in
+ if !Config.twopass then
+ mk_runtime M.twopass_top_down_run auto v Tree.root R.NS.length R.NS.serialize None
+ else
+ mk_runtime M.top_down_run auto v Tree.root R.NS.length R.NS.serialize !Config.output_file