diff options
author | Iman Hosseini <hosseini.iman@yahoo.com> | 2022-09-20 00:05:00 -0400 |
---|---|---|
committer | Iman Hosseini <hosseini.iman@yahoo.com> | 2022-09-20 00:05:00 -0400 |
commit | dfd191367991cb157b53767dcc05824c826b5abd (patch) | |
tree | 8891eff92502ba3d42a9ddf372f0f2f6e5a5e44c /fesvr/htif.h | |
parent | a0972c82d022f6f7c337b06b27c89a60af52202a (diff) | |
download | spike-dfd191367991cb157b53767dcc05824c826b5abd.zip spike-dfd191367991cb157b53767dcc05824c826b5abd.tar.gz spike-dfd191367991cb157b53767dcc05824c826b5abd.tar.bz2 |
detects the loading of isa-incompatible (i.e. 32 bit code to 64bit HART) code and emits an error message to help avoid unintentionally loading wrong elf.
Diffstat (limited to 'fesvr/htif.h')
-rw-r--r-- | fesvr/htif.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fesvr/htif.h b/fesvr/htif.h index ca5b362..cf8b2d5 100644 --- a/fesvr/htif.h +++ b/fesvr/htif.h @@ -26,7 +26,7 @@ class htif_t : public chunked_memif_t int run(); bool done(); int exit_code(); - + void set_expected_xlen(unsigned int m) { expected_xlen = m; } virtual memif_t& memif() { return mem; } template<typename T> inline T from_target(target_endian<T> n) const @@ -74,7 +74,7 @@ class htif_t : public chunked_memif_t void parse_arguments(int argc, char ** argv); void register_devices(); void usage(const char * program_name); - + unsigned int expected_xlen = 0; memif_t mem; reg_t entry; bool writezeros; |