mono_generic_context_check_used (struct MonoGenericContext * context)
{
  struct MonoGenericInst * D.25275;
  int D.25276;
  struct MonoGenericInst * D.25277;
  int D.25278;
  int D.25279;
  int context_used;

  context_used = 0;
  D.25275 = context->class_inst;
  D.25276 = inst_check_context_used (D.25275);
  context_used = D.25276 | context_used;
  D.25277 = context->method_inst;
  D.25278 = inst_check_context_used (D.25277);
  context_used = D.25278 | context_used;
  D.25279 = context_used;
  return D.25279;
}


inst_check_context_used (struct MonoGenericInst * inst)
{
  int D.25283;
  struct MonoType * D.25284;
  int D.25285;
  <unnamed-unsigned:22> D.25286;
  int D.25287;
  int context_used;
  int i;

  context_used = 0;
  if (inst == 0B) goto <D.25281>; else goto <D.25282>;
  <D.25281>:
  D.25283 = 0;
  return D.25283;
  <D.25282>:
  i = 0;
  goto <D.24364>;
  <D.24363>:
  D.25284 = inst->type_argv[i];
  D.25285 = type_check_context_used (D.25284, 1);
  context_used = D.25285 | context_used;
  i = i + 1;
  <D.24364>:
  D.25286 = inst->type_argc;
  D.25287 = (int) D.25286;
  if (D.25287 > i) goto <D.24363>; else goto <D.24365>;
  <D.24365>:
  D.25283 = context_used;
  return D.25283;
}


type_check_context_used (struct MonoType * type, gboolean recursive)
{
  int D.25289;
  int D.25290;
  struct MonoClass * D.25291;
  struct MonoArrayType * D.25292;
  struct MonoClass * D.25293;
  struct MonoClass * D.25296;
  struct MonoClass * D.25299;
  struct MonoGenericContainer * D.25300;
  _Bool D.25301;
  long int D.25302;
  long int D.25303;
  struct MonoGenericContext * D.25306;

  D.25289 = mono_type_get_type (type);
  switch (D.25289) <default: <D.24357>, case 18: <D.24354>, case 19: <D.24350>, case 20: <D.24353>, case 21: <D.24355>, case 29: <D.24352>, case 30: <D.24351>>
  <D.24350>:
  D.25290 = 1;
  return D.25290;
  <D.24351>:
  D.25290 = 2;
  return D.25290;
  <D.24352>:
  D.25291 = mono_type_get_class (type);
  D.25290 = mono_class_check_context_used (D.25291);
  return D.25290;
  <D.24353>:
  D.25292 = mono_type_get_array_type (type);
  D.25293 = D.25292->eklass;
  D.25290 = mono_class_check_context_used (D.25293);
  return D.25290;
  <D.24354>:
  if (recursive != 0) goto <D.25294>; else goto <D.25295>;
  <D.25294>:
  D.25296 = mono_type_get_class (type);
  D.25290 = mono_class_check_context_used (D.25296);
  return D.25290;
  <D.25295>:
  D.25290 = 0;
  return D.25290;
  <D.24355>:
  if (recursive != 0) goto <D.25297>; else goto <D.25298>;
  <D.25297>:
  {
    struct MonoGenericClass * gclass;

    gclass = type->data.generic_class;
    D.25299 = gclass->container_class;
    D.25300 = D.25299->generic_container;
    D.25301 = D.25300 == 0B;
    D.25302 = (long int) D.25301;
    D.25303 = __builtin_expect (D.25302, 0);
    if (D.25303 != 0) goto <D.25304>; else goto <D.25305>;
    <D.25304>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 64, "gclass->container_class->generic_container");
    <D.25305>:
    D.25306 = &gclass->context;
    D.25290 = mono_generic_context_check_used (D.25306);
    return D.25290;
  }
  <D.25298>:
  D.25290 = 0;
  return D.25290;
  <D.24357>:
  D.25290 = 0;
  return D.25290;
}


mono_class_check_context_used (struct MonoClass * class)
{
  struct MonoType * D.25308;
  int D.25309;
  struct MonoType * D.25310;
  int D.25311;
  struct MonoGenericClass * D.25312;
  struct MonoGenericContext * D.25315;
  int D.25316;
  struct MonoGenericContainer * D.25318;
  struct MonoGenericContext * D.25321;
  int D.25322;
  int D.25323;
  int context_used;

  context_used = 0;
  D.25308 = &class->this_arg;
  D.25309 = type_check_context_used (D.25308, 0);
  context_used = D.25309 | context_used;
  D.25310 = &class->byval_arg;
  D.25311 = type_check_context_used (D.25310, 0);
  context_used = D.25311 | context_used;
  D.25312 = class->generic_class;
  if (D.25312 != 0B) goto <D.25313>; else goto <D.25314>;
  <D.25313>:
  D.25312 = class->generic_class;
  D.25315 = &D.25312->context;
  D.25316 = mono_generic_context_check_used (D.25315);
  context_used = D.25316 | context_used;
  goto <D.25317>;
  <D.25314>:
  D.25318 = class->generic_container;
  if (D.25318 != 0B) goto <D.25319>; else goto <D.25320>;
  <D.25319>:
  D.25318 = class->generic_container;
  D.25321 = &D.25318->context;
  D.25322 = mono_generic_context_check_used (D.25321);
  context_used = D.25322 | context_used;
  <D.25320>:
  <D.25317>:
  D.25323 = context_used;
  return D.25323;
}


mono_method_get_declaring_generic_method (struct MonoMethod * method)
{
  unsigned char D.25325;
  unsigned char D.25326;
  _Bool D.25327;
  long int D.25328;
  long int D.25329;
  struct MonoMethod * D.25332;
  struct MonoMethodInflated * inflated;

  D.25325 = BIT_FIELD_REF <*method, 8, 168>;
  D.25326 = D.25325 & 16;
  D.25327 = D.25326 == 0;
  D.25328 = (long int) D.25327;
  D.25329 = __builtin_expect (D.25328, 0);
  if (D.25329 != 0) goto <D.25330>; else goto <D.25331>;
  <D.25330>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 449, "method->is_inflated");
  <D.25331>:
  inflated = method;
  D.25332 = inflated->declaring;
  return D.25332;
}


mono_class_get_method_generic (struct MonoClass * klass, struct MonoMethod * method)
{
  unsigned char D.25334;
  unsigned char D.25335;
  struct MonoGenericClass * D.25339;
  unsigned char D.25344;
  struct MonoMethod * D.25347;
  struct MonoMethod * * D.25348;
  unsigned int i.0;
  unsigned int D.25350;
  struct MonoMethod * * D.25351;
  unsigned char D.25353;
  unsigned char D.25354;
  struct MonoMethod * D.25357;
  unsigned int i.1;
  unsigned int D.25360;
  struct MonoGenericContext * D.25365;
  struct MonoGenericInst * D.25366;
  struct MonoMethod * declaring;
  struct MonoMethod * m;
  int i;

  D.25334 = BIT_FIELD_REF <*method, 8, 168>;
  D.25335 = D.25334 & 16;
  if (D.25335 != 0) goto <D.25336>; else goto <D.25337>;
  <D.25336>:
  declaring = mono_method_get_declaring_generic_method (method);
  goto <D.25338>;
  <D.25337>:
  declaring = method;
  <D.25338>:
  m = 0B;
  D.25339 = klass->generic_class;
  if (D.25339 != 0B) goto <D.25340>; else goto <D.25341>;
  <D.25340>:
  m = mono_class_get_inflated_method (klass, declaring);
  <D.25341>:
  if (m == 0B) goto <D.25342>; else goto <D.25343>;
  <D.25342>:
  mono_class_setup_methods (klass);
  D.25344 = klass->exception_type;
  if (D.25344 != 0) goto <D.25345>; else goto <D.25346>;
  <D.25345>:
  D.25347 = 0B;
  return D.25347;
  <D.25346>:
  i = 0;
  goto <D.24492>;
  <D.24491>:
  D.25348 = klass->methods;
  i.0 = (unsigned int) i;
  D.25350 = i.0 * 4;
  D.25351 = D.25348 + D.25350;
  m = *D.25351;
  if (m == declaring) goto <D.24490>; else goto <D.25352>;
  <D.25352>:
  D.25353 = BIT_FIELD_REF <*m, 8, 168>;
  D.25354 = D.25353 & 16;
  if (D.25354 != 0) goto <D.25355>; else goto <D.25356>;
  <D.25355>:
  D.25357 = mono_method_get_declaring_generic_method (m);
  if (D.25357 == declaring) goto <D.24490>; else goto <D.25358>;
  <D.25358>:
  <D.25356>:
  i = i + 1;
  <D.24492>:
  i.1 = (unsigned int) i;
  D.25360 = klass->method.count;
  if (i.1 < D.25360) goto <D.24491>; else goto <D.24490>;
  <D.24490>:
  i.1 = (unsigned int) i;
  D.25360 = klass->method.count;
  if (i.1 >= D.25360) goto <D.25361>; else goto <D.25362>;
  <D.25361>:
  D.25347 = 0B;
  return D.25347;
  <D.25362>:
  <D.25343>:
  if (method != declaring) goto <D.25363>; else goto <D.25364>;
  <D.25363>:
  {
    struct MonoGenericContext context;

    try
      {
        context.class_inst = 0B;
        D.25365 = mono_method_get_context (method);
        D.25366 = D.25365->method_inst;
        context.method_inst = D.25366;
        m = mono_class_inflate_generic_method (m, &context);
      }
    finally
      {
        context = {CLOBBER};
      }
  }
  <D.25364>:
  D.25347 = m;
  return D.25347;
}


mono_is_partially_sharable_inst (struct MonoGenericInst * inst)
{
  struct MonoType * D.25371;
  int D.25372;
  unsigned char D.25374;
  <unnamed-unsigned:22> D.25376;
  int D.25377;
  gboolean D.25378;
  _Bool D.25379;
  _Bool D.25380;
  _Bool D.25381;
  int i;
  gboolean has_refs;
  gboolean has_non_refs;

  has_refs = 0;
  has_non_refs = 0;
  i = 0;
  goto <D.24598>;
  <D.24597>:
  D.25371 = inst->type_argv[i];
  D.25372 = mono_type_is_reference (D.25371);
  if (D.25372 != 0) goto <D.25368>; else goto <D.25373>;
  <D.25373>:
  D.25371 = inst->type_argv[i];
  D.25374 = D.25371->type;
  if (D.25374 == 19) goto <D.25368>; else goto <D.25375>;
  <D.25375>:
  D.25371 = inst->type_argv[i];
  D.25374 = D.25371->type;
  if (D.25374 == 30) goto <D.25368>; else goto <D.25369>;
  <D.25368>:
  has_refs = 1;
  goto <D.25370>;
  <D.25369>:
  has_non_refs = 1;
  <D.25370>:
  i = i + 1;
  <D.24598>:
  D.25376 = inst->type_argc;
  D.25377 = (int) D.25376;
  if (D.25377 > i) goto <D.24597>; else goto <D.24599>;
  <D.24599>:
  D.25379 = has_refs != 0;
  D.25380 = has_non_refs != 0;
  D.25381 = D.25379 & D.25380;
  D.25378 = (gboolean) D.25381;
  return D.25378;
}


mini_get_gsharedvt_wrapper (gboolean gsharedvt_in, void * addr, struct MonoMethodSignature * normal_sig, struct MonoMethodSignature * gsharedvt_sig, struct MonoGenericSharingContext * gsctx, gint32 vcall_offset, gboolean calli)
{
  int inited.2;
  union mono_mutex_t * D.25386;
  _Bool D.25389;
  long int D.25390;
  long int D.25391;
  struct GHashTable * D.25394;
  struct GHashTable * D.25397;
  _Bool D.25400;
  long int D.25401;
  long int D.25402;
  void * D.25407;
  void * tramp_addr.3;
  void * tramp_addr.4;
  int mono_aot_only.5;
  struct MonoDomain * D.25421;
  int num_trampolines.6;
  int num_trampolines.7;
  _Bool D.25426;
  long int D.25427;
  long int D.25428;
  _Bool D.25433;
  long int D.25434;
  long int D.25435;
  static gboolean inited = 0;
  static int num_trampolines;
  void * res;
  void * info;
  struct MonoDomain * domain;
  struct MonoJitDomainInfo * domain_info;
  struct GSharedVtTrampInfo * tramp_info;
  struct GSharedVtTrampInfo tinfo;

  try
    {
      domain = mono_domain_get ();
      inited.2 = inited;
      if (inited.2 == 0) goto <D.25384>; else goto <D.25385>;
      <D.25384>:
      mono_counters_register ("GSHAREDVT arg trampolines", 256, &num_trampolines);
      inited = 1;
      <D.25385>:
      tinfo.is_in = gsharedvt_in;
      tinfo.calli = calli;
      tinfo.vcall_offset = vcall_offset;
      tinfo.addr = addr;
      tinfo.sig = normal_sig;
      tinfo.gsig = gsharedvt_sig;
      memcpy (&tinfo.gsctx, gsctx, 8);
      domain_info = domain->runtime_info;
      {
        int ret;

        D.25386 = &domain->lock.mutex;
        ret = pthread_mutex_lock (D.25386);
        if (ret != 0) goto <D.25387>; else goto <D.25388>;
        <D.25387>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
        <D.25388>:
        D.25389 = ret != 0;
        D.25390 = (long int) D.25389;
        D.25391 = __builtin_expect (D.25390, 0);
        if (D.25391 != 0) goto <D.25392>; else goto <D.25393>;
        <D.25392>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1148, "ret == 0");
        <D.25393>:
      }
      D.25394 = domain_info->gsharedvt_arg_tramp_hash;
      if (D.25394 == 0B) goto <D.25395>; else goto <D.25396>;
      <D.25395>:
      D.25397 = monoeg_g_hash_table_new (tramp_info_hash, tramp_info_equal);
      domain_info->gsharedvt_arg_tramp_hash = D.25397;
      <D.25396>:
      D.25394 = domain_info->gsharedvt_arg_tramp_hash;
      res = monoeg_g_hash_table_lookup (D.25394, &tinfo);
      {
        int ret;

        D.25386 = &domain->lock.mutex;
        ret = pthread_mutex_unlock (D.25386);
        if (ret != 0) goto <D.25398>; else goto <D.25399>;
        <D.25398>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
        <D.25399>:
        D.25400 = ret != 0;
        D.25401 = (long int) D.25400;
        D.25402 = __builtin_expect (D.25401, 0);
        if (D.25402 != 0) goto <D.25403>; else goto <D.25404>;
        <D.25403>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1152, "ret == 0");
        <D.25404>:
      }
      if (res != 0B) goto <D.25405>; else goto <D.25406>;
      <D.25405>:
      D.25407 = res;
      return D.25407;
      <D.25406>:
      info = mono_arch_get_gsharedvt_call_info (addr, normal_sig, gsharedvt_sig, gsctx, gsharedvt_in, vcall_offset, calli);
      if (gsharedvt_in != 0) goto <D.25408>; else goto <D.25409>;
      <D.25408>:
      {
        static void * tramp_addr;
        struct MonoMethod * wrapper;

        tramp_addr.3 = tramp_addr;
        if (tramp_addr.3 == 0B) goto <D.25411>; else goto <D.25412>;
        <D.25411>:
        wrapper = mono_marshal_get_gsharedvt_in_wrapper ();
        addr = mono_compile_method (wrapper);
        mono_memory_barrier ();
        tramp_addr = addr;
        <D.25412>:
        addr = tramp_addr;
      }
      goto <D.25413>;
      <D.25409>:
      {
        static void * tramp_addr;
        struct MonoMethod * wrapper;

        tramp_addr.4 = tramp_addr;
        if (tramp_addr.4 == 0B) goto <D.25415>; else goto <D.25416>;
        <D.25415>:
        wrapper = mono_marshal_get_gsharedvt_out_wrapper ();
        addr = mono_compile_method (wrapper);
        mono_memory_barrier ();
        tramp_addr = addr;
        <D.25416>:
        addr = tramp_addr;
      }
      <D.25413>:
      mono_aot_only.5 = mono_aot_only;
      if (mono_aot_only.5 != 0) goto <D.25418>; else goto <D.25419>;
      <D.25418>:
      addr = mono_aot_get_gsharedvt_arg_trampoline (info, addr);
      goto <D.25420>;
      <D.25419>:
      D.25421 = mono_domain_get ();
      addr = mono_arch_get_gsharedvt_arg_trampoline (D.25421, info, addr);
      <D.25420>:
      num_trampolines.6 = num_trampolines;
      num_trampolines.7 = num_trampolines.6 + 1;
      num_trampolines = num_trampolines.7;
      tramp_info = mono_domain_alloc0 (domain, 32);
      memcpy (tramp_info, &tinfo, 32);
      {
        int ret;

        D.25386 = &domain->lock.mutex;
        ret = pthread_mutex_lock (D.25386);
        if (ret != 0) goto <D.25424>; else goto <D.25425>;
        <D.25424>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
        <D.25425>:
        D.25426 = ret != 0;
        D.25427 = (long int) D.25426;
        D.25428 = __builtin_expect (D.25427, 0);
        if (D.25428 != 0) goto <D.25429>; else goto <D.25430>;
        <D.25429>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1193, "ret == 0");
        <D.25430>:
      }
      D.25394 = domain_info->gsharedvt_arg_tramp_hash;
      monoeg_g_hash_table_insert_replace (D.25394, tramp_info, addr, 0);
      {
        int ret;

        D.25386 = &domain->lock.mutex;
        ret = pthread_mutex_unlock (D.25386);
        if (ret != 0) goto <D.25431>; else goto <D.25432>;
        <D.25431>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
        <D.25432>:
        D.25433 = ret != 0;
        D.25434 = (long int) D.25433;
        D.25435 = __builtin_expect (D.25434, 0);
        if (D.25435 != 0) goto <D.25436>; else goto <D.25437>;
        <D.25436>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1196, "ret == 0");
        <D.25437>:
      }
      D.25407 = addr;
      return D.25407;
    }
  finally
    {
      tinfo = {CLOBBER};
    }
}


tramp_info_equal (const void * a, const void * b)
{
  gboolean D.25440;
  int iftmp.8;
  int D.25444;
  int D.25445;
  int D.25447;
  int D.25448;
  int D.25450;
  int D.25451;
  void * D.25453;
  void * D.25454;
  struct MonoMethodSignature * D.25456;
  struct MonoMethodSignature * D.25457;
  struct MonoMethodSignature * D.25459;
  struct MonoMethodSignature * D.25460;
  struct MonoGenericInst * D.25462;
  struct MonoGenericInst * D.25463;
  struct MonoGenericInst * D.25465;
  struct MonoGenericInst * D.25466;
  struct GSharedVtTrampInfo * tramp1;
  struct GSharedVtTrampInfo * tramp2;

  tramp1 = a;
  tramp2 = b;
  D.25444 = tramp1->is_in;
  D.25445 = tramp2->is_in;
  if (D.25444 == D.25445) goto <D.25446>; else goto <D.25442>;
  <D.25446>:
  D.25447 = tramp1->calli;
  D.25448 = tramp2->calli;
  if (D.25447 == D.25448) goto <D.25449>; else goto <D.25442>;
  <D.25449>:
  D.25450 = tramp1->vcall_offset;
  D.25451 = tramp2->vcall_offset;
  if (D.25450 == D.25451) goto <D.25452>; else goto <D.25442>;
  <D.25452>:
  D.25453 = tramp1->addr;
  D.25454 = tramp2->addr;
  if (D.25453 == D.25454) goto <D.25455>; else goto <D.25442>;
  <D.25455>:
  D.25456 = tramp1->sig;
  D.25457 = tramp2->sig;
  if (D.25456 == D.25457) goto <D.25458>; else goto <D.25442>;
  <D.25458>:
  D.25459 = tramp1->gsig;
  D.25460 = tramp2->gsig;
  if (D.25459 == D.25460) goto <D.25461>; else goto <D.25442>;
  <D.25461>:
  D.25462 = tramp1->gsctx.class_inst;
  D.25463 = tramp2->gsctx.class_inst;
  if (D.25462 == D.25463) goto <D.25464>; else goto <D.25442>;
  <D.25464>:
  D.25465 = tramp1->gsctx.method_inst;
  D.25466 = tramp2->gsctx.method_inst;
  if (D.25465 == D.25466) goto <D.25467>; else goto <D.25442>;
  <D.25467>:
  iftmp.8 = 1;
  goto <D.25443>;
  <D.25442>:
  iftmp.8 = 0;
  <D.25443>:
  D.25440 = iftmp.8;
  return D.25440;
}


tramp_info_hash (const void * key)
{
  guint D.25469;
  void * D.25470;
  struct GSharedVtTrampInfo * tramp;

  tramp = key;
  D.25470 = tramp->addr;
  D.25469 = (guint) D.25470;
  return D.25469;
}


mono_memory_barrier ()
{
  __sync_synchronize ();
}


memcpy (void * restrict __dest, const void * restrict __src, size_t __len)
{
  void * D.25472;
  unsigned int D.25473;

  D.25473 = __builtin_object_size (__dest, 0);
  D.25472 = __builtin___memcpy_chk (__dest, __src, __len, D.25473);
  return D.25472;
}


mono_rgctx_info_type_to_str (MonoRgctxInfoType type)
{
  const char * D.25475;

  switch (type) <default: <D.24851>, case 0: <D.24826>, case 1: <D.24827>, case 2: <D.24828>, case 3: <D.24829>, case 4: <D.24830>, case 5: <D.24831>, case 6: <D.24833>, case 7: <D.24834>, case 8: <D.24835>, case 9: <D.24836>, case 10: <D.24837>, case 11: <D.24838>, case 12: <D.24839>, case 13: <D.24840>, case 14: <D.24841>, case 15: <D.24843>, case 16: <D.24844>, case 17: <D.24845>, case 18: <D.24846>, case 19: <D.24842>, case 20: <D.24832>, case 22: <D.24847>, case 23: <D.24848>, case 24: <D.24849>, case 25: <D.24850>>
  <D.24826>:
  D.25475 = "STATIC_DATA";
  return D.25475;
  <D.24827>:
  D.25475 = "KLASS";
  return D.25475;
  <D.24828>:
  D.25475 = "VTABLE";
  return D.25475;
  <D.24829>:
  D.25475 = "TYPE";
  return D.25475;
  <D.24830>:
  D.25475 = "REFLECTION_TYPE";
  return D.25475;
  <D.24831>:
  D.25475 = "METHOD";
  return D.25475;
  <D.24832>:
  D.25475 = "GSHAREDVT_INFO";
  return D.25475;
  <D.24833>:
  D.25475 = "GENERIC_METHOD_CODE";
  return D.25475;
  <D.24834>:
  D.25475 = "CLASS_FIELD";
  return D.25475;
  <D.24835>:
  D.25475 = "METHOD_RGCTX";
  return D.25475;
  <D.24836>:
  D.25475 = "METHOD_CONTEXT";
  return D.25475;
  <D.24837>:
  D.25475 = "REMOTING_INVOKE_WITH_CHECK";
  return D.25475;
  <D.24838>:
  D.25475 = "METHOD_DELEGATE_CODE";
  return D.25475;
  <D.24839>:
  D.25475 = "CAST_CACHE";
  return D.25475;
  <D.24840>:
  D.25475 = "ARRAY_ELEMENT_SIZE";
  return D.25475;
  <D.24841>:
  D.25475 = "VALUE_SIZE";
  return D.25475;
  <D.24842>:
  D.25475 = "CLASS_BOX_TYPE";
  return D.25475;
  <D.24843>:
  D.25475 = "FIELD_OFFSET";
  return D.25475;
  <D.24844>:
  D.25475 = "METHOD_GSHAREDVT_OUT_TRAMPOLINE";
  return D.25475;
  <D.24845>:
  D.25475 = "METHOD_GSHAREDVT_OUT_TRAMPOLINE_VIRT";
  return D.25475;
  <D.24846>:
  D.25475 = "SIG_GSHAREDVT_OUT_TRAMPOLINE_CALLI";
  return D.25475;
  <D.24847>:
  D.25475 = "MEMCPY";
  return D.25475;
  <D.24848>:
  D.25475 = "BZERO";
  return D.25475;
  <D.24849>:
  D.25475 = "NULLABLE_CLASS_BOX";
  return D.25475;
  <D.24850>:
  D.25475 = "NULLABLE_CLASS_UNBOX";
  return D.25475;
  <D.24851>:
  D.25475 = "<UNKNOWN RGCTX INFO TYPE>";
  return D.25475;
}


mini_rgctx_info_type_to_patch_info_type (MonoRgctxInfoType info_type)
{
  MonoJumpInfoType D.25477;

  switch (info_type) <default: <D.24925>, case 0: <D.24910>, case 1: <D.24911>, case 2: <D.24912>, case 3: <D.24913>, case 4: <D.24914>, case 12: <D.24915>, case 13: <D.24916>, case 14: <D.24917>, case 15: <D.24924>, case 19: <D.24918>, case 21: <D.24923>, case 22: <D.24919>, case 23: <D.24920>, case 24: <D.24921>, case 25: <D.24922>>
  <D.24910>:
  <D.24911>:
  <D.24912>:
  <D.24913>:
  <D.24914>:
  <D.24915>:
  <D.24916>:
  <D.24917>:
  <D.24918>:
  <D.24919>:
  <D.24920>:
  <D.24921>:
  <D.24922>:
  <D.24923>:
  D.25477 = 11;
  return D.25477;
  <D.24924>:
  D.25477 = 13;
  return D.25477;
  <D.24925>:
  monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 1677);
  D.25477 = 4294967295;
  return D.25477;
}


