Skip to content

convert switch id check with architecture to warning instead of error #2855

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jan 13, 2025

Conversation

saaramahmoudi
Copy link
Contributor

This PR converts the switch error check with the architecture to a warning.

@vaughnbetz

@github-actions github-actions bot added the lang-cpp C/C++ code label Jan 7, 2025
Copy link
Contributor

@vaughnbetz vaughnbetz left a comment

Choose a reason for hiding this comment

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

Can you summarize the testing for this case? The nightly tests aren't running automatically right now, so if you're not sure if this case is tested in the github runners you should run them manually.

Do we need any new tests?

@@ -534,7 +534,7 @@ class RrGraphSerializer final : public uxsd::RrGraphBase<RrGraphContextTypes> {
}
}
if (!found_arch_name) {
report_error("Switch name '%s' not found in architecture\n", string_name.c_str());
VTR_LOG_WARN("Switch name '%s' not found in architecture\n", string_name.c_str());
Copy link
Contributor

Choose a reason for hiding this comment

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

Probably we should not make this a warning, and instead just make it an info message saying something like:
"Switch name '%s' found in RR graph input from file but not in architecture file; creating it.\n", string_name.c_str());

Otherwise you are likely to get many warnings with the RR graphs you are bringing in, and they will be spurious.

@saaramahmoudi
Copy link
Contributor Author

@vaughnbetz I don't think there is a need to add new tests. However, I have ran the titan benchmarks locally and made sure that nothing is going to break with this change.
We also treat internal switches for flat router with the same logic, we don't look for them in the architecture file and we just don't print any error with those. So, I think it should be working fine

Copy link
Contributor

@vaughnbetz vaughnbetz left a comment

Choose a reason for hiding this comment

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

Thanks. One nit: there should be a semicolon (or a period and new sentence if you prefer) before "creating it." i.e. "; creating it."

@saaramahmoudi
Copy link
Contributor Author

@vaughnbetz resolved

@vaughnbetz vaughnbetz merged commit f6ded92 into master Jan 13, 2025
38 checks passed
@vaughnbetz vaughnbetz deleted the rrgraph_switch_warning branch January 13, 2025 20:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lang-cpp C/C++ code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants