[PATCH] D104386: [PowerPC][Builtins] Added a number of builtins for compatibility with XL.

Dimitry Andric via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Aug 31 03:53:50 PDT 2021


dim added subscribers: adalava, jhibbits.
dim added a comment.

In D104386#2973372 <https://reviews.llvm.org/D104386#2973372>, @nemanjai wrote:

> In D104386#2973245 <https://reviews.llvm.org/D104386#2973245>, @dim wrote:
>
>> Note that this unexpectedly broke FreeBSD's powerpc64 builds, as we've long used the following in our `lib/libc/powerpc64/string/bcopy.S`:

...

>> However, I think I can make do with adding `-U__bcopy` to the clang command line. It would have been nice if these aliases were behind some `--xl-compat` flag... :)
>
> I am really sorry that we broke you. Would it help if we defined this macro only if compiling for Linux/AIX? If so, are there any others (or perhaps all of them) that you'd like us to conditionally define only on AIX/Linux?

Well, it seems that `defineXLCompatMacros` was rather small in the beginning (when it was introduced in rG62b5df7fe2b3fda1772befeda15598fbef96a614 <https://reviews.llvm.org/rG62b5df7fe2b3fda1772befeda15598fbef96a614>) so there were not so many chances for collisions. This is probably why we've not noticed these definitions, and also because they're not there for clang <= 12. :)

That said, if you think there is a use case for sometimes compiling with the XL compiler on systems *other* than Linux/AIX, then your suggested workaround might not be adequate. @jhibbits @adalava did you ever use the XL compiler on FreeBSD?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D104386



More information about the cfe-commits mailing list