Skip to content

Commit

Permalink
Fir 2022 1 next br
Browse files Browse the repository at this point in the history
* Updated GeMM Design...

* Updated GeMM Design...

* Updated GeMM Design...

* Corrected hw-emu run-time setup in Makefile...

* Updated description.json with the latest syntax

* Updated removd hw_emu run for now from fir hls design to stop timeout related failures...

* Updated GeMM DSP README.md

* Updated GeMM Documentation...

* Updated GeMM Documentation...

* Updated GeMM Documentation...

* Updated FIR and FFT_2D documention...

Co-authored-by: Jithin Pillai <[email protected]>
  • Loading branch information
2 people authored and GitHub Enterprise committed Aug 28, 2022
1 parent eb543cb commit df43aeb
Show file tree
Hide file tree
Showing 9 changed files with 116 additions and 106 deletions.
46 changes: 32 additions & 14 deletions AI_Engine_Development/Design_Tutorials/06-fft2d_AIEvsHLS/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,12 @@ A similar set of harnesses is developed and maintained between the two implement

```
fft2d_AIEvsHLS
|__sample_env_setup.sh......contains sample template for setting up the environment for running the designs
|__AIE......................contains AI Engine implementation
| |Makefile....................with recipes for each step of the design compilation
| |images......................contains images used for AI Engine Design documentation
| |description.json............required for XOAH
| |build.......................created and contains subfolders from design build
| |build.......................created while execution and contains subfolders from design build
| |design......................contains source and include files
| | |aie_src....................contains all the aie source files
| | |pl_src.....................contains all the data mover source files
Expand All @@ -116,7 +117,7 @@ fft2d_AIEvsHLS
| |Makefile....................with recipes for each step of the design compilation
| |images......................contains images used for DSP Design documentation
| |description.json............required for XOAH
| |build.......................created and contains subfolders from design build
| |build.......................created while execution and contains subfolders from design build
| |design......................contains source and include files
| | |pl_src.....................contains all the fft_2d and data mover source files
| | |host_app_src...............contains host application source files
Expand Down Expand Up @@ -146,21 +147,31 @@ fft2d_AIEvsHLS
<details>
<summary>Installing the Tools</summary>

## Installing the Tools
## *Tools*: Installing the Tools

* [AI Engine Tools Lounge](https://www.xilinx.com/member/versal_ai_tools_ea.html)
Tools Documentation:

* [AI Engine Documentation](https://www.xilinx.com/products/design-tools/vitis/vitis-ai.html)
* [Versal AI Engines Secure Site](https://www.xilinx.com/member/forms/registration/versal_ai_engines.html#documentation)

To build and run the 2D-FFT tutorial (AI Engine and HLS implementations), perform the following steps:
* [AI Engine Documentation](https://docs.xilinx.com/search/all?filters=Document_ID~%2522UG1076%2522_%2522UG1079%2522&content-lang=en-US)

* Install the [Vitis Software Platform](https://www.xilinx.com/products/design-tools/vitis/vitis-platform.html).
To build and run the FIR filter tutorial (AI Engine and DSP implementations), you will need the following tools downloaded/installed:

* Obtain licenses for AI Engine tools.
* [DSP Library (DSPLib) Documentation](https://xilinx.github.io/Vitis_Libraries/dsp/2022.1/index.html)

* Follow the instructions in [Installing Xilinx Runtime and Platforms](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installing-Xilinx-Runtime-and-Platforms) (XRT).
* Download and set up the [VCK190 Vitis Platform for 2022.1](https://www.xilinx.com/support/download/index.html/content/xilinx/en/downloadNav/embedded-platforms.html)
* Install the [Vitis Platform 2022.1](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installation)
* Installing the [Vitis Embedded Platforms 2022.1](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installing-Embedded-Platforms?tocId=dtznqDN8RSf91SuduQDZ2A)
* [Platforms Repository 2022.1](https://github.com/Xilinx/Vitis_Embedded_Platform_Source/tree/2022.1)

* Download and set up the [VCK190 Vitis Platform](https://www.xilinx.com/member/vck190_headstart.html#docs).
* [Get Versal Commom Image, comman target and sysroot lincenses and sources](https://www.xilinx.com/support/download/index.html/content/xilinx/en/downloadNav/embedded-platforms/2022-1.html)

* Obtain licenses for AI Engine tools

* [DSP Library (DSPLib) Documentation](https://xilinx.github.io/Vitis_Libraries/dsp/2022.1/index.html)
* Download the [DSP Library](https://github.com/Xilinx/Vitis_Libraries/tree/master/dsp)

* Follow the instructions in [Installing Xilinx Runtime and Platforms](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installing-Xilinx-Runtime-and-Platforms) (XRT)

</details>

Expand All @@ -180,10 +191,17 @@ This tutorial targets the [VCK190 production board](https://www.xilinx.com/produ

## Setting up the Environment

When the elements of the Vitis software platform are installed, update the shell environment script. Set the environment variables to your system-specific paths.
When the elements of the Vitis software platform are installed, create a shell environment script, `env_setup.sh`, using the template given as `sample_env_setup.sh`. Set the environment variables to your system specific paths.

To set up XRT, if you have not done this already, run the following command:

```bash
# XRT Setup...
export XILINX_XRT=<XRT-LOCATION>
source $XILINX_XRT/setup.sh
```

In the design directory of each implementation, edit `env_setup.sh` script with your file paths, then source the environment script:
Edit `env_setup.sh` script with your file paths, then source the environment script:

```bash
source env_setup.sh
Expand All @@ -194,8 +212,8 @@ The script sets up the environment variables and sources scripts explained below
1. The `PLATFORM_REPO_PATHS` environment variable is based on where you downloaded the platform.
2. The `XILINX_TOOLS_LOCATION` path to the Xilinx tools is used to source the `settings64.sh` script.
3. The `XLNX_VERSAL` path to the `xilinx-versal-common-v2022.1` directory is used in the step below.
4. The platform is set up by running the `xilinx-versal-common-v2022.1/environment-setup-cortexa72-cortexa53-xilinx-linux` script as provided in the platform download This script sets up the `SDKTARGETSYSROOT` and `CXX` variables. If the script is not present, you _must_ run the `xilinx-versal-common-v2022.1/sdk.sh` script.
5. `DSPLIB_ROOT` is the path to the downloaded Vitis DSP Libraries. This is only required for the AI Engine implementation.
4. The platform is set up by running the `xilinx-versal-common-v2022.1/environment-setup-cortexa72-cortexa53-xilinx-linux` script as provided in the platform download This script sets up the `SDKTARGETSYSROOT` and `CXX` variables. If the script is not present, you _must_ run the `xilinx-versal-common-v2022.1/sdk.sh` script FIRST.
5. `DSPLIB_VITIS` is the path to the downloaded Vitis DSP Libraries. This is only required for the AI Engine implementation.
6. In the script, you can optionally set up an `XRT_ROOT` environment variable, pointing to XRT - RPMs, which can be packaged in the Vitis compiler packaging step. If it is not set up, this environment variable is automatically be excluded from packaging.
7. The script also sets up the `PLATFORM` variable pointing to the required `.xpfm` file of the target platform set by the variable `tgt_plat`.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,12 @@ export XLNX_VERSAL=<Path to xilinx-versal-common-v2022.1 - Directory>
# if not set it will automatically be excluded from v++ packaging...
#export XRT_ROOT=<Path to XRT RPMs - Directory>

# Set the path to the VITIS LIBs, required only for AIE designs using Vitis DSP Libraries...
# DSPLIB_ROOT variable is set in Makefile using DSPLIB_VITIS variable set below:
export DSPLIB_VITIS=<Path to Vitis Libraries - Directory>

# Setup SDKTARGETSYSROOT and CXX...
unset LD_LIBRARY_PATH
source $XILINX_VERSAL/environment-setup-cortexa72-cortexa53-xilinx-linux

# Source XRT, VITIS, and Aietools...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,7 @@ At the end of this section, the design flow will generate a new directory (calle
<summary>Make Steps</summary>

## Make Steps
To run the following `make` steps (e.g. `make kernels`, `make graph`, etc), you must be in the `Makefiles/` folder.
```bash
cd Makefiles
```

The following options can be specified in the make steps. See the make steps for instructions on how to apply them.
To run the following `make` steps (that is, `make kernels`, `make graph`, and so on), you must be in the `AIE/` folder. The options that can be specified in the `make` steps are as follows.

* TARGET: It can be set to "hw" or "hw_emu" to build the design in hardware or hardware emulation flow. Default is "hw_emu"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ ifeq ($(LAUNCH_HW_EMU_EXEC),0)

else
cd $(EMBEDDED_PACKAGE_OUT); \
./launch_hw_emu.sh -run-app $(EMBEDDED_EXEC_SCRIPT) -timeout -10800 | tee embedded_run.log
./launch_hw_emu.sh -run-app $(EMBEDDED_EXEC_SCRIPT) -timeout 10800 | tee embedded_run.log

