From d602a69210f10a50f1f81fdcf42350e43c41c891 Mon Sep 17 00:00:00 2001 From: 3405691582 Date: Tue, 19 Jan 2021 21:34:50 -0500 Subject: [PATCH] [test] These tests should check for codegen support. These tests checks for x86_64-* targets and armv7-* targets. If LLVM is not built with support for these targets, these tests will trip. It appears the way to check for this is by REQUIRES CODEGENERATOR, so add this to properly condition these tests. --- test/Interop/Cxx/class/constructors-copy-irgen.swift | 2 ++ test/Interop/Cxx/class/constructors-irgen.swift | 2 ++ 2 files changed, 4 insertions(+) diff --git a/test/Interop/Cxx/class/constructors-copy-irgen.swift b/test/Interop/Cxx/class/constructors-copy-irgen.swift index a0686ea021c72..32b68e996c8e5 100644 --- a/test/Interop/Cxx/class/constructors-copy-irgen.swift +++ b/test/Interop/Cxx/class/constructors-copy-irgen.swift @@ -1,5 +1,7 @@ // Target-specific tests for C++ copy constructor code generation. +// REQUIRES: CODEGENERATOR=ARM && CODEGENERATOR=X86 + // RUN: %swift -module-name Swift -target x86_64-apple-macosx10.9 -dump-clang-diagnostics -I %S/Inputs -enable-cxx-interop -emit-ir %s -parse-stdlib -parse-as-library -disable-legacy-type-info | %FileCheck %s -check-prefix=ITANIUM_X64 // RUN: %swift -module-name Swift -target armv7-none-linux-androideabi -dump-clang-diagnostics -I %S/Inputs -enable-cxx-interop -emit-ir %s -parse-stdlib -parse-as-library -disable-legacy-type-info | %FileCheck %s -check-prefix=ITANIUM_ARM // RUN: %swift -module-name Swift -target x86_64-unknown-windows-msvc -dump-clang-diagnostics -I %S/Inputs -enable-cxx-interop -emit-ir %s -parse-stdlib -parse-as-library -disable-legacy-type-info | %FileCheck %s -check-prefix=MICROSOFT_X64 diff --git a/test/Interop/Cxx/class/constructors-irgen.swift b/test/Interop/Cxx/class/constructors-irgen.swift index 85f2603feae42..ee60650203cee 100644 --- a/test/Interop/Cxx/class/constructors-irgen.swift +++ b/test/Interop/Cxx/class/constructors-irgen.swift @@ -1,5 +1,7 @@ // Target-specific tests for C++ constructor call code generation. +// REQUIRES: CODEGENERATOR=ARM && CODEGENERATOR=X86 + // RUN: %swift -module-name Swift -target x86_64-apple-macosx10.9 -dump-clang-diagnostics -I %S/Inputs -enable-cxx-interop -emit-ir %s -parse-stdlib -parse-as-library -disable-legacy-type-info | %FileCheck %s -check-prefix=ITANIUM_X64 // RUN: %swift -module-name Swift -target armv7-unknown-linux-androideabi -dump-clang-diagnostics -I %S/Inputs -enable-cxx-interop -emit-ir %s -parse-stdlib -parse-as-library -disable-legacy-type-info | %FileCheck %s -check-prefix=ITANIUM_ARM // RUN: %swift -module-name Swift -target x86_64-unknown-windows-msvc -dump-clang-diagnostics -I %S/Inputs -enable-cxx-interop -emit-ir %s -parse-stdlib -parse-as-library -disable-legacy-type-info | %FileCheck %s -check-prefix=MICROSOFT_X64