<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic IPP IIR Function in Intel® Business Client Software Development</title>
    <link>https://community.intel.com/t5/Intel-Business-Client-Software/IPP-IIR-Function/m-p/863988#M2428</link>
    <description>&lt;P&gt;about a month ago i posted a question about the "ippsIIR"&lt;/P&gt;
&lt;P&gt;An application that had used this function was crashing on a Core 2 duo, and not on a regular Pentium 4 PC.&lt;/P&gt;
&lt;P&gt;It is still happening, but now i have some more details about the problem.&lt;/P&gt;
&lt;P&gt;&lt;U&gt;Here Is The Code I'm Using:&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;static std::vector&lt;IPPSIIRSTATE_64F&gt; pStateVec;&lt;/IPPSIIRSTATE_64F&gt;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;static std::vector&lt;IPP8U&gt; pBufferVec;&lt;/IPP8U&gt;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;int InitIIRFilter(const double NUM[], const double DEN[], int FilterOrder)&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;{&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;IppsIIRState_64f* State;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;int BufferSize;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;Ippstatus = ippsIIRGetStateSize_64f(FilterOrder,&amp;amp;BufferSize);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;assert(s==ippStsNoErr);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;Ipp8u* Buffer = new Ipp8u[BufferSize];&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;pBufferVec.push_back(Buffer);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;Ipp64f* pTaps =new Ipp64f[2*(FilterOrder+1)];&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;memcpy(pTaps, NUM, (FilterOrder+1)*sizeof(Ipp64f));&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;memcpy(pTaps+ (FilterOrder+1), DEN, (FilterOrder+1)*sizeof(Ipp64f));&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt; s = ippsIIRInit_64f(&amp;amp;State, pTaps, FilterOrder, NULL, Buffer);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;assert(s==ippStsNoErr);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;pStateVec.push_back(State);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt; delete [] pTaps;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;return static_cast&lt;INT&gt;(pStateVec.size()-1);&lt;/INT&gt;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;}&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;void IIRFilter(const double FilterInput[], int len, &lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;double FilterOutput[],intindInFiltStruct)&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;{&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;IppStatus s = ippsIIR_64f(FilterInput, FilterOutput, len, pStateVec[indInFiltStruct]);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;assert(s==ippStsNoErr);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;}&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;The Terminate Function is not stated here&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;NOTES&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;When I debug this code on both PC's, I notice that on the single core, The Value of "State" assumes the Value of "Buffer", after IIRInit, i.e. , points to the start of the buffer, whereas, on the dual core, before the application crashes, "State" points to "Buffer" + 4 bytes, and not to Buffer, i.e. does not point to the start of the buffer, but to 4 bytes after the start.Moreover, I have&amp;amp;
nbsp;one filter with a different filter order, which succeeds running on the dual core. when this filter runs, "State" and "Buffer" point to the same address.&lt;/P&gt;
&lt;P&gt;What Do I Do? Could this be related to alignment issues, and if so, what is the solution?&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Tomer&lt;/P&gt;</description>
    <pubDate>Tue, 08 May 2007 05:45:50 GMT</pubDate>
    <dc:creator>tomerme</dc:creator>
    <dc:date>2007-05-08T05:45:50Z</dc:date>
    <item>
      <title>IPP IIR Function</title>
      <link>https://community.intel.com/t5/Intel-Business-Client-Software/IPP-IIR-Function/m-p/863988#M2428</link>
      <description>&lt;P&gt;about a month ago i posted a question about the "ippsIIR"&lt;/P&gt;
&lt;P&gt;An application that had used this function was crashing on a Core 2 duo, and not on a regular Pentium 4 PC.&lt;/P&gt;
&lt;P&gt;It is still happening, but now i have some more details about the problem.&lt;/P&gt;
&lt;P&gt;&lt;U&gt;Here Is The Code I'm Using:&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;static std::vector&lt;IPPSIIRSTATE_64F&gt; pStateVec;&lt;/IPPSIIRSTATE_64F&gt;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;static std::vector&lt;IPP8U&gt; pBufferVec;&lt;/IPP8U&gt;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;int InitIIRFilter(const double NUM[], const double DEN[], int FilterOrder)&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;{&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;IppsIIRState_64f* State;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;int BufferSize;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;Ippstatus = ippsIIRGetStateSize_64f(FilterOrder,&amp;amp;BufferSize);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;assert(s==ippStsNoErr);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;Ipp8u* Buffer = new Ipp8u[BufferSize];&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;pBufferVec.push_back(Buffer);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;Ipp64f* pTaps =new Ipp64f[2*(FilterOrder+1)];&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;memcpy(pTaps, NUM, (FilterOrder+1)*sizeof(Ipp64f));&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;memcpy(pTaps+ (FilterOrder+1), DEN, (FilterOrder+1)*sizeof(Ipp64f));&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt; s = ippsIIRInit_64f(&amp;amp;State, pTaps, FilterOrder, NULL, Buffer);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;assert(s==ippStsNoErr);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;pStateVec.push_back(State);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt; delete [] pTaps;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;return static_cast&lt;INT&gt;(pStateVec.size()-1);&lt;/INT&gt;&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;}&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;void IIRFilter(const double FilterInput[], int len, &lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;double FilterOutput[],intindInFiltStruct)&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;{&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;IppStatus s = ippsIIR_64f(FilterInput, FilterOutput, len, pStateVec[indInFiltStruct]);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;assert(s==ippStsNoErr);&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face="Tahoma" size="2"&gt;}&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;The Terminate Function is not stated here&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;NOTES&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;When I debug this code on both PC's, I notice that on the single core, The Value of "State" assumes the Value of "Buffer", after IIRInit, i.e. , points to the start of the buffer, whereas, on the dual core, before the application crashes, "State" points to "Buffer" + 4 bytes, and not to Buffer, i.e. does not point to the start of the buffer, but to 4 bytes after the start.Moreover, I have&amp;amp;
nbsp;one filter with a different filter order, which succeeds running on the dual core. when this filter runs, "State" and "Buffer" point to the same address.&lt;/P&gt;
&lt;P&gt;What Do I Do? Could this be related to alignment issues, and if so, what is the solution?&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Tomer&lt;/P&gt;</description>
      <pubDate>Tue, 08 May 2007 05:45:50 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Business-Client-Software/IPP-IIR-Function/m-p/863988#M2428</guid>
      <dc:creator>tomerme</dc:creator>
      <dc:date>2007-05-08T05:45:50Z</dc:date>
    </item>
    <item>
      <title>Re: IPP IIR Function</title>
      <link>https://community.intel.com/t5/Intel-Business-Client-Software/IPP-IIR-Function/m-p/863989#M2429</link>
      <description>&lt;P&gt;Hi Tomer,&lt;/P&gt;
&lt;P&gt;I few of us have been trying to figure out how to answer you question.. Could you re-port the question in the threading forum? This is the managibility forum and we focus on Intel AMT and other such issues. I am affraid I can't help you with your threading problem.&lt;/P&gt;
&lt;P&gt;Thanks,&lt;BR /&gt;Ylian&lt;/P&gt;</description>
      <pubDate>Sat, 12 May 2007 23:42:04 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Business-Client-Software/IPP-IIR-Function/m-p/863989#M2429</guid>
      <dc:creator>Ylian_S_Intel</dc:creator>
      <dc:date>2007-05-12T23:42:04Z</dc:date>
    </item>
  </channel>
</rss>

