[gomp4] Add tables generation
Bernd Schmidt
bernds@codesourcery.com
Thu Mar 27 13:59:00 GMT 2014
On 03/27/2014 02:31 PM, Ilya Verbin wrote:
>> +#ifdef ACCEL_COMPILER
>> + /* Decls are placed in reversed order in fat-objects, so we need to
>> + revert them back if we compile target. */
>> ...
>
> Actually this change is incorrect. If host binary is built with -flto, then
> both host gcc and target gcc read decls from lto and target_lto sections in the
> same order, and resulting tables are identical.
> So, in this case there is no need to change the order.
>
> But what if one wants to link non-lto host object files with a target image,
> produced from target_lto sections?
> In this case the order of host table, produced during ordinary compilation will
> differ from the order of target table, produced during lto compilation.
I haven't looked into the ordering issue here (the reversing of the
order is from Michael's original patch), because I still think the whole
scheme can't work and I was intending to produce a testcase to
demonstrate that. Looks like you saved me some time here :)
My suggestion would be to augment the tables with the unique-name scheme
I posted previously. I think the objections against it were a little
exaggerated, and it would ensure reliability.
Bernd
More information about the Gcc-patches
mailing list