mono_method_lookup_or_register_info (struct MonoMethod * method, gboolean in_mrgctx, void * data, MonoRgctxInfoType info_type, struct MonoGenericContext * generic_context)
{
  struct MonoGenericContext * D.25481;
  int iftmp.9;
  unsigned char D.25486;
  unsigned char D.25487;
  _Bool D.25489;
  long int D.25490;
  long int D.25491;
  <unnamed-unsigned:22> D.25494;
  _Bool D.25495;
  long int D.25496;
  long int D.25497;
  guint32 D.25503;
  unsigned int index.10;
  struct MonoClass * class;
  int type_argc;
  int index;

  class = method->klass;
  if (in_mrgctx != 0) goto <D.25479>; else goto <D.25480>;
  <D.25479>:
  {
    struct MonoGenericInst * method_inst;

    D.25481 = mono_method_get_context (method);
    method_inst = D.25481->method_inst;
    D.25486 = BIT_FIELD_REF <*method, 8, 168>;
    D.25487 = D.25486 & 16;
    if (D.25487 == 0) goto <D.25483>; else goto <D.25488>;
    <D.25488>:
    if (method_inst == 0B) goto <D.25483>; else goto <D.25484>;
    <D.25483>:
    iftmp.9 = 1;
    goto <D.25485>;
    <D.25484>:
    iftmp.9 = 0;
    <D.25485>:
    D.25489 = iftmp.9 != 0;
    D.25490 = (long int) D.25489;
    D.25491 = __builtin_expect (D.25490, 0);
    if (D.25491 != 0) goto <D.25492>; else goto <D.25493>;
    <D.25492>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1755, "method->is_inflated && method_inst");
    <D.25493>:
    D.25494 = method_inst->type_argc;
    type_argc = (int) D.25494;
    D.25495 = type_argc <= 0;
    D.25496 = (long int) D.25495;
    D.25497 = __builtin_expect (D.25496, 0);
    if (D.25497 != 0) goto <D.25498>; else goto <D.25499>;
    <D.25498>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1757, "type_argc > 0");
    <D.25499>:
  }
  goto <D.25500>;
  <D.25480>:
  type_argc = 0;
  <D.25500>:
  index = lookup_or_register_info (class, type_argc, data, info_type, generic_context);
  if (in_mrgctx != 0) goto <D.25501>; else goto <D.25502>;
  <D.25501>:
  index.10 = (unsigned int) index;
  D.25503 = index.10 | 2147483648;
  return D.25503;
  <D.25502>:
  D.25503 = (guint32) index;
  return D.25503;
}


lookup_or_register_info (struct MonoClass * class, int type_argc, void * data, MonoRgctxInfoType info_type, struct MonoGenericContext * generic_context)
{
  int D.25506;
  <unnamed type> D.25511;
  void * D.25513;
  int D.25514;
  int D.25517;
  int inited.11;
  int max_slot.12;
  static gboolean inited = 0;
  static int max_slot = 0;
  struct MonoRuntimeGenericContextTemplate * rgctx_template;
  struct MonoRuntimeGenericContextInfoTemplate * oti_list;
  struct MonoRuntimeGenericContextInfoTemplate * oti;
  int i;

  rgctx_template = mono_class_get_runtime_generic_context_template (class);
  class = get_shared_class (class);
  mono_loader_lock ();
  D.25506 = info_has_identity (info_type);
  if (D.25506 != 0) goto <D.25507>; else goto <D.25508>;
  <D.25507>:
  oti_list = get_info_templates (rgctx_template, type_argc);
  oti = oti_list;
  i = 0;
  goto <D.24942>;
  <D.24941>:
  {
    void * inflated_data;

    D.25511 = oti->info_type;
    if (D.25511 != info_type) goto <D.25509>; else goto <D.25512>;
    <D.25512>:
    D.25513 = oti->data;
    if (D.25513 == 0B) goto <D.25509>; else goto <D.25510>;
    <D.25509>:
    // predicted unlikely by continue predictor.
    goto <D.24940>;
    <D.25510>:
    inflated_data = inflate_info (oti, generic_context, class, 1);
    D.25514 = info_equal (data, inflated_data, info_type);
    if (D.25514 != 0) goto <D.25515>; else goto <D.25516>;
    <D.25515>:
    free_inflated_info (info_type, inflated_data);
    mono_loader_unlock ();
    D.25517 = i;
    return D.25517;
    <D.25516>:
    free_inflated_info (info_type, inflated_data);
  }
  <D.24940>:
  oti = oti->next;
  i = i + 1;
  <D.24942>:
  if (oti != 0B) goto <D.24941>; else goto <D.24943>;
  <D.24943>:
  <D.25508>:
  i = register_info (class, type_argc, data, info_type);
  mono_loader_unlock ();
  inited.11 = inited;
  if (inited.11 == 0) goto <D.25519>; else goto <D.25520>;
  <D.25519>:
  mono_counters_register ("RGCTX max slot number", 2048, &max_slot);
  inited = 1;
  <D.25520>:
  max_slot.12 = max_slot;
  if (i > max_slot.12) goto <D.25522>; else goto <D.25523>;
  <D.25522>:
  max_slot = i;
  <D.25523>:
  D.25517 = i;
  return D.25517;
}


mono_class_get_runtime_generic_context_template (struct MonoClass * class)
{
  struct MonoRuntimeGenericContextTemplate * D.25527;
  struct MonoClass * D.25528;
  int D.25531;
  void * D.25532;
  struct MonoClass * D.25535;
  struct MonoType * D.25536;
  struct MonoImage * D.25539;
  int i.13;
  <unnamed type> D.25541;
  struct MonoRuntimeGenericContextTemplate * D.25542;
  struct MonoRuntimeGenericContextTemplate * parent_template;
  struct MonoRuntimeGenericContextTemplate * template;
  guint32 i;

  class = get_shared_class (class);
  mono_loader_lock ();
  template = class_lookup_rgctx_template (class);
  mono_loader_unlock ();
  if (template != 0B) goto <D.25525>; else goto <D.25526>;
  <D.25525>:
  D.25527 = template;
  return D.25527;
  <D.25526>:
  template = alloc_template (class);
  mono_loader_lock ();
  D.25528 = class->parent;
  if (D.25528 != 0B) goto <D.25529>; else goto <D.25530>;
  <D.25529>:
  {
    guint32 num_entries;
    int max_argc;
    int type_argc;

    D.25528 = class->parent;
    parent_template = mono_class_get_runtime_generic_context_template (D.25528);
    max_argc = template_get_max_argc (parent_template);
    type_argc = 0;
    goto <D.24617>;
    <D.24616>:
    D.25531 = rgctx_template_num_infos (parent_template, type_argc);
    num_entries = (guint32) D.25531;
    i = 0;
    goto <D.24614>;
    <D.24613>:
    {
      struct MonoRuntimeGenericContextInfoTemplate oti;

      try
        {
          D.25528 = class->parent;
          oti = class_get_rgctx_template_oti (D.25528, type_argc, i, 0, 0, 0B); [return slot optimization]
          D.25532 = oti.data;
          if (D.25532 != 0B) goto <D.25533>; else goto <D.25534>;
          <D.25533>:
          D.25532 = oti.data;
          D.25535 = mono_defaults.object_class;
          D.25536 = &D.25535->byval_arg;
          if (D.25532 != D.25536) goto <D.25537>; else goto <D.25538>;
          <D.25537>:
          D.25539 = class->image;
          i.13 = (int) i;
          D.25532 = oti.data;
          D.25541 = oti.info_type;
          rgctx_template_set_slot (D.25539, template, type_argc, i.13, D.25532, D.25541);
          <D.25538>:
          <D.25534>:
        }
      finally
        {
          oti = {CLOBBER};
        }
    }
    i = i + 1;
    <D.24614>:
    if (i < num_entries) goto <D.24613>; else goto <D.24615>;
    <D.24615>:
    type_argc = type_argc + 1;
    <D.24617>:
    if (type_argc <= max_argc) goto <D.24616>; else goto <D.24618>;
    <D.24618>:
  }
  <D.25530>:
  D.25542 = class_lookup_rgctx_template (class);
  if (D.25542 != 0B) goto <D.25543>; else goto <D.25544>;
  <D.25543>:
  template = class_lookup_rgctx_template (class);
  goto <D.25545>;
  <D.25544>:
  class_set_rgctx_template (class, template);
  D.25528 = class->parent;
  if (D.25528 != 0B) goto <D.25546>; else goto <D.25547>;
  <D.25546>:
  register_generic_subclass (class);
  <D.25547>:
  <D.25545>:
  mono_loader_unlock ();
  D.25527 = template;
  return D.25527;
}


alloc_template (struct MonoClass * class)
{
  int inited.14;
  int num_allocted.15;
  int num_allocted.16;
  int num_bytes.17;
  int num_bytes.18;
  struct MonoRuntimeGenericContextTemplate * D.25556;
  struct MonoImage * D.25557;
  unsigned int size.19;
  static gboolean inited = 0;
  static int num_allocted = 0;
  static int num_bytes = 0;
  int size;

  size = 12;
  inited.14 = inited;
  if (inited.14 == 0) goto <D.25550>; else goto <D.25551>;
  <D.25550>:
  mono_counters_register ("RGCTX template num allocted", 2048, &num_allocted);
  mono_counters_register ("RGCTX template bytes allocted", 2048, &num_bytes);
  inited = 1;
  <D.25551>:
  num_allocted.15 = num_allocted;
  num_allocted.16 = num_allocted.15 + 1;
  num_allocted = num_allocted.16;
  num_bytes.17 = num_bytes;
  num_bytes.18 = num_bytes.17 + size;
  num_bytes = num_bytes.18;
  D.25557 = class->image;
  size.19 = (unsigned int) size;
  D.25556 = mono_image_alloc0 (D.25557, size.19);
  return D.25556;
}


template_get_max_argc (struct MonoRuntimeGenericContextTemplate * template)
{
  int D.25560;
  struct GSList * D.25561;
  unsigned int D.25562;

  D.25561 = template->method_templates;
  D.25562 = monoeg_g_slist_length (D.25561);
  D.25560 = (int) D.25562;
  return D.25560;
}


rgctx_template_num_infos (struct MonoRuntimeGenericContextTemplate * template, int type_argc)
{
  int D.25564;
  struct MonoRuntimeGenericContextInfoTemplate * oti;
  int i;

  i = 0;
  oti = get_info_templates (template, type_argc);
  goto <D.24409>;
  <D.24408>:
  i = i + 1;
  oti = oti->next;
  <D.24409>:
  if (oti != 0B) goto <D.24408>; else goto <D.24410>;
  <D.24410>:
  D.25564 = i;
  return D.25564;
}


class_get_rgctx_template_oti (struct MonoClass * class, int type_argc, guint32 slot, gboolean temporary, gboolean shared, gboolean * do_free)
{
  int iftmp.20;
  _Bool D.25570;
  _Bool D.25571;
  _Bool D.25572;
  _Bool D.25574;
  _Bool D.25575;
  _Bool D.25576;
  _Bool D.25578;
  long int D.25579;
  long int D.25580;
  struct MonoGenericClass * D.25584;
  struct MonoClass * D.25587;
  void * D.25588;
  struct MonoGenericContext * D.25591;
  void * D.25592;
  int tmp_do_free.21;
  <unnamed type> D.25596;
  int slot.22;
  _Bool D.25600;
  long int D.25601;
  long int D.25602;

  D.25570 = temporary == 0;
  D.25571 = do_free == 0B;
  D.25572 = D.25570 | D.25571;
  if (D.25572 != 0) goto <D.25573>; else goto <D.25568>;
  <D.25573>:
  D.25574 = temporary != 0;
  D.25575 = do_free != 0B;
  D.25576 = D.25574 | D.25575;
  if (D.25576 != 0) goto <D.25577>; else goto <D.25568>;
  <D.25577>:
  iftmp.20 = 1;
  goto <D.25569>;
  <D.25568>:
  iftmp.20 = 0;
  <D.25569>:
  D.25578 = iftmp.20 != 0;
  D.25579 = (long int) D.25578;
  D.25580 = __builtin_expect (D.25579, 0);
  if (D.25580 != 0) goto <D.25581>; else goto <D.25582>;
  <D.25581>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 886, "(temporary && do_free) || (!temporary && !do_free)");
  <D.25582>:
  D.25584 = class->generic_class;
  if (D.25584 != 0B) goto <D.25585>; else goto <D.25583>;
  <D.25585>:
  if (shared == 0) goto <D.25586>; else goto <D.25583>;
  <D.25586>:
  {
    struct MonoRuntimeGenericContextInfoTemplate oti;
    gboolean tmp_do_free;

    try
      {
        D.25584 = class->generic_class;
        D.25587 = D.25584->container_class;
        oti = class_get_rgctx_template_oti (D.25587, type_argc, slot, 1, 0, &tmp_do_free);
        D.25588 = oti.data;
        if (D.25588 != 0B) goto <D.25589>; else goto <D.25590>;
        <D.25589>:
        {
          void * info;

          info = oti.data;
          D.25584 = class->generic_class;
          D.25591 = &D.25584->context;
          D.25592 = inflate_info (&oti, D.25591, class, temporary);
          oti.data = D.25592;
          tmp_do_free.21 = tmp_do_free;
          if (tmp_do_free.21 != 0) goto <D.25594>; else goto <D.25595>;
          <D.25594>:
          D.25596 = oti.info_type;
          free_inflated_info (D.25596, info);
          <D.25595>:
        }
        <D.25590>:
        if (temporary != 0) goto <D.25597>; else goto <D.25598>;
        <D.25597>:
        *do_free = 1;
        <D.25598>:
        <retval> = oti;
        return <retval>;
      }
    finally
      {
        oti = {CLOBBER};
        tmp_do_free = {CLOBBER};
      }
  }
  <D.25583>:
  {
    struct MonoRuntimeGenericContextTemplate * template;
    struct MonoRuntimeGenericContextInfoTemplate * oti;

    template = mono_class_get_runtime_generic_context_template (class);
    slot.22 = (int) slot;
    oti = rgctx_template_get_other_slot (template, type_argc, slot.22);
    D.25600 = oti == 0B;
    D.25601 = (long int) D.25600;
    D.25602 = __builtin_expect (D.25601, 0);
    if (D.25602 != 0) goto <D.25603>; else goto <D.25604>;
    <D.25603>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 912, "oti");
    <D.25604>:
    if (temporary != 0) goto <D.25605>; else goto <D.25606>;
    <D.25605>:
    *do_free = 0;
    <D.25606>:
    <retval> = *oti;
    return <retval>;
  }
}


rgctx_template_get_other_slot (struct MonoRuntimeGenericContextTemplate * template, int type_argc, int slot)
{
  _Bool D.25609;
  long int D.25610;
  long int D.25611;
  struct MonoRuntimeGenericContextInfoTemplate * D.25616;
  int i;
  struct MonoRuntimeGenericContextInfoTemplate * oti;

  D.25609 = slot < 0;
  D.25610 = (long int) D.25609;
  D.25611 = __builtin_expect (D.25610, 0);
  if (D.25611 != 0) goto <D.25612>; else goto <D.25613>;
  <D.25612>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 189, "slot >= 0");
  <D.25613>:
  oti = get_info_templates (template, type_argc);
  i = 0;
  goto <D.24400>;
  <D.24399>:
  if (oti == 0B) goto <D.25614>; else goto <D.25615>;
  <D.25614>:
  D.25616 = 0B;
  return D.25616;
  <D.25615>:
  oti = oti->next;
  i = i + 1;
  <D.24400>:
  if (i < slot) goto <D.24399>; else goto <D.24401>;
  <D.24401>:
  D.25616 = oti;
  return D.25616;
}


rgctx_template_set_slot (struct MonoImage * image, struct MonoRuntimeGenericContextTemplate * template, int type_argc, int slot, void * data, MonoRgctxInfoType info_type)
{
  struct MonoRuntimeGenericContextInfoTemplate * list.23;
  int inited.24;
  _Bool D.25622;
  long int D.25623;
  long int D.25624;
  _Bool D.25627;
  long int D.25628;
  long int D.25629;
  struct MonoRuntimeGenericContextInfoTemplate * D.25634;
  struct MonoRuntimeGenericContextInfoTemplate * D.25637;
  void * D.25638;
  _Bool D.25639;
  long int D.25640;
  long int D.25641;
  struct MonoRuntimeGenericContextInfoTemplate * list.25;
  struct MonoClass * D.25645;
  struct MonoType * D.25646;
  int num_markers.26;
  int num_markers.27;
  int num_data.28;
  int num_data.29;
  static gboolean inited = 0;
  static int num_markers = 0;
  static int num_data = 0;
  int i;
  struct MonoRuntimeGenericContextInfoTemplate * list;
  struct MonoRuntimeGenericContextInfoTemplate * * oti;

  try
    {
      list.23 = get_info_templates (template, type_argc);
      list = list.23;
      oti = &list;
      inited.24 = inited;
      if (inited.24 == 0) goto <D.25620>; else goto <D.25621>;
      <D.25620>:
      mono_counters_register ("RGCTX oti num markers", 2048, &num_markers);
      mono_counters_register ("RGCTX oti num data", 2048, &num_data);
      inited = 1;
      <D.25621>:
      D.25622 = slot < 0;
      D.25623 = (long int) D.25622;
      D.25624 = __builtin_expect (D.25623, 0);
      if (D.25624 != 0) goto <D.25625>; else goto <D.25626>;
      <D.25625>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 414, "slot >= 0");
      <D.25626>:
      D.25627 = data == 0B;
      D.25628 = (long int) D.25627;
      D.25629 = __builtin_expect (D.25628, 0);
      if (D.25629 != 0) goto <D.25630>; else goto <D.25631>;
      <D.25630>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 415, "data");
      <D.25631>:
      i = 0;
      goto <D.24477>;
      <D.24476>:
      if (i > 0) goto <D.25632>; else goto <D.25633>;
      <D.25632>:
      D.25634 = *oti;
      oti = &D.25634->next;
      <D.25633>:
      D.25634 = *oti;
      if (D.25634 == 0B) goto <D.25635>; else goto <D.25636>;
      <D.25635>:
      D.25637 = alloc_oti (image);
      *oti = D.25637;
      <D.25636>:
      i = i + 1;
      <D.24477>:
      if (i <= slot) goto <D.24476>; else goto <D.24478>;
      <D.24478>:
      D.25634 = *oti;
      D.25638 = D.25634->data;
      D.25639 = D.25638 != 0B;
      D.25640 = (long int) D.25639;
      D.25641 = __builtin_expect (D.25640, 0);
      if (D.25641 != 0) goto <D.25642>; else goto <D.25643>;
      <D.25642>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 426, "!(*oti)->data");
      <D.25643>:
      D.25634 = *oti;
      D.25634->data = data;
      D.25634 = *oti;
      D.25634->info_type = info_type;
      list.25 = list;
      set_info_templates (image, template, type_argc, list.25);
      D.25645 = mono_defaults.object_class;
      D.25646 = &D.25645->byval_arg;
      if (D.25646 == data) goto <D.25647>; else goto <D.25648>;
      <D.25647>:
      num_markers.26 = num_markers;
      num_markers.27 = num_markers.26 + 1;
      num_markers = num_markers.27;
      goto <D.25651>;
      <D.25648>:
      num_data.28 = num_data;
      num_data.29 = num_data.28 + 1;
      num_data = num_data.29;
      <D.25651>:
    }
  finally
    {
      list = {CLOBBER};
    }
}


alloc_oti (struct MonoImage * image)
{
  int inited.30;
  int num_allocted.31;
  int num_allocted.32;
  int num_bytes.33;
  int num_bytes.34;
  struct MonoRuntimeGenericContextInfoTemplate * D.25661;
  unsigned int size.35;
  static gboolean inited = 0;
  static int num_allocted = 0;
  static int num_bytes = 0;
  int size;

  size = 12;
  inited.30 = inited;
  if (inited.30 == 0) goto <D.25655>; else goto <D.25656>;
  <D.25655>:
  mono_counters_register ("RGCTX oti num allocted", 2048, &num_allocted);
  mono_counters_register ("RGCTX oti bytes allocted", 2048, &num_bytes);
  inited = 1;
  <D.25656>:
  num_allocted.31 = num_allocted;
  num_allocted.32 = num_allocted.31 + 1;
  num_allocted = num_allocted.32;
  num_bytes.33 = num_bytes;
  num_bytes.34 = num_bytes.33 + size;
  num_bytes = num_bytes.34;
  size.35 = (unsigned int) size;
  D.25661 = mono_image_alloc0 (image, size.35);
  return D.25661;
}


set_info_templates (struct MonoImage * image, struct MonoRuntimeGenericContextTemplate * template, int type_argc, struct MonoRuntimeGenericContextInfoTemplate * oti)
{
  _Bool D.25664;
  long int D.25665;
  long int D.25666;
  struct GSList * D.25672;
  unsigned int D.25673;
  struct GSList * D.25674;
  int D.25675;
  unsigned int D.25676;
  _Bool D.25677;
  long int D.25678;
  long int D.25679;

  D.25664 = type_argc < 0;
  D.25665 = (long int) D.25664;
  D.25666 = __builtin_expect (D.25665, 0);
  if (D.25666 != 0) goto <D.25667>; else goto <D.25668>;
  <D.25667>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 152, "type_argc >= 0");
  <D.25668>:
  if (type_argc == 0) goto <D.25669>; else goto <D.25670>;
  <D.25669>:
  template->infos = oti;
  goto <D.25671>;
  <D.25670>:
  {
    int length;
    struct GSList * list;

    D.25672 = template->method_templates;
    D.25673 = monoeg_g_slist_length (D.25672);
    length = (int) D.25673;
    goto <D.24387>;
    <D.24386>:
    D.25672 = template->method_templates;
    D.25674 = g_slist_append_image (image, D.25672, 0B);
    template->method_templates = D.25674;
    length = length + 1;
    <D.24387>:
    if (length < type_argc) goto <D.24386>; else goto <D.24388>;
    <D.24388>:
    D.25672 = template->method_templates;
    D.25675 = type_argc + -1;
    D.25676 = (unsigned int) D.25675;
    list = monoeg_g_slist_nth (D.25672, D.25676);
    D.25677 = list == 0B;
    D.25678 = (long int) D.25677;
    D.25679 = __builtin_expect (D.25678, 0);
    if (D.25679 != 0) goto <D.25680>; else goto <D.25681>;
    <D.25680>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 166, "list");
    <D.25681>:
    list->data = oti;
  }
  <D.25671>:
}


class_lookup_rgctx_template (struct MonoClass * class)
{
  struct MonoImage * D.25682;
  struct GHashTable * D.25683;
  struct MonoRuntimeGenericContextTemplate * D.25686;
  struct MonoRuntimeGenericContextTemplate * template;

  D.25682 = class->image;
  D.25683 = D.25682->rgctx_template_hash;
  if (D.25683 == 0B) goto <D.25684>; else goto <D.25685>;
  <D.25684>:
  D.25686 = 0B;
  return D.25686;
  <D.25685>:
  D.25682 = class->image;
  D.25683 = D.25682->rgctx_template_hash;
  template = monoeg_g_hash_table_lookup (D.25683, class);
  D.25686 = template;
  return D.25686;
}


class_set_rgctx_template (struct MonoClass * class, struct MonoRuntimeGenericContextTemplate * rgctx_template)
{
  struct MonoImage * D.25688;
  struct GHashTable * D.25689;
  struct GHashTable * D.25692;

  D.25688 = class->image;
  D.25689 = D.25688->rgctx_template_hash;
  if (D.25689 == 0B) goto <D.25690>; else goto <D.25691>;
  <D.25690>:
  D.25688 = class->image;
  D.25692 = monoeg_g_hash_table_new (mono_aligned_addr_hash, 0B);
  D.25688->rgctx_template_hash = D.25692;
  <D.25691>:
  D.25688 = class->image;
  D.25689 = D.25688->rgctx_template_hash;
  monoeg_g_hash_table_insert_replace (D.25689, class, rgctx_template, 0);
}


register_generic_subclass (struct MonoClass * class)
{
  _Bool D.25693;
  long int D.25694;
  long int D.25695;
  struct MonoGenericClass * D.25698;
  struct GHashTable * generic_subclass_hash.36;
  struct GHashTable * generic_subclass_hash.37;
  struct MonoClass * parent;
  struct MonoClass * subclass;
  struct MonoRuntimeGenericContextTemplate * rgctx_template;

  parent = class->parent;
  rgctx_template = class_lookup_rgctx_template (class);
  D.25693 = rgctx_template == 0B;
  D.25694 = (long int) D.25693;
  D.25695 = __builtin_expect (D.25694, 0);
  if (D.25695 != 0) goto <D.25696>; else goto <D.25697>;
  <D.25696>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 260, "rgctx_template");
  <D.25697>:
  D.25698 = parent->generic_class;
  if (D.25698 != 0B) goto <D.25699>; else goto <D.25700>;
  <D.25699>:
  D.25698 = parent->generic_class;
  parent = D.25698->container_class;
  <D.25700>:
  generic_subclass_hash.36 = generic_subclass_hash;
  if (generic_subclass_hash.36 == 0B) goto <D.25702>; else goto <D.25703>;
  <D.25702>:
  generic_subclass_hash.37 = monoeg_g_hash_table_new (mono_aligned_addr_hash, 0B);
  generic_subclass_hash = generic_subclass_hash.37;
  <D.25703>:
  generic_subclass_hash.36 = generic_subclass_hash;
  subclass = monoeg_g_hash_table_lookup (generic_subclass_hash.36, parent);
  rgctx_template->next_subclass = subclass;
  generic_subclass_hash.36 = generic_subclass_hash;
  monoeg_g_hash_table_insert_replace (generic_subclass_hash.36, parent, class, 0);
}


get_shared_class (struct MonoClass * class)
{
  struct MonoClass * D.25705;

  D.25705 = class_uninstantiated (class);
  return D.25705;
}


class_uninstantiated (struct MonoClass * class)
{
  struct MonoGenericClass * D.25707;
  struct MonoClass * D.25710;

  D.25707 = class->generic_class;
  if (D.25707 != 0B) goto <D.25708>; else goto <D.25709>;
  <D.25708>:
  D.25707 = class->generic_class;
  D.25710 = D.25707->container_class;
  return D.25710;
  <D.25709>:
  D.25710 = class;
  return D.25710;
}


info_has_identity (MonoRgctxInfoType info_type)
{
  int D.25712;
  _Bool D.25713;

  D.25713 = info_type != 12;
  D.25712 = (int) D.25713;
  return D.25712;
}


get_info_templates (struct MonoRuntimeGenericContextTemplate * template, int type_argc)
{
  _Bool D.25715;
  long int D.25716;
  long int D.25717;
  struct MonoRuntimeGenericContextInfoTemplate * D.25722;
  struct GSList * D.25723;
  int D.25724;
  unsigned int D.25725;

  D.25715 = type_argc < 0;
  D.25716 = (long int) D.25715;
  D.25717 = __builtin_expect (D.25716, 0);
  if (D.25717 != 0) goto <D.25718>; else goto <D.25719>;
  <D.25718>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 139, "type_argc >= 0");
  <D.25719>:
  if (type_argc == 0) goto <D.25720>; else goto <D.25721>;
  <D.25720>:
  D.25722 = template->infos;
  return D.25722;
  <D.25721>:
  D.25723 = template->method_templates;
  D.25724 = type_argc + -1;
  D.25725 = (unsigned int) D.25724;
  D.25722 = monoeg_g_slist_nth_data (D.25723, D.25725);
  return D.25722;
}


inflate_info (struct MonoRuntimeGenericContextInfoTemplate * oti, struct MonoGenericContext * context, struct MonoClass * class, gboolean temporary)
{
  _Bool D.25727;
  long int D.25728;
  long int D.25729;
  struct MonoClass * D.25732;
  struct MonoType * D.25733;
  void * D.25736;
  struct MonoImage * iftmp.38;
  int D.25741;
  _Bool D.25742;
  long int D.25743;
  long int D.25744;
  struct MonoClass * D.25747;
  struct MonoType * D.25748;
  unsigned char D.25749;
  unsigned char D.25750;
  _Bool D.25751;
  long int D.25752;
  long int D.25753;
  unsigned char D.25756;
  _Bool D.25757;
  _Bool D.25758;
  _Bool D.25759;
  const char * D.25762;
  struct MonoMethodSignature * D.25763;
  struct MonoClass * D.25765;
  _Bool D.25766;
  long int D.25767;
  long int D.25768;
  struct GPtrArray * D.25771;
  struct GPtrArray * D.25772;
  void * * D.25773;
  unsigned int i.39;
  unsigned int D.25775;
  void * * D.25776;
  void * D.25777;
  struct GPtrArray * D.25778;
  unsigned int i.40;
  unsigned int D.25780;
  struct MonoClass * D.25781;
  struct MonoType * D.25782;
  struct MonoMethodSignature * D.25783;
  unsigned char D.25784;
  unsigned char D.25785;
  _Bool D.25786;
  long int D.25787;
  long int D.25788;
  unsigned char D.25791;
  _Bool D.25792;
  _Bool D.25793;
  _Bool D.25794;
  const char * D.25797;
  struct MonoMethodSignature * D.25798;
  struct MonoClass * D.25800;
  _Bool D.25801;
  long int D.25802;
  long int D.25803;
  struct MonoClass * D.25806;
  struct MonoType * D.25807;
  int field.41;
  struct MonoClassField * D.25809;
  int D.25810;
  int D.25811;
  struct MonoClassField * D.25812;
  _Bool D.25813;
  long int D.25814;
  long int D.25815;
  unsigned int i.42;
  unsigned int D.25819;
  int D.25820;
  _Bool D.25821;
  long int D.25822;
  long int D.25823;
  void * data;
  MonoRgctxInfoType info_type;
  struct MonoError error;

  try
    {
      data = oti->data;
      info_type = oti->info_type;
      D.25727 = data == 0B;
      D.25728 = (long int) D.25727;
      D.25729 = __builtin_expect (D.25728, 0);
      if (D.25729 != 0) goto <D.25730>; else goto <D.25731>;
      <D.25730>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 519, "data");
      <D.25731>:
      D.25732 = mono_defaults.object_class;
      D.25733 = &D.25732->byval_arg;
      if (D.25733 == data) goto <D.25734>; else goto <D.25735>;
      <D.25734>:
      D.25732 = mono_defaults.object_class;
      D.25736 = &D.25732->byval_arg;
      return D.25736;
      <D.25735>:
      switch (info_type) <default: <D.24556>, case 0: <D.24503>, case 1: <D.24504>, case 2: <D.24505>, case 3: <D.24506>, case 4: <D.24507>, case 5: <D.24518>, case 6: <D.24519>, case 7: <D.24545>, case 8: <D.24520>, case 9: <D.24521>, case 10: <D.24522>, case 11: <D.24523>, case 12: <D.24508>, case 13: <D.24509>, case 14: <D.24510>, case 15: <D.24546>, case 16: <D.24537>, case 17: <D.24538>, case 18: <D.24552>, case 19: <D.24511>, case 20: <D.24528>, case 21: <D.24514>, case 22: <D.24512>, case 23: <D.24513>, case 24: <D.24515>, case 25: <D.24516>>
      <D.24503>:
      <D.24504>:
      <D.24505>:
      <D.24506>:
      <D.24507>:
      <D.24508>:
      <D.24509>:
      <D.24510>:
      <D.24511>:
      <D.24512>:
      <D.24513>:
      <D.24514>:
      <D.24515>:
      <D.24516>:
      {
        void * result;

        if (temporary == 0) goto <D.25738>; else goto <D.25739>;
        <D.25738>:
        iftmp.38 = class->image;
        goto <D.25740>;
        <D.25739>:
        iftmp.38 = 0B;
        <D.25740>:
        result = mono_class_inflate_generic_type_with_mempool (iftmp.38, data, context, &error);
        D.25741 = mono_error_ok (&error);
        D.25742 = D.25741 == 0;
        D.25743 = (long int) D.25742;
        D.25744 = __builtin_expect (D.25743, 0);
        if (D.25744 != 0) goto <D.25745>; else goto <D.25746>;
        <D.25745>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 542, "mono_error_ok (&error)");
        <D.25746>:
        D.25736 = result;
        return D.25736;
      }
      <D.24518>:
      <D.24519>:
      <D.24520>:
      <D.24521>:
      <D.24522>:
      <D.24523>:
      {
        struct MonoMethod * method;
        struct MonoMethod * inflated_method;
        struct MonoType * inflated_type;
        struct MonoClass * inflated_class;

        method = data;
        D.25747 = method->klass;
        D.25748 = &D.25747->byval_arg;
        inflated_type = mono_class_inflate_generic_type (D.25748, context);
        inflated_class = mono_class_from_mono_type (inflated_type);
        mono_metadata_free_type (inflated_type);
        mono_class_init (inflated_class);
        D.25749 = BIT_FIELD_REF <*method, 8, 160>;
        D.25750 = D.25749 & 124;
        D.25751 = D.25750 != 0;
        D.25752 = (long int) D.25751;
        D.25753 = __builtin_expect (D.25752, 0);
        if (D.25753 != 0) goto <D.25754>; else goto <D.25755>;
        <D.25754>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 561, "!method->wrapper_type");
        <D.25755>:
        D.25756 = inflated_class->byval_arg.type;
        D.25757 = D.25756 == 20;
        D.25758 = D.25756 == 29;
        D.25759 = D.25757 | D.25758;
        if (D.25759 != 0) goto <D.25760>; else goto <D.25761>;
        <D.25760>:
        D.25762 = method->name;
        D.25763 = method->signature;
        inflated_method = mono_method_search_in_array_class (inflated_class, D.25762, D.25763);
        goto <D.25764>;
        <D.25761>:
        inflated_method = mono_class_inflate_generic_method (method, context);
        <D.25764>:
        D.25765 = inflated_method->klass;
        mono_class_init (D.25765);
        D.25765 = inflated_method->klass;
        D.25766 = D.25765 != inflated_class;
        D.25767 = (long int) D.25766;
        D.25768 = __builtin_expect (D.25767, 0);
        if (D.25768 != 0) goto <D.25769>; else goto <D.25770>;
        <D.25769>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 571, "inflated_method->klass == inflated_class");
        <D.25770>:
        D.25736 = inflated_method;
        return D.25736;
      }
      <D.24528>:
      {
        struct MonoGSharedVtMethodInfo * info;
        struct MonoGSharedVtMethodInfo * res;
        int i;

        info = data;
        res = monoeg_malloc0 (8);
        D.25771 = monoeg_g_ptr_array_new ();
        res->entries = D.25771;
        i = 0;
        goto <D.24535>;
        <D.24534>:
        {
          struct MonoRuntimeGenericContextInfoTemplate * otemplate;
          struct MonoRuntimeGenericContextInfoTemplate * template;

          D.25772 = info->entries;
          D.25773 = D.25772->pdata;
          i.39 = (unsigned int) i;
          D.25775 = i.39 * 4;
          D.25776 = D.25773 + D.25775;
          otemplate = *D.25776;
          template = monoeg_malloc0 (12);
          memcpy (template, otemplate, 12);
          D.25777 = inflate_info (template, context, class, 0);
          template->data = D.25777;
          D.25778 = res->entries;
          monoeg_g_ptr_array_add (D.25778, template);
        }
        i = i + 1;
        <D.24535>:
        i.40 = (unsigned int) i;
        D.25772 = info->entries;
        D.25780 = D.25772->len;
        if (i.40 < D.25780) goto <D.24534>; else goto <D.24536>;
        <D.24536>:
        D.25736 = res;
        return D.25736;
      }
      <D.24537>:
      <D.24538>:
      {
        struct MonoJumpInfoGSharedVtCall * info;
        struct MonoMethod * method;
        struct MonoMethod * inflated_method;
        struct MonoType * inflated_type;
        struct MonoClass * inflated_class;
        struct MonoJumpInfoGSharedVtCall * res;

        info = data;
        method = info->method;
        D.25781 = method->klass;
        D.25782 = &D.25781->byval_arg;
        inflated_type = mono_class_inflate_generic_type (D.25782, context);
        inflated_class = mono_class_from_mono_type (inflated_type);
        res = monoeg_malloc0 (8);
        D.25783 = info->sig;
        res->sig = D.25783;
        mono_metadata_free_type (inflated_type);
        mono_class_init (inflated_class);
        D.25784 = BIT_FIELD_REF <*method, 8, 160>;
        D.25785 = D.25784 & 124;
        D.25786 = D.25785 != 0;
        D.25787 = (long int) D.25786;
        D.25788 = __builtin_expect (D.25787, 0);
        if (D.25788 != 0) goto <D.25789>; else goto <D.25790>;
        <D.25789>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 616, "!method->wrapper_type");
        <D.25790>:
        D.25791 = inflated_class->byval_arg.type;
        D.25792 = D.25791 == 20;
        D.25793 = D.25791 == 29;
        D.25794 = D.25792 | D.25793;
        if (D.25794 != 0) goto <D.25795>; else goto <D.25796>;
        <D.25795>:
        D.25797 = method->name;
        D.25798 = method->signature;
        inflated_method = mono_method_search_in_array_class (inflated_class, D.25797, D.25798);
        goto <D.25799>;
        <D.25796>:
        inflated_method = mono_class_inflate_generic_method (method, context);
        <D.25799>:
        D.25800 = inflated_method->klass;
        mono_class_init (D.25800);
        D.25800 = inflated_method->klass;
        D.25801 = D.25800 != inflated_class;
        D.25802 = (long int) D.25801;
        D.25803 = __builtin_expect (D.25802, 0);
        if (D.25803 != 0) goto <D.25804>; else goto <D.25805>;
        <D.25804>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 626, "inflated_method->klass == inflated_class");
        <D.25805>:
        res->method = inflated_method;
        D.25736 = res;
        return D.25736;
      }
      <D.24545>:
      <D.24546>:
      {
        struct MonoClassField * field;
        struct MonoType * inflated_type;
        struct MonoClass * inflated_class;
        int i;
        void * dummy;

        try
          {
            field = data;
            D.25806 = field->parent;
            D.25807 = &D.25806->byval_arg;
            inflated_type = mono_class_inflate_generic_type (D.25807, context);
            inflated_class = mono_class_from_mono_type (inflated_type);
            field.41 = (int) field;
            D.25806 = field->parent;
            D.25809 = D.25806->fields;
            D.25810 = (int) D.25809;
            D.25811 = field.41 - D.25810;
            i = D.25811 /[ex] 16;
            dummy = 0B;
            mono_metadata_free_type (inflated_type);
            mono_class_get_fields (inflated_class, &dummy);
            D.25812 = inflated_class->fields;
            D.25813 = D.25812 == 0B;
            D.25814 = (long int) D.25813;
            D.25815 = __builtin_expect (D.25814, 0);
            if (D.25815 != 0) goto <D.25816>; else goto <D.25817>;
            <D.25816>:
            monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 643, "inflated_class->fields");
            <D.25817>:
            D.25812 = inflated_class->fields;
            i.42 = (unsigned int) i;
            D.25819 = i.42 * 16;
            D.25736 = D.25812 + D.25819;
            return D.25736;
          }
        finally
          {
            dummy = {CLOBBER};
          }
      }
      <D.24552>:
      {
        struct MonoMethodSignature * sig;
        struct MonoMethodSignature * isig;
        struct MonoError error;

        try
          {
            sig = data;
            isig = mono_inflate_generic_signature (sig, context, &error);
            D.25820 = mono_error_ok (&error);
            D.25821 = D.25820 == 0;
            D.25822 = (long int) D.25821;
            D.25823 = __builtin_expect (D.25822, 0);
            if (D.25823 != 0) goto <D.25824>; else goto <D.25825>;
            <D.25824>:
            monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 653, "mono_error_ok (&error)");
            <D.25825>:
            D.25736 = isig;
            return D.25736;
          }
        finally
          {
            error = {CLOBBER};
          }
      }
      <D.24556>:
      monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 658);
      D.25736 = 0B;
      return D.25736;
    }
  finally
    {
      error = {CLOBBER};
    }
}


info_equal (void * data1, void * data2, MonoRgctxInfoType info_type)
{
  gboolean D.25830;
  struct MonoClass * D.25831;
  struct MonoClass * D.25832;
  _Bool D.25833;
  _Bool D.25834;

  switch (info_type) <default: <D.24906>, case 0: <D.24881>, case 1: <D.24882>, case 2: <D.24883>, case 3: <D.24884>, case 4: <D.24885>, case 5: <D.24894>, case 6: <D.24896>, case 7: <D.24897>, case 8: <D.24899>, case 9: <D.24900>, case 10: <D.24901>, case 11: <D.24902>, case 12: <D.24886>, case 13: <D.24887>, case 14: <D.24888>, case 15: <D.24898>, case 16: <D.24903>, case 17: <D.24904>, case 18: <D.24905>, case 19: <D.24889>, case 20: <D.24895>, case 22: <D.24890>, case 23: <D.24891>, case 24: <D.24892>, case 25: <D.24893>>
  <D.24881>:
  <D.24882>:
  <D.24883>:
  <D.24884>:
  <D.24885>:
  <D.24886>:
  <D.24887>:
  <D.24888>:
  <D.24889>:
  <D.24890>:
  <D.24891>:
  <D.24892>:
  <D.24893>:
  D.25831 = mono_class_from_mono_type (data1);
  D.25832 = mono_class_from_mono_type (data2);
  D.25833 = D.25831 == D.25832;
  D.25830 = (gboolean) D.25833;
  return D.25830;
  <D.24894>:
  <D.24895>:
  <D.24896>:
  <D.24897>:
  <D.24898>:
  <D.24899>:
  <D.24900>:
  <D.24901>:
  <D.24902>:
  <D.24903>:
  <D.24904>:
  <D.24905>:
  D.25834 = data1 == data2;
  D.25830 = (gboolean) D.25834;
  return D.25830;
  <D.24906>:
  monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 1644);
  D.25830 = 0;
  return D.25830;
}


free_inflated_info (MonoRgctxInfoType info_type, void * info)
{
  if (info == 0B) goto <D.25836>; else goto <D.25837>;
  <D.25836>:
  return;
  <D.25837>:
  switch (info_type) <default: <D.24568>, case 0: <D.24561>, case 1: <D.24562>, case 2: <D.24563>, case 3: <D.24564>, case 4: <D.24565>, case 12: <D.24566>>
  <D.24561>:
  <D.24562>:
  <D.24563>:
  <D.24564>:
  <D.24565>:
  <D.24566>:
  mono_metadata_free_type (info);
  goto <D.24567>;
  <D.24568>:
  goto <D.24567>;
  <D.24567>:
}


register_info (struct MonoClass * class, int type_argc, void * data, MonoRgctxInfoType info_type)
{
  void * D.25840;
  struct MonoGenericClass * D.25842;
  void * D.25847;
  struct MonoImage * D.25849;
  struct MonoClass * D.25850;
  struct MonoType * D.25851;
  int D.25852;
  int i;
  struct MonoRuntimeGenericContextTemplate * template;
  struct MonoClass * parent;
  struct MonoRuntimeGenericContextInfoTemplate * oti;

  template = mono_class_get_runtime_generic_context_template (class);
  i = 0;
  oti = get_info_templates (template, type_argc);
  goto <D.24870>;
  <D.24869>:
  D.25840 = oti->data;
  if (D.25840 == 0B) goto <D.24868>; else goto <D.25841>;
  <D.25841>:
  i = i + 1;
  oti = oti->next;
  <D.24870>:
  if (oti != 0B) goto <D.24869>; else goto <D.24868>;
  <D.24868>:
  parent = class->parent;
  goto <D.24875>;
  <D.24874>:
  {
    struct MonoRuntimeGenericContextTemplate * parent_template;
    struct MonoRuntimeGenericContextInfoTemplate * oti;

    D.25842 = parent->generic_class;
    if (D.25842 != 0B) goto <D.25843>; else goto <D.25844>;
    <D.25843>:
    D.25842 = parent->generic_class;
    parent = D.25842->container_class;
    <D.25844>:
    parent_template = mono_class_get_runtime_generic_context_template (parent);
    oti = rgctx_template_get_other_slot (parent_template, type_argc, i);
    if (oti != 0B) goto <D.25845>; else goto <D.25846>;
    <D.25845>:
    D.25847 = oti->data;
    if (D.25847 != 0B) goto <D.24873>; else goto <D.25848>;
    <D.25848>:
    <D.25846>:
    D.25849 = parent->image;
    D.25850 = mono_defaults.object_class;
    D.25851 = &D.25850->byval_arg;
    rgctx_template_set_slot (D.25849, parent_template, type_argc, i, D.25851, 0);
    parent = parent->parent;
  }
  <D.24875>:
  if (parent != 0B) goto <D.24874>; else goto <D.24873>;
  <D.24873>:
  fill_in_rgctx_template_slot (class, type_argc, i, data, info_type);
  D.25852 = i;
  return D.25852;
}


fill_in_rgctx_template_slot (struct MonoClass * class, int type_argc, int index, void * data, MonoRgctxInfoType info_type)
{
  struct MonoImage * D.25854;
  struct GHashTable * generic_subclass_hash.43;
  _Bool D.25859;
  long int D.25860;
  long int D.25861;
  struct MonoClass * D.25864;
  unsigned int index.44;
  void * D.25866;
  _Bool D.25867;
  long int D.25868;
  long int D.25869;
  struct MonoRuntimeGenericContextTemplate * template;
  struct MonoClass * subclass;

  template = mono_class_get_runtime_generic_context_template (class);
  D.25854 = class->image;
  rgctx_template_set_slot (D.25854, template, type_argc, index, data, info_type);
  generic_subclass_hash.43 = generic_subclass_hash;
  if (generic_subclass_hash.43 != 0B) goto <D.25856>; else goto <D.25857>;
  <D.25856>:
  generic_subclass_hash.43 = generic_subclass_hash;
  subclass = monoeg_g_hash_table_lookup (generic_subclass_hash.43, class);
  goto <D.25858>;
  <D.25857>:
  subclass = 0B;
  <D.25858>:
  goto <D.24821>;
  <D.24820>:
  {
    struct MonoRuntimeGenericContextInfoTemplate subclass_oti;
    struct MonoRuntimeGenericContextTemplate * subclass_template;

    try
      {
        subclass_template = class_lookup_rgctx_template (subclass);
        D.25859 = subclass_template == 0B;
        D.25860 = (long int) D.25859;
        D.25861 = __builtin_expect (D.25860, 0);
        if (D.25861 != 0) goto <D.25862>; else goto <D.25863>;
        <D.25862>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1509, "subclass_template");
        <D.25863>:
        D.25864 = subclass->parent;
        index.44 = (unsigned int) index;
        subclass_oti = class_get_rgctx_template_oti (D.25864, type_argc, index.44, 0, 0, 0B); [return slot optimization]
        D.25866 = subclass_oti.data;
        D.25867 = D.25866 == 0B;
        D.25868 = (long int) D.25867;
        D.25869 = __builtin_expect (D.25868, 0);
        if (D.25869 != 0) goto <D.25870>; else goto <D.25871>;
        <D.25870>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1512, "subclass_oti.data");
        <D.25871>:
        D.25866 = subclass_oti.data;
        fill_in_rgctx_template_slot (subclass, type_argc, index, D.25866, info_type);
        subclass = subclass_template->next_subclass;
      }
    finally
      {
        subclass_oti = {CLOBBER};
      }
  }
  <D.24821>:
  if (subclass != 0B) goto <D.24820>; else goto <D.24822>;
  <D.24822>:
}


mono_class_rgctx_get_array_size (int n, gboolean mrgctx)
{
  unsigned int n.45;
  _Bool D.25873;
  long int D.25874;
  long int D.25875;
  int D.25880;

  n.45 = (unsigned int) n;
  D.25873 = n.45 > 29;
  D.25874 = (long int) D.25873;
  D.25875 = __builtin_expect (D.25874, 0);
  if (D.25875 != 0) goto <D.25876>; else goto <D.25877>;
  <D.25876>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1784, "n >= 0 && n < 30");
  <D.25877>:
  if (mrgctx != 0) goto <D.25878>; else goto <D.25879>;
  <D.25878>:
  D.25880 = 6 << n;
  return D.25880;
  <D.25879>:
  D.25880 = 4 << n;
  return D.25880;
}


mono_class_fill_runtime_generic_context (struct MonoVTable * class_vtable, guint8 * caller, guint32 slot)
{
  union mono_mutex_t * D.25882;
  _Bool D.25885;
  long int D.25886;
  long int D.25887;
  int inited.46;
  int num_alloced.47;
  int num_alloced.48;
  _Bool D.25899;
  long int D.25900;
  long int D.25901;
  void * D.25904;
  static gboolean inited = 0;
  static int num_alloced = 0;
  struct MonoDomain * domain;
  void * * rgctx;
  void * info;

  domain = class_vtable->domain;
  {
    int ret;

    D.25882 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.25882);
    if (ret != 0) goto <D.25883>; else goto <D.25884>;
    <D.25883>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.25884>:
    D.25885 = ret != 0;
    D.25886 = (long int) D.25885;
    D.25887 = __builtin_expect (D.25886, 0);
    if (D.25887 != 0) goto <D.25888>; else goto <D.25889>;
    <D.25888>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1925, "ret == 0");
    <D.25889>:
  }
  inited.46 = inited;
  if (inited.46 == 0) goto <D.25891>; else goto <D.25892>;
  <D.25891>:
  mono_counters_register ("RGCTX num alloced", 2048, &num_alloced);
  inited = 1;
  <D.25892>:
  rgctx = class_vtable->runtime_generic_context;
  if (rgctx == 0B) goto <D.25893>; else goto <D.25894>;
  <D.25893>:
  rgctx = alloc_rgctx_array (domain, 0, 0);
  class_vtable->runtime_generic_context = rgctx;
  num_alloced.47 = num_alloced;
  num_alloced.48 = num_alloced.47 + 1;
  num_alloced = num_alloced.48;
  <D.25894>:
  {
    int ret;

    D.25882 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.25882);
    if (ret != 0) goto <D.25897>; else goto <D.25898>;
    <D.25897>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.25898>:
    D.25899 = ret != 0;
    D.25900 = (long int) D.25899;
    D.25901 = __builtin_expect (D.25900, 0);
    if (D.25901 != 0) goto <D.25902>; else goto <D.25903>;
    <D.25902>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1939, "ret == 0");
    <D.25903>:
  }
  info = fill_runtime_generic_context (class_vtable, rgctx, caller, slot, 0B);
  D.25904 = info;
  return D.25904;
}


