Skip to content
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

[HandshakeToNetlist] Improved components' names #10

Merged
merged 3 commits into from
Jul 28, 2023
Merged

[HandshakeToNetlist] Improved components' names #10

merged 3 commits into from
Jul 28, 2023

Conversation

Liudmila-Paskonova
Copy link
Collaborator

@Liudmila-Paskonova Liudmila-Paskonova commented Jul 25, 2023

Components' names updated

  • extern components' names simplified: for example, "@handshake_fork_2_32" instead of "@handshake_fork_in_ui32_ui32".
  • some code modules improved

Components' names updated
- extern components' names simplified: for example, "@handshake_fork_2_32" instead of "@handshake_fork_in_ui32_ui32".
- some code modules improved
@lucas-rami lucas-rami changed the title [HandshakeToNetlist] [HandshakeToNetlist] Improved components' names Jul 25, 2023
Copy link
Member

@lucas-rami lucas-rami left a comment

Choose a reason for hiding this comment

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

Some cosmetic things to address. Beyond what I wrote, and before this can be merged, please use clang-format (and configure your IDE to format on file save) to have standardized formatting throughout.

@@ -172,10 +172,10 @@ static std::string getTypeName(Type type, Location loc) {
// Integer-like types
if (type.isIntOrIndex()) {
if (auto indexType = type.dyn_cast<IndexType>())
return "_ui" + std::to_string(indexType.kInternalStorageBitWidth);
return "_" + std::to_string(indexType.kInternalStorageBitWidth);
Copy link
Member

Choose a reason for hiding this comment

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

We don't support index types in the pass so this can all be simplified to a single

return "_" + std::to_string(type.getIntOrFloatBitWidth());

extModName += "_in";
// array of input bitwidths
for (auto inType : inTypes)
extModName += getTypeName(inType, loc);
Copy link
Member

Choose a reason for hiding this comment

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

fix indentation here (use clang-format on file save to avoid this)

@lucas-rami lucas-rami merged commit 04f9a62 into main Jul 28, 2023
@lucas-rami lucas-rami deleted the for_pr branch July 30, 2023 06:54
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.

2 participants