After the mapping is successful, we need to print the mapping output and visualize it.
Previously, both were hard coded using a fixed pattern specific to the device model.
Now, this process has been generalized.
Note: printing and visualization related functions are combined together in utilities.cpp and defined in utilities.h with documentation
printVertexModel():
Earlier the vertex model was printing using the pre-defined sequence of the node-IDs in the device-model graph.
Now this has been generalized using a STL map ( gNames )
Key | Value
-- | --
Boost-node-id from device-model-graph (G) | Name of the device-model-node
printMappedResults():
Prints mapping results in the neato format and it is done primarily using two sub-functions:
*printPlacementResults()*: Prints routing information to a mapping-output file.
*printRoutingResults()* : Prints placement information to a mapping-output file.
Earlier only a dot file with co-ordinates was being outputted by GRAMM but considering a large mapping operation with so many x,y co-ordinates can be confusing in terms of visual understanding, that’s why right now GRAMM output two dot files:
positionedOutputFile: (positioned_dot_output.dot) the positioned-output dot file stream (this dot-file contains actual co-ordinates of the node cells).
unpositionedOutputFile : (unpositioned_dot_output.dot) the unpositioned-output dot file stream (this dot-file does not contain any co-ordinates of the node cells).
Go ahead. So far, everything looks good but I'll let you know if an error pops up. Let me know when you push the changes into master so I can create a new branch for the pins
printing and visualization related functions are combined together in utilities.cpp and defined in utilities.h with documentation
printVertexModel():
Earlier the vertex model was printing using the pre-defined sequence of the node-IDs in the device-model graph.
Now this has been generalized using a STL map (
Key | Value -- | -- Boost-node-id from device-model-graph (G) | Name of the device-model-nodegNames
)printMappedResults():
*printPlacementResults()*
: Prints routing information to a mapping-output file.*printRoutingResults()*
: Prints placement information to a mapping-output file.positionedOutputFile
: (positioned_dot_output.dot) the positioned-output dot file stream (this dot-file contains actual co-ordinates of the node cells).unpositionedOutputFile
: (unpositioned_dot_output.dot) the unpositioned-output dot file stream (this dot-file does not contain any co-ordinates of the node cells).Demo:
Pull the latest changes from the: https://github.com/ombhilare999/GRAMM/tree/new_pin_layout_fix
run:
./run_gramm.sh Kernels/Conv_Balance/conv_nounroll_Balance.dot 8 8 RIKEN_with_pins
VertexModel results:
![image](https://github.com/user-attachments/assets/a76b97c2-b4de-434b-a3c2-99cd5b4f07d9)positioned_dot_output.dot: (this dot-file contains actual co-ordinates of the node cells).
Since the current GRAMM doesn't include the last-mile connection (i.e., inPin and ALU connection), it was manually added
unpositioned_dot_output.dot: (this dot-file does not contain any co-ordinates of the node cells)