一篇非常详细的关于verilog文件读写的文章,包括各种文件读写函数的说明,还有例程,word格式,22页。对于写有关文件操作的testbench比较实用,希望能帮助到大家。
下面给出文件简要说明
Introduction
This describes how you can read and write files in a Verilog model using a set of user functions, based on the C stdio package. With these functions you can perform file input and output directly in Verilog models without having to learn C or the PLI. This code works with VCS, MTI, Verilog-XL, and NC-Verilog (see $fread for one restriction).
Note that Synopsys' VCS 6.1, NC-Verilog 3.3, and MTI's ModelSim 5.5 offer native support for the IEEE-1364 2001 standard. Verilog-XL does not support these tasks except through this PLI application.
包括以下章节
Copyright
Overview
Differences between fileio and IEEE-1364 Verilog-2001 standard
File Input Functions
Restrictions and Caveats
Reading pattern files
Comparing outputs with expected results
Reading script files
Reading data files into memories
Linking with VCS
Linking with Verilog-XL
Linking with MTI
Linking with NC-Verilog
英文好的朋友,可以下下来看看哦。
read_and_write_files_for_verilog.doc