; LLVM IR from turi-code/SFrame :: oss_src/flexible_type (string_escape)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN8graphlab13escape_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEcbcbbRS5_Rm(ptr noundef nonnull align 8 dereferenceable(32) %0, i8 noundef signext %1, i1 noundef zeroext %2, i8 noundef signext %3, i1 noundef zeroext %4, i1 noundef zeroext %5, ptr noundef nonnull align 8 dereferenceable(32) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #0 {
  %9 = alloca ptr, align 8
  %10 = alloca i8, align 1
  %11 = alloca i8, align 1
  %12 = alloca i8, align 1
  %13 = alloca i8, align 1
  %14 = alloca i8, align 1
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca i64, align 8
  %19 = alloca i8, align 1
  %20 = alloca i64, align 8
  %21 = alloca i8, align 1
  %22 = alloca i64, align 8
  store ptr %0, ptr %9, align 8, !tbaa !5
  store i8 %1, ptr %10, align 1, !tbaa !9
  %23 = zext i1 %2 to i8
  store i8 %23, ptr %11, align 1, !tbaa !10
  store i8 %3, ptr %12, align 1, !tbaa !9
  %24 = zext i1 %4 to i8
  store i8 %24, ptr %13, align 1, !tbaa !10
  %25 = zext i1 %5 to i8
  store i8 %25, ptr %14, align 1, !tbaa !10
  store ptr %6, ptr %15, align 8, !tbaa !5
  store ptr %7, ptr %16, align 8, !tbaa !5
  %26 = load ptr, ptr %15, align 8, !tbaa !5
  %27 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %26) #3
  %28 = load ptr, ptr %9, align 8, !tbaa !5
  %29 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %28) #3
  %30 = mul i64 2, %29
  %31 = add i64 2, %30
  %32 = icmp ult i64 %27, %31
  br i1 %32, label %33, label %39

33:                                               ; preds = %8
  %34 = load ptr, ptr %15, align 8, !tbaa !5
  %35 = load ptr, ptr %9, align 8, !tbaa !5
  %36 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %35) #3
  %37 = mul i64 2, %36
  %38 = add i64 2, %37
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(32) %34, i64 noundef %38)
  br label %39

39:                                               ; preds = %33, %8
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  %40 = load ptr, ptr %15, align 8, !tbaa !5
  %41 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %40, i64 noundef 0)
  store ptr %41, ptr %17, align 8, !tbaa !5
  %42 = load i8, ptr %13, align 1, !tbaa !10, !range !12, !noundef !13
  %43 = trunc i8 %42 to i1
  br i1 %43, label %44, label %48

44:                                               ; preds = %39
  %45 = load i8, ptr %12, align 1, !tbaa !9
  %46 = load ptr, ptr %17, align 8, !tbaa !5
  %47 = getelementptr inbounds i8, ptr %46, i32 1
  store ptr %47, ptr %17, align 8, !tbaa !5
  store i8 %45, ptr %46, align 1, !tbaa !9
  br label %48

48:                                               ; preds = %44, %39
  %49 = load i8, ptr %11, align 1, !tbaa !10, !range !12, !noundef !13
  %50 = trunc i8 %49 to i1
  br i1 %50, label %51, label %197

51:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  store i64 0, ptr %18, align 8, !tbaa !14
  br label %52

52:                                               ; preds = %193, %51
  %53 = load i64, ptr %18, align 8, !tbaa !14
  %54 = load ptr, ptr %9, align 8, !tbaa !5
  %55 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %54) #3
  %56 = icmp ult i64 %53, %55
  br i1 %56, label %58, label %57

57:                                               ; preds = %52
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  br label %196

58:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 1, ptr %19) #3
  %59 = load ptr, ptr %9, align 8, !tbaa !5
  %60 = load i64, ptr %18, align 8, !tbaa !14
  %61 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %59, i64 noundef %60) #3
  %62 = load i8, ptr %61, align 1, !tbaa !9
  store i8 %62, ptr %19, align 1, !tbaa !9
  %63 = load i8, ptr %19, align 1, !tbaa !9
  %64 = sext i8 %63 to i32
  switch i32 %64, label %188 [
    i32 39, label %65
    i32 34, label %95
    i32 92, label %125
    i32 9, label %158
    i32 8, label %164
    i32 13, label %170
    i32 10, label %176
    i32 0, label %182
  ]

65:                                               ; preds = %58
  %66 = load i8, ptr %14, align 1, !tbaa !10, !range !12, !noundef !13
  %67 = trunc i8 %66 to i1
  br i1 %67, label %68, label %77

68:                                               ; preds = %65
  %69 = load i8, ptr %12, align 1, !tbaa !9
  %70 = sext i8 %69 to i32
  %71 = icmp eq i32 %70, 39
  br i1 %71, label %72, label %77

72:                                               ; preds = %68
  %73 = load ptr, ptr %17, align 8, !tbaa !5
  %74 = getelementptr inbounds i8, ptr %73, i32 1
  store ptr %74, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %73, align 1, !tbaa !9
  %75 = load ptr, ptr %17, align 8, !tbaa !5
  %76 = getelementptr inbounds i8, ptr %75, i32 1
  store ptr %76, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %75, align 1, !tbaa !9
  br label %94

77:                                               ; preds = %68, %65
  %78 = load i8, ptr %13, align 1, !tbaa !10, !range !12, !noundef !13
  %79 = trunc i8 %78 to i1
  br i1 %79, label %80, label %90

80:                                               ; preds = %77
  %81 = load i8, ptr %12, align 1, !tbaa !9
  %82 = sext i8 %81 to i32
  %83 = icmp eq i32 %82, 39
  br i1 %83, label %84, label %90

84:                                               ; preds = %80
  %85 = load i8, ptr %10, align 1, !tbaa !9
  %86 = load ptr, ptr %17, align 8, !tbaa !5
  %87 = getelementptr inbounds i8, ptr %86, i32 1
  store ptr %87, ptr %17, align 8, !tbaa !5
  store i8 %85, ptr %86, align 1, !tbaa !9
  %88 = load ptr, ptr %17, align 8, !tbaa !5
  %89 = getelementptr inbounds i8, ptr %88, i32 1
  store ptr %89, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %88, align 1, !tbaa !9
  br label %93

90:                                               ; preds = %80, %77
  %91 = load ptr, ptr %17, align 8, !tbaa !5
  %92 = getelementptr inbounds i8, ptr %91, i32 1
  store ptr %92, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %91, align 1, !tbaa !9
  br label %93

93:                                               ; preds = %90, %84
  br label %94

94:                                               ; preds = %93, %72
  br label %192

95:                                               ; preds = %58
  %96 = load i8, ptr %14, align 1, !tbaa !10, !range !12, !noundef !13
  %97 = trunc i8 %96 to i1
  br i1 %97, label %98, label %107

98:                                               ; preds = %95
  %99 = load i8, ptr %12, align 1, !tbaa !9
  %100 = sext i8 %99 to i32
  %101 = icmp eq i32 %100, 34
  br i1 %101, label %102, label %107

102:                                              ; preds = %98
  %103 = load ptr, ptr %17, align 8, !tbaa !5
  %104 = getelementptr inbounds i8, ptr %103, i32 1
  store ptr %104, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %103, align 1, !tbaa !9
  %105 = load ptr, ptr %17, align 8, !tbaa !5
  %106 = getelementptr inbounds i8, ptr %105, i32 1
  store ptr %106, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %105, align 1, !tbaa !9
  br label %124

107:                                              ; preds = %98, %95
  %108 = load i8, ptr %13, align 1, !tbaa !10, !range !12, !noundef !13
  %109 = trunc i8 %108 to i1
  br i1 %109, label %110, label %120

110:                                              ; preds = %107
  %111 = load i8, ptr %12, align 1, !tbaa !9
  %112 = sext i8 %111 to i32
  %113 = icmp eq i32 %112, 34
  br i1 %113, label %114, label %120

114:                                              ; preds = %110
  %115 = load i8, ptr %10, align 1, !tbaa !9
  %116 = load ptr, ptr %17, align 8, !tbaa !5
  %117 = getelementptr inbounds i8, ptr %116, i32 1
  store ptr %117, ptr %17, align 8, !tbaa !5
  store i8 %115, ptr %116, align 1, !tbaa !9
  %118 = load ptr, ptr %17, align 8, !tbaa !5
  %119 = getelementptr inbounds i8, ptr %118, i32 1
  store ptr %119, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %118, align 1, !tbaa !9
  br label %123

120:                                              ; preds = %110, %107
  %121 = load ptr, ptr %17, align 8, !tbaa !5
  %122 = getelementptr inbounds i8, ptr %121, i32 1
  store ptr %122, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %121, align 1, !tbaa !9
  br label %123

123:                                              ; preds = %120, %114
  br label %124

124:                                              ; preds = %123, %102
  br label %192

125:                                              ; preds = %58
  %126 = load i64, ptr %18, align 8, !tbaa !14
  %127 = load ptr, ptr %9, align 8, !tbaa !5
  %128 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %127) #3
  %129 = sub i64 %128, 1
  %130 = icmp ult i64 %126, %129
  br i1 %130, label %131, label %151

131:                                              ; preds = %125
  %132 = load ptr, ptr %9, align 8, !tbaa !5
  %133 = load i64, ptr %18, align 8, !tbaa !14
  %134 = add i64 %133, 1
  %135 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %132, i64 noundef %134) #3
  %136 = load i8, ptr %135, align 1, !tbaa !9
  %137 = sext i8 %136 to i32
  %138 = icmp eq i32 %137, 117
  br i1 %138, label %147, label %139

139:                                              ; preds = %131
  %140 = load ptr, ptr %9, align 8, !tbaa !5
  %141 = load i64, ptr %18, align 8, !tbaa !14
  %142 = add i64 %141, 1
  %143 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %140, i64 noundef %142) #3
  %144 = load i8, ptr %143, align 1, !tbaa !9
  %145 = sext i8 %144 to i32
  %146 = icmp eq i32 %145, 120
  br i1 %146, label %147, label %151

147:                                              ; preds = %139, %131
  %148 = load i8, ptr %19, align 1, !tbaa !9
  %149 = load ptr, ptr %17, align 8, !tbaa !5
  %150 = getelementptr inbounds i8, ptr %149, i32 1
  store ptr %150, ptr %17, align 8, !tbaa !5
  store i8 %148, ptr %149, align 1, !tbaa !9
  br label %157

151:                                              ; preds = %139, %125
  %152 = load i8, ptr %10, align 1, !tbaa !9
  %153 = load ptr, ptr %17, align 8, !tbaa !5
  %154 = getelementptr inbounds i8, ptr %153, i32 1
  store ptr %154, ptr %17, align 8, !tbaa !5
  store i8 %152, ptr %153, align 1, !tbaa !9
  %155 = load ptr, ptr %17, align 8, !tbaa !5
  %156 = getelementptr inbounds i8, ptr %155, i32 1
  store ptr %156, ptr %17, align 8, !tbaa !5
  store i8 92, ptr %155, align 1, !tbaa !9
  br label %157

157:                                              ; preds = %151, %147
  br label %192

158:                                              ; preds = %58
  %159 = load i8, ptr %10, align 1, !tbaa !9
  %160 = load ptr, ptr %17, align 8, !tbaa !5
  %161 = getelementptr inbounds i8, ptr %160, i32 1
  store ptr %161, ptr %17, align 8, !tbaa !5
  store i8 %159, ptr %160, align 1, !tbaa !9
  %162 = load ptr, ptr %17, align 8, !tbaa !5
  %163 = getelementptr inbounds i8, ptr %162, i32 1
  store ptr %163, ptr %17, align 8, !tbaa !5
  store i8 116, ptr %162, align 1, !tbaa !9
  br label %192

164:                                              ; preds = %58
  %165 = load i8, ptr %10, align 1, !tbaa !9
  %166 = load ptr, ptr %17, align 8, !tbaa !5
  %167 = getelementptr inbounds i8, ptr %166, i32 1
  store ptr %167, ptr %17, align 8, !tbaa !5
  store i8 %165, ptr %166, align 1, !tbaa !9
  %168 = load ptr, ptr %17, align 8, !tbaa !5
  %169 = getelementptr inbounds i8, ptr %168, i32 1
  store ptr %169, ptr %17, align 8, !tbaa !5
  store i8 98, ptr %168, align 1, !tbaa !9
  br label %192

170:                                              ; preds = %58
  %171 = load i8, ptr %10, align 1, !tbaa !9
  %172 = load ptr, ptr %17, align 8, !tbaa !5
  %173 = getelementptr inbounds i8, ptr %172, i32 1
  store ptr %173, ptr %17, align 8, !tbaa !5
  store i8 %171, ptr %172, align 1, !tbaa !9
  %174 = load ptr, ptr %17, align 8, !tbaa !5
  %175 = getelementptr inbounds i8, ptr %174, i32 1
  store ptr %175, ptr %17, align 8, !tbaa !5
  store i8 114, ptr %174, align 1, !tbaa !9
  br label %192

176:                                              ; preds = %58
  %177 = load i8, ptr %10, align 1, !tbaa !9
  %178 = load ptr, ptr %17, align 8, !tbaa !5
  %179 = getelementptr inbounds i8, ptr %178, i32 1
  store ptr %179, ptr %17, align 8, !tbaa !5
  store i8 %177, ptr %178, align 1, !tbaa !9
  %180 = load ptr, ptr %17, align 8, !tbaa !5
  %181 = getelementptr inbounds i8, ptr %180, i32 1
  store ptr %181, ptr %17, align 8, !tbaa !5
  store i8 110, ptr %180, align 1, !tbaa !9
  br label %192

182:                                              ; preds = %58
  %183 = load i8, ptr %10, align 1, !tbaa !9
  %184 = load ptr, ptr %17, align 8, !tbaa !5
  %185 = getelementptr inbounds i8, ptr %184, i32 1
  store ptr %185, ptr %17, align 8, !tbaa !5
  store i8 %183, ptr %184, align 1, !tbaa !9
  %186 = load ptr, ptr %17, align 8, !tbaa !5
  %187 = getelementptr inbounds i8, ptr %186, i32 1
  store ptr %187, ptr %17, align 8, !tbaa !5
  store i8 0, ptr %186, align 1, !tbaa !9
  br label %192

188:                                              ; preds = %58
  %189 = load i8, ptr %19, align 1, !tbaa !9
  %190 = load ptr, ptr %17, align 8, !tbaa !5
  %191 = getelementptr inbounds i8, ptr %190, i32 1
  store ptr %191, ptr %17, align 8, !tbaa !5
  store i8 %189, ptr %190, align 1, !tbaa !9
  br label %192

192:                                              ; preds = %188, %182, %176, %170, %164, %158, %157, %124, %94
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #3
  br label %193

193:                                              ; preds = %192
  %194 = load i64, ptr %18, align 8, !tbaa !14
  %195 = add i64 %194, 1
  store i64 %195, ptr %18, align 8, !tbaa !14
  br label %52, !llvm.loop !16

196:                                              ; preds = %57
  br label %248

197:                                              ; preds = %48
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #3
  store i64 0, ptr %20, align 8, !tbaa !14
  br label %198

198:                                              ; preds = %244, %197
  %199 = load i64, ptr %20, align 8, !tbaa !14
  %200 = load ptr, ptr %9, align 8, !tbaa !5
  %201 = call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %200) #3
  %202 = icmp ult i64 %199, %201
  br i1 %202, label %204, label %203

203:                                              ; preds = %198
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #3
  br label %247

204:                                              ; preds = %198
  call void @llvm.lifetime.start.p0(i64 1, ptr %21) #3
  %205 = load ptr, ptr %9, align 8, !tbaa !5
  %206 = load i64, ptr %20, align 8, !tbaa !14
  %207 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %205, i64 noundef %206) #3
  %208 = load i8, ptr %207, align 1, !tbaa !9
  store i8 %208, ptr %21, align 1, !tbaa !9
  %209 = load i8, ptr %21, align 1, !tbaa !9
  %210 = sext i8 %209 to i32
  switch i32 %210, label %239 [
    i32 39, label %211
    i32 34, label %227
  ]

211:                                              ; preds = %204
  %212 = load i8, ptr %14, align 1, !tbaa !10, !range !12, !noundef !13
  %213 = trunc i8 %212 to i1
  br i1 %213, label %214, label %223

214:                                              ; preds = %211
  %215 = load i8, ptr %12, align 1, !tbaa !9
  %216 = sext i8 %215 to i32
  %217 = icmp eq i32 %216, 39
  br i1 %217, label %218, label %223

218:                                              ; preds = %214
  %219 = load ptr, ptr %17, align 8, !tbaa !5
  %220 = getelementptr inbounds i8, ptr %219, i32 1
  store ptr %220, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %219, align 1, !tbaa !9
  %221 = load ptr, ptr %17, align 8, !tbaa !5
  %222 = getelementptr inbounds i8, ptr %221, i32 1
  store ptr %222, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %221, align 1, !tbaa !9
  br label %226

223:                                              ; preds = %214, %211
  %224 = load ptr, ptr %17, align 8, !tbaa !5
  %225 = getelementptr inbounds i8, ptr %224, i32 1
  store ptr %225, ptr %17, align 8, !tbaa !5
  store i8 39, ptr %224, align 1, !tbaa !9
  br label %226

226:                                              ; preds = %223, %218
  br label %243

227:                                              ; preds = %204
  %228 = load i8, ptr %14, align 1, !tbaa !10, !range !12, !noundef !13
  %229 = trunc i8 %228 to i1
  br i1 %229, label %230, label %235

230:                                              ; preds = %227
  %231 = load ptr, ptr %17, align 8, !tbaa !5
  %232 = getelementptr inbounds i8, ptr %231, i32 1
  store ptr %232, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %231, align 1, !tbaa !9
  %233 = load ptr, ptr %17, align 8, !tbaa !5
  %234 = getelementptr inbounds i8, ptr %233, i32 1
  store ptr %234, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %233, align 1, !tbaa !9
  br label %238

235:                                              ; preds = %227
  %236 = load ptr, ptr %17, align 8, !tbaa !5
  %237 = getelementptr inbounds i8, ptr %236, i32 1
  store ptr %237, ptr %17, align 8, !tbaa !5
  store i8 34, ptr %236, align 1, !tbaa !9
  br label %238

238:                                              ; preds = %235, %230
  br label %243

239:                                              ; preds = %204
  %240 = load i8, ptr %21, align 1, !tbaa !9
  %241 = load ptr, ptr %17, align 8, !tbaa !5
  %242 = getelementptr inbounds i8, ptr %241, i32 1
  store ptr %242, ptr %17, align 8, !tbaa !5
  store i8 %240, ptr %241, align 1, !tbaa !9
  br label %243

243:                                              ; preds = %239, %238, %226
  call void @llvm.lifetime.end.p0(i64 1, ptr %21) #3
  br label %244

244:                                              ; preds = %243
  %245 = load i64, ptr %20, align 8, !tbaa !14
  %246 = add i64 %245, 1
  store i64 %246, ptr %20, align 8, !tbaa !14
  br label %198, !llvm.loop !18

247:                                              ; preds = %203
  br label %248

248:                                              ; preds = %247, %196
  %249 = load i8, ptr %13, align 1, !tbaa !10, !range !12, !noundef !13
  %250 = trunc i8 %249 to i1
  br i1 %250, label %251, label %255

251:                                              ; preds = %248
  %252 = load i8, ptr %12, align 1, !tbaa !9
  %253 = load ptr, ptr %17, align 8, !tbaa !5
  %254 = getelementptr inbounds i8, ptr %253, i32 1
  store ptr %254, ptr %17, align 8, !tbaa !5
  store i8 %252, ptr %253, align 1, !tbaa !9
  br label %255

255:                                              ; preds = %251, %248
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #3
  %256 = load ptr, ptr %17, align 8, !tbaa !5
  %257 = load ptr, ptr %15, align 8, !tbaa !5
  %258 = call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %257, i64 noundef 0)
  %259 = ptrtoint ptr %256 to i64
  %260 = ptrtoint ptr %258 to i64
  %261 = sub i64 %259, %260
  store i64 %261, ptr %22, align 8, !tbaa !14
  %262 = load i64, ptr %22, align 8, !tbaa !14
  %263 = load ptr, ptr %16, align 8, !tbaa !5
  store i64 %262, ptr %263, align 8, !tbaa !14
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  ret void
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32)) #1 align 2

; Function Attrs: mustprogress uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) #0 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #2

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) #1 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #2

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!7, !7, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"bool", !7, i64 0}
!12 = !{i8 0, i8 2}
!13 = !{}
!14 = !{!15, !15, i64 0}
!15 = !{!"long", !7, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN8graphlab13escape_stringERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEcbcbbRS5_Rm(ptr noundef nonnull align 8 dereferenceable(32) %0, i8 noundef signext %1, i1 noundef zeroext %2, i8 noundef signext %3, i1 noundef zeroext %4, i1 noundef zeroext %5, ptr noundef nonnull align 8 dereferenceable(32) %6, ptr nocapture noundef nonnull writeonly align 8 dereferenceable(8) %7) local_unnamed_addr #0 {
  %9 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %6) #2
  %10 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %11 = shl i64 %10, 1
  %12 = add i64 %11, 2
  %13 = icmp ult i64 %9, %12
  br i1 %13, label %14, label %18

14:                                               ; preds = %8
  %15 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %16 = shl i64 %15, 1
  %17 = add i64 %16, 2
  tail call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(32) %6, i64 noundef %17)
  br label %18

18:                                               ; preds = %14, %8
  %19 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %6, i64 noundef 0)
  br i1 %4, label %20, label %22

20:                                               ; preds = %18
  %21 = getelementptr inbounds i8, ptr %19, i64 1
  store i8 %3, ptr %19, align 1, !tbaa !5
  br label %22

22:                                               ; preds = %20, %18
  %.0 = phi ptr [ %21, %20 ], [ %19, %18 ]
  %23 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %.not117 = icmp eq i64 %23, 0
  br i1 %2, label %.preheader, label %.preheader102

.preheader102:                                    ; preds = %22
  br i1 %.not117, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader102
  br i1 %5, label %.lr.ph.split.us, label %.lr.ph.split.split

.lr.ph.split.us:                                  ; preds = %.lr.ph
  %24 = icmp eq i8 %3, 39
  br i1 %24, label %.lr.ph.split.us.split.us, label %.lr.ph.split.us.split

.lr.ph.split.us.split.us:                         ; preds = %.lr.ph.split.us, %33
  %.3105.us.us = phi ptr [ %.4.us.us, %33 ], [ %.0, %.lr.ph.split.us ]
  %.0101104.us.us = phi i64 [ %34, %33 ], [ 0, %.lr.ph.split.us ]
  %25 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %0, i64 noundef %.0101104.us.us) #2
  %26 = load i8, ptr %25, align 1, !tbaa !5
  %27 = getelementptr inbounds i8, ptr %.3105.us.us, i64 1
  switch i8 %26, label %32 [
    i8 39, label %30
    i8 34, label %28
  ]

28:                                               ; preds = %.lr.ph.split.us.split.us
  store i8 34, ptr %.3105.us.us, align 1, !tbaa !5
  %29 = getelementptr inbounds i8, ptr %.3105.us.us, i64 2
  store i8 34, ptr %27, align 1, !tbaa !5
  br label %33

30:                                               ; preds = %.lr.ph.split.us.split.us
  store i8 39, ptr %.3105.us.us, align 1, !tbaa !5
  %31 = getelementptr inbounds i8, ptr %.3105.us.us, i64 2
  store i8 39, ptr %27, align 1, !tbaa !5
  br label %33

32:                                               ; preds = %.lr.ph.split.us.split.us
  store i8 %26, ptr %.3105.us.us, align 1, !tbaa !5
  br label %33

33:                                               ; preds = %32, %30, %28
  %.4.us.us = phi ptr [ %27, %32 ], [ %29, %28 ], [ %31, %30 ]
  %34 = add nuw i64 %.0101104.us.us, 1
  %35 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %36 = icmp ult i64 %34, %35
  br i1 %36, label %.lr.ph.split.us.split.us, label %.loopexit, !llvm.loop !8

.lr.ph.split.us.split:                            ; preds = %.lr.ph.split.us, %44
  %.3105.us = phi ptr [ %.4.us, %44 ], [ %.0, %.lr.ph.split.us ]
  %.0101104.us = phi i64 [ %45, %44 ], [ 0, %.lr.ph.split.us ]
  %37 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %0, i64 noundef %.0101104.us) #2
  %38 = load i8, ptr %37, align 1, !tbaa !5
  %39 = getelementptr inbounds i8, ptr %.3105.us, i64 1
  switch i8 %38, label %43 [
    i8 39, label %42
    i8 34, label %40
  ]

40:                                               ; preds = %.lr.ph.split.us.split
  store i8 34, ptr %.3105.us, align 1, !tbaa !5
  %41 = getelementptr inbounds i8, ptr %.3105.us, i64 2
  store i8 34, ptr %39, align 1, !tbaa !5
  br label %44

42:                                               ; preds = %.lr.ph.split.us.split
  store i8 39, ptr %.3105.us, align 1, !tbaa !5
  br label %44

43:                                               ; preds = %.lr.ph.split.us.split
  store i8 %38, ptr %.3105.us, align 1, !tbaa !5
  br label %44

44:                                               ; preds = %43, %42, %40
  %.4.us = phi ptr [ %39, %43 ], [ %41, %40 ], [ %39, %42 ]
  %45 = add nuw i64 %.0101104.us, 1
  %46 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %47 = icmp ult i64 %45, %46
  br i1 %47, label %.lr.ph.split.us.split, label %.loopexit, !llvm.loop !8

.preheader:                                       ; preds = %22
  br i1 %.not117, label %.loopexit, label %.lr.ph115

.lr.ph115:                                        ; preds = %.preheader
  %48 = icmp eq i8 %3, 34
  %or.cond8 = and i1 %48, %5
  %or.cond11 = and i1 %48, %4
  %49 = icmp eq i8 %3, 39
  %or.cond = and i1 %49, %5
  %or.cond5 = and i1 %49, %4
  br label %50

50:                                               ; preds = %.lr.ph115, %104
  %.1114 = phi ptr [ %.0, %.lr.ph115 ], [ %.2, %104 ]
  %.0100112 = phi i64 [ 0, %.lr.ph115 ], [ %105, %104 ]
  %51 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %0, i64 noundef %.0100112) #2
  %52 = load i8, ptr %51, align 1, !tbaa !5
  switch i8 %52, label %102 [
    i8 39, label %53
    i8 34, label %61
    i8 92, label %69
    i8 9, label %87
    i8 8, label %90
    i8 13, label %93
    i8 10, label %96
    i8 0, label %99
  ]

53:                                               ; preds = %50
  %54 = getelementptr inbounds i8, ptr %.1114, i64 1
  br i1 %or.cond, label %55, label %57

55:                                               ; preds = %53
  store i8 39, ptr %.1114, align 1, !tbaa !5
  %56 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 39, ptr %54, align 1, !tbaa !5
  br label %104

57:                                               ; preds = %53
  br i1 %or.cond5, label %58, label %60

58:                                               ; preds = %57
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %59 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 39, ptr %54, align 1, !tbaa !5
  br label %104

60:                                               ; preds = %57
  store i8 39, ptr %.1114, align 1, !tbaa !5
  br label %104

61:                                               ; preds = %50
  %62 = getelementptr inbounds i8, ptr %.1114, i64 1
  br i1 %or.cond8, label %63, label %65

63:                                               ; preds = %61
  store i8 34, ptr %.1114, align 1, !tbaa !5
  %64 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 34, ptr %62, align 1, !tbaa !5
  br label %104

65:                                               ; preds = %61
  br i1 %or.cond11, label %66, label %68

66:                                               ; preds = %65
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %67 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 34, ptr %62, align 1, !tbaa !5
  br label %104

68:                                               ; preds = %65
  store i8 34, ptr %.1114, align 1, !tbaa !5
  br label %104

69:                                               ; preds = %50
  %70 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %71 = add i64 %70, -1
  %72 = icmp ult i64 %.0100112, %71
  br i1 %72, label %73, label %84

73:                                               ; preds = %69
  %74 = add nuw i64 %.0100112, 1
  %75 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %0, i64 noundef %74) #2
  %76 = load i8, ptr %75, align 1, !tbaa !5
  %77 = icmp eq i8 %76, 117
  br i1 %77, label %82, label %78

78:                                               ; preds = %73
  %79 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %0, i64 noundef %74) #2
  %80 = load i8, ptr %79, align 1, !tbaa !5
  %81 = icmp eq i8 %80, 120
  br i1 %81, label %82, label %84

