|
3 | 3 | #include "vpr_types.h"
|
4 | 4 | #include "clustered_netlist_utils.h"
|
5 | 5 |
|
| 6 | +<<<<<<< HEAD |
| 7 | +======= |
| 8 | +/* Stores the information of the move for a block that is * |
| 9 | + * moved during placement * |
| 10 | + * block_num: the index of the moved block * |
| 11 | + * old_loc: the location the block is moved from * |
| 12 | + * new_loc: the location the block is moved to */ |
| 13 | +struct t_pl_moved_block { |
| 14 | + t_pl_moved_block() = default; |
| 15 | + t_pl_moved_block(ClusterBlockId block_num_, const t_pl_loc& old_loc_, const t_pl_loc& new_loc_) |
| 16 | + : block_num(block_num_) |
| 17 | + , old_loc(old_loc_) |
| 18 | + , new_loc(new_loc_) {} |
| 19 | + ClusterBlockId block_num; |
| 20 | + t_pl_loc old_loc; |
| 21 | + t_pl_loc new_loc; |
| 22 | +}; |
| 23 | + |
| 24 | +/* Stores the list of cluster blocks to be moved in a swap during * |
| 25 | + * placement. * |
| 26 | + * Store the information on the blocks to be moved in a swap during * |
| 27 | + * placement, in the form of array of structs instead of struct with * |
| 28 | + * arrays for cache effifiency * |
| 29 | + * |
| 30 | + * num_moved_blocks: total number of blocks moved when * |
| 31 | + * swapping two blocks. * |
| 32 | + * moved blocks: a list of moved blocks data structure with * |
| 33 | + * information on the move. * |
| 34 | + * [0...max_blocks-1] * |
| 35 | + * affected_pins: pins affected by this move (used to * |
| 36 | + * incrementally invalidate parts of the timing * |
| 37 | + * graph. */ |
| 38 | +struct t_pl_blocks_to_be_moved { |
| 39 | + explicit t_pl_blocks_to_be_moved(size_t max_blocks) |
| 40 | + : moved_blocks(max_blocks) {} |
| 41 | + |
| 42 | + int num_moved_blocks = 0; |
| 43 | + std::vector<t_pl_moved_block> moved_blocks; |
| 44 | + std::unordered_set<t_pl_loc> moved_from; |
| 45 | + std::unordered_set<t_pl_loc> moved_to; |
| 46 | + |
| 47 | + std::vector<ClusterPinId> affected_pins; |
| 48 | +}; |
| 49 | + |
| 50 | +>>>>>>> a0e4a8d19 (Re-commit changes) |
6 | 51 | enum class e_block_move_result {
|
7 | 52 | VALID, //Move successful
|
8 | 53 | ABORT, //Unable to perform move
|
|
0 commit comments