endif
else
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,7 @@ At the end of this section, the design flow will generate a new directory (calle
<summary>Make Steps</summary>

## Make Steps
To run the following `make` steps (e.g. `make kernels`, `make graph`, etc), you must be in the `Makefiles/` folder.
```bash
cd Makefiles
```

The following options can be specified in the make steps. See the make steps for instructions how to apply them.
To run the following `make` steps (for example, `make kernels`, `make xsa`, and so on), you must be in the `HLS/` folder. The following options can be specified in the `make` steps. Instructions for how to apply them are provided later in this section.

* TARGET: it can be set to "hw" or "hw_emu" to build the design in hardware or hardware emulation flow. Default is "hw_emu".

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
],
"targets": [
"vitis_hw_build",
"vitis_hw_emu",
"vitis_hw_run"
],
"category": "canary",
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -75,20 +75,31 @@ The makefile based build process can be directed to build different length chai
## Directory Structure
```
filter_AIEvsHLS
+-- AIE......................contains AI Engine implementation
| +-- build ...................created and contains subfolders from design build
| +-- design ..................contains source and include files
| | +-- aie_src .................AI Engine source code
| | +-- app_src .................A72 application source code
| | +-- pl_src ..................PL (HLS) source code
| +--run_dir...................contains bootable image files to run HW flow
+-- HLS......................contains HLS FIR implementation, targeting DSP Engines
| +-- build ......................created and contains subfolders from design build
| +-- design......................contains source and include files
| | +-- app_src .................A72 application source code
| | +-- pl_src ..................PL (HLS) source code
| +--run_dir...................contains bootable image files to run HW flow
+-- report_dir...............contains the generated resource and power utilization reports for both AI Engine and DSP implementations
|__sample_env_setup.sh......contains sample template for setting up the environment for running the designs
|__AIE......................contains AI Engine implementation
| |Makefile....................with recipes for each step of the design compilation
| |images......................contains images used for AI Engine Design documentation
| |description.json............required for XOAH
| |build.......................created while execution and contains subfolders from design build
| |design......................contains source and include files
| | |aie_src....................contains all the aie source files
| | |pl_src.....................contains all the data mover source files
| | |host_app_src...............contains host application source files
| | |system_configs.............contains all system configuration files
| | |profiling_configs..........contains xrt.ini file
| | |hw_emu_files...............contains hw_emu launch script
|__HLS......................contains HLS implementation targeting PL and DSP Engines
| |Makefile....................with recipes for each step of the design compilation
| |images......................contains images used for DSP Design documentation
| |description.json............required for XOAH
| |build.......................created while execution and contains subfolders from design build
| |design......................contains source and include files
| | |pl_src.....................contains all the fir and data mover source files
| | |host_app_src...............contains host application source files
| | |system_configs.............contains all system configuration files
| | |profiling_configs..........contains xrt.ini file
| | |directives.................contains directives for various vitis compilation stages like hls.pre_tcl etc.
| | |hw_emu_files...............contains hw_emu launch script
```

</details>
Expand Down Expand Up @@ -122,31 +133,65 @@ Tools Documentation:

To build and run the FIR filter tutorial (AI Engine and DSP implementations), you will need the following tools downloaded/installed:

