Skip to content

Keep certain function that are potentially used in the debugger #68843

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
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
4 changes: 4 additions & 0 deletions include/swift/SIL/SILFunction.h
Original file line number Diff line number Diff line change
Expand Up @@ -845,6 +845,10 @@ class SILFunction
/// current SILModule.
bool isPossiblyUsedExternally() const;

/// Helper method which returns whether this function should be preserved so
/// it can potentially be used in the debugger.
bool shouldBePreservedForDebugger() const;

/// In addition to isPossiblyUsedExternally() it returns also true if this
/// is a (private or internal) vtable method which can be referenced by
/// vtables of derived classes outside the compilation unit.
Expand Down
12 changes: 6 additions & 6 deletions lib/IRGen/GenDecl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1252,12 +1252,6 @@ static bool isLazilyEmittedFunction(SILFunction &f, SILModule &m) {
if (f.getDynamicallyReplacedFunction())
return false;

// Needed by lldb to print global variables which are propagated by the
// mandatory GlobalOpt.
if (m.getOptions().OptMode == OptimizationMode::NoOptimization &&
f.isGlobalInit())
return false;

return true;
}

Expand Down Expand Up @@ -3554,9 +3548,15 @@ llvm::Function *IRGenModule::getAddrOfSILFunction(
// Mark as llvm.used if @_used, set section if @_section
if (f->markedAsUsed())
addUsedGlobal(fn);

if (!f->section().empty())
fn->setSection(f->section());

// Also mark as llvm.used any functions that should be kept for the debugger.
// Only definitions should be kept.
if (f->shouldBePreservedForDebugger() && !fn->isDeclaration())
addUsedGlobal(fn);

// If `hasCReferences` is true, then the function is either marked with
// @_silgen_name OR @_cdecl. If it is the latter, it must have a definition
// associated with it. The combination of the two allows us to identify the
Expand Down
36 changes: 36 additions & 0 deletions lib/SIL/IR/SILFunction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -862,6 +862,9 @@ SILFunction::isPossiblyUsedExternally() const {
if (markedAsUsed())
return true;

if (shouldBePreservedForDebugger())
return true;

// Declaration marked as `@_alwaysEmitIntoClient` that
// returns opaque result type with availability conditions
// has to be kept alive to emit opaque type metadata descriptor.
Expand All @@ -872,6 +875,39 @@ SILFunction::isPossiblyUsedExternally() const {
return swift::isPossiblyUsedExternally(linkage, getModule().isWholeModule());
}

bool SILFunction::shouldBePreservedForDebugger() const {
// Only preserve for the debugger at Onone.
if (getEffectiveOptimizationMode() != OptimizationMode::NoOptimization)
return false;

// Only keep functions defined in this module.
if (!isDefinition())
return false;

// Don't preserve anything markes as always emit into client.
if (markedAsAlwaysEmitIntoClient())
return false;

// Needed by lldb to print global variables which are propagated by the
// mandatory GlobalOpt.
if (isGlobalInit())
return true;

// Preserve any user-written functions.
if (auto declContext = getDeclContext())
if (auto decl = declContext->getAsDecl())
if (!decl->isImplicit())
return true;

// Keep any setters/getters, even compiler generated ones.
if (auto *accessorDecl =
llvm::dyn_cast_or_null<swift::AccessorDecl>(getDeclContext()))
if (accessorDecl->isGetterOrSetter())
return true;

return false;
}

bool SILFunction::isExternallyUsedSymbol() const {
return swift::isPossiblyUsedExternally(getEffectiveSymbolLinkage(),
getModule().isWholeModule());
Expand Down
21 changes: 12 additions & 9 deletions test/IRGen/asmname.swift
Original file line number Diff line number Diff line change
Expand Up @@ -11,33 +11,36 @@ _ = atan2test(0.0, 0.0)


// Ordinary Swift definitions
// The unused internal and private functions are expected to be eliminated.
// The unused internal and private functions are expected to be kept as they
// may be used from the debugger in unoptimized builds.

public func PlainPublic() { }
internal func PlainInternal() { }
private func PlainPrivate() { }
// CHECK: define{{( dllexport)?}}{{( protected)?}} swiftcc void @"$s7asmname11PlainPublic
// CHECK-NOT: PlainInternal
// CHECK-NOT: PlainPrivate
// CHECK: define{{( dllexport)?}}{{( protected)?}} hidden swiftcc void @"$s7asmname13PlainInternalyyF
// CHECK: define{{( dllexport)?}}{{( protected)?}} internal swiftcc void @"$s7asmname12PlainPrivate


// Swift _silgen_name definitions
// The private function is expected to be eliminated
// but the internal function must survive for C use.
// The private function is expected
// to be eliminated as it may be used from the
// debugger in unoptimized builds,
// and the internal function must survive for C use.
// Only the C-named definition is emitted.

@_silgen_name("silgen_name_public") public func SilgenNamePublic() { }
@_silgen_name("silgen_name_internal") internal func SilgenNameInternal() { }
@_silgen_name("silgen_name_private") private func SilgenNamePrivate() { }
// CHECK: define{{( dllexport)?}}{{( protected)?}} swiftcc void @silgen_name_public
// CHECK: define hidden swiftcc void @silgen_name_internal
// CHECK-NOT: silgen_name_private
// CHECK: define internal swiftcc void @silgen_name_private
// CHECK-NOT: SilgenName


// Swift cdecl definitions
// The private functions are expected to be eliminated
// but the internal functions must survive for C use.
// The private functions are expected to be kept as it may be used from the debugger,
// and the internal functions must survive for C use.
// Both a C-named definition and a Swift-named definition are emitted.

@_cdecl("cdecl_public") public func CDeclPublic() { }
Expand All @@ -47,4 +50,4 @@ private func PlainPrivate() { }
// CHECK: define{{( dllexport)?}}{{( protected)?}} swiftcc void @"$s7asmname11CDeclPublic
// CHECK: define hidden void @cdecl_internal
// CHECK: define hidden swiftcc void @"$s7asmname13CDeclInternal
// CHECK-NOT: cdecl_private
// CHECK: define internal void @cdecl_private()
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ protocol P {
// CHECK: exiting call_f

// CHECK-LL: @"$s4main1PPAAE1fyyYaFTu" = hidden global %swift.async_func_pointer
// CHECK-LL: @"$s4main6call_fyyxYaAA1PRzlFTu" = hidden global %swift.async_func_pointer
// CHECK-LL: @"$s4main1XCAA1PA2aDP1fyyYaFTWTu" = internal global %swift.async_func_pointer
// CHECK-LL: @"$s4main6call_fyyxYaAA1PRzlFTu" = hidden global %swift.async_func_pointer

extension P {
// CHECK-LL: define hidden swift{{(tail)?}}cc void @"$s4main1PPAAE1fyyYaF"(
Expand Down
5 changes: 3 additions & 2 deletions test/IRGen/objc_implementation.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
// RUN: %FileCheck --input-file %t.ir --check-prefix NEGATIVE %s
// REQUIRES: objc_interop

// CHECK: [[selector_data_implProperty:@[^, ]+]] = private global [13 x i8] c"implProperty\00", section "__TEXT,__objc_methname,cstring_literals", align 1
// CHECK: [[selector_data_setImplProperty_:@[^, ]+]] = private global [17 x i8] c"setImplProperty:\00", section "__TEXT,__objc_methname,cstring_literals", align 1

// CHECK: [[selector_data_mainMethod_:@[^, ]+]] = private global [12 x i8] c"mainMethod:\00", section "__TEXT,__objc_methname,cstring_literals", align 1

//
Expand All @@ -19,8 +22,6 @@
// TODO: Why the extra i32 field above?

// Class
// CHECK: [[selector_data_implProperty:@[^, ]+]] = private global [13 x i8] c"implProperty\00", section "__TEXT,__objc_methname,cstring_literals", align 1
// CHECK: [[selector_data_setImplProperty_:@[^, ]+]] = private global [17 x i8] c"setImplProperty:\00", section "__TEXT,__objc_methname,cstring_literals", align 1
// CHECK: [[selector_data__cxx_destruct:@[^, ]+]] = private global [14 x i8] c".cxx_destruct\00", section "__TEXT,__objc_methname,cstring_literals", align 1
// CHECK: [[_INSTANCE_METHODS_ImplClass:@[^, ]+]] = internal constant { i32, i32, [7 x { ptr, ptr, ptr }] } { i32 24, i32 7, [7 x { ptr, ptr, ptr }] [{ ptr, ptr, ptr } { ptr @"\01L_selector_data(init)", ptr @".str.7.@16@0:8", ptr @"$sSo9ImplClassC19objc_implementationEABycfcTo{{(\.ptrauth)?}}" }, { ptr, ptr, ptr } { ptr [[selector_data_implProperty]], ptr @".str.7.i16@0:8", ptr @"$sSo9ImplClassC19objc_implementationE12implPropertys5Int32VvgTo{{(\.ptrauth)?}}" }, { ptr, ptr, ptr } { ptr [[selector_data_setImplProperty_]], ptr @".str.10.v20@0:8i16", ptr @"$sSo9ImplClassC19objc_implementationE12implPropertys5Int32VvsTo{{(\.ptrauth)?}}" }, { ptr, ptr, ptr } { ptr [[selector_data_mainMethod_]], ptr @".str.10.v20@0:8i16", ptr @"$sSo9ImplClassC19objc_implementationE10mainMethodyys5Int32VFTo{{(\.ptrauth)?}}" }, { ptr, ptr, ptr } { ptr @"\01L_selector_data(copyWithZone:)", ptr @".str.11.@24@0:8^v16", ptr @"$sSo9ImplClassC19objc_implementationE4copy4withypSg10ObjectiveC6NSZoneVSg_tFTo{{(\.ptrauth)?}}" }, { ptr, ptr, ptr } { ptr @"\01L_selector_data(dealloc)", ptr @".str.7.v16@0:8", ptr @"$sSo9ImplClassC19objc_implementationEfDTo{{(\.ptrauth)?}}" }, { ptr, ptr, ptr } { ptr [[selector_data__cxx_destruct]], ptr @".str.7.v16@0:8", ptr @"$sSo9ImplClassCfETo{{(\.ptrauth)?}}" }] }, section "__DATA, __objc_data", align 8
// CHECK: [[_IVARS_ImplClass:@[^, ]+]] = internal constant { i32, i32, [2 x { ptr, ptr, ptr, i32, i32 }] } { i32 32, i32 2, [2 x { ptr, ptr, ptr, i32, i32 }] [{ ptr, ptr, ptr, i32, i32 } { ptr @"$sSo9ImplClassC19objc_implementationE12implPropertys5Int32VvpWvd", ptr @.str.12.implProperty, ptr @.str.0., i32 2, i32 4 }, { ptr, ptr, ptr, i32, i32 } { ptr @"$sSo9ImplClassC19objc_implementationE13implProperty2So8NSObjectCSgvpWvd", ptr @.str.13.implProperty2, ptr @.str.0., i32 3, i32 8 }] }, section "__DATA, __objc_const", align 8
Expand Down
28 changes: 28 additions & 0 deletions test/IRGen/preserve_for_debugger.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
// RUN: %target-swiftc_driver %s -g -Onone -emit-ir | %FileCheck %s

// Check that unused functions are preserved at Onone.
func unused() {
}

// Property wrappers generate transparent getters, which we would like to check still exist at Onone.
@propertyWrapper
struct IntWrapper {
private var storage = 42
var wrappedValue: Int {
return storage
}
}

public class User {
@IntWrapper private var number: Int

func f() {
// Force the generation of the getter
_ = self.number
}
}
let c = User()
c.f()

// CHECK: !DISubprogram(name: "unused", linkageName: "$s21preserve_for_debugger6unusedyyF"
// CHECK: !DISubprogram(name: "number.get"
Original file line number Diff line number Diff line change
Expand Up @@ -117,18 +117,6 @@ func doit() {
}
doit()

// CHECK: define internal swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]LLCMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr [[ARGUMENT1_METADATA:%[0-9]+]], ptr [[ARGUMENT2_METADATA:%[0-9]+]]) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
// CHECK-SAME: [[INT]] [[METADATA_REQUEST]],
// CHECK-SAME: ptr [[ARGUMENT1_METADATA]],
// CHECK-SAME: ptr [[ARGUMENT2_METADATA]],
// CHECK-SAME: ptr undef,
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMn
// CHECK-SAME: )
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }


// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_4]]LLCyAA9Argument1ACLLCySiGAA9Argument2ACLLCySSGGMb"([[INT]] {{%[0-9]+}}) {{#[0-9]}} {{(section)?.*}}{
// CHECK: entry:
// CHECK: call swiftcc %swift.metadata_response @"$s4main9Argument1[[UNIQUE_ID_1]]LLCySiGMb"([[INT]] 0)
Expand All @@ -147,3 +135,13 @@ doit()
// CHECK-apple: ret %swift.metadata_response [[METADATA_RESPONSE]]
// CHECK: }

// CHECK: define internal swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]LLCMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr [[ARGUMENT1_METADATA:%[0-9]+]], ptr [[ARGUMENT2_METADATA:%[0-9]+]]) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
// CHECK-SAME: [[INT]] [[METADATA_REQUEST]],
// CHECK-SAME: ptr [[ARGUMENT1_METADATA]],
// CHECK-SAME: ptr [[ARGUMENT2_METADATA]],
// CHECK-SAME: ptr undef,
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMn
// CHECK-SAME: )
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }
Original file line number Diff line number Diff line change
Expand Up @@ -109,18 +109,6 @@ func doit() {
}
doit()

// CHECK: define internal swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]LLCMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr [[ARGUMENT1_METADATA:%[0-9]+]], ptr [[ARGUMENT2_METADATA:%[0-9]+]]) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: {{%[0-9]+}} = call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
// CHECK-SAME: [[INT]] [[METADATA_REQUEST]],
// CHECK-SAME: ptr [[ARGUMENT1_METADATA]],
// CHECK-SAME: ptr [[ARGUMENT2_METADATA]],
// CHECK-SAME: ptr undef,
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMn
// CHECK: )
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }


// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_4]]LLCyAA9Argument1ACLLCySiGAFySSGGMb"([[INT]] {{%[0-9]+}}) {{#[0-9]}} {{(section)?.*}}{
// CHECK: entry:
// CHECK: call swiftcc %swift.metadata_response @"$s4main9Argument1[[UNIQUE_ID_1]]LLCySiGMb"([[INT]] 0)
Expand All @@ -141,4 +129,13 @@ doit()
// CHECK-apple: ret %swift.metadata_response [[METADATA_RESPONSE]]
// CHECK: }


// CHECK: define internal swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]LLCMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr [[ARGUMENT1_METADATA:%[0-9]+]], ptr [[ARGUMENT2_METADATA:%[0-9]+]]) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: {{%[0-9]+}} = call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
// CHECK-SAME: [[INT]] [[METADATA_REQUEST]],
// CHECK-SAME: ptr [[ARGUMENT1_METADATA]],
// CHECK-SAME: ptr [[ARGUMENT2_METADATA]],
// CHECK-SAME: ptr undef,
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMn
// CHECK: )
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }
Original file line number Diff line number Diff line change
Expand Up @@ -108,20 +108,6 @@ func doit() {
}
doit()

// CHECK: define internal swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]LLCMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr [[ARGUMENT1_METADATA:%[0-9]+]], ptr [[ARGUMENT2_METADATA:%[0-9]+]]) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: entry:
// CHECK: {{%[0-9]+}} = call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
// CHECK-SAME: [[INT]] [[METADATA_REQUEST]],
// CHECK-SAME: ptr [[ARGUMENT1_METADATA]],
// CHECK-SAME: ptr [[ARGUMENT2_METADATA]],
// CHECK-SAME: ptr undef,
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMn
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMz
// CHECK: )
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }


// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_4]]LLCyAA9Argument1ACLLCySiGAGGMb"([[INT]] {{%[0-9]+}}) {{#[0-9]}} {{(section)?.*}}{
// CHECK: entry:
// CHECK: call swiftcc %swift.metadata_response @"$s4main9Argument1[[UNIQUE_ID_1]]LLCySiGMb"([[INT]] 0)
Expand All @@ -141,3 +127,16 @@ doit()
// CHECK-apple: [[METADATA_RESPONSE:%[0-9]+]] = insertvalue %swift.metadata_response [[PARTIAL_METADATA_RESPONSE]], [[INT]] 0, 1
// CHECK-apple: ret %swift.metadata_response [[METADATA_RESPONSE]]
// CHECK: }

// CHECK: define internal swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]LLCMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr [[ARGUMENT1_METADATA:%[0-9]+]], ptr [[ARGUMENT2_METADATA:%[0-9]+]]) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: entry:
// CHECK: {{%[0-9]+}} = call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
// CHECK-SAME: [[INT]] [[METADATA_REQUEST]],
// CHECK-SAME: ptr [[ARGUMENT1_METADATA]],
// CHECK-SAME: ptr [[ARGUMENT2_METADATA]],
// CHECK-SAME: ptr undef,
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMn
// CHECK-SAME: $s4main5Value[[UNIQUE_ID_1]]LLCMz
// CHECK: )
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,18 @@ func doit() {
}
doit()

