oneapi-src / oneapi-src/oneAPI-samples

FPGA simulation run fails if <binary>.fpga_sim.prj not in same location

オープン
#1,515 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

bug
主要言語
C++
スター
1.2k
フォーク
745
PR マージ指標
30日以内にマージされた PR はありません

説明

Summary

If a <binary>.fpga_sim is run from a directory where <binary>.fpga_sim.prj does not exist then the runtime throws an exception:
-2 (PI_ERROR_DEVICE_NOT_AVAILABLE) -2 (PI_ERROR_DEVICE_NOT_AVAILABLE).

This must be because the simulation_raw.json file generated by Modelsim is written to <binary>.fpga_sim.prj/reports/resources/json/simulation_raw.json instead of to the current directory. Maybe erroring out is the intended behaviour, but in that case the specific runtime error is misleading.

Version

oneAPI Toolkit version 2023.1.0 (2023.1.0.20230320)
oneAPI Sample hash 5be94fc7db259dafd54e8aedfcc99b39dc025cfc

Environment

Ubuntu 22.04, Quartus 22.4, Questa Starter Edition 22.1

Steps to reproduce

Following the GettingStarted guide:

cd DirectProgramming/C++SYCL_FPGA/Tutorials/GettingStarted/fpga_compile/part4_dpcpp_lambda_buffers/src
icpx -fsycl -fintelfpga -DFPGA_SIMULATOR -I../../../../include vector_add.cpp -Xssimulation -Xstarget=Arria10 -Xsghdl -o vector_add_sim.fpga_sim
cd ..
./src/vector_add_sim.fpga_sim

Observed behavior

-2 (PI_ERROR_DEVICE_NOT_AVAILABLE) -2 (PI_ERROR_DEVICE_NOT_AVAILABLE)

Expected behavior

Simulation runs. <binary>.fpga_sim.prj is found based on the binary path. If not found, either write simulation_raw.json to the current directory or give a meaningful error.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

GettingStarted fpga_compile/part4_dpcpp_lambda_buffers の例とその src/vector_add.cpp から始め、次に、ドキュメントに記載されたコマンドを使って親ディレクトリから FPGA シミュレーターの実行を再現します。simulation_raw.json が vector_add_sim.fpga_sim に対してどこにあることを想定されているかを追跡し、プロジェクトディレクトリの外部で実行した場合に成功するか、具体的で意味のあるエラーが報告されることを確認します。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
cpp
領域
devtools
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。