alloc_rgctx_array (struct MonoDomain * domain, int n, gboolean is_mrgctx)
{
  int D.25906;
  unsigned int D.25907;
  unsigned int D.25908;
  unsigned int size.49;
  int inited.50;
  int mrgctx_num_alloced.51;
  int mrgctx_num_alloced.52;
  int mrgctx_bytes_alloced.53;
  int mrgctx_bytes_alloced.54;
  int rgctx_num_alloced.55;
  int rgctx_num_alloced.56;
  int rgctx_bytes_alloced.57;
  int rgctx_bytes_alloced.58;
  void * * D.25924;
  static gboolean inited = 0;
  static int rgctx_num_alloced = 0;
  static int rgctx_bytes_alloced = 0;
  static int mrgctx_num_alloced = 0;
  static int mrgctx_bytes_alloced = 0;
  int size;
  void * array;

  D.25906 = mono_class_rgctx_get_array_size (n, is_mrgctx);
  D.25907 = (unsigned int) D.25906;
  D.25908 = D.25907 * 4;
  size = (int) D.25908;
  size.49 = (unsigned int) size;
  array = mono_domain_alloc0 (domain, size.49);
  inited.50 = inited;
  if (inited.50 == 0) goto <D.25911>; else goto <D.25912>;
  <D.25911>:
  mono_counters_register ("RGCTX num arrays alloced", 2048, &rgctx_num_alloced);
  mono_counters_register ("RGCTX bytes alloced", 2048, &rgctx_bytes_alloced);
  mono_counters_register ("MRGCTX num arrays alloced", 2048, &mrgctx_num_alloced);
  mono_counters_register ("MRGCTX bytes alloced", 2048, &mrgctx_bytes_alloced);
  inited = 1;
  <D.25912>:
  if (is_mrgctx != 0) goto <D.25913>; else goto <D.25914>;
  <D.25913>:
  mrgctx_num_alloced.51 = mrgctx_num_alloced;
  mrgctx_num_alloced.52 = mrgctx_num_alloced.51 + 1;
  mrgctx_num_alloced = mrgctx_num_alloced.52;
  mrgctx_bytes_alloced.53 = mrgctx_bytes_alloced;
  mrgctx_bytes_alloced.54 = mrgctx_bytes_alloced.53 + size;
  mrgctx_bytes_alloced = mrgctx_bytes_alloced.54;
  goto <D.25919>;
  <D.25914>:
  rgctx_num_alloced.55 = rgctx_num_alloced;
  rgctx_num_alloced.56 = rgctx_num_alloced.55 + 1;
  rgctx_num_alloced = rgctx_num_alloced.56;
  rgctx_bytes_alloced.57 = rgctx_bytes_alloced;
  rgctx_bytes_alloced.58 = rgctx_bytes_alloced.57 + size;
  rgctx_bytes_alloced = rgctx_bytes_alloced.58;
  <D.25919>:
  D.25924 = array;
  return D.25924;
}


fill_runtime_generic_context (struct MonoVTable * class_vtable, void * * rgctx, guint8 * caller, guint32 slot, struct MonoGenericInst * method_inst)
{
  struct MonoGenericContext * iftmp.59;
  struct MonoGenericClass * D.25927;
  struct MonoGenericInst * iftmp.60;
  _Bool D.25935;
  long int D.25936;
  long int D.25937;
  union mono_mutex_t * D.25940;
  _Bool D.25943;
  long int D.25944;
  long int D.25945;
  _Bool D.25948;
  int D.25949;
  unsigned int size.61;
  unsigned int D.25953;
  _Bool D.25954;
  _Bool D.25955;
  int D.25959;
  int D.25960;
  unsigned int D.25961;
  unsigned int first_slot.62;
  unsigned int D.25965;
  unsigned int offset.63;
  unsigned int D.25967;
  unsigned int D.25968;
  unsigned int rgctx_index.64;
  unsigned int D.25970;
  void * * D.25971;
  _Bool D.25976;
  long int D.25977;
  long int D.25978;
  void * D.25981;
  unsigned int offset.65;
  unsigned int D.25983;
  void * * D.25984;
  void * D.25985;
  int D.25988;
  void * * D.25989;
  int D.25990;
  void * D.25991;
  _Bool D.25992;
  long int D.25993;
  long int D.25994;
  _Bool D.25999;
  long int D.26000;
  long int D.26001;
  struct MonoClass * D.26004;
  int iftmp.66;
  <unnamed-unsigned:22> D.26008;
  _Bool D.26012;
  long int D.26013;
  long int D.26014;
  _Bool D.26022;
  long int D.26023;
  long int D.26024;
  int do_free.67;
  <unnamed type> D.26030;
  void * D.26031;
  void * info;
  int i;
  int first_slot;
  int size;
  struct MonoDomain * domain;
  struct MonoClass * class;
  struct MonoGenericContext * class_context;
  struct MonoRuntimeGenericContextInfoTemplate oti;
  struct MonoGenericContext context;
  int rgctx_index;
  gboolean do_free;

  try
    {
      domain = class_vtable->domain;
      class = class_vtable->klass;
      D.25927 = class->generic_class;
      if (D.25927 != 0B) goto <D.25928>; else goto <D.25929>;
      <D.25928>:
      D.25927 = class->generic_class;
      iftmp.59 = &D.25927->context;
      goto <D.25930>;
      <D.25929>:
      iftmp.59 = 0B;
      <D.25930>:
      class_context = iftmp.59;
      if (class_context != 0B) goto <D.25932>; else goto <D.25933>;
      <D.25932>:
      iftmp.60 = class_context->class_inst;
      goto <D.25934>;
      <D.25933>:
      iftmp.60 = 0B;
      <D.25934>:
      context.class_inst = iftmp.60;
      context.method_inst = method_inst;
      D.25935 = rgctx == 0B;
      D.25936 = (long int) D.25935;
      D.25937 = __builtin_expect (D.25936, 0);
      if (D.25937 != 0) goto <D.25938>; else goto <D.25939>;
      <D.25938>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1840, "rgctx");
      <D.25939>:
      {
        int ret;

        D.25940 = &domain->lock.mutex;
        ret = pthread_mutex_lock (D.25940);
        if (ret != 0) goto <D.25941>; else goto <D.25942>;
        <D.25941>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
        <D.25942>:
        D.25943 = ret != 0;
        D.25944 = (long int) D.25943;
        D.25945 = __builtin_expect (D.25944, 0);
        if (D.25945 != 0) goto <D.25946>; else goto <D.25947>;
        <D.25946>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1842, "ret == 0");
        <D.25947>:
      }
      first_slot = 0;
      D.25948 = method_inst != 0B;
      D.25949 = (int) D.25948;
      size = mono_class_rgctx_get_array_size (0, D.25949);
      if (method_inst != 0B) goto <D.25950>; else goto <D.25951>;
      <D.25950>:
      size.61 = (unsigned int) size;
      D.25953 = size.61 + 4294967294;
      size = (int) D.25953;
      <D.25951>:
      i = 0;
      <D.24993>:
      {
        int offset;

        D.25948 = method_inst != 0B;
        D.25954 = i == 0;
        D.25955 = D.25948 & D.25954;
        if (D.25955 != 0) goto <D.25956>; else goto <D.25957>;
        <D.25956>:
        offset = 2;
        goto <D.25958>;
        <D.25957>:
        offset = 0;
        <D.25958>:
        D.25959 = first_slot + size;
        D.25960 = D.25959 + -1;
        D.25961 = (unsigned int) D.25960;
        if (D.25961 > slot) goto <D.25962>; else goto <D.25963>;
        <D.25962>:
        first_slot.62 = (unsigned int) first_slot;
        D.25965 = slot - first_slot.62;
        offset.63 = (unsigned int) offset;
        D.25967 = D.25965 + offset.63;
        D.25968 = D.25967 + 1;
        rgctx_index = (int) D.25968;
        rgctx_index.64 = (unsigned int) rgctx_index;
        D.25970 = rgctx_index.64 * 4;
        D.25971 = rgctx + D.25970;
        info = *D.25971;
        if (info != 0B) goto <D.25972>; else goto <D.25973>;
        <D.25972>:
        {
          int ret;

          D.25940 = &domain->lock.mutex;
          ret = pthread_mutex_unlock (D.25940);
          if (ret != 0) goto <D.25974>; else goto <D.25975>;
          <D.25974>:
          monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
          <D.25975>:
          D.25976 = ret != 0;
          D.25977 = (long int) D.25976;
          D.25978 = __builtin_expect (D.25977, 0);
          if (D.25978 != 0) goto <D.25979>; else goto <D.25980>;
          <D.25979>:
          monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1863, "ret == 0");
          <D.25980>:
        }
        D.25981 = info;
        return D.25981;
        <D.25973>:
        goto <D.24992>;
        <D.25963>:
        offset.65 = (unsigned int) offset;
        D.25983 = offset.65 * 4;
        D.25984 = rgctx + D.25983;
        D.25985 = *D.25984;
        if (D.25985 == 0B) goto <D.25986>; else goto <D.25987>;
        <D.25986>:
        offset.65 = (unsigned int) offset;
        D.25983 = offset.65 * 4;
        D.25984 = rgctx + D.25983;
        D.25988 = i + 1;
        D.25948 = method_inst != 0B;
        D.25949 = (int) D.25948;
        D.25989 = alloc_rgctx_array (domain, D.25988, D.25949);
        *D.25984 = D.25989;
        <D.25987>:
        offset.65 = (unsigned int) offset;
        D.25983 = offset.65 * 4;
        D.25984 = rgctx + D.25983;
        rgctx = *D.25984;
        D.25990 = size + -1;
        first_slot = D.25990 + first_slot;
        D.25988 = i + 1;
        D.25948 = method_inst != 0B;
        D.25949 = (int) D.25948;
        size = mono_class_rgctx_get_array_size (D.25988, D.25949);
      }
      i = i + 1;
      goto <D.24993>;
      <D.24992>:
      rgctx_index.64 = (unsigned int) rgctx_index;
      D.25970 = rgctx_index.64 * 4;
      D.25971 = rgctx + D.25970;
      D.25991 = *D.25971;
      D.25992 = D.25991 != 0B;
      D.25993 = (long int) D.25992;
      D.25994 = __builtin_expect (D.25993, 0);
      if (D.25994 != 0) goto <D.25995>; else goto <D.25996>;
      <D.25995>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1875, "!rgctx [rgctx_index]");
      <D.25996>:
      {
        int ret;

        D.25940 = &domain->lock.mutex;
        ret = pthread_mutex_unlock (D.25940);
        if (ret != 0) goto <D.25997>; else goto <D.25998>;
        <D.25997>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
        <D.25998>:
        D.25999 = ret != 0;
        D.26000 = (long int) D.25999;
        D.26001 = __builtin_expect (D.26000, 0);
        if (D.26001 != 0) goto <D.26002>; else goto <D.26003>;
        <D.26002>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1877, "ret == 0");
        <D.26003>:
      }
      D.26004 = get_shared_class (class);
      if (method_inst != 0B) goto <D.26006>; else goto <D.26007>;
      <D.26006>:
      D.26008 = method_inst->type_argc;
      iftmp.66 = (int) D.26008;
      goto <D.26009>;
      <D.26007>:
      iftmp.66 = 0;
      <D.26009>:
      oti = class_get_rgctx_template_oti (D.26004, iftmp.66, slot, 1, 1, &do_free);
      info = instantiate_info (domain, &oti, &context, class, caller);
      {
        int ret;

        D.25940 = &domain->lock.mutex;
        ret = pthread_mutex_lock (D.25940);
        if (ret != 0) goto <D.26010>; else goto <D.26011>;
        <D.26010>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
        <D.26011>:
        D.26012 = ret != 0;
        D.26013 = (long int) D.26012;
        D.26014 = __builtin_expect (D.26013, 0);
        if (D.26014 != 0) goto <D.26015>; else goto <D.26016>;
        <D.26015>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1890, "ret == 0");
        <D.26016>:
      }
      rgctx_index.64 = (unsigned int) rgctx_index;
      D.25970 = rgctx_index.64 * 4;
      D.25971 = rgctx + D.25970;
      D.25991 = *D.25971;
      if (D.25991 != 0B) goto <D.26017>; else goto <D.26018>;
      <D.26017>:
      rgctx_index.64 = (unsigned int) rgctx_index;
      D.25970 = rgctx_index.64 * 4;
      D.25971 = rgctx + D.25970;
      info = *D.25971;
      goto <D.26019>;
      <D.26018>:
      rgctx_index.64 = (unsigned int) rgctx_index;
      D.25970 = rgctx_index.64 * 4;
      D.25971 = rgctx + D.25970;
      *D.25971 = info;
      <D.26019>:
      {
        int ret;

        D.25940 = &domain->lock.mutex;
        ret = pthread_mutex_unlock (D.25940);
        if (ret != 0) goto <D.26020>; else goto <D.26021>;
        <D.26020>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
        <D.26021>:
        D.26022 = ret != 0;
        D.26023 = (long int) D.26022;
        D.26024 = __builtin_expect (D.26023, 0);
        if (D.26024 != 0) goto <D.26025>; else goto <D.26026>;
        <D.26025>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1899, "ret == 0");
        <D.26026>:
      }
      do_free.67 = do_free;
      if (do_free.67 != 0) goto <D.26028>; else goto <D.26029>;
      <D.26028>:
      D.26030 = oti.info_type;
      D.26031 = oti.data;
      free_inflated_info (D.26030, D.26031);
      <D.26029>:
      D.25981 = info;
      return D.25981;
    }
  finally
    {
      oti = {CLOBBER};
      context = {CLOBBER};
      do_free = {CLOBBER};
    }
}


instantiate_info (struct MonoDomain * domain, struct MonoRuntimeGenericContextInfoTemplate * oti, struct MonoGenericContext * context, struct MonoClass * class, guint8 * caller)
{
  void * D.26034;
  void * D.26037;
  <unnamed type> D.26038;
  _Bool D.26039;
  long int D.26040;
  long int D.26041;
  int D.26046;
  struct MonoMethod * D.26047;
  struct MonoClass * D.26049;
  unsigned char D.26050;
  unsigned char D.26051;
  struct MonoType * D.26053;
  short unsigned int D.26054;
  int D.26055;
  int D.26056;
  int D.26058;
  unsigned int D.26059;
  unsigned int D.26060;
  unsigned char D.26061;
  unsigned char D.26062;
  _Bool D.26063;
  long int D.26064;
  long int D.26065;
  struct MonoGenericInst * D.26068;
  _Bool D.26069;
  long int D.26070;
  long int D.26071;
  struct MonoClass * D.26074;
  struct MonoException * D.26077;
  unsigned char D.26078;
  unsigned char D.26079;
  _Bool D.26080;
  long int D.26081;
  long int D.26082;
  struct MonoGenericInst * D.26085;
  _Bool D.26086;
  long int D.26087;
  long int D.26088;
  _Bool D.26091;
  long int D.26092;
  long int D.26093;
  struct MonoDomain * D.26096;
  void * D.26097;
  _Bool D.26098;
  long int D.26099;
  long int D.26100;
  _Bool D.26103;
  long int D.26104;
  long int D.26105;
  struct MonoGenericSharingContext * D.26108;
  _Bool D.26109;
  unsigned char D.26110;
  unsigned char D.26111;
  _Bool D.26112;
  long int D.26113;
  long int D.26114;
  struct MonoClass * D.26124;
  struct MonoClass * D.26125;
  struct MonoClass * D.26126;
  int D.24787;
  int iftmp.68;
  int D.24786;
  const char[7] * D.26131;
  unsigned char D.26132;
  int D.26133;
  unsigned char D.26134;
  int D.26135;
  _Bool D.26136;
  _Bool D.26137;
  _Bool D.26138;
  const unsigned char * D.26141;
  unsigned char D.26142;
  int D.26143;
  const unsigned char * D.26144;
  unsigned char D.26145;
  int D.26146;
  _Bool D.26147;
  _Bool D.26148;
  const unsigned char * D.26151;
  unsigned char D.26152;
  int D.26153;
  const unsigned char * D.26154;
  unsigned char D.26155;
  int D.26156;
  _Bool D.26157;
  _Bool D.26158;
  const unsigned char * D.26161;
  unsigned char D.26162;
  int D.26163;
  const unsigned char * D.26164;
  unsigned char D.26165;
  int D.26166;
  const char * D.26168;
  unsigned int D.26170;
  unsigned int D.26171;
  int imt_slot.69;
  int D.26175;
  int D.26177;
  int D.26178;
  unsigned int D.26179;
  unsigned int D.26180;
  struct MonoDomain * D.26184;
  void * D.26185;
  _Bool D.26186;
  long int D.26187;
  long int D.26188;
  _Bool D.26191;
  long int D.26192;
  long int D.26193;
  struct MonoDomain * D.26196;
  void * D.26197;
  _Bool D.26200;
  long int D.26201;
  long int D.26202;
  _Bool D.26205;
  _Bool D.26206;
  _Bool D.26207;
  struct MonoGenericSharingContext * D.26212;
  struct MonoMethodSignature * D.26216;
  struct MonoMethod * D.26220;
  void * D.26221;
  struct MonoGenericSharingContext * D.26222;
  struct GPtrArray * D.26223;
  unsigned int D.26224;
  unsigned int D.26225;
  unsigned int D.26226;
  void * * D.26227;
  unsigned int i.70;
  unsigned int D.26229;
  void * * D.26230;
  <unnamed type> D.26231;
  int align.71;
  unsigned int align.72;
  int D.26236;
  int D.26241;
  int D.26242;
  void * offset.73;
  void * D.26244;
  unsigned int i.74;
  void * data;
  gboolean temporary;

  D.26034 = oti->data;
  if (D.26034 == 0B) goto <D.26035>; else goto <D.26036>;
  <D.26035>:
  D.26037 = 0B;
  return D.26037;
  <D.26036>:
  D.26038 = oti->info_type;
  switch (D.26038) <default: <D.24732>, case 0: <D.24727>, case 1: <D.24728>, case 2: <D.24729>, case 12: <D.24730>>
  <D.24727>:
  <D.24728>:
  <D.24729>:
  <D.24730>:
  temporary = 1;
  goto <D.24731>;
  <D.24732>:
  temporary = 0;
  <D.24731>:
  data = inflate_info (oti, context, class, temporary);
  D.26038 = oti->info_type;
  switch (D.26038) <default: <D.24808>, case 0: <D.24733>, case 1: <D.24734>, case 2: <D.24735>, case 3: <D.24745>, case 4: <D.24746>, case 5: <D.24747>, case 6: <D.24748>, case 7: <D.24752>, case 8: <D.24755>, case 9: <D.24758>, case 10: <D.24750>, case 11: <D.24751>, case 12: <D.24736>, case 13: <D.24737>, case 14: <D.24738>, case 15: <D.24753>, case 16: <D.24766>, case 17: <D.24767>, case 18: <D.24760>, case 19: <D.24739>, case 20: <D.24793>, case 22: <D.24740>, case 23: <D.24741>, case 24: <D.24742>, case 25: <D.24743>>
  <D.24733>:
  <D.24734>:
  <D.24735>:
  <D.24736>:
  <D.24737>:
  <D.24738>:
  <D.24739>:
  <D.24740>:
  <D.24741>:
  <D.24742>:
  <D.24743>:
  {
    struct MonoClass * arg_class;

    arg_class = mono_class_from_mono_type (data);
    D.26038 = oti->info_type;
    free_inflated_info (D.26038, data);
    D.26039 = arg_class == 0B;
    D.26040 = (long int) D.26039;
    D.26041 = __builtin_expect (D.26040, 0);
    if (D.26041 != 0) goto <D.26042>; else goto <D.26043>;
    <D.26042>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1239, "arg_class");
    <D.26043>:
    D.26038 = oti->info_type;
    if (D.26038 == 1) goto <D.26044>; else goto <D.26045>;
    <D.26044>:
    mono_class_compute_gc_descriptor (arg_class);
    <D.26045>:
    D.26038 = oti->info_type;
    D.26037 = class_type_info (domain, arg_class, D.26038);
    return D.26037;
  }
  <D.24745>:
  D.26037 = data;
  return D.26037;
  <D.24746>:
  D.26037 = mono_type_get_object (domain, data);
  return D.26037;
  <D.24747>:
  D.26037 = data;
  return D.26037;
  <D.24748>:
  {
    void * addr;

    addr = mono_compile_method (data);
    D.26046 = mono_method_needs_static_rgctx_invoke (data, 0);
    D.26037 = mini_add_method_trampoline (0B, data, addr, D.26046, 0);
    return D.26037;
  }
  <D.24750>:
  D.26047 = mono_marshal_get_remoting_invoke_with_check (data);
  D.26037 = mono_compile_method (D.26047);
  return D.26037;
  <D.24751>:
  D.26037 = mono_domain_alloc0 (domain, 4);
  return D.26037;
  <D.24752>:
  D.26037 = data;
  return D.26037;
  <D.24753>:
  {
    struct MonoClassField * field;

    field = data;
    D.26049 = field->parent;
    D.26050 = BIT_FIELD_REF <*D.26049, 8, 160>;
    D.26051 = D.26050 & 8;
    if (D.26051 != 0) goto <D.26052>; else goto <D.26048>;
    <D.26052>:
    D.26053 = field->type;
    D.26054 = D.26053->attrs;
    D.26055 = (int) D.26054;
    D.26056 = D.26055 & 16;
    if (D.26056 == 0) goto <D.26057>; else goto <D.26048>;
    <D.26057>:
    D.26058 = field->offset;
    D.26059 = (unsigned int) D.26058;
    D.26060 = D.26059 + 4294967288;
    D.26037 = (void *) D.26060;
    return D.26037;
    <D.26048>:
    D.26058 = field->offset;
    D.26037 = (void *) D.26058;
    return D.26037;
  }
  <D.24755>:
  {
    struct MonoMethodInflated * method;
    struct MonoVTable * vtable;

    method = data;
    D.26061 = BIT_FIELD_REF <*method, 8, 168>;
    D.26062 = D.26061 & 16;
    D.26063 = D.26062 == 0;
    D.26064 = (long int) D.26063;
    D.26065 = __builtin_expect (D.26064, 0);
    if (D.26065 != 0) goto <D.26066>; else goto <D.26067>;
    <D.26066>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1281, "method->method.method.is_inflated");
    <D.26067>:
    D.26068 = method->context.method_inst;
    D.26069 = D.26068 == 0B;
    D.26070 = (long int) D.26069;
    D.26071 = __builtin_expect (D.26070, 0);
    if (D.26071 != 0) goto <D.26072>; else goto <D.26073>;
    <D.26072>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1282, "method->context.method_inst");
    <D.26073>:
    D.26074 = method->method.method.klass;
    vtable = mono_class_vtable (domain, D.26074);
    if (vtable == 0B) goto <D.26075>; else goto <D.26076>;
    <D.26075>:
    D.26074 = method->method.method.klass;
    D.26077 = mono_class_get_exception_for_failure (D.26074);
    mono_raise_exception (D.26077);
    <D.26076>:
    D.26068 = method->context.method_inst;
    D.26037 = mono_method_lookup_rgctx (vtable, D.26068);
    return D.26037;
  }
  <D.24758>:
  {
    struct MonoMethodInflated * method;

    method = data;
    D.26078 = BIT_FIELD_REF <*method, 8, 168>;
    D.26079 = D.26078 & 16;
    D.26080 = D.26079 == 0;
    D.26081 = (long int) D.26080;
    D.26082 = __builtin_expect (D.26081, 0);
    if (D.26082 != 0) goto <D.26083>; else goto <D.26084>;
    <D.26083>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1293, "method->method.method.is_inflated");
    <D.26084>:
    D.26085 = method->context.method_inst;
    D.26086 = D.26085 == 0B;
    D.26087 = (long int) D.26086;
    D.26088 = __builtin_expect (D.26087, 0);
    if (D.26088 != 0) goto <D.26089>; else goto <D.26090>;
    <D.26089>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1294, "method->context.method_inst");
    <D.26090>:
    D.26037 = method->context.method_inst;
    return D.26037;
  }
  <D.24760>:
  {
    struct MonoMethodSignature * gsig;
    struct MonoMethodSignature * sig;
    void * addr;
    struct MonoJitInfo * caller_ji;
    struct MonoGenericJitInfo * gji;

    gsig = oti->data;
    sig = data;
    D.26091 = caller == 0B;
    D.26092 = (long int) D.26091;
    D.26093 = __builtin_expect (D.26092, 0);
    if (D.26093 != 0) goto <D.26094>; else goto <D.26095>;
    <D.26094>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1310, "caller");
    <D.26095>:
    D.26096 = mono_domain_get ();
    D.26097 = mono_get_addr_from_ftnptr (caller);
    caller_ji = mini_jit_info_table_find (D.26096, D.26097, 0B);
    D.26098 = caller_ji == 0B;
    D.26099 = (long int) D.26098;
    D.26100 = __builtin_expect (D.26099, 0);
    if (D.26100 != 0) goto <D.26101>; else goto <D.26102>;
    <D.26101>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1312, "caller_ji");
    <D.26102>:
    gji = mono_jit_info_get_generic_jit_info (caller_ji);
    D.26103 = gji == 0B;
    D.26104 = (long int) D.26103;
    D.26105 = __builtin_expect (D.26104, 0);
    if (D.26105 != 0) goto <D.26106>; else goto <D.26107>;
    <D.26106>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1314, "gji");
    <D.26107>:
    D.26108 = gji->generic_sharing_context;
    addr = mini_get_gsharedvt_wrapper (0, 0B, sig, gsig, D.26108, -1, 1);
    D.26037 = addr;
    return D.26037;
  }
  <D.24766>:
  <D.24767>:
  {
    struct MonoJumpInfoGSharedVtCall * call_info;
    struct MonoMethodSignature * call_sig;
    struct MonoMethod * method;
    void * addr;
    struct MonoJitInfo * caller_ji;
    struct MonoJitInfo * callee_ji;
    gboolean virtual;
    gint32 vcall_offset;
    struct MonoGenericJitInfo * gji;
    struct MonoGenericJitInfo * callee_gji;
    gboolean callee_gsharedvt;

    call_info = data;
    D.26038 = oti->info_type;
    D.26109 = D.26038 == 17;
    virtual = (gboolean) D.26109;
    callee_gji = 0B;
    call_sig = call_info->sig;
    method = call_info->method;
    D.26110 = BIT_FIELD_REF <*method, 8, 168>;
    D.26111 = D.26110 & 16;
    D.26112 = D.26111 == 0;
    D.26113 = (long int) D.26112;
    D.26114 = __builtin_expect (D.26113, 0);
    if (D.26114 != 0) goto <D.26115>; else goto <D.26116>;
    <D.26115>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1337, "method->is_inflated");
    <D.26116>:
    if (virtual == 0) goto <D.26117>; else goto <D.26118>;
    <D.26117>:
    addr = mono_compile_method (method);
    goto <D.26119>;
    <D.26118>:
    addr = 0B;
    <D.26119>:
    if (virtual != 0) goto <D.26120>; else goto <D.26121>;
    <D.26120>:
    D.26124 = method->klass;
    D.26125 = D.26124->parent;
    D.26126 = mono_defaults.multicastdelegate_class;
    if (D.26125 == D.26126) goto <D.26127>; else goto <D.26122>;
    <D.26127>:
    {
      size_t __s1_len;
      size_t __s2_len;

      __s2_len = 6;
      if (__s2_len <= 3) goto <D.26129>; else goto <D.26130>;
      <D.26129>:
      {
        const unsigned char * __s2;
        int __result;

        __s2 = method->name;
        D.26131 = "Invoke";
        D.26132 = MEM[(const unsigned char *)D.26131];
        D.26133 = (int) D.26132;
        D.26134 = *__s2;
        D.26135 = (int) D.26134;
        __result = D.26133 - D.26135;
        {
          D.26136 = __s2_len != 0;
          D.26137 = __result == 0;
          D.26138 = D.26136 & D.26137;
          if (D.26138 != 0) goto <D.26139>; else goto <D.26140>;
          <D.26139>:
          D.26141 = &MEM[(void *)"Invoke" + 1B];
          D.26142 = *D.26141;
          D.26143 = (int) D.26142;
          D.26144 = __s2 + 1;
          D.26145 = *D.26144;
          D.26146 = (int) D.26145;
          __result = D.26143 - D.26146;
          D.26147 = __s2_len > 1;
          D.26137 = __result == 0;
          D.26148 = D.26147 & D.26137;
          if (D.26148 != 0) goto <D.26149>; else goto <D.26150>;
          <D.26149>:
          D.26151 = &MEM[(void *)"Invoke" + 2B];
          D.26152 = *D.26151;
          D.26153 = (int) D.26152;
          D.26154 = __s2 + 2;
          D.26155 = *D.26154;
          D.26156 = (int) D.26155;
          __result = D.26153 - D.26156;
          D.26157 = __s2_len > 2;
          D.26137 = __result == 0;
          D.26158 = D.26157 & D.26137;
          if (D.26158 != 0) goto <D.26159>; else goto <D.26160>;
          <D.26159>:
          D.26161 = &MEM[(void *)"Invoke" + 3B];
          D.26162 = *D.26161;
          D.26163 = (int) D.26162;
          D.26164 = __s2 + 3;
          D.26165 = *D.26164;
          D.26166 = (int) D.26165;
          __result = D.26163 - D.26166;
          <D.26160>:
          <D.26150>:
          <D.26140>:
        }
        D.24786 = __result;
      }
      iftmp.68 = -D.24786;
      goto <D.26167>;
      <D.26130>:
      D.26168 = method->name;
      iftmp.68 = __builtin_strcmp (D.26168, "Invoke");
      <D.26167>:
      D.24787 = iftmp.68;
    }
    if (D.24787 == 0) goto <D.26169>; else goto <D.26122>;
    <D.26169>:
    vcall_offset = -2;
    goto <D.26123>;
    <D.26122>:
    D.26124 = method->klass;
    D.26170 = D.26124->flags;
    D.26171 = D.26170 & 32;
    if (D.26171 != 0) goto <D.26172>; else goto <D.26173>;
    <D.26172>:
    {
      guint32 imt_slot;

      imt_slot = mono_method_get_imt_slot (method);
      imt_slot.69 = (int) imt_slot;
      D.26175 = imt_slot.69 + -19;
      vcall_offset = D.26175 * 4;
    }
    goto <D.26176>;
    <D.26173>:
    D.26177 = mono_method_get_vtable_index (method);
    D.26178 = D.26177 * 4;
    D.26179 = (unsigned int) D.26178;
    D.26180 = D.26179 + 32;
    vcall_offset = (gint32) D.26180;
    <D.26176>:
    <D.26123>:
    goto <D.26181>;
    <D.26121>:
    vcall_offset = -1;
    <D.26181>:
    D.26091 = caller == 0B;
    D.26092 = (long int) D.26091;
    D.26093 = __builtin_expect (D.26092, 0);
    if (D.26093 != 0) goto <D.26182>; else goto <D.26183>;
    <D.26182>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1364, "caller");
    <D.26183>:
    D.26184 = mono_domain_get ();
    D.26185 = mono_get_addr_from_ftnptr (caller);
    caller_ji = mini_jit_info_table_find (D.26184, D.26185, 0B);
    D.26186 = caller_ji == 0B;
    D.26187 = (long int) D.26186;
    D.26188 = __builtin_expect (D.26187, 0);
    if (D.26188 != 0) goto <D.26189>; else goto <D.26190>;
    <D.26189>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1366, "caller_ji");
    <D.26190>:
    gji = mono_jit_info_get_generic_jit_info (caller_ji);
    D.26191 = gji == 0B;
    D.26192 = (long int) D.26191;
    D.26193 = __builtin_expect (D.26192, 0);
    if (D.26193 != 0) goto <D.26194>; else goto <D.26195>;
    <D.26194>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1368, "gji");
    <D.26195>:
    D.26196 = mono_domain_get ();
    D.26197 = mono_get_addr_from_ftnptr (addr);
    callee_ji = mini_jit_info_table_find (D.26196, D.26197, 0B);
    callee_gsharedvt = ji_is_gsharedvt (callee_ji);
    if (callee_gsharedvt != 0) goto <D.26198>; else goto <D.26199>;
    <D.26198>:
    callee_gji = mono_jit_info_get_generic_jit_info (callee_ji);
    D.26200 = callee_gji == 0B;
    D.26201 = (long int) D.26200;
    D.26202 = __builtin_expect (D.26201, 0);
    if (D.26202 != 0) goto <D.26203>; else goto <D.26204>;
    <D.26203>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1375, "callee_gji");
    <D.26204>:
    <D.26199>:
    D.26205 = virtual != 0;
    D.26206 = callee_gsharedvt == 0;
    D.26207 = D.26205 | D.26206;
    if (D.26207 != 0) goto <D.26208>; else goto <D.26209>;
    <D.26208>:
    {
      struct MonoMethodSignature * sig;
      struct MonoMethodSignature * gsig;

      D.26110 = BIT_FIELD_REF <*method, 8, 168>;
      D.26111 = D.26110 & 16;
      D.26112 = D.26111 == 0;
      D.26113 = (long int) D.26112;
      D.26114 = __builtin_expect (D.26113, 0);
      if (D.26114 != 0) goto <D.26210>; else goto <D.26211>;
      <D.26210>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1392, "method->is_inflated");
      <D.26211>:
      sig = mono_method_signature (method);
      gsig = call_sig;
      D.26212 = gji->generic_sharing_context;
      addr = mini_get_gsharedvt_wrapper (0, addr, sig, gsig, D.26212, vcall_offset, 0);
    }
    goto <D.26213>;
    <D.26209>:
    if (callee_gsharedvt != 0) goto <D.26214>; else goto <D.26215>;
    <D.26214>:
    {
      struct MonoMethodSignature * sig;
      struct MonoMethodSignature * gsig;

      D.26216 = mono_method_signature (method);
      if (D.26216 == call_sig) goto <D.26217>; else goto <D.26218>;
      <D.26217>:
      goto <D.26219>;
      <D.26218>:
      sig = mono_method_signature (method);
      D.26220 = jinfo_get_method (callee_ji);
      gsig = mono_method_signature (D.26220);
      D.26221 = callee_ji->code_start;
      D.26222 = callee_gji->generic_sharing_context;
      addr = mini_get_gsharedvt_wrapper (1, D.26221, sig, gsig, D.26222, -1, 0);
      sig = mono_method_signature (method);
      gsig = call_sig;
      D.26212 = gji->generic_sharing_context;
      addr = mini_get_gsharedvt_wrapper (0, addr, sig, gsig, D.26212, -1, 0);
      <D.26219>:
    }
    <D.26215>:
    <D.26213>:
    D.26037 = addr;
    return D.26037;
  }
  <D.24793>:
  {
    struct MonoGSharedVtMethodInfo * info;
    struct MonoGSharedVtMethodRuntimeInfo * res;
    struct MonoType * t;
    int i;
    int offset;
    int align;
    int size;

    try
      {
        info = data;
        D.26223 = info->entries;
        D.26224 = D.26223->len;
        D.26225 = D.26224 + 1;
        D.26226 = D.26225 * 4;
        res = monoeg_malloc0 (D.26226);
        offset = 0;
        i = 0;
        goto <D.24806>;
        <D.24805>:
        {
          struct MonoRuntimeGenericContextInfoTemplate * template;

          D.26223 = info->entries;
          D.26227 = D.26223->pdata;
          i.70 = (unsigned int) i;
          D.26229 = i.70 * 4;
          D.26230 = D.26227 + D.26229;
          template = *D.26230;
          D.26231 = template->info_type;
          switch (D.26231) <default: <D.24804>, case 21: <D.24802>>
          <D.24802>:
          t = template->data;
          size = mono_type_size (t, &align);
          align.71 = align;
          align.72 = (unsigned int) align.71;
          if (align.72 <= 3) goto <D.26234>; else goto <D.26235>;
          <D.26234>:
          align = 4;
          <D.26235>:
          D.26236 = mono_type_is_struct (t);
          if (D.26236 != 0) goto <D.26237>; else goto <D.26238>;
          <D.26237>:
          align.71 = align;
          align.72 = (unsigned int) align.71;
          if (align.72 <= 7) goto <D.26239>; else goto <D.26240>;
          <D.26239>:
          align = 8;
          <D.26240>:
          <D.26238>:
          align.71 = align;
          D.26241 = align.71 + -1;
          offset = D.26241 + offset;
          align.71 = align;
          D.26242 = -align.71;
          offset = D.26242 & offset;
          offset.73 = (void *) offset;
          res->entries[i] = offset.73;
          offset = offset + size;
          goto <D.24803>;
          <D.24804>:
          D.26244 = instantiate_info (domain, template, context, class, 0B);
          res->entries[i] = D.26244;
          goto <D.24803>;
          <D.24803>:
        }
        i = i + 1;
        <D.24806>:
        i.74 = (unsigned int) i;
        D.26223 = info->entries;
        D.26224 = D.26223->len;
        if (i.74 < D.26224) goto <D.24805>; else goto <D.24807>;
        <D.24807>:
        res->locals_size = offset;
        D.26037 = res;
        return D.26037;
      }
    finally
      {
        align = {CLOBBER};
      }
  }
  <D.24808>:
  monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 1482);
  D.26037 = 0B;
  return D.26037;
}


class_type_info (struct MonoDomain * domain, struct MonoClass * class, MonoRgctxInfoType info_type)
{
  struct MonoException * D.26250;
  void * D.26251;
  struct MonoException * D.26254;
  void * * * D.26255;
  int D.26256;
  struct MonoType * D.26257;
  int D.26258;
  int D.26261;
  int D.26262;
  int D.26265;
  int D.26268;
  unsigned int size.75;
  unsigned int D.26273;
  _Bool D.26274;
  _Bool D.26275;
  _Bool D.26276;
  unsigned int size.76;
  unsigned int align.77;
  struct MonoMethod * D.26287;
  struct MonoClass * D.26293;
  _Bool D.26294;
  long int D.26295;
  long int D.26296;
  void * * D.26299;
  struct MonoMethod * D.26302;
  _Bool D.26308;
  long int D.26309;
  long int D.26310;
  void * * D.26313;
  int D.26316;
  struct MonoDomain * D.26322;
  void * D.26323;
  _Bool D.26324;
  long int D.26325;
  long int D.26326;
  int D.26329;

  switch (info_type) <default: <D.24670>, case 0: <D.24637>, case 1: <D.24639>, case 2: <D.24640>, case 12: <D.24642>, case 13: <D.24644>, case 14: <D.24645>, case 19: <D.24646>, case 22: <D.24647>, case 23: <D.24648>, case 24: <D.24660>, case 25: <D.24661>>
  <D.24637>:
  {
    struct MonoVTable * vtable;

    vtable = mono_class_vtable (domain, class);
    if (vtable == 0B) goto <D.26248>; else goto <D.26249>;
    <D.26248>:
    D.26250 = mono_class_get_exception_for_failure (class);
    mono_raise_exception (D.26250);
    <D.26249>:
    D.26251 = mono_vtable_get_static_field_data (vtable);
    return D.26251;
  }
  <D.24639>:
  D.26251 = class;
  return D.26251;
  <D.24640>:
  {
    struct MonoVTable * vtable;

    vtable = mono_class_vtable (domain, class);
    if (vtable == 0B) goto <D.26252>; else goto <D.26253>;
    <D.26252>:
    D.26254 = mono_class_get_exception_for_failure (class);
    mono_raise_exception (D.26254);
    <D.26253>:
    D.26251 = vtable;
    return D.26251;
  }
  <D.24642>:
  {
    void * * * cache_data;

    cache_data = mono_domain_alloc0 (domain, 8);
    D.26255 = cache_data + 4;
    *D.26255 = class;
    D.26251 = cache_data;
    return D.26251;
  }
  <D.24644>:
  D.26256 = mono_class_array_element_size (class);
  D.26251 = (void *) D.26256;
  return D.26251;
  <D.24645>:
  D.26257 = &class->byval_arg;
  D.26258 = mono_type_is_reference (D.26257);
  if (D.26258 != 0) goto <D.26259>; else goto <D.26260>;
  <D.26259>:
  D.26251 = 4B;
  return D.26251;
  <D.26260>:
  D.26261 = mono_class_value_size (class, 0B);
  D.26251 = (void *) D.26261;
  return D.26251;
  <D.24646>:
  D.26257 = &class->byval_arg;
  D.26262 = mono_type_is_reference (D.26257);
  if (D.26262 != 0) goto <D.26263>; else goto <D.26264>;
  <D.26263>:
  D.26251 = 1B;
  return D.26251;
  <D.26264>:
  D.26265 = mono_class_is_nullable (class);
  if (D.26265 != 0) goto <D.26266>; else goto <D.26267>;
  <D.26266>:
  D.26251 = 2B;
  return D.26251;
  <D.26267>:
  D.26251 = 0B;
  return D.26251;
  <D.24647>:
  <D.24648>:
  {
    static struct MonoMethod * memcpy_method[17];
    static struct MonoMethod * bzero_method[17];
    struct MonoJitDomainInfo * domain_info;
    int size;
    guint32 align;

    try
      {
        domain_info = domain->runtime_info;
        D.26257 = &class->byval_arg;
        D.26268 = mono_type_is_reference (D.26257);
        if (D.26268 != 0) goto <D.26269>; else goto <D.26270>;
        <D.26269>:
        size = 4;
        align = 4;
        goto <D.26271>;
        <D.26270>:
        size = mono_class_value_size (class, &align);
        <D.26271>:
        size.75 = (unsigned int) size;
        D.26273 = size.75 + 4294967295;
        D.26274 = D.26273 > 1;
        D.26275 = size != 4;
        D.26276 = D.26274 & D.26275;
        if (D.26276 != 0) goto <D.26277>; else goto <D.26278>;
        <D.26277>:
        if (size != 8) goto <D.26279>; else goto <D.26280>;
        <D.26279>:
        size = 0;
        <D.26280>:
        <D.26278>:
        size.76 = (unsigned int) size;
        align.77 = align;
        if (size.76 > align.77) goto <D.26283>; else goto <D.26284>;
        <D.26283>:
        size = 0;
        <D.26284>:
        if (info_type == 22) goto <D.26285>; else goto <D.26286>;
        <D.26285>:
        D.26287 = memcpy_method[size];
        if (D.26287 == 0B) goto <D.26288>; else goto <D.26289>;
        <D.26288>:
        {
          struct MonoMethod * m;
          char name[32];

          try
            {
              if (size == 0) goto <D.26290>; else goto <D.26291>;
              <D.26290>:
              sprintf (&name, "memcpy");
              goto <D.26292>;
              <D.26291>:
              sprintf (&name, "memcpy_aligned_%d", size);
              <D.26292>:
              D.26293 = mono_defaults.string_class;
              m = mono_class_get_method_from_name (D.26293, &name, 3);
              D.26294 = m == 0B;
              D.26295 = (long int) D.26294;
              D.26296 = __builtin_expect (D.26295, 0);
              if (D.26296 != 0) goto <D.26297>; else goto <D.26298>;
              <D.26297>:
              monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 991, "m");
              <D.26298>:
              mono_memory_barrier ();
              memcpy_method[size] = m;
            }
          finally
            {
              name = {CLOBBER};
            }
        }
        <D.26289>:
        D.26299 = domain_info->memcpy_addr[size];
        if (D.26299 == 0B) goto <D.26300>; else goto <D.26301>;
        <D.26300>:
        {
          void * addr;

          D.26287 = memcpy_method[size];
          addr = mono_compile_method (D.26287);
          mono_memory_barrier ();
          domain_info->memcpy_addr[size] = addr;
        }
        <D.26301>:
        D.26251 = domain_info->memcpy_addr[size];
        return D.26251;
        <D.26286>:
        D.26302 = bzero_method[size];
        if (D.26302 == 0B) goto <D.26303>; else goto <D.26304>;
        <D.26303>:
        {
          struct MonoMethod * m;
          char name[32];

          try
            {
              if (size == 0) goto <D.26305>; else goto <D.26306>;
              <D.26305>:
              sprintf (&name, "bzero");
              goto <D.26307>;
              <D.26306>:
              sprintf (&name, "bzero_aligned_%d", size);
              <D.26307>:
              D.26293 = mono_defaults.string_class;
              m = mono_class_get_method_from_name (D.26293, &name, 2);
              D.26308 = m == 0B;
              D.26309 = (long int) D.26308;
              D.26310 = __builtin_expect (D.26309, 0);
              if (D.26310 != 0) goto <D.26311>; else goto <D.26312>;
              <D.26311>:
              monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1011, "m");
              <D.26312>:
              mono_memory_barrier ();
              bzero_method[size] = m;
            }
          finally
            {
              name = {CLOBBER};
            }
        }
        <D.26304>:
        D.26313 = domain_info->bzero_addr[size];
        if (D.26313 == 0B) goto <D.26314>; else goto <D.26315>;
        <D.26314>:
        {
          void * addr;

          D.26302 = bzero_method[size];
          addr = mono_compile_method (D.26302);
          mono_memory_barrier ();
          domain_info->bzero_addr[size] = addr;
        }
        <D.26315>:
        D.26251 = domain_info->bzero_addr[size];
        return D.26251;
      }
    finally
      {
        align = {CLOBBER};
      }
  }
  <D.24660>:
  <D.24661>:
  {
    struct MonoMethod * method;
    void * addr;
    struct MonoJitInfo * ji;
    struct MonoGenericContext * ctx;

    D.26316 = mono_class_is_nullable (class);
    if (D.26316 == 0) goto <D.26317>; else goto <D.26318>;
    <D.26317>:
    D.26251 = 0B;
    return D.26251;
    <D.26318>:
    if (info_type == 24) goto <D.26319>; else goto <D.26320>;
    <D.26319>:
    method = mono_class_get_method_from_name (class, "Box", 1);
    goto <D.26321>;
    <D.26320>:
    method = mono_class_get_method_from_name (class, "Unbox", 1);
    <D.26321>:
    addr = mono_compile_method (method);
    D.26322 = mono_domain_get ();
    D.26323 = mono_get_addr_from_ftnptr (addr);
    ji = mini_jit_info_table_find (D.26322, D.26323, 0B);
    D.26324 = ji == 0B;
    D.26325 = (long int) D.26324;
    D.26326 = __builtin_expect (D.26325, 0);
    if (D.26326 != 0) goto <D.26327>; else goto <D.26328>;
    <D.26327>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 1042, "ji");
    <D.26328>:
    D.26329 = mini_jit_info_is_gsharedvt (ji);
    if (D.26329 != 0) goto <D.26330>; else goto <D.26331>;
    <D.26330>:
    D.26251 = mono_create_static_rgctx_trampoline (method, addr);
    return D.26251;
    <D.26331>:
    {
      struct MonoGenericSharingContext gsctx;
      struct MonoMethodSignature * sig;
      struct MonoMethodSignature * gsig;
      struct MonoMethod * gmethod;

      try
        {
          gmethod = mini_get_shared_method (method);
          sig = mono_method_signature (method);
          gsig = mono_method_signature (gmethod);
          ctx = mono_method_get_context (gmethod);
          mini_init_gsctx (ctx, &gsctx);
          addr = mini_get_gsharedvt_wrapper (0, addr, sig, gsig, &gsctx, -1, 0);
          addr = mono_create_static_rgctx_trampoline (method, addr);
          D.26251 = addr;
          return D.26251;
        }
      finally
        {
          gsctx = {CLOBBER};
        }
    }
  }
  <D.24670>:
  monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 1065);
  D.26251 = 0B;
  return D.26251;
}


sprintf (char * restrict __s, const char * restrict __fmt)
{
  int D.26335;
  unsigned int D.26336;

  D.26336 = __builtin_object_size (__s, 1);
  D.26335 = __builtin___sprintf_chk (__s, 1, D.26336, __fmt, __builtin_va_arg_pack ());
  return D.26335;
}


ji_is_gsharedvt (struct MonoJitInfo * ji)
{
  unsigned char D.26341;
  unsigned char D.26342;
  struct MonoGenericSharingContext * D.26344;
  gboolean * D.26345;
  struct MonoGenericSharingContext * D.26347;
  gboolean * D.26348;
  gboolean D.26349;

  if (ji != 0B) goto <D.26340>; else goto <D.26338>;
  <D.26340>:
  D.26341 = BIT_FIELD_REF <*ji, 8, 176>;
  D.26342 = D.26341 & 2;
  if (D.26342 != 0) goto <D.26343>; else goto <D.26338>;
  <D.26343>:
  D.26344 = mono_jit_info_get_generic_sharing_context (ji);
  D.26345 = D.26344->var_is_vt;
  if (D.26345 != 0B) goto <D.26339>; else goto <D.26346>;
  <D.26346>:
  D.26347 = mono_jit_info_get_generic_sharing_context (ji);
  D.26348 = D.26347->mvar_is_vt;
  if (D.26348 != 0B) goto <D.26339>; else goto <D.26338>;
  <D.26339>:
  D.26349 = 1;
  return D.26349;
  <D.26338>:
  D.26349 = 0;
  return D.26349;
}


jinfo_get_method (struct MonoJitInfo * ji)
{
  struct MonoMethod * D.26351;

  D.26351 = mono_jit_info_get_method (ji);
  return D.26351;
}


mono_method_fill_runtime_generic_context (struct MonoMethodRuntimeGenericContext * mrgctx, guint8 * caller, guint32 slot)
{
  struct MonoVTable * D.26353;
  struct MonoGenericInst * D.26354;
  void * D.26355;
  void * info;

  D.26353 = mrgctx->class_vtable;
  D.26354 = mrgctx->method_inst;
  info = fill_runtime_generic_context (D.26353, mrgctx, caller, slot, D.26354);
  D.26355 = info;
  return D.26355;
}


