Initialize tohost and fromhost to zero
authorAndrew Waterman <waterman@eecs.berkeley.edu>
Thu, 16 Jan 2014 08:09:27 +0000 (00:09 -0800)
committerAndrew Waterman <waterman@eecs.berkeley.edu>
Thu, 16 Jan 2014 08:09:27 +0000 (00:09 -0800)
Surprising we got away without doing this for so long

riscv/processor.cc

index 17b418140fc1fd08edd0385bf887ab06440d1a17..067288ce1bff25810408028a197079b51573e7b4 100644 (file)
@@ -47,12 +47,15 @@ void state_t::reset()
   XPR.reset();
   FPR.reset();
 
-  evec = 0;
   epc = 0;
   badvaddr = 0;
-  cause = 0;
+  evec = 0;
+  ptbr = 0;
   pcr_k0 = 0;
   pcr_k1 = 0;
+  cause = 0;
+  tohost = 0;
+  fromhost = 0;
   count = 0;
   compare = 0;
   fflags = 0;