[AIX] Avoid structor alias; die before bad alias codegen
authorHubert Tong <hubert.reinterpretcast@gmail.com>
Fri, 8 May 2020 20:29:58 +0000 (16:29 -0400)
committerHubert Tong <hubert.reinterpretcast@gmail.com>
Fri, 8 May 2020 20:51:34 +0000 (16:51 -0400)
commitb116ded57da3530e661f871f4191c59cd9e091cd
treec2cd1f88bb91b204968d8daa62a0e721b212f241
parentf66309deab1d99a17d6740244dfd1b9f959e9095
[AIX] Avoid structor alias; die before bad alias codegen

Summary:
`AsmPrinter::emitGlobalIndirectSymbol` is dependent on
`MCStreamer::emitAssignment` to produce `.set` directives for alias
symbols; however, the `.set` pseudo-op on AIX is documented as not
usable with external relocatable terms or expressions, which limits its
applicability in generating alias symbols.

Disable generating aliases on AIX until a different implementation
strategy is available.

Reviewers: cebowleratibm, jasonliu, sfertile, daltenty, DiggerLin

Reviewed By: jasonliu

Differential Revision: https://reviews.llvm.org/D79044
clang/lib/Driver/ToolChains/Clang.cpp
clang/test/Driver/aix-constructor-alias.c [new file with mode: 0644]
llvm/lib/Target/PowerPC/PPCAsmPrinter.cpp
llvm/test/CodeGen/PowerPC/aix-alias.ll [new file with mode: 0644]