Skip to content

Revert "Merge pull request #40342 from aschwaighofer/make_objc_metadata_weak_hidden" #40484

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions lib/IRGen/GenClass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1343,8 +1343,7 @@ namespace {
// };

assert(fields.getNextOffsetFromGlobal() == size);
return buildGlobalVariable(fields, "_CATEGORY_", /*const*/ true,
llvm::GlobalVariable::InternalLinkage);
return buildGlobalVariable(fields, "_CATEGORY_", /*const*/ true);
}

llvm::Constant *emitProtocol() {
Expand Down Expand Up @@ -1504,8 +1503,7 @@ namespace {
// statically. Otherwise, the ObjC runtime may slide the InstanceSize
// based on changing base class layout.
return buildGlobalVariable(fields, dataSuffix,
/*const*/ forMeta || FieldLayout->isFixedSize(),
llvm::GlobalVariable::InternalLinkage);
/*const*/ forMeta || FieldLayout->isFixedSize());
}

private:
Expand Down Expand Up @@ -1770,8 +1768,12 @@ namespace {
return null();
}

return buildGlobalVariable(array, "_PROTOCOL_METHOD_TYPES_",
/*const*/ true);
auto *gv_as_const = buildGlobalVariable(array, "_PROTOCOL_METHOD_TYPES_",
/*const*/ true,
/*likage*/ llvm::GlobalVariable::WeakAnyLinkage);
llvm::GlobalValue *gv = (llvm::GlobalValue *)gv_as_const;
gv->setVisibility(llvm::GlobalValue::HiddenVisibility);
return gv;
}

