This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 0/2] Offloading from dlopened libraries
- From: Ilya Verbin <iverbin at gmail dot com>
- To: Jakub Jelinek <jakub at redhat dot com>, Thomas Schwinge <thomas at codesourcery dot com>, gcc-patches at gcc dot gnu dot org
- Cc: Kirill Yukhin <kirill dot yukhin at gmail dot com>
- Date: Mon, 12 Jan 2015 15:02:21 +0300
- Subject: Re: [PATCH 0/2] Offloading from dlopened libraries
- Authentication-results: sourceware.org; auth=none
- References: <20141113235354 dot GD28110 at msticlxl57 dot ims dot intel dot com>
Hi!
How about this patch? It adds a new symbol into GOMP_4.0.1 symver, so it would
be nice to include it into GCC 5 release.
On 14 Nov 02:53, Ilya Verbin wrote:
> This patch fixes offloading from dlopened libraries, part 1 is for libgomp and
> part 2 is for intelmic plugin.
>
> How it works:
> When a library is loaded it calls GOMP_offload_register as usually.
> At this time some devices may already be initialized, and some may be not.
> Therefore libgomp goes through all devices and for the initialized devices calls
> GOMP_OFFLOAD_load_image, then receives corresponding addresses and inserts them
> into splay tree. Also it fills offload_images array for lazy Initialization.
>
> When the library is unloaded it calls GOMP_offload_unregister.
> This function also need to go through all devices and to call
> GOMP_OFFLOAD_unload_image for all initialized devices. Also it removes mapped
> addresses from corresponding splay trees and pending images from the array.
>
> Any thoughts on that?
>
> Thomas, Julian,
> Will this approach work for OpenACC+PTX? I hope that it is general enough.
> Yeah, I understand that this change will require some efforts on your part to
> rebase the patches, but it would be good to define a common libgomp<->plugin
> interface as early as possible.
-- Ilya