Application Acceleration With FPGAs
Programmable Acceleration Cards (PACs), DCP, FPGA AI Suite, Software Stack, and Reference Designs
477 Discussions

Using A10 PAC BSP with OpenCL SDK 18.1

AAmor
Novice
2,943 Views

Hi,

 

I am having trouble compiling some of our kernels for our a10 PAC device using OpenCL SDK 17.1. (The compilation processes hangs for 16 hours and then crashes with no explanation). We managed, however, to build these same kernels using OpenCL SDK 18.1 instead. Unfortunately, it seems that our BSP for PAC requires SDK 17.1 to work properly, therefore we have not been able to run kernels that are built with SDK 18.1 on PAC. We get the following error message:

 

"> FAILED to read auto-discovery string at byte 44. Full auto-discovery string value is 17 560ead0c322a10f2d520cdcbbec868eea363a5d8 pac_a10 0 0 2 4294967296 0 4294967296 4294967296 8589934592 0 1 rtmforward 0 256 0 0 0 0 1 215 11 0 0 4 0 0 4 2 1 8 2 1 8 2 1 8 2 1 8 2 1 8 2 1 8 2 1 8 2 1 8 2 1 8 0 2 6 160 7 160 1 1 1 3 1 1 1 3 

acl_hal_mmd.c:1393:assert failure: Failed to initialize kernel interfacertm_modmig_cpu: acl_hal_mmd.c:1393: l_try_device: Assertion `0' failed."

 

So, I would like to know 2 things:

 

1 . Is it possible to build kernels using newer versions of the SDK (18.1) while keeping the original BSP for SDK 17.1?

2. If it is not possible, are there any updates for the PAC BSP we could use for SDK 18.1?

 

Thanks

 

0 Kudos
5 Replies
Fawaz_Al-Jubori
Employee
975 Views

Hello,

I am still investigating the source of this error.

I will reply to you shortly.

 

Thanks

0 Kudos
AAmor
Novice
975 Views

Hi,

 

I managed to build and run my problematic kernels using SDK 18.1 this weekend. The problem was that I had to build kernels on a remote compilation server, with OpenCL 18.1, while my workstation, where PAC is, had SDK 17.1 installed. The problem disappeared when I updated the SDK on my workstation to the version 18.1. Silly me! Now everything runs fine.

 

One observation, however: the same kernel won't build on any SDK lower than 18.0. I wonder what was the difference.

 

Thank you so much for your attention.

0 Kudos
Fawaz_Al-Jubori
Employee
975 Views

Hello,

I got a confirmation regarding this. You can compile OpenCL kernel using latest intel SDK with older BSP version.

You need to set the environment to make everything works:

  • Set environment variables to point the Quartus Prime version that was used to compile the BSP.
  • Set the environment variables to point to the BSP directory.
  • Set environment variables to point to the latest version of the Intel SDK for OpenCL.
  • Run the Intel SDK for OpenCL initialization script.
  • Compile the kernel.
  • Run the design using the latest version of the Intel SDK for OpenCL or Intel RTE for OpenCL.

 

For example:

 

export QSYS_ROOTDIR=/IntelFPGA_pro/17.1/qsys/bin

export QUARTUS_ROOTDIR=/IntelFPGA_pro/17.1/quartus/bin

export QUARTUS_ROOTDIR_OVERRIDE=/IntelFPGA_pro/17.1/quartus/bin

export PATH="/IntelFPGA_pro/17.1/quartus/bin/:$PATH"

export PATH="/IntelFPGA_pro/17.1/qsys/bin:$PATH"

 

# A10 ref BSP version 17.1

export AOCL_BOARD_PACKAGE_ROOT=/IntelFPGA_pro/17.1/hld/board/a10_ref

export PATH="/IntelFPGA_pro/17.1/hld/board/a10_ref/ip/:$PATH"

 

# set OpenCL version 18.1

export ALTERAOCLSDKROOT=/IntelFPGA_pro/18.1/hld

export INTELFPGAOCLSDKROOT=/IntelFPGA_pro/18.1/hld

 

#run the OpenCL Setup script in 18.1

source /IntelFPGA_pro/18.1/hld/init_opencl.sh

 

 

 

Hope this might help

 

0 Kudos
AAmor
Novice
975 Views

Hi, @FJumaah​ 

 

Thank you for your support. I've made the changes you suggested on my environment variables. The building process is working properly for small kernels, but for larger one I keep getting the error message bellow at the end of the compilation. I wanted to be sure if its a kernel or environment problem.

 

Thank you again for your help.

 

"Compiler Warning: addpipe in board_spec.xml is set to 1 which is no longer supported

Compiler Warning: global memory pipeline stage is now implemented in BSP instead

aoc: First stage compilation completed successfully.

Compiling for FPGA. This process may take a long time, please be patient.

Error: An error occurred during placement

Error: Quartus Prime Fitter was unsuccessful. 1 error, 594 warnings

Error (293001): Quartus Prime Fitter was unsuccessful. 3 errors, 594 warnings

Error (23031): Evaluation of Tcl script a10_partial_reconfig/flow.tcl unsuccessful

Error: Quartus Prime Shell was unsuccessful. 8 errors, 2776 warnings

Error: Compiler Error, not able to generate hardware"

 

HRZ
Valued Contributor III
975 Views

The process is failing during fitting, likely because your kernel is too large to fit on the device. I can give you a more concrete answer if you attach the complete "quartus_sh_compile.log" file from the compilation folder.

0 Kudos
Reply