Skip to content

fix(sv): fix slang RTL export compatibility#82

Merged
Makiras merged 1 commit into
masterfrom
fix-slang-parse
Apr 21, 2026
Merged

fix(sv): fix slang RTL export compatibility#82
Makiras merged 1 commit into
masterfrom
fix-slang-parse

Conversation

@FrankOu2001
Copy link
Copy Markdown
Contributor

@FrankOu2001 FrankOu2001 commented Apr 20, 2026

fix #81

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves the SystemVerilog/Verilog parsing path that uses slang, aiming to make RTL export more compatible with real-world filelist flows (macros shared across files, deterministic file ordering, and tolerating missing child modules).

Changes:

  • Add unit tests covering macro visibility across filelist sources, filelist-vs-explicit ordering, and missing child module handling.
  • Update slang driver invocation to use single compilation unit mode, ignore unknown modules, and enable VCS compatibility mode when requested.
  • Deduplicate explicit/direct source arguments against sources discovered from filelists.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
src/parser/sv.cpp Adds slang CLI flags and introduces source deduplication logic using a seen_sources set.
test/test_parser_sv_unit.cpp Adds new regression tests for filelist macro behavior, ordering, and missing child modules.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/parser/sv.cpp
Comment thread test/test_parser_sv_unit.cpp
Comment thread test/test_parser_sv_unit.cpp
@Makiras Makiras merged commit 61333fe into master Apr 21, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

提示宏定义未找到,但是在相应的flielist.txt中已提供声明宏定义的文件

3 participants