[Bug fortran/119136] Printing result of function that prints itself hangs
kargl at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sun Jan 4 18:37:03 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119136
--- Comment #28 from Steve Kargl <kargl at gcc dot gnu.org> ---
(In reply to Thomas Koenig from comment #27)
> Created attachment 63214 [details]
> Patch based on ID comparison
>
> This patch uses Jerry's, adjusted for the comparison of the result
> of __gthread_self () to the locking unit.
>
> This passes regression-test on Linux with a new glibc, but it would be
> important to test this on a system where pthreads are not automatically
> linked.
>
> Any idea where this could be tested?
FWIW, the patch applies cleanly, builds, and
regression tests okay on x86_64-*-freebsd.
On FreeBSD, the -fopenmp will add the -pthread
option to the command line, which adds -lpthread
for the thread library. In the absences of
-pthread, -lpthread is not linked.
More information about the Gcc-bugs
mailing list