aboutsummaryrefslogtreecommitdiffstats
path: root/common/Switchaux.ml
diff options
context:
space:
mode:
authorDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-03-29 20:23:27 +0100
committerDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-03-29 20:23:27 +0100
commitc24042a694b960237827c6255d5d407fb58227dc (patch)
tree7e2114e69aa27cb7a62f6af0028eff9f08eef614 /common/Switchaux.ml
parent4645d92db40ecffa7cad4bf71acc93482954e8d7 (diff)
downloadcompcert-kvx-c24042a694b960237827c6255d5d407fb58227dc.tar.gz
compcert-kvx-c24042a694b960237827c6255d5d407fb58227dc.zip
FIXME: Jumptables have linking issues.
Diffstat (limited to 'common/Switchaux.ml')
-rw-r--r--common/Switchaux.ml4
1 files changed, 4 insertions, 0 deletions
diff --git a/common/Switchaux.ml b/common/Switchaux.ml
index 69300feb..81d7208f 100644
--- a/common/Switchaux.ml
+++ b/common/Switchaux.ml
@@ -80,6 +80,9 @@ let compile_switch_as_jumptable default cases minkey maxkey =
CTaction default)
let dense_enough (numcases: int) (minkey: Z.t) (maxkey: Z.t) =
+ false
+
+ (* DM FIXME 2019-03-29 do not use jump tables bug in assembly/link
let span = Z.sub maxkey minkey in
assert (Z.ge span Z.zero);
let tree_size = Z.mul (Z.of_uint 4) (Z.of_uint numcases)
@@ -87,6 +90,7 @@ let dense_enough (numcases: int) (minkey: Z.t) (maxkey: Z.t) =
numcases >= 7 (* small jump tables are always less efficient *)
&& Z.le table_size tree_size
&& Z.lt span (Z.of_uint Sys.max_array_length)
+ *)
let compile_switch modulus default table =
let (tbl, keys) = normalize_table table in