#include /*!\file \brief Functions used by the data layout conversion functions. $Id: common.C,v 1.5 2004/09/02 16:59:26 zs Exp $ */ #include CPS_START_NAMESPACE #if 0 #ifdef __cplusplus extern "C" { #endif void negate_link(unsigned link_size, IFloat *link) ; void site2cram(IFloat *src, IFloat *dst, unsigned site_size) ; void site2dram(IFloat *src, IFloat *dst, unsigned *link_tbl, unsigned site_size) ; #ifdef __cplusplus } #endif #endif //! Negate a floating point array. /*! \param link_size The length of the array. \param link The array \post All elements of \a link are negated. */ inline void negate_link(unsigned link_size, IFloat *link) { unsigned idx ; for (idx=0; idx\n dst[link_tbl[i]] = src[i] \n \param src The array to copy from. \param dst The array to copy to. \param link_tbl The look-up table for the \a dst indices. \param site_size The length of the \a src array. */ inline void site2dram(IFloat *src, IFloat *dst, unsigned *link_tbl, unsigned site_size) { unsigned offset ; for (offset=0; offset