Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.

ippsDiv_32f_I crash on divide by zero

thorsan
Beginner
405 Views
Hi

In my application i do the following call:

[cpp]iSt = ippsDiv_32f_I(iPtr1,iPtr2,mLength);
[/cpp]
But this crashes when iPtr1 has a zero value (not the pointer but one of the values in the vector), and the peculiar thing is that it crashes only when I compile the thing in release mode. I am using IPP6.0 and MSVC 8.0. If I remove zero values from iPtr1, it all works nicely.

Thanks,
Thor Andreas

0 Kudos
4 Replies
Vladimir_Dudnik
Employee
405 Views
Thanks for the reporting on the issue. What platform you are running on? Is that IA32 based or EM64T?

Vladimir
0 Kudos
thorsan
Beginner
405 Views
Thanks for the reporting on the issue. What platform you are running on? Is that IA32 based or EM64T?

Vladimir
IA32.

Thor Andreas
0 Kudos
Vladimir_Dudnik
Employee
405 Views
Thanks, I submitted this as a bug report for you. IPP developers team will investigate this and we will come back to you with update on this.

Vladimir
0 Kudos
Gennady_F_Intel
Moderator
405 Views
Hiall,
right now I wasn't able to reproduce the problem.
I used MVSC 2008
IPP v.6.0
WinXP
CPU types were used for testing this case are:
- Intel Core 2 Duo CPU
and another one:
- Intel Core 2 QuAD CPU

Below the source code I used and the output I got:
+++++++++++++++
int main() {
IppStatus status = ippStsNoErr;
Ipp32f pSrc[4] = { 2, 20, 0, 200 };
Ipp32f pSrcDst[4] = { 100, 100, 100, 100 };
int len = 4;
status = ippsDiv_32f_I( pSrc, pSrcDst, len);
if( status != ippStsNoErr ){
printf( "Error: "%s" in position n", ippGetStatusString( status ));
}else{
printf("n PASSED n");
}
printf("pSrcDst = %lfn", pSrcDst[0]);
printf("pSrcDst = %lfn", pSrcDst[1]);
printf("pSrcDst = %lfn", pSrcDst[2]);
printf("pSrcDst = %lfn", pSrcDst[3]);
return 0;
}//main()
+++++++++++++++++

Error: "ippStsDivByZero: Zero value(s) of the divisor in the function Div" in position
pSrcDst = 50.000000
pSrcDst = 5.000000
pSrcDst = 1.#INF00
pSrcDst = 0.500000
Press any key to continue . . .
++++++++++++++++++++

as we can see, we have the expected behavior with this test.

--Gennady

0 Kudos
Reply