00001 #ifndef CTHREAD_H_INCLUDED_ 00002 #define CTHREAD_H_INCLUDED_ 00003 00004 #include <vector> 00005 #include <utility> 00006 00007 #include "rose.h" 00008 00009 #include "function.h" 00010 00011 namespace risc { 00012 00013 class Port; 00014 class InPort; 00015 00016 // These are the reset signal types. A reset signal 00017 // can be represented by a in/inout port 00018 typedef std::pair<Port*, SgBoolValExp*> ResetSignal; 00019 //typedef std::pair<Port*, SgBoolValExp*> AsyncResetSignal; 00020 00021 typedef std::vector<ResetSignal*> ResetSignalVector; 00022 typedef std::vector<ResetSignal*>::iterator ResetSignalVectorIter; 00023 typedef std::vector<ResetSignal*>::const_iterator ResetSignalVectorConstIter; 00024 00025 //typedef std::vector<AsyncResetSignal*> 00026 // AsyncResetSignalVector; 00027 //typedef std::vector<AsyncResetSignal*>::iterator 00028 // AsyncResetSignalVectorIter; 00029 //typedef std::vector<AsyncResetSignal*>::const_iterator 00030 // AsyncResetSignalVectorConstIter; 00031 00032 class CThread: public Function { 00033 00034 public: 00035 00039 explicit CThread(SgFunctionDefinition *ast_node); 00040 00041 InPort *clk_port_; 00042 00043 ResetSignalVector reset_signal_; 00044 ResetSignalVector async_reset_signal_; 00045 00046 private: 00050 CThread(const CThread &t); 00051 }; 00052 00053 typedef std::vector<CThread*> CThreadVector; 00054 typedef std::vector<CThread*>::iterator CThreadVectorIter; 00055 typedef std::vector<CThread*>::const_iterator CThreadVectorConstIter; 00056 00057 }; // end namespace risc 00058 00059 #endif /* CTHREAD_H_INCLUDED_ */ 00060 00061 /* ex: set softtabstop=2 tabstop=2 shiftwidth=2 expandtab: */