-
Notifications
You must be signed in to change notification settings - Fork 210
Install and run SDAccel on your own machine
The SDAccel flow for F1 supports the following development models:
- Cloud based development on AWS EC2 cloud instances
- On-premise development on your own local workstations
In both cases, the final binaries are deployed on an AWS F1 instance loaded with the FPGA Developer AMI.
This guide provides step-by-step instructions for getting started with the on-premise flow and covers the following:
- Installing and licensing SDAccel in your own environment
- Building your application on-premise with SDAccel
- Executing your application on F1
Before going through the steps described in this document, the user should have completed the tutorial on how to Create, configure and test an AWS F1 instance. It is important to be familiarized with the cloud-based development environment before setting-up SDAccel in your own environment.
The supported Operating Systems for SDaccel On-premise development are:
- Red Hat Enterprise Workstation/Server 7.2 and 7.3 (64-bit)
- Red Hat Enterprise Workstation 6.7 and 6.8 (64-bit)
- CentOS 6.8, CentOS 7.3 (64-bit)
- Ubuntu Linux 16.04.1 LTS (64-bit)
In order to develop any SDAccel application on-premise, you will need to install the same version of SDAccel as deployed on AWS F1. The SDAccel installer can be found here:
This requires a Xilinx login. If you do not have an existing Xilinx account, select Create your account.
New Xilinx users will also need to obtain an on-premises license of Vivado. The users can request node-locked or floating license from the following page (Links are at Right side of the page):
https://www.xilinx.com/products/design-tools/acceleration-zone/ef-vivado-sdx-vu9p-op-fl-nl.html
The AWS Github repository contains all the necessary platform definition files and setup scripts to run SDAccel and build a design for F1 instances. It also contains numerous examples that will help you learn more about SDAccel.
Execute the following commands on your local machine to clone the Github repository and configure the SDAccel environment:
$ git clone https://github.com/aws/aws-fpga.git
$ cd aws-fpga
$ source sdaccel_setup.sh
Note: Sourcing sdaccel_setup.sh may show some errors as it also tries to install runtime drivers which requires sudo access. These errors are non-intrusive, and you can ignore these messages.
These steps will show you how to:
- Confirm you are able to run SDAccel on your local machine
- Generate binaries which you can then deploy on the F1 instance.
When using Github examples, you can execute same sets of commands that you have used on an AWS EC2 instance.
To invoke the SDAccel GUI, type the following command:
$ sdx
Once you have confirmed the GUI invokes correctly, you can close it. The following steps show how to run this example from the command line.
Execute the following commands to run the SW Emulation step for the SDAccel 'hello world' example:
$ cd SDAccel/examples/xilinx/getting_started/host/helloworld_ocl/
$ make clean
$ make check TARGETS=sw_emu DEVICES=$AWS_PLATFORM all
Execute the following commands to run the HW Emulation step for the SDAccel 'hello world' example:
$ cd SDAccel/examples/xilinx/getting_started/host/helloworld_ocl/
$ make clean
$ make check TARGETS=hw_emu DEVICES=$AWS_PLATFORM all
Execute the following commands to build the application for execution on AWS F1:
$ cd SDAccel/examples/xilinx/getting_started/host/helloworld_ocl/
$ make clean
$ make TARGETS=hw DEVICES=$AWS_PLATFORM all
The build process will generate the host and FPGA binaries.
- Host binary: ./helloworld
- FPGA binary: ./xclbin/vector_addition.hw.xilinx_aws-vu9p-f1_4ddr-xpr-2pr_4_0.xclbin
These binary files are ready to be uploaded to F1.
In this section we will cover the following steps:
- Upload your application built on-premise to the AWS cloud
- Execute your application on F1
Upload the host and kernel binaries to AWS using the provided PEM file, public IP address of the instance, and login id.
$ scp -i ~/<pem-name>.pem <Host binary> <login-id>@<host-ip>:/home/<login-id>/<target directory>/.
$ scp -i ~/<pem-name>.pem <Kernel binary> <login-id>@<host-ip>:/home/<login-id>/<target directory>/.
The steps required to deploy and execute your uploaded applocation are the same as if the application had been developed in the cloud:
- Log-in to F1
- Open a new shell
- Install the SDAccel environment
- Copy all the necessary files
- If a new .xclbin has been uploaded, created and register a new AFI
- Execute your application
All these are described in the AWS SDAccel README
SDAccel Examples Wiki