* Install the [Vitis Software Platform 2022.1](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installation)
* [DSP Library (DSPLib) Documentation](https://xilinx.github.io/Vitis_Libraries/dsp/2022.1/index.html)

* Obtain licenses for AI Engine tools
* Download and set up the [VCK190 Vitis Platform for 2022.1](https://www.xilinx.com/support/download/index.html/content/xilinx/en/downloadNav/embedded-platforms.html)
* Install the [Vitis Platform 2022.1](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installation)
* Installing the [Vitis Embedded Platforms 2022.1](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installing-Embedded-Platforms?tocId=dtznqDN8RSf91SuduQDZ2A)
* [Platforms Repository 2022.1](https://github.com/Xilinx/Vitis_Embedded_Platform_Source/tree/2022.1)

* Download and set up the [VCK190 Vitis Platform for 2022.1](https://www.xilinx.com/member/vck190_headstart.html#docs)
* [Get Versal Commom Image, comman target and sysroot lincenses and sources](https://www.xilinx.com/support/download/index.html/content/xilinx/en/downloadNav/embedded-platforms/2022-1.html)

* [DSP Library (DSPLib) Documentation](https://xilinx.github.io/Vitis_Libraries/dsp/2022.1/index.html)
* Obtain licenses for AI Engine tools

* [DSP Library (DSPLib) Documentation](https://xilinx.github.io/Vitis_Libraries/dsp/2022.1/index.html)
* Download the [DSP Library](https://github.com/Xilinx/Vitis_Libraries/tree/master/dsp)

* Follow the instructions in [Installing Xilinx Runtime and Platforms](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Installing-Xilinx-Runtime-and-Platforms) (XRT)

</details>

<details>
<summary>Environment: Setting Up the Shell Environment</summary>
<summary>Platform</summary>

## Platform

## Environment: Setting Up the Shell Environment
When the elements of the Vitis software platform are installed, update the shell environment script.
Before beginning the tutorial, make sure you have read and followed the [Vitis Software Platform Release Notes (v2022.1)](https://docs.xilinx.com/r/en-US/ug1393-vitis-application-acceleration/Vitis-Software-Platform-Release-Notes) for setting up software and installing the VCK190 base platform.

1. Set up your platform by running the `xilinx-versal-common-v2022.1/environment-setup-cortexa72-cortexa53-xilinx-linux` script as provided in the platform download. This script sets up the `SDKTARGETSYSROOT` and `CXX` variables. If the script is not present, you **must** run the `xilinx-versal-common-v2022.1/sdk.sh`.
2. Set up your `XLNX_VERSAL` to point to the `xilinx-versal-common-v2022.1` directory.
3. Set up your `PLATFORM_REPO_PATHS` environment variable based upon where you downloaded the platform.
4. Set up your `DSPLIB_ROOT` environment variable based upon where you downloaded the Library
5. Set up Vitis: ```bash source <XILNX-TOOLS-LOCATION>/Vitis/<TOOLS-BUILD>/settings64.sh```
This tutorial targets the [VCK190 production board](https://www.xilinx.com/products/boards-and-kits/vck190.html). If you have already purchased this board, download the necessary files from the Xilinx Website and ensure you have the correct licenses installed. If you do not have a board and the required license, contact your Xilinx sales contact.

</details>

<details>
<summary>Setting Up the Environment</summary>

## Setting up the Environment

When the elements of the Vitis software platform are installed, create a shell environment script, `env_setup.sh`, using the template given as `sample_env_setup.sh`. Set the environment variables to your system specific paths.

To set up XRT, if you have not done this already, run the following command:

```bash
# XRT Setup...
export XILINX_XRT=<XRT-LOCATION>
source $XILINX_XRT/setup.sh
```

Edit `env_setup.sh` script with your file paths, then source the environment script:

```bash
source env_setup.sh
```

The script sets up the environment variables and sources scripts explained below:

1. The `PLATFORM_REPO_PATHS` environment variable is based on where you downloaded the platform.
2. The `XILINX_TOOLS_LOCATION` path to the Xilinx tools is used to source the `settings64.sh` script.
3. The `XLNX_VERSAL` path to the `xilinx-versal-common-v2022.1` directory is used in the step below.
4. The platform is set up by running the `xilinx-versal-common-v2022.1/environment-setup-cortexa72-cortexa53-xilinx-linux` script as provided in the platform download This script sets up the `SDKTARGETSYSROOT` and `CXX` variables. If the script is not present, you _must_ run the `xilinx-versal-common-v2022.1/sdk.sh` script FIRST.
5. `DSPLIB_VITIS` is the path to the downloaded Vitis DSP Libraries. This is only required for the AI Engine implementation.
6. In the script, you can optionally set up an `XRT_ROOT` environment variable, pointing to XRT - RPMs, which can be packaged in the Vitis compiler packaging step. If it is not set up, this environment variable is automatically be excluded from packaging.
7. The script also sets up the `PLATFORM` variable pointing to the required `.xpfm` file of the target platform set by the variable `tgt_plat`.

</details>

Expand Down
Loading

0 comments on commit df43aeb

Please sign in to comment.