summaryrefslogtreecommitdiff
path: root/compiler/Interpreter.ml
diff options
context:
space:
mode:
authorSon Ho2022-11-09 18:04:03 +0100
committerSon HO2022-11-10 11:35:30 +0100
commit8b6f8e5fb85bcd1b3257550270c4c857d4ee7f55 (patch)
treeb0090425eb850af3b5c8dc1d4f6aa1eafe2c8e1a /compiler/Interpreter.ml
parentb970183881379ff676b232e47e353e924de8cfdd (diff)
Implement the generation of stateful backward functions (controlled by an option)
Diffstat (limited to '')
-rw-r--r--compiler/Interpreter.ml11
1 files changed, 9 insertions, 2 deletions
diff --git a/compiler/Interpreter.ml b/compiler/Interpreter.ml
index d3b3c7e6..e752594e 100644
--- a/compiler/Interpreter.ml
+++ b/compiler/Interpreter.ml
@@ -253,8 +253,15 @@ let evaluate_function_symbolic (config : C.partial_config) (synthesize : bool)
cf_pop cf_return ctx
| Some back_id ->
(* Backward translation *)
- evaluate_function_symbolic_synthesize_backward_from_return config
- fdef inst_sg back_id ctx
+ let e =
+ evaluate_function_symbolic_synthesize_backward_from_return
+ config fdef inst_sg back_id ctx
+ in
+ (* We insert a delimiter to indicate the point where we switch
+ * from the part which is common to all the functions (forwards
+ * and backwards) and the part specific to this backward function.
+ *)
+ S.synthesize_forward_end e
else None
| Panic ->
(* Note that as we explore all the execution branches, one of