Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)
17257 Discussions

How to input llvm IR into aoc?

Altera_Forum
Honored Contributor II
1,531 Views

Hello, 

The aoc compiler gets the <input>.cl kernel code and passes to aocl-clang to generate altera's specific LLVM IR. 

 

I would like to know if I can feed (somehow) the LLVM IR (using clang -x cl -s -emit-llvm input.cl -o output.ll) inside the aoc compiler ? 

 

I see that the aoc compiler uses the aocl-opt and etc as tool for its chain, but I don't know wich flags should I use. Furthermore, I do not know if aocl-clang frontend does anything to the IR different from the standard clang (what I think it is a company secret). 

 

My interest in doing this (feed my clang IR into aoc) is because I'm writing a LLVM optimization pass which results I would like to use to create an FPGA accelerator.  

 

Thank you
0 Kudos
1 Reply
Altera_Forum
Honored Contributor II
726 Views

How do you hack the aoc compilation flow ? I think aocl is a different command chain from aoc.

0 Kudos
Reply