Readme : Un/DoPACK and Congestion VPR Release version 1.01 Last updated November 7, 2007 Darius Chiu David Yeager David Leong Marvin Tom Guy Lemieux This package contains the source code for the UndoPack clustering, placement, and routing CAD flow. It includes a modified version of VPR 4.30 which allows for congestion estimation and visualization. Contents: --------- ubcpack/ Source code for packing tool, includes iRAC replica and incremental clustering mode rePlace/ VPR 4.30, modified for incremental placement and congestion estimation visualization arch/ Sample architecture files blifs/ Sample blif files scripts/ Scripts to run the Un/DoPack flow Getting Started: ---------------- Get started by running example scripts: 1. Compile the clustering and placement tools 2. Run the testcase generator script: perl makecase.pl test 3. Run the run.pl script (perl run.pl testcase channel_width blif): perl run.pl alu4_30 30 alu4 Un/DoPack script: ---------------- The arguments for the script are as follows: undopack_fast.sh \ \ -- circuit name, including blif extension -- the targeted constraint to meet -- architecture file (not included in package) -- clustering algorithm to use, either .irac., .tvpack. -- name of the test case -- LUT size to use when re-clustering -- Cluster size to use when re-clustering -- input pins per cluster to use when re-clustering -- aperture size for multi-region re-clustering. (The radius is calculated as radius = nx / Congestion_Radius) -Please refer to run_undopack.sh for an example script that runs with Torque/Moab job schedulers (eg, on WestGrid). The script submits multiple tasks to target multiple channel width constraints for multiple circuits. Clustering Tool (UBC Pack): --------------------------- To select the various clustering algorithms, use the new .-cluster_method. option with arguments -cluster_method connection, tvpack, irac, pvpack, ptvpack or depth_optimal. To use the new incremental mode, a new .-incremental. option has been added. To use incremental, we need 4 more arguments as follows: -incremental . Output file from the congestion estimator, contains lets of clbs in each congestion region. The format of the file is simple, please refer to the example.cong file for the format in the example folder. Each congestion region contains a list of associated CLBs and a new cluster size constraint - clustered net file from the previous iteration of the Un/DoPack flow. (previous clustering solution) iPlace output of the placement solution from the previous stage output file name for the generated floorplan file for use with iPlace. So for example: alu4.blif output.net -lut_size 4 -cluster_size 8 -inputs_per_cluster 18 \ -cluster_method irac -incremental a.cong alu4.net alu4.imd alu4.fp \ -cluster_seed timing The following are the steps that the incremental clustering algorithm works: 1: parse the congestion file 2: parse the old .net file 3: Create data structures for the incremental mode (all linked lists) 4: Output a floorplan. Each floorplan element is tagged as __dpop{N}, where {N} is the previous congestion map element 5: Re-cluster each congestion element with the new predicted size 6: Output the .net file (Based on previous .net + new re-clustering) Placement and Routing Tool (iPlace + CongeVPR): ---------------------------------- First, a little explanation on the file formats as follows: .imd or incremental file. (Generated with .-dump_imd. option) This file stores the previous location of each CLB. The file format is as follows: (File attached as well) num_clbs x_size y_size Name1 x_loc y_loc Name2 x_loc y_loc Name3 x_loc y_loc EG: 763 23 23 tin_psv39_8_8_ 0 18 tin_psv39_0_0_ 0 18 tin_psv13_5_5_ 0 18 tin_psv2_13_13_ 0 18 .... .fp or floorplan file (File also attached with example.fp) .NUMELEMENTS num (number of floorplan elements) .SIZE X Y (Size of the previous placement) .ELEMENT tag x0 y0 x_size y_size 1 (Floorplan element with a bounding box, the last 1 was a left over from earlier changes, just use 1) EG: .NUMELEMENTS 1 .SIZE 22 22 .ELEMENT __cl 7 5 14 14 1 And here are the new options added to VPR for incremental placement: 1: To dump the incremental file for incremental placement: -dump_imd filename 2: Route and find best routing solution by continuing to route and finding the best solution -op_delay 3: Turning ON incremental placement (1st stage) -incremental -Previous placement file generated with .-dump_imd. -sgrid -x_size: array X size -y_size: array Y size -initial_t: initial temperature to start the annealing. -floorplan - floorplan file to give better initial placement of modified regions -fp_param - annealing parameters - alpha is the temperature degredation factor - freeze_mult is the number of greedy swaps post annealing (freeze_mult * num_blocks) - rlim is the range limiter percentage Recommended parameters for stage 1: -initial_t: 0 -alpha: 0 -freeze_mult: 0 -rlim: 0.125 4: Turning on Incremental placement (2nd stage) -sgrid_refinement -initial_t is the initial temperature for the second stage. (44% acceptance temperature) -fp_param -Same tuning parameters as stage 1 -inner_num -number of swaps per temperature range (n*num_blocks) Recommended parameters for stage 2: -initial_t: 44% acceptance rate temperature from initial placement -alpha: 0.7 -freeze_mult: 0 -rlim: 0.125 -inner_num: variable 1 to 3 for quality vs run-time trade off Viewing visual congestion information in the placement and routing tool: ------------------------------------------------------------------------- The included VPR version (in the rePlace/ directory) contains the ability to visualize congestion information. Just run it as you would normally run VPR and the on screen controls will let you experiment with different congestion estimation settings. The graphics presented after routing show a comparison of the estimated congestion map, on the left, and actual congestion map, on the right.