Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
|
12-23-2012, 01:45 PM
|
#16
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
Edit: I did a google search after posting the info below. The only relevant looking hit I found listed that same error message as a symptom of a bug fixed in the Intel compiler version 11.1. What version do you have and what level of downloading patches have you done?
The error still might be a result of user error, so what I originally wrote might still apply:
-----------------------------------------------
Did you turn on multi-file optimization on purpose?
I've never gotten that to work. I work on big projects that are probably too big for Intel's multi-file optimization. I'm sure that if you give the right commands, that optimization can work for reasonable size projects. But I've never had occasion to want it in a reasonable size project.
If you didn't purposely turn it on, it should be easy to fix your command line to not turn it on.
If you do want multi-file optimization, I think you will need to read some tutorial on how to use it. Or ask in an Intel forum. Maybe start a new thread specifically about Intel Compiler multi-file optimization.
Anyway, I can't tell you how to use it.
Last edited by johnsfine; 12-23-2012 at 01:54 PM.
|
|
|
|
12-25-2012, 12:38 AM
|
#17
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
I am tring to run the Example using QR factorization in plasma(example_cgeqrf.c)
for compiling I run gcc-c pt.c -I/home/dalal/plasma-installer_2.5.0/plasma-installer_2.5.0b1/install/include
no problems in compiling.
for linking I run gcc -o exe pt2.o -L/home/dalal/plasma-installer_2.5.0/plasma-installer_2.5.0b1/install/lib -lplasma -lquark -lpthread -llapacke -lcoreblas -lcblas -ltmg -llapack -lm -L/opt/intel/mkl/lib/intel64 -lmkl_intel_lp64 -lmkl_sequential -lmkl_core
also there is no error but to execute:
./exe it give me the following error:
./exe: symbol lookup error: ./exe: undefined symbol: LAPACKE_cgeqr2_work
can you please help me to understand what going on and fix it?
Thanks
Last edited by dalal; 12-25-2012 at 04:47 AM.
|
|
|
|
12-25-2012, 06:58 AM
|
#18
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
After linking, you can use the following command to find out what .so files your exe depends on and whether those can be found with the default load time search for .so files
ldd exe
Please post the output of that. Before I can deduce any details of why a symbol might be missing at load time, I need to understand what .so files are needed/found.
But my best guess based on just the info you provided is that the linker found some version of liblapacke.so at link time, but the loader found a different version at load time. You need the one found at load time to be the same as the one found at link time.
There are a few different ways to control which .so files are found during load time. One way is to set the LD_LIBRARY_PATH environment variable before running the exe. Another is to specify the full path of the .so to the linker.
The first method could be done with a command such as
Code:
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/home/dalal/plasma-installer_2.5.0/plasma-installer_2.5.0b1/install/lib
In many of my projects, I have a tiny bash script for executing the program. The script sets LD_LIBRARY_PATH then executes the program. If you are doing the command manually rather than in a script, only do it once per shell session; don't do it again each time you run the exe.
I think the second method can be accomplished by using the full path and name of the .so file without a -l instead of -llapacke
Check the directory listing to be sure, but I think that full path and name might be:
/home/dalal/plasma-installer_2.5.0/plasma-installer_2.5.0b1/install/lib/liblapacke.so
I hope some other expert comments here. I'm not entirely confident the methods I have used for forcing the right .so to be found are best practice.
Last edited by johnsfine; 12-25-2012 at 07:14 AM.
|
|
|
|
12-25-2012, 07:02 AM
|
#19
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
linux-vdso.so.1 => (0x00007fffb19ff000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003576000000)
libm.so.6 => /lib64/libm.so.6 (0x0000003576800000)
libmkl_intel_lp64.so => /opt/share/INTEL/v11.1.075.app/ifort/mkl/lib/em64t/libmkl_intel_lp64.so (0x00007f7a8a70c000)
libmkl_sequential.so => /opt/share/INTEL/v11.1.075.app/ifort/mkl/lib/em64t/libmkl_sequential.so (0x00007f7a89dd5000)
libmkl_core.so => /opt/share/INTEL/v11.1.075.app/ifort/mkl/lib/em64t/libmkl_core.so (0x00007f7a89918000)
libc.so.6 => /lib64/libc.so.6 (0x0000003575c00000)
/lib64/ld-linux-x86-64.so.2 (0x0000003575400000)
libdl.so.2 => /lib64/libdl.so.2 (0x0000003575800000)
|
|
|
|
12-25-2012, 07:09 AM
|
#20
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
Actually I am not so familiar with these things, how you do know this is the reosone of this that error?, what i have to change now?
thanks
|
|
|
|
12-25-2012, 07:18 AM
|
#21
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
still give the same error!!!!!!!!!!
|
|
|
|
12-25-2012, 07:19 AM
|
#22
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
After seeing your ldd output I'm confused. Everything I guessed about liblapacke.so seems to be incorrect.
|
|
|
|
12-25-2012, 07:31 AM
|
#23
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
The sequence of the -l options in the link command matters. Generally you want high level packages before low level packages.
In my experience, an undefined symbol error caused by a sequence problem is reported at link time, not at load time. But maybe it is that kind of problem anyway.
When it is difficult to figure out the perfect sequence, you can fix the problem by repeating some of the -l options at the end of the command line.
Try adding another copy of -llapacke at the end of your link command line. If that changes any link time or load time behavior that indicates the problem was sequencing of -l options. If it doesn't change any behavior the problem was something else.
If adding that changes which symbols are undefined then the problem was sequence of -l options, but duplicating that one at the end wasn't enough to fix it (more rearrange or duplication of -l options is required).
Last edited by johnsfine; 12-25-2012 at 07:33 AM.
|
|
|
|
12-25-2012, 07:37 AM
|
#24
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
no changes the same error.
|
|
|
|
12-25-2012, 07:42 AM
|
#25
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
Where is liblapacke.a and/or liblapacke.so ?
If the linker didn't find that file at all, I'd expect an error at link time, which you haven't mentioned. But something is going wrong with use of that file at link time, so you need to start from there.
|
|
|
|
12-25-2012, 07:51 AM
|
#26
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
liblapacke.a is in plasma-installer_2.5.0/ plasma-installer_2.5.0b1/install/lib
there is any command to find the path of liblapacke.so ?
|
|
|
|
12-25-2012, 07:56 AM
|
#27
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
The linker only uses one or the other of those two files. I wasn't sure which. Since the .a is where the -L told the linker to find it, I assume that is the one the linker used.
At the moment, I have no idea why that undefined symbol would be reported at load time. If the symbol were needed and missing that should have been reported at link time.
No google search results exactly matched your issue, but one result hinted at a possibility:
http://icl.cs.utk.edu/plasma/forum/v...c.php?f=2&t=67
You might have installed a version of lapack that is too old to be compatible with your version of plasma.
Last edited by johnsfine; 12-25-2012 at 08:00 AM.
|
|
|
|
12-29-2012, 02:22 AM
|
#28
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
Iam tring to run example_dpotrf in plasma, no problem in compliling and linking but when I excute it it give me:
Floating point exception
what the mean of this? how I can solve this error?
Thanks
|
|
|
|
12-29-2012, 02:47 AM
|
#29
|
|
LQ Newbie
Registered: Dec 2012
Posts: 17
Original Poster
Rep: 
|
I am tring to run example_dpotrf in plasma, no problems in compiling nor in linking, but when I excute it, it gives:
Floating point exception.
what is the mean of this error and how to solve this problem?
Thanks
|
|
|
|
12-29-2012, 07:36 AM
|
#30
|
|
Senior Member
Registered: Dec 2007
Distribution: Mepis, Centos
Posts: 4,674
|
I'm not sure why floating point exceptions are turned on in your example. I thought they were turned off by default.
There should be some way to turn them off. Try google yourself this time.
Various operations such as divide by zero produce floating point exceptions if those are enabled, but produce INF and NaN values if floating point exceptions are disabled. So the problem may be that your data is bad. If you had better data, you could avoid the floating point exceptions without disabling them.
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 05:53 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|