サードパーティー・シミュレーション・ユーザーガイド: インテル® Quartus® Prime プロ・エディション

ID 683870
日付 5/07/2018
Public
ドキュメント目次

1.6.2.2.4. Mentor Graphics ModelSim* Simulatorセットアップ・スクリプトの入手

生成されたModelSim* IPのシミュレーション・スクリプトをトップレベルのプロジェクト・シミュレーション・スクリプトに組み込むには、次の手順に従ってください。
  1. 生成されたシミュレーション・スクリプトには、次のテンプレート・ラインが含まれています。 これらのラインを切り取り、新しいファイルに貼り付けます。 例えば、sim_top.tclなどです。
    # # Start of template
    # # If the copied and modified template file is "mentor.do", run it
    # # as: vsim -c -do mentor.do
    # # 
    # # Source the generated sim script
    # source msim_setup.tcl
    # # Compile eda/sim_lib contents first
    # dev_com
    # # Override the top-level name (so that elab is useful)
    # set TOP_LEVEL_NAME top
    # # Compile the standalone IP.
    # com
    # # Compile the top-level
    # vlog -sv ../../top.sv
    # # Elaborate the design.
    # elab
    # # Run the simulation
    # run -a
    # # Report success to the shell
    # exit -code 0
    # # End of template
  2. 各ラインの最初の2文字を削除します(コメントとスペース)。
    # Start of template
    # If the copied and modified template file is "mentor.do", run it
    # as: vsim -c -do mentor.do
    # 
    # Source the generated sim script source msim_setup.tcl
    # Compile eda/sim_lib contents first
    dev_com
    # Override the top-level name (so that elab is useful)
    set TOP_LEVEL_NAME top
    # Compile the standalone IP.
    com
    # Compile the top-level vlog -sv ../../top.sv
    # Elaborate the design.
    elab
    # Run the simulation
    run -a
    # Report success to the shell
    exit -code 0
    # End of template
  3. シミュレーションのトップレベル・ファイルに応じて、TOP_LEVEL_NAMEおよびコンパイル・ステップを適切に変更します。 例えば:
    set TOP_LEVEL_NAME sim_top vlog -sv ../../sim_top.sv
  4. 必要に応じて、QSYS_SIMDIR変数を追加して、生成されたIPシミュレーション・ファイルの位置を指定します。 デザインのシミュレーション要件を満たすために必要な変更を指定します。 スクリプトには、コンパイルまたはシミュレーション・オプションを設定するための変数が用意されています。 詳細については、生成されたスクリプトを参照してください。
  5. 生成されたシミュレーション・ディレクトリーから結果のトップレベル・スクリプトを実行します。
    vsim –c –do <path to sim_top>.tcl