Skip to content

Commit 0929e2a

Browse files
committed
Merge remote-tracking branch 'origin/master' into master-next
2 parents 9dc2f64 + 03c2ff4 commit 0929e2a

File tree

6 files changed

+34
-10
lines changed

6 files changed

+34
-10
lines changed

test/ClangImporter/MixedSource/Inputs/AutolinkingTest.framework/AutolinkingTest

Whitespace-only changes.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
struct Test {
2+
int value;
3+
};
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
framework module AutolinkingTest {
2+
umbrella header "AutolinkingTest.h"
3+
export *
4+
module * { export * }
5+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// RUN: %target-swift-frontend %s -module-name AutolinkingTest -F %S/Inputs -import-underlying-module -emit-ir | %FileCheck %s
2+
3+
// Linux uses a different autolinking mechanism, based on
4+
// swift-autolink-extract. This file tests the Darwin mechanism.
5+
// UNSUPPORTED: OS=linux-gnu
6+
// UNSUPPORTED: OS=linux-gnueabihf
7+
// UNSUPPORTED: OS=freebsd
8+
// UNSUPPORTED: OS=linux-androideabi
9+
10+
// Use a type declared in the Clang part of the module.
11+
public let y = Test()
12+
13+
// CHECK: !llvm.linker.options
14+
// CHECK-NOT: !{!"-framework", !"AutolinkingTest"}
15+
// CHECK: !{!"-lswiftCore"}
16+
// CHECK-NOT: !{!"-framework", !"AutolinkingTest"}

test/Driver/bridging-pch.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
// RUN: %target-build-swift -typecheck -disable-bridging-pch -driver-print-jobs -import-objc-header %S/Inputs/bridging-header.h %s 2>&1 | %FileCheck %s -check-prefix=NOPCHJOB
1818
// NOPCHJOB: {{.*}}swift -frontend {{.*}} -import-objc-header {{.*}}Inputs/bridging-header.h
1919

20-
// RUN: echo "{\"\": {\"swift-dependencies\": \"master.swiftdeps\"}}" > %t.json
20+
// RUN: echo "{\"\": {\"swift-dependencies\": \"%t/master.swiftdeps\"}, \"%s\": {\"swift-dependencies\": \"%t/bridging-header.swiftdeps\"}}" > %t.json
2121
// RUN: %target-build-swift -typecheck -incremental -enable-bridging-pch -output-file-map %t.json -import-objc-header %S/Inputs/bridging-header.h %s
2222

2323
// RUN: mkdir %t/tmp

test/Driver/multi-threaded.swift

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
// RUN: echo "{\"%s\": {\"assembly\": \"/build/multi-threaded.s\"}, \"%S/Inputs/main.swift\": {\"assembly\": \"/build/main.s\"}}" > %t/ofms.json
44
// RUN: %target-swiftc_driver -driver-print-jobs -module-name=ThisModule -wmo -num-threads 4 %S/Inputs/main.swift %s -output-file-map %t/ofms.json -S | %FileCheck -check-prefix=ASSEMBLY %s
55
// RUN: %target-swiftc_driver -driver-print-jobs -module-name=ThisModule -wmo -num-threads 4 %S/Inputs/main.swift %s -c | %FileCheck -check-prefix=OBJECT %s
6-
// RUN: %target-swiftc_driver -parseable-output -module-name=ThisModule -wmo -num-threads 4 %S/Inputs/main.swift %s -c 2> %t/parseable-output
6+
// RUN: (cd %t && %target-swiftc_driver -parseable-output -module-name=ThisModule -wmo -num-threads 4 %S/Inputs/main.swift %s -c) 2> %t/parseable-output
77
// RUN: cat %t/parseable-output | %FileCheck -check-prefix=PARSEABLE %s
88
// RUN: (cd %t && env TMPDIR=/tmp %swiftc_driver -driver-print-jobs -module-name=ThisModule -wmo -num-threads 4 %S/Inputs/main.swift %s -o a.out ) | %FileCheck -check-prefix=EXEC %s
9-
// RUN: echo "{\"%s\": {\"llvm-bc\": \"multi-threaded.bc\", \"object\": \"%t/multi-threaded.o\"}, \"%S/Inputs/main.swift\": {\"llvm-bc\": \"main.bc\", \"object\": \"%t/main.o\"}}" > %t/ofmo.json
9+
// RUN: echo "{\"%s\": {\"llvm-bc\": \"%t/multi-threaded.bc\", \"object\": \"%t/multi-threaded.o\"}, \"%S/Inputs/main.swift\": {\"llvm-bc\": \"%t/main.bc\", \"object\": \"%t/main.o\"}}" > %t/ofmo.json
1010
// RUN: %target-swiftc_driver -module-name=ThisModule -wmo -num-threads 4 %S/Inputs/main.swift %s -emit-dependencies -output-file-map %t/ofmo.json -c
1111
// RUN: cat %t/*.d | %FileCheck -check-prefix=DEPENDENCIES %s
1212

@@ -42,9 +42,9 @@
4242
// BITCODE: -frontend
4343
// BITCODE-DAG: -num-threads 4
4444
// BITCODE-DAG: {{[^ ]*}}/Inputs/main.swift {{[^ ]*}}/multi-threaded.swift
45-
// BITCODE-DAG: -o main.bc -o multi-threaded.bc
46-
// BITCODE-DAG: -frontend -c -primary-file main.bc {{.*}} -o {{[^ ]*}}main.o
47-
// BITCODE-DAG: -frontend -c -primary-file multi-threaded.bc {{.*}} -o {{[^ ]*}}multi-threaded.o
45+
// BITCODE-DAG: -o {{.*}}/main.bc -o {{.*}}/multi-threaded.bc
46+
// BITCODE-DAG: -frontend -c -primary-file {{.*}}/main.bc {{.*}} -o {{[^ ]*}}main.o
47+
// BITCODE-DAG: -frontend -c -primary-file {{.*}}/multi-threaded.bc {{.*}} -o {{[^ ]*}}multi-threaded.o
4848
// BITCODE-NOT: ld
4949

5050
// PARSEABLE: "outputs": [
@@ -63,16 +63,16 @@
6363

6464
// PARSEABLE2: "name": "compile"
6565
// PARSEABLE2: "outputs": [
66-
// PARSEABLE2: "path": "main.bc"
67-
// PARSEABLE2: "path": "multi-threaded.bc"
66+
// PARSEABLE2: "path": "{{.*}}/main.bc"
67+
// PARSEABLE2: "path": "{{.*}}/multi-threaded.bc"
6868
// PARSEABLE2: "name": "backend"
6969
// PARSEABLE2: "inputs": [
70-
// PARSEABLE2: "main.bc"
70+
// PARSEABLE2: "{{.*}}/main.bc"
7171
// PARSEABLE2: "outputs": [
7272
// PARSEABLE2: "path": "{{.*}}/main.o"
7373
// PARSEABLE2: "name": "backend"
7474
// PARSEABLE2: "inputs": [
75-
// PARSEABLE2: "multi-threaded.bc"
75+
// PARSEABLE2: "{{.*}}/multi-threaded.bc"
7676
// PARSEABLE2: "outputs": [
7777
// PARSEABLE2: "path": "{{.*}}/multi-threaded.o"
7878

0 commit comments

Comments
 (0)