diff options
author | Justin Hibbits <chmeeedalf@gmail.com> | 2019-11-21 16:33:24 -0600 |
---|---|---|
committer | Justin Hibbits <chmeeedalf@gmail.com> | 2019-12-19 09:27:13 -0600 |
commit | d3aeac8e20fb3714eb69d6ed5838d57c7ddcd8e8 (patch) | |
tree | 3f35681e2c780634c94d2f3d600e6ad6b82fbd28 /llvm/test/CodeGen/PowerPC/available-externally.ll | |
parent | dcb48f50bdfa0fa47b62d089b6ed999d857fc9f8 (diff) | |
download | bcm5719-llvm-d3aeac8e20fb3714eb69d6ed5838d57c7ddcd8e8.tar.gz bcm5719-llvm-d3aeac8e20fb3714eb69d6ed5838d57c7ddcd8e8.zip |
[PowerPC] Only use PLT annotations if using PIC relocation model
Summary:
The default static (non-PIC, non-PIE) model for 32-bit powerpc does not
use @PLT annotations and relocations in GCC. LLVM shouldn't use @PLT
annotations either, because it breaks secure-PLT linking with (some
versions of?) GNU LD.
Update the available-externally.ll test to reflect that default mode should be
the same as the static relocation, by using the same check prefix.
Reviewed by: sfertile
Differential Revision: https://reviews.llvm.org/D70570
Diffstat (limited to 'llvm/test/CodeGen/PowerPC/available-externally.ll')
-rw-r--r-- | llvm/test/CodeGen/PowerPC/available-externally.ll | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/test/CodeGen/PowerPC/available-externally.ll b/llvm/test/CodeGen/PowerPC/available-externally.ll index 51b972bd3d7..ec83c67993b 100644 --- a/llvm/test/CodeGen/PowerPC/available-externally.ll +++ b/llvm/test/CodeGen/PowerPC/available-externally.ll @@ -1,3 +1,4 @@ +; RUN: llc -verify-machineinstrs < %s | FileCheck %s -check-prefix=STATIC ; RUN: llc -verify-machineinstrs < %s -relocation-model=static | FileCheck %s -check-prefix=STATIC ; RUN: llc -verify-machineinstrs < %s -relocation-model=pic -mtriple=powerpc-unknown-linux-gnu | FileCheck %s -check-prefix=PIC ; RUN: llc -verify-machineinstrs < %s -relocation-model=pic -mtriple=powerpc-unknown-linux | FileCheck %s -check-prefix=PICELF @@ -14,7 +15,7 @@ target triple = "powerpc-unknown-linux-gnu" define i32 @foo(i64 %x) nounwind { entry: ; STATIC: foo: -; STATIC: bl exact_log2@PLT +; STATIC: bl exact_log2 ; STATIC: blr ; PIC: foo: |