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: 
Newbie elissoos
Newbie
468 Views
Registered: ‎11-06-2017

HLS Floating Point Addition Not Working

Hi,

 

Sorry for my lack of knowledge, I'm rather new to HLS. I'm currently trying to do some floating point addition with HLS. Basically, I read from memory, cast the data to floats and then perform floating point addition and write back to memory. By using waveforms, I've found that the `fadd` unit is outputting 'UUUUUUU' even though the inputs are valid and have been valid for more clock cycles than the floating point addition requires. Thanks for the help!

 

The code looks something like the following (just as a note, memory reads are done in granularity of 512 bits, that's what snap_membus_t is):

 

 

snap_membus_t temp = (din_gmem + input_address);
float * vals = (float *) &temp;
cf = vals[0] + vals[1];
ci = *((unsigned int *) &cf);
snap_membus_t buffer = (snap_membus_t) ci;

 

0 Kudos