Skip to content

Applications Execution

ELHorta edited this page Oct 29, 2021 · 28 revisions

The first step to run the applications is to create a folder with the same absolute path on both servers (x86 and ARM).

The next step is to copy all files from folder "Xar-Trek-BIN", generated by Xar-Trek, to the folder created on the x86 machine. The XCLBIN(s) file(s) must be stored only on the x86 machine folder. All the applications must be run on the x86 server.

After that, the binaries with suffixes "_aarch64" and "_x86-64" must be copied to the folder created on the ARM machine.

Before running the applications, on each server (x86, ARM), it is necessary to copy the respective binary to a file without the suffix. For example, on the x86 server, the files to be copied are "_x86-64", and on the ARM server, the files to be copied are "_aarch64".

One of the files will be used to start the application on the x86 machine, and the other one must be in the ARM server.

For example, if an application name is FaceDet320, there must be on the x86 machine three executables: FaceDet320_x86-64, FaceDet320_aarch64, FaceDet320 (a copy of FaceDet320_x86-64).

On the x86 server, these would be the executable files:

x86 Folder

On the ARM server, the folder will look like this:

ARM Folder

If the option of software emulation was used in the configuration file, before running the threshold estimator tool and the scheduler server, it is necessary to execute the following command on the applications folder:

~$ export XCL_EMULATION_MODE=sw_emu

The next step before running the applications and starting migration them through the available platforms is activating the scheduler server.

These are the steps to activate the scheduler server:

  1. Open a new terminal

  2. cd ~/Pop_Scheduler/popcorn-scheduler

  3. source /opt/xilinx/xrt/setup.sh

  4. ~$ ./pop_server

The scheduler server shows at the beginning the available hardware kernels on the XCLBIN file:

******************** Xar-Trek Scheduler Server ****************
Available Hardware Kernels:
KNL_HW_face_detect_sw
KNL_HW_DigitRec_sw

Xar-Trek Scheduler Server: waiting for connections...

The Xar-Trek scheduler uses two tables to dynamically migrate the applications among the target platforms. The threshold estimator tool is responsible for the automatic generation of these tables before running the applications.

You must copy the Threshold Estimator Tool to the same folder containing the binaries and XCLBIN files on the x86 server.

If the option of software emulation was used in the configuration file, before running the threshold estimator tool and the scheduler server, it is necessary to execute the following commands on the applications folder:

~$ source /tools/Xilinx/Vitis/2020.2/settings64.sh
~$ export XCL_EMULATION_MODE=sw_emu

Then, these two commands start the estimator tool:

~$ source /opt/xilinx/xrt/setup.sh
~$ ./Xar-Trek-Threshold-Estimator.sh

Congratulations!!

You are now able to run your applications through Xar-Trek

Clone this wiki locally