82:                                               ; preds = %78, %73
  %83 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 92, ptr %.1114, align 1, !tbaa !5
  br label %104

84:                                               ; preds = %78, %69
  %85 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %86 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 92, ptr %85, align 1, !tbaa !5
  br label %104

87:                                               ; preds = %50
  %88 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %89 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 116, ptr %88, align 1, !tbaa !5
  br label %104

90:                                               ; preds = %50
  %91 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %92 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 98, ptr %91, align 1, !tbaa !5
  br label %104

93:                                               ; preds = %50
  %94 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %95 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 114, ptr %94, align 1, !tbaa !5
  br label %104

96:                                               ; preds = %50
  %97 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %98 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 110, ptr %97, align 1, !tbaa !5
  br label %104

99:                                               ; preds = %50
  %100 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %1, ptr %.1114, align 1, !tbaa !5
  %101 = getelementptr inbounds i8, ptr %.1114, i64 2
  store i8 0, ptr %100, align 1, !tbaa !5
  br label %104

102:                                              ; preds = %50
  %103 = getelementptr inbounds i8, ptr %.1114, i64 1
  store i8 %52, ptr %.1114, align 1, !tbaa !5
  br label %104

104:                                              ; preds = %82, %84, %63, %68, %66, %55, %60, %58, %102, %99, %96, %93, %90, %87
  %.2 = phi ptr [ %103, %102 ], [ %101, %99 ], [ %98, %96 ], [ %95, %93 ], [ %92, %90 ], [ %89, %87 ], [ %83, %82 ], [ %86, %84 ], [ %64, %63 ], [ %67, %66 ], [ %62, %68 ], [ %56, %55 ], [ %59, %58 ], [ %54, %60 ]
  %105 = add nuw i64 %.0100112, 1
  %106 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %107 = icmp ult i64 %105, %106
  br i1 %107, label %50, label %.loopexit, !llvm.loop !10

.lr.ph.split.split:                               ; preds = %.lr.ph, %.lr.ph.split.split
  %.3105 = phi ptr [ %.4, %.lr.ph.split.split ], [ %.0, %.lr.ph ]
  %.0101104 = phi i64 [ %110, %.lr.ph.split.split ], [ 0, %.lr.ph ]
  %108 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %0, i64 noundef %.0101104) #2
  %109 = load i8, ptr %108, align 1, !tbaa !5
  store i8 %109, ptr %.3105, align 1, !tbaa !5
  %.4 = getelementptr inbounds i8, ptr %.3105, i64 1
  %110 = add nuw i64 %.0101104, 1
  %111 = tail call noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32) %0) #2
  %112 = icmp ult i64 %110, %111
  br i1 %112, label %.lr.ph.split.split, label %.loopexit, !llvm.loop !8

.loopexit:                                        ; preds = %.lr.ph.split.split, %44, %33, %104, %.preheader102, %.preheader
  %.5 = phi ptr [ %.0, %.preheader ], [ %.0, %.preheader102 ], [ %.2, %104 ], [ %.4.us.us, %33 ], [ %.4.us, %44 ], [ %.4, %.lr.ph.split.split ]
  br i1 %4, label %113, label %115

113:                                              ; preds = %.loopexit
  %114 = getelementptr inbounds i8, ptr %.5, i64 1
  store i8 %3, ptr %.5, align 1, !tbaa !5
  br label %115

115:                                              ; preds = %113, %.loopexit
  %.6 = phi ptr [ %114, %113 ], [ %.5, %.loopexit ]
  %116 = tail call noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32) %6, i64 noundef 0)
  %117 = ptrtoint ptr %.6 to i64
  %118 = ptrtoint ptr %116 to i64
  %119 = sub i64 %117, %118
  store i64 %119, ptr %7, align 8, !tbaa !11
  ret void
}

; Function Attrs: mustprogress nounwind uwtable
declare noundef i64 @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 1 dereferenceable(1) ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEixEm(ptr noundef nonnull align 8 dereferenceable(32), i64 noundef) local_unnamed_addr #1 align 2

attributes #0 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = distinct !{!8, !9}
!9 = !{!"llvm.loop.mustprogress"}
!10 = distinct !{!10, !9}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !6, i64 0}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass