Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.
Announcements
FPGA community forums and blogs have moved to the Altera Community. Existing Intel Community members can sign in with their current credentials.

can't get simple ipp example to work

Phil_Stimac
Beginner
576 Views
I am completely new to using IPP and c++ and I need a hint on how to get a simple example to work. Below is the c++ code I would like to get working. Following that is the error message that I get. I thought all the environmental variable and such were set by including this in my .bashrc file: source /opt/intel/Compiler/11.1/064/ipp/em64t/tools/env/ippvarsem64t.sh
I have the Intel C++ 11.1 professional version for linux (rhel 5.2) installed and have checked that the ipp stuff works by running the scripts in perfsys.

Any help would be greatly appreciated! Many thanks.

______________________________________
#include "ipp.h"

using namespace std;

void func_autocorr();

int main ()
{
ippStaticInit();
func_autocorr();
return 0;
}

void func_autocorr()

{
Ipp32f pSrc[5] = {0.2, 3.1, 2.0, 1.2, -1.1};
const int dstLen = 10;
Ipp32f pDst[dstLen];
ippsAutoCorr_NormB_32f(pSrc, 5, pDst, dstLen);
}
_______________________________________

Here is the error that I get:

/tmp/icc56FrxX.o: In function `main':
walker.cpp:(.text+0x29): undefined reference to `ippStaticInit'
walker.cpp:(.text+0x69): undefined reference to `ippsAutoCorr_NormB_32f'
/tmp/icc56FrxX.o: In function `func_autocorr()':
walker.cpp:(.text+0xc0): undefined reference to `ippsAutoCorr_NormB_32f'


0 Kudos
2 Replies
Phil_Stimac
Beginner
576 Views
Quoting - Phil Stimac


I am completely new to using IPP and c++ and I need a hint on how to get a simple example to work. Below is the c++ code I would like to get working. Following that is the error message that I get. I thought all the environmental variable and such were set by including this in my .bashrc file: source /opt/intel/Compiler/11.1/064/ipp/em64t/tools/env/ippvarsem64t.sh
I have the Intel C++ 11.1 professional version for linux (rhel 5.2) installed and have checked that the ipp stuff works by running the scripts in perfsys.

Any help would be greatly appreciated! Many thanks.

______________________________________
#include "ipp.h"

using namespace std;

void func_autocorr();

int main ()
{
ippStaticInit();
func_autocorr();
return 0;
}

void func_autocorr()

{
Ipp32f pSrc[5] = {0.2, 3.1, 2.0, 1.2, -1.1};
const int dstLen = 10;
Ipp32f pDst[dstLen];
ippsAutoCorr_NormB_32f(pSrc, 5, pDst, dstLen);
}
_______________________________________

Here is the error that I get:

/tmp/icc56FrxX.o: In function `main':
walker.cpp:(.text+0x29): undefined reference to `ippStaticInit'
walker.cpp:(.text+0x69): undefined reference to `ippsAutoCorr_NormB_32f'
/tmp/icc56FrxX.o: In function `func_autocorr()':
walker.cpp:(.text+0xc0): undefined reference to `ippsAutoCorr_NormB_32f'



OK, we figured this out. I was not linking to the necessary libraries during compile time. Thanks.
0 Kudos
PaulF_IntelCorp
Employee
576 Views
Phil,

Glad you found the problem. I was about to write a reply when you posted yours. The part that was confusing me was a lack of error regarding ipp.h. I was thinking about the compiler, not the linker...

Paul

0 Kudos
Reply