// CHECK: ; Function Attrs: noinline nounwind memory(none)
// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]CySSGMb"([[INT]] {{%[0-9]+}}) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: call swiftcc %swift.metadata_response @"$s4main9Ancestor1[[UNIQUE_ID_1]]CySiGMb"([[INT]] 0)
// CHECK-NOT: call swiftcc %swift.metadata_response @"$s4main9Ancestor2[[UNIQUE_ID_1]]CySiGMb"([[INT]] 0)
// CHECK-unknown: ret
// CHECK-apple: [[INITIALIZED_CLASS:%[0-9]+]] = call ptr @objc_opt_self(
// CHECK-SAME: @"$s4main5Value[[UNIQUE_ID_1]]CySSGMf"
// CHECK-apple: [[PARTIAL_METADATA_RESPONSE:%[0-9]+]] = insertvalue %swift.metadata_response undef, ptr [[INITIALIZED_CLASS]], 0
// CHECK-apple: [[METADATA_RESPONSE:%[0-9]+]] = insertvalue %swift.metadata_response [[PARTIAL_METADATA_RESPONSE]], [[INT]] 0, 1
// CHECK-apple: ret %swift.metadata_response [[METADATA_RESPONSE]]
// CHECK: }

// CHECK: define internal swiftcc %swift.metadata_response @"$s4main9Ancestor2[[UNIQUE_ID_1]]CMa"([[INT]] [[METADATA_REQUEST:%[0-9]+]], ptr %1) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: entry:
// CHECK: {{%[0-9]+}} = call swiftcc %swift.metadata_response @__swift_instantiateCanonicalPrespecializedGenericMetadata(
Expand Down Expand Up @@ -162,18 +174,6 @@ doit()
// CHECK: ret %swift.metadata_response {{%[0-9]+}}
// CHECK: }

// CHECK: ; Function Attrs: noinline nounwind memory(none)
// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main5Value[[UNIQUE_ID_1]]CySSGMb"([[INT]] {{%[0-9]+}}) #{{[0-9]+}} {{(section)?.*}}{
// CHECK: call swiftcc %swift.metadata_response @"$s4main9Ancestor1[[UNIQUE_ID_1]]CySiGMb"([[INT]] 0)
// CHECK-NOT: call swiftcc %swift.metadata_response @"$s4main9Ancestor2[[UNIQUE_ID_1]]CySiGMb"([[INT]] 0)
// CHECK-unknown: ret
// CHECK-apple: [[INITIALIZED_CLASS:%[0-9]+]] = call ptr @objc_opt_self(
// CHECK-SAME: @"$s4main5Value[[UNIQUE_ID_1]]CySSGMf"
// CHECK-apple: [[PARTIAL_METADATA_RESPONSE:%[0-9]+]] = insertvalue %swift.metadata_response undef, ptr [[INITIALIZED_CLASS]], 0
// CHECK-apple: [[METADATA_RESPONSE:%[0-9]+]] = insertvalue %swift.metadata_response [[PARTIAL_METADATA_RESPONSE]], [[INT]] 0, 1
// CHECK-apple: ret %swift.metadata_response [[METADATA_RESPONSE]]
// CHECK: }

// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main9Ancestor1[[UNIQUE_ID_1]]CySiGMb"([[INT]] {{%[0-9]+}})

// CHECK: define linkonce_odr hidden swiftcc %swift.metadata_response @"$s4main9Ancestor2[[UNIQUE_ID_1]]CySdGMb"([[INT]] {{%[0-9]+}})
Expand Down
Loading