UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Visitor segugasa
Visitor
645 Views
Registered: ‎10-18-2018

s_axilite port=return directive

Jump to solution

Hello,

Is it posible to create s_axilite port=return directive (not pragma)?

Example:

void foo_top(UINT32_T MEM[MEM_SIZE]);

directive for axi_lite port:

set_directive_interface -mode s_axilite -bundle mem_b "foo_top" MEM

Now, how to convert this pragma to directive?

     #pragma HLS INTERFACE s_axilite port=return bundle=mem_b

Thank you.

 

1 Solution

Accepted Solutions
Moderator
Moderator
512 Views
Registered: ‎08-16-2018

Re: s_axilite port=return directive

Jump to solution

@segugasa

In the current example, we are applying pragma on "function-level". This requires only top-level function name for "set_directive_interface", whereas 'return' is required for corresponding "pragma". Therefore "no return" value is shown in "directive.tcl". 

Please see UG902 for more detail; a snapshot of the same is attached at the end. 

Further, if we apply the same "pragma" for "port level interface" e.g. for "MEM" as below, 

#pragma HLS INTERFACE ap_memory port=MEM

Then corresponding "directive.tcl" will have the port value as below, 

set_directive_interface -mode ap_memory "foo_top" MEM

 

 

Screenshot_4.jpg
0 Kudos
5 Replies
Moderator
Moderator
568 Views
Registered: ‎08-16-2018

Re: s_axilite port=return directive

Jump to solution

@segugasa

Do you want to put the "pragma" in the "directive.tcl" file?

For the above case, you can go to "directive tab"->Click on the desired pragma->Select "Directive file". The "pragma" will move to "directive.tcl" file (see attached figure). 

 

Similary, we can move the content from 'directive.tcl' to 'source file' (by selecting the source.file in the last step). 

Screenshot_1.jpg
0 Kudos
Visitor segugasa
Visitor
534 Views
Registered: ‎10-18-2018

Re: s_axilite port=return directive

Jump to solution

@meherp, thank you for your answer.

However, I've tried it already, it doesn't work for port=return pragma.

the  #pragma HLS INTERFACE s_axilite port=return bundle=mem_b 

becomes

set_directive_interface -mode s_axilite -bundle mem_b "foo_top" in directive file.

No  port=return.

This is my problem.

Thank you.

0 Kudos
Visitor segugasa
Visitor
521 Views
Registered: ‎10-18-2018

Re: s_axilite port=return directive

Jump to solution

@meherp

Attached please kindly find the simple project.

0 Kudos
Moderator
Moderator
513 Views
Registered: ‎08-16-2018

Re: s_axilite port=return directive

Jump to solution

@segugasa

In the current example, we are applying pragma on "function-level". This requires only top-level function name for "set_directive_interface", whereas 'return' is required for corresponding "pragma". Therefore "no return" value is shown in "directive.tcl". 

Please see UG902 for more detail; a snapshot of the same is attached at the end. 

Further, if we apply the same "pragma" for "port level interface" e.g. for "MEM" as below, 

#pragma HLS INTERFACE ap_memory port=MEM

Then corresponding "directive.tcl" will have the port value as below, 

set_directive_interface -mode ap_memory "foo_top" MEM

 

 

Screenshot_4.jpg
0 Kudos
Visitor segugasa
Visitor
494 Views
Registered: ‎10-18-2018

Re: s_axilite port=return directive

Jump to solution

@meherpThank you!

0 Kudos