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

[FIRRTL][ExpandWhens] Fix performance with large blocks #5293

Merged
merged 1 commit into from
May 30, 2023

Conversation

youngar
Copy link
Member

@youngar youngar commented May 30, 2023

We need to make sure that we do not doubly process drivers when a wire is driven in both the then and else block, so we were removing the driver from the else block's driver map. Since we are using MapVectors to record drivers, which is needed for deterministic error messages, deleting a single driver from the else block's driver map scaled linearly with the number of drivers. Instead of removing it from the else block's driver map, just check if it was also in the then block's driver map.

@youngar youngar added the FIRRTL Involving the `firrtl` dialect label May 30, 2023
We need to make sure that we do not doubly process drivers when a wire
is driven in both the `then` and `else` block, so we were removing the
driver from the `else` block's driver map.  Since we are using
MapVectors to record drivers, which is needed for deterministic error
messages, deleting a single driver the `else` block's driver map scaled
linearly with the number of drivers.  Instead of removing it from the
`else` block's driver map, just check if it was also in the `then`
block's driver map.
@youngar youngar merged commit c44bb3a into llvm:main May 30, 2023
@youngar youngar deleted the firrtl-expandwhens-slow branch May 30, 2023 20:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FIRRTL Involving the `firrtl` dialect
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant