Setting up a Linux-Based FPGA Compile Worker

Updated Mar 8, 2024

Environment

Software

  • LabVIEW
  • LabVIEW FPGA Module
  • LabVIEW FPGA Compile Farm Toolkit

Operating System

  • Linux
  • Windows

The NI LabVIEW FPGA Module, along with standard NI reconfigurable I/O (RIO) hardware, has made field-programmable gate arrays (FPGAs) more accessible to engineers and scientists for a decade. However, FPGA programmers industry-wide know that one difficulty with FPGA technology is overcoming the processor-intensive task of synthesizing, placing, and routing an FPGA design, which results in compile times that can last minutes to hours. Selecting an appropriate Linux-based compile system may reduce your compile times. The following section outlines how to use the Linux-based FPGA compile worker along with the LabVIEW 2012 FPGA Module and later, either through NI's compile service or through your own hardware setup.

Note: For access to a high-availability compile server without any installation or maintenance required at your office, consider using the NI LabVIEW FPGA Compile Cloud Service.

LabVIEW FPGA Compile System Overview

NI architected the LabVIEW FPGA compile system with three fundamental software components, which results in a modular, scalable compile solution. The compile system is split into three parts: the development computer, the compile server, and any number of compile workers.

  • LabVIEW FPGA Module Development Environment —The LabVIEW development environment that you are familiar with is where you create your application. Clicking Run on your FPGA VI completes the generating intermediate files step (see LabVIEW FPGA Compilation Process or more information). After generation, the development computer sends the intermediate files through web services communication to the compile server.
  • Compile Server —The compile server accepts compile jobs from one or many LabVIEW FPGA development systems and looks for available compile workers to farm out compile jobs to. If no compile workers are available, the compile server holds the compile job in a queue until a compile worker becomes available.
  • Compile Worker —The compile worker has the LabVIEW FPGA/Xilinx compilation tools installed for FPGA design synthesis, mapping, placing, and routing. With these tools, a compile worker implements the design and generates a bitfile. The compile worker sends the bitfile back to the compile server, which, in turn, sends the bitfile back to the development computer.

Figure 1. The LabVIEW FPGA compile system architecture includes three parts: the development computer, the compile server, and the compile worker(s). The compile server functionality may run on the development computer or on a separate computer.

 

General Requirements

  • Internet Connection – The LabVIEW FPGA Compilation Tools for Vivado 2021.1 and later are installed through an online package repository hosted by NI. The install process starts by downloading and installing a repo registration package. And then once the repo is registered, the actual compilation tools can be installed by the native package manager of your Linux distribution.
  • Legacy Installation Media – For compilation tools older than Vivado 2021.1, the installation process requires the Xilinx compilation tools DVD, found in your FPGA kit. If you did not receive this DVD with your purchase, you can download the installation materials online. Refer to Compatibility between Xilinx Compilation Tools and NI FPGA Hardware to determine which Xilinx compilation tools you need to compile on your operating system with your hardware.
  • Dedicated Computer for the compile worker – A computer with a minimum of 8GB of RAM per core.
    • Note: Faster hard drives or solid state disks do not add significant gains to remote compile speeds. When selecting a computer to run remote compiles on Linux, select for high CPU speed over number of cores.
    • Note: The compile worker can be a VM, but it will not be as performant.
  • 64-bit Linux OS – Refer to the release notes for the relevant Xilinx Compilation Tools for a statement about supported OSs for that specific version of Xilinx tools (e.g. Vivado 2021.1 release notes). Alternatively, you can open the zip file that downloads with the LabVIEW FPGA Compilation Tool for Linux and see which distros are supported in that version of the NI tools by inspecting the file names of the repo registration packages.
  • Familiarity with Linux – Installing and configuring the Linux compile worker does not require advanced Linux knowledge. However, you should have some familiarity with Linux such as troubleshooting network connectivity and utilizing the native package manager for your distribution.
 

Offloading One Compile at a Time

For small development teams, consider offloading compiles to a single Linux computer. The following image represents the computers and software necessary for two developers to offload their compiles to the Linux compile worker.


Note: In this example, though two development computers can communicate with the Linux compile worker, only one can offload a compile at one time. 

 

Installation Overview

