📄 00418.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN">
<html>
<head>
<title>30.12.1 VPI reader routines</title>
<meta http-equiv="Content-Type" content="text/html; charset=GB2312" />
<meta name="generator" content="Doc-O-Matic" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<link rel="STYLESHEET" href="default.css" type="text/css" />
<script type="text/javascript" src="scripts.js"></script>
</head>
<body class="Element700" onload="onBodyLoadEx('systemverilog31a.html', 'topic', '00418.html');" onmousedown="onBodyMouseDown();">
<!-- Begin Popups -->
<div class="Element801" id="popup00589">
<div class="Element800">
<div class="Element14">
链接</div>
<div class="Element11">
<div class="Element10">
<a href="00417.html" target="topic">30.12 VPI routines added in SystemVerilog</a></div>
</div>
</div>
</div>
<!-- End Popups -->
<!-- Begin Page Header -->
<div class="Element710" id="areafixed">
<div class="Element92">
<table width="100%" cellspacing="0" cellpadding="0">
<tr><td width="33%">
<div class="Element1">
<a href="#" onmousedown="showPopup(this, 'popup00589');"><img src="seealsolink.png" border="0" alt="" title=""></a> SystemVerilog 3.1a语言参考手册</div>
</td><td width="34%">
<div class="Element2">
</div>
</td><td width="33%">
<div class="Element90">
<a href="00417.html" target="topic"><img src="btn_prev_lightblue.gif" border="0" alt="Previous" title="Previous" onmouseover="switchImage(this, 'btn_prev_lightblue_hover.gif');" onmouseout="switchImage(this, 'btn_prev_lightblue.gif');"></a><a href="00417.html" target="topic"><img src="btn_up_lightblue.gif" border="0" alt="Up" title="Up" onmouseover="switchImage(this, 'btn_up_lightblue_hover.gif');" onmouseout="switchImage(this, 'btn_up_lightblue.gif');"></a><a href="00861.html" target="topic"><img src="btn_next_lightblue.gif" border="0" alt="Next" title="Next" onmouseover="switchImage(this, 'btn_next_lightblue_hover.gif');" onmouseout="switchImage(this, 'btn_next_lightblue.gif');"></a></div>
</td></tr></table><div class="Element5">
30.12.1 VPI reader routines</div>
</div>
</div>
<!-- End Page Header -->
<!-- Begin Client Area -->
<div class="Element720" id="areascroll">
<div class="Element721">
<!-- Begin Page Content -->
<div class="Element58">
<a name="描述"></a><div class="Element11">
<div class="Element10">
<div class="Element170">
<a href="#" onclick="CopyElementToClipboard('code01058');">Copy Code</a></div>
<div class="Element13"><div class="Element12" id="code01058"><pre class="Element12">vpi_close()
<strong>Synopsis</strong>: Close the database if open.
<strong>Syntax</strong>: vpi_close(PLI_INT32 tool, vpiType prop, PLI_BYTE8* name)
<strong>Returns</strong>: PLI_INT32, 1 for success, 0 for fail.
<strong>Arguments</strong>:
PLI_INT32 tool: 0 for the reader.
vpiType prop:
vpiAccessPostProcess: Access data stored in specified database.
vpiAccessInteractive: Access data interactively, database is the flush area.
Tool shall keep value history up to the current time.
PLI_BYTE8* name: Name of the database. This can be the logical name of a database
or the actual name of the data file depending on the tool implementation.
<strong>Related routines</strong>: None.
vpi_load_init()
<strong>Synopsis</strong>: Initialize the load access to scope and/or collection of objects.
<strong>Syntax</strong>: vpi_load_init(vpiHandle objCollection, vpiHandle scope, PLI_INT32 level)
<strong>Returns</strong>: PLI_INT32, 1 for success, 0 for fail.
<strong>Arguments</strong>:
vpiHandle objCollection: Object collection of type vpiObjCollection, a
collection of design objects.
vpiHandle scope: Scope of the load.
PLI_INT32 level: If 0 then enables read access to scope and all its subscopes,
1 means just the scope.
<strong>Related routines</strong>: None.
vpi_load()
<strong>Synopsis</strong>: Load the data of the given object into memory for data access and
traversal if object is an object handle; load the whole collection
(i.e. set of objects) if passed handle is an object collection of type
vpiObjCollection.
<strong>Syntax</strong>: vpi_load(vpiHandle h)
<strong>Returns</strong>: PLI_INT32, 1 for success of loading (all) object(s) (in collection),
0 for fail of loading (any) object (in collection).
<strong>Arguments</strong>:
vpiHandle h: Handle to a design object (of any valid type) or object collection
of type vpiObjCollection.
<strong>Related routines</strong>: None
vpi_unload()
<strong>Synopsis</strong>: Unload the given object data from (active) memory if object is an object
handle, unload the whole collection if passed object is a collection of
type vpiObjCollection. See Section 30.9 for a description of data
unloading.
<strong>Syntax</strong>: vpi_unload(vpiHandle h)
<strong>Returns</strong>: PLI_INT32, 1 for success, 0 for fail.
<strong>Arguments</strong>:
vpiHandle h: Handle to an object or collection (of type vpiObjCollection).
<strong>Related routines</strong>: None.
vpi_create()
<strong>Synopsis</strong>: Create or add to an object or traverse collection.
<strong>Syntax</strong>: vpi_create(vpiType prop, vpiHandle h, vpiHandle obj)
<strong>Returns</strong>: vpiHandle of type vpiObjCollection for success, NULL for fail.
<strong>Arguments</strong>:
vpiType prop:
vpiObjCollection: Create (or add to) object (vpiObjCollection) or
traverse (vpiTrvsCollection) collection.
vpiHandle h: Handle to a (object) traverse collection of
type (vpiObjCollection)
vpiTrvsCollection, NULL for first call (creation)
vpiHandle obj: Handle of object to add, NULL if for first time creation of
collection.
<strong>Related routines</strong>: None.
vpi_goto()
<strong>Synopsis</strong>: Try to move to min, max or specified time. A new traverse (collection)
handle is returned pointing to the specified time. If the traverse handle
(members of collection) has a VC at that time then the returned handle
(members of returned collection) is updated to point to the specified
time, otherwise it is not updated. If the passed handle has no VC (for
collection this means no VC for any object) a fail is indicated,
otherwise a success is indicated. In case of a jump to a specified time,
and there is no value change at the specified time, then the value change
traverse index of the returned (new) handle (member of returned collection)
is aligned based on the jump behavior defined in Section 30.8.4.2, and
its time (and the time pointer argument if passed and is non-NULL) shall
be updated based on the aligned traverse point. In the case of vpiNextVC
or vpiPrevVC, the time argument, if passed and is non-NULL (otherwise
it is ignored and not updated), is updated if there is a VC (for
collection this means a VC for any object) to the new time, otherwise the
value is not updated.
<strong>Syntax</strong>: vpi_goto(vpiType prop, vpiHandle obj, p_vpi_time time_p, PLI_INT32
*ret_code)
<strong>Returns</strong>: vpiHandle of type vpitrvsObj (vpiObjCollection).
<strong>Arguments</strong>:
vpiType prop:
vpiMinTime: Goto the minimum time of traverse collection handle.
vpiMaxTime: Goto the maximum time of traverse collection handle.
vpiTime: Jump to the time specified in time_p.
vpiNextVC: Goto the (time of) next VC.
vpiPrevVC: Goto the (time of) previous VC.
vpiHandle obj: Handle to a traverse object (collection) of type vpiTrvsObj
(vpiTrvsCollection)
p_vpi_time time_p: Pointer to a structure containing time information. Used only if prop is
of type vpiTime, otherwise it is ignored.
PLI_INT32 *ret_code:Pointer to a return code indicator. It is 1 for success and 0 for fail.
Related routines: None.
vpi_filter()
Synopsis: Filter a general collection, a traversable object collection, or traverse collection according to a
specific criterion. Return a collection of the handles that meet the criterion. Original collection is not
changed.
Syntax: vpi_filter(vpiHandle h, PLI_INT32 ft, PLI_INT32 flag)
Returns: vpiHandle of type vpiObjCollection for success, NULL for fail.
Arguments:
vpiHandle h: Handle to a collection of type vpiCollection, vpiObjCollection or
vpiTrvsCollection
PLI_INT32 ft: Filter criterion, any vpiType or a VPI boolean property.
PLI_INT32 flag: Flag to indicate whether to match criterion (if set to TRUE), or not (if set to
FALSE).
Related routines: None.</pre></div></div>
</div>
</div>
<a name="Group"></a><div class="Element14">
<a onclick="toggleVisibilityStored('Group');" class="a_Element14"><img src="sectionminus.png" border="0" alt="" title="" id="imgGroup">Group</a></div>
<div id="divGroup">
<div class="Element11">
<div class="Element10">
<p class="Element10">
<a href="00417.html" target="topic">30.12 VPI routines added in SystemVerilog</a></p></div>
</div>
</div>
<a name="Links"></a><div class="Element14">
<a onclick="toggleVisibilityStored('链接');" class="a_Element14"><img src="sectionminus.png" border="0" alt="" title="" id="img链接">链接</a></div>
<div id="div链接">
<div class="Element11">
<div class="Element10">
<a href="00417.html" target="topic">30.12 VPI routines added in SystemVerilog</a></div>
</div>
</div>
</div>
<!-- End Page Content -->
<!-- Begin Page Footer -->
<hr width="98%" align="center" size="1" color="#CCCCCC" />
<table align="center" cellpadding="0" cellspacing="0" border="0">
<tbody>
<tr height="10">
<td></td>
</tr>
<tr align="center">
<td>
<script type="text/javascript"><!--
google_ad_client = "pub-5266859600380184";
google_ad_width = 468;
google_ad_height = 60;
google_ad_format = "468x60_as";
google_ad_type = "text_image";
google_ad_channel ="";
google_page_url = document.location;
//--></script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
</td>
</tr>
<tr height="15">
<td></td>
</tr>
<tr align="center">
<td>
<font size=2>除非特别声明,原文版权归作者所有,如有转摘请注明原作者以及译者(<a href="http://www.fpgatech.net/" target="_blank">FPGA技术网</a>)信息。<br />
如果您对本主题有何建议或意见,请登陆<a href="http://www.fpgatech.net/forum/forumdisplay.php?fid=18" target="_blank">FPGA开发者家园</a>提交,您的参与是我们前进的动力。</font>
<script language="javascript" type="text/javascript" src="http://js.users.51.la/195685.js"></script>
<noscript><a href="http://www.51.la/?195685" target="_blank"><img alt="我要啦免费统计" src="http://img.users.51.la/195685.asp" style="border:none" /></a></noscript>
</td>
</tr>
</tbody>
</table>
<!-- End Page Footer -->
</div>
</div>
<!-- End Client Area -->
</body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -