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: 
Observer deepa_krishna
Observer
2,207 Views
Registered: ‎08-09-2016

C\ RTL cosimulation result Interval NA in 2017.1

Hi Everyone,

 

I have a problem, while running the C\RTL co simulation in VIVADO HLS 2017.1.

 

I have successfully run my code in 2014 and 2016 version.

 

Can any one tell me why is the report NA only for interval??

 

-------------------------source code-----------------------------------
#include <stdio.h>
#include "ap_int.h"

void scounter ( volatile int delay, volatile int divider, volatile ap_int<4> *counter)
{

#pragma HLS INTERFACE ap_none register port=counter
#pragma HLS INTERFACE ap_none register port=delay
#pragma HLS INTERFACE ap_none register port=divider

#pragma HLS RESOURCE variable=delay core=AXI4LiteS metadata="-bus_bundle CONTROL_BUS"
#pragma HLS RESOURCE variable=divider core=AXI4LiteS metadata="-bus_bundle CONTROL_BUS"
#pragma HLS RESOURCE variable=return core=AXI4LiteS metadata="-bus_bundle CONTROL_BUS"

{
for (volatile int i = 1; i <= delay; i++)
{
*counter = i;
for (volatile int ii = 0; ii < divider; ii++);

}
return;
}
}


--------------------------Test bench------------------------------------

#include <stdio.h>
#include "ap_int.h"

void scounter(volatile int, volatile int, volatile ap_int<4> *);

int main ()
{
volatile int k=15;
volatile int j=5;
volatile ap_int<4> y;

scounter (k,j, &y);

return 0 ;
}

NA.PNG
0 Kudos
4 Replies
Moderator
Moderator
2,196 Views
Registered: ‎11-09-2015

Re: C\ RTL cosimulation result Interval NA in 2017.1

Hi @deepa_krishna,

 

I guess this is because your values of divider and delay are not fixed. So the interval will depends on them.

 

If you fix them to a certain value (not input of the function), you should have a value for the interval.

 

Regards,

 

Florent


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos
Observer deepa_krishna
Observer
2,189 Views
Registered: ‎08-09-2016

Re: C\ RTL cosimulation result Interval NA in 2017.1

I have set their values in test bench.

 

Do I have to increase their value??

 

Regards,

Deepa Krishna

0 Kudos
Observer deepa_krishna
Observer
2,091 Views
Registered: ‎08-09-2016

Re: C\ RTL cosimulation result Interval NA in 2017.1

It is because of this warning I am unable to get it

While reading UG902, I relaised that the arbitary data types and volatile cannot be used together.

So i changed volatile ap_int<4> led* to ap_int<4> led*.

 But, then I am getting the below warning.

 

I even tried to change the interface to M_AXI and set the offset as slave. As I have defined the data type to be  4 bits. I am unable to use that interface.

 

WARNING: [RTGEN 206-101] Port 'led_V' with mode 'ap_none' may require an associated data valid signal to correctly communicate with other blocks or a test bench; automatic C/RTL co-simulation may not be able to verify such a port.

 

Please help me solving this warning

0 Kudos
Observer deepa_krishna
Observer
2,085 Views
Registered: ‎08-09-2016

Re: C\ RTL cosimulation result Interval NA in 2017.1

the arbitary data type and volatile can't be used together if an arithmetic operation is involved

0 Kudos