Andrew Pinski wrote: > On Mon, Aug 22, 2016 at 9:42 AM, Andy Ross <andrew.j.r...@intel.com> wrote: > > I don't follow. There's no change to the ABI, the generated code is > > identical in all cases. Can you explain what you mean? > > The encoding of int and long are different in C++. So if you have a > library built where you compiled it with the old compiler and try to > link it with the new one, the link will fail. Again try my simple > testcase and you will see that.
Ah, you're talking about symbol naming. Yeah, good point. That's sort of upsetting though. What's the path to getting this addressed then? Like I said newlib is schizo in its own headers on exactly this point, so it would already see the problem between C++ libraries compiled with gcc and putative other compilers that don't set __INT32_TYPE__ in exactly the same way (I checked btw: clang does set it, but not like gcc: it uses an "int" as there's no "newlib" support to tell it otherwise). I mean, it's sort of a mess. Can't we just fix it? Or deprecate --enable-newlib or something? Andy