host/main_xrt.cpp host application is compiled into the
build/ps_app.exe executable. This host application reads in the
input_j.txt files that initalize the
m2s_x2 PL kernel’s
jbuff DDR buffer inputs. This host application starts the PL kernels and the AI Engine graph and waits for one iteration of data to flow through the design. Once the
s2m_x4 PL kernel completes, this host application compares the AI Engine output to the golden output files (
s2m_x4_k3.txt files). If there are any data mismatches, then the
TEST FAILED, else the
TEST PASSED. If you provide the
--profile command line input, this host application also calculates the execution times for the C++ N-Body Simulator and the AI Engine N-Body Simulator for comparison.
host/main_animate.cpp host application is compiled into the
build/ps_animate.exe executable. This host application does the following:
uses the NBodySimulator API to generate initial data (
save the position data (x,y,and z) for all 12,800 particles to the
feeds input data through the AI Engine design
captures the output data from the
reconstructs the output data into a new
feeds the new
input_jback into the AI Engine design and computes another timesteps
The host application repeats these actions for 300 timesteps. You can provide the
--timesteps <num_timesteps> command line input to specify how many timesteps (iterations) the design runs for.
The following is the general execution flow for the host applications.