diff --git a/clang/lib/CodeGen/CodeGenModule.cpp b/clang/lib/CodeGen/CodeGenModule.cpp index d57415352d0c5..489c08a4d4819 100644 --- a/clang/lib/CodeGen/CodeGenModule.cpp +++ b/clang/lib/CodeGen/CodeGenModule.cpp @@ -1192,7 +1192,8 @@ void CodeGenModule::Release() { getModule().addModuleFlag(llvm::Module::Min, "sign-return-address-with-bkey", 1); - if (getTriple().isOSLinux() && getTriple().isOSBinFormatELF()) { + if (getTriple().isOSLinux()) { + assert(getTriple().isOSBinFormatELF()); using namespace llvm::ELF; uint64_t PAuthABIVersion = (LangOpts.PointerAuthIntrinsics diff --git a/clang/test/CodeGen/aarch64-elf-pauthabi.c b/clang/test/CodeGen/aarch64-elf-pauthabi.c index c579bfed893c8..aa83ee3e0d7b0 100644 --- a/clang/test/CodeGen/aarch64-elf-pauthabi.c +++ b/clang/test/CodeGen/aarch64-elf-pauthabi.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-intrinsics \ // RUN: -fptrauth-calls \ // RUN: -fptrauth-returns \ @@ -8,27 +8,27 @@ // RUN: -fptrauth-init-fini %s | \ // RUN: FileCheck %s --check-prefix=ALL -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-intrinsics %s | FileCheck %s --check-prefix=INTRIN -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-calls %s | FileCheck %s --check-prefix=CALL -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-returns %s | FileCheck %s --check-prefix=RET -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-auth-traps %s | FileCheck %s --check-prefix=TRAP -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-calls -fptrauth-vtable-pointer-address-discrimination %s | \ // RUN: FileCheck %s --check-prefix=VPTRADDR -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-calls -fptrauth-vtable-pointer-type-discrimination %s | \ // RUN: FileCheck %s --check-prefix=VPTRTYPE -// RUN: %clang_cc1 -triple aarch64-linux -S -emit-llvm -o - \ +// RUN: %clang_cc1 -triple aarch64-linux -emit-llvm -o - \ // RUN: -fptrauth-calls -fptrauth-init-fini %s | \ // RUN: FileCheck %s --check-prefix=INITFINI