Semantic Inconsistency in Intermediate FIRRTL File During Compilation: Incorrect reg Emission Instead of node and Loss of Memory readUnderWrite Behavior
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
ShiftResetTester、ShiftTester、SyncReadMemWriteCollisionTester のケースを実行し、生成された .fir ファイルを調べます。src/main/scala/firrtl/ir/Serializer.scala の303行目付近を読み、出力された FIRRTL を src/test/scala/chiselTests/Reg.scala および Mem.scala と比較します。生成された中間ファイルが期待される node/reg セマンティクスと readUnderWrite の動作を保持していれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Type of issue: Bug Report
Please provide the steps to reproduce the problem:
Chisel Version: v3.5.6
FIRRTL Version: v1.5.6
Treadle Version: v1.5.6
We ran the official tests for each of the following cases (without any modifications), and then examined the .fir files in the test_run_dir. We observed inconsistencies between the .fir files and the source code. The details are provided below.
- ShiftResetTester
- Source Code:
src/test/scala/chiselTests/Reg.scala, Line 54 - Description: When
n = 0, the registersrshould have a constant value, which should be compiled to anode. (This is observable when emitting FIRRTL, where the translation results in anode.) However, when emitting Verilog (which generates a.firfile in the same directory), the registersris compiled to areg, leading to an inconsistency with the source code. Initially, the value inreg sris either random or zero (depending on the settings), rather than the expected constant value.
- ShiftTester
- Source Code:
src/test/scala/chiselTests/Reg.scala, Line 44 - Description: This issue is similar to that in ShiftResetTester.
- SyncReadMemWriteCollisionTester
- Source Code:
src/test/scala/chiselTests/Mem.scala, Line 37 - Description: When emitting to Verilog, the memory
readUnderWritebehavior is lost in the.firfile generated in the same directory.
What is the current behavior?
There are cases of semantic inconsistencies between the .fir intermediate files generated by Chisel's emit verilog and the source code (including incorrect compilation and loss of semantic information).
What is the expected behavior?
The semantic behavior of the .fir intermediate files generated by Chisel's emit verilog is consistent with the source code.
Please tell us about your environment:
- version:
v3.5.6 - OS:
Ubuntu 24.04 LTS
Other Information
Use emit verilog to generate the .fir in the same directory (test_run_dir) instead of directly using emit firrtl. I observed that in the FIRRTL repository source code, in src/main/scala/firrtl/ir/Serializer.scala at Line 303, the readUnderWrite field is lost during the emission.
What is the use case for changing the behavior?
I have mentioned it before: the official test code for ShiftResetTester, ShiftTester, and SyncReadMemWriteCollisionTester in the Chisel v3.5.6 repository.
- 主要言語
- Scala
- スター
- 4.8k
- フォーク
- 669
- 平均マージ
- 1日 12時間
- マージ済み PR(30日)
- 25
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
chipsalliance/chisel のほかの issue
-
`addAttribute` cannot be used on RawModule対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
chipsalliance/chisel#5570 ·
メンテナーはふだん 1 日以内に返信
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
chipsalliance/chisel#5499 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 54/100
chipsalliance/chisel#5430 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
MultiClockSpec chiselTest fails with recent Verilator version対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 3/5 1〜2日 初心者へのやさしさ 68/100
chipsalliance/chisel#5418 · コメント 3 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 50/100
chipsalliance/chisel#5411 · コメント 4 件 ·
メンテナーはふだん 1 日以内に返信
chipsalliance/chisel の issue をすべて見る
似ている issue
-
[Bug][NewCSR] vsstatus.SDT latches writes while DTE=0, exposing illegal (vsstatus.SDT=1 && vsstatus.SIE=1)対応中かも @docluka77 が 1 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
OpenXiangShan/XiangShan#7134 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1時間未満 初心者へのやさしさ 83/100
rchillyard/TableParser#230 ·
メンテナーはふだん 1 日以内に返信
-
AI Generated CI/CD ⚒️ Flaky-tests 🐦 python 🐍
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
valkey-io/valkey-glide#8012 ·
メンテナーはふだん 3 日以内に返信
-
Agent Workspace Python guidance: the agent can choose an interpreter without magda-python-runtime plan対応中かも @chandrasahith が 2 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
magda-io/magda#4007 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
[BUG] Iceberg v3 read test fails during schema setup with a zero decimal default対応中かも @res-life が 1 日前に担当しました。 オープンbot_watch bug
難易度 2/5 1〜3時間 初心者へのやさしさ 79/100
NVIDIA/cudf-spark#17288 · 担当者 1 名 ·
メンテナーはふだん 2 日以内に返信