- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
int _tmain(int argc, _TCHAR* argv[]) { Ipp64f pSrc1[3*4] = { 1, 2, 3, 4, 5, 6, 7, 8, 4, 3, 2, 1 }; int src1Width = 4; int src1Height = 3; int src1Stride2 = sizeof(Ipp64f); int src1Stride1 = 4*sizeof(Ipp64f); /* Src2 matrix with width=3 and height=4 */ Ipp64f pSrc2[4*3] = { 1, 5, 4, 2, 6, 3, 3, 7, 2, 4, 8, 1 }; int src2Width = 3; int src2Height = 4; int src2Stride2 = sizeof(Ipp64f); int src2Stride1 = 3*sizeof(Ipp64f); /* // Destination matrix has width=src2Width=3 and height=src1Height=3 */ //Ipp64f pDst[3*3]; //<==allocated on stack. Will work. Ipp64f* pDst = ippsMalloc_64f( 9 ); //<== allocated on heap. Causing crash. If increase to 12 or larger bytes, it won't crash but will overran the pDst buffer. int dstStride2 = sizeof(Ipp64f); int dstStride1 = 3*sizeof(Ipp64f); IppStatus status = ippmMul_mm_64f((const Ipp64f*)pSrc1, src1Stride1, src1Stride2, src1Width, src1Height, (const Ipp64f*)pSrc2, src2Stride1, src2Stride2, src2Width, src2Height, pDst, dstStride1, dstStride2); ippsFree( pDst ); //<===== crash return 0; }
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Fan,
there is answer from our expert
Thisproblem isnt concern with any project building features. An unfortunatelythere is a bugin ippmMul functionin IPP5.0.
This mistake has been already fixed to IPP5.1. One workaround today is to use IPP5.0 ippmpx library instead of processor specific version (ippmw7).
PX version is correct.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for answering my question.
I have to say this: for tough technical problem, posting question on the forum is more effective than talking with premier tech-support.
I recall another post said the same thing.
Good work! Vladimir, althought I guess I did not get paid for QA IPP 5.0. :)
Fan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you. By the way, providing a way and possibilityfor quick answering such technical but easy to answer questionswas the main goal of creating this forum. We are glad that it work as expected:)
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
well, I apologize for the harsh words in the post above. If IPP wasn't an integral part of our product, I won't be pissed off like that.
FYI, I also tried regular dynmaic dll and static linkage with dispatch. It showed exactly the same results. I am not going to try that catch-all (px)version of IPP functions since it defeats the whole point of using IPP.
I would appreciate very much if host can forward this message to the IPP dev team. I could not log in the tech-support for some reason today.
Many thanks.
Fan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Fan,
thank you for reporting this issue again, we will double check this. It should be fixed in IPP v5.1 according engineering response.
We also will create issue on Premier for you.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Fan,
we are apologize if you still have issue with that functions. But IPP engineer has provided some modification of your test code. He successfully tested this with IPP v5.1. Could you please check if it solve your problem?
Engineer also commented that you probably use wrong size of destination matrix in case of both operands are transposed. Code below should demonstrate correct usage.
Code:
int _tmain(int argc, _TCHAR* argv[]) { Ipp64f pSrc1[3*4] = { 1, 2, 3, 4, 5, 6, 7, 8, 4, 3, 2, 1 }; int src1Width = 4; int src1Height = 3; int src1Stride2 = sizeof(Ipp64f); int src1Stride1 = 4*sizeof(Ipp64f); /* Src2 matrix with width=3 and height=4 */ Ipp64f pSrc2[4*3] = { 1, 5, 4, 2, 6, 3, 3, 7, 2, 4, 8, 1 }; int src2Width = 3; int src2Height = 4; int src2Stride2 = sizeof(Ipp64f); int src2Stride1 = 3*sizeof(Ipp64f); /* // As the both operands are transposed matrices // destination matrix has dstWidth=src2Height=4 and dstHeight=src1Width=4 */ //Ipp64f pDst[4*4]; . Ipp64f* pDst = ippsMalloc_64f( 16 ); int dstStride2 = sizeof(Ipp64f); int dstStride1 = 4*sizeof(Ipp64f); IppStatus status = ippmMul_tt_64f((const Ipp64f*)pSrc1, src1Stride1, src1Stride2, src1Width, src1Height, (const Ipp64f*)pSrc2, src2Stride1, src2Stride2, src2Width, src2Height, pDst, dstStride1, dstStride2); ippsFree( pDst ); return 0; } Destination matrix: 42.000000 44.000000 46.000000 48.000000 44.000000 49.000000 54.000000 59.000000 46.000000 54.000000 62.000000 70.000000 48.000000 59.000000 70.000000 81.000000
Anyway, I'll inform IPP engineers and technical support engineers to re-open your previus issue or to create new one, so you will get notification email to track status of that.
Thanks,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Vladimir,
I know I can count on you. :) I got emails from the tech-support acknowledging the case is re-opened.
I hope I was wrong in understanding the "transposeness" of a matrix. But in your code posted above, it does multiplication of two transposed matrices. That is not what I intend to do. I want to multiply two matrices as they are defined. We are testing two different IPP functions.
Actually, my original code was copied from a source from INTEL. If you look at the page 5-42 of the matrix manual, mine is almost identical to that code with trivial differences.
I still could not log into the tech-support. My bookmark did not work. It seems thatthe link on your site pointing to tech-supportcould not find the webpage either. Could you please point me to the right URL if the site is available right now please?
Thanks a bunch...
Fan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Fan,
could you please attach simple test case, so we can verify issue exactly on your code (with all that trivial changes). Just to be sure that we catch your case, because of no issues in our internal testing, which is good enough, to be honest.
Regarding accessing to technical support, please try to login to Intel Premier Support site.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
#include "stdafx.h" //#include "ipp.h" #include "IPPCustomDll.h" #includevoid main(int argc, char* argv[]) { /*const int SIZE = 256; Ipp8u pSrc[SIZE], pDst[SIZE]; int i; for (i=0; i = (Ipp8u)i; my_ippsCopy_8u(pSrc, pDst, SIZE); printf("pDst[%d] = %d ", SIZE-1, pDst[SIZE-1]);*/ Ipp64f pSrc1[3*4] = { 1, 2, 3, 4, 5, 6, 7, 8, 4, 3, 2, 1 }; int src1Width = 4; int src1Height = 3; int src1Stride2 = sizeof(Ipp64f); int src1Stride1 = 4*sizeof(Ipp64f); /* Src2 matrix with width=3 and height=4 */ Ipp64f pSrc2[4*3] = { 1, 5, 4, 2, 6, 3, 3, 7, 2, 4, 8, 1 }; int src2Width = 3; int src2Height = 4; int src2Stride2 = sizeof(Ipp64f); int src2Stride1 = 3*sizeof(Ipp64f); /* // Destination matrix has width=src2Width=3 and height=src1Height=3 */ //Ipp64f pDst[9]; Ipp64f* pDst = vs_ippsMalloc_64f( 9 ); //<== allocated on heap. int dstStride2 = sizeof(Ipp64f); int dstStride1 = 3*sizeof(Ipp64f); IppStatus status = vs_ippmMul_mm_64f((const Ipp64f*)pSrc1, src1Stride1, src1Stride2, src1Width, src1Height, (const Ipp64f*)pSrc2, src2Stride1, src2Stride2, src2Width, src2Height, pDst, dstStride1, dstStride2); vs_ippsFree( pDst ); //<===== crash return; }
Here is the code I used without any modification. It will crash at vs_ippsFree(...). The prefix "vs_" is added in my custom dll project. But I did try using IPP as regular DLL, in which case there is no "vs_", the problem still exists, at least it does on my machine...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, Vladimir.
I also linked that simple code with static library. But I got the same result. I am glad that finally we might getting close to where the problem is.
I am trying to reinstall IPP v.5.1. But it did not find my old license file and started asking for serial number. The serial number I have inside the CD box doesn't work. I already informed the tech-support on this issue. I bought v.4.1 with commerical license. I don't need to pay for v. 5.1, don't I ?
I will let you know if it works with my static library afterre-installing v. 5.1
Thanks.
Fan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear Fan,
We are working for ourregistration team for your account in our premier support . We will resend your the new password.
Regards,
Chao
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Fan,
thanks for updating on this. We glad that you find solution. Please feel free to communicate any issues.
Regards,
Vladimir
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page