cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Teacher
Teacher
1,282 Views
Registered: ‎03-31-2012

how to merge fully partitioned array ports?

Jump to solution

Hi,

I have the following top level description

 

void fun(const float In[N], float P[N][3]. ...);

 

I do a complete partition of the P port in 2nd dimension and make it an interface of bram. 

Alas this gives me 3 ports P_0, P_1, P_2 of 32 bits with their own read (AND write despite trim_...) 

Is it possible to merge these three ports into a single 96 bit bram port?

 

Unfortunately during constraint interpretation, the P array is not partitioned yet, so I cannot do array map as the names P_0 etc don't exist yet.

 

I guess I can make a single 96 bit port and convert it to 3 float later but I don't want to do that at this stage. Any ideas?

 

- Please mark the Answer as "Accept as solution" if information provided is helpful.
Give Kudos to a post which you think is helpful and reply oriented.
0 Kudos
Reply
1 Solution

Accepted Solutions
Voyager
Voyager
1,620 Views
Registered: ‎06-24-2013

Hey @muzaffer,

 

I'd change the float P[N][3] to const float P[N][3] and use the following #pragmas to get rid of the read interface as well as separate ports ...

    #pragma HLS INTERFACE ap_memory port=In
    #pragma HLS INTERFACE ap_memory port=P
    #pragma HLS ARRAY_RESHAPE variable=P complete dim=2

 

Best,

Herbert

-------------- Yes, I do this for fun!

View solution in original post

0 Kudos
Reply
3 Replies
Voyager
Voyager
1,271 Views
Registered: ‎06-24-2013

Hey @muzaffer,

 

So P is a read/write port or a read only port?

And N I presume is a constant?

 

Best,

Herbert

-------------- Yes, I do this for fun!
0 Kudos
Reply
Teacher
Teacher
1,262 Views
Registered: ‎03-31-2012

@hpoetzl P is a read-only port. All write related ports are pulled to zero in the IP. I am not sure why they are not just trimmed.

Being able to merge them to a single port would be quite nice (ie without declaring a 96 bit vector instead)

- Please mark the Answer as "Accept as solution" if information provided is helpful.
Give Kudos to a post which you think is helpful and reply oriented.
0 Kudos
Reply
Voyager
Voyager
1,621 Views
Registered: ‎06-24-2013

Hey @muzaffer,

 

I'd change the float P[N][3] to const float P[N][3] and use the following #pragmas to get rid of the read interface as well as separate ports ...

    #pragma HLS INTERFACE ap_memory port=In
    #pragma HLS INTERFACE ap_memory port=P
    #pragma HLS ARRAY_RESHAPE variable=P complete dim=2

 

Best,

Herbert

-------------- Yes, I do this for fun!

View solution in original post

0 Kudos
Reply