⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 main.cpp

📁 Kluwer.Academic.Pub.Systemc.From.The.Ground.Up-此全书的范例程式。
💻 CPP
字号:
//BEGIN main.cpp//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//See mutex_ex.h for more information//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#include <iostream>using std::cout;using std::endl;#include <systemc.h>#include "mutex_ex.h"unsigned errors = 0;char* simulation_name = "mutex_ex";int sc_main(int argc, char* argv[]) {  //sc_set_time_resolution(1,SC_PS);  //sc_set_default_time_unit(1,SC_NS);  mutex_ex mutex_ex_i("mutex_ex_i");  cout << "INFO: Starting "<<simulation_name<<" simulation" << endl;  sc_time max_sim(96,SC_SEC);  sc_start(max_sim);  cout << "INFO: Exiting "<<simulation_name<<" simulation" << endl;  cout << "INFO: Simulation " << simulation_name       << " " << (errors?"FAILED":"PASSED")       << " with " << errors << " errors"       << endl;  return errors?1:0;}//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~//END $Id: main.cpp,v 1.1 2003/11/25 12:55:40 dcblack Exp $

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -