返回介绍

23.14 对Verilog-2001系统任务的增强

发布于 2020-09-09 22:55:57 字数 1492 浏览 1006 评论 0 收藏 0

SystemVerilog adds system tasks and system functions as described in the following sections. In addition, SystemVerilog extends the behavior of the following:

  • %u and %z format specifiers:
    • For packed data, %u and %z are defined to operate as though the operation were applied to the equivalent vector.
    • For unpacked struct data, %u and %z are defined to apply as though the operation were performed on each member in declaration order.
    • For unpacked union data, %u and %z are defined to apply as though the operation were performed on the first member in declaration order.
    • %u and %z are not defined on unpacked arrays.
    • The count of data items read by a %u or %z for an aggregate type is always either 1 or 0; the individual members are not counted separately.
  • $fread
$fread has two variants—a register variant and a set of three memory variants.

The register variant,

$fread(myreg, fd);

  • is defined to be the one applied for all packed data.
  • For unpacked struct data, $fread is defined to apply as though the operation were performed on each member in declaration order.
  • For unpacked union data, $fread is defined to apply as though the operation were performed on the first member in declaration order.
  • For unpacked arrays, the original definition applies except that unpacked struct or union elements are read as described above.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文