mono_method_lookup_rgctx (struct MonoVTable * class_vtable, struct MonoGenericInst * method_inst)
{
  struct MonoClass * D.26357;
  struct MonoGenericContainer * D.26358;
  _Bool D.26359;
  long int D.26360;
  long int D.26361;
  unsigned char D.26364;
  unsigned char D.26365;
  _Bool D.26366;
  long int D.26367;
  long int D.26368;
  union mono_mutex_t * D.26371;
  _Bool D.26374;
  long int D.26375;
  long int D.26376;
  struct GHashTable * D.26379;
  struct GHashTable * D.26382;
  _Bool D.26387;
  long int D.26388;
  long int D.26389;
  _Bool D.26392;
  long int D.26393;
  long int D.26394;
  struct MonoMethodRuntimeGenericContext * D.26397;
  struct MonoDomain * domain;
  struct MonoMethodRuntimeGenericContext * mrgctx;
  struct MonoMethodRuntimeGenericContext key;

  try
    {
      domain = class_vtable->domain;
      D.26357 = class_vtable->klass;
      D.26358 = D.26357->generic_container;
      D.26359 = D.26358 != 0B;
      D.26360 = (long int) D.26359;
      D.26361 = __builtin_expect (D.26360, 0);
      if (D.26361 != 0) goto <D.26362>; else goto <D.26363>;
      <D.26362>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2002, "!class_vtable->klass->generic_container");
      <D.26363>:
      D.26364 = BIT_FIELD_REF <*method_inst, 8, 48>;
      D.26365 = D.26364 & 64;
      D.26366 = D.26365 != 0;
      D.26367 = (long int) D.26366;
      D.26368 = __builtin_expect (D.26367, 0);
      if (D.26368 != 0) goto <D.26369>; else goto <D.26370>;
      <D.26369>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2003, "!method_inst->is_open");
      <D.26370>:
      {
        int ret;

        D.26371 = &domain->lock.mutex;
        ret = pthread_mutex_lock (D.26371);
        if (ret != 0) goto <D.26372>; else goto <D.26373>;
        <D.26372>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
        <D.26373>:
        D.26374 = ret != 0;
        D.26375 = (long int) D.26374;
        D.26376 = __builtin_expect (D.26375, 0);
        if (D.26376 != 0) goto <D.26377>; else goto <D.26378>;
        <D.26377>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2005, "ret == 0");
        <D.26378>:
      }
      D.26379 = domain->method_rgctx_hash;
      if (D.26379 == 0B) goto <D.26380>; else goto <D.26381>;
      <D.26380>:
      D.26382 = monoeg_g_hash_table_new (mrgctx_hash_func, mrgctx_equal_func);
      domain->method_rgctx_hash = D.26382;
      <D.26381>:
      key.class_vtable = class_vtable;
      key.method_inst = method_inst;
      D.26379 = domain->method_rgctx_hash;
      mrgctx = monoeg_g_hash_table_lookup (D.26379, &key);
      if (mrgctx == 0B) goto <D.26383>; else goto <D.26384>;
      <D.26383>:
      mrgctx = alloc_rgctx_array (domain, 0, 1);
      mrgctx->class_vtable = class_vtable;
      mrgctx->method_inst = method_inst;
      D.26379 = domain->method_rgctx_hash;
      monoeg_g_hash_table_insert_replace (D.26379, mrgctx, mrgctx, 0);
      <D.26384>:
      {
        int ret;

        D.26371 = &domain->lock.mutex;
        ret = pthread_mutex_unlock (D.26371);
        if (ret != 0) goto <D.26385>; else goto <D.26386>;
        <D.26385>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
        <D.26386>:
        D.26387 = ret != 0;
        D.26388 = (long int) D.26387;
        D.26389 = __builtin_expect (D.26388, 0);
        if (D.26389 != 0) goto <D.26390>; else goto <D.26391>;
        <D.26390>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2031, "ret == 0");
        <D.26391>:
      }
      D.26392 = mrgctx == 0B;
      D.26393 = (long int) D.26392;
      D.26394 = __builtin_expect (D.26393, 0);
      if (D.26394 != 0) goto <D.26395>; else goto <D.26396>;
      <D.26395>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2033, "mrgctx");
      <D.26396>:
      D.26397 = mrgctx;
      return D.26397;
    }
  finally
    {
      key = {CLOBBER};
    }
}


mrgctx_equal_func (const void * a, const void * b)
{
  gboolean D.26400;
  int iftmp.78;
  struct MonoVTable * D.26404;
  struct MonoVTable * D.26405;
  struct MonoGenericInst * D.26407;
  struct MonoGenericInst * D.26408;
  int D.26409;
  const struct MonoMethodRuntimeGenericContext * mrgctx1;
  const struct MonoMethodRuntimeGenericContext * mrgctx2;

  mrgctx1 = a;
  mrgctx2 = b;
  D.26404 = mrgctx1->class_vtable;
  D.26405 = mrgctx2->class_vtable;
  if (D.26404 == D.26405) goto <D.26406>; else goto <D.26402>;
  <D.26406>:
  D.26407 = mrgctx1->method_inst;
  D.26408 = mrgctx2->method_inst;
  D.26409 = mono_metadata_generic_inst_equal (D.26407, D.26408);
  if (D.26409 != 0) goto <D.26410>; else goto <D.26402>;
  <D.26410>:
  iftmp.78 = 1;
  goto <D.26403>;
  <D.26402>:
  iftmp.78 = 0;
  <D.26403>:
  D.26400 = iftmp.78;
  return D.26400;
}


mrgctx_hash_func (const void * key)
{
  guint D.26412;
  struct MonoVTable * D.26413;
  unsigned int D.26414;
  struct MonoGenericInst * D.26415;
  unsigned int D.26416;
  const struct MonoMethodRuntimeGenericContext * mrgctx;

  mrgctx = key;
  D.26413 = mrgctx->class_vtable;
  D.26414 = mono_aligned_addr_hash (D.26413);
  D.26415 = mrgctx->method_inst;
  D.26416 = mono_metadata_generic_inst_hash (D.26415);
  D.26412 = D.26414 ^ D.26416;
  return D.26412;
}


mono_generic_context_is_sharable_full (struct MonoGenericContext * context, gboolean allow_type_vars, gboolean allow_partial)
{
  int iftmp.79;
  struct MonoGenericInst * D.26421;
  struct MonoGenericInst * D.26423;
  _Bool D.26425;
  long int D.26426;
  long int D.26427;
  int D.26432;
  gboolean D.26435;
  int D.26438;

  D.26421 = context->class_inst;
  if (D.26421 == 0B) goto <D.26422>; else goto <D.26419>;
  <D.26422>:
  D.26423 = context->method_inst;
  if (D.26423 == 0B) goto <D.26424>; else goto <D.26419>;
  <D.26424>:
  iftmp.79 = 1;
  goto <D.26420>;
  <D.26419>:
  iftmp.79 = 0;
  <D.26420>:
  D.26425 = iftmp.79 != 0;
  D.26426 = (long int) D.26425;
  D.26427 = __builtin_expect (D.26426, 0);
  if (D.26427 != 0) goto <D.26428>; else goto <D.26429>;
  <D.26428>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2051, "context->class_inst || context->method_inst");
  <D.26429>:
  D.26421 = context->class_inst;
  if (D.26421 != 0B) goto <D.26430>; else goto <D.26431>;
  <D.26430>:
  D.26421 = context->class_inst;
  D.26432 = generic_inst_is_sharable (D.26421, allow_type_vars, allow_partial);
  if (D.26432 == 0) goto <D.26433>; else goto <D.26434>;
  <D.26433>:
  D.26435 = 0;
  return D.26435;
  <D.26434>:
  <D.26431>:
  D.26423 = context->method_inst;
  if (D.26423 != 0B) goto <D.26436>; else goto <D.26437>;
  <D.26436>:
  D.26423 = context->method_inst;
  D.26438 = generic_inst_is_sharable (D.26423, allow_type_vars, allow_partial);
  if (D.26438 == 0) goto <D.26439>; else goto <D.26440>;
  <D.26439>:
  D.26435 = 0;
  return D.26435;
  <D.26440>:
  <D.26437>:
  D.26435 = 1;
  return D.26435;
}


generic_inst_is_sharable (struct MonoGenericInst * inst, gboolean allow_type_vars, gboolean allow_partial)
{
  int D.26444;
  unsigned char D.26447;
  _Bool D.26448;
  _Bool D.26449;
  _Bool D.26450;
  unsigned char D.26455;
  unsigned char D.26456;
  unsigned char D.26459;
  unsigned char D.26460;
  _Bool D.26461;
  _Bool D.26462;
  _Bool D.26463;
  unsigned char D.26465;
  gboolean D.26466;
  <unnamed-unsigned:22> D.26467;
  int D.26468;
  int i;
  gboolean has_ref;

  has_ref = 0;
  i = 0;
  goto <D.24589>;
  <D.24588>:
  {
    struct MonoType * type;

    type = inst->type_argv[i];
    D.26444 = mono_type_is_reference (type);
    if (D.26444 != 0) goto <D.26442>; else goto <D.26445>;
    <D.26445>:
    if (allow_type_vars != 0) goto <D.26446>; else goto <D.26443>;
    <D.26446>:
    D.26447 = type->type;
    D.26448 = D.26447 == 19;
    D.26449 = D.26447 == 30;
    D.26450 = D.26448 | D.26449;
    if (D.26450 != 0) goto <D.26442>; else goto <D.26443>;
    <D.26442>:
    has_ref = 1;
    // predicted unlikely by continue predictor.
    goto <D.24587>;
    <D.26443>:
    if (allow_partial != 0) goto <D.26453>; else goto <D.26454>;
    <D.26453>:
    D.26455 = BIT_FIELD_REF <*type, 8, 56>;
    D.26456 = D.26455 & 64;
    if (D.26456 == 0) goto <D.26457>; else goto <D.26458>;
    <D.26457>:
    D.26459 = type->type;
    D.26460 = D.26459 + 254;
    D.26461 = D.26460 <= 11;
    D.26462 = D.26459 == 24;
    D.26463 = D.26461 | D.26462;
    if (D.26463 != 0) goto <D.26451>; else goto <D.26464>;
    <D.26464>:
    D.26465 = type->type;
    if (D.26465 == 25) goto <D.26451>; else goto <D.26452>;
    <D.26451>:
    // predicted unlikely by continue predictor.
    goto <D.24587>;
    <D.26452>:
    <D.26458>:
    <D.26454>:
    D.26466 = 0;
    return D.26466;
  }
  <D.24587>:
  i = i + 1;
  <D.24589>:
  D.26467 = inst->type_argc;
  D.26468 = (int) D.26467;
  if (D.26468 > i) goto <D.24588>; else goto <D.24590>;
  <D.24590>:
  if (allow_partial != 0) goto <D.26469>; else goto <D.26470>;
  <D.26469>:
  D.26466 = has_ref;
  return D.26466;
  <D.26470>:
  D.26466 = 1;
  return D.26466;
}


mono_generic_context_is_sharable (struct MonoGenericContext * context, gboolean allow_type_vars)
{
  gboolean D.26472;
  int D.26473;

  D.26473 = partial_sharing_supported ();
  D.26472 = mono_generic_context_is_sharable_full (context, allow_type_vars, D.26473);
  return D.26472;
}


partial_sharing_supported ()
{
  gboolean D.26477;
  int partial_supported.80;
  int mono_aot_only.81;

  if (0 != 0) goto <D.26475>; else goto <D.26476>;
  <D.26475>:
  D.26477 = 0;
  return D.26477;
  <D.26476>:
  partial_supported.80 = partial_supported;
  if (partial_supported.80 != 0) goto <D.26478>; else goto <D.26481>;
  <D.26481>:
  mono_aot_only.81 = mono_aot_only;
  if (mono_aot_only.81 != 0) goto <D.26478>; else goto <D.26479>;
  <D.26478>:
  D.26477 = 1;
  return D.26477;
  <D.26479>:
  D.26477 = 0;
  return D.26477;
}


mono_method_is_generic_impl (struct MonoMethod * method)
{
  unsigned char D.26484;
  unsigned char D.26485;
  gboolean D.26488;
  unsigned char D.26489;
  unsigned char D.26490;
  struct MonoClass * D.26493;
  struct MonoGenericContainer * D.26494;

  D.26484 = BIT_FIELD_REF <*method, 8, 168>;
  D.26485 = D.26484 & 16;
  if (D.26485 != 0) goto <D.26486>; else goto <D.26487>;
  <D.26486>:
  D.26488 = 1;
  return D.26488;
  <D.26487>:
  D.26489 = BIT_FIELD_REF <*method, 8, 160>;
  D.26490 = D.26489 & 124;
  if (D.26490 != 0) goto <D.26491>; else goto <D.26492>;
  <D.26491>:
  D.26488 = 0;
  return D.26488;
  <D.26492>:
  D.26493 = method->klass;
  D.26494 = D.26493->generic_container;
  if (D.26494 != 0B) goto <D.26495>; else goto <D.26496>;
  <D.26495>:
  D.26488 = 1;
  return D.26488;
  <D.26496>:
  D.26488 = 0;
  return D.26488;
}


mono_method_is_generic_sharable_full (struct MonoMethod * method, gboolean allow_type_vars, gboolean allow_partial, gboolean allow_gsharedvt)
{
  int D.26498;
  gboolean D.26501;
  int D.26502;
  struct MonoClass * D.26505;
  int D.26506;
  int D.26511;
  int D.26514;
  unsigned char D.26517;
  unsigned char D.26518;
  int D.26521;
  struct MonoMethod * D.26524;
  _Bool D.26525;
  long int D.26526;
  long int D.26527;
  unsigned char D.26530;
  unsigned char D.26531;
  struct MonoGenericContainer * D.26534;
  int D.26535;
  struct MonoGenericClass * D.26538;
  struct MonoGenericContext * D.26541;
  int D.26542;
  int iftmp.82;
  struct MonoClass * D.26549;
  struct MonoGenericContainer * D.26551;
  _Bool D.26552;
  long int D.26553;
  long int D.26554;
  int D.26557;
  struct MonoGenericContainer * D.26560;
  int D.26565;
  int D.26568;

  D.26498 = mono_method_is_generic_impl (method);
  if (D.26498 == 0) goto <D.26499>; else goto <D.26500>;
  <D.26499>:
  D.26501 = 0;
  return D.26501;
  <D.26500>:
  D.26502 = partial_sharing_supported ();
  if (D.26502 == 0) goto <D.26503>; else goto <D.26504>;
  <D.26503>:
  allow_partial = 0;
  <D.26504>:
  D.26505 = method->klass;
  D.26506 = is_async_state_machine_class (D.26505);
  if (D.26506 != 0) goto <D.26507>; else goto <D.26508>;
  <D.26507>:
  D.26501 = 0;
  return D.26501;
  <D.26508>:
  if (allow_gsharedvt != 0) goto <D.26509>; else goto <D.26510>;
  <D.26509>:
  D.26511 = mini_is_gsharedvt_sharable_method (method);
  if (D.26511 != 0) goto <D.26512>; else goto <D.26513>;
  <D.26512>:
  D.26514 = is_async_method (method);
  if (D.26514 != 0) goto <D.26515>; else goto <D.26516>;
  <D.26515>:
  D.26501 = 0;
  return D.26501;
  <D.26516>:
  D.26501 = 1;
  return D.26501;
  <D.26513>:
  <D.26510>:
  D.26517 = BIT_FIELD_REF <*method, 8, 168>;
  D.26518 = D.26517 & 16;
  if (D.26518 != 0) goto <D.26519>; else goto <D.26520>;
  <D.26519>:
  {
    struct MonoMethodInflated * inflated;
    struct MonoGenericContext * context;

    inflated = method;
    context = &inflated->context;
    D.26521 = mono_generic_context_is_sharable_full (context, allow_type_vars, allow_partial);
    if (D.26521 == 0) goto <D.26522>; else goto <D.26523>;
    <D.26522>:
    D.26501 = 0;
    return D.26501;
    <D.26523>:
    D.26524 = inflated->declaring;
    D.26525 = D.26524 == 0B;
    D.26526 = (long int) D.26525;
    D.26527 = __builtin_expect (D.26526, 0);
    if (D.26527 != 0) goto <D.26528>; else goto <D.26529>;
    <D.26528>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2216, "inflated->declaring");
    <D.26529>:
    D.26524 = inflated->declaring;
    D.26530 = BIT_FIELD_REF <*D.26524, 8, 168>;
    D.26531 = D.26530 & 8;
    if (D.26531 != 0) goto <D.26532>; else goto <D.26533>;
    <D.26532>:
    D.26524 = inflated->declaring;
    D.26534 = mono_method_get_generic_container (D.26524);
    D.26535 = has_constraints (D.26534);
    if (D.26535 != 0) goto <D.26536>; else goto <D.26537>;
    <D.26536>:
    D.26501 = 0;
    return D.26501;
    <D.26537>:
    <D.26533>:
  }
  <D.26520>:
  D.26505 = method->klass;
  D.26538 = D.26505->generic_class;
  if (D.26538 != 0B) goto <D.26539>; else goto <D.26540>;
  <D.26539>:
  D.26505 = method->klass;
  D.26538 = D.26505->generic_class;
  D.26541 = &D.26538->context;
  D.26542 = mono_generic_context_is_sharable_full (D.26541, allow_type_vars, allow_partial);
  if (D.26542 == 0) goto <D.26543>; else goto <D.26544>;
  <D.26543>:
  D.26501 = 0;
  return D.26501;
  <D.26544>:
  D.26505 = method->klass;
  D.26538 = D.26505->generic_class;
  D.26549 = D.26538->container_class;
  if (D.26549 == 0B) goto <D.26546>; else goto <D.26550>;
  <D.26550>:
  D.26505 = method->klass;
  D.26538 = D.26505->generic_class;
  D.26549 = D.26538->container_class;
  D.26551 = D.26549->generic_container;
  if (D.26551 == 0B) goto <D.26546>; else goto <D.26547>;
  <D.26546>:
  iftmp.82 = 1;
  goto <D.26548>;
  <D.26547>:
  iftmp.82 = 0;
  <D.26548>:
  D.26552 = iftmp.82 != 0;
  D.26553 = (long int) D.26552;
  D.26554 = __builtin_expect (D.26553, 0);
  if (D.26554 != 0) goto <D.26555>; else goto <D.26556>;
  <D.26555>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2229, "method->klass->generic_class->container_class && method->klass->generic_class->container_class->generic_container");
  <D.26556>:
  D.26505 = method->klass;
  D.26538 = D.26505->generic_class;
  D.26549 = D.26538->container_class;
  D.26551 = D.26549->generic_container;
  D.26557 = has_constraints (D.26551);
  if (D.26557 != 0) goto <D.26558>; else goto <D.26559>;
  <D.26558>:
  D.26501 = 0;
  return D.26501;
  <D.26559>:
  <D.26540>:
  D.26505 = method->klass;
  D.26560 = D.26505->generic_container;
  if (D.26560 != 0B) goto <D.26561>; else goto <D.26562>;
  <D.26561>:
  if (allow_type_vars == 0) goto <D.26563>; else goto <D.26564>;
  <D.26563>:
  D.26501 = 0;
  return D.26501;
  <D.26564>:
  <D.26562>:
  D.26565 = is_async_method (method);
  if (D.26565 != 0) goto <D.26566>; else goto <D.26567>;
  <D.26566>:
  D.26568 = mini_method_is_open (method);
  if (D.26568 != 0) goto <D.26569>; else goto <D.26570>;
  <D.26569>:
  D.26501 = 1;
  return D.26501;
  <D.26570>:
  D.26501 = 0;
  return D.26501;
  <D.26567>:
  D.26501 = 1;
  return D.26501;
}


is_async_state_machine_class (struct MonoClass * klass)
{
  gboolean D.26572;
  int iclass_set.83;
  struct MonoImage * D.26576;
  struct MonoClass * iclass.84;
  struct MonoClass * iclass.85;
  unsigned char D.26581;
  unsigned char D.26582;
  int D.26585;
  static struct MonoClass * iclass;
  static gboolean iclass_set;

  D.26572 = 0;
  return D.26572;
  iclass_set.83 = iclass_set;
  if (iclass_set.83 == 0) goto <D.26574>; else goto <D.26575>;
  <D.26574>:
  D.26576 = mono_defaults.corlib;
  iclass.84 = mono_class_from_name (D.26576, "System.Runtime.CompilerServices", "IAsyncStateMachine");
  iclass = iclass.84;
  mono_memory_barrier ();
  iclass_set = 1;
  <D.26575>:
  iclass.85 = iclass;
  if (iclass.85 != 0B) goto <D.26579>; else goto <D.26580>;
  <D.26579>:
  D.26581 = BIT_FIELD_REF <*klass, 8, 160>;
  D.26582 = D.26581 & 8;
  if (D.26582 != 0) goto <D.26583>; else goto <D.26584>;
  <D.26583>:
  iclass.85 = iclass;
  D.26585 = mono_class_is_assignable_from (iclass.85, klass);
  if (D.26585 != 0) goto <D.26586>; else goto <D.26587>;
  <D.26586>:
  D.26572 = 1;
  return D.26572;
  <D.26587>:
  <D.26584>:
  <D.26580>:
  D.26572 = 0;
  return D.26572;
}


has_constraints (struct MonoGenericContainer * container)
{
  gboolean D.26589;

  D.26589 = 0;
  return D.26589;
}


is_async_method (struct MonoMethod * method)
{
  gboolean D.26591;
  int attr_class_set.86;
  struct MonoImage * D.26595;
  struct MonoClass * attr_class.87;
  struct MonoClass * attr_class.88;
  struct MonoType * D.26605;
  unsigned char D.26606;
  struct MonoGenericClass * D.26609;
  struct MonoClass * D.26610;
  int D.25074;
  int iftmp.89;
  int D.25073;
  const char[7] * D.26615;
  unsigned char D.26616;
  int D.26617;
  unsigned char D.26618;
  int D.26619;
  _Bool D.26620;
  _Bool D.26621;
  _Bool D.26622;
  const unsigned char * D.26625;
  unsigned char D.26626;
  int D.26627;
  const unsigned char * D.26628;
  unsigned char D.26629;
  int D.26630;
  _Bool D.26631;
  _Bool D.26632;
  const unsigned char * D.26635;
  unsigned char D.26636;
  int D.26637;
  const unsigned char * D.26638;
  unsigned char D.26639;
  int D.26640;
  _Bool D.26641;
  _Bool D.26642;
  const unsigned char * D.26645;
  unsigned char D.26646;
  int D.26647;
  const unsigned char * D.26648;
  unsigned char D.26649;
  int D.26650;
  const char * D.26652;
  int D.26655;
  struct MonoCustomAttrInfo * cattr;
  struct MonoMethodSignature * sig;
  gboolean res;
  static struct MonoClass * attr_class;
  static gboolean attr_class_set;

  res = 0;
  D.26591 = 0;
  return D.26591;
  attr_class_set.86 = attr_class_set;
  if (attr_class_set.86 == 0) goto <D.26593>; else goto <D.26594>;
  <D.26593>:
  D.26595 = mono_defaults.corlib;
  attr_class.87 = mono_class_from_name (D.26595, "System.Runtime.CompilerServices", "AsyncStateMachineAttribute");
  attr_class = attr_class.87;
  mono_memory_barrier ();
  attr_class_set = 1;
  <D.26594>:
  sig = mono_method_signature (method);
  attr_class.88 = attr_class;
  if (attr_class.88 != 0B) goto <D.26601>; else goto <D.26602>;
  <D.26601>:
  if (sig != 0B) goto <D.26603>; else goto <D.26604>;
  <D.26603>:
  D.26605 = sig->ret;
  D.26606 = D.26605->type;
  if (D.26606 == 1) goto <D.26597>; else goto <D.26607>;
  <D.26607>:
  D.26605 = sig->ret;
  D.26606 = D.26605->type;
  if (D.26606 == 18) goto <D.26608>; else goto <D.26598>;
  <D.26608>:
  D.26605 = sig->ret;
  D.26609 = D.26605->data.generic_class;
  D.26610 = D.26609->container_class;
  if (1 != 0) goto <D.26597>; else goto <D.26598>;
  <D.26598>:
  D.26605 = sig->ret;
  D.26606 = D.26605->type;
  if (D.26606 == 21) goto <D.26611>; else goto <D.26599>;
  <D.26611>:
  {
    size_t __s1_len;
    size_t __s2_len;

    __s2_len = 6;
    if (__s2_len <= 3) goto <D.26613>; else goto <D.26614>;
    <D.26613>:
    {
      const unsigned char * __s2;
      int __result;

      D.26605 = sig->ret;
      D.26609 = D.26605->data.generic_class;
      D.26610 = D.26609->container_class;
      __s2 = D.26610->name;
      D.26615 = "Task`1";
      D.26616 = MEM[(const unsigned char *)D.26615];
      D.26617 = (int) D.26616;
      D.26618 = *__s2;
      D.26619 = (int) D.26618;
      __result = D.26617 - D.26619;
      {
        D.26620 = __s2_len != 0;
        D.26621 = __result == 0;
        D.26622 = D.26620 & D.26621;
        if (D.26622 != 0) goto <D.26623>; else goto <D.26624>;
        <D.26623>:
        D.26625 = &MEM[(void *)"Task`1" + 1B];
        D.26626 = *D.26625;
        D.26627 = (int) D.26626;
        D.26628 = __s2 + 1;
        D.26629 = *D.26628;
        D.26630 = (int) D.26629;
        __result = D.26627 - D.26630;
        D.26631 = __s2_len > 1;
        D.26621 = __result == 0;
        D.26632 = D.26631 & D.26621;
        if (D.26632 != 0) goto <D.26633>; else goto <D.26634>;
        <D.26633>:
        D.26635 = &MEM[(void *)"Task`1" + 2B];
        D.26636 = *D.26635;
        D.26637 = (int) D.26636;
        D.26638 = __s2 + 2;
        D.26639 = *D.26638;
        D.26640 = (int) D.26639;
        __result = D.26637 - D.26640;
        D.26641 = __s2_len > 2;
        D.26621 = __result == 0;
        D.26642 = D.26641 & D.26621;
        if (D.26642 != 0) goto <D.26643>; else goto <D.26644>;
        <D.26643>:
        D.26645 = &MEM[(void *)"Task`1" + 3B];
        D.26646 = *D.26645;
        D.26647 = (int) D.26646;
        D.26648 = __s2 + 3;
        D.26649 = *D.26648;
        D.26650 = (int) D.26649;
        __result = D.26647 - D.26650;
        <D.26644>:
        <D.26634>:
        <D.26624>:
      }
      D.25073 = __result;
    }
    iftmp.89 = -D.25073;
    goto <D.26651>;
    <D.26614>:
    D.26605 = sig->ret;
    D.26609 = D.26605->data.generic_class;
    D.26610 = D.26609->container_class;
    D.26652 = D.26610->name;
    iftmp.89 = __builtin_strcmp (D.26652, "Task`1");
    <D.26651>:
    D.25074 = iftmp.89;
  }
  if (D.25074 == 0) goto <D.26597>; else goto <D.26599>;
  <D.26597>:
  cattr = mono_custom_attrs_from_method (method);
  if (cattr != 0B) goto <D.26653>; else goto <D.26654>;
  <D.26653>:
  attr_class.88 = attr_class;
  D.26655 = mono_custom_attrs_has_attr (cattr, attr_class.88);
  if (D.26655 != 0) goto <D.26656>; else goto <D.26657>;
  <D.26656>:
  res = 1;
  <D.26657>:
  mono_custom_attrs_free (cattr);
  <D.26654>:
  <D.26599>:
  <D.26604>:
  <D.26602>:
  D.26591 = res;
  return D.26591;
}


mini_method_is_open (struct MonoMethod * method)
{
  unsigned char D.26659;
  unsigned char D.26660;
  struct MonoGenericInst * D.26663;
  unsigned char D.26666;
  unsigned char D.26667;
  gboolean D.26670;
  struct MonoGenericInst * D.26671;
  unsigned char D.26674;
  unsigned char D.26675;

  D.26659 = BIT_FIELD_REF <*method, 8, 168>;
  D.26660 = D.26659 & 16;
  if (D.26660 != 0) goto <D.26661>; else goto <D.26662>;
  <D.26661>:
  {
    struct MonoGenericContext * ctx;

    ctx = mono_method_get_context (method);
    D.26663 = ctx->class_inst;
    if (D.26663 != 0B) goto <D.26664>; else goto <D.26665>;
    <D.26664>:
    D.26663 = ctx->class_inst;
    D.26666 = BIT_FIELD_REF <*D.26663, 8, 48>;
    D.26667 = D.26666 & 64;
    if (D.26667 != 0) goto <D.26668>; else goto <D.26669>;
    <D.26668>:
    D.26670 = 1;
    return D.26670;
    <D.26669>:
    <D.26665>:
    D.26671 = ctx->method_inst;
    if (D.26671 != 0B) goto <D.26672>; else goto <D.26673>;
    <D.26672>:
    D.26671 = ctx->method_inst;
    D.26674 = BIT_FIELD_REF <*D.26671, 8, 48>;
    D.26675 = D.26674 & 64;
    if (D.26675 != 0) goto <D.26676>; else goto <D.26677>;
    <D.26676>:
    D.26670 = 1;
    return D.26670;
    <D.26677>:
    <D.26673>:
  }
  <D.26662>:
  D.26670 = 0;
  return D.26670;
}


mono_method_is_generic_sharable (struct MonoMethod * method, gboolean allow_type_vars)
{
  gboolean D.26679;
  int D.26680;

  D.26680 = partial_sharing_supported ();
  D.26679 = mono_method_is_generic_sharable_full (method, allow_type_vars, D.26680, 1);
  return D.26679;
}


mono_method_needs_static_rgctx_invoke (struct MonoMethod * method, gboolean allow_type_vars)
{
  struct MonoClass * D.26682;
  int D.26683;
  gboolean D.26686;
  int D.26687;
  unsigned char D.26690;
  unsigned char D.26691;
  struct MonoGenericContext * D.26694;
  struct MonoGenericInst * D.26695;
  int iftmp.90;
  short unsigned int D.26703;
  int D.26704;
  int D.26705;
  unsigned char D.26707;
  unsigned char D.26708;
  struct MonoGenericClass * D.26709;
  struct MonoGenericContainer * D.26711;

  D.26682 = method->klass;
  D.26683 = mono_class_generic_sharing_enabled (D.26682);
  if (D.26683 == 0) goto <D.26684>; else goto <D.26685>;
  <D.26684>:
  D.26686 = 0;
  return D.26686;
  <D.26685>:
  D.26687 = mono_method_is_generic_sharable (method, allow_type_vars);
  if (D.26687 == 0) goto <D.26688>; else goto <D.26689>;
  <D.26688>:
  D.26686 = 0;
  return D.26686;
  <D.26689>:
  D.26690 = BIT_FIELD_REF <*method, 8, 168>;
  D.26691 = D.26690 & 16;
  if (D.26691 != 0) goto <D.26692>; else goto <D.26693>;
  <D.26692>:
  D.26694 = mono_method_get_context (method);
  D.26695 = D.26694->method_inst;
  if (D.26695 != 0B) goto <D.26696>; else goto <D.26697>;
  <D.26696>:
  D.26686 = 1;
  return D.26686;
  <D.26697>:
  <D.26693>:
  D.26703 = method->flags;
  D.26704 = (int) D.26703;
  D.26705 = D.26704 & 16;
  if (D.26705 != 0) goto <D.26699>; else goto <D.26706>;
  <D.26706>:
  D.26682 = method->klass;
  D.26707 = BIT_FIELD_REF <*D.26682, 8, 160>;
  D.26708 = D.26707 & 8;
  if (D.26708 != 0) goto <D.26699>; else goto <D.26700>;
  <D.26699>:
  D.26682 = method->klass;
  D.26709 = D.26682->generic_class;
  if (D.26709 != 0B) goto <D.26701>; else goto <D.26710>;
  <D.26710>:
  D.26682 = method->klass;
  D.26711 = D.26682->generic_container;
  if (D.26711 != 0B) goto <D.26701>; else goto <D.26700>;
  <D.26701>:
  iftmp.90 = 1;
  goto <D.26702>;
  <D.26700>:
  iftmp.90 = 0;
  <D.26702>:
  D.26686 = iftmp.90;
  return D.26686;
}


mono_method_construct_object_context (struct MonoMethod * method)
{
  struct MonoClass * D.26714;
  struct MonoGenericClass * D.26715;
  _Bool D.26716;
  long int D.26717;
  long int D.26718;
  struct MonoGenericContainer * D.26721;
  <unnamed-signed:31> D.26724;
  struct MonoGenericInst * D.26725;
  struct MonoGenericContext * D.26727;
  struct MonoGenericInst * D.26728;
  struct MonoGenericContext * D.26731;
  struct MonoGenericInst * D.26732;
  <unnamed-unsigned:22> D.26733;
  struct MonoGenericInst * D.26734;
  int iftmp.91;
  struct MonoGenericInst * D.26739;
  struct MonoGenericInst * D.26741;
  _Bool D.26743;
  long int D.26744;
  long int D.26745;
  struct MonoGenericContext object_context;

  try
    {
      D.26714 = method->klass;
      D.26715 = D.26714->generic_class;
      D.26716 = D.26715 != 0B;
      D.26717 = (long int) D.26716;
      D.26718 = __builtin_expect (D.26717, 0);
      if (D.26718 != 0) goto <D.26719>; else goto <D.26720>;
      <D.26719>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2298, "!method->klass->generic_class");
      <D.26720>:
      D.26714 = method->klass;
      D.26721 = D.26714->generic_container;
      if (D.26721 != 0B) goto <D.26722>; else goto <D.26723>;
      <D.26722>:
      {
        int type_argc;

        D.26714 = method->klass;
        D.26721 = D.26714->generic_container;
        D.26724 = D.26721->type_argc;
        type_argc = (int) D.26724;
        D.26725 = get_object_generic_inst (type_argc);
        object_context.class_inst = D.26725;
      }
      goto <D.26726>;
      <D.26723>:
      object_context.class_inst = 0B;
      <D.26726>:
      D.26727 = mono_method_get_context_general (method, 1);
      D.26728 = D.26727->method_inst;
      if (D.26728 != 0B) goto <D.26729>; else goto <D.26730>;
      <D.26729>:
      {
        int type_argc;

        D.26731 = mono_method_get_context_general (method, 1);
        D.26732 = D.26731->method_inst;
        D.26733 = D.26732->type_argc;
        type_argc = (int) D.26733;
        D.26734 = get_object_generic_inst (type_argc);
        object_context.method_inst = D.26734;
      }
      goto <D.26735>;
      <D.26730>:
      object_context.method_inst = 0B;
      <D.26735>:
      D.26739 = object_context.class_inst;
      if (D.26739 == 0B) goto <D.26740>; else goto <D.26737>;
      <D.26740>:
      D.26741 = object_context.method_inst;
      if (D.26741 == 0B) goto <D.26742>; else goto <D.26737>;
      <D.26742>:
      iftmp.91 = 1;
      goto <D.26738>;
      <D.26737>:
      iftmp.91 = 0;
      <D.26738>:
      D.26743 = iftmp.91 != 0;
      D.26744 = (long int) D.26743;
      D.26745 = __builtin_expect (D.26744, 0);
      if (D.26745 != 0) goto <D.26746>; else goto <D.26747>;
      <D.26746>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2315, "object_context.class_inst || object_context.method_inst");
      <D.26747>:
      <retval> = object_context;
      return <retval>;
    }
  finally
    {
      object_context = {CLOBBER};
    }
}


get_object_generic_inst (int type_argc)
{
  unsigned int type_argc.92;
  unsigned int D.26751;
  unsigned int i.93;
  unsigned int D.26753;
  struct MonoType * * D.26754;
  struct MonoClass * D.26755;
  struct MonoType * D.26756;
  struct MonoGenericInst * D.26757;
  struct MonoType * * type_argv;
  int i;

  type_argc.92 = (unsigned int) type_argc;
  D.26751 = type_argc.92 * 4;
  type_argv = __builtin_alloca (D.26751);
  i = 0;
  goto <D.25097>;
  <D.25096>:
  i.93 = (unsigned int) i;
  D.26753 = i.93 * 4;
  D.26754 = type_argv + D.26753;
  D.26755 = mono_defaults.object_class;
  D.26756 = &D.26755->byval_arg;
  *D.26754 = D.26756;
  i = i + 1;
  <D.25097>:
  if (i < type_argc) goto <D.25096>; else goto <D.25098>;
  <D.25098>:
  D.26757 = mono_metadata_get_generic_inst (type_argc, type_argv);
  return D.26757;
}


mono_set_generic_sharing_supported (gboolean supported)
{
  gshared_supported = supported;
}


mono_set_generic_sharing_vt_supported (gboolean supported)
{
  gsharedvt_supported = supported;
}


mono_set_partial_sharing_supported (gboolean supported)
{
  partial_supported = supported;
}


mono_class_generic_sharing_enabled (struct MonoClass * class)
{
  int inited.94;
  int gshared_supported.95;
  int D.25130;
  int iftmp.96;
  int D.25129;
  const char[7] * D.26771;
  unsigned char D.26772;
  int D.26773;
  unsigned char D.26774;
  int D.26775;
  _Bool D.26776;
  _Bool D.26777;
  _Bool D.26778;
  const unsigned char * D.26781;
  unsigned char D.26782;
  int D.26783;
  const unsigned char * D.26784;
  unsigned char D.26785;
  int D.26786;
  _Bool D.26787;
  _Bool D.26788;
  const unsigned char * D.26791;
  unsigned char D.26792;
  int D.26793;
  const unsigned char * D.26794;
  unsigned char D.26795;
  int D.26796;
  _Bool D.26797;
  _Bool D.26798;
  const unsigned char * D.26801;
  unsigned char D.26802;
  int D.26803;
  const unsigned char * D.26804;
  unsigned char D.26805;
  int D.26806;
  int D.25139;
  int iftmp.97;
  int D.25138;
  const char[12] * D.26814;
  unsigned char D.26815;
  int D.26816;
  unsigned char D.26817;
  int D.26818;
  _Bool D.26819;
  _Bool D.26820;
  _Bool D.26821;
  const unsigned char * D.26824;
  unsigned char D.26825;
  int D.26826;
  const unsigned char * D.26827;
  unsigned char D.26828;
  int D.26829;
  _Bool D.26830;
  _Bool D.26831;
  const unsigned char * D.26834;
  unsigned char D.26835;
  int D.26836;
  const unsigned char * D.26837;
  unsigned char D.26838;
  int D.26839;
  _Bool D.26840;
  _Bool D.26841;
  const unsigned char * D.26844;
  unsigned char D.26845;
  int D.26846;
  const unsigned char * D.26847;
  unsigned char D.26848;
  int D.26849;
  int D.25148;
  int iftmp.98;
  int D.25147;
  const char[4] * D.26857;
  unsigned char D.26858;
  int D.26859;
  unsigned char D.26860;
  int D.26861;
  _Bool D.26862;
  _Bool D.26863;
  _Bool D.26864;
  const unsigned char * D.26867;
  unsigned char D.26868;
  int D.26869;
  const unsigned char * D.26870;
  unsigned char D.26871;
  int D.26872;
  _Bool D.26873;
  _Bool D.26874;
  const unsigned char * D.26877;
  unsigned char D.26878;
  int D.26879;
  const unsigned char * D.26880;
  unsigned char D.26881;
  int D.26882;
  _Bool D.26883;
  _Bool D.26884;
  const unsigned char * D.26887;
  unsigned char D.26888;
  int D.26889;
  const unsigned char * D.26890;
  unsigned char D.26891;
  int D.26892;
  int D.25157;
  int iftmp.99;
  int D.25156;
  const char[5] * D.26900;
  unsigned char D.26901;
  int D.26902;
  unsigned char D.26903;
  int D.26904;
  _Bool D.26905;
  _Bool D.26906;
  _Bool D.26907;
  const unsigned char * D.26910;
  unsigned char D.26911;
  int D.26912;
  const unsigned char * D.26913;
  unsigned char D.26914;
  int D.26915;
  _Bool D.26916;
  _Bool D.26917;
  const unsigned char * D.26920;
  unsigned char D.26921;
  int D.26922;
  const unsigned char * D.26923;
  unsigned char D.26924;
  int D.26925;
  _Bool D.26926;
  _Bool D.26927;
  const unsigned char * D.26930;
  unsigned char D.26931;
  int D.26932;
  const unsigned char * D.26933;
  unsigned char D.26934;
  int D.26935;
  int generic_sharing.100;
  gboolean D.26943;
  struct MonoImage * D.26944;
  struct MonoImage * D.26945;
  _Bool D.26946;
  struct MonoClass * D.26949;
  const char * D.26950;
  static int generic_sharing = 0;
  static gboolean inited = 0;

  inited.94 = inited;
  if (inited.94 == 0) goto <D.26760>; else goto <D.26761>;
  <D.26760>:
  {
    const char * option;

    gshared_supported.95 = gshared_supported;
    if (gshared_supported.95 != 0) goto <D.26763>; else goto <D.26764>;
    <D.26763>:
    generic_sharing = 3;
    goto <D.26765>;
    <D.26764>:
    generic_sharing = 0;
    <D.26765>:
    option = monoeg_g_getenv ("MONO_GENERIC_SHARING");
    if (option != 0B) goto <D.26766>; else goto <D.26767>;
    <D.26766>:
    {
      size_t __s1_len;
      size_t __s2_len;

      __s2_len = 6;
      if (__s2_len <= 3) goto <D.26769>; else goto <D.26770>;
      <D.26769>:
      {
        const unsigned char * __s2;
        int __result;

        __s2 = option;
        D.26771 = "corlib";
        D.26772 = MEM[(const unsigned char *)D.26771];
        D.26773 = (int) D.26772;
        D.26774 = *__s2;
        D.26775 = (int) D.26774;
        __result = D.26773 - D.26775;
        {
          D.26776 = __s2_len != 0;
          D.26777 = __result == 0;
          D.26778 = D.26776 & D.26777;
          if (D.26778 != 0) goto <D.26779>; else goto <D.26780>;
          <D.26779>:
          D.26781 = &MEM[(void *)"corlib" + 1B];
          D.26782 = *D.26781;
          D.26783 = (int) D.26782;
          D.26784 = __s2 + 1;
          D.26785 = *D.26784;
          D.26786 = (int) D.26785;
          __result = D.26783 - D.26786;
          D.26787 = __s2_len > 1;
          D.26777 = __result == 0;
          D.26788 = D.26787 & D.26777;
          if (D.26788 != 0) goto <D.26789>; else goto <D.26790>;
          <D.26789>:
          D.26791 = &MEM[(void *)"corlib" + 2B];
          D.26792 = *D.26791;
          D.26793 = (int) D.26792;
          D.26794 = __s2 + 2;
          D.26795 = *D.26794;
          D.26796 = (int) D.26795;
          __result = D.26793 - D.26796;
          D.26797 = __s2_len > 2;
          D.26777 = __result == 0;
          D.26798 = D.26797 & D.26777;
          if (D.26798 != 0) goto <D.26799>; else goto <D.26800>;
          <D.26799>:
          D.26801 = &MEM[(void *)"corlib" + 3B];
          D.26802 = *D.26801;
          D.26803 = (int) D.26802;
          D.26804 = __s2 + 3;
          D.26805 = *D.26804;
          D.26806 = (int) D.26805;
          __result = D.26803 - D.26806;
          <D.26800>:
          <D.26790>:
          <D.26780>:
        }
        D.25129 = __result;
      }
      iftmp.96 = -D.25129;
      goto <D.26807>;
      <D.26770>:
      iftmp.96 = __builtin_strcmp (option, "corlib");
      <D.26807>:
      D.25130 = iftmp.96;
    }
    if (D.25130 == 0) goto <D.26808>; else goto <D.26809>;
    <D.26808>:
    generic_sharing = 2;
    goto <D.26810>;
    <D.26809>:
    {
      size_t __s1_len;
      size_t __s2_len;

      __s2_len = 11;
      if (__s2_len <= 3) goto <D.26812>; else goto <D.26813>;
      <D.26812>:
      {
        const unsigned char * __s2;
        int __result;

        __s2 = option;
        D.26814 = "collections";
        D.26815 = MEM[(const unsigned char *)D.26814];
        D.26816 = (int) D.26815;
        D.26817 = *__s2;
        D.26818 = (int) D.26817;
        __result = D.26816 - D.26818;
        {
          D.26819 = __s2_len != 0;
          D.26820 = __result == 0;
          D.26821 = D.26819 & D.26820;
          if (D.26821 != 0) goto <D.26822>; else goto <D.26823>;
          <D.26822>:
          D.26824 = &MEM[(void *)"collections" + 1B];
          D.26825 = *D.26824;
          D.26826 = (int) D.26825;
          D.26827 = __s2 + 1;
          D.26828 = *D.26827;
          D.26829 = (int) D.26828;
          __result = D.26826 - D.26829;
          D.26830 = __s2_len > 1;
          D.26820 = __result == 0;
          D.26831 = D.26830 & D.26820;
          if (D.26831 != 0) goto <D.26832>; else goto <D.26833>;
          <D.26832>:
          D.26834 = &MEM[(void *)"collections" + 2B];
          D.26835 = *D.26834;
          D.26836 = (int) D.26835;
          D.26837 = __s2 + 2;
          D.26838 = *D.26837;
          D.26839 = (int) D.26838;
          __result = D.26836 - D.26839;
          D.26840 = __s2_len > 2;
          D.26820 = __result == 0;
          D.26841 = D.26840 & D.26820;
          if (D.26841 != 0) goto <D.26842>; else goto <D.26843>;
          <D.26842>:
          D.26844 = &MEM[(void *)"collections" + 3B];
          D.26845 = *D.26844;
          D.26846 = (int) D.26845;
          D.26847 = __s2 + 3;
          D.26848 = *D.26847;
          D.26849 = (int) D.26848;
          __result = D.26846 - D.26849;
          <D.26843>:
          <D.26833>:
          <D.26823>:
        }
        D.25138 = __result;
      }
      iftmp.97 = -D.25138;
      goto <D.26850>;
      <D.26813>:
      iftmp.97 = __builtin_strcmp (option, "collections");
      <D.26850>:
      D.25139 = iftmp.97;
    }
    if (D.25139 == 0) goto <D.26851>; else goto <D.26852>;
    <D.26851>:
    generic_sharing = 1;
    goto <D.26853>;
    <D.26852>:
    {
      size_t __s1_len;
      size_t __s2_len;

      __s2_len = 3;
      if (__s2_len <= 3) goto <D.26855>; else goto <D.26856>;
      <D.26855>:
      {
        const unsigned char * __s2;
        int __result;

        __s2 = option;
        D.26857 = "all";
        D.26858 = MEM[(const unsigned char *)D.26857];
        D.26859 = (int) D.26858;
        D.26860 = *__s2;
        D.26861 = (int) D.26860;
        __result = D.26859 - D.26861;
        {
          D.26862 = __s2_len != 0;
          D.26863 = __result == 0;
          D.26864 = D.26862 & D.26863;
          if (D.26864 != 0) goto <D.26865>; else goto <D.26866>;
          <D.26865>:
          D.26867 = &MEM[(void *)"all" + 1B];
          D.26868 = *D.26867;
          D.26869 = (int) D.26868;
          D.26870 = __s2 + 1;
          D.26871 = *D.26870;
          D.26872 = (int) D.26871;
          __result = D.26869 - D.26872;
          D.26873 = __s2_len > 1;
          D.26863 = __result == 0;
          D.26874 = D.26873 & D.26863;
          if (D.26874 != 0) goto <D.26875>; else goto <D.26876>;
          <D.26875>:
          D.26877 = &MEM[(void *)"all" + 2B];
          D.26878 = *D.26877;
          D.26879 = (int) D.26878;
          D.26880 = __s2 + 2;
          D.26881 = *D.26880;
          D.26882 = (int) D.26881;
          __result = D.26879 - D.26882;
          D.26883 = __s2_len > 2;
          D.26863 = __result == 0;
          D.26884 = D.26883 & D.26863;
          if (D.26884 != 0) goto <D.26885>; else goto <D.26886>;
          <D.26885>:
          D.26887 = &MEM[(void *)"all" + 3B];
          D.26888 = *D.26887;
          D.26889 = (int) D.26888;
          D.26890 = __s2 + 3;
          D.26891 = *D.26890;
          D.26892 = (int) D.26891;
          __result = D.26889 - D.26892;
          <D.26886>:
          <D.26876>:
          <D.26866>:
        }
        D.25147 = __result;
      }
      iftmp.98 = -D.25147;
      goto <D.26893>;
      <D.26856>:
      iftmp.98 = __builtin_strcmp (option, "all");
      <D.26893>:
      D.25148 = iftmp.98;
    }
    if (D.25148 == 0) goto <D.26894>; else goto <D.26895>;
    <D.26894>:
    generic_sharing = 3;
    goto <D.26896>;
    <D.26895>:
    {
      size_t __s1_len;
      size_t __s2_len;

      __s2_len = 4;
      if (__s2_len <= 3) goto <D.26898>; else goto <D.26899>;
      <D.26898>:
      {
        const unsigned char * __s2;
        int __result;

        __s2 = option;
        D.26900 = "none";
        D.26901 = MEM[(const unsigned char *)D.26900];
        D.26902 = (int) D.26901;
        D.26903 = *__s2;
        D.26904 = (int) D.26903;
        __result = D.26902 - D.26904;
        {
          D.26905 = __s2_len != 0;
          D.26906 = __result == 0;
          D.26907 = D.26905 & D.26906;
          if (D.26907 != 0) goto <D.26908>; else goto <D.26909>;
          <D.26908>:
          D.26910 = &MEM[(void *)"none" + 1B];
          D.26911 = *D.26910;
          D.26912 = (int) D.26911;
          D.26913 = __s2 + 1;
          D.26914 = *D.26913;
          D.26915 = (int) D.26914;
          __result = D.26912 - D.26915;
          D.26916 = __s2_len > 1;
          D.26906 = __result == 0;
          D.26917 = D.26916 & D.26906;
          if (D.26917 != 0) goto <D.26918>; else goto <D.26919>;
          <D.26918>:
          D.26920 = &MEM[(void *)"none" + 2B];
          D.26921 = *D.26920;
          D.26922 = (int) D.26921;
          D.26923 = __s2 + 2;
          D.26924 = *D.26923;
          D.26925 = (int) D.26924;
          __result = D.26922 - D.26925;
          D.26926 = __s2_len > 2;
          D.26906 = __result == 0;
          D.26927 = D.26926 & D.26906;
          if (D.26927 != 0) goto <D.26928>; else goto <D.26929>;
          <D.26928>:
          D.26930 = &MEM[(void *)"none" + 3B];
          D.26931 = *D.26930;
          D.26932 = (int) D.26931;
          D.26933 = __s2 + 3;
          D.26934 = *D.26933;
          D.26935 = (int) D.26934;
          __result = D.26932 - D.26935;
          <D.26929>:
          <D.26919>:
          <D.26909>:
        }
        D.25156 = __result;
      }
      iftmp.99 = -D.25156;
      goto <D.26936>;
      <D.26899>:
      iftmp.99 = __builtin_strcmp (option, "none");
      <D.26936>:
      D.25157 = iftmp.99;
    }
    if (D.25157 == 0) goto <D.26937>; else goto <D.26938>;
    <D.26937>:
    generic_sharing = 0;
    goto <D.26939>;
    <D.26938>:
    monoeg_g_log (0B, 16, "Unknown generic sharing option `%s\'.", option);
    <D.26939>:
    <D.26896>:
    <D.26853>:
    <D.26810>:
    <D.26767>:
    gshared_supported.95 = gshared_supported;
    if (gshared_supported.95 == 0) goto <D.26940>; else goto <D.26941>;
    <D.26940>:
    generic_sharing = 0;
    <D.26941>:
    inited = 1;
  }
  <D.26761>:
  generic_sharing.100 = generic_sharing;
  switch (generic_sharing.100) <default: <D.25165>, case 0: <D.25158>, case 1: <D.25161>, case 2: <D.25160>, case 3: <D.25159>>
  <D.25158>:
  D.26943 = 0;
  return D.26943;
  <D.25159>:
  D.26943 = 1;
  return D.26943;
  <D.25160>:
  D.26944 = class->image;
  D.26945 = mono_defaults.corlib;
  D.26946 = D.26944 == D.26945;
  D.26943 = (gboolean) D.26946;
  return D.26943;
  <D.25161>:
  D.26944 = class->image;
  D.26945 = mono_defaults.corlib;
  if (D.26944 != D.26945) goto <D.26947>; else goto <D.26948>;
  <D.26947>:
  D.26943 = 0;
  return D.26943;
  <D.26948>:
  goto <D.25163>;
  <D.25162>:
  class = class->nested_in;
  <D.25163>:
  D.26949 = class->nested_in;
  if (D.26949 != 0B) goto <D.25162>; else goto <D.25164>;
  <D.25164>:
  D.26950 = class->name_space;
  D.26943 = monoeg_g_str_has_prefix (D.26950, "System.Collections.Generic");
  return D.26943;
  <D.25165>:
  monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 2398);
  D.26943 = 0;
  return D.26943;
}


