On 08/02/16 14:00, Tom de Vries wrote: > Hi, > > when running libgomp.c testsuite with "-flto -flto-partition=1to1 > -fno-toplevel-reorder" we run into many compilation failures like this: > ... > /tmp/xxxxxxxx.ltrans0.ltrans.o:(.gnu.offload_funcs+0x1a0): undefined > reference to `MAIN__._omp_fn.0'^M > ... > > The problem is that the offload table is in one lto partition, and the > function listed in the offload table is in another, without the function > having been promoted to be visible in the other partition. > > The patch fixes this by promoting the symbols in the offload table such > that they're visible in all partitions. > > Bootstrapped and reg-tested on x86_64. > > Build for nvidia accelerator and reg-tested libgomp with various lto > settings. > Added multi-source testcase target-3{7,8}.c that triggers the PR for intelmicemul accelerator. OK for trunk, stage1 (or stage4, if that's appropriate)? Thanks, - Tom