diff options
author | David Chisnall <csdavec@swan.ac.uk> | 2018-08-10 12:53:13 +0000 |
---|---|---|
committer | David Chisnall <csdavec@swan.ac.uk> | 2018-08-10 12:53:13 +0000 |
commit | 93ce018f3d1a84a463e5a2c4b0d2a445c91e933d (patch) | |
tree | 97f7ab98f3b7a2331262d63109166af35a2c2ba0 /clang/test | |
parent | bebcd6fa4d2cbac48401bb95befb58dc81f6e54e (diff) | |
download | bcm5719-llvm-93ce018f3d1a84a463e5a2c4b0d2a445c91e933d.tar.gz bcm5719-llvm-93ce018f3d1a84a463e5a2c4b0d2a445c91e933d.zip |
Add Windows support for the GNUstep Objective-C ABI V2.
Summary:
Introduces funclet-based unwinding for Objective-C and fixes an issue
where global blocks can't have their isa pointers initialised on
Windows.
After discussion with Dustin, this changes the name mangling of
Objective-C types to prevent a C++ catch statement of type struct X*
from catching an Objective-C object of type X*.
Reviewers: rjmccall, DHowett-MSFT
Reviewed By: rjmccall, DHowett-MSFT
Subscribers: mgrang, mstorsjo, smeenai, cfe-commits
Differential Revision: https://reviews.llvm.org/D50144
llvm-svn: 339428
Diffstat (limited to 'clang/test')
-rw-r--r-- | clang/test/CodeGenObjC/gnu-init.m | 39 | ||||
-rw-r--r-- | clang/test/CodeGenObjC/gnustep2-proto.m | 6 | ||||
-rw-r--r-- | clang/test/CodeGenObjCXX/arc-marker-funclet.mm | 2 | ||||
-rw-r--r-- | clang/test/CodeGenObjCXX/microsoft-abi-arc-param-order.mm | 2 | ||||
-rw-r--r-- | clang/test/CodeGenObjCXX/msabi-objc-extensions.mm | 38 | ||||
-rw-r--r-- | clang/test/CodeGenObjCXX/msabi-objc-types.mm | 114 |
6 files changed, 118 insertions, 83 deletions
diff --git a/clang/test/CodeGenObjC/gnu-init.m b/clang/test/CodeGenObjC/gnu-init.m index beb06bbe0df..de07c401858 100644 --- a/clang/test/CodeGenObjC/gnu-init.m +++ b/clang/test/CodeGenObjC/gnu-init.m @@ -1,4 +1,5 @@ // RUN: %clang_cc1 -triple x86_64-unknown-freebsd -S -emit-llvm -fobjc-runtime=gnustep-2.0 -o - %s | FileCheck %s -check-prefix=CHECK-NEW +// RUN: %clang_cc1 -triple x86_64-pc-windows-msvc -S -emit-llvm -fobjc-runtime=gnustep-2.0 -o - %s | FileCheck %s -check-prefix=CHECK-WIN // RUN: %clang_cc1 -triple x86_64-unknown-freebsd -S -emit-llvm -fobjc-runtime=gnustep-1.8 -o - %s | FileCheck %s -check-prefix=CHECK-OLD // Almost minimal Objective-C file, check that it emits calls to the correct @@ -49,9 +50,9 @@ // CHECK-NEW: @.objc_null_class_alias = linkonce_odr hidden global { i8*, i8* } zeroinitializer, section "__objc_class_aliases", comdat, align 8 // CHECK-NEW: @.objc_null_constant_string = linkonce_odr hidden global { i8*, i32, i32, i32, i32, i8* } zeroinitializer, section "__objc_constant_string", comdat, align 8 // Make sure that the null symbols are not going to be removed, even by linking. -// CHECK-NEW: @llvm.used = appending global [7 x i8*] [i8* bitcast ({ { i8*, i8*, i8*, i64, i64, i64, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i64, i8* }*, i8*, i8*, i64, i64, i64, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i64, i8* }** @._OBJC_INIT_CLASS_X to i8*), i8* bitcast ({ i8*, i8* }* @.objc_null_selector to i8*), i8* bitcast ({ i8*, i8*, i8*, i8*, i8*, i8*, i8* }* @.objc_null_category to i8*), i8* bitcast ({ i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8* }* @.objc_null_protocol to i8*), i8* bitcast ({ i8* }* @.objc_null_protocol_ref to i8*), i8* bitcast ({ i8*, i8* }* @.objc_null_class_alias to i8*), i8* bitcast ({ i8*, i32, i32, i32, i32, i8* }* @.objc_null_constant_string to i8*)], section "llvm.metadata" +// CHECK-NEW: @llvm.used = appending global [8 x i8*] [i8* bitcast ({ { i8*, i8*, i8*, i64, i64, i64, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i64, i8* }*, i8*, i8*, i64, i64, i64, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i64, i8* }** @._OBJC_INIT_CLASS_X to i8*), i8* bitcast (void ()** @.objc_ctor to i8*), i8* bitcast ({ i8*, i8* }* @.objc_null_selector to i8*), i8* bitcast ({ i8*, i8*, i8*, i8*, i8*, i8*, i8* }* @.objc_null_category to i8*), i8* bitcast ({ i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8* }* @.objc_null_protocol to i8*), i8* bitcast ({ i8* }* @.objc_null_protocol_ref to i8*), i8* bitcast ({ i8*, i8* }* @.objc_null_class_alias to i8*), i8* bitcast ({ i8*, i32, i32, i32, i32, i8* }* @.objc_null_constant_string to i8*)], section "llvm.metadata" // Make sure that the load function and the reference to it are marked as used. -// CHECK-NEW: @llvm.compiler.used = appending global [2 x i8*] [i8* bitcast (void ()* @.objcv2_load_function to i8*), i8* bitcast (void ()** @.objc_ctor to i8*)], section "llvm.metadata" +// CHECK-NEW: @llvm.compiler.used = appending global [1 x i8*] [i8* bitcast (void ()* @.objcv2_load_function to i8*)], section "llvm.metadata" // Check that we emit the load function in a comdat and that it does the right thing. // CHECK-NEW: define linkonce_odr hidden void @.objcv2_load_function() comdat { @@ -67,3 +68,37 @@ // CHECK-OLD-NEXT: entry: // CHECK-OLD-NEXT: call void ({ i64, i64, i8*, { i64, { i8*, i8* }*, i16, i16, [4 x i8*] }* }*, ...) @__objc_exec_class({ i64, i64, i8*, { i64, { i8*, i8* }*, i16, i16, [4 x i8*] }* }* @4) + + +// Make sure all of our section boundary variables are emitted correctly. +// CHECK-WIN: @__start___objc_selectors = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_selectors$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_selectors = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_selectors$z", comdat, align 1 +// CHECK-WIN: @__start___objc_classes = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_classes$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_classes = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_classes$z", comdat, align 1 +// CHECK-WIN: @__start___objc_class_refs = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_class_refs$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_class_refs = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_class_refs$z", comdat, align 1 +// CHECK-WIN: @__start___objc_cats = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_cats$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_cats = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_cats$z", comdat, align 1 +// CHECK-WIN: @__start___objc_protocols = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_protocols$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_protocols = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_protocols$z", comdat, align 1 +// CHECK-WIN: @__start___objc_protocol_refs = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_protocol_refs$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_protocol_refs = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_protocol_refs$z", comdat, align 1 +// CHECK-WIN: @__start___objc_class_aliases = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_class_aliases$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_class_aliases = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_class_aliases$z", comdat, align 1 +// CHECK-WIN: @__start___objc_constant_string = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_constant_string$a", comdat, align 1 +// CHECK-WIN: @__stop__objc_constant_string = linkonce_odr hidden global %.objc_section_sentinel zeroinitializer, section "__objc_constant_string$z", comdat, align 1 +// CHECK-WIN: @.objc_init = linkonce_odr hidden global { i64, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel*, %.objc_section_sentinel* } { i64 0, %.objc_section_sentinel* @__start___objc_selectors, %.objc_section_sentinel* @__stop__objc_selectors, %.objc_section_sentinel* @__start___objc_classes, %.objc_section_sentinel* @__stop__objc_classes, %.objc_section_sentinel* @__start___objc_class_refs, %.objc_section_sentinel* @__stop__objc_class_refs, %.objc_section_sentinel* @__start___objc_cats, %.objc_section_sentinel* @__stop__objc_cats, %.objc_section_sentinel* @__start___objc_protocols, %.objc_section_sentinel* @__stop__objc_protocols, %.objc_section_sentinel* @__start___objc_protocol_refs, %.objc_section_sentinel* @__stop__objc_protocol_refs, %.objc_section_sentinel* @__start___objc_class_aliases, %.objc_section_sentinel* @__stop__objc_class_aliases, %.objc_section_sentinel* @__start___objc_constant_string, %.objc_section_sentinel* @__stop__objc_constant_string }, comdat, align 8 + +// Make sure our init variable is in the correct section for late library init. +// CHECK-WIN: @.objc_ctor = linkonce hidden constant void ()* @.objcv2_load_function, section ".CRT$XCLz", comdat + +// We shouldn't have emitted any null placeholders on Windows. +// CHECK-WIN: @llvm.used = appending global [2 x i8*] [i8* bitcast ({ { i8*, i8*, i8*, i32, i32, i32, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i32, i8* }*, i8*, i8*, i32, i32, i32, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i8*, i32, i8* }** @._OBJC_INIT_CLASS_X to i8*), i8* bitcast (void ()** @.objc_ctor to i8*)], section "llvm.metadata" +// CHECK-WIN: @llvm.compiler.used = appending global [1 x i8*] [i8* bitcast (void ()* @.objcv2_load_function to i8*)], section "llvm.metadata" + +// Check our load function is in a comdat. +// CHECK-WIN: define linkonce_odr hidden void @.objcv2_load_function() comdat { + +// Make sure we have dllimport on the load function +// CHECK-WIN: declare dllimport void @__objc_load + diff --git a/clang/test/CodeGenObjC/gnustep2-proto.m b/clang/test/CodeGenObjC/gnustep2-proto.m index 536714f03a9..8550b0fb2d9 100644 --- a/clang/test/CodeGenObjC/gnustep2-proto.m +++ b/clang/test/CodeGenObjC/gnustep2-proto.m @@ -22,11 +22,11 @@ // Check that we're emitting the protocol and a correctly initialised // indirection variable. -// CHECK: @._OBJC_PROTOCOL_X = global +// CHECK: @._OBJC_PROTOCOL_X = global // CHECK-SAME: , section "__objc_protocols", comdat, align 8 -// CHECK: @._OBJC_REF_PROTOCOL_X = global +// CHECK: @._OBJC_REF_PROTOCOL_X = linkonce_odr global // CHECK-SAME: @._OBJC_PROTOCOL_X -// CHECK-SAME: , section "__objc_protocol_refs", align 8 +// CHECK-SAME: , section "__objc_protocol_refs", comdat, align 8 // Check that we load from the indirection variable on protocol references. diff --git a/clang/test/CodeGenObjCXX/arc-marker-funclet.mm b/clang/test/CodeGenObjCXX/arc-marker-funclet.mm index 900c2788dae..6ad0acd6878 100644 --- a/clang/test/CodeGenObjCXX/arc-marker-funclet.mm +++ b/clang/test/CodeGenObjCXX/arc-marker-funclet.mm @@ -10,7 +10,7 @@ void g() { } } -// CHECK: call i8* @"?f@@YAPAUobjc_object@@XZ"() [ "funclet"(token %1) ] +// CHECK: call i8* @"?f@@YAPAU.objc_object@@XZ"() [ "funclet"(token %1) ] // CHECK-NEXT: call void asm sideeffect "movl{{.*}}%ebp, %ebp{{.*}}", ""() [ "funclet"(token %1) ] // The corresponding f() call was invoked from the entry basic block. diff --git a/clang/test/CodeGenObjCXX/microsoft-abi-arc-param-order.mm b/clang/test/CodeGenObjCXX/microsoft-abi-arc-param-order.mm index 910a7db7340..125f8821ef2 100644 --- a/clang/test/CodeGenObjCXX/microsoft-abi-arc-param-order.mm +++ b/clang/test/CodeGenObjCXX/microsoft-abi-arc-param-order.mm @@ -9,7 +9,7 @@ struct A { // Verify that we destruct things from left to right in the MS C++ ABI: a, b, c, d. // -// CHECK-LABEL: define dso_local void @"?test_arc_order@@YAXUA@@PAUobjc_object@@01@Z" +// CHECK-LABEL: define dso_local void @"?test_arc_order@@YAXUA@@PAU.objc_object@@01@Z" // CHECK: (<{ %struct.A, i8*, %struct.A, i8* }>* inalloca) void test_arc_order(A a, id __attribute__((ns_consumed)) b , A c, id __attribute__((ns_consumed)) d) { // CHECK: call x86_thiscallcc void @"??1A@@QAE@XZ"(%struct.A* %{{.*}}) diff --git a/clang/test/CodeGenObjCXX/msabi-objc-extensions.mm b/clang/test/CodeGenObjCXX/msabi-objc-extensions.mm index 2f724a985f3..d3c77dddb4d 100644 --- a/clang/test/CodeGenObjCXX/msabi-objc-extensions.mm +++ b/clang/test/CodeGenObjCXX/msabi-objc-extensions.mm @@ -6,61 +6,61 @@ @class I; void f(id<P>, id, id<P>, id) {} -// CHECK-LABEL: "?f@@YAXPAU?$objc_object@U?$Protocol@UP@@@__ObjC@@@@PAUobjc_object@@01@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_object@U?$Protocol@UP@@@__ObjC@@@@PAU.objc_object@@01@Z" void f(id, id<P>, id<P>, id) {} -// CHECK-LABEL: "?f@@YAXPAUobjc_object@@PAU?$objc_object@U?$Protocol@UP@@@__ObjC@@@@10@Z" +// CHECK-LABEL: "?f@@YAXPAU.objc_object@@PAU?$.objc_object@U?$Protocol@UP@@@__ObjC@@@@10@Z" void f(id<P>, id<P>) {} -// CHECK-LABEL: "?f@@YAXPAU?$objc_object@U?$Protocol@UP@@@__ObjC@@@@0@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_object@U?$Protocol@UP@@@__ObjC@@@@0@Z" void f(id<P>) {} -// CHECK-LABEL: "?f@@YAXPAU?$objc_object@U?$Protocol@UP@@@__ObjC@@@@@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_object@U?$Protocol@UP@@@__ObjC@@@@@Z" void f(id<P, Q>) {} -// CHECK-LABEL: "?f@@YAXPAU?$objc_object@U?$Protocol@UP@@@__ObjC@@U?$Protocol@UQ@@@2@@@@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_object@U?$Protocol@UP@@@__ObjC@@U?$Protocol@UQ@@@2@@@@Z" void f(Class<P>) {} -// CHECK-LABEL: "?f@@YAXPAU?$objc_class@U?$Protocol@UP@@@__ObjC@@@@@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_class@U?$Protocol@UP@@@__ObjC@@@@@Z" void f(Class<P, Q>) {} -// CHECK-LABEL: "?f@@YAXPAU?$objc_class@U?$Protocol@UP@@@__ObjC@@U?$Protocol@UQ@@@2@@@@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_class@U?$Protocol@UP@@@__ObjC@@U?$Protocol@UQ@@@2@@@@Z" void f(I<P> *) {} -// CHECK-LABEL: "?f@@YAXPAU?$I@U?$Protocol@UP@@@__ObjC@@@@@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_cls_I@U?$Protocol@UP@@@__ObjC@@@@@Z" void f(I<P, Q> *) {} -// CHECK-LABEL: "?f@@YAXPAU?$I@U?$Protocol@UP@@@__ObjC@@U?$Protocol@UQ@@@2@@@@Z" +// CHECK-LABEL: "?f@@YAXPAU?$.objc_cls_I@U?$Protocol@UP@@@__ObjC@@U?$Protocol@UQ@@@2@@@@Z" template <typename> struct S {}; void f(S<__unsafe_unretained id>) {} -// CHECK-LABEL: "?f@@YAXU?$S@PAUobjc_object@@@@@Z" +// CHECK-LABEL: "?f@@YAXU?$S@PAU.objc_object@@@@@Z" void f(S<__autoreleasing id>) {} -// CHECK-LABEL: "?f@@YAXU?$S@U?$Autoreleasing@PAUobjc_object@@@__ObjC@@@@@Z" +// CHECK-LABEL: "?f@@YAXU?$S@U?$Autoreleasing@PAU.objc_object@@@__ObjC@@@@@Z" void f(S<__strong id>) {} -// CHECK-LABEL: "?f@@YAXU?$S@U?$Strong@PAUobjc_object@@@__ObjC@@@@@Z" +// CHECK-LABEL: "?f@@YAXU?$S@U?$Strong@PAU.objc_object@@@__ObjC@@@@@Z" void f(S<__weak id>) {} -// CHECK-LABEL: "?f@@YAXU?$S@U?$Weak@PAUobjc_object@@@__ObjC@@@@@Z" +// CHECK-LABEL: "?f@@YAXU?$S@U?$Weak@PAU.objc_object@@@__ObjC@@@@@Z" void w(__weak id) {} -// CHECK-LABEL: "?w@@YAXPAUobjc_object@@@Z" +// CHECK-LABEL: "?w@@YAXPAU.objc_object@@@Z" void s(__strong id) {} -// CHECK-LABEL: "?s@@YAXPAUobjc_object@@@Z" +// CHECK-LABEL: "?s@@YAXPAU.objc_object@@@Z" void a(__autoreleasing id) {} -// CHECK-LABEL: "?a@@YAXPAUobjc_object@@@Z" +// CHECK-LABEL: "?a@@YAXPAU.objc_object@@@Z" void u(__unsafe_unretained id) {} -// CHECK-LABEL: "?u@@YAXPAUobjc_object@@@Z" +// CHECK-LABEL: "?u@@YAXPAU.objc_object@@@Z" S<__autoreleasing id> g() { return S<__autoreleasing id>(); } -// CHECK-LABEL: "?g@@YA?AU?$S@U?$Autoreleasing@PAUobjc_object@@@__ObjC@@@@XZ" +// CHECK-LABEL: "?g@@YA?AU?$S@U?$Autoreleasing@PAU.objc_object@@@__ObjC@@@@XZ" __autoreleasing id h() { return nullptr; } -// CHECK-LABEL: "?h@@YAPAUobjc_object@@XZ" +// CHECK-LABEL: "?h@@YAPAU.objc_object@@XZ" diff --git a/clang/test/CodeGenObjCXX/msabi-objc-types.mm b/clang/test/CodeGenObjCXX/msabi-objc-types.mm index 192dd4c23ff..08807bbe1a5 100644 --- a/clang/test/CodeGenObjCXX/msabi-objc-types.mm +++ b/clang/test/CodeGenObjCXX/msabi-objc-types.mm @@ -3,166 +3,166 @@ @class I; id kid; -// CHECK: @"?kid@@3PAUobjc_object@@A" = dso_local global +// CHECK: @"?kid@@3PAU.objc_object@@A" = dso_local global Class klass; -// CHECK: @"?klass@@3PAUobjc_class@@A" = dso_local global +// CHECK: @"?klass@@3PAU.objc_class@@A" = dso_local global I *kI; -// CHECK: @"?kI@@3PAUI@@A" = dso_local global +// CHECK: @"?kI@@3PAU.objc_cls_I@@A" = dso_local global void f(I *) {} -// CHECK-LABEL: "?f@@YAXPAUI@@@Z" +// CHECK-LABEL: "?f@@YAXPAU.objc_cls_I@@@Z" void f(const I *) {} -// CHECK-LABEL: "?f@@YAXPBUI@@@Z" +// CHECK-LABEL: "?f@@YAXPBU.objc_cls_I@@@Z" void f(I &) {} -// CHECK-LABEL: "?f@@YAXAAUI@@@Z" +// CHECK-LABEL: "?f@@YAXAAU.objc_cls_I@@@Z" void f(const I &) {} -// CHECK-LABEL: "?f@@YAXABUI@@@Z" +// CHECK-LABEL: "?f@@YAXABU.objc_cls_I@@@Z" void f(const I &&) {} -// CHECK-LABEL: "?f@@YAX$$QBUI@@@Z" +// CHECK-LABEL: "?f@@YAX$$QBU.objc_cls_I@@@Z" void g(id) {} -// CHECK-LABEL: "?g@@YAXPAUobjc_object@@@Z" +// CHECK-LABEL: "?g@@YAXPAU.objc_object@@@Z" void g(id &) {} -// CHECK-LABEL: "?g@@YAXAAPAUobjc_object@@@Z" +// CHECK-LABEL: "?g@@YAXAAPAU.objc_object@@@Z" void g(const id &) {} -// CHECK-LABEL: "?g@@YAXABQAUobjc_object@@@Z" +// CHECK-LABEL: "?g@@YAXABQAU.objc_object@@@Z" void g(id &&) {} -// CHECK-LABEL: "?g@@YAX$$QAPAUobjc_object@@@Z" +// CHECK-LABEL: "?g@@YAX$$QAPAU.objc_object@@@Z" void h(Class) {} -// CHECK-LABEL: "?h@@YAXPAUobjc_class@@@Z" +// CHECK-LABEL: "?h@@YAXPAU.objc_class@@@Z" void h(Class &) {} -// CHECK-LABEL: "?h@@YAXAAPAUobjc_class@@@Z" +// CHECK-LABEL: "?h@@YAXAAPAU.objc_class@@@Z" void h(const Class &) {} -// CHECK-LABEL: "?h@@YAXABQAUobjc_class@@@Z" +// CHECK-LABEL: "?h@@YAXABQAU.objc_class@@@Z" void h(Class &&) {} -// CHECK-LABEL: "?h@@YAX$$QAPAUobjc_class@@@Z" +// CHECK-LABEL: "?h@@YAX$$QAPAU.objc_class@@@Z" I *i() { return nullptr; } -// CHECK-LABEL: "?i@@YAPAUI@@XZ" +// CHECK-LABEL: "?i@@YAPAU.objc_cls_I@@XZ" const I *j() { return nullptr; } -// CHECK-LABEL: "?j@@YAPBUI@@XZ" +// CHECK-LABEL: "?j@@YAPBU.objc_cls_I@@XZ" I &k() { return *kI; } -// CHECK-LABEL: "?k@@YAAAUI@@XZ" +// CHECK-LABEL: "?k@@YAAAU.objc_cls_I@@XZ" const I &l() { return *kI; } -// CHECK-LABEL: "?l@@YAABUI@@XZ" +// CHECK-LABEL: "?l@@YAABU.objc_cls_I@@XZ" void m(const id) {} -// CHECK-LABEL: "?m@@YAXQAUobjc_object@@@Z" +// CHECK-LABEL: "?m@@YAXQAU.objc_object@@@Z" void m(const I *) {} -// CHECK-LABEL: "?m@@YAXPBUI@@@Z" +// CHECK-LABEL: "?m@@YAXPBU.objc_cls_I@@@Z" void n(SEL) {} -// CHECK-LABEL: "?n@@YAXPAUobjc_selector@@@Z" +// CHECK-LABEL: "?n@@YAXPAU.objc_selector@@@Z" void n(SEL *) {} -// CHECK-LABEL: "?n@@YAXPAPAUobjc_selector@@@Z" +// CHECK-LABEL: "?n@@YAXPAPAU.objc_selector@@@Z" void n(const SEL *) {} -// CHECK-LABEL: "?n@@YAXPBQAUobjc_selector@@@Z" +// CHECK-LABEL: "?n@@YAXPBQAU.objc_selector@@@Z" void n(SEL &) {} -// CHECK-LABEL: "?n@@YAXAAPAUobjc_selector@@@Z" +// CHECK-LABEL: "?n@@YAXAAPAU.objc_selector@@@Z" void n(const SEL &) {} -// CHECK-LABEL: "?n@@YAXABQAUobjc_selector@@@Z" +// CHECK-LABEL: "?n@@YAXABQAU.objc_selector@@@Z" void n(SEL &&) {} -// CHECK-LABEL: "?n@@YAX$$QAPAUobjc_selector@@@Z" +// CHECK-LABEL: "?n@@YAX$$QAPAU.objc_selector@@@Z" struct __declspec(dllexport) s { struct s &operator=(const struct s &) = delete; void m(I *) {} - // CHECK-LABEL: "?m@s@@QAAXPAUI@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPAU.objc_cls_I@@@Z" void m(const I *) {} - // CHECK-LABEL: "?m@s@@QAAXPBUI@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPBU.objc_cls_I@@@Z" void m(I &) {} - // CHECK-LABEL: "?m@s@@QAAXAAUI@@@Z" + // CHECK-LABEL: "?m@s@@QAAXAAU.objc_cls_I@@@Z" void m(const I &) {} - // CHECK-LABEL: "?m@s@@QAAXABUI@@@Z" + // CHECK-LABEL: "?m@s@@QAAXABU.objc_cls_I@@@Z" void m(I &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QAUI@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QAU.objc_cls_I@@@Z" void m(const I &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QBUI@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QBU.objc_cls_I@@@Z" void m(id) {} - // CHECK-LABEL: "?m@s@@QAAXPAUobjc_object@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPAU.objc_object@@@Z" void m(id &) {} - // CHECK-LABEL: "?m@s@@QAAXAAPAUobjc_object@@@Z" + // CHECK-LABEL: "?m@s@@QAAXAAPAU.objc_object@@@Z" void m(id &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QAPAUobjc_object@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QAPAU.objc_object@@@Z" void m(const id &) {} - // CHECK-LABEL: "?m@s@@QAAXABQAUobjc_object@@@Z" + // CHECK-LABEL: "?m@s@@QAAXABQAU.objc_object@@@Z" void m(const id &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QBQAUobjc_object@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QBQAU.objc_object@@@Z" void m(Class *) {} - // CHECK-LABEL: "?m@s@@QAAXPAPAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPAPAU.objc_class@@@Z" void m(const Class *) {} - // CHECK-LABEL: "?m@s@@QAAXPBQAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPBQAU.objc_class@@@Z" void m(Class) {} - // CHECK-LABEL: "?m@s@@QAAXPAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPAU.objc_class@@@Z" void m(Class &) {} - // CHECK-LABEL: "?m@s@@QAAXAAPAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAXAAPAU.objc_class@@@Z" void m(const Class &) {} - // CHECK-LABEL: "?m@s@@QAAXABQAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAXABQAU.objc_class@@@Z" void m(Class &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QAPAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QAPAU.objc_class@@@Z" void m(const Class &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QBQAUobjc_class@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QBQAU.objc_class@@@Z" void m(SEL) {} - // CHECK-LABEL: "?m@s@@QAAXPAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPAU.objc_selector@@@Z" void m(SEL *) {} - // CHECK-LABEL: "?m@s@@QAAXPAPAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPAPAU.objc_selector@@@Z" void m(const SEL *) {} - // CHECK-LABEL: "?m@s@@QAAXPBQAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAXPBQAU.objc_selector@@@Z" void m(SEL &) {} - // CHECK-LABEL: "?m@s@@QAAXAAPAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAXAAPAU.objc_selector@@@Z" void m(const SEL &) {} - // CHECK-LABEL: "?m@s@@QAAXABQAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAXABQAU.objc_selector@@@Z" void m(SEL &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QAPAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QAPAU.objc_selector@@@Z" void m(const SEL &&) {} - // CHECK-LABEL: "?m@s@@QAAX$$QBQAUobjc_selector@@@Z" + // CHECK-LABEL: "?m@s@@QAAX$$QBQAU.objc_selector@@@Z" }; template <typename T> @@ -179,14 +179,14 @@ struct t { }; template struct t<id>; -// CHECK-LABEL: "??0?$t@PAUobjc_object@@@@QAA@XZ" +// CHECK-LABEL: "??0?$t@PAU.objc_object@@@@QAA@XZ" template struct t<remove_pointer<id>::type>; -// CHECK-LABEL: "??0?$t@Uobjc_object@@@@QAA@XZ" +// CHECK-LABEL: "??0?$t@U.objc_object@@@@QAA@XZ" template struct t<SEL>; -// CHECK-LABEL: "??0?$t@PAUobjc_selector@@@@QAA@XZ" +// CHECK-LABEL: "??0?$t@PAU.objc_selector@@@@QAA@XZ" template struct t<remove_pointer<SEL>::type>; -// CHECK-LABEL: "??0?$t@Uobjc_selector@@@@QAA@XZ" +// CHECK-LABEL: "??0?$t@U.objc_selector@@@@QAA@XZ" |