Skip to content

[AP][HotFix] Placed Fixed Blocks First During IP #3009

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

Conversation

AlexandreSinger
Copy link
Contributor

The cost terms in the AP initial placer were not placing fixed blocks early enough, causing other blocks to take their place and causing the initial placer to not return a solution.

Blocks which have region constraints are now placed first based on how constrained they are. More constrained blocks (can only be placed in a smaller region) will be placed first.

Also found that macros that contained fixed blocks were not observing these constraints when calculating the centroid position of the macro. For constrained macros, projected the centroid position onto the partition region to get the closest point in the partition region to the calculated centroid. This new centroid is used to then perform the placement.

Resolves #3002

The cost terms in the AP initial placer were not placing fixed blocks
early enough, causing other blocks to take their place and causing the
initial placer to not return a solution.

Blocks which have region constraints are now placed first based on how
constrained they are. More constrained blocks (can only be placed in a
smaller region) will be placed first.

Also found that macros that contained fixed blocks were not observing
these constraints when calculating the centroid position of the macro.
For constrained macros, projected the centroid position onto the
partition region to get the closest point in the partition region to the
calculated centroid. This new centroid is used to then perform the
placement.
@github-actions github-actions bot added VPR VPR FPGA Placement & Routing Tool lang-cpp C/C++ code labels Apr 29, 2025
// original centroid.
return best_projected_pos;
}

Copy link
Contributor

Choose a reason for hiding this comment

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

This is a clever solution I guess.

Copy link
Contributor

@haydar-c haydar-c left a comment

Choose a reason for hiding this comment

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

This looks good to me. Thank you for fixing that @AlexandreSinger!

@AlexandreSinger AlexandreSinger merged commit 28e050f into verilog-to-routing:master Apr 29, 2025
66 of 67 checks passed
@AlexandreSinger AlexandreSinger deleted the hotfix-ap-fixed-blocks-ip branch April 29, 2025 23:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lang-cpp C/C++ code VPR VPR FPGA Placement & Routing Tool
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[AP] Fixed IO block handling in the initial placement
2 participants