This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [gomp4] Add tables generation
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Bernd Schmidt <bernds at codesourcery dot com>
- Cc: Thomas Schwinge <thomas at codesourcery dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>, Ilya Verbin <iverbin at gmail dot com>, Michael Zolotukhin <michael dot v dot zolotukhin at gmail dot com>
- Date: Tue, 8 Apr 2014 08:03:18 +0200
- Subject: Re: [gomp4] Add tables generation
- Authentication-results: sourceware.org; auth=none
- References: <532B1C45 dot 9020308 at codesourcery dot com> <20140320185619 dot GN1817 at tucnak dot redhat dot com> <532C5729 dot 5050101 at codesourcery dot com> <20140321152053 dot GS1817 at tucnak dot redhat dot com> <533E7BC9 dot 8000504 at codesourcery dot com> <87lhvjhl6e dot fsf at kepler dot schwinge dot homeip dot net> <53401FA1 dot 2060407 at codesourcery dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Sat, Apr 05, 2014 at 05:22:09PM +0200, Bernd Schmidt wrote:
> On 04/05/2014 05:04 PM, Thomas Schwinge wrote:
> >Is it a linker bug that I need to add something like the following?
> >
> >--- libgcc/ompstuff.c
> >+++ libgcc/ompstuff.c
> >@@ -40,6 +40,12 @@ see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
> > #include "libgcc_tm.h"
> >
> > #if defined(HAVE_GAS_HIDDEN) && defined(ENABLE_OFFLOADING)
> >+# if 1
> >+/* TODO: Without the following, will get missing symbols for __start_* and
> >+ __stop_*. Linker bug? */
> >+static void *_funcs[0] __attribute__ ((section ("__gnu_offload_funcs"))) = { };
> >+static void *_vars[0] __attribute__ ((section ("__gnu_offload_vars"))) = { };
> >+# endif
>
> Things seemed to work over here, but now I'm not certain whether the
> __start_/__stop_ functionality is GNU ld specific? Maybe we should
> just go back to the previous version of this patch which didn't try
> to use this.
Somebody needs to try it with gold, I think it should support the same.
As for other linkers, don't we need linker plugin support anyway, which is
not available for other linkers?
Jakub