aboutsummaryrefslogtreecommitdiffhomepage
path: root/proofs
diff options
context:
space:
mode:
authorGravatar Maxime Dénès <mail@maximedenes.fr>2017-12-14 17:23:13 +0100
committerGravatar Maxime Dénès <mail@maximedenes.fr>2017-12-14 17:23:13 +0100
commit1853470c78d1a8aa2525dd57bbfce1064d359ff2 (patch)
treed0af37b803fd6113e9fdc12f37501af3c8eba7ae /proofs
parent84e570d7c532f16104157b806da714906fdf26b3 (diff)
parent4554a860ffdcb30bf5711bd52f443484f9f950d9 (diff)
Merge PR #6264: [kernel] Patch allowing to disable VM reduction.
Diffstat (limited to 'proofs')
-rw-r--r--proofs/redexpr.ml15
1 files changed, 9 insertions, 6 deletions
diff --git a/proofs/redexpr.ml b/proofs/redexpr.ml
index 6052ba367..9a5d4e154 100644
--- a/proofs/redexpr.ml
+++ b/proofs/redexpr.ml
@@ -25,8 +25,11 @@ open Misctypes
(* call by value normalisation function using the virtual machine *)
let cbv_vm env sigma c =
- let ctyp = Retyping.get_type_of env sigma c in
- Vnorm.cbv_vm env sigma c ctyp
+ if Coq_config.bytecode_compiler then
+ let ctyp = Retyping.get_type_of env sigma c in
+ Vnorm.cbv_vm env sigma c ctyp
+ else
+ compute env sigma c
let warn_native_compute_disabled =
CWarnings.create ~name:"native-compute-disabled" ~category:"native-compiler"
@@ -34,12 +37,12 @@ let warn_native_compute_disabled =
strbrk "native_compute disabled at configure time; falling back to vm_compute.")
let cbv_native env sigma c =
- if Coq_config.no_native_compiler then
- (warn_native_compute_disabled ();
- cbv_vm env sigma c)
- else
+ if Coq_config.native_compiler then
let ctyp = Retyping.get_type_of env sigma c in
Nativenorm.native_norm env sigma c ctyp
+ else
+ (warn_native_compute_disabled ();
+ cbv_vm env sigma c)
let whd_cbn flags env sigma t =
let (state,_) =