OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [orpsocv2/] [bench/] [sysc/] [include/] [Or1200MonitorSC.h] - Diff between revs 52 and 63

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 52 Rev 63
Line 59... Line 59...
  // Method to check instructions
  // Method to check instructions
  void  checkInstruction();
  void  checkInstruction();
 
 
  // Methods to setup and output state of processor to a file
  // Methods to setup and output state of processor to a file
  void displayState();
  void displayState();
 
  void displayStateBinary();
 
 
  // Methods to generate the call and return list during execution
  // Methods to generate the call and return list during execution
  void callLog();
  void callLog();
 
 
  // Method to calculate performance of the sim
  // Method to calculate performance of the sim
Line 75... Line 76...
  void printUsage();
  void printUsage();
 
 
  // Method to dump simulation's RAM contents at finish
  // Method to dump simulation's RAM contents at finish
  void memdump();
  void memdump();
 
 
 
  // Method used for monitoring and logging transactions on the system bus
 
  void busMonitor();
 
 
 
 
  // The ports
  // The ports
  sc_in<bool>   clk;
  sc_in<bool>   clk;
 
 
private:
private:
 
 
 
#define DEFAULT_EXEC_LOG_FILE "or1200_exec.log"
#define DEFAULT_PROF_FILE "sim.profile"
#define DEFAULT_PROF_FILE "sim.profile"
#define DEFAULT_MEMDUMP_FILE "vorpsoc_ram.dump"
#define DEFAULT_MEMDUMP_FILE "vorpsoc_ram.dump"
 
#define DEFAULT_BUS_LOG_FILE "bus_trans.log"
 
 
  // Special NOP instructions
  // Special NOP instructions
  static const uint32_t NOP_NOP    = 0x15000000;  //!< Normal nop instruction
  static const uint32_t NOP_NOP    = 0x15000000;  //!< Normal nop instruction
  static const uint32_t NOP_EXIT   = 0x15000001;  //!< End of simulation
  static const uint32_t NOP_EXIT   = 0x15000001;  //!< End of simulation
  static const uint32_t NOP_REPORT = 0x15000002;  //!< Simple report
  static const uint32_t NOP_REPORT = 0x15000002;  //!< Simple report
  static const uint32_t NOP_PRINTF = 0x15000003;  //!< Simprintf instruction
  static const uint32_t NOP_PRINTF = 0x15000003;  //!< Simprintf instruction
  static const uint32_t NOP_PUTC   = 0x15000004;  //!< Putc instruction
  static const uint32_t NOP_PUTC   = 0x15000004;  //!< Putc instruction
 
  static const uint32_t NOP_CNT_RESET = 0x15000005; //!< Reset statistics counters
 
  static const uint32_t NOP_MEM_STATS_RESET  = 0x15000010; //!< Reset memory statistics counters
 
  static const uint32_t NOP_CNT_RESET_DIFFERENCE = 0x15000006; //!< Reset stats counters, print 
 
 
  // Variables for processor status output
  // Variables for processor status output
  ofstream statusFile;
  ofstream statusFile;
  ofstream profileFile;
  ofstream profileFile;
  int profiling_enabled;
  bool profiling_enabled;
  int logging_enabled;
  bool logging_enabled;
  int exit_perf_summary_enabled;
  bool logfile_name_provided;
  int insn_count;
  bool logging_regs;
  long long cycle_count;
  bool binary_log_format;
 
  bool exit_perf_summary_enabled;
 
  bool monitor_for_crash;
 
  int lookslikewevecrashed_count, crash_monitor_buffer_head;
 
#define CRASH_MONITOR_BUFFER_SIZE 32
 
  uint32_t crash_monitor_buffer[CRASH_MONITOR_BUFFER_SIZE][2]; //PC, Insn
 
  bool wait_for_stall_cmd_response;
 
  unsigned long long insn_count, insn_count_rst;
 
  unsigned long long cycle_count, cycle_count_rst;
  ofstream memdumpFile;
  ofstream memdumpFile;
  string memdumpFileName;
  string memdumpFileName;
  int do_memdump, memdump_start_addr, memdump_end_addr;
  bool do_memdump;
 
  int memdump_start_addr, memdump_end_addr;
 
  bool bus_trans_log_enabled, bus_trans_log_name_provided, bus_trans_log_start_delay_enable;
 
  sc_time bus_trans_log_start_delay;
 
  enum busLogStates { BUS_LOG_IDLE, BUS_LOG_WAIT_FOR_ACK };
 
  ofstream busTransLog;
 
 
  //! Time measurement variable - for calculating performance of the sim
  //! Time measurement variable - for calculating performance of the sim
  clock_t start;
  clock_t start;
 
 
  //! The accessor for the Orpsoc instance
  //! The accessor for the Orpsoc instance

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.