LabVIEW FPGA Development Computer (Compile Server)

  • LabVIEW
  • LabVIEW FPGA Module
  • LabVIEW FPGA Compile Farm Toolkit
Linux Compile Worker
  • LabVIEW FPGA Compilation Tool
 

Setting up the Computers

LabVIEW FPGA Development Computer + Compile Server (Windows)

  1. Install LabVIEW and LabVIEW FPGA.
  2. Install the LabVIEW FPGA Compile Farm Toolkit
  3. Select Start>>National Instruments>> FPGA>> FPGA Compile Server Configuration to launch the FPGA compile server configuration dialog box.
  4. Place a checkmark in the Allow users to connect remotely to this compile server checkbox and click OK.
  1. Ensure that your firewall settings permit other computers to request information from this computer.
  2. Launch the FPGA Compile Farm Console (which can be found in the start menu and is an application that runs in a browser) to monitor available and active compile workers.

If the Linux compile worker connects to the Windows computer, the compile appears in the Status field in the compile worker window.
Note: In Linux, closing the compile worker window closes the program.
 

Linux Compile Worker

Exact commands vary based on the package manager and which registration package is relevant for the OS.
  1. Download the relevant version of compile tools for Linux from the LabVIEW FPGA Compilation Tool download page .
  2. Unzip the zip file and find the relevant repo registration package for the distribution.
  3. Install the relevant repo registration package using the native package manager
    1. E.g. sudo apt install ./ni-vivado-2021.1-cg_24.1.0.49363-0+f211-ubuntu2004_all.deb
  4. Refresh the package list of the package manager
    1. E.g. sudo apt update
  5. Install the compile worker’s top-level package
    1. E.g. sudo apt install ni-vivado-2021.1-cg
  6. Select Applications >>National Instruments >>Compile Worker.
 
  1. Click Configure to launch the Configure Compile Worker dialog box.
  2. In the Hostname field, enter the name or IP address of the computer configured as the compile server. In this example, WindowsMachine1 is the compile server.
 

Testing Your Setup

When you initiate a compile using any configured Windows computer, the compile appears in the Status field in the compile worker window.

If you receive an error or are unable to connect to the compile worker, follow these steps on your development computer:

  1. Open the Windows Task Manager (Ctrl + Shift + Esc) >> Processes and look for a CompileWorker process. Click on the CompileWorker process and then click End Process.
  2. In LabVIEW, select Tools >>Options>> FPGA Module>>Use local compile server. Remove the checkmark from the Prompt to select a compile server for each compilation checkbox. Click OK.
  3. Try to compile your VI. The job first looks for a local compile worker. Failing that, the job uses the remote Linux compile worker.
 

Offloading Multiple Compiles at a Time

For larger teams, offload compiles to a farm of multiple Linux computers. The following image represents the computers and software necessary for multiple developers to offload their compiles to a Linux compile farm.


 

Installation Overview

Compile Server (Windows)

  • LabVIEW FPGA Compile Farm Toolkit

LabVIEW FPGA Development Computers (Windows)

  • LabVIEW
  • LabVIEW FPGA

Compile Workers (Linux)

  • LabVIEW FPGA Compilation Tool
 

Setting up the Computers

Compile Server

  1. Install the LabVIEW FPGA Compile Farm Toolkit.
  2. Select Start>>National Instruments>> FPGA>> FPGA Compile Server Configuration to launch the FPGA compile server configuration dialog box.
  3. Place a checkmark in the Allow users to connect remotely to this compile server checkbox and click OK.
 
  1. Ensure that your firewall settings permit other computers to request information from this computer.
  2. Launch the FPGA Compile Farm Console (which can be found in the start menu and is an application that runs in a browser) to monitor available and active compile workers.

If the Linux compile worker connects to the Windows computer, the compile appears in the Status field in the compile worker window.
Note: In Linux, closing the compile worker window closes the program.

LabVIEW FPGA Development Computers

  1. Install LabVIEW and LabVIEW FPGA
  2. Configure LabVIEW FPGA to use the FPGA Compile Farm Server. For more information about configuring LabVIEW compile servers, refer to the Compiling an FPGA VI Remotely (FPGA Module) topic in the LabVIEW FPGA Module Help.

Linux Compile Workers

Refer to the instructions for configuring a Linux Compile Worker under Offloading One Parallel Compile at a Time.