-
Notifications
You must be signed in to change notification settings - Fork 408
Questions about FPGA Routing Architecture Visualization #2837
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
Comments
I suspect you are getting some edge effects. If your wires are unidirectional (the most common type), some of the wires at the edge (those that would go left) have their drivers cut off and are unusable. Hence they have been removed, and don't draw.
It is surprising this happens only on the right / top edge of the chip and not on the left / bottom though. |
I generated the RR graph of the FPGA shown in the photo, but I don't fully understand it. It seems that all the wires are present, but I'm not entirely sure. I have attached the RR graph in a zip file, which contains the .xml format. |
The ptc_nums for a bunch of the rr nodes are odd. E.g.: The ptc_num has a range, which I haven't seen before. All the wires seem to be there, but the ones with a range of ptc_nums seem to be drawn just using the first ptc_num, or perhaps not drawn (both would look the same I think since they would be drawn on top of each other for the first case). Maybe this is an Open FPGA related feature? Was this rr-graph generated by VPR or brought in from an external tool? @saaramahmoudi : I know you put a form of ptc_num needed by vtr in the code; could it be leading to this range of values printing out? @soheilshahrouz : adding you in case you have any time to dig into this. |
According to the documentation at https://docs.verilogtorouting.org/en/latest/vpr/file_formats/#routing-resource-graph-file-format-xml, ptc can only be an int, not a list. So I'm not sure what added the ptc list in the attached file. |
@vaughnbetz |
Note that the VPR ptc number will always be the first in the OpenFPGA-generated list. Consequently, when we were using both VPR and OpenFPGA, we would take the string contents in ptc="" and drop the first comma through the end of the string. Now we use only VPR-style so this is not needed, but we keep it for backward compatibility. I believe @saaramahmoudi added twist="" or similar to VPR's rr_graph dump, which is fine, but we haven't started using it. The comments about uniqueness are correct. Thanks. |
I think that's the reason for the unusual drawing then @LucaMartis00 . The other wires are there, but drawn on top of each other (as the ptc number is used to decide where to draw wires in a channel, and it seems the openfpga branch is assigning ptc numbers that overlap if you just take the first one in the list). Do you need to use openfpga to generate the rr-graph? If so, the only way to make it draw more nicely would be to write some code to traverse the rr-graph and fix up the ptc numbers (choose better ones to draw more nicely). |
Hi, thanks for your help. One question about the meaning of L4: does it mean that a wire behaves as if it connects one CLB to another without interruptions? |
Yes, some wires are drawn on top of each other. If you right click on them to highlight them you will probably see that sometimes a shorter wire is highlighted and sometimes a longer one, but they are overlapped. L4 means a wire that passes by 4 grid units before it ends. Since CLBs are usually specified as 1 grid unit in arch files, that means an L4 wire would go past 4 CLBs without interruptions. |
Sorry, but I still don't fully understand the meaning of ends and interrupt. The "wire" passes through the switch blocks and isn't even connected to the CLBs it passes by. |
If you're using a unidirectional architecture (the most common type) a wire can only be driven at one end, as the driver is not-tristatable (it is a mux with no tristate). It can drive the inputs of CLBs it passes by, but only the CLBs at one end could drive it in this case. |
Thank you very much, it's much clearer now. I also have some doubts about the Fs parameter of the switch block. Should I open a new issue or continue in this one? |
I'd just write them here if they are questions / concerns. |
I’ve included in the zip file the architecture I’m using. vpr_arch.zip The value of Fs is set to 3, so if I understand correctly, I would expect each input wire to the switch block to be connected to three outputs. However, this doesn’t happen. |
That is odd ... the straight through connections (e.g. left to right) seem to be missing, but I don't see any reason in the architecture file of why they would be missing. Does this happen for all wires or just some? For unidirectional routing architectures there is a step that tries to rearrange muxes to balance how many inputs they have, and the rr-graph generator has to ensure each wire is driven only at one end, so that is part of the rearrangement. I'm not sure if that could lead to this behaviour or not, but I am surprised by it. |
Hello,
I have a question regarding the graphical representation of the routing architecture.
The channel width is set to a fixed value of 20, which corresponds to the number of channels highlighted in yellow. However, in other areas, such as the section highlighted in orange, the number of channels decreases to 10.
Why does this happen? Shouldn't the channel width remain constant across the FPGA, resulting in 20 channels throughout?
I would appreciate your assistance.
The text was updated successfully, but these errors were encountered: