import Foundation

main()

func main() {
    guard let s = readLine() else {
        return
    }
    let ans = s.components(separatedBy: "S").map { $0.count }.max()
    print(ans!)
}

; ModuleID = '/data/TheStack_IR/OJ_Samples/Collated/Swift/Source_3004/llvm_O3.ll'
source_filename = "/data/TheStack_IR/OJ_Samples/Collated/Swift/Source_3004/llvm_O3.ll"
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct._SwiftEmptyArrayStorage = type { %struct.HeapObject, %struct._SwiftArrayBodyStorage }
%struct.HeapObject = type { %struct.HeapMetadata*, %struct.InlineRefCountsPlaceholder }
%struct.HeapMetadata = type opaque
%struct.InlineRefCountsPlaceholder = type { i64 }
%struct._SwiftArrayBodyStorage = type { i64, i64 }
%swift.type = type { i64 }
%swift.protocol_conformance_descriptor = type { i32, i32, i32, i32 }
%swift.type_descriptor = type opaque
%TSS = type <{ %Ts11_StringGutsV }>
%Ts11_StringGutsV = type <{ %Ts13_StringObjectV }>
%Ts13_StringObjectV = type <{ %Ts6UInt64V, %swift.bridge* }>
%Ts6UInt64V = type <{ i64 }>
%swift.bridge = type opaque
%Ts15ContiguousArrayV = type <{ %Ts22_ContiguousArrayBufferV }>
%Ts22_ContiguousArrayBufferV = type <{ %Ts28__ContiguousArrayStorageBaseC* }>
%Ts28__ContiguousArrayStorageBaseC = type <{ %swift.refcounted, %Ts10_ArrayBodyV }>
%swift.refcounted = type { %swift.type*, i64 }
%Ts10_ArrayBodyV = type <{ %TSo22_SwiftArrayBodyStorageV }>
%TSo22_SwiftArrayBodyStorageV = type <{ %TSi, %TSu }>
%TSi = type <{ i64 }>
%TSu = type <{ i64 }>
%swift.opaque = type opaque

@_swiftEmptyArrayStorage = external global %struct._SwiftEmptyArrayStorage, align 8
@"$sSSN" = external global %swift.type, align 8
@"$sS2SSysWL" = linkonce_odr hidden local_unnamed_addr global i8** null, align 8
@"$sSSSysMc" = external global %swift.protocol_conformance_descriptor, align 4
@"$ss23_ContiguousArrayStorageCMn" = external global %swift.type_descriptor, align 4
@"got.$ss23_ContiguousArrayStorageCMn" = private unnamed_addr constant %swift.type_descriptor* @"$ss23_ContiguousArrayStorageCMn"
@"symbolic _____yypG s23_ContiguousArrayStorageC" = linkonce_odr hidden constant <{ i8, i32, [4 x i8], i8 }> <{ i8 2, i32 trunc (i64 sub (i64 ptrtoint (%swift.type_descriptor** @"got.$ss23_ContiguousArrayStorageCMn" to i64), i64 ptrtoint (i32* getelementptr inbounds (<{ i8, i32, [4 x i8], i8 }>, <{ i8, i32, [4 x i8], i8 }>* @"symbolic _____yypG s23_ContiguousArrayStorageC", i32 0, i32 1) to i64)) to i32), [4 x i8] c"yypG", i8 0 }>, section "swift5_typeref", no_sanitize_address, align 2
@"$ss23_ContiguousArrayStorageCyypGMD" = linkonce_odr hidden global { i32, i32 } { i32 trunc (i64 sub (i64 ptrtoint (<{ i8, i32, [4 x i8], i8 }>* @"symbolic _____yypG s23_ContiguousArrayStorageC" to i64), i64 ptrtoint ({ i32, i32 }* @"$ss23_ContiguousArrayStorageCyypGMD" to i64)) to i32), i32 -9 }, align 8
@"$sSiN" = external global %swift.type, align 8
@"\01l_entry_point" = private constant { i32, i32 } { i32 trunc (i64 sub (i64 ptrtoint (i32 (i32, i8**)* @main to i64), i64 ptrtoint ({ i32, i32 }* @"\01l_entry_point" to i64)) to i32), i32 0 }, section "swift5_entry", align 4
@"symbolic _____ySiG s23_ContiguousArrayStorageC" = linkonce_odr hidden constant <{ i8, i32, [4 x i8], i8 }> <{ i8 2, i32 trunc (i64 sub (i64 ptrtoint (%swift.type_descriptor** @"got.$ss23_ContiguousArrayStorageCMn" to i64), i64 ptrtoint (i32* getelementptr inbounds (<{ i8, i32, [4 x i8], i8 }>, <{ i8, i32, [4 x i8], i8 }>* @"symbolic _____ySiG s23_ContiguousArrayStorageC", i32 0, i32 1) to i64)) to i32), [4 x i8] c"ySiG", i8 0 }>, section "swift5_typeref", no_sanitize_address, align 2
@"$ss23_ContiguousArrayStorageCySiGMD" = linkonce_odr hidden global { i32, i32 } { i32 trunc (i64 sub (i64 ptrtoint (<{ i8, i32, [4 x i8], i8 }>* @"symbolic _____ySiG s23_ContiguousArrayStorageC" to i64), i64 ptrtoint ({ i32, i32 }* @"$ss23_ContiguousArrayStorageCySiGMD" to i64)) to i32), i32 -9 }, align 8
@__swift_reflection_version = linkonce_odr hidden constant i16 3
@_swift1_autolink_entries = private constant [172 x i8] c"-lFoundation\00-lswiftCore\00-lswift_StringProcessing\00-lswift_RegexParser\00-lswift_Concurrency\00-lswiftGlibc\00-lm\00-lpthread\00-lutil\00-ldl\00-lswiftDispatch\00-ldispatch\00-lBlocksRuntime\00", section ".swift1_autolink_entries", no_sanitize_address, align 8
@llvm.compiler.used = appending global [4 x i8*] [i8* bitcast ({ i32, i32 }* @"\01l_entry_point" to i8*), i8* bitcast (i16* @__swift_reflection_version to i8*), i8* getelementptr inbounds ([172 x i8], [172 x i8]* @_swift1_autolink_entries, i32 0, i32 0), i8* bitcast (i32 (i32, i8**)* @main to i8*)], section "llvm.metadata"

define protected i32 @main(i32 %0, i8** nocapture readnone %1) #0 {
entry:
  tail call swiftcc void @"$s7llvm_O34mainyyF"()
  ret i32 0
}

define hidden swiftcc void @"$s7llvm_O34mainyyF"() local_unnamed_addr #0 {
entry:
  %0 = alloca %TSS, align 8
  %1 = alloca %TSS, align 8
  %2 = alloca %Ts15ContiguousArrayV, align 8
  %3 = tail call swiftcc { i64, i64 } @"$ss8readLine16strippingNewlineSSSgSb_tF"(i1 true)
  %4 = extractvalue { i64, i64 } %3, 1
  %5 = icmp eq i64 %4, 0
  br i1 %5, label %77, label %6

6:                                                ; preds = %entry
  %7 = extractvalue { i64, i64 } %3, 0
  %8 = inttoptr i64 %4 to %swift.bridge*
  %9 = bitcast %TSS* %0 to i8*
  call void @llvm.lifetime.start.p0i8(i64 16, i8* nonnull %9)
  %._guts._object._countAndFlagsBits._value = getelementptr inbounds %TSS, %TSS* %0, i64 0, i32 0, i32 0, i32 0, i32 0
  store i64 %7, i64* %._guts._object._countAndFlagsBits._value, align 8
  %._guts._object._object = getelementptr inbounds %TSS, %TSS* %0, i64 0, i32 0, i32 0, i32 1
  store %swift.bridge* %8, %swift.bridge** %._guts._object._object, align 8
  %10 = bitcast %TSS* %1 to i8*
  call void @llvm.lifetime.start.p0i8(i64 16, i8* nonnull %10)
  %._guts1._object._countAndFlagsBits._value = getelementptr inbounds %TSS, %TSS* %1, i64 0, i32 0, i32 0, i32 0, i32 0
  store i64 83, i64* %._guts1._object._countAndFlagsBits._value, align 8
  %._guts1._object._object = getelementptr inbounds %TSS, %TSS* %1, i64 0, i32 0, i32 0, i32 1
  store %swift.bridge* inttoptr (i64 -2233785415175766016 to %swift.bridge*), %swift.bridge** %._guts1._object._object, align 8
  %11 = bitcast %TSS* %1 to %swift.opaque*
  %12 = tail call i8** @"$sS2SSysWl"() #13
  %13 = bitcast %TSS* %0 to %swift.opaque*
  %14 = call swiftcc %Ts28__ContiguousArrayStorageBaseC* @"$sSy10FoundationE10components11separatedBySaySSGqd___tSyRd__lF"(%swift.opaque* noalias nocapture nonnull %11, %swift.type* nonnull @"$sSSN", %swift.type* nonnull @"$sSSN", i8** %12, i8** %12, %swift.opaque* noalias nocapture nonnull swiftself %13)
  call void @llvm.lifetime.end.p0i8(i64 16, i8* nonnull %10)
  call void @llvm.lifetime.end.p0i8(i64 16, i8* nonnull %9)
  %._storage.count._value = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %14, i64 0, i32 1, i32 0, i32 0, i32 0
  %15 = load i64, i64* %._storage.count._value, align 8, !range !6
  %16 = icmp eq i64 %15, 0
  br i1 %16, label %17, label %19

17:                                               ; preds = %6
  %18 = getelementptr %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %14, i64 0, i32 0
  tail call void @swift_release(%swift.refcounted* %18) #6
  br label %23

19:                                               ; preds = %6
  %20 = bitcast %Ts15ContiguousArrayV* %2 to i8*
  call void @llvm.lifetime.start.p0i8(i64 8, i8* nonnull %20)
  %._buffer._storage = getelementptr inbounds %Ts15ContiguousArrayV, %Ts15ContiguousArrayV* %2, i64 0, i32 0, i32 0
  store %Ts28__ContiguousArrayStorageBaseC* bitcast (%struct._SwiftEmptyArrayStorage* @_swiftEmptyArrayStorage to %Ts28__ContiguousArrayStorageBaseC*), %Ts28__ContiguousArrayStorageBaseC** %._buffer._storage, align 8
  call swiftcc void @"$ss15ContiguousArrayV16_createNewBuffer14bufferIsUnique15minimumCapacity13growForAppendySb_SiSbtFSi_Tg5"(i1 false, i64 %15, i1 false, %Ts15ContiguousArrayV* nocapture nonnull swiftself dereferenceable(8) %2)
  %21 = load %Ts28__ContiguousArrayStorageBaseC*, %Ts28__ContiguousArrayStorageBaseC** %._buffer._storage, align 8
  %22 = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %14, i64 1
  %tailaddr = bitcast %Ts28__ContiguousArrayStorageBaseC* %22 to %TSS*
  br label %52

23:                                               ; preds = %17, %70
  %24 = phi %Ts28__ContiguousArrayStorageBaseC* [ %66, %70 ], [ bitcast (%struct._SwiftEmptyArrayStorage* @_swiftEmptyArrayStorage to %Ts28__ContiguousArrayStorageBaseC*), %17 ]
  %._storage.count._value.i = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %24, i64 0, i32 1, i32 0, i32 0, i32 0
  %25 = load i64, i64* %._storage.count._value.i, align 8, !range !6
  %26 = icmp eq i64 %25, 0
  br i1 %26, label %"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit", label %27

27:                                               ; preds = %23
  %28 = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %24, i64 1
  %tailaddr.i = bitcast %Ts28__ContiguousArrayStorageBaseC* %28 to %TSi*
  %tailaddr._value.i = bitcast %Ts28__ContiguousArrayStorageBaseC* %28 to i64*
  %29 = load i64, i64* %tailaddr._value.i, align 8
  %30 = icmp eq i64 %25, 1
  br i1 %30, label %"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit", label %.preheader.i.preheader

.preheader.i.preheader:                           ; preds = %27
  %31 = add nsw i64 %25, -1
  %min.iters.check = icmp ult i64 %25, 5
  br i1 %min.iters.check, label %.preheader.i.preheader23, label %vector.ph

vector.ph:                                        ; preds = %.preheader.i.preheader
  %n.vec = and i64 %31, -4
  %ind.end = or i64 %n.vec, 1
  %minmax.ident.splatinsert = insertelement <2 x i64> poison, i64 %29, i64 0
  %minmax.ident.splat = shufflevector <2 x i64> %minmax.ident.splatinsert, <2 x i64> poison, <2 x i32> zeroinitializer
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.phi = phi <2 x i64> [ %minmax.ident.splat, %vector.ph ], [ %36, %vector.body ]
  %vec.phi21 = phi <2 x i64> [ %minmax.ident.splat, %vector.ph ], [ %37, %vector.body ]
  %offset.idx = or i64 %index, 1
  %32 = getelementptr inbounds %TSi, %TSi* %tailaddr.i, i64 %offset.idx, i32 0
  %33 = bitcast i64* %32 to <2 x i64>*
  %wide.load = load <2 x i64>, <2 x i64>* %33, align 8
  %34 = getelementptr inbounds i64, i64* %32, i64 2
  %35 = bitcast i64* %34 to <2 x i64>*
  %wide.load22 = load <2 x i64>, <2 x i64>* %35, align 8
  %36 = tail call <2 x i64> @llvm.smax.v2i64(<2 x i64> %vec.phi, <2 x i64> %wide.load)
  %37 = tail call <2 x i64> @llvm.smax.v2i64(<2 x i64> %vec.phi21, <2 x i64> %wide.load22)
  %index.next = add nuw i64 %index, 4
  %38 = icmp eq i64 %index.next, %n.vec
  br i1 %38, label %middle.block, label %vector.body, !llvm.loop !7

middle.block:                                     ; preds = %vector.body
  %39 = tail call <2 x i64> @llvm.smax.v2i64(<2 x i64> %36, <2 x i64> %37)
  %40 = tail call i64 @llvm.vector.reduce.smax.v2i64(<2 x i64> %39)
  %cmp.n = icmp eq i64 %31, %n.vec
  br i1 %cmp.n, label %"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit", label %.preheader.i.preheader23

.preheader.i.preheader23:                         ; preds = %.preheader.i.preheader, %middle.block
  %.ph = phi i64 [ %29, %.preheader.i.preheader ], [ %40, %middle.block ]
  %.ph24 = phi i64 [ 1, %.preheader.i.preheader ], [ %ind.end, %middle.block ]
  br label %.preheader.i

.preheader.i:                                     ; preds = %.preheader.i.preheader23, %.preheader.i
  %41 = phi i64 [ %44, %.preheader.i ], [ %.ph, %.preheader.i.preheader23 ]
  %42 = phi i64 [ %45, %.preheader.i ], [ %.ph24, %.preheader.i.preheader23 ]
  %._value.i = getelementptr inbounds %TSi, %TSi* %tailaddr.i, i64 %42, i32 0
  %43 = load i64, i64* %._value.i, align 8
  %44 = tail call i64 @llvm.smax.i64(i64 %41, i64 %43)
  %45 = add i64 %42, 1
  %46 = icmp eq i64 %45, %25
  br i1 %46, label %"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit", label %.preheader.i, !llvm.loop !9

"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit": ; preds = %.preheader.i, %middle.block, %23, %27
  %47 = phi i64 [ 0, %23 ], [ %29, %27 ], [ %40, %middle.block ], [ %44, %.preheader.i ]
  %48 = getelementptr %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %24, i64 0, i32 0
  tail call void @swift_release(%swift.refcounted* %48) #6
  %49 = tail call %swift.type* @__swift_instantiateConcreteTypeFromMangledName({ i32, i32 }* nonnull @"$ss23_ContiguousArrayStorageCyypGMD") #14
  %50 = tail call noalias %swift.refcounted* @swift_allocObject(%swift.type* %49, i64 64, i64 7) #6
  %51 = getelementptr inbounds %swift.refcounted, %swift.refcounted* %50, i64 1
  %._storage8.count._value = bitcast %swift.refcounted* %51 to i64*
  store i64 1, i64* %._storage8.count._value, align 8
  %._storage8._capacityAndFlags = getelementptr inbounds %swift.refcounted, %swift.refcounted* %50, i64 1, i32 1
  store i64 2, i64* %._storage8._capacityAndFlags, align 8
  br i1 %26, label %78, label %72

52:                                               ; preds = %65, %19
  %53 = phi i64 [ 0, %19 ], [ %67, %65 ]
  %54 = phi %Ts28__ContiguousArrayStorageBaseC* [ %21, %19 ], [ %66, %65 ]
  %._guts3._object._countAndFlagsBits._value = getelementptr inbounds %TSS, %TSS* %tailaddr, i64 %53, i32 0, i32 0, i32 0, i32 0
  %55 = load i64, i64* %._guts3._object._countAndFlagsBits._value, align 8
  %._guts3._object._object = getelementptr inbounds %TSS, %TSS* %tailaddr, i64 %53, i32 0, i32 0, i32 1
  %56 = load %swift.bridge*, %swift.bridge** %._guts3._object._object, align 8
  %57 = tail call %swift.bridge* @swift_bridgeObjectRetain(%swift.bridge* returned %56) #6
  %58 = tail call swiftcc i64 @"$sSS5countSivg"(i64 %55, %swift.bridge* %56)
  tail call void @swift_bridgeObjectRelease(%swift.bridge* %56) #6
  store %Ts28__ContiguousArrayStorageBaseC* %54, %Ts28__ContiguousArrayStorageBaseC** %._buffer._storage, align 8
  %._storage5.count._value = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %54, i64 0, i32 1, i32 0, i32 0, i32 0
  %59 = load i64, i64* %._storage5.count._value, align 8, !range !6
  %._storage5._capacityAndFlags._value = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %54, i64 0, i32 1, i32 0, i32 1, i32 0
  %60 = load i64, i64* %._storage5._capacityAndFlags._value, align 8
  %61 = lshr i64 %60, 1
  %62 = add nuw nsw i64 %59, 1
  %.not = icmp ugt i64 %61, %59
  br i1 %.not, label %65, label %63, !prof !11

63:                                               ; preds = %52
  %64 = icmp ugt i64 %60, 1
  call swiftcc void @"$ss15ContiguousArrayV16_createNewBuffer14bufferIsUnique15minimumCapacity13growForAppendySb_SiSbtFSi_Tg5"(i1 %64, i64 %62, i1 true, %Ts15ContiguousArrayV* nocapture nonnull swiftself dereferenceable(8) %2)
  %.pre = load %Ts28__ContiguousArrayStorageBaseC*, %Ts28__ContiguousArrayStorageBaseC** %._buffer._storage, align 8
  br label %65

65:                                               ; preds = %52, %63
  %66 = phi %Ts28__ContiguousArrayStorageBaseC* [ %54, %52 ], [ %.pre, %63 ]
  %67 = add nuw nsw i64 %53, 1
  %._storage6.count._value = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %66, i64 0, i32 1, i32 0, i32 0, i32 0
  store i64 %62, i64* %._storage6.count._value, align 8
  %68 = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %66, i64 1
  %tailaddr7 = bitcast %Ts28__ContiguousArrayStorageBaseC* %68 to %TSi*
  %._value = getelementptr inbounds %TSi, %TSi* %tailaddr7, i64 %59, i32 0
  store i64 %58, i64* %._value, align 8
  %69 = icmp eq i64 %67, %15
  br i1 %69, label %70, label %52

70:                                               ; preds = %65
  %71 = getelementptr %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %14, i64 0, i32 0
  tail call void @swift_release(%swift.refcounted* %71) #6
  call void @llvm.lifetime.end.p0i8(i64 8, i8* nonnull %20)
  br label %23

72:                                               ; preds = %"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit"
  %73 = bitcast %swift.refcounted* %50 to %Ts28__ContiguousArrayStorageBaseC*
  %74 = getelementptr inbounds %swift.refcounted, %swift.refcounted* %50, i64 2
  %75 = getelementptr inbounds %swift.refcounted, %swift.refcounted* %50, i64 3, i32 1
  %76 = bitcast i64* %75 to %swift.type**
  store %swift.type* @"$sSiN", %swift.type** %76, align 8
  %._value10 = bitcast %swift.refcounted* %74 to i64*
  store i64 %47, i64* %._value10, align 8
  tail call swiftcc void @"$ss5print_9separator10terminatoryypd_S2StF"(%Ts28__ContiguousArrayStorageBaseC* %73, i64 32, %swift.bridge* nonnull inttoptr (i64 -2233785415175766016 to %swift.bridge*), i64 10, %swift.bridge* nonnull inttoptr (i64 -2233785415175766016 to %swift.bridge*))
  tail call void @swift_bridgeObjectRelease(%swift.bridge* nonnull %8) #6
  tail call void @swift_release(%swift.refcounted* nonnull %50) #6
  br label %77

77:                                               ; preds = %entry, %72
  ret void

78:                                               ; preds = %"$sSTsSL7ElementRpzrlE3maxABSgyFSaySiG_Tg5.exit"
  tail call void asm sideeffect "", "n"(i32 1) #6
  tail call void @llvm.trap()
  unreachable
}

declare swiftcc { i64, i64 } @"$ss8readLine16strippingNewlineSSSgSb_tF"(i1) local_unnamed_addr #0

; Function Attrs: argmemonly mustprogress nocallback nofree nosync nounwind willreturn
declare void @llvm.lifetime.start.p0i8(i64 immarg, i8* nocapture) #1

; Function Attrs: argmemonly mustprogress nocallback nofree nosync nounwind willreturn
declare void @llvm.lifetime.end.p0i8(i64 immarg, i8* nocapture) #1

declare swiftcc %Ts28__ContiguousArrayStorageBaseC* @"$sSy10FoundationE10components11separatedBySaySSGqd___tSyRd__lF"(%swift.opaque* noalias nocapture, %swift.type*, %swift.type*, i8**, i8**, %swift.opaque* noalias nocapture swiftself) local_unnamed_addr #0

; Function Attrs: nofree noinline nosync nounwind readnone
define linkonce_odr hidden i8** @"$sS2SSysWl"() local_unnamed_addr #2 {
entry:
  %0 = load i8**, i8*** @"$sS2SSysWL", align 8
  %1 = icmp eq i8** %0, null
  br i1 %1, label %cacheIsNull, label %cont

cacheIsNull:                                      ; preds = %entry
  %2 = tail call i8** @swift_getWitnessTable(%swift.protocol_conformance_descriptor* nonnull @"$sSSSysMc", %swift.type* nonnull @"$sSSN", i8*** undef) #14
  store atomic i8** %2, i8*** @"$sS2SSysWL" release, align 8
  br label %cont

cont:                                             ; preds = %cacheIsNull, %entry
  %3 = phi i8** [ %0, %entry ], [ %2, %cacheIsNull ]
  ret i8** %3
}

; Function Attrs: nofree nounwind readonly
declare i8** @swift_getWitnessTable(%swift.protocol_conformance_descriptor*, %swift.type*, i8***) local_unnamed_addr #3

; Function Attrs: noinline
define linkonce_odr hidden swiftcc void @"$ss15ContiguousArrayV16_createNewBuffer14bufferIsUnique15minimumCapacity13growForAppendySb_SiSbtFSi_Tg5"(i1 %0, i64 %1, i1 %2, %Ts15ContiguousArrayV* nocapture swiftself dereferenceable(8) %3) local_unnamed_addr #4 {
entry:
  %._buffer._storage = getelementptr inbounds %Ts15ContiguousArrayV, %Ts15ContiguousArrayV* %3, i64 0, i32 0, i32 0
  %4 = load %Ts28__ContiguousArrayStorageBaseC*, %Ts28__ContiguousArrayStorageBaseC** %._buffer._storage, align 8
  %5 = tail call swiftcc %Ts28__ContiguousArrayStorageBaseC* @"$ss22_ContiguousArrayBufferV20_consumeAndCreateNew14bufferIsUnique15minimumCapacity13growForAppendAByxGSb_SiSbtFSi_Tg5"(i1 %0, i64 %1, i1 %2, %Ts28__ContiguousArrayStorageBaseC* %4)
  store %Ts28__ContiguousArrayStorageBaseC* %5, %Ts28__ContiguousArrayStorageBaseC** %._buffer._storage, align 8
  ret void
}

declare swiftcc i64 @"$sSS5countSivg"(i64, %swift.bridge*) local_unnamed_addr #0

; Function Attrs: cold noreturn nounwind
declare void @llvm.trap() #5

; Function Attrs: nounwind
declare %swift.bridge* @swift_bridgeObjectRetain(%swift.bridge* returned) local_unnamed_addr #6

; Function Attrs: nounwind
declare void @swift_bridgeObjectRelease(%swift.bridge*) local_unnamed_addr #6

; Function Attrs: nounwind
declare void @swift_release(%swift.refcounted*) local_unnamed_addr #6

; Function Attrs: mustprogress nofree noinline nounwind readonly willreturn
define linkonce_odr hidden %swift.type* @__swift_instantiateConcreteTypeFromMangledName({ i32, i32 }* %0) local_unnamed_addr #7 {
entry:
  %1 = bitcast { i32, i32 }* %0 to i64*
  %2 = load atomic i64, i64* %1 monotonic, align 8
  %3 = icmp slt i64 %2, 0
  br i1 %3, label %7, label %4, !prof !12

4:                                                ; preds = %7, %entry
  %5 = phi i64 [ %2, %entry ], [ %15, %7 ]
  %6 = inttoptr i64 %5 to %swift.type*
  ret %swift.type* %6

7:                                                ; preds = %entry
  %8 = ashr i64 %2, 32
  %9 = sub nsw i64 0, %8
  %sext = shl i64 %2, 32
  %10 = ashr exact i64 %sext, 32
  %11 = ptrtoint { i32, i32 }* %0 to i64
  %12 = add i64 %10, %11
  %13 = inttoptr i64 %12 to i8*
  %14 = tail call swiftcc %swift.type* @swift_getTypeByMangledNameInContext2(i8* %13, i64 %9, %swift.type_descriptor* null, i8** null) #15
  %15 = ptrtoint %swift.type* %14 to i64
  store atomic i64 %15, i64* %1 monotonic, align 8
  br label %4
}

; Function Attrs: argmemonly nounwind
declare swiftcc %swift.type* @swift_getTypeByMangledNameInContext2(i8*, i64, %swift.type_descriptor*, i8**) local_unnamed_addr #8

; Function Attrs: nounwind
declare %swift.refcounted* @swift_allocObject(%swift.type*, i64, i64) local_unnamed_addr #6

declare swiftcc void @"$ss5print_9separator10terminatoryypd_S2StF"(%Ts28__ContiguousArrayStorageBaseC*, i64, %swift.bridge*, i64, %swift.bridge*) local_unnamed_addr #0

; Function Attrs: noinline
define linkonce_odr hidden swiftcc %Ts28__ContiguousArrayStorageBaseC* @"$ss22_ContiguousArrayBufferV20_consumeAndCreateNew14bufferIsUnique15minimumCapacity13growForAppendAByxGSb_SiSbtFSi_Tg5"(i1 %0, i64 %1, i1 %2, %Ts28__ContiguousArrayStorageBaseC* %3) local_unnamed_addr #4 {
entry:
  br i1 %2, label %4, label %14

4:                                                ; preds = %entry
  %._storage._capacityAndFlags._value = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %3, i64 0, i32 1, i32 0, i32 1, i32 0
  %5 = load i64, i64* %._storage._capacityAndFlags._value, align 8
  %6 = lshr i64 %5, 1
  %7 = icmp slt i64 %6, %1
  br i1 %7, label %8, label %14

8:                                                ; preds = %4
  %9 = add nuw i64 %6, 4611686018427387904
  %10 = icmp slt i64 %9, 0
  br i1 %10, label %46, label %11, !prof !12

11:                                               ; preds = %8
  %12 = and i64 %5, -2
  %13 = tail call i64 @llvm.smax.i64(i64 %12, i64 %1)
  br label %14

14:                                               ; preds = %4, %11, %entry
  %15 = phi i64 [ %1, %entry ], [ %13, %11 ], [ %6, %4 ]
  %._storage.count._value = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %3, i64 0, i32 1, i32 0, i32 0, i32 0
  %16 = load i64, i64* %._storage.count._value, align 8, !range !6
  %17 = tail call i64 @llvm.smax.i64(i64 %15, i64 %16)
  %18 = icmp eq i64 %17, 0
  br i1 %18, label %29, label %19

19:                                               ; preds = %14
  %20 = tail call %swift.type* @__swift_instantiateConcreteTypeFromMangledName({ i32, i32 }* nonnull @"$ss23_ContiguousArrayStorageCySiGMD") #14
  %21 = shl i64 %17, 3
  %22 = add i64 %21, 32
  %23 = tail call noalias %swift.refcounted* @swift_allocObject(%swift.type* %20, i64 %22, i64 7) #6
  %24 = bitcast %swift.refcounted* %23 to %Ts28__ContiguousArrayStorageBaseC*
  %25 = bitcast %swift.refcounted* %23 to i8*
  %call.i = tail call i64 @malloc_usable_size(i8* noundef %25) #16
  %gepdiff = add nsw i64 %call.i, -32
  %26 = sdiv i64 %gepdiff, 8
  %27 = shl nsw i64 %26, 1
  %28 = getelementptr inbounds %swift.refcounted, %swift.refcounted* %23, i64 1
  %._storage7.count._value = bitcast %swift.refcounted* %28 to i64*
  store i64 %16, i64* %._storage7.count._value, align 8
  %._storage7._capacityAndFlags = getelementptr inbounds %swift.refcounted, %swift.refcounted* %23, i64 1, i32 1
  store i64 %27, i64* %._storage7._capacityAndFlags, align 8
  br label %29

29:                                               ; preds = %14, %19
  %30 = phi %Ts28__ContiguousArrayStorageBaseC* [ %24, %19 ], [ bitcast (%struct._SwiftEmptyArrayStorage* @_swiftEmptyArrayStorage to %Ts28__ContiguousArrayStorageBaseC*), %14 ]
  %31 = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %30, i64 1
  %32 = bitcast %Ts28__ContiguousArrayStorageBaseC* %31 to i8*
  %33 = getelementptr inbounds %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %3, i64 1
  %34 = bitcast %Ts28__ContiguousArrayStorageBaseC* %33 to i8*
  br i1 %0, label %35, label %42

35:                                               ; preds = %29
  %tailaddr4 = bitcast %Ts28__ContiguousArrayStorageBaseC* %33 to %TSi*
  %36 = getelementptr inbounds %TSi, %TSi* %tailaddr4, i64 %16
  %37 = bitcast %TSi* %36 to %Ts28__ContiguousArrayStorageBaseC*
  %38 = icmp ult %Ts28__ContiguousArrayStorageBaseC* %31, %37
  %39 = icmp eq %Ts28__ContiguousArrayStorageBaseC* %30, %3
  %or.cond14 = select i1 %39, i1 %38, i1 false
  br i1 %or.cond14, label %41, label %.sink.split

.sink.split:                                      ; preds = %35
  %40 = shl nuw i64 %16, 3
  tail call void @llvm.memmove.p0i8.p0i8.i64(i8* nonnull align 8 %32, i8* nonnull align 8 %34, i64 %40, i1 false)
  br label %41

41:                                               ; preds = %35, %.sink.split
  store i64 0, i64* %._storage.count._value, align 8
  br label %44

42:                                               ; preds = %29
  %43 = shl nuw i64 %16, 3
  tail call void @llvm.memcpy.p0i8.p0i8.i64(i8* nonnull align 8 %32, i8* nonnull align 8 %34, i64 %43, i1 false)
  br label %44

44:                                               ; preds = %41, %42
  %45 = getelementptr %Ts28__ContiguousArrayStorageBaseC, %Ts28__ContiguousArrayStorageBaseC* %3, i64 0, i32 0
  tail call void @swift_release(%swift.refcounted* %45) #6
  ret %Ts28__ContiguousArrayStorageBaseC* %30

46:                                               ; preds = %8
  tail call void asm sideeffect "", "n"(i32 0) #6
  tail call void @llvm.trap()
  unreachable
}

; Function Attrs: argmemonly mustprogress nocallback nofree nounwind willreturn
declare void @llvm.memcpy.p0i8.p0i8.i64(i8* noalias nocapture writeonly, i8* noalias nocapture readonly, i64, i1 immarg) #9

; Function Attrs: argmemonly mustprogress nocallback nofree nounwind willreturn
declare void @llvm.memmove.p0i8.p0i8.i64(i8* nocapture writeonly, i8* nocapture readonly, i64, i1 immarg) #9

; Function Attrs: optsize
declare i64 @malloc_usable_size(i8* noundef) local_unnamed_addr #10

; Function Attrs: nocallback nofree nosync nounwind readnone speculatable willreturn
declare i64 @llvm.smax.i64(i64, i64) #11

; Function Attrs: nocallback nofree nosync nounwind readnone speculatable willreturn
declare <2 x i64> @llvm.smax.v2i64(<2 x i64>, <2 x i64>) #11

; Function Attrs: nocallback nofree nosync nounwind readnone willreturn
declare i64 @llvm.vector.reduce.smax.v2i64(<2 x i64>) #12

attributes #0 = { "frame-pointer"="none" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx16,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { argmemonly mustprogress nocallback nofree nosync nounwind willreturn }
attributes #2 = { nofree noinline nosync nounwind readnone "frame-pointer"="non-leaf" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx16,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nofree nounwind readonly }
attributes #4 = { noinline "frame-pointer"="none" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx16,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { cold noreturn nounwind }
attributes #6 = { nounwind }
attributes #7 = { mustprogress nofree noinline nounwind readonly willreturn "frame-pointer"="non-leaf" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx16,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { argmemonly nounwind }
attributes #9 = { argmemonly mustprogress nocallback nofree nounwind willreturn }
attributes #10 = { optsize "frame-pointer"="none" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cx16,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #11 = { nocallback nofree nosync nounwind readnone speculatable willreturn }
attributes #12 = { nocallback nofree nosync nounwind readnone willreturn }
attributes #13 = { nounwind readnone }
attributes #14 = { nounwind readonly }
attributes #15 = { argmemonly nounwind readonly }
attributes #16 = { nounwind optsize }

!swift.module.flags = !{!0}
!llvm.linker.options = !{}
!llvm.module.flags = !{!1, !2, !3, !4, !5}

!0 = !{!"standard-library", i1 false}
!1 = !{i32 1, !"wchar_size", i32 4}
!2 = !{i32 8, !"PIC Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{i32 4, !"Objective-C Garbage Collection", i32 84477696}
!5 = !{i32 1, !"Swift Version", i32 7}
!6 = !{i64 0, i64 9223372036854775807}
!7 = distinct !{!7, !8}
!8 = !{!"llvm.loop.isvectorized", i32 1}
!9 = distinct !{!9, !10, !8}
!10 = !{!"llvm.loop.unroll.runtime.disable"}
!11 = !{!"branch_weights", i32 2000, i32 1}
!12 = !{!"branch_weights", i32 1, i32 2000}
