CVC verilog simulator コンパイル2015年08月26日 18:53

Verilog のシミュレータでCVCというのを見つけた。
http://www.tachyon-da.com/

個人的には Veritak が使いやすくていいのだが、System Verilog には未対応だし、大きなシミュレーションは難しい。(SystemVerilog対応版も菅原さんが地道に開発を進められている)
フリーソフトでは、icarus が有名だが、いかんせんシミュレーションが遅い。
Verilator は速いみたいだけど、最上位をC++で書かないといけないし、ちょっと癖がありすぎる感じ。まあ、一番上は、クロックとリセット、終了判断だけにして決まった記述にすればいいのでチャレンジしようかと思っていた矢先ではあるが・・・

とりあえず、CVCをダウンロードしてインストール(というかコンパイル)してみたのでメモに残す。

環境は、CentOS7 (minimal)。

0) まずは、必要なパッケージの準備。
 ダウンロードしたファイルを解凍するための bzip2、コンパイルのための make と gcc、CVC が使用する zlib をインストール。
yum install bzip2
yum install make
yum install gcc
yum install zlib zlib-devel
make するときに、カレントディレクトリを参照できるように、パスを追加。
PATH=$PATH:.
これでコンパイルの準備完了。

1) 適当なディレクトリにファイルをダウンロード
 open_src_cvc_700c_tar.bz2 というファイル名だった。

2) ファイルを展開
tar xvf open_src_cvc_700c_tar.bz2
 open-src-cvc-700c というディレクトリが出来る。

3) open-src-cvc-700c/src に移動して make する
cd open-src-cvc-700c/src
make -f makefile.cvc64
 問題なければ、src ディレクトリに cvc64 という実行ファイルが生成される。

4) 動作確認
 検証用のシミュレーションを通してみる。
 cvc64 を /tmp ディレクトリにコピーして、open_src_cvc_700c/tests_and_examples/install.test ディレクトリにある inst_test.sh と inst_test_interp.sh を実行
cp cvc64 /tmp
cd ../tests_and_examples/install.test
inst_test.sh cvc64
inst_test_interp.sh cvc64
2つのテストでそれぞれ
>>>> Install test completed (this should be only message printed).
と表示されれば成功。
inst_test_interp.sh は、インタープリターモードなので時間がかかる。ちなみに引数の cvc64 は、ファイル名ではなく単なるフラグらしい。
最終的に必要なのは、この cvc64 という実行ファイルだけ。パスの通った適当なディレクトリに置いておけばいい。

詳細は、http://www.tachyon-da.com/cvc-resources/を参照のこと。

コメント

_ shoe lifts ― 2018年01月06日 18:42

Hey! This is my 1st comment here so I just wanted to give a quick
shout out and say I really enjoy reading through your posts.

Can you suggest any other blogs/websites/forums that deal with the same subjects?
Thanks a lot!

_ choc ― 2018年04月30日 18:41

Hello there I am so thrilled I found your webpage, I really found you by accident,
while I was browsing on Bing for something else, Anyways
I am here now and would just like to say thank
you for a remarkable post and a all round exciting blog (I also love the
theme/design), I don’t have time to read it all at the minute but
I have saved it and also added in your RSS feeds, so when I have time I will be back
to read a great deal more, Please do keep up the great
work.

コメントをどうぞ

※メールアドレスとURLの入力は必須ではありません。 入力されたメールアドレスは記事に反映されず、ブログの管理者のみが参照できます。

名前:
メールアドレス:
URL:
コメント:

トラックバック

このエントリのトラックバックURL: http://marusu.asablo.jp/blog/2015/08/26/7750873/tb