void buildExtMethodTypes(ConstantArrayBuilder &array,
Expand Down Expand Up @@ -2173,7 +2175,7 @@ namespace {
template <class B>
llvm::Constant *buildGlobalVariable(B &fields, StringRef nameBase, bool isConst,
llvm::GlobalValue::LinkageTypes linkage =
llvm::GlobalVariable::WeakAnyLinkage) {
llvm::GlobalVariable::InternalLinkage) {
llvm::SmallString<64> nameBuffer;
auto var =
fields.finishAndCreateGlobal(Twine(nameBase)
Expand All @@ -2184,9 +2186,6 @@ namespace {
IGM.getPointerAlignment(),
/*constant*/ true,
linkage);
if (linkage == llvm::GlobalVariable::WeakAnyLinkage) {
var->setVisibility(llvm::GlobalValue::HiddenVisibility);
}

switch (IGM.TargetInfo.OutputObjectFormat) {
case llvm::Triple::MachO:
Expand Down
2 changes: 1 addition & 1 deletion test/Concurrency/objc_async_protocol_irgen.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ let anyObject: AnyObject = (MyAsyncProtocol.self as AnyObject) // or something l
// Make sure we don't emit 2 copies of methods, due to a completion-handler
// version and another due to an async based version.

// CHECK-LABEL: @_PROTOCOL_INSTANCE_METHODS_MyAsyncProtocol = weak hidden constant
// CHECK-LABEL: @_PROTOCOL_INSTANCE_METHODS_MyAsyncProtocol = internal constant
// CHECK-SAME: selector_data(myAsyncMethod:)
// CHECK-NOT: selector_data(myAsyncMethod:)
// CHECK-SAME: align [[ALIGNMENT]]
8 changes: 4 additions & 4 deletions test/IRGen/generic_casts.swift
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,22 @@ import Foundation
import gizmo

// -- Protocol records for cast-to ObjC protocols
// CHECK: @_PROTOCOL__TtP13generic_casts10ObjCProto1_ = weak hidden constant
// CHECK: @_PROTOCOL__TtP13generic_casts10ObjCProto1_ = internal constant
// CHECK: @"\01l_OBJC_LABEL_PROTOCOL_$__TtP13generic_casts10ObjCProto1_" = weak hidden global i8* bitcast ({{.*}} @_PROTOCOL__TtP13generic_casts10ObjCProto1_ to i8*), section {{"__DATA,__objc_protolist,coalesced,no_dead_strip"|"objc_protolist"|".objc_protolist\$B"}}
// CHECK: @"\01l_OBJC_PROTOCOL_REFERENCE_$__TtP13generic_casts10ObjCProto1_" = weak hidden global i8* bitcast ({{.*}} @_PROTOCOL__TtP13generic_casts10ObjCProto1_ to i8*), section {{"__DATA,__objc_protorefs,coalesced,no_dead_strip"|"objc_protorefs"|".objc_protorefs\$B"}}

// CHECK: @_PROTOCOL_NSRuncing = weak hidden constant
// CHECK: @_PROTOCOL_NSRuncing = internal constant
// CHECK: @"\01l_OBJC_LABEL_PROTOCOL_$_NSRuncing" = weak hidden global i8* bitcast ({{.*}} @_PROTOCOL_NSRuncing to i8*), section {{"__DATA,__objc_protolist,coalesced,no_dead_strip"|"objc_protolist"|".objc_protolist\$B"}}
// CHECK: @"\01l_OBJC_PROTOCOL_REFERENCE_$_NSRuncing" = weak hidden global i8* bitcast ({{.*}} @_PROTOCOL_NSRuncing to i8*), section {{"__DATA,__objc_protorefs,coalesced,no_dead_strip"|"objc_protorefs"|".objc_protorefs\$B"}}

// CHECK: @_PROTOCOLS__TtC13generic_casts10ObjCClass2 = weak hidden constant { i64, [1 x i8*] } {
// CHECK: @_PROTOCOLS__TtC13generic_casts10ObjCClass2 = internal constant { i64, [1 x i8*] } {
// CHECK: i64 1,
// CHECK: @_PROTOCOL__TtP13generic_casts10ObjCProto2_
// CHECK: }

// CHECK: @_DATA__TtC13generic_casts10ObjCClass2 = internal constant {{.*}} @_PROTOCOLS__TtC13generic_casts10ObjCClass2

// CHECK: @_PROTOCOL_PROTOCOLS__TtP13generic_casts10ObjCProto2_ = weak hidden constant { i64, [1 x i8*] } {
// CHECK: @_PROTOCOL_PROTOCOLS__TtP13generic_casts10ObjCProto2_ = internal constant { i64, [1 x i8*] } {
// CHECK: i64 1,
// CHECK: @_PROTOCOL__TtP13generic_casts10ObjCProto1_
// CHECK: }
Expand Down
4 changes: 2 additions & 2 deletions test/IRGen/objc_async_metadata.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import Foundation
// CHECK: [[ENCODE_ASYNC_STRING:@.*]] = private unnamed_addr constant [28 x i8] c"v24@0:8@?<v@?@\22NSString\22>16\00"
// CHECK: [[ENCODE_ASYNC_THROWS_STRING:@.*]] = private unnamed_addr constant [38 x i8] c"v24@0:8@?<v@?@\22NSString\22@\22NSError\22>16\00"

// CHECK: @_INSTANCE_METHODS__TtC19objc_async_metadata7MyClass = weak hidden constant
// CHECK: @_INSTANCE_METHODS__TtC19objc_async_metadata7MyClass = internal constant
// CHECK-SAME: methodWithCompletionHandler:
// CHECK-SAME: [[ENCODE_ASYNC_STRING]]
// CHECK-SAME: throwingMethodWithCompletionHandler:
Expand All @@ -23,7 +23,7 @@ class MyClass: NSObject {
}

// CHECK: [[ENCODE_ASYNC_STRING_PROTO:@.*]] = private unnamed_addr constant [15 x i8] c"v32@0:8@16@?24\00"
// CHECK-LABEL: @_PROTOCOL_INSTANCE_METHODS__TtP19objc_async_metadata7MyProto_ = weak hidden constant
// CHECK-LABEL: @_PROTOCOL_INSTANCE_METHODS__TtP19objc_async_metadata7MyProto_ = internal constant
// CHECK-SAME: _selector_data(myProtoRequirement:completionHandler:)
// CHECK-SAME: [15 x i8]* [[ENCODE_ASYNC_STRING_PROTO]]

Expand Down
4 changes: 2 additions & 2 deletions test/IRGen/objc_attr_NSManaged.sil
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ import Foundation
sil_vtable X {}

// The getter/setter should not show up in the Objective-C metadata.
// CHECK: @_INSTANCE_METHODS__TtC19objc_attr_NSManaged10SwiftGizmo = weak hidden constant { i32, i32, [2 x { i8*, i8*, i8* }] } { i32 24, i32 2, {{.*}} @"\01L_selector_data(initWithBellsOn:)", {{.*}} @"\01L_selector_data(init)",
// CHECK: @_INSTANCE_METHODS__TtC19objc_attr_NSManaged10SwiftGizmo = internal constant { i32, i32, [2 x { i8*, i8*, i8* }] } { i32 24, i32 2, {{.*}} @"\01L_selector_data(initWithBellsOn:)", {{.*}} @"\01L_selector_data(init)",

// CHECK: [[X:@[0-9]+]] = private unnamed_addr constant [2 x i8] c"x\00"

// The property 'x' should show up in the Objective-C metadata.
// CHECK: @_PROPERTIES__TtC19objc_attr_NSManaged10SwiftGizmo = weak hidden constant { {{.*}}i32, i32, [1 x { i8*, i8* }] } { i32 16, i32 1, [1 x { i8*, i8* }] [{ i8*, i8* } { i8* getelementptr inbounds ([2 x i8], [2 x i8]* [[X]], i64 0, i64 0),
// CHECK: @_PROPERTIES__TtC19objc_attr_NSManaged10SwiftGizmo = internal constant { {{.*}}i32, i32, [1 x { i8*, i8* }] } { i32 16, i32 1, [1 x { i8*, i8* }] [{ i8*, i8* } { i8* getelementptr inbounds ([2 x i8], [2 x i8]* [[X]], i64 0, i64 0),

// The getter/setter should not show up in the Swift metadata.
// CHECK: @"$s19objc_attr_NSManaged10SwiftGizmoCMf" = internal global <{ {{.*}} }> <{ void (%T19objc_attr_NSManaged10SwiftGizmoC*)* {{.*}}@"$s19objc_attr_NSManaged10SwiftGizmoCfD{{(\.ptrauth)?}}"{{.*}}, i8**{{.*}} @"$sBOWV{{(.ptrauth)?(.)?[0-9]?}}"{{.*}}, {{.*}} @"OBJC_METACLASS_$__TtC19objc_attr_NSManaged10SwiftGizmo{{(.ptrauth)?}}"{{.*}}, %objc_class*{{.*}} @"OBJC_CLASS_$_Gizmo{{(.ptrauth)?}}"{{.*}}, %swift.opaque* @_objc_empty_cache, %swift.opaque* null,{{.*}}@_DATA__TtC19objc_attr_NSManaged10SwiftGizmo{{.*}}i64 {{1|2}}){{.*}}, i32 {{1|0}}, i32 0, i32 8, i16 7, i16 0, i32 96, i32 16, {{.*}}* @"$s19objc_attr_NSManaged10SwiftGizmoCMn{{(\.ptrauth)?}}"{{.*}}, i8* null }>
Expand Down
6 changes: 3 additions & 3 deletions test/IRGen/objc_bridge.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import Foundation
// CHECK: [[SETTER_SIGNATURE:@.*]] = private unnamed_addr constant [11 x i8] c"v24@0:8@16\00"
// CHECK: [[DEALLOC_SIGNATURE:@.*]] = private unnamed_addr constant [8 x i8] c"v16@0:8\00"

// CHECK: @_INSTANCE_METHODS__TtC11objc_bridge3Bas = weak hidden constant { i32, i32, [17 x { i8*, i8*, i8* }] } {
// CHECK: @_INSTANCE_METHODS__TtC11objc_bridge3Bas = internal constant { i32, i32, [17 x { i8*, i8*, i8* }] } {
// CHECK: i32 24,
// CHECK: i32 17,
// CHECK: [17 x { i8*, i8*, i8* }] [
Expand Down Expand Up @@ -114,10 +114,10 @@ import Foundation
// CHECK: ]
// CHECK: }, section "__DATA, {{.*}}", align 8

// CHECK: @_PROPERTIES__TtC11objc_bridge3Bas = weak hidden constant { i32, i32, [5 x { i8*, i8* }] } {
// CHECK: @_PROPERTIES__TtC11objc_bridge3Bas = internal constant { i32, i32, [5 x { i8*, i8* }] } {

// CHECK: [[OBJC_BLOCK_PROPERTY:@.*]] = private unnamed_addr constant [8 x i8] c"T@?,N,C\00"
// CHECK: @_PROPERTIES__TtC11objc_bridge21OptionalBlockProperty = weak hidden constant {{.*}} [[OBJC_BLOCK_PROPERTY]]
// CHECK: @_PROPERTIES__TtC11objc_bridge21OptionalBlockProperty = internal constant {{.*}} [[OBJC_BLOCK_PROPERTY]]

func getDescription(_ o: NSObject) -> String {
return o.description
Expand Down
4 changes: 2 additions & 2 deletions test/IRGen/objc_class_property.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
// class properties, so no ObjC property is reflected.

// CHECK-NOT: @_PROPERTIES__TtC19objc_class_property7Smashed
// CHECK: @_CLASS_METHODS__TtC19objc_class_property7Smashed = weak hidden constant { i32, i32, [1 x { i8*, i8*, i8* }] } {
// CHECK: @_CLASS_METHODS__TtC19objc_class_property7Smashed = internal constant { i32, i32, [1 x { i8*, i8*, i8* }] } {
// CHECK: i8* getelementptr inbounds ([14 x i8], [14 x i8]* @"\01L_selector_data(sharedSmashed)"
// CHECK-NOT: @_PROPERTIES__TtC19objc_class_property7Smashed
// CHECK: @_INSTANCE_METHODS__TtC19objc_class_property7Smashed = weak hidden constant { i32, i32, [1 x { i8*, i8*, i8* }] } {
// CHECK: @_INSTANCE_METHODS__TtC19objc_class_property7Smashed = internal constant { i32, i32, [1 x { i8*, i8*, i8* }] } {
// CHECK: i8* getelementptr inbounds ([5 x i8], [5 x i8]* @"\01L_selector_data(init)"
// CHECK-NOT: @_PROPERTIES__TtC19objc_class_property7Smashed

Expand Down
10 changes: 5 additions & 5 deletions test/IRGen/objc_extensions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import objc_extension_base
// CHECK: [[CATEGORY_NAME:@.*]] = private constant [16 x i8] c"objc_extensions\00"
// CHECK: [[METHOD_TYPE:@.*]] = private unnamed_addr constant [8 x i8] c"v16@0:8\00"

// CHECK-LABEL: @"_CATEGORY_PROTOCOLS_Gizmo_$_objc_extensions" = weak hidden constant
// CHECK-LABEL: @"_CATEGORY_PROTOCOLS_Gizmo_$_objc_extensions" = internal constant
// CHECK-SAME: i64 1,
// CHECK-SAME: @_PROTOCOL__TtP15objc_extensions11NewProtocol_

Expand Down Expand Up @@ -84,7 +84,7 @@ extension Gizmo {
class Hoozit : NSObject {
}

// CHECK-LABEL: @"_CATEGORY_INSTANCE_METHODS__TtC15objc_extensions6Hoozit_$_objc_extensions" = weak hidden constant
// CHECK-LABEL: @"_CATEGORY_INSTANCE_METHODS__TtC15objc_extensions6Hoozit_$_objc_extensions" = internal constant
// CHECK: i32 24,
// CHECK: i32 1,
// CHECK: [1 x { i8*, i8*, i8* }] [{ i8*, i8*, i8* } {
Expand All @@ -94,7 +94,7 @@ class Hoozit : NSObject {
// CHECK: }]
// CHECK: }, section "__DATA, {{.*}}", align 8

// CHECK-LABEL: @"_CATEGORY_CLASS_METHODS__TtC15objc_extensions6Hoozit_$_objc_extensions" = weak hidden constant
// CHECK-LABEL: @"_CATEGORY_CLASS_METHODS__TtC15objc_extensions6Hoozit_$_objc_extensions" = internal constant
// CHECK: i32 24,
// CHECK: i32 1,
// CHECK: [1 x { i8*, i8*, i8* }] [{ i8*, i8*, i8* } {
Expand All @@ -120,7 +120,7 @@ extension Hoozit {

class SwiftOnly { }

// CHECK-LABEL: @"_CATEGORY_INSTANCE_METHODS__TtC15objc_extensions9SwiftOnly_$_objc_extensions" = weak hidden constant
// CHECK-LABEL: @"_CATEGORY_INSTANCE_METHODS__TtC15objc_extensions9SwiftOnly_$_objc_extensions" = internal constant
// CHECK: i32 24,
// CHECK: i32 1,
// CHECK: [1 x { i8*, i8*, i8* }] [{ i8*, i8*, i8* } {
Expand Down Expand Up @@ -175,7 +175,7 @@ class NSDogcow : NSObject {}

// CHECK: [[NAME:@.*]] = private unnamed_addr constant [5 x i8] c"woof\00"
// CHECK: [[ATTR:@.*]] = private unnamed_addr constant [7 x i8] c"Tq,N,D\00"
// CHECK: @"_CATEGORY_PROPERTIES__TtC15objc_extensions8NSDogcow_$_objc_extensions" = weak hidden constant {{.*}} [[NAME]], {{.*}} [[ATTR]], {{.*}}, section "__DATA, {{.*}}", align 8
// CHECK: @"_CATEGORY_PROPERTIES__TtC15objc_extensions8NSDogcow_$_objc_extensions" = internal constant {{.*}} [[NAME]], {{.*}} [[ATTR]], {{.*}}, section "__DATA, {{.*}}", align 8
extension NSDogcow {
@NSManaged var woof: Int
}
Expand Down
2 changes: 1 addition & 1 deletion test/IRGen/objc_int_encoding.sil
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
// CHECK-64: [[INT_UINT_METHOD_ENCODING:@.*]] = private unnamed_addr constant {{.*}} c"Q24@0:8q16\00"
// CHECK-32: [[INT_UINT_METHOD_ENCODING:@.*]] = private unnamed_addr constant {{.*}} c"I12@0:4i8\00"

// CHECK: @_INSTANCE_METHODS__TtC17objc_int_encoding3Foo = weak hidden constant {{.*}} [[SELECTOR]], {{.*}} [[INT_UINT_METHOD_ENCODING]], {{.*}} @"$s17objc_int_encoding3FooC3foo1xSuSi_tFTo{{(\.ptrauth)?}}"
// CHECK: @_INSTANCE_METHODS__TtC17objc_int_encoding3Foo = internal constant {{.*}} [[SELECTOR]], {{.*}} [[INT_UINT_METHOD_ENCODING]], {{.*}} @"$s17objc_int_encoding3FooC3foo1xSuSi_tFTo{{(\.ptrauth)?}}"

sil_stage canonical

Expand Down
4 changes: 2 additions & 2 deletions test/IRGen/objc_methods.swift
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class ObjcDestructible: NSObject {
// CHECK-ios: [[FAIL_SIGNATURE:@.*]] = private unnamed_addr constant [12 x i8] c"B24@0:8^@16\00"
// CHECK-tvos: [[FAIL_SIGNATURE:@.*]] = private unnamed_addr constant [12 x i8] c"B24@0:8^@16\00"
// CHECK-watchos: [[FAIL_SIGNATURE:@.*]] = private unnamed_addr constant [12 x i8] c"B24@0:8^@16\00"
// CHECK: @_INSTANCE_METHODS__TtC12objc_methods3Foo = weak hidden constant { {{.*}}] } {
// CHECK: @_INSTANCE_METHODS__TtC12objc_methods3Foo = internal constant { {{.*}}] } {
// CHECK: i32 24,
// CHECK: i32 10,
// CHECK: [10 x { i8*, i8*, i8* }] [{
Expand Down Expand Up @@ -84,7 +84,7 @@ class ObjcDestructible: NSObject {
// CHECK-ios: i8* bitcast (i1 (i8*, i8*, %4**)* @"$s12objc_methods3FooC4failyyKFTo" to i8*)
// CHECK: }]
// CHECK: }, section "__DATA, {{.*}}", align 8
// CHECK: @_INSTANCE_METHODS__TtC12objc_methods16ObjcDestructible = weak hidden constant { {{.*}}] } {
// CHECK: @_INSTANCE_METHODS__TtC12objc_methods16ObjcDestructible = internal constant { {{.*}}] } {
// CHECK: i32 24,
// CHECK: i32 2,
// CHECK: [2 x { i8*, i8*, i8* }] [{
Expand Down
18 changes: 9 additions & 9 deletions test/IRGen/objc_properties.swift
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ class SomeWrapperTests {
// CHECK-NEW: [[SHARED_NAME:@.*]] = private unnamed_addr constant [11 x i8] c"sharedProp\00"
// CHECK-NEW: [[SHARED_ATTRS:@.*]] = private unnamed_addr constant [5 x i8] c"Tq,N\00"

// CHECK-NEW: @_CLASS_PROPERTIES__TtC15objc_properties10SomeObject = weak hidden constant { {{.*}}] } {
// CHECK-NEW: @_CLASS_PROPERTIES__TtC15objc_properties10SomeObject = internal constant { {{.*}}] } {
// CHECK-NEW: i32 16,
// CHECK-NEW: i32 1,
// CHECK-NEW: [1 x { i8*, i8* }] [{
Expand All @@ -127,7 +127,7 @@ class SomeWrapperTests {
// CHECK: [[GETTER_SIGNATURE:@.*]] = private unnamed_addr constant [8 x i8] c"@16@0:8\00"
// CHECK: [[SETTER_SIGNATURE:@.*]] = private unnamed_addr constant [11 x i8] c"v24@0:8@16\00"

// CHECK: @_INSTANCE_METHODS__TtC15objc_properties10SomeObject = weak hidden constant { {{.*}}] } {
// CHECK: @_INSTANCE_METHODS__TtC15objc_properties10SomeObject = internal constant { {{.*}}] } {
// CHECK: i32 24,
// CHECK: i32 8,
// CHECK: [8 x { i8*, i8*, i8* }] [{
Expand Down Expand Up @@ -179,7 +179,7 @@ class SomeWrapperTests {
// CHECK: [[WIBBLE_NAME:@.*]] = private unnamed_addr constant [7 x i8] c"wobble\00"
// CHECK: [[WIBBLE_ATTRS:@.*]] = private unnamed_addr constant [50 x i8] c"T@\22_TtC15objc_properties10SomeObject\22,N,&,Vwibble\00"

// CHECK: @_PROPERTIES__TtC15objc_properties10SomeObject = weak hidden constant { {{.*}}] } {
// CHECK: @_PROPERTIES__TtC15objc_properties10SomeObject = internal constant { {{.*}}] } {
// CHECK: i32 16,
// CHECK: i32 4,
// CHECK: [4 x { i8*, i8* }] [{
Expand Down Expand Up @@ -208,7 +208,7 @@ class SomeWrapperTests {
// CHECK: { {{.+}} }* @_PROPERTIES__TtC15objc_properties10SomeObject
// CHECK: }, section "__DATA, {{.*}}", align 8

// CHECK: @"_CATEGORY_INSTANCE_METHODS__TtC15objc_properties10SomeObject_$_objc_properties" = weak hidden constant { {{.*}}] } {
// CHECK: @"_CATEGORY_INSTANCE_METHODS__TtC15objc_properties10SomeObject_$_objc_properties" = internal constant { {{.*}}] } {
// CHECK: i32 24,
// CHECK: i32 2,
// CHECK: [2 x { i8*, i8*, i8* }] [{
Expand All @@ -224,7 +224,7 @@ class SomeWrapperTests {

// CHECK: [[EXTENSIONPROPERTY_NAME:@.*]] = private unnamed_addr constant [18 x i8] c"extensionProperty\00"

// CHECK: @"_CATEGORY_PROPERTIES__TtC15objc_properties10SomeObject_$_objc_properties" = weak hidden constant { {{.*}}] } {
// CHECK: @"_CATEGORY_PROPERTIES__TtC15objc_properties10SomeObject_$_objc_properties" = internal constant { {{.*}}] } {
// CHECK: i32 16,
// CHECK: i32 1,
// CHECK: [1 x { i8*, i8* }] [{
Expand All @@ -237,7 +237,7 @@ class SomeWrapperTests {
// CHECK-NEW: [[EXTENSIONCLASSPROPERTY_ATTRS:@.*]] = private unnamed_addr constant [7 x i8] c"T#,N,R\00"
// CHECK-NEW: [[EXTENSIONSTATICPROPERTY_NAME:@.*]] = private unnamed_addr constant [26 x i8] c"extensionStoredStaticProp\00"

// CHECK-NEW: @"_CATEGORY_CLASS_PROPERTIES__TtC15objc_properties10SomeObject_$_objc_properties" = weak hidden constant { {{.*}}] } {
// CHECK-NEW: @"_CATEGORY_CLASS_PROPERTIES__TtC15objc_properties10SomeObject_$_objc_properties" = internal constant { {{.*}}] } {
// CHECK-NEW: i32 16,
// CHECK-NEW: i32 2,
// CHECK-NEW: [2 x { i8*, i8* }] [{
Expand Down Expand Up @@ -269,7 +269,7 @@ class SomeWrapperTests {
// CHECK: i8* getelementptr inbounds ([11 x i8], [11 x i8]* [[SETTER_SIGNATURE]], i64 0, i64 0),
// CHECK: @"$s15objc_properties4TreeC6parentACSgvsTo{{(.ptrauth)?}}"

// CHECK: @_PROTOCOL__TtP15objc_properties5Proto_ = weak hidden constant { {{.+}} } {
// CHECK: @_PROTOCOL__TtP15objc_properties5Proto_ = internal constant { {{.+}} } {
// CHECK: i8* null,
// CHECK: i8* getelementptr inbounds ([{{.+}} x i8], [{{.+}} x i8]* {{@.+}}, i64 0, i64 0),
// CHECK: i8* null,
Expand All @@ -289,7 +289,7 @@ class SomeWrapperTests {
// CHECK: [[PROTOCOLPROPERTY_NAME:@.+]] = private unnamed_addr constant [6 x i8] c"value\00"
// CHECK: [[PROTOCOLPROPERTY_ATTRS:@.+]] = private unnamed_addr constant [7 x i8] c"Tq,N,R\00"

// CHECK: @_PROTOCOL_PROPERTIES__TtP15objc_properties5Proto_ = weak hidden constant { {{.*}}] } {
// CHECK: @_PROTOCOL_PROPERTIES__TtP15objc_properties5Proto_ = internal constant { {{.*}}] } {
// CHECK: i32 16,
// CHECK: i32 1,
// CHECK: [1 x { i8*, i8* }] [{
Expand All @@ -301,7 +301,7 @@ class SomeWrapperTests {
// CHECK-NEW: [[PROTOCOLCLASSPROPERTY_NAME:@.+]] = private unnamed_addr constant [15 x i8] c"sharedInstance\00"
// CHECK-NEW: [[PROTOCOLCLASSPROPERTY_ATTRS:@.+]] = private unnamed_addr constant [7 x i8] c"T@,N,&\00"

// CHECK-NEW: @_PROTOCOL_CLASS_PROPERTIES__TtP15objc_properties5Proto_ = weak hidden constant { {{.*}}] } {
// CHECK-NEW: @_PROTOCOL_CLASS_PROPERTIES__TtP15objc_properties5Proto_ = internal constant { {{.*}}] } {
// CHECK-NEW: i32 16,
// CHECK-NEW: i32 1,
// CHECK-NEW: [1 x { i8*, i8* }] [{
Expand Down
Loading