- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hi,everybody,
I have finished a program calling the cryptography library in AMD64 bits machine.But I come across a trouble that I have no idea how to compile it to see whether it is right or not.It bores me a long time.
If someone knows the answer,can you tell me how to fix it?
Thanks~
Link Copied
- 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
Can gcc compile the program?
I run the command "gcc -o TestIpp TestIpp.c -I /opt/intel/ipp/6.1.2.051/em64t/include -L /opt/intel/ipp/6.1.2.051/em64t/sharedlib -lippiem64t -lippsem64t -lippcoreem64t -liomp5 -lm -lpthread"
Then,it returns some errors:
TestIpp.c:(.text+0x1d5): undefined reference to `ippsRijndael256GetSize'
TestIpp.c:(.text+0x1fc): undefined reference to `ippsRijndael256Init'
TestIpp.c:(.text+0x22e): undefined reference to `ippsRijndael256EncryptCFB'
it seems that the program doesn't link to the cryptography library, but I don't konw how to deal with it next
Can someone help me ?
Thank you ~
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I don't see a reference to the crypto library in your link list. The crypto libraries are a separate download, they are not included with the standard IPP library package. Visit this page in the IPP knowledge base:
Where Do I Download The Intel Ipp Cryptography Libraries
for information on how to download a copy of the crypto library add-on. Note that you must download and install the version of the crypto libraries that matches your IPP library. For example, if you installed IPP as part of the Intel Compiler Pro package then you need to download and install the Intel Compiler Pro Crypto library. The crypto add-on package will only install on top of its matching IPP installation.
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Finally, I noticed that you are using Intel IPP 6.1 update 2, you may check out the latest 6.1 update 4 and download the libraries from Intel Registration Center and upgrade it with your valid Intel IPP license.
Thanks,
Ying
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am sorry that I didn't mention I hadinstalled crytography library seperately above,but your answer gives me some ideas.
The path I install IPP library is :/opt/intel/ipp/6.1.2.051/em64t
The path I install cryptography library is :/opt/intel/ipp/6.1.2.051/em64t/l_crypto_ipp_em64t_p_6.1.2.051
WhenI compile the command:
gcc -o TestIpp TestIpp.c -I /opt/intel/ipp/6.1.2.051/em64t/include -L /opt/intel/ipp/6.1.2.051/em64t/sharedlib -lippiem64t -lippsem64t -lippcoreem64t -liomp5 -lm -lpthread
Then the errors return:
TestIpp.c:(.text+0x1d5): undefined reference to `ippsRijndael256GetSize'
TestIpp.c:(.text+0x1fc): undefined reference to `ippsRijndael256Init'
TestIpp.c:(.text+0x22e): undefined reference to `ippsRijndael256EncryptCFB'
Is it because the program doesn't link to the cryptography library?
And when I compile the main.c in the page of intel@ipp install guide, it runs correctly.
Thanks for the valuable suggestions~
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I add "-lippcpem64t" in the command and then it works.
Then command is as follows:
g++ -o TestIpp TestIpp.c -I /opt/intel/ipp/6.1.2.051/em64t/include -L /opt/intel/ipp/6.1.2.051/em64t/sharedlib -lippiem64t -lippsem64t -lippcoreem64t -lippcpem64t -liomp5 -lm -lpthread
Then it words~It's amazing
But I am surprise to find that the performance of IPP cryptography function is bad.
Is it because that the processor is AMD64bits or the command is wrong?
Call for help~
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Chen,
Not sure what you mean by "...or the command is wrong?" If you are referring to your the "g++" command line, it appears that everything is okay. Did you get any other compile or link errors?
What are you measuring your performance against?
The performance you get is SIMD architecture dependent; that is, different SSE instruction architectures can give different performance results. For example, the performance on a processor that supports AES-NI is different than the that on a machine that supports SSE4.1 versus SSSE3 versus SSE2, etc. You can compile and run the CPUINFO sample to see which SIMD architecture the library detects your machine to support.
Perhaps you need to use the ippInit() function?
Please review these two articles for more information about the dispatching feature of the library:
Understanding CPU Dispatching in the Intel IPP Library
IPP Dispatcher Control Functions - ipp*Init*() functions
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hello,Paul,
Thanks very much for your detail help !
Now I am testing the performance of Intel@IPP cryptography library against OpenSSL cryptography functions.
I have read the article titled "Boosting Cryptography Performance with Intel_ Libraries - Intel_ Software" and amazed to the performance of Intel@IPP cryptography functions , so I want to have a try.
The machine I am using is the AMD-64bits processor.Buttheresult is notsatisfy me.Even though I add ippInit() function,butthe performancedoesn't improve very much.
Some part of my program is as follows:
ippsRijndael256GetSize(&ctxsize);
IppsRijndael256Spec* pCtx = (IppsRijndael256Spec*)(new Ipp8u [ctxsize]);
ippsRijndael256Init(key,IppsRijndaelKey256,pCtx);
ippsRijndael256EncryptCFB(plaintext,ciphertext,len,32,pCtx,iv,IppsCPPaddingNONE);
It does works, but the performance is worse than OpenSSL functions.
Can you tell me the reasons?
Thank you ~
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have found the reason.
The performance is not very goodhas something to do with the processor, when I run the same program on a machine with Inter xeon processor ,the performance improve.
However,the performanceof Intel@IPP is just a little higher than that of Openssl,about 2% higher in my test.Thetest is to measure the cost time of encrypt. Some of my codes are as follows:
ippInit();
...
...
ippsRijndael256GetSize(&ctxsize);
IppsRijndael256Spec* pCtx = (IppsRijndael256Spec*)(new Ipp8u [ctxsize]);
ippsRijndael256Init(key,IppsRijndaelKey256,pCtx);
ippsRijndael256EncryptCFB(plaintext,ciphertext,len,32,pCtx,iv,IppsCPPaddingNONE);
...
...
I am puzzled with the result.
Wait for someone's help~
Thanks~
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page