6

For programming FPGAS, is it possible to write my own place & route routines? [The point is not that mine would be better; the point is whether I have the freedom to do so] -- or does the place & route stage output into undocumented bitfiles, essengially forcing me to use proprietary tools?

Thanks!

anon
  • 41,035
  • 53
  • 197
  • 293

2 Answers2

9

There's been some discussion of this on comp.arch.fpga in the past. The conclusion is generally that unless you want to attract intense legal action from the FPGA companies then you probably don't want to do something like this. bitfile formats are closely guarded secrets of the FPGA companies and you would likely have to understand the file format in order to do what you want to do. That implies that you would need to reverse engineer the format and that (if you made your tool public in any way) would get you a lawsuit in short order.

I will add that there probably are intermediate files and that you likely wouldn't read or write the bitfile itself to do what you want to do, but those intermediate files tend to be undocumented as well. Read the EULA for your FPGA synthesis tool (ISE from Xilinx, for example) - any kind of reverse engineering is strictly forbidden. It seems that the only way we'll ever have open source alternatives in this space is for an open source FPGA architecture to emerge.

aneccodeal
  • 8,531
  • 7
  • 45
  • 74
  • 7
    Thank you. And an open source FPGA architecture is BADLY needed for many reasons. The current situation is almost like if only Apply iOS were the only OS in the world. – Prof. Falken Mar 29 '11 at 20:30
  • Attempts for open source FPGA architectures are already in the making, As an example we have "ZUMA: An Open FPGA Overlay Architecture" http://www1.cse.wustl.edu/~roger/565M.f12/4699a093.pdf seems like an interesting start Actually, this might be even more interesting http://www.eecs.berkeley.edu/Pubs/TechRpts/2014/EECS-2014-43.pdf – Rikard Söderström Jun 14 '15 at 19:28
3

I agree with annccodeal, but to amplify a little bit, on Xilinx, there may be a few ways to do this. The XDL file format allows (or used to allow) explicit placement and routing. In addition, it should be possible to script the FPGA Editor to implement custom routing.

As regards placement, there is a rich infrastructure to constrain technology mapping of logic to primitives and to control placement of those primitives. For example LUT_MAP constraints can control technology mapping and LOC and RLOC constraints can determine placement. In practice, these allow the experienced designer great control over how a design is implemented without requiring them to duplicate man-centuries of software development to generate a bitstream directly.

You may also find interesting the current state of the art FPGA CAD research software such VPR. In my opinion these are challenged to keep up with vendor's own tools that must cope with modern heterogeneous FPGAs with splittable 6-LUTs, DSP blocks, etc.

Happy hacking.

Jan Gray
  • 3,454
  • 19
  • 15