how to use bambu with a .ll file

40 views
Skip to first unread message

nikhil...@gmail.com

unread,
Apr 27, 2020, 11:25:59 PM4/27/20
to PandA project discussions and questions
Hi,
I am new user to Bambu. I am working on a project which does some transformations on the llvm IR. I want to use this transformed IR (.ll file) as an input to bambu. However, when I do, there are compilation errors. 
Could you please advice on how to use it?

Thanks

Fabrizio Ferrandi

unread,
Apr 29, 2020, 10:05:20 AM4/29/20
to PandA project discussions and questions
Hi,
Thank you very much for considering bambu in your research.
Performing the HLS of a .ll file just requires to pass the .ll file to bambu and to use a Clang/LLVM compiler as front end.
So a typical use could be this one:
bambu filename.ll —compiler=I386_CLANG6

Much depend which clang version you have configured in your system.

In case this is not working with you, I need some further details on the way you bambu and which .ll you used.

Cheers,

Fabrizio

nikhil ghanathe

unread,
Apr 29, 2020, 5:01:32 PM4/29/20
to PandA project discussions and questions
Hello,
Thanks a lot for getting back to me!
I tried out above command and it gives me the following error:

error -> Unexpected file extension: —compiler=I386_CLANG6

I am using a simple C program with two if-else blocks. I am converting the C code to llvm IR using clang before feeding it to bambu. Please find the .c and .ll file attached for your reference. 
Also, I am using the latest version of Bambu and clang 6.0 version

Thanks

Fabrizio Ferrandi

unread,
Apr 30, 2020, 5:40:26 AM4/30/20
to panda-project-dis...@googlegroups.com
Hi,
not sure but it looks like that you have a copy & paste problem.
The option to be passed to bambu is --compiler=I386_CLANG6
minus minus compiler=I386_CLANG6

from the message, I saw a single minus/dash.

Cheers,
Fabrizio

nikhil ghanathe

unread,
Apr 30, 2020, 2:23:24 PM4/30/20
to PandA project discussions and questions
Thanks a lot! it was just a simple copy & paste error :)
I works now

Thanks,
Nikhil
Reply all
Reply to author
Forward
0 new messages