mono_get_generic_context_from_code (guint8 * code)
{
  struct MonoDomain * D.26952;
  _Bool D.26953;
  long int D.26954;
  long int D.26955;
  struct MonoGenericSharingContext * D.26958;
  struct MonoJitInfo * jit_info;

  D.26952 = mono_domain_get ();
  jit_info = mini_jit_info_table_find (D.26952, code, 0B);
  D.26953 = jit_info == 0B;
  D.26954 = (long int) D.26953;
  D.26955 = __builtin_expect (D.26954, 0);
  if (D.26955 != 0) goto <D.26956>; else goto <D.26957>;
  <D.26956>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2414, "jit_info");
  <D.26957>:
  D.26958 = mono_jit_info_get_generic_sharing_context (jit_info);
  return D.26958;
}


mini_method_get_context (struct MonoMethod * method)
{
  struct MonoGenericContext * D.26960;

  D.26960 = mono_method_get_context_general (method, 1);
  return D.26960;
}


mono_method_check_context_used (struct MonoMethod * method)
{
  struct MonoClass * D.26964;
  unsigned char D.26965;
  int D.26969;
  int D.26970;
  struct MonoGenericContext * method_context;
  int context_used;

  method_context = mini_method_get_context (method);
  context_used = 0;
  if (method_context == 0B) goto <D.26962>; else goto <D.26963>;
  <D.26962>:
  D.26964 = method->klass;
  D.26965 = D.26964->rank;
  if (D.26965 != 0) goto <D.26966>; else goto <D.26967>;
  <D.26966>:
  D.26964 = method->klass;
  context_used = mono_class_check_context_used (D.26964);
  <D.26967>:
  goto <D.26968>;
  <D.26963>:
  context_used = mono_generic_context_check_used (method_context);
  D.26964 = method->klass;
  D.26969 = mono_class_check_context_used (D.26964);
  context_used = D.26969 | context_used;
  <D.26968>:
  D.26970 = context_used;
  return D.26970;
}


mono_generic_context_equal_deep (struct MonoGenericContext * context1, struct MonoGenericContext * context2)
{
  gboolean D.26972;
  int iftmp.101;
  struct MonoGenericInst * D.26976;
  struct MonoGenericInst * D.26977;
  int D.26978;
  struct MonoGenericInst * D.26980;
  struct MonoGenericInst * D.26981;
  int D.26982;

  D.26976 = context1->class_inst;
  D.26977 = context2->class_inst;
  D.26978 = generic_inst_equal (D.26976, D.26977);
  if (D.26978 != 0) goto <D.26979>; else goto <D.26974>;
  <D.26979>:
  D.26980 = context1->method_inst;
  D.26981 = context2->method_inst;
  D.26982 = generic_inst_equal (D.26980, D.26981);
  if (D.26982 != 0) goto <D.26983>; else goto <D.26974>;
  <D.26983>:
  iftmp.101 = 1;
  goto <D.26975>;
  <D.26974>:
  iftmp.101 = 0;
  <D.26975>:
  D.26972 = iftmp.101;
  return D.26972;
}


generic_inst_equal (struct MonoGenericInst * inst1, struct MonoGenericInst * inst2)
{
  _Bool D.26987;
  long int D.26988;
  long int D.26989;
  gboolean D.26992;
  _Bool D.26993;
  long int D.26994;
  long int D.26995;
  unsigned int D.26998;
  unsigned int D.26999;
  unsigned int D.27000;
  unsigned int D.27001;
  struct MonoType * D.27004;
  struct MonoType * D.27005;
  int D.27006;
  <unnamed-unsigned:22> D.27009;
  int D.27010;
  int i;

  if (inst1 == 0B) goto <D.26985>; else goto <D.26986>;
  <D.26985>:
  D.26987 = inst2 != 0B;
  D.26988 = (long int) D.26987;
  D.26989 = __builtin_expect (D.26988, 0);
  if (D.26989 != 0) goto <D.26990>; else goto <D.26991>;
  <D.26990>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2458, "!inst2");
  <D.26991>:
  D.26992 = 1;
  return D.26992;
  <D.26986>:
  D.26993 = inst2 == 0B;
  D.26994 = (long int) D.26993;
  D.26995 = __builtin_expect (D.26994, 0);
  if (D.26995 != 0) goto <D.26996>; else goto <D.26997>;
  <D.26996>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2462, "inst2");
  <D.26997>:
  D.26998 = BIT_FIELD_REF <*inst1, 32, 32>;
  D.26999 = BIT_FIELD_REF <*inst2, 32, 32>;
  D.27000 = D.26998 ^ D.26999;
  D.27001 = D.27000 & 4194303;
  if (D.27001 != 0) goto <D.27002>; else goto <D.27003>;
  <D.27002>:
  D.26992 = 0;
  return D.26992;
  <D.27003>:
  i = 0;
  goto <D.25184>;
  <D.25183>:
  D.27004 = inst1->type_argv[i];
  D.27005 = inst2->type_argv[i];
  D.27006 = mono_metadata_type_equal (D.27004, D.27005);
  if (D.27006 == 0) goto <D.27007>; else goto <D.27008>;
  <D.27007>:
  D.26992 = 0;
  return D.26992;
  <D.27008>:
  i = i + 1;
  <D.25184>:
  D.27009 = inst1->type_argc;
  D.27010 = (int) D.27009;
  if (D.27010 > i) goto <D.25183>; else goto <D.25185>;
  <D.25185>:
  D.26992 = 1;
  return D.26992;
}


mini_class_get_container_class (struct MonoClass * class)
{
  struct MonoGenericClass * D.27012;
  struct MonoClass * D.27015;
  struct MonoGenericContainer * D.27016;
  _Bool D.27017;
  long int D.27018;
  long int D.27019;

  D.27012 = class->generic_class;
  if (D.27012 != 0B) goto <D.27013>; else goto <D.27014>;
  <D.27013>:
  D.27012 = class->generic_class;
  D.27015 = D.27012->container_class;
  return D.27015;
  <D.27014>:
  D.27016 = class->generic_container;
  D.27017 = D.27016 == 0B;
  D.27018 = (long int) D.27017;
  D.27019 = __builtin_expect (D.27018, 0);
  if (D.27019 != 0) goto <D.27020>; else goto <D.27021>;
  <D.27020>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2502, "class->generic_container");
  <D.27021>:
  D.27015 = class;
  return D.27015;
}


mini_class_get_context (struct MonoClass * class)
{
  struct MonoGenericClass * D.27023;
  struct MonoGenericContext * D.27026;
  struct MonoGenericContainer * D.27027;
  _Bool D.27028;
  long int D.27029;
  long int D.27030;

  D.27023 = class->generic_class;
  if (D.27023 != 0B) goto <D.27024>; else goto <D.27025>;
  <D.27024>:
  D.27023 = class->generic_class;
  D.27026 = &D.27023->context;
  return D.27026;
  <D.27025>:
  D.27027 = class->generic_container;
  D.27028 = D.27027 == 0B;
  D.27029 = (long int) D.27028;
  D.27030 = __builtin_expect (D.27029, 0);
  if (D.27030 != 0) goto <D.27031>; else goto <D.27032>;
  <D.27031>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 2518, "class->generic_container");
  <D.27032>:
  D.27027 = class->generic_container;
  D.27026 = &D.27027->context;
  return D.27026;
}


mini_get_basic_type_from_generic (struct MonoGenericSharingContext * gsctx, struct MonoType * type)
{
  unsigned char D.27035;
  unsigned char D.27036;
  unsigned char D.27038;
  _Bool D.27039;
  _Bool D.27040;
  _Bool D.27041;
  int D.27043;
  struct MonoType * D.27045;

  D.27035 = BIT_FIELD_REF <*type, 8, 56>;
  D.27036 = D.27035 & 64;
  if (D.27036 == 0) goto <D.27037>; else goto <D.27034>;
  <D.27037>:
  D.27038 = type->type;
  D.27039 = D.27038 == 19;
  D.27040 = D.27038 == 30;
  D.27041 = D.27039 | D.27040;
  if (D.27041 != 0) goto <D.27042>; else goto <D.27034>;
  <D.27042>:
  D.27043 = mini_is_gsharedvt_type_gsctx (gsctx, type);
  if (D.27043 != 0) goto <D.27044>; else goto <D.27034>;
  <D.27044>:
  D.27045 = type;
  return D.27045;
  <D.27034>:
  D.27045 = mono_type_get_basic_type_from_generic (type);
  return D.27045;
}


mini_type_get_underlying_type (struct MonoGenericSharingContext * gsctx, struct MonoType * type)
{
  unsigned char D.27047;
  unsigned char D.27048;
  struct MonoType * D.27051;
  struct MonoClass * D.27052;
  unsigned char D.27055;
  _Bool D.27056;
  _Bool D.27057;
  _Bool D.27058;
  int D.27061;
  struct MonoType * D.27064;

  D.27047 = BIT_FIELD_REF <*type, 8, 56>;
  D.27048 = D.27047 & 64;
  if (D.27048 != 0) goto <D.27049>; else goto <D.27050>;
  <D.27049>:
  D.27052 = mono_defaults.int_class;
  D.27051 = &D.27052->byval_arg;
  return D.27051;
  <D.27050>:
  D.27047 = BIT_FIELD_REF <*type, 8, 56>;
  D.27048 = D.27047 & 64;
  if (D.27048 == 0) goto <D.27053>; else goto <D.27054>;
  <D.27053>:
  D.27055 = type->type;
  D.27056 = D.27055 == 19;
  D.27057 = D.27055 == 30;
  D.27058 = D.27056 | D.27057;
  if (D.27058 != 0) goto <D.27059>; else goto <D.27060>;
  <D.27059>:
  D.27061 = mini_is_gsharedvt_type_gsctx (gsctx, type);
  if (D.27061 != 0) goto <D.27062>; else goto <D.27063>;
  <D.27062>:
  D.27051 = type;
  return D.27051;
  <D.27063>:
  <D.27060>:
  <D.27054>:
  D.27064 = mono_type_get_underlying_type (type);
  D.27051 = mini_get_basic_type_from_generic (gsctx, D.27064);
  return D.27051;
}


mini_type_stack_size (struct MonoGenericSharingContext * gsctx, struct MonoType * t, int * align)
{
  int D.27066;
  gboolean allow_open;

  allow_open = 1;
  D.27066 = mono_type_stack_size_internal (t, align, allow_open);
  return D.27066;
}


mini_type_stack_size_full (struct MonoGenericSharingContext * gsctx, struct MonoType * t, guint32 * align, gboolean pinvoke)
{
  int ialign.102;
  unsigned int ialign.103;
  int D.27076;
  int size;

  if (pinvoke != 0) goto <D.27068>; else goto <D.27069>;
  <D.27068>:
  size = mono_type_native_stack_size (t, align);
  goto <D.27070>;
  <D.27069>:
  {
    int ialign;

    try
      {
        if (align != 0B) goto <D.27071>; else goto <D.27072>;
        <D.27071>:
        size = mini_type_stack_size (gsctx, t, &ialign);
        ialign.102 = ialign;
        ialign.103 = (unsigned int) ialign.102;
        *align = ialign.103;
        goto <D.27075>;
        <D.27072>:
        size = mini_type_stack_size (gsctx, t, 0B);
        <D.27075>:
      }
    finally
      {
        ialign = {CLOBBER};
      }
  }
  <D.27070>:
  D.27076 = size;
  return D.27076;
}


mono_generic_sharing_init ()
{
  mono_install_image_unload_hook (mono_class_unregister_image_generic_subclasses, 0B);
}


mono_class_unregister_image_generic_subclasses (struct MonoImage * image, void * user_data)
{
  struct GHashTable * generic_subclass_hash.104;
  struct GHashTable * generic_subclass_hash.105;
  struct GHashTable * old_hash;

  generic_subclass_hash.104 = generic_subclass_hash;
  if (generic_subclass_hash.104 == 0B) goto <D.27079>; else goto <D.27080>;
  <D.27079>:
  return;
  <D.27080>:
  mono_loader_lock ();
  old_hash = generic_subclass_hash;
  generic_subclass_hash.105 = monoeg_g_hash_table_new (mono_aligned_addr_hash, 0B);
  generic_subclass_hash = generic_subclass_hash.105;
  monoeg_g_hash_table_foreach (old_hash, move_subclasses_not_in_image_foreach_func, image);
  mono_loader_unlock ();
  monoeg_g_hash_table_destroy (old_hash);
}


move_subclasses_not_in_image_foreach_func (struct MonoClass * class, struct MonoClass * subclass, struct MonoImage * image)
{
  struct MonoImage * D.27083;
  struct MonoImage * D.27086;
  _Bool D.27087;
  long int D.27088;
  long int D.27089;
  struct MonoRuntimeGenericContextTemplate * D.27092;
  struct GHashTable * generic_subclass_hash.106;
  struct MonoClass * new_list;

  D.27083 = class->image;
  if (D.27083 == image) goto <D.27084>; else goto <D.27085>;
  <D.27084>:
  goto <D.24433>;
  <D.24432>:
  D.27086 = subclass->image;
  D.27087 = D.27086 != image;
  D.27088 = (long int) D.27087;
  D.27089 = __builtin_expect (D.27088, 0);
  if (D.27089 != 0) goto <D.27090>; else goto <D.27091>;
  <D.27090>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "mini-generic-sharing.c", 285, "subclass->image == image");
  <D.27091>:
  D.27092 = class_lookup_rgctx_template (subclass);
  subclass = D.27092->next_subclass;
  <D.24433>:
  if (subclass != 0B) goto <D.24432>; else goto <D.24434>;
  <D.24434>:
  return;
  <D.27085>:
  new_list = 0B;
  goto <D.24438>;
  <D.24437>:
  {
    struct MonoRuntimeGenericContextTemplate * subclass_template;
    struct MonoClass * next;

    subclass_template = class_lookup_rgctx_template (subclass);
    next = subclass_template->next_subclass;
    D.27086 = subclass->image;
    if (D.27086 != image) goto <D.27093>; else goto <D.27094>;
    <D.27093>:
    subclass_template->next_subclass = new_list;
    new_list = subclass;
    <D.27094>:
    subclass = next;
  }
  <D.24438>:
  if (subclass != 0B) goto <D.24437>; else goto <D.24439>;
  <D.24439>:
  if (new_list != 0B) goto <D.27095>; else goto <D.27096>;
  <D.27095>:
  generic_subclass_hash.106 = generic_subclass_hash;
  monoeg_g_hash_table_insert_replace (generic_subclass_hash.106, class, new_list, 0);
  <D.27096>:
}


mono_generic_sharing_cleanup ()
{
  struct GHashTable * generic_subclass_hash.107;

  mono_remove_image_unload_hook (mono_class_unregister_image_generic_subclasses, 0B);
  generic_subclass_hash.107 = generic_subclass_hash;
  if (generic_subclass_hash.107 != 0B) goto <D.27100>; else goto <D.27101>;
  <D.27100>:
  generic_subclass_hash.107 = generic_subclass_hash;
  monoeg_g_hash_table_destroy (generic_subclass_hash.107);
  <D.27101>:
}


mini_type_var_is_vt (struct MonoCompile * cfg, struct MonoType * type)
{
  unsigned char D.27102;
  struct MonoGenericSharingContext * D.27106;
  gboolean * D.27107;
  struct MonoGenericParam * D.27109;
  short unsigned int D.27110;
  unsigned int D.27111;
  unsigned int D.27112;
  gboolean * D.27113;
  int D.27114;
  gboolean D.27116;
  gboolean * D.27120;
  gboolean * D.27122;
  int D.27123;

  D.27102 = type->type;
  if (D.27102 == 19) goto <D.27103>; else goto <D.27104>;
  <D.27103>:
  D.27106 = cfg->generic_sharing_context;
  D.27107 = D.27106->var_is_vt;
  if (D.27107 != 0B) goto <D.27108>; else goto <D.27105>;
  <D.27108>:
  D.27106 = cfg->generic_sharing_context;
  D.27107 = D.27106->var_is_vt;
  D.27109 = type->data.generic_param;
  D.27110 = D.27109->num;
  D.27111 = (unsigned int) D.27110;
  D.27112 = D.27111 * 4;
  D.27113 = D.27107 + D.27112;
  D.27114 = *D.27113;
  if (D.27114 != 0) goto <D.27115>; else goto <D.27105>;
  <D.27115>:
  D.27116 = 1;
  return D.27116;
  <D.27105>:
  D.27116 = 0;
  return D.27116;
  <D.27104>:
  D.27102 = type->type;
  if (D.27102 == 30) goto <D.27117>; else goto <D.27118>;
  <D.27117>:
  D.27106 = cfg->generic_sharing_context;
  D.27120 = D.27106->mvar_is_vt;
  if (D.27120 != 0B) goto <D.27121>; else goto <D.27119>;
  <D.27121>:
  D.27106 = cfg->generic_sharing_context;
  D.27120 = D.27106->mvar_is_vt;
  D.27109 = type->data.generic_param;
  D.27110 = D.27109->num;
  D.27111 = (unsigned int) D.27110;
  D.27112 = D.27111 * 4;
  D.27122 = D.27120 + D.27112;
  D.27123 = *D.27122;
  if (D.27123 != 0) goto <D.27124>; else goto <D.27119>;
  <D.27124>:
  D.27116 = 1;
  return D.27116;
  <D.27119>:
  D.27116 = 0;
  return D.27116;
  <D.27118>:
  monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "mini-generic-sharing.c", 2651);
  D.27116 = 0;
  return D.27116;
}


mini_type_is_reference (struct MonoCompile * cfg, struct MonoType * type)
{
  int D.27126;
  gboolean D.27129;
  struct MonoGenericSharingContext * D.27130;
  int iftmp.108;
  unsigned char D.27136;
  _Bool D.27137;
  _Bool D.27138;
  _Bool D.27139;
  int D.27141;

  D.27126 = mono_type_is_reference (type);
  if (D.27126 != 0) goto <D.27127>; else goto <D.27128>;
  <D.27127>:
  D.27129 = 1;
  return D.27129;
  <D.27128>:
  D.27130 = cfg->generic_sharing_context;
  if (D.27130 == 0B) goto <D.27131>; else goto <D.27132>;
  <D.27131>:
  D.27129 = 0;
  return D.27129;
  <D.27132>:
  D.27136 = type->type;
  D.27137 = D.27136 == 19;
  D.27138 = D.27136 == 30;
  D.27139 = D.27137 | D.27138;
  if (D.27139 != 0) goto <D.27140>; else goto <D.27134>;
  <D.27140>:
  D.27141 = mini_type_var_is_vt (cfg, type);
  if (D.27141 == 0) goto <D.27142>; else goto <D.27134>;
  <D.27142>:
  iftmp.108 = 1;
  goto <D.27135>;
  <D.27134>:
  iftmp.108 = 0;
  <D.27135>:
  D.27129 = iftmp.108;
  return D.27129;
}


mini_method_get_rgctx (struct MonoMethod * m)
{
  struct MonoGenericContext * D.27144;
  struct MonoGenericInst * D.27145;
  void * D.27148;
  struct MonoDomain * D.27149;
  struct MonoClass * D.27150;
  struct MonoVTable * D.27151;
  struct MonoGenericContext * D.27152;
  struct MonoGenericInst * D.27153;
  struct MonoDomain * D.27154;

  D.27144 = mini_method_get_context (m);
  D.27145 = D.27144->method_inst;
  if (D.27145 != 0B) goto <D.27146>; else goto <D.27147>;
  <D.27146>:
  D.27149 = mono_domain_get ();
  D.27150 = m->klass;
  D.27151 = mono_class_vtable (D.27149, D.27150);
  D.27152 = mini_method_get_context (m);
  D.27153 = D.27152->method_inst;
  D.27148 = mono_method_lookup_rgctx (D.27151, D.27153);
  return D.27148;
  <D.27147>:
  D.27154 = mono_domain_get ();
  D.27150 = m->klass;
  D.27148 = mono_class_vtable (D.27154, D.27150);
  return D.27148;
}


mini_type_is_vtype (struct MonoCompile * cfg, struct MonoType * t)
{
  gboolean D.27156;
  int iftmp.109;
  int D.27161;
  int D.27163;

  D.27161 = mono_type_is_struct (t);
  if (D.27161 != 0) goto <D.27158>; else goto <D.27162>;
  <D.27162>:
  D.27163 = mini_is_gsharedvt_variable_type (cfg, t);
  if (D.27163 != 0) goto <D.27158>; else goto <D.27159>;
  <D.27158>:
  iftmp.109 = 1;
  goto <D.27160>;
  <D.27159>:
  iftmp.109 = 0;
  <D.27160>:
  D.27156 = iftmp.109;
  return D.27156;
}


mini_class_is_generic_sharable (struct MonoClass * klass)
{
  struct MonoGenericClass * D.27165;
  int D.27168;
  gboolean D.27171;
  int iftmp.110;
  struct MonoGenericContext * D.27176;
  int D.27177;

  D.27165 = klass->generic_class;
  if (D.27165 != 0B) goto <D.27166>; else goto <D.27167>;
  <D.27166>:
  D.27168 = is_async_state_machine_class (klass);
  if (D.27168 != 0) goto <D.27169>; else goto <D.27170>;
  <D.27169>:
  D.27171 = 0;
  return D.27171;
  <D.27170>:
  <D.27167>:
  D.27165 = klass->generic_class;
  if (D.27165 != 0B) goto <D.27175>; else goto <D.27173>;
  <D.27175>:
  D.27165 = klass->generic_class;
  D.27176 = &D.27165->context;
  D.27177 = mono_generic_context_is_sharable (D.27176, 0);
  if (D.27177 != 0) goto <D.27178>; else goto <D.27173>;
  <D.27178>:
  iftmp.110 = 1;
  goto <D.27174>;
  <D.27173>:
  iftmp.110 = 0;
  <D.27174>:
  D.27171 = iftmp.110;
  return D.27171;
}


mini_is_gsharedvt_variable_klass (struct MonoCompile * cfg, struct MonoClass * klass)
{
  gboolean D.27180;
  struct MonoType * D.27181;

  D.27181 = &klass->byval_arg;
  D.27180 = mini_is_gsharedvt_variable_type (cfg, D.27181);
  return D.27180;
}


mini_is_gsharedvt_type_gsctx (struct MonoGenericSharingContext * gsctx, struct MonoType * t)
{
  gboolean D.27183;

  D.27183 = 0;
  return D.27183;
}


mini_is_gsharedvt_type (struct MonoCompile * cfg, struct MonoType * t)
{
  gboolean D.27185;

  D.27185 = 0;
  return D.27185;
}


mini_is_gsharedvt_klass (struct MonoCompile * cfg, struct MonoClass * klass)
{
  gboolean D.27187;

  D.27187 = 0;
  return D.27187;
}


mini_is_gsharedvt_signature (struct MonoCompile * cfg, struct MonoMethodSignature * sig)
{
  gboolean D.27189;

  D.27189 = 0;
  return D.27189;
}


mini_is_gsharedvt_variable_type (struct MonoCompile * cfg, struct MonoType * t)
{
  gboolean D.27191;

  D.27191 = 0;
  return D.27191;
}


mini_is_gsharedvt_sharable_method (struct MonoMethod * method)
{
  gboolean D.27193;

  D.27193 = 0;
  return D.27193;
}


mini_is_gsharedvt_variable_signature (struct MonoMethodSignature * sig)
{
  gboolean D.27195;

  D.27195 = 0;
  return D.27195;
}


