Ignore:
Timestamp:
Apr 9, 2010, 1:36:34 PM (14 years ago)
Author:
simerabe
Message:

updating lib components

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/vci_ring_target/caba/source/include/vci_ring_target.h

    r11 r16  
    3030#include "ring_signals_2.h"
    3131
    32 #define T_DEBUG
    33 #define TR_DEBUG
     32//#define T_DEBUG
     33//#define TR_DEBUG
    3434//#define T_DEBUG_FSM
    3535
     
    192192
    193193#ifdef T_DEBUG_FSM
    194     std::cout << "--------------------------------------------" << std::endl;
    195     std::cout             << " vci cmd fsm  = " << vci_cmd_fsm_state_str_t[r_vci_cmd_fsm] << std::endl
    196                           << " vci rsp fsm  = " << vci_rsp_fsm_state_str_t[r_vci_rsp_fsm] << std::endl
    197                           << " ring cmd fsm = " << ring_cmd_fsm_state_str_t[r_ring_cmd_fsm] << std::endl
    198                           << " ring rsp fsm = " << ring_rsp_fsm_state_str_t[r_ring_rsp_fsm] << std::endl;
     194if( trace(sc_time_stamp()))
     195    std::cout << sc_time_stamp() << " - " << m_name
     196                                 << " - vci cmd = " << vci_cmd_fsm_state_str_t[r_vci_cmd_fsm]
     197                                 << " - vci rsp = " << vci_rsp_fsm_state_str_t[r_vci_rsp_fsm]
     198                                 << " - ring cmd = " << ring_cmd_fsm_state_str_t[r_ring_cmd_fsm]
     199                                 << " - ring rsp = " << ring_rsp_fsm_state_str_t[r_ring_rsp_fsm]
     200                                 << std::endl;
    199201#endif
    200202       
     
    219221                                if (m_cmd_fifo.read() & 0x1 == 0x1) // broadcast
    220222                                {
    221 #ifdef I_DEBUG
    222 std::cout << sc_time_stamp() << " -- " << m_name << " --  broadcast " << std::endl;
    223 #endif
    224223                                        r_addr   = (sc_uint<vci_param::N>) 0x3;     
    225                                         r_srcid  = (sc_uint<vci_param::S>) (m_cmd_fifo.read() >> 21);
     224                                        r_srcid  = (sc_uint<vci_param::S>) (m_cmd_fifo.read() >> 20);
    226225                                        r_cmd    = (sc_uint<2>)  0x2;
    227226                                        r_contig = (sc_uint<1>)  0x1;
     
    229228                                        r_plen   = (sc_uint<vci_param::K>) 0x04;
    230229                                        r_pktid  = (sc_uint<vci_param::P>) 0x0;
    231                                         r_trdid  = (sc_uint<vci_param::T>) ((m_cmd_fifo.read() >> 17) & 0xF);
     230                                        r_trdid  = (sc_uint<vci_param::T>) ((m_cmd_fifo.read() >> 16) & 0xF);
    232231
    233232                                        r_vci_cmd_fsm = WDATA;
     
    269268                                else  // write command
    270269                                {
    271 #ifdef T_DEBUG
    272 if( trace(sc_time_stamp()))
    273          std::cout << sc_time_stamp() << " -- " << m_name 
    274               << " -- r_vci_cmd_fsm -- CMD_SECOND_HEADER & !EOP (WRITE)"
    275               << std::endl;
    276 #endif
     270
    277271                                        cmd_fifo_get =  true;
    278272                                        r_srcid  = (sc_uint<vci_param::S>)  (m_cmd_fifo.read() >> 20) ;
     
    319313        {
    320314                case RSP_HEADER:
    321 
    322                         if((p_vci.rspval.read() == true) && (m_rsp_fifo.wok()))
    323                         {
    324315#ifdef T_DEBUG
    325316if( trace(sc_time_stamp()))
     
    332323              << std::endl;
    333324#endif
     325                        if((p_vci.rspval.read() == true) && (m_rsp_fifo.wok()))
     326                        {
     327
    334328                                rsp_fifo_data = (((uint64_t) p_vci.rsrcid.read() & 0x3FFF) << 12) |
    335329                                                (((uint64_t) p_vci.rerror.read() & 0x1) << 8) |
     
    342336
    343337                case DATA:
    344              
    345                         if((p_vci.rspval.read() == true) && (m_rsp_fifo.wok()))
    346                         {
    347 #ifdef T_DEBUG
     338 #ifdef T_DEBUG
    348339if( trace(sc_time_stamp()))
    349340         std::cout << sc_time_stamp() << " -- " << m_name 
     
    354345              << " -- reop : " << p_vci.reop.read()
    355346              << std::endl;
    356 #endif
     347#endif             
     348                        if((p_vci.rspval.read() == true) && (m_rsp_fifo.wok()))
     349                        {
     350
    357351
    358352                                rsp_fifo_put = true;
Note: See TracChangeset for help on using the changeset viewer.