aboutsummaryrefslogtreecommitdiff
path: root/ocaml_emulator
diff options
context:
space:
mode:
authorIbrahim Abu Kharmeh <abukharmeh@gmail.com>2021-11-17 15:41:15 +0000
committerGitHub <noreply@github.com>2021-11-17 15:41:15 +0000
commitc5e62ea4b3d481fcd491b22b317cc319b089f05d (patch)
tree5ddc23d7d67d434cd54b59dd8e3ae207f10fb430 /ocaml_emulator
parent01720566318e292df12693bba1fe5f09ea0857df (diff)
downloadsail-riscv-c5e62ea4b3d481fcd491b22b317cc319b089f05d.zip
sail-riscv-c5e62ea4b3d481fcd491b22b317cc319b089f05d.tar.gz
sail-riscv-c5e62ea4b3d481fcd491b22b317cc319b089f05d.tar.bz2
Initial introduction of zfinx (#75)
* Adds Zfinx enable flag * Hardwire misa.{f,d} and mstats.FS to 0 * Moving nan boxing functions to fdext_reg * Swaps register names for floating point instructions Adds new mapping to swap register names, and use it in all assembly clauses * Disable Floating point loads, stores and moves * Add X_or_F_s and X_or_F_d functions, and use them to access all registers for floating points Changes register accessed for floating point instructions and modify nan boxing functions for zfinx * Formatting Remove couple of misplaced whitespace, unnecessary parens * Fix inconsistent indentation in insts_dext file * Fix spacing in fdext_regs * Remove redundant comparasion with true/ false * Constistant tuples spacing and removes couple of unnecessary parens. * Consistent functions declaration & calls spacing and removes couple of unnecessary parens. * Consistent spacing and removes couple of unnecessary comparasion with true/false * Make spacing consistent * Remove checks from execution stage * Add checks to encdec stage
Diffstat (limited to 'ocaml_emulator')
-rw-r--r--ocaml_emulator/platform.ml2
1 files changed, 2 insertions, 0 deletions
diff --git a/ocaml_emulator/platform.ml b/ocaml_emulator/platform.ml
index 81e33da..a1d9c82 100644
--- a/ocaml_emulator/platform.ml
+++ b/ocaml_emulator/platform.ml
@@ -11,6 +11,7 @@ let config_enable_dirty_update = ref false
let config_enable_misaligned_access = ref false
let config_mtval_has_illegal_inst_bits = ref false
let config_enable_pmp = ref false
+let config_enable_zfinx = ref false
let platform_arch = ref P.RV64
@@ -82,6 +83,7 @@ let enable_dirty_update () = !config_enable_dirty_update
let enable_misaligned_access () = !config_enable_misaligned_access
let mtval_has_illegal_inst_bits () = !config_mtval_has_illegal_inst_bits
let enable_pmp () = !config_enable_pmp
+let enable_zfinx () = !config_enable_zfinx
let rom_base () = arch_bits_of_int64 P.rom_base
let rom_size () = arch_bits_of_int !rom_size_ref