--- Comment #7 from victor dot pasko at gmail dot com 2010-07-14 10:11
---
(In reply to comment #6)
> Please don't keep reopening this bug.
Why? I disagree with your resolution.
> The symbols are weak undefs because libgfortran doesn't require (and shouldn't
>
--- Comment #8 from victor dot pasko at gmail dot com 2010-07-16 03:55
---
You know, libgfortran works incorrectly with weak symbols from pthread :(
In case of static library it needs to call these functions only if its value is
not NULL.
So, the follwing is to be:
if
--- Comment #12 from victor dot pasko at gmail dot com 2010-07-19 10:25
---
Isn't really difficult to fix that in libgfortran sources by using:
if(pthread_cancel)
{
pthread_cancel(...);
}
instead of just
pthread_cancel(...);
as it is now.
--
--- Comment #14 from victor dot pasko at gmail dot com 2010-07-20 06:19
---
(In reply to comment #13)
> You clearly haven't looked at the code.
Yes, I didn't look at libgfortran sources.
However, I am not sure about 'terrible performance' if just two instructi
Version: 4.5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: victor dot pasko at gmail dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44927
--- Comment #2 from victor dot pasko at gmail dot com 2010-07-13 09:27
---
OK test PASSED after adding -Wl,--whole-archive -lpthread
-Wl,--no-whole-archive
But there is some strange warning:
% gfortran -static bug.f90 -lgomp -Wl,--whole-archive -lpthread
-Wl,--no-whole-archive -lrt
--- Comment #3 from victor dot pasko at gmail dot com 2010-07-13 12:01
---
I would like that it was possible to get correct static program by using just:
gfortran -static bug.f90 -fopenmp
--
victor dot pasko at gmail dot com changed:
What|Removed
--- Comment #5 from victor dot pasko at gmail dot com 2010-07-13 12:36
---
The root cause of the problem is in using weak symbol pthread_cancel in unit.o
object from libgfortran.a library. Why it's so?
Look:
% nm unit.o
04f0 T _gfortrani_close_unit
0