Fix spike-dasm. (#184)
authorTim Newsome <tim@sifive.com>
Mon, 19 Mar 2018 20:10:06 +0000 (13:10 -0700)
committerAndrew Waterman <aswaterman@gmail.com>
Mon, 19 Mar 2018 20:10:06 +0000 (15:10 -0500)
It had been broken by 90bafe660b323250338fd564bb9ab4316576d59b.

riscv/processor.cc

index 5a57c285c9bcada230568c2bc76991987c8a9fd3..7a5df901b315c7a5b1642c45415520cdcb659ef3 100644 (file)
@@ -155,7 +155,8 @@ void processor_t::reset()
   if (ext)
     ext->reset(); // reset the extension
 
   if (ext)
     ext->reset(); // reset the extension
 
-  sim->proc_reset(id);
+  if (sim)
+    sim->proc_reset(id);
 }
 
 // Count number of contiguous 0 bits starting from the LSB.
 }
 
 // Count number of contiguous 0 bits starting from the LSB.