Re: [RFC] Target compilation for offloading

2013-11-19 Thread Andrey Turetskiy
Ping On Fri, Nov 15, 2013 at 7:45 PM, Andrey Turetskiy wrote: > Let's suppose, we are going to run target gcc driver from lto-wrapper. > How could a list of offload targets be passed there from option > parser? > In my opinion, the simpliest way to do it is to use environment > variable. Would yo

Re: [RFC] Target compilation for offloading

2013-11-15 Thread Andrey Turetskiy
Let's suppose, we are going to run target gcc driver from lto-wrapper. How could a list of offload targets be passed there from option parser? In my opinion, the simpliest way to do it is to use environment variable. Would you agree with such approach? On Fri, Nov 8, 2013 at 6:34 PM, Jakub Jelinek

Re: [RFC] Target compilation for offloading

2013-11-08 Thread Andrey Turetskiy
Thanks. And a few questions about compiler options: 1) You've mentioned two options for offloading: -foffload-target= - to specify targets for offloading -foffload-target-= - to specify compiler options for different targets Do we really need two options to set up offloading? What do you th

Re: [RFC] Target compilation for offloading

2013-11-08 Thread Jakub Jelinek
On Fri, Nov 08, 2013 at 06:26:53PM +0400, Andrey Turetskiy wrote: > Thanks. > And a few questions about compiler options: > 1) You've mentioned two options for offloading: > -foffload-target= - to specify targets for offloading > -foffload-target-= - to specify > compiler options for differ

Re: [RFC] Target compilation for offloading

2013-11-07 Thread Jakub Jelinek
On Thu, Nov 07, 2013 at 07:36:06PM +0400, Andrey Turetskiy wrote: > > Note, configure options should be either --with- or --enable- prefixed. > > Plus, it is probably better to use configuration triplets there. > > Do you mean smth like this: > configure --build=x86 --host=x86 --target=x86,mic,ptx

Re: [RFC] Target compilation for offloading

2013-11-07 Thread Andrey Turetskiy
> Note, configure options should be either --with- or --enable- prefixed. > Plus, it is probably better to use configuration triplets there. Do you mean smth like this: configure --build=x86 --host=x86 --target=x86,mic,ptx Then "make" should build 3 gcc: x86 native and crosses for mic and ptx. -

Re: [RFC] Target compilation for offloading

2013-11-06 Thread Jakub Jelinek
On Wed, Nov 06, 2013 at 05:11:07PM +0400, Andrey Turetskiy wrote: > > Let's check my understanding: > > 1) We can configure gcc with, say, --offload-target=mic,ptx. It means Note, configure options should be either --with- or --enable- prefixed. Plus, it is probably better to use configuration tri

Re: [RFC] Target compilation for offloading

2013-11-06 Thread Andrey Turetskiy
Ping On Thu, Oct 31, 2013 at 7:42 PM, Andrey Turetskiy wrote: > Let's check my understanding: > 1) We can configure gcc with, say, --offload-target=mic,ptx. It means > that after build and install we have 3 compilers: for host, for mic > and for ptx. In general case, the number may be less, becau

Re: [RFC] Target compilation for offloading

2013-10-31 Thread Andrey Turetskiy
Let's check my understanding: 1) We can configure gcc with, say, --offload-target=mic,ptx. It means that after build and install we have 3 compilers: for host, for mic and for ptx. In general case, the number may be less, because one compiler may suit more than one target/host (e.g.when host and on

Re: [RFC] Target compilation for offloading

2013-10-29 Thread Jakub Jelinek
On Tue, Oct 29, 2013 at 01:33:17PM +0400, Andrey Turetskiy wrote: > I wonder how compiler is going to choose which target binaries should > be created for offload? Will compiler make choice on its own or it is > the user who should add specific options like --offload-target=... > How does compiler

[RFC] Target compilation for offloading

2013-10-29 Thread Andrey Turetskiy
Hi Jakub, I wonder how compiler is going to choose which target binaries should be created for offload? Will compiler make choice on its own or it is the user who should add specific options like --offload-target=... How does compiler know paths to target compilers? Will it use environment variabl