; LLVM IR from ASDAlexander77/TypeScriptCompiler :: tsc/tsc-new-parser (parenthesizer_rules)

; 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"

%struct.ptr.17 = type { %"class.std::shared_ptr.18" }
%"class.std::shared_ptr.18" = type { %"class.std::__shared_ptr.19" }
%"class.std::__shared_ptr.19" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%struct.ptr.35 = type { %"class.std::shared_ptr.36" }
%"class.std::shared_ptr.36" = type { %"class.std::__shared_ptr.37" }
%"class.std::__shared_ptr.37" = type { ptr, %"class.std::__shared_count" }
%struct.ptr.39 = type { %"class.std::shared_ptr.40" }
%"class.std::shared_ptr.40" = type { %"class.std::__shared_ptr.41" }
%"class.std::__shared_ptr.41" = type { ptr, %"class.std::__shared_count" }
%struct.ptr = type { %"class.std::shared_ptr" }
%"class.std::shared_ptr" = type { %"class.std::__shared_ptr" }
%"class.std::__shared_ptr" = type { ptr, %"class.std::__shared_count" }
%struct.ptr.43 = type { %"class.std::shared_ptr.44" }
%"class.std::shared_ptr.44" = type { %"class.std::__shared_ptr.45" }
%"class.std::__shared_ptr.45" = type { ptr, %"class.std::__shared_count" }
%struct.ptr.31 = type { %"class.std::shared_ptr.32" }
%"class.std::shared_ptr.32" = type { %"class.std::__shared_ptr.33" }
%"class.std::__shared_ptr.33" = type { ptr, %"class.std::__shared_count" }
%"struct.ts::ParenthesizerRules" = type { ptr }
%"struct.ts::data::NewExpression" = type { %"struct.ts::data::Declaration", %struct.ptr.39, %"struct.ts::data::NodeArray.71", %"struct.ts::data::NodeArray" }
%"struct.ts::data::Declaration" = type { %"struct.ts::data::DeclarationStatement", %struct.ptr.79, %struct.ptr.79 }
%"struct.ts::data::DeclarationStatement" = type { %"struct.ts::data::Statement" }
%"struct.ts::data::Statement" = type { %"struct.ts::data::PrimaryExpression" }
%"struct.ts::data::PrimaryExpression" = type { %"struct.ts::data::MemberExpression" }
%"struct.ts::data::MemberExpression" = type { %"struct.ts::data::LeftHandSideExpression" }
%"struct.ts::data::LeftHandSideExpression" = type { %"struct.ts::data::UpdateExpression" }
%"struct.ts::data::UpdateExpression" = type { %"struct.ts::data::UnaryExpression" }
%"struct.ts::data::UnaryExpression" = type { %"struct.ts::data::ExpressionWithTypeArguments" }
%"struct.ts::data::ExpressionWithTypeArguments" = type { %"struct.ts::data::NodeWithTypeArguments", %struct.ptr.39 }
%"struct.ts::data::NodeWithTypeArguments" = type { %"struct.ts::data::Expression", %"struct.ts::data::NodeArray.71" }
%"struct.ts::data::Expression" = type { %"struct.ts::data::TypeNode" }
%"struct.ts::data::TypeNode" = type { %"struct.ts::data::JSDocContainer" }
%"struct.ts::data::JSDocContainer" = type { %"struct.ts::data::Node.base", [3 x i8], %"struct.ts::data::NodeArray.55", %"struct.ts::data::NodeArray.63" }
%"struct.ts::data::Node.base" = type <{ ptr, %"struct.ts::data::TextRange", i32, i32, i32, i32, [4 x i8], %"struct.ts::data::NodeArray.47", i32, [4 x i8], %struct.ptr.35, %struct.ptr.35, i32, i8 }>
%"struct.ts::data::TextRange" = type { %"struct.ts::pos_type", i32 }
%"struct.ts::pos_type" = type { i32, i32 }
%"struct.ts::data::NodeArray.47" = type <{ %"struct.ts::data::ReadonlyArray.48", %"struct.ts::data::TextRange", i8, i8, i8, i8, i32, [4 x i8] }>
%"struct.ts::data::ReadonlyArray.48" = type { %"class.std::vector.49" }
%"class.std::vector.49" = type { %"struct.std::_Vector_base.50" }
%"struct.std::_Vector_base.50" = type { %"struct.std::_Vector_base<ptr<ts::data::Node>, std::allocator<ptr<ts::data::Node>>>::_Vector_impl" }
%"struct.std::_Vector_base<ptr<ts::data::Node>, std::allocator<ptr<ts::data::Node>>>::_Vector_impl" = type { %"struct.std::_Vector_base<ptr<ts::data::Node>, std::allocator<ptr<ts::data::Node>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<ptr<ts::data::Node>, std::allocator<ptr<ts::data::Node>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.ts::data::NodeArray.55" = type <{ %"struct.ts::data::ReadonlyArray.56", %"struct.ts::data::TextRange", i8, i8, i8, i8, i32, [4 x i8] }>
%"struct.ts::data::ReadonlyArray.56" = type { %"class.std::vector.57" }
%"class.std::vector.57" = type { %"struct.std::_Vector_base.58" }
%"struct.std::_Vector_base.58" = type { %"struct.std::_Vector_base<ptr<ts::data::JSDoc>, std::allocator<ptr<ts::data::JSDoc>>>::_Vector_impl" }
%"struct.std::_Vector_base<ptr<ts::data::JSDoc>, std::allocator<ptr<ts::data::JSDoc>>>::_Vector_impl" = type { %"struct.std::_Vector_base<ptr<ts::data::JSDoc>, std::allocator<ptr<ts::data::JSDoc>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<ptr<ts::data::JSDoc>, std::allocator<ptr<ts::data::JSDoc>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.ts::data::NodeArray.63" = type <{ %"struct.ts::data::ReadonlyArray.64", %"struct.ts::data::TextRange", i8, i8, i8, i8, i32, [4 x i8] }>
%"struct.ts::data::ReadonlyArray.64" = type { %"class.std::vector.65" }
%"class.std::vector.65" = type { %"struct.std::_Vector_base.66" }
%"struct.std::_Vector_base.66" = type { %"struct.std::_Vector_base<ptr<ts::data::JSDocTag>, std::allocator<ptr<ts::data::JSDocTag>>>::_Vector_impl" }
%"struct.std::_Vector_base<ptr<ts::data::JSDocTag>, std::allocator<ptr<ts::data::JSDocTag>>>::_Vector_impl" = type { %"struct.std::_Vector_base<ptr<ts::data::JSDocTag>, std::allocator<ptr<ts::data::JSDocTag>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<ptr<ts::data::JSDocTag>, std::allocator<ptr<ts::data::JSDocTag>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%struct.ptr.79 = type { %"class.std::shared_ptr.80" }
%"class.std::shared_ptr.80" = type { %"class.std::__shared_ptr.81" }
%"class.std::__shared_ptr.81" = type { ptr, %"class.std::__shared_count" }
%"struct.ts::data::NodeArray.71" = type <{ %"struct.ts::data::ReadonlyArray.72", %"struct.ts::data::TextRange", i8, i8, i8, i8, i32, [4 x i8] }>
%"struct.ts::data::ReadonlyArray.72" = type { %"class.std::vector.73" }
%"class.std::vector.73" = type { %"struct.std::_Vector_base.74" }
%"struct.std::_Vector_base.74" = type { %"struct.std::_Vector_base<ptr<ts::data::TypeNode>, std::allocator<ptr<ts::data::TypeNode>>>::_Vector_impl" }
%"struct.std::_Vector_base<ptr<ts::data::TypeNode>, std::allocator<ptr<ts::data::TypeNode>>>::_Vector_impl" = type { %"struct.std::_Vector_base<ptr<ts::data::TypeNode>, std::allocator<ptr<ts::data::TypeNode>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<ptr<ts::data::TypeNode>, std::allocator<ptr<ts::data::TypeNode>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.ts::data::NodeArray" = type <{ %"struct.ts::data::ReadonlyArray", %"struct.ts::data::TextRange", i8, i8, i8, i8, i32, [4 x i8] }>
%"struct.ts::data::ReadonlyArray" = type { %"class.std::vector.21" }
%"class.std::vector.21" = type { %"struct.std::_Vector_base.22" }
%"struct.std::_Vector_base.22" = type { %"struct.std::_Vector_base<ptr<ts::data::Expression>, std::allocator<ptr<ts::data::Expression>>>::_Vector_impl" }
%"struct.std::_Vector_base<ptr<ts::data::Expression>, std::allocator<ptr<ts::data::Expression>>>::_Vector_impl" = type { %"struct.std::_Vector_base<ptr<ts::data::Expression>, std::allocator<ptr<ts::data::Expression>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<ptr<ts::data::Expression>, std::allocator<ptr<ts::data::Expression>>>::_Vector_impl_data" = type { ptr, ptr, ptr }

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

declare i32 @__gxx_personality_v0(...)

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

declare noundef zeroext i1 @_ZN2ts11NodeFactory20NoParenthesizerRulesEv(ptr noundef nonnull align 8 dereferenceable(232)) #1

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2 align 2

declare void @_ZN2ts11NodeFactory29createParenthesizedExpressionE3ptrINS_4data10ExpressionEE(ptr dead_on_unwind writable sret(%struct.ptr.17) align 8, ptr noundef nonnull align 8 dereferenceable(232), ptr noundef) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data9TextRangeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN2ts31skipPartiallyEmittedExpressionsE3ptrINS_4data4NodeEE(ptr dead_on_unwind noalias writable sret(%struct.ptr.35) align 8, ptr noundef) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data9TextRangeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN2ts18ParenthesizerRules28parenthesizeLeftSideOfAccessE3ptrINS_4data10ExpressionEEb(ptr dead_on_unwind noalias writable sret(%struct.ptr.39) align 8 %0, ptr noundef nonnull align 8 dereferenceable(8) %1, ptr noundef %2, i1 noundef zeroext %3) #5 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i8, align 1
  %9 = alloca %struct.ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca %struct.ptr.35, align 8
  %13 = alloca %struct.ptr.35, align 8
  %14 = alloca %struct.ptr, align 8
  %15 = alloca %struct.ptr.35, align 8
  %16 = alloca %struct.ptr.43, align 8
  %17 = alloca i1, align 1
  %18 = alloca i1, align 1
  %19 = alloca %struct.ptr.35, align 8
  %20 = alloca i1, align 1
  %21 = alloca i32, align 4
  %22 = alloca %struct.ptr.17, align 8
  %23 = alloca %struct.ptr.17, align 8
  %24 = alloca %struct.ptr, align 8
  %25 = alloca %struct.ptr.31, align 8
  %26 = alloca %struct.ptr, align 8
  store ptr %0, ptr %5, align 8
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %27 = zext i1 %3 to i8
  store i8 %27, ptr %8, align 1, !tbaa !9
  %28 = load ptr, ptr %6, align 8
  %29 = getelementptr inbounds %"struct.ts::ParenthesizerRules", ptr %28, i32 0, i32 0
  %30 = load ptr, ptr %29, align 8, !tbaa !11
  %31 = call noundef zeroext i1 @_ZN2ts11NodeFactory20NoParenthesizerRulesEv(ptr noundef nonnull align 8 dereferenceable(232) %30)
  br i1 %31, label %32, label %38

32:                                               ; preds = %4
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  invoke void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef %9)
          to label %33 unwind label %34

33:                                               ; preds = %32
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br label %145

34:                                               ; preds = %32
  %35 = landingpad { ptr, i32 }
          cleanup
  %36 = extractvalue { ptr, i32 } %35, 0
  store ptr %36, ptr %10, align 8
  %37 = extractvalue { ptr, i32 } %35, 1
  store i32 %37, ptr %11, align 4
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br label %146

38:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 16, ptr %12) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  invoke void @_ZN3ptrIN2ts4data4NodeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef %14)
          to label %39 unwind label %75

39:                                               ; preds = %38
  invoke void @_ZN2ts31skipPartiallyEmittedExpressionsE3ptrINS_4data4NodeEE(ptr dead_on_unwind writable sret(%struct.ptr.35) align 8 %12, ptr noundef %13)
          to label %40 unwind label %79

40:                                               ; preds = %39
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %13) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #6
  call void @_ZN3ptrIN2ts4data4NodeEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %15, ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  store i1 false, ptr %17, align 1
  store i1 false, ptr %18, align 1
  store i1 false, ptr %20, align 1
  %41 = invoke noundef zeroext i1 @_ZN2ts24isLeftHandSideExpressionE3ptrINS_4data4NodeEE(ptr noundef %15)
          to label %42 unwind label %84

42:                                               ; preds = %40
  br i1 %41, label %43, label %62

43:                                               ; preds = %42
  %44 = invoke noundef zeroext i1 @_ZN3ptrIN2ts4data4NodeEEneE10SyntaxKind(ptr noundef nonnull align 8 dereferenceable(16) %12, i32 noundef 214)
          to label %45 unwind label %84

45:                                               ; preds = %43
  br i1 %44, label %53, label %46

46:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 16, ptr %16) #6
  store i1 true, ptr %17, align 1
  invoke void @_ZN3ptrIN2ts4data4NodeEE2asIS_INS1_13NewExpressionEEEET_v(ptr dead_on_unwind writable sret(%struct.ptr.43) align 8 %16, ptr noundef nonnull align 8 dereferenceable(16) %12)
          to label %47 unwind label %88

47:                                               ; preds = %46
  store i1 true, ptr %18, align 1
  %48 = invoke noundef ptr @_ZN3ptrIN2ts4data13NewExpressionEEptEv(ptr noundef nonnull align 8 dereferenceable(16) %16)
          to label %49 unwind label %92

49:                                               ; preds = %47
  %50 = getelementptr inbounds %"struct.ts::data::NewExpression", ptr %48, i32 0, i32 3
  %51 = invoke noundef zeroext i1 @_ZN2ts4data9NodeArrayI3ptrINS0_10ExpressionEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(44) %50)
          to label %52 unwind label %92

52:                                               ; preds = %49
  br i1 %51, label %53, label %62

53:                                               ; preds = %52, %45
  %54 = load i8, ptr %8, align 1, !tbaa !9, !range !13, !noundef !14
  %55 = trunc i8 %54 to i1
  br i1 %55, label %60, label %56

56:                                               ; preds = %53
  call void @_ZN3ptrIN2ts4data4NodeEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %19, ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  store i1 true, ptr %20, align 1
  %57 = invoke noundef zeroext i1 @_ZN2tsL15isOptionalChainE3ptrINS_4data4NodeEE(ptr noundef %19)
          to label %58 unwind label %96

58:                                               ; preds = %56
  %59 = xor i1 %57, true
  br label %60

60:                                               ; preds = %58, %53
  %61 = phi i1 [ true, %53 ], [ %59, %58 ]
  br label %62

62:                                               ; preds = %60, %52, %42
  %63 = phi i1 [ false, %52 ], [ false, %42 ], [ %61, %60 ]
  %64 = load i1, ptr %20, align 1
  br i1 %64, label %65, label %66

65:                                               ; preds = %62
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %19) #6
  br label %66

66:                                               ; preds = %65, %62
  %67 = load i1, ptr %18, align 1
  br i1 %67, label %68, label %69

68:                                               ; preds = %66
  call void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %16) #6
  br label %69

69:                                               ; preds = %68, %66
  %70 = load i1, ptr %17, align 1
  br i1 %70, label %71, label %72

71:                                               ; preds = %69
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #6
  br label %72

72:                                               ; preds = %71, %69
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %15) #6
  br i1 %63, label %73, label %116

73:                                               ; preds = %72
  invoke void @_ZN3ptrIN2ts4data10ExpressionEE2asIS_INS1_22LeftHandSideExpressionEEEET_v(ptr dead_on_unwind writable sret(%struct.ptr.39) align 8 %0, ptr noundef nonnull align 8 dereferenceable(16) %2)
          to label %74 unwind label %112

74:                                               ; preds = %73
  store i32 1, ptr %21, align 4
  br label %142

75:                                               ; preds = %38
  %76 = landingpad { ptr, i32 }
          cleanup
  %77 = extractvalue { ptr, i32 } %76, 0
  store ptr %77, ptr %10, align 8
  %78 = extractvalue { ptr, i32 } %76, 1
  store i32 %78, ptr %11, align 4
  br label %83

79:                                               ; preds = %39
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %10, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %11, align 4
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %13) #6
  br label %83

83:                                               ; preds = %79, %75
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #6
  br label %144

84:                                               ; preds = %43, %40
  %85 = landingpad { ptr, i32 }
          cleanup
  %86 = extractvalue { ptr, i32 } %85, 0
  store ptr %86, ptr %10, align 8
  %87 = extractvalue { ptr, i32 } %85, 1
  store i32 %87, ptr %11, align 4
  br label %111

88:                                               ; preds = %46
  %89 = landingpad { ptr, i32 }
          cleanup
  %90 = extractvalue { ptr, i32 } %89, 0
  store ptr %90, ptr %10, align 8
  %91 = extractvalue { ptr, i32 } %89, 1
  store i32 %91, ptr %11, align 4
  br label %107

92:                                               ; preds = %49, %47
  %93 = landingpad { ptr, i32 }
          cleanup
  %94 = extractvalue { ptr, i32 } %93, 0
  store ptr %94, ptr %10, align 8
  %95 = extractvalue { ptr, i32 } %93, 1
  store i32 %95, ptr %11, align 4
  br label %103

96:                                               ; preds = %56
  %97 = landingpad { ptr, i32 }
          cleanup
  %98 = extractvalue { ptr, i32 } %97, 0
  store ptr %98, ptr %10, align 8
  %99 = extractvalue { ptr, i32 } %97, 1
  store i32 %99, ptr %11, align 4
  %100 = load i1, ptr %20, align 1
  br i1 %100, label %101, label %102

101:                                              ; preds = %96
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %19) #6
  br label %102

102:                                              ; preds = %101, %96
  br label %103

103:                                              ; preds = %102, %92
  %104 = load i1, ptr %18, align 1
  br i1 %104, label %105, label %106

105:                                              ; preds = %103
  call void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %16) #6
  br label %106

106:                                              ; preds = %105, %103
  br label %107

107:                                              ; preds = %106, %88
  %108 = load i1, ptr %17, align 1
  br i1 %108, label %109, label %110

109:                                              ; preds = %107
  call void @llvm.lifetime.end.p0(i64 16, ptr %16) #6
  br label %110

110:                                              ; preds = %109, %107
  br label %111

111:                                              ; preds = %110, %84
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %15) #6
  br label %143

112:                                              ; preds = %73
  %113 = landingpad { ptr, i32 }
          cleanup
  %114 = extractvalue { ptr, i32 } %113, 0
  store ptr %114, ptr %10, align 8
  %115 = extractvalue { ptr, i32 } %113, 1
  store i32 %115, ptr %11, align 4
  br label %143

116:                                              ; preds = %72
  %117 = getelementptr inbounds %"struct.ts::ParenthesizerRules", ptr %28, i32 0, i32 0
  %118 = load ptr, ptr %117, align 8, !tbaa !11
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %24, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  invoke void @_ZN2ts11NodeFactory29createParenthesizedExpressionE3ptrINS_4data10ExpressionEE(ptr dead_on_unwind writable sret(%struct.ptr.17) align 8 %23, ptr noundef nonnull align 8 dereferenceable(232) %118, ptr noundef %24)
          to label %119 unwind label %123

119:                                              ; preds = %116
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %26, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  invoke void @_ZN3ptrIN2ts4data9TextRangeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %25, ptr noundef %26)
          to label %120 unwind label %127

120:                                              ; preds = %119
  invoke void @_ZN2ts12setTextRangeI3ptrINS_4data23ParenthesizedExpressionEEEET_S5_S1_INS2_9TextRangeEE(ptr dead_on_unwind writable sret(%struct.ptr.17) align 8 %22, ptr noundef %23, ptr noundef %25)
          to label %121 unwind label %131

121:                                              ; preds = %120
  invoke void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_23ParenthesizedExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef %22)
          to label %122 unwind label %135

122:                                              ; preds = %121
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %22) #6
  call void @_ZN3ptrIN2ts4data9TextRangeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %25) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %26) #6
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %23) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %24) #6
  store i32 1, ptr %21, align 4
  br label %142

123:                                              ; preds = %116
  %124 = landingpad { ptr, i32 }
          cleanup
  %125 = extractvalue { ptr, i32 } %124, 0
  store ptr %125, ptr %10, align 8
  %126 = extractvalue { ptr, i32 } %124, 1
  store i32 %126, ptr %11, align 4
  br label %141

127:                                              ; preds = %119
  %128 = landingpad { ptr, i32 }
          cleanup
  %129 = extractvalue { ptr, i32 } %128, 0
  store ptr %129, ptr %10, align 8
  %130 = extractvalue { ptr, i32 } %128, 1
  store i32 %130, ptr %11, align 4
  br label %140

131:                                              ; preds = %120
  %132 = landingpad { ptr, i32 }
          cleanup
  %133 = extractvalue { ptr, i32 } %132, 0
  store ptr %133, ptr %10, align 8
  %134 = extractvalue { ptr, i32 } %132, 1
  store i32 %134, ptr %11, align 4
  br label %139

135:                                              ; preds = %121
  %136 = landingpad { ptr, i32 }
          cleanup
  %137 = extractvalue { ptr, i32 } %136, 0
  store ptr %137, ptr %10, align 8
  %138 = extractvalue { ptr, i32 } %136, 1
  store i32 %138, ptr %11, align 4
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %22) #6
  br label %139

139:                                              ; preds = %135, %131
  call void @_ZN3ptrIN2ts4data9TextRangeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %25) #6
  br label %140

140:                                              ; preds = %139, %127
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %26) #6
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %23) #6
  br label %141

141:                                              ; preds = %140, %123
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %24) #6
  br label %143

142:                                              ; preds = %122, %74
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #6
  br label %145

143:                                              ; preds = %141, %112, %111
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  br label %144

144:                                              ; preds = %143, %83
  call void @llvm.lifetime.end.p0(i64 16, ptr %12) #6
  br label %146

145:                                              ; preds = %142, %33
  ret void

146:                                              ; preds = %144, %34
  %147 = load ptr, ptr %10, align 8
  %148 = load i32, ptr %11, align 4
  %149 = insertvalue { ptr, i32 } poison, ptr %147, 0
  %150 = insertvalue { ptr, i32 } %149, i32 %148, 1
  resume { ptr, i32 } %150
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN2ts24isLeftHandSideExpressionE3ptrINS_4data4NodeEE(ptr noundef) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN3ptrIN2ts4data4NodeEEneE10SyntaxKind(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEE2asIS_INS1_13NewExpressionEEEET_v(ptr dead_on_unwind noalias writable sret(%struct.ptr.43) align 8, ptr noundef nonnull align 8 dereferenceable(16)) #4 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZN3ptrIN2ts4data13NewExpressionEEptEv(ptr noundef nonnull align 8 dereferenceable(16)) #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN2ts4data9NodeArrayI3ptrINS0_10ExpressionEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(44)) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare hidden noundef zeroext i1 @_ZN2tsL15isOptionalChainE3ptrINS_4data4NodeEE(ptr noundef) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3ptrIN2ts4data10ExpressionEE2asIS_INS1_22LeftHandSideExpressionEEEET_v(ptr dead_on_unwind noalias writable sret(%struct.ptr.39) align 8, ptr noundef nonnull align 8 dereferenceable(16)) #4 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN2ts12setTextRangeI3ptrINS_4data23ParenthesizedExpressionEEEET_S5_S1_INS2_9TextRangeEE(ptr dead_on_unwind noalias writable sret(%struct.ptr.17) align 8, ptr noundef, ptr noundef) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_23ParenthesizedExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { inlinehint 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 #3 = { 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 #4 = { inlinehint 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 #5 = { 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 #6 = { 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 = !{!10, !10, i64 0}
!10 = !{!"bool", !7, i64 0}
!11 = !{!12, !6, i64 0}
!12 = !{!"_ZTSN2ts18ParenthesizerRulesE", !6, i64 0}
!13 = !{i8 0, i8 2}
!14 = !{}


; 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"

%struct.ptr.17 = type { %"class.std::shared_ptr.18" }
%"class.std::shared_ptr.18" = type { %"class.std::__shared_ptr.19" }
%"class.std::__shared_ptr.19" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%struct.ptr.35 = type { %"class.std::shared_ptr.36" }
%"class.std::shared_ptr.36" = type { %"class.std::__shared_ptr.37" }
%"class.std::__shared_ptr.37" = type { ptr, %"class.std::__shared_count" }
%struct.ptr.39 = type { %"class.std::shared_ptr.40" }
%"class.std::shared_ptr.40" = type { %"class.std::__shared_ptr.41" }
%"class.std::__shared_ptr.41" = type { ptr, %"class.std::__shared_count" }
%struct.ptr = type { %"class.std::shared_ptr" }
%"class.std::shared_ptr" = type { %"class.std::__shared_ptr" }
%"class.std::__shared_ptr" = type { ptr, %"class.std::__shared_count" }
%struct.ptr.43 = type { %"class.std::shared_ptr.44" }
%"class.std::shared_ptr.44" = type { %"class.std::__shared_ptr.45" }
%"class.std::__shared_ptr.45" = type { ptr, %"class.std::__shared_count" }
%struct.ptr.31 = type { %"class.std::shared_ptr.32" }
%"class.std::shared_ptr.32" = type { %"class.std::__shared_ptr.33" }
%"class.std::__shared_ptr.33" = type { ptr, %"class.std::__shared_count" }

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

declare i32 @__gxx_personality_v0(...)

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

declare noundef zeroext i1 @_ZN2ts11NodeFactory20NoParenthesizerRulesEv(ptr noundef nonnull align 8 dereferenceable(232)) local_unnamed_addr #1

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2 align 2

declare void @_ZN2ts11NodeFactory29createParenthesizedExpressionE3ptrINS_4data10ExpressionEE(ptr dead_on_unwind writable sret(%struct.ptr.17) align 8, ptr noundef nonnull align 8 dereferenceable(232), ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data9TextRangeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN2ts31skipPartiallyEmittedExpressionsE3ptrINS_4data4NodeEE(ptr dead_on_unwind noalias writable sret(%struct.ptr.35) align 8, ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data9TextRangeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN2ts18ParenthesizerRules28parenthesizeLeftSideOfAccessE3ptrINS_4data10ExpressionEEb(ptr dead_on_unwind noalias writable sret(%struct.ptr.39) align 8 %0, ptr nocapture noundef nonnull readonly align 8 dereferenceable(8) %1, ptr noundef %2, i1 noundef zeroext %3) local_unnamed_addr #5 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca %struct.ptr, align 8
  %6 = alloca %struct.ptr.35, align 8
  %7 = alloca %struct.ptr.35, align 8
  %8 = alloca %struct.ptr, align 8
  %9 = alloca %struct.ptr.35, align 8
  %10 = alloca %struct.ptr.43, align 8
  %11 = alloca %struct.ptr.35, align 8
  %12 = alloca %struct.ptr.17, align 8
  %13 = alloca %struct.ptr.17, align 8
  %14 = alloca %struct.ptr, align 8
  %15 = alloca %struct.ptr.31, align 8
  %16 = alloca %struct.ptr, align 8
  %17 = load ptr, ptr %1, align 8, !tbaa !5
  %18 = tail call noundef zeroext i1 @_ZN2ts11NodeFactory20NoParenthesizerRulesEv(ptr noundef nonnull align 8 dereferenceable(232) %17)
  br i1 %18, label %19, label %20

19:                                               ; preds = %4
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  call void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef nonnull %5)
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %5) #6
  br label %61

20:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  call void @_ZN3ptrIN2ts4data4NodeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %7, ptr noundef nonnull %8)
  invoke void @_ZN2ts31skipPartiallyEmittedExpressionsE3ptrINS_4data4NodeEE(ptr dead_on_unwind nonnull writable sret(%struct.ptr.35) align 8 %6, ptr noundef nonnull %7)
          to label %21 unwind label %36

21:                                               ; preds = %20
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %8) #6
  call void @_ZN3ptrIN2ts4data4NodeEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %9, ptr noundef nonnull align 8 dereferenceable(16) %6) #6
  %22 = invoke noundef zeroext i1 @_ZN2ts24isLeftHandSideExpressionE3ptrINS_4data4NodeEE(ptr noundef nonnull %9)
          to label %23 unwind label %38

23:                                               ; preds = %21
  br i1 %22, label %24, label %.sink.split45

24:                                               ; preds = %23
  %25 = call noundef zeroext i1 @_ZN3ptrIN2ts4data4NodeEEneE10SyntaxKind(ptr noundef nonnull align 8 dereferenceable(16) %6, i32 noundef 214)
  br i1 %25, label %31, label %26

26:                                               ; preds = %24
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %10) #6
  invoke void @_ZN3ptrIN2ts4data4NodeEE2asIS_INS1_13NewExpressionEEEET_v(ptr dead_on_unwind nonnull writable sret(%struct.ptr.43) align 8 %10, ptr noundef nonnull align 8 dereferenceable(16) %6)
          to label %27 unwind label %40

27:                                               ; preds = %26
  %28 = call noundef ptr @_ZN3ptrIN2ts4data13NewExpressionEEptEv(ptr noundef nonnull align 8 dereferenceable(16) %10)
  %29 = getelementptr inbounds i8, ptr %28, i64 392
  %30 = call noundef zeroext i1 @_ZN2ts4data9NodeArrayI3ptrINS0_10ExpressionEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(44) %29)
  br i1 %30, label %.thread43, label %.critedge42

31:                                               ; preds = %24
  br i1 %3, label %.sink.split, label %32

.thread43:                                        ; preds = %27
  br i1 %3, label %.critedge41, label %32

32:                                               ; preds = %.thread43, %31
  call void @_ZN3ptrIN2ts4data4NodeEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %11, ptr noundef nonnull align 8 dereferenceable(16) %6) #6
  %33 = invoke noundef zeroext i1 @_ZN2tsL15isOptionalChainE3ptrINS_4data4NodeEE(ptr noundef nonnull %11)
          to label %34 unwind label %42

34:                                               ; preds = %32
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %11) #6
  br i1 %25, label %.critedge, label %.thread.thread

.thread.thread:                                   ; preds = %34
  call void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %10) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #6
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br i1 %33, label %49, label %35

.critedge:                                        ; preds = %34
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br i1 %33, label %49, label %35

.critedge41:                                      ; preds = %.thread43
  call void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %10) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #6
  br label %.sink.split

.sink.split:                                      ; preds = %31, %.critedge41
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br label %35

35:                                               ; preds = %.sink.split, %.thread.thread, %.critedge
  invoke void @_ZN3ptrIN2ts4data10ExpressionEE2asIS_INS1_22LeftHandSideExpressionEEEET_v(ptr dead_on_unwind writable sret(%struct.ptr.39) align 8 %0, ptr noundef nonnull align 8 dereferenceable(16) %2)
          to label %58 unwind label %47

36:                                               ; preds = %20
  %37 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %7) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %8) #6
  br label %60

38:                                               ; preds = %21
  %39 = landingpad { ptr, i32 }
          cleanup
  br label %46

40:                                               ; preds = %26
  %41 = landingpad { ptr, i32 }
          cleanup
  br label %45

42:                                               ; preds = %32
  %43 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %11) #6
  br i1 %25, label %46, label %44

44:                                               ; preds = %42
  call void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %10) #6
  br label %45

45:                                               ; preds = %44, %40
  %.pn.ph = phi { ptr, i32 } [ %41, %40 ], [ %43, %44 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #6
  br label %46

46:                                               ; preds = %42, %45, %38
  %.pn.pn = phi { ptr, i32 } [ %.pn.ph, %45 ], [ %39, %38 ], [ %43, %42 ]
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br label %59

47:                                               ; preds = %35
  %48 = landingpad { ptr, i32 }
          cleanup
  br label %59

.critedge42:                                      ; preds = %27
  call void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %10) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #6
  br label %.sink.split45

.sink.split45:                                    ; preds = %23, %.critedge42
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %9) #6
  br label %49

49:                                               ; preds = %.sink.split45, %.thread.thread, %.critedge
  %50 = load ptr, ptr %1, align 8, !tbaa !5
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  invoke void @_ZN2ts11NodeFactory29createParenthesizedExpressionE3ptrINS_4data10ExpressionEE(ptr dead_on_unwind nonnull writable sret(%struct.ptr.17) align 8 %13, ptr noundef nonnull align 8 dereferenceable(232) %50, ptr noundef nonnull %14)
          to label %51 unwind label %53

51:                                               ; preds = %49
  call void @_ZN3ptrIN2ts4data10ExpressionEEC2ERKS3_(ptr noundef nonnull align 8 dereferenceable(16) %16, ptr noundef nonnull align 8 dereferenceable(16) %2) #6
  call void @_ZN3ptrIN2ts4data9TextRangeEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %15, ptr noundef nonnull %16)
  invoke void @_ZN2ts12setTextRangeI3ptrINS_4data23ParenthesizedExpressionEEEET_S5_S1_INS2_9TextRangeEE(ptr dead_on_unwind nonnull writable sret(%struct.ptr.17) align 8 %12, ptr noundef nonnull %13, ptr noundef nonnull %15)
          to label %52 unwind label %55

52:                                               ; preds = %51
  call void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_23ParenthesizedExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16) %0, ptr noundef nonnull %12)
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %12) #6
  call void @_ZN3ptrIN2ts4data9TextRangeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %15) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %16) #6
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %13) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #6
  br label %58

53:                                               ; preds = %49
  %54 = landingpad { ptr, i32 }
          cleanup
  br label %57

55:                                               ; preds = %51
  %56 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN3ptrIN2ts4data9TextRangeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %15) #6
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %16) #6
  call void @_ZN3ptrIN2ts4data23ParenthesizedExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %13) #6
  br label %57

57:                                               ; preds = %55, %53
  %.pn22 = phi { ptr, i32 } [ %56, %55 ], [ %54, %53 ]
  call void @_ZN3ptrIN2ts4data10ExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %14) #6
  br label %59

58:                                               ; preds = %35, %52
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %6) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #6
  br label %61

59:                                               ; preds = %57, %47, %46
  %.pn24 = phi { ptr, i32 } [ %48, %47 ], [ %.pn22, %57 ], [ %.pn.pn, %46 ]
  call void @_ZN3ptrIN2ts4data4NodeEED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %6) #6
  br label %60

60:                                               ; preds = %59, %36
  %.pn24.pn = phi { ptr, i32 } [ %.pn24, %59 ], [ %37, %36 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #6
  resume { ptr, i32 } %.pn24.pn

61:                                               ; preds = %58, %19
  ret void
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_10ExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN2ts24isLeftHandSideExpressionE3ptrINS_4data4NodeEE(ptr noundef) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN3ptrIN2ts4data4NodeEEneE10SyntaxKind(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3ptrIN2ts4data4NodeEE2asIS_INS1_13NewExpressionEEEET_v(ptr dead_on_unwind noalias writable sret(%struct.ptr.43) align 8, ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZN3ptrIN2ts4data13NewExpressionEEptEv(ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN2ts4data9NodeArrayI3ptrINS0_10ExpressionEEEcvbEv(ptr noundef nonnull align 8 dereferenceable(44)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare hidden noundef zeroext i1 @_ZN2tsL15isOptionalChainE3ptrINS_4data4NodeEE(ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data13NewExpressionEED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN3ptrIN2ts4data10ExpressionEE2asIS_INS1_22LeftHandSideExpressionEEEET_v(ptr dead_on_unwind noalias writable sret(%struct.ptr.39) align 8, ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN2ts12setTextRangeI3ptrINS_4data23ParenthesizedExpressionEEEET_S5_S1_INS2_9TextRangeEE(ptr dead_on_unwind noalias writable sret(%struct.ptr.17) align 8, ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3ptrIN2ts4data22LeftHandSideExpressionEEC2INS1_23ParenthesizedExpressionEEES_IT_E(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "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 = { inlinehint 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 #3 = { 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 #4 = { inlinehint 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 #5 = { 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 #6 = { 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, !7, i64 0}
!6 = !{!"_ZTSN2ts18ParenthesizerRulesE", !7, i64 0}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass