[PATCH] D85802: [clang] Add -fc++-abi= flag for specifying which C++ ABI to use

David Blaikie via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Oct 14 19:10:08 PDT 2022


dblaikie added a comment.

In D85802#3859540 <https://reviews.llvm.org/D85802#3859540>, @leonardchan wrote:

>> Naive question, but what does it mean to target Fuschia but be gnu-compatible? (how would that be different than using whatever gnu OS (linux, etc) the other code was built for)
>
> (Probably poor wording on my part.) When I mention gnu-compatible here, I don't mean ABI compatible to the OS but ABI compatible to whatever another compiler might generate. For example, if you want to use gcc to compile some code targeting fuchsia, gcc won't emit relative vtables but if you want to link against stuff like libcxx, libunwind, etc. then you'd need versions of those libs that also target fuchsia but would use the "regular" vtable layout.

Oh, I didn't mean to refer to the GNU OS - but I was trying to understand what you meant by gnu-compatible. Does GCC have a fuschia target? I'm trying to understand what compiler you're trying to be compatible with.

(this sounds sort of like either some non-fuschia ABI or that you have two Fuschia ABIs? & starts to remind me of the idea I've mentioned from time to time of a "floating" ABI flag that just says "this is whatever you want to do so long as Clang is consistent with itself at the same revision" and then a non-floating ABI. So are you trying to be compatible with an older version of Clang's Fuschia support when you mean "gnu-compatible"?)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85802/new/

https://reviews.llvm.org/D85802



More information about the cfe-commits mailing list