ovm_ports.svh

Go to the documentation of this file.
00001 // $Id: ovm__ports_8svh-source.html,v 1.1 2008/10/07 21:54:20 alex.marin Exp $
00002 //----------------------------------------------------------------------
00003 //   Copyright 2007-2008 Mentor Graphics Corporation
00004 //   Copyright 2007-2008 Cadence Design Systems, Inc.
00005 //   All Rights Reserved Worldwide
00006 //
00007 //   Licensed under the Apache License, Version 2.0 (the
00008 //   "License"); you may not use this file except in
00009 //   compliance with the License.  You may obtain a copy of
00010 //   the License at
00011 //
00012 //       http://www.apache.org/licenses/LICENSE-2.0
00013 //
00014 //   Unless required by applicable law or agreed to in
00015 //   writing, software distributed under the License is
00016 //   distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
00017 //   CONDITIONS OF ANY KIND, either express or implied.  See
00018 //   the License for the specific language governing
00019 //   permissions and limitations under the License.
00020 //----------------------------------------------------------------------
00021 
00022 class ovm_blocking_put_port #(type T=int)
00023   extends ovm_port_base #(tlm_if_base #(T,T));
00024   `OVM_PORT_COMMON(`TLM_BLOCKING_PUT_MASK,"ovm_blocking_put_port")
00025   `BLOCKING_PUT_IMP (this.m_if, T, t)
00026 endclass 
00027 
00028 class ovm_nonblocking_put_port #(type T=int)
00029   extends ovm_port_base #(tlm_if_base #(T,T));
00030   `OVM_PORT_COMMON(`TLM_NONBLOCKING_PUT_MASK,"ovm_nonblocking_put_port")
00031   `NONBLOCKING_PUT_IMP (this.m_if, T, t)
00032 endclass
00033 
00034 class ovm_put_port #(type T=int)
00035   extends ovm_port_base #(tlm_if_base #(T,T));
00036   `OVM_PORT_COMMON(`TLM_PUT_MASK,"ovm_put_port")
00037   `PUT_IMP (this.m_if, T, t)
00038 endclass
00039 
00040 class ovm_blocking_get_port #(type T=int)
00041   extends ovm_port_base #(tlm_if_base #(T,T));
00042   `OVM_PORT_COMMON(`TLM_BLOCKING_GET_MASK,"ovm_blocking_get_port")
00043   `BLOCKING_GET_IMP (this.m_if, T, t)
00044 endclass 
00045 
00046 class ovm_nonblocking_get_port #(type T=int)
00047   extends ovm_port_base #(tlm_if_base #(T,T));
00048   `OVM_PORT_COMMON(`TLM_NONBLOCKING_GET_MASK,"ovm_nonblocking_get_port")
00049   `NONBLOCKING_GET_IMP (this.m_if, T, t)
00050 endclass
00051 
00052 class ovm_get_port #(type T=int)
00053   extends ovm_port_base #(tlm_if_base #(T,T));
00054   `OVM_PORT_COMMON(`TLM_GET_MASK,"ovm_get_port")
00055   `GET_IMP (this.m_if, T, t)
00056 endclass 
00057 
00058 class ovm_blocking_peek_port #(type T=int)
00059   extends ovm_port_base #(tlm_if_base #(T,T));
00060   `OVM_PORT_COMMON(`TLM_BLOCKING_PEEK_MASK,"ovm_blocking_peek_port")
00061   `BLOCKING_PEEK_IMP (this.m_if, T, t)
00062 endclass 
00063 
00064 class ovm_nonblocking_peek_port #(type T=int)
00065   extends ovm_port_base #(tlm_if_base #(T,T));
00066   `OVM_PORT_COMMON(`TLM_NONBLOCKING_PEEK_MASK,"ovm_nonblocking_peek_port")
00067   `NONBLOCKING_PEEK_IMP (this.m_if, T, t)
00068 endclass
00069 
00070 class ovm_peek_port #(type T=int)
00071   extends ovm_port_base #(tlm_if_base #(T,T));
00072   `OVM_PORT_COMMON(`TLM_PEEK_MASK,"ovm_peek_port")
00073   `PEEK_IMP (this.m_if, T, t)
00074 endclass 
00075 
00076 class ovm_blocking_get_peek_port #(type T=int)
00077   extends ovm_port_base #(tlm_if_base #(T,T));
00078   `OVM_PORT_COMMON(`TLM_BLOCKING_GET_PEEK_MASK,"ovm_blocking_get_peek_port")
00079   `BLOCKING_GET_PEEK_IMP (this.m_if, T, t)
00080 endclass 
00081 
00082 class ovm_nonblocking_get_peek_port #(type T=int)
00083   extends ovm_port_base #(tlm_if_base #(T,T));
00084   `OVM_PORT_COMMON(`TLM_NONBLOCKING_GET_PEEK_MASK,"ovm_nonblocking_get_peek_port")
00085   `NONBLOCKING_GET_PEEK_IMP (this.m_if, T, t)
00086 endclass
00087 
00088 class ovm_get_peek_port #(type T=int)
00089   extends ovm_port_base #(tlm_if_base #(T,T));
00090   `OVM_PORT_COMMON(`TLM_GET_PEEK_MASK,"ovm_get_peek_port")
00091   `GET_PEEK_IMP (this.m_if, T, t)
00092 endclass 
00093 
00094 class ovm_blocking_master_port #(type REQ=int, type RSP=int)
00095   extends ovm_port_base #(tlm_if_base #(REQ, RSP));
00096   `OVM_PORT_COMMON(`TLM_BLOCKING_MASTER_MASK,"ovm_blocking_master_port")
00097   `BLOCKING_PUT_IMP (this.m_if, REQ, t)
00098   `BLOCKING_GET_PEEK_IMP (this.m_if, RSP, t)
00099 endclass 
00100 
00101 class ovm_nonblocking_master_port #(type REQ=int, type RSP=int)
00102   extends ovm_port_base #(tlm_if_base #(REQ, RSP));
00103   `OVM_PORT_COMMON(`TLM_NONBLOCKING_MASTER_MASK,"ovm_nonblocking_master_port")
00104   `NONBLOCKING_PUT_IMP (this.m_if, REQ, t)
00105   `NONBLOCKING_GET_PEEK_IMP (this.m_if, RSP, t)
00106 endclass 
00107 
00108 class ovm_master_port #(type REQ=int, type RSP=int)
00109   extends ovm_port_base #(tlm_if_base #(REQ, RSP));
00110   `OVM_PORT_COMMON(`TLM_MASTER_MASK,"ovm_master_port")
00111   `PUT_IMP (this.m_if, REQ, t)
00112   `GET_PEEK_IMP (this.m_if, RSP, t)
00113 endclass
00114 
00115 class ovm_blocking_slave_port #(type REQ=int, type RSP=int)
00116   extends ovm_port_base #(tlm_if_base #(RSP, REQ));
00117   `OVM_PORT_COMMON(`TLM_BLOCKING_SLAVE_MASK,"ovm_blocking_slave_port")
00118   `BLOCKING_PUT_IMP (this.m_if, RSP, t)
00119   `BLOCKING_GET_PEEK_IMP (this.m_if, REQ, t)
00120 endclass 
00121 
00122 class ovm_nonblocking_slave_port #(type REQ=int, type RSP=int)
00123   extends ovm_port_base #(tlm_if_base #(RSP, REQ));
00124   `OVM_PORT_COMMON(`TLM_NONBLOCKING_SLAVE_MASK,"ovm_nonblocking_slave_port")
00125   `NONBLOCKING_PUT_IMP (this.m_if, RSP, t)
00126   `NONBLOCKING_GET_PEEK_IMP (this.m_if, REQ, t)
00127 endclass 
00128 
00129 class ovm_slave_port #(type REQ=int, type RSP=int)
00130   extends ovm_port_base #(tlm_if_base #(RSP, REQ));
00131   `OVM_PORT_COMMON(`TLM_SLAVE_MASK,"ovm_slave_port")
00132   `PUT_IMP (this.m_if, RSP, t)
00133   `GET_PEEK_IMP (this.m_if, REQ, t)
00134 endclass
00135 
00136 class ovm_blocking_transport_port #(type REQ=int, type RSP=int)
00137   extends ovm_port_base #(tlm_if_base #(REQ, RSP));
00138   `OVM_PORT_COMMON(`TLM_BLOCKING_TRANSPORT_MASK,"ovm_blocking_transport_port")
00139   `BLOCKING_TRANSPORT_IMP (this.m_if, REQ, RSP, req, rsp)
00140 endclass
00141 
00142 class ovm_nonblocking_transport_port #(type REQ=int, type RSP=int)
00143   extends ovm_port_base #(tlm_if_base #(REQ, RSP));
00144   `OVM_PORT_COMMON(`TLM_NONBLOCKING_TRANSPORT_MASK,"ovm_nonblocking_transport_port")
00145   `NONBLOCKING_TRANSPORT_IMP (this.m_if, REQ, RSP, req, rsp)
00146 endclass
00147 
00148 class ovm_transport_port #(type REQ=int, type RSP=int)
00149   extends ovm_port_base #(tlm_if_base #(REQ, RSP));
00150   `OVM_PORT_COMMON(`TLM_TRANSPORT_MASK,"ovm_transport_port")
00151   `TRANSPORT_IMP (this.m_if, REQ, RSP, req, rsp)
00152 endclass
00153 
00154 class ovm_analysis_port # (type T = int)
00155   extends ovm_port_base # (tlm_if_base #(T,T));
00156 
00157   function new (string name, ovm_component parent);
00158     super.new (name, parent, OVM_PORT, 0, OVM_UNBOUNDED_CONNECTIONS);
00159     m_if_mask = `TLM_ANALYSIS_MASK;  
00160   endfunction
00161 
00162   virtual function string get_type_name();
00163     return "ovm_analysis_port";
00164   endfunction
00165 
00166   // analysis port differs from other ports in that it broadcasts
00167   // to all connected interfaces. Ports only send to the interface
00168   // at the index specified in a call to set_if (0 by default).
00169   function void write (input T t);
00170     tlm_if_base # (T, T) tif;
00171     for (int i = 0; i < this.size(); i++) begin
00172       tif = this.get_if (i);
00173       assert (tif != null);
00174       tif.write (t);
00175     end 
00176   endfunction
00177 
00178 endclass

Intelligent Design Verification
Intelligent Design Verification
Project: OVM, Revision: 1.1.0
Copyright (c) 2008 Intelligent Design Verification.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
A copy of the license is included here:
http://www.intelligentdv.com/licenses/fdl.txt
doxygen
Doxygen Version: 1.4.6
Mon Sep 29 14:23:30 2008
Find a documentation bug? Report bugs to: bugs.intelligentdv.com Project: DoxygenFilterSV