__attribute__((visibility ("hidden")))
mono_domain_get_tls_key ()
{
  pthread_key_t D.18652;

  D.18652 = appdomain_thread_id;
  return D.18652;
}


__attribute__((visibility ("hidden")))
mono_domain_get_tls_offset ()
{
  gint32 D.18654;
  int offset;

  offset = -1;
  {
    guint64 foo;

    __asm__("basr	%%r1,0
	j	0f
	.quad tls_appdomain@NTPOFF
0:
	lg	%0,4(%%r1)
	" : "=r" foo :  : "1");
    offset = (int) foo;
  }
  D.18654 = offset;
  return D.18654;
}


__attribute__((visibility ("hidden")))
mono_jit_info_table_find_internal (struct MonoDomain * domain, char * addr, gboolean try_aot)
{
  long unsigned int D.18656;
  long unsigned int D.18657;
  struct MonoJitInfoTable * volatile * D.18658;
  struct MonoJitInfo * D.18665;
  struct MonoDomain * mono_root_domain.0;
  struct MonoJitInfoTable * D.18671;
  struct MonoJitInfoTable * volatile * D.18674;
  struct MonoJitInfo * (*<T1b4b>) (struct MonoDomain *, struct MonoImage *, void *) jit_info_find_in_aot_func.1;
  struct MonoImage * D.18678;
  struct MonoJitInfoTable * table;
  struct MonoJitInfo * ji;
  struct MonoJitInfo * module_ji;
  struct MonoThreadHazardPointers * hp;

  hp = mono_hazard_pointer_get ();
  D.18656 = mono_stats.jit_info_table_lookup_count;
  D.18657 = D.18656 + 1;
  mono_stats.jit_info_table_lookup_count = D.18657;
  D.18658 = &domain->jit_info_table;
  table = get_hazardous_pointer (D.18658, hp, 0);
  ji = jit_info_table_find (table, hp, addr);
  if (hp != 0B) goto <D.18659>; else goto <D.18660>;
  <D.18659>:
  if (0 != 0) goto <D.18661>; else goto <D.18662>;
  <D.18661>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 401, "(0) >= 0 && (0) < HAZARD_POINTER_COUNT");
  <D.18662>:
  hp->hazard_pointers[0] = 0B;
  <D.18660>:
  if (ji != 0B) goto <D.18663>; else goto <D.18664>;
  <D.18663>:
  D.18665 = ji;
  return D.18665;
  <D.18664>:
  if (try_aot != 0) goto <D.18666>; else goto <D.18667>;
  <D.18666>:
  mono_root_domain.0 = mono_root_domain;
  if (mono_root_domain.0 != 0B) goto <D.18669>; else goto <D.18670>;
  <D.18669>:
  mono_root_domain.0 = mono_root_domain;
  D.18671 = mono_root_domain.0->aot_modules;
  if (D.18671 != 0B) goto <D.18672>; else goto <D.18673>;
  <D.18672>:
  mono_root_domain.0 = mono_root_domain;
  D.18674 = &mono_root_domain.0->aot_modules;
  table = get_hazardous_pointer (D.18674, hp, 0);
  module_ji = jit_info_table_find (table, hp, addr);
  if (module_ji != 0B) goto <D.18675>; else goto <D.18676>;
  <D.18675>:
  jit_info_find_in_aot_func.1 = jit_info_find_in_aot_func;
  D.18678 = module_ji->d.image;
  ji = jit_info_find_in_aot_func.1 (domain, D.18678, addr);
  <D.18676>:
  if (hp != 0B) goto <D.18679>; else goto <D.18680>;
  <D.18679>:
  if (0 != 0) goto <D.18681>; else goto <D.18682>;
  <D.18681>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 412, "(0) >= 0 && (0) < HAZARD_POINTER_COUNT");
  <D.18682>:
  hp->hazard_pointers[0] = 0B;
  <D.18680>:
  <D.18673>:
  <D.18670>:
  <D.18667>:
  D.18665 = ji;
  return D.18665;
}


jit_info_table_find (struct MonoJitInfoTable * table, struct MonoThreadHazardPointers * hp, gint8 * addr)
{
  int D.18684;
  _Bool D.18685;
  long int D.18686;
  long int D.18687;
  struct MonoJitInfoTableChunk * D.18690;
  struct MonoJitInfo * volatile * D.18691;
  struct MonoMethod * D.18692;
  void * D.18697;
  int D.18700;
  sizetype D.18701;
  gint8 * D.18702;
  struct MonoJitInfo * D.18707;
  int D.18709;
  struct MonoJitInfo * ji;
  int chunk_pos;
  int pos;
  void not_found = <<< error >>>;

  chunk_pos = jit_info_table_index (table, addr);
  D.18684 = table->num_chunks;
  D.18685 = D.18684 <= chunk_pos;
  D.18686 = (long int) D.18685;
  D.18687 = __builtin_expect (D.18686, 0);
  if (D.18687 != 0) goto <D.18688>; else goto <D.18689>;
  <D.18688>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 327, "chunk_pos < table->num_chunks");
  <D.18689>:
  D.18690 = table->chunks[chunk_pos];
  pos = jit_info_table_chunk_index (D.18690, hp, addr);
  <D.17995>:
  {
    struct MonoJitInfoTableChunk * chunk;

    chunk = table->chunks[chunk_pos];
    goto <D.17991>;
    <D.17993>:
    D.18691 = &chunk->data[pos];
    ji = get_hazardous_pointer (D.18691, hp, 1);
    pos = pos + 1;
    D.18692 = ji->d.method;
    if (D.18692 == 0B) goto <D.18693>; else goto <D.18694>;
    <D.18693>:
    if (0 != 0) goto <D.18695>; else goto <D.18696>;
    <D.18695>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 345, "(1) >= 0 && (1) < HAZARD_POINTER_COUNT");
    <D.18696>:
    hp->hazard_pointers[1] = 0B;
    // predicted unlikely by continue predictor.
    goto <D.17991>;
    <D.18694>:
    D.18697 = ji->code_start;
    if (D.18697 <= addr) goto <D.18698>; else goto <D.18699>;
    <D.18698>:
    D.18697 = ji->code_start;
    D.18700 = ji->code_size;
    D.18701 = (sizetype) D.18700;
    D.18702 = D.18697 + D.18701;
    if (D.18702 > addr) goto <D.18703>; else goto <D.18704>;
    <D.18703>:
    if (0 != 0) goto <D.18705>; else goto <D.18706>;
    <D.18705>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 350, "(1) >= 0 && (1) < HAZARD_POINTER_COUNT");
    <D.18706>:
    hp->hazard_pointers[1] = 0B;
    D.18707 = ji;
    return D.18707;
    <D.18704>:
    <D.18699>:
    D.18697 = ji->code_start;
    if (D.18697 > addr) goto not_found; else goto <D.18708>;
    <D.18708>:
    <D.17991>:
    D.18709 = chunk->num_elements;
    if (D.18709 > pos) goto <D.17993>; else goto <D.17994>;
    <D.17994>:
    chunk_pos = chunk_pos + 1;
    pos = 0;
  }
  D.18684 = table->num_chunks;
  if (D.18684 > chunk_pos) goto <D.17995>; else goto <D.17996>;
  <D.17996>:
  not_found:
  if (hp != 0B) goto <D.18710>; else goto <D.18711>;
  <D.18710>:
  if (0 != 0) goto <D.18712>; else goto <D.18713>;
  <D.18712>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 367, "(1) >= 0 && (1) < HAZARD_POINTER_COUNT");
  <D.18713>:
  hp->hazard_pointers[1] = 0B;
  <D.18711>:
  D.18707 = 0B;
  return D.18707;
}


jit_info_table_index (struct MonoJitInfoTable * table, gint8 * addr)
{
  _Bool D.18715;
  long int D.18716;
  long int D.18717;
  int D.18720;
  volatile gint8 * D.18721;
  _Bool D.18725;
  long int D.18726;
  long int D.18727;
  int D.18730;
  int D.18733;
  int left;
  int right;

  left = 0;
  right = table->num_chunks;
  D.18715 = left >= right;
  D.18716 = (long int) D.18715;
  D.18717 = __builtin_expect (D.18716, 0);
  if (D.18717 != 0) goto <D.18718>; else goto <D.18719>;
  <D.18718>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 282, "left < right");
  <D.18719>:
  <D.17967>:
  {
    int pos;
    struct MonoJitInfoTableChunk * chunk;

    D.18720 = left + right;
    pos = D.18720 / 2;
    chunk = table->chunks[pos];
    D.18721 = chunk->last_code_end;
    if (D.18721 > addr) goto <D.18722>; else goto <D.18723>;
    <D.18722>:
    right = pos;
    goto <D.18724>;
    <D.18723>:
    left = pos + 1;
    <D.18724>:
  }
  if (left < right) goto <D.17967>; else goto <D.17968>;
  <D.17968>:
  D.18725 = left != right;
  D.18726 = (long int) D.18725;
  D.18727 = __builtin_expect (D.18726, 0);
  if (D.18727 != 0) goto <D.18728>; else goto <D.18729>;
  <D.18728>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 293, "left == right");
  <D.18729>:
  D.18730 = table->num_chunks;
  if (D.18730 <= left) goto <D.18731>; else goto <D.18732>;
  <D.18731>:
  D.18730 = table->num_chunks;
  D.18733 = D.18730 + -1;
  return D.18733;
  <D.18732>:
  D.18733 = left;
  return D.18733;
}


jit_info_table_chunk_index (struct MonoJitInfoTableChunk * chunk, struct MonoThreadHazardPointers * hp, gint8 * addr)
{
  int D.18735;
  struct MonoJitInfo * volatile * D.18736;
  void * D.18737;
  int D.18738;
  sizetype D.18739;
  _Bool D.18743;
  long int D.18744;
  long int D.18745;
  int D.18748;
  int left;
  int right;

  left = 0;
  right = chunk->num_elements;
  goto <D.17980>;
  <D.17979>:
  {
    int pos;
    struct MonoJitInfo * ji;
    gint8 * code_end;

    D.18735 = left + right;
    pos = D.18735 / 2;
    D.18736 = &chunk->data[pos];
    ji = get_hazardous_pointer (D.18736, hp, 1);
    D.18737 = ji->code_start;
    D.18738 = ji->code_size;
    D.18739 = (sizetype) D.18738;
    code_end = D.18737 + D.18739;
    if (addr < code_end) goto <D.18740>; else goto <D.18741>;
    <D.18740>:
    right = pos;
    goto <D.18742>;
    <D.18741>:
    left = pos + 1;
    <D.18742>:
  }
  <D.17980>:
  if (left < right) goto <D.17979>; else goto <D.17981>;
  <D.17981>:
  D.18743 = left != right;
  D.18744 = (long int) D.18743;
  D.18745 = __builtin_expect (D.18744, 0);
  if (D.18745 != 0) goto <D.18746>; else goto <D.18747>;
  <D.18746>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 315, "left == right");
  <D.18747>:
  D.18748 = left;
  return D.18748;
}


mono_jit_info_table_find (struct MonoDomain * domain, char * addr)
{
  struct MonoJitInfo * D.18750;

  D.18750 = mono_jit_info_table_find_internal (domain, addr, 1);
  return D.18750;
}


__attribute__((visibility ("hidden")))
mono_jit_info_table_add (struct MonoDomain * domain, struct MonoJitInfo * ji)
{
  struct MonoMethod * D.18752;
  _Bool D.18753;
  long int D.18754;
  long int D.18755;
  union mono_mutex_t * D.18758;
  _Bool D.18761;
  long int D.18762;
  long int D.18763;
  long unsigned int D.18766;
  long unsigned int D.18767;
  struct MonoJitInfoTable * volatile * D.18768;
  _Bool D.18771;
  long int D.18772;
  long int D.18773;

  D.18752 = ji->d.method;
  D.18753 = D.18752 == 0B;
  D.18754 = (long int) D.18753;
  D.18755 = __builtin_expect (D.18754, 0);
  if (D.18755 != 0) goto <D.18756>; else goto <D.18757>;
  <D.18756>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 749, "ji->d.method != NULL");
  <D.18757>:
  {
    int ret;

    D.18758 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.18758);
    if (ret != 0) goto <D.18759>; else goto <D.18760>;
    <D.18759>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.18760>:
    D.18761 = ret != 0;
    D.18762 = (long int) D.18761;
    D.18763 = __builtin_expect (D.18762, 0);
    if (D.18763 != 0) goto <D.18764>; else goto <D.18765>;
    <D.18764>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 751, "ret == 0");
    <D.18765>:
  }
  D.18766 = mono_stats.jit_info_table_insert_count;
  D.18767 = D.18766 + 1;
  mono_stats.jit_info_table_insert_count = D.18767;
  D.18768 = &domain->jit_info_table;
  jit_info_table_add (domain, D.18768, ji);
  {
    int ret;

    D.18758 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.18758);
    if (ret != 0) goto <D.18769>; else goto <D.18770>;
    <D.18769>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.18770>:
    D.18771 = ret != 0;
    D.18772 = (long int) D.18771;
    D.18773 = __builtin_expect (D.18772, 0);
    if (D.18773 != 0) goto <D.18774>; else goto <D.18775>;
    <D.18774>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 757, "ret == 0");
    <D.18775>:
  }
}


jit_info_table_add (struct MonoDomain * domain, struct MonoJitInfoTable * volatile * table_ptr, struct MonoJitInfo * ji)
{
  void * D.18776;
  int D.18777;
  sizetype D.18778;
  gint8 * D.18779;
  int D.18780;
  _Bool D.18781;
  long int D.18782;
  long int D.18783;
  int D.18786;
  int D.18789;
  int D.18790;
  int D.18793;
  struct MonoJitInfo * D.18794;
  int D.18796;
  struct MonoJitInfo * D.18797;
  int D.18798;
  int D.18799;
  struct MonoJitInfo * D.18800;
  void * D.18801;
  int D.18802;
  int D.18803;
  struct MonoJitInfo * D.18804;
  int D.18805;
  sizetype D.18806;
  volatile gint8 * D.18807;
  struct MonoJitInfoTable * table;
  struct MonoJitInfoTableChunk * chunk;
  int chunk_pos;
  int pos;
  int num_elements;
  int i;
  void restart = <<< error >>>;

  table = *table_ptr;
  restart:
  D.18776 = ji->code_start;
  D.18777 = ji->code_size;
  D.18778 = (sizetype) D.18777;
  D.18779 = D.18776 + D.18778;
  chunk_pos = jit_info_table_index (table, D.18779);
  D.18780 = table->num_chunks;
  D.18781 = D.18780 <= chunk_pos;
  D.18782 = (long int) D.18781;
  D.18783 = __builtin_expect (D.18782, 0);
  if (D.18783 != 0) goto <D.18784>; else goto <D.18785>;
  <D.18784>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 693, "chunk_pos < table->num_chunks");
  <D.18785>:
  chunk = table->chunks[chunk_pos];
  D.18786 = chunk->num_elements;
  if (D.18786 > 63) goto <D.18787>; else goto <D.18788>;
  <D.18787>:
  {
    struct MonoJitInfoTable * new_table;

    new_table = jit_info_table_chunk_overflow (table, chunk);
    *table_ptr = new_table;
    mono_memory_barrier ();
    D.18789 = domain->num_jit_info_tables;
    D.18790 = D.18789 + 1;
    domain->num_jit_info_tables = D.18790;
    mono_thread_hazardous_free_or_queue (table, jit_info_table_free, 1, 0);
    table = new_table;
    goto restart;
  }
  <D.18788>:
  num_elements = chunk->num_elements;
  D.18776 = ji->code_start;
  D.18777 = ji->code_size;
  D.18778 = (sizetype) D.18777;
  D.18779 = D.18776 + D.18778;
  pos = jit_info_table_chunk_index (chunk, 0B, D.18779);
  if (num_elements > 0) goto <D.18791>; else goto <D.18792>;
  <D.18791>:
  D.18793 = num_elements + -1;
  D.18794 = chunk->data[D.18793];
  chunk->data[num_elements] = D.18794;
  goto <D.18795>;
  <D.18792>:
  chunk->data[0] = ji;
  <D.18795>:
  mono_memory_write_barrier ();
  num_elements = num_elements + 1;
  chunk->num_elements = num_elements;
  i = num_elements + -2;
  goto <D.18114>;
  <D.18113>:
  mono_memory_write_barrier ();
  D.18796 = i + 1;
  D.18797 = chunk->data[i];
  chunk->data[D.18796] = D.18797;
  i = i + -1;
  <D.18114>:
  if (i >= pos) goto <D.18113>; else goto <D.18115>;
  <D.18115>:
  mono_memory_write_barrier ();
  chunk->data[pos] = ji;
  D.18798 = chunk->num_elements;
  D.18799 = D.18798 + -1;
  D.18800 = chunk->data[D.18799];
  D.18801 = D.18800->code_start;
  D.18802 = chunk->num_elements;
  D.18803 = D.18802 + -1;
  D.18804 = chunk->data[D.18803];
  D.18805 = D.18804->code_size;
  D.18806 = (sizetype) D.18805;
  D.18807 = D.18801 + D.18806;
  chunk->last_code_end = D.18807;
}


jit_info_table_free (struct MonoJitInfoTable * table)
{
  union mono_mutex_t * D.18808;
  _Bool D.18811;
  long int D.18812;
  long int D.18813;
  struct MonoDomain * D.18816;
  int D.18817;
  int D.18818;
  void * D.18821;
  struct GSList * D.18822;
  int D.18823;
  int D.18824;
  struct MonoMethod * D.18827;
  _Bool D.18832;
  long int D.18833;
  long int D.18834;
  int i;
  int num_chunks;
  struct MonoDomain * domain;

  num_chunks = table->num_chunks;
  domain = table->domain;
  {
    int ret;

    D.18808 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.18808);
    if (ret != 0) goto <D.18809>; else goto <D.18810>;
    <D.18809>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.18810>:
    D.18811 = ret != 0;
    D.18812 = (long int) D.18811;
    D.18813 = __builtin_expect (D.18812, 0);
    if (D.18813 != 0) goto <D.18814>; else goto <D.18815>;
    <D.18814>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 216, "ret == 0");
    <D.18815>:
  }
  D.18816 = table->domain;
  D.18817 = D.18816->num_jit_info_tables;
  D.18818 = D.18817 + -1;
  D.18816->num_jit_info_tables = D.18818;
  D.18816 = table->domain;
  D.18817 = D.18816->num_jit_info_tables;
  if (D.18817 <= 1) goto <D.18819>; else goto <D.18820>;
  <D.18819>:
  {
    struct GSList * list;

    D.18816 = table->domain;
    list = D.18816->jit_info_free_queue;
    goto <D.17945>;
    <D.17944>:
    D.18821 = list->data;
    monoeg_g_free (D.18821);
    list = list->next;
    <D.17945>:
    if (list != 0B) goto <D.17944>; else goto <D.17946>;
    <D.17946>:
    D.18816 = table->domain;
    D.18822 = D.18816->jit_info_free_queue;
    monoeg_g_slist_free (D.18822);
    D.18816 = table->domain;
    D.18816->jit_info_free_queue = 0B;
  }
  <D.18820>:
  i = 0;
  goto <D.17956>;
  <D.17955>:
  {
    struct MonoJitInfoTableChunk * chunk;
    int num_elements;
    int j;

    chunk = table->chunks[i];
    D.18823 = chunk->refcount;
    D.18824 = D.18823 + -1;
    chunk->refcount = D.18824;
    D.18823 = chunk->refcount;
    if (D.18823 > 0) goto <D.18825>; else goto <D.18826>;
    <D.18825>:
    // predicted unlikely by continue predictor.
    goto <D.17950>;
    <D.18826>:
    num_elements = chunk->num_elements;
    j = 0;
    goto <D.17953>;
    <D.17952>:
    {
      struct MonoJitInfo * ji;

      ji = chunk->data[j];
      D.18827 = ji->d.method;
      if (D.18827 == 0B) goto <D.18828>; else goto <D.18829>;
      <D.18828>:
      monoeg_g_free (ji);
      <D.18829>:
    }
    j = j + 1;
    <D.17953>:
    if (j < num_elements) goto <D.17952>; else goto <D.17954>;
    <D.17954>:
    monoeg_g_free (chunk);
  }
  <D.17950>:
  i = i + 1;
  <D.17956>:
  if (i < num_chunks) goto <D.17955>; else goto <D.17957>;
  <D.17957>:
  {
    int ret;

    D.18808 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.18808);
    if (ret != 0) goto <D.18830>; else goto <D.18831>;
    <D.18830>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.18831>:
    D.18832 = ret != 0;
    D.18833 = (long int) D.18832;
    D.18834 = __builtin_expect (D.18833, 0);
    if (D.18834 != 0) goto <D.18835>; else goto <D.18836>;
    <D.18835>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 252, "ret == 0");
    <D.18836>:
  }
  monoeg_g_free (table);
}


jit_info_table_chunk_overflow (struct MonoJitInfoTable * table, struct MonoJitInfoTableChunk * chunk)
{
  int D.18839;
  int D.18840;
  int D.18842;
  int D.18843;
  struct MonoJitInfoTable * D.18844;
  struct MonoJitInfo * D.18845;
  struct MonoMethod * D.18846;
  int D.18849;
  int num_elements;
  int i;

  num_elements = jit_info_table_num_elements (table);
  D.18839 = table->num_chunks;
  D.18840 = D.18839 * 32;
  if (D.18840 > num_elements) goto <D.18837>; else goto <D.18841>;
  <D.18841>:
  D.18839 = table->num_chunks;
  D.18842 = D.18839 * 320;
  D.18843 = D.18842 / 6;
  if (D.18843 < num_elements) goto <D.18837>; else goto <D.18838>;
  <D.18837>:
  D.18844 = jit_info_table_realloc (table);
  return D.18844;
  <D.18838>:
  num_elements = 0;
  i = 0;
  goto <D.18098>;
  <D.18097>:
  D.18845 = chunk->data[i];
  D.18846 = D.18845->d.method;
  if (D.18846 != 0B) goto <D.18847>; else goto <D.18848>;
  <D.18847>:
  num_elements = num_elements + 1;
  <D.18848>:
  i = i + 1;
  <D.18098>:
  D.18849 = chunk->num_elements;
  if (D.18849 > i) goto <D.18097>; else goto <D.18099>;
  <D.18099>:
  if (num_elements == 64) goto <D.18850>; else goto <D.18851>;
  <D.18850>:
  D.18844 = jit_info_table_copy_and_split_chunk (table, chunk);
  return D.18844;
  <D.18851>:
  D.18844 = jit_info_table_copy_and_purify_chunk (table, chunk);
  return D.18844;
}


jit_info_table_num_elements (struct MonoJitInfoTable * table)
{
  struct MonoJitInfo * D.18853;
  struct MonoMethod * D.18854;
  int D.18857;
  int D.18858;
  int i;
  int num_elements;

  num_elements = 0;
  i = 0;
  goto <D.17926>;
  <D.17925>:
  {
    struct MonoJitInfoTableChunk * chunk;
    int chunk_num_elements;
    int j;

    chunk = table->chunks[i];
    chunk_num_elements = chunk->num_elements;
    j = 0;
    goto <D.17923>;
    <D.17922>:
    D.18853 = chunk->data[j];
    D.18854 = D.18853->d.method;
    if (D.18854 != 0B) goto <D.18855>; else goto <D.18856>;
    <D.18855>:
    num_elements = num_elements + 1;
    <D.18856>:
    j = j + 1;
    <D.17923>:
    if (j < chunk_num_elements) goto <D.17922>; else goto <D.17924>;
    <D.17924>:
  }
  i = i + 1;
  <D.17926>:
  D.18857 = table->num_chunks;
  if (D.18857 > i) goto <D.17925>; else goto <D.17927>;
  <D.17927>:
  D.18858 = num_elements;
  return D.18858;
}


jit_info_table_realloc (struct MonoJitInfoTable * old)
{
  long int D.18860;
  long int D.18861;
  long int D.18862;
  int D.18863;
  _Bool D.18866;
  long int D.18867;
  long int D.18868;
  struct MonoJitInfoTable * D.18871;
  struct MonoDomain * D.18872;
  _Bool D.18873;
  long int D.18874;
  long int D.18875;
  long unsigned int D.18878;
  long unsigned int D.18879;
  long unsigned int D.18880;
  struct MonoJitInfoTableChunk * D.18881;
  struct MonoJitInfo * D.18882;
  struct MonoMethod * D.18883;
  _Bool D.18886;
  long int D.18887;
  long int D.18888;
  struct MonoJitInfoTableChunk * D.18891;
  struct MonoJitInfo * D.18892;
  int D.18895;
  int D.18898;
  _Bool D.18899;
  long int D.18900;
  long int D.18901;
  int D.18904;
  _Bool D.18905;
  long int D.18906;
  long int D.18907;
  int D.18910;
  int D.18911;
  struct MonoJitInfoTableChunk * D.18912;
  void * D.18913;
  int D.18914;
  sizetype D.18915;
  volatile gint8 * D.18916;
  int i;
  int num_elements;
  int required_size;
  int num_chunks;
  int new_chunk;
  int new_element;
  struct MonoJitInfoTable * new;

  num_elements = jit_info_table_num_elements (old);
  D.18860 = (long int) num_elements;
  D.18861 = D.18860 * 4;
  D.18862 = D.18861 / 3;
  required_size = (int) D.18862;
  D.18863 = required_size + 63;
  num_chunks = D.18863 / 64;
  if (num_chunks == 0) goto <D.18864>; else goto <D.18865>;
  <D.18864>:
  D.18866 = num_elements != 0;
  D.18867 = (long int) D.18866;
  D.18868 = __builtin_expect (D.18867, 0);
  if (D.18868 != 0) goto <D.18869>; else goto <D.18870>;
  <D.18869>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 480, "num_elements == 0");
  <D.18870>:
  D.18872 = old->domain;
  D.18871 = jit_info_table_new (D.18872);
  return D.18871;
  <D.18865>:
  D.18873 = num_chunks <= 0;
  D.18874 = (long int) D.18873;
  D.18875 = __builtin_expect (D.18874, 0);
  if (D.18875 != 0) goto <D.18876>; else goto <D.18877>;
  <D.18876>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 483, "num_chunks > 0");
  <D.18877>:
  D.18878 = (long unsigned int) num_chunks;
  D.18879 = D.18878 + 2;
  D.18880 = D.18879 * 8;
  new = monoeg_malloc (D.18880);
  D.18872 = old->domain;
  new->domain = D.18872;
  new->num_chunks = num_chunks;
  i = 0;
  goto <D.18039>;
  <D.18038>:
  D.18881 = jit_info_table_new_chunk ();
  new->chunks[i] = D.18881;
  i = i + 1;
  <D.18039>:
  if (i < num_chunks) goto <D.18038>; else goto <D.18040>;
  <D.18040>:
  new_chunk = 0;
  new_element = 0;
  i = 0;
  goto <D.18048>;
  <D.18047>:
  {
    struct MonoJitInfoTableChunk * chunk;
    int chunk_num_elements;
    int j;

    chunk = old->chunks[i];
    chunk_num_elements = chunk->num_elements;
    j = 0;
    goto <D.18045>;
    <D.18044>:
    D.18882 = chunk->data[j];
    D.18883 = D.18882->d.method;
    if (D.18883 != 0B) goto <D.18884>; else goto <D.18885>;
    <D.18884>:
    D.18886 = new_chunk >= num_chunks;
    D.18887 = (long int) D.18886;
    D.18888 = __builtin_expect (D.18887, 0);
    if (D.18888 != 0) goto <D.18889>; else goto <D.18890>;
    <D.18889>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 501, "new_chunk < num_chunks");
    <D.18890>:
    D.18891 = new->chunks[new_chunk];
    D.18892 = chunk->data[j];
    D.18891->data[new_element] = D.18892;
    new_element = new_element + 1;
    if (new_element > 47) goto <D.18893>; else goto <D.18894>;
    <D.18893>:
    D.18891 = new->chunks[new_chunk];
    D.18891->num_elements = new_element;
    new_chunk = new_chunk + 1;
    new_element = 0;
    <D.18894>:
    <D.18885>:
    j = j + 1;
    <D.18045>:
    if (j < chunk_num_elements) goto <D.18044>; else goto <D.18046>;
    <D.18046>:
  }
  i = i + 1;
  <D.18048>:
  D.18895 = old->num_chunks;
  if (D.18895 > i) goto <D.18047>; else goto <D.18049>;
  <D.18049>:
  if (new_chunk < num_chunks) goto <D.18896>; else goto <D.18897>;
  <D.18896>:
  D.18898 = num_chunks + -1;
  D.18899 = D.18898 != new_chunk;
  D.18900 = (long int) D.18899;
  D.18901 = __builtin_expect (D.18900, 0);
  if (D.18901 != 0) goto <D.18902>; else goto <D.18903>;
  <D.18902>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 513, "new_chunk == num_chunks - 1");
  <D.18903>:
  D.18891 = new->chunks[new_chunk];
  D.18891->num_elements = new_element;
  D.18891 = new->chunks[new_chunk];
  D.18904 = D.18891->num_elements;
  D.18905 = D.18904 <= 0;
  D.18906 = (long int) D.18905;
  D.18907 = __builtin_expect (D.18906, 0);
  if (D.18907 != 0) goto <D.18908>; else goto <D.18909>;
  <D.18908>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 515, "new->chunks [new_chunk]->num_elements > 0");
  <D.18909>:
  <D.18897>:
  i = 0;
  goto <D.18053>;
  <D.18052>:
  {
    struct MonoJitInfoTableChunk * chunk;
    struct MonoJitInfo * ji;

    chunk = new->chunks[i];
    D.18910 = chunk->num_elements;
    D.18911 = D.18910 + -1;
    ji = chunk->data[D.18911];
    D.18912 = new->chunks[i];
    D.18913 = ji->code_start;
    D.18914 = ji->code_size;
    D.18915 = (sizetype) D.18914;
    D.18916 = D.18913 + D.18915;
    D.18912->last_code_end = D.18916;
  }
  i = i + 1;
  <D.18053>:
  if (i < num_chunks) goto <D.18052>; else goto <D.18054>;
  <D.18054>:
  D.18871 = new;
  return D.18871;
}


jit_info_table_new (struct MonoDomain * domain)
{
  struct MonoJitInfoTableChunk * D.18918;
  struct MonoJitInfoTable * D.18919;
  struct MonoJitInfoTable * table;

  table = monoeg_malloc0 (24);
  table->domain = domain;
  table->num_chunks = 1;
  D.18918 = jit_info_table_new_chunk ();
  table->chunks[0] = D.18918;
  D.18919 = table;
  return D.18919;
}


jit_info_table_new_chunk ()
{
  struct MonoJitInfoTableChunk * D.18921;
  struct MonoJitInfoTableChunk * chunk;

  chunk = monoeg_malloc0 (528);
  chunk->refcount = 1;
  D.18921 = chunk;
  return D.18921;
}


jit_info_table_copy_and_split_chunk (struct MonoJitInfoTable * table, struct MonoJitInfoTableChunk * chunk)
{
  int D.18923;
  int D.18924;
  long unsigned int D.18925;
  long unsigned int D.18926;
  long unsigned int D.18927;
  struct MonoDomain * D.18928;
  struct MonoJitInfoTableChunk * D.18929;
  struct MonoJitInfoTableChunk * * D.18932;
  int D.18933;
  struct MonoJitInfoTableChunk * * D.18934;
  struct MonoJitInfoTableChunk * D.18936;
  int D.18937;
  int D.18938;
  int D.18939;
  _Bool D.18940;
  long int D.18941;
  long int D.18942;
  struct MonoJitInfoTable * D.18945;
  struct MonoJitInfoTable * new_table;
  int i;
  int j;

  D.18923 = table->num_chunks;
  D.18924 = D.18923 + 1;
  D.18925 = (long unsigned int) D.18924;
  D.18926 = D.18925 + 2;
  D.18927 = D.18926 * 8;
  new_table = monoeg_malloc (D.18927);
  D.18928 = table->domain;
  new_table->domain = D.18928;
  D.18923 = table->num_chunks;
  D.18924 = D.18923 + 1;
  new_table->num_chunks = D.18924;
  j = 0;
  i = 0;
  goto <D.18070>;
  <D.18069>:
  D.18929 = table->chunks[i];
  if (D.18929 == chunk) goto <D.18930>; else goto <D.18931>;
  <D.18930>:
  D.18932 = &new_table->chunks[j];
  D.18933 = j + 1;
  D.18934 = &new_table->chunks[D.18933];
  jit_info_table_split_chunk (chunk, D.18932, D.18934);
  j = j + 2;
  goto <D.18935>;
  <D.18931>:
  D.18929 = table->chunks[i];
  new_table->chunks[j] = D.18929;
  D.18936 = new_table->chunks[j];
  D.18937 = D.18936->refcount;
  D.18938 = D.18937 + 1;
  D.18936->refcount = D.18938;
  j = j + 1;
  <D.18935>:
  i = i + 1;
  <D.18070>:
  D.18923 = table->num_chunks;
  if (D.18923 > i) goto <D.18069>; else goto <D.18071>;
  <D.18071>:
  D.18939 = new_table->num_chunks;
  D.18940 = D.18939 != j;
  D.18941 = (long int) D.18940;
  D.18942 = __builtin_expect (D.18941, 0);
  if (D.18942 != 0) goto <D.18943>; else goto <D.18944>;
  <D.18943>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 573, "j == new_table->num_chunks");
  <D.18944>:
  D.18945 = new_table;
  return D.18945;
}


jit_info_table_split_chunk (struct MonoJitInfoTableChunk * chunk, struct MonoJitInfoTableChunk * * new1p, struct MonoJitInfoTableChunk * * new2p)
{
  int D.18947;
  _Bool D.18948;
  long int D.18949;
  long int D.18950;
  int D.18953;
  int D.18954;
  struct MonoJitInfo * volatile[64] * D.18955;
  struct MonoJitInfo * volatile[64] * D.18956;
  int D.18957;
  long unsigned int D.18958;
  long unsigned int D.18959;
  struct MonoJitInfo * volatile[64] * D.18960;
  struct MonoJitInfo * volatile[64] * D.18961;
  int D.18962;
  long unsigned int D.18963;
  long unsigned int D.18964;
  const void * D.18965;
  int D.18966;
  long unsigned int D.18967;
  long unsigned int D.18968;
  int D.18969;
  int D.18970;
  struct MonoJitInfo * D.18971;
  void * D.18972;
  int D.18973;
  int D.18974;
  struct MonoJitInfo * D.18975;
  int D.18976;
  sizetype D.18977;
  volatile gint8 * D.18978;
  int D.18979;
  int D.18980;
  struct MonoJitInfo * D.18981;
  void * D.18982;
  int D.18983;
  int D.18984;
  struct MonoJitInfo * D.18985;
  int D.18986;
  sizetype D.18987;
  volatile gint8 * D.18988;
  struct MonoJitInfoTableChunk * new1;
  struct MonoJitInfoTableChunk * new2;

  new1 = jit_info_table_new_chunk ();
  new2 = jit_info_table_new_chunk ();
  D.18947 = chunk->num_elements;
  D.18948 = D.18947 != 64;
  D.18949 = (long int) D.18948;
  D.18950 = __builtin_expect (D.18949, 0);
  if (D.18950 != 0) goto <D.18951>; else goto <D.18952>;
  <D.18951>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 534, "chunk->num_elements == MONO_JIT_INFO_TABLE_CHUNK_SIZE");
  <D.18952>:
  new1->num_elements = 32;
  D.18953 = new1->num_elements;
  D.18954 = 64 - D.18953;
  new2->num_elements = D.18954;
  D.18955 = &new1->data;
  D.18956 = &chunk->data;
  D.18957 = new1->num_elements;
  D.18958 = (long unsigned int) D.18957;
  D.18959 = D.18958 * 8;
  memcpy (D.18955, D.18956, D.18959);
  D.18960 = &new2->data;
  D.18961 = &chunk->data;
  D.18962 = new1->num_elements;
  D.18963 = (long unsigned int) D.18962;
  D.18964 = D.18963 * 8;
  D.18965 = D.18961 + D.18964;
  D.18966 = new2->num_elements;
  D.18967 = (long unsigned int) D.18966;
  D.18968 = D.18967 * 8;
  memcpy (D.18960, D.18965, D.18968);
  D.18969 = new1->num_elements;
  D.18970 = D.18969 + -1;
  D.18971 = new1->data[D.18970];
  D.18972 = D.18971->code_start;
  D.18973 = new1->num_elements;
  D.18974 = D.18973 + -1;
  D.18975 = new1->data[D.18974];
  D.18976 = D.18975->code_size;
  D.18977 = (sizetype) D.18976;
  D.18978 = D.18972 + D.18977;
  new1->last_code_end = D.18978;
  D.18979 = new2->num_elements;
  D.18980 = D.18979 + -1;
  D.18981 = new2->data[D.18980];
  D.18982 = D.18981->code_start;
  D.18983 = new2->num_elements;
  D.18984 = D.18983 + -1;
  D.18985 = new2->data[D.18984];
  D.18986 = D.18985->code_size;
  D.18987 = (sizetype) D.18986;
  D.18988 = D.18982 + D.18987;
  new2->last_code_end = D.18988;
  *new1p = new1;
  *new2p = new2;
}


__attribute__((__artificial__, __gnu_inline__, __always_inline__, __nothrow__, __leaf__))
memcpy (void * restrict __dest, const void * restrict __src, size_t __len)
{
  void * D.18989;
  long unsigned int D.18990;

  D.18990 = __builtin_object_size (__dest, 0);
  D.18989 = __builtin___memcpy_chk (__dest, __src, __len, D.18990);
  return D.18989;
}


jit_info_table_copy_and_purify_chunk (struct MonoJitInfoTable * table, struct MonoJitInfoTableChunk * chunk)
{
  int D.18992;
  long unsigned int D.18993;
  long unsigned int D.18994;
  long unsigned int D.18995;
  struct MonoDomain * D.18996;
  struct MonoJitInfoTableChunk * D.18997;
  int j.2;
  struct MonoJitInfoTableChunk * D.19001;
  struct MonoJitInfoTableChunk * D.19003;
  int D.19004;
  int D.19005;
  int D.19006;
  _Bool D.19007;
  long int D.19008;
  long int D.19009;
  struct MonoJitInfoTable * D.19012;
  struct MonoJitInfoTable * new_table;
  int i;
  int j;

  D.18992 = table->num_chunks;
  D.18993 = (long unsigned int) D.18992;
  D.18994 = D.18993 + 2;
  D.18995 = D.18994 * 8;
  new_table = monoeg_malloc (D.18995);
  D.18996 = table->domain;
  new_table->domain = D.18996;
  D.18992 = table->num_chunks;
  new_table->num_chunks = D.18992;
  j = 0;
  i = 0;
  goto <D.18089>;
  <D.18088>:
  D.18997 = table->chunks[i];
  if (D.18997 == chunk) goto <D.18998>; else goto <D.18999>;
  <D.18998>:
  j.2 = j;
  j = j.2 + 1;
  D.18997 = table->chunks[i];
  D.19001 = jit_info_table_purify_chunk (D.18997);
  new_table->chunks[j.2] = D.19001;
  goto <D.19002>;
  <D.18999>:
  D.18997 = table->chunks[i];
  new_table->chunks[j] = D.18997;
  D.19003 = new_table->chunks[j];
  D.19004 = D.19003->refcount;
  D.19005 = D.19004 + 1;
  D.19003->refcount = D.19005;
  j = j + 1;
  <D.19002>:
  i = i + 1;
  <D.18089>:
  D.18992 = table->num_chunks;
  if (D.18992 > i) goto <D.18088>; else goto <D.18090>;
  <D.18090>:
  D.19006 = new_table->num_chunks;
  D.19007 = D.19006 != j;
  D.19008 = (long int) D.19007;
  D.19009 = __builtin_expect (D.19008, 0);
  if (D.19009 != 0) goto <D.19010>; else goto <D.19011>;
  <D.19010>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 620, "j == new_table->num_chunks");
  <D.19011>:
  D.19012 = new_table;
  return D.19012;
}


jit_info_table_purify_chunk (struct MonoJitInfoTableChunk * old)
{
  struct MonoJitInfo * D.19014;
  struct MonoMethod * D.19015;
  int j.3;
  struct MonoJitInfo * D.19019;
  int D.19020;
  int D.19021;
  int D.19024;
  struct MonoJitInfo * D.19025;
  void * D.19026;
  struct MonoJitInfo * D.19027;
  int D.19028;
  sizetype D.19029;
  volatile gint8 * D.19030;
  volatile gint8 * D.19032;
  struct MonoJitInfoTableChunk * D.19033;
  struct MonoJitInfoTableChunk * new;
  int i;
  int j;

  new = jit_info_table_new_chunk ();
  j = 0;
  i = 0;
  goto <D.18079>;
  <D.18078>:
  D.19014 = old->data[i];
  D.19015 = D.19014->d.method;
  if (D.19015 != 0B) goto <D.19016>; else goto <D.19017>;
  <D.19016>:
  j.3 = j;
  j = j.3 + 1;
  D.19019 = old->data[i];
  new->data[j.3] = D.19019;
  <D.19017>:
  i = i + 1;
  <D.18079>:
  D.19020 = old->num_elements;
  if (D.19020 > i) goto <D.18078>; else goto <D.18080>;
  <D.18080>:
  new->num_elements = j;
  D.19021 = new->num_elements;
  if (D.19021 > 0) goto <D.19022>; else goto <D.19023>;
  <D.19022>:
  D.19024 = j + -1;
  D.19025 = new->data[D.19024];
  D.19026 = D.19025->code_start;
  D.19024 = j + -1;
  D.19027 = new->data[D.19024];
  D.19028 = D.19027->code_size;
  D.19029 = (sizetype) D.19028;
  D.19030 = D.19026 + D.19029;
  new->last_code_end = D.19030;
  goto <D.19031>;
  <D.19023>:
  D.19032 = old->last_code_end;
  new->last_code_end = D.19032;
  <D.19031>:
  D.19033 = new;
  return D.19033;
}


mono_memory_barrier ()
{
  __sync_synchronize ();
}


mono_memory_write_barrier ()
{
  mono_memory_barrier ();
}


__attribute__((visibility ("hidden")))
mono_jit_info_table_remove (struct MonoDomain * domain, struct MonoJitInfo * ji)
{
  union mono_mutex_t * D.19035;
  _Bool D.19038;
  long int D.19039;
  long int D.19040;
  long unsigned int D.19043;
  long unsigned int D.19044;
  _Bool D.19047;
  long int D.19048;
  long int D.19049;
  struct MonoJitInfoTable * table;

  {
    int ret;

    D.19035 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.19035);
    if (ret != 0) goto <D.19036>; else goto <D.19037>;
    <D.19036>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.19037>:
    D.19038 = ret != 0;
    D.19039 = (long int) D.19038;
    D.19040 = __builtin_expect (D.19039, 0);
    if (D.19040 != 0) goto <D.19041>; else goto <D.19042>;
    <D.19041>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 831, "ret == 0");
    <D.19042>:
  }
  table = domain->jit_info_table;
  D.19043 = mono_stats.jit_info_table_remove_count;
  D.19044 = D.19043 + 1;
  mono_stats.jit_info_table_remove_count = D.19044;
  jit_info_table_remove (table, ji);
  mono_jit_info_free_or_queue (domain, ji);
  {
    int ret;

    D.19035 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.19035);
    if (ret != 0) goto <D.19045>; else goto <D.19046>;
    <D.19045>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19046>:
    D.19047 = ret != 0;
    D.19048 = (long int) D.19047;
    D.19049 = __builtin_expect (D.19048, 0);
    if (D.19049 != 0) goto <D.19050>; else goto <D.19051>;
    <D.19050>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 840, "ret == 0");
    <D.19051>:
  }
}


jit_info_table_remove (struct MonoJitInfoTable * table, struct MonoJitInfo * ji)
{
  int D.19052;
  _Bool D.19053;
  long int D.19054;
  long int D.19055;
  struct MonoJitInfoTableChunk * D.19058;
  struct MonoJitInfo * D.19059;
  struct MonoJitInfo * D.19061;
  struct MonoMethod * D.19062;
  _Bool D.19063;
  long int D.19064;
  long int D.19065;
  struct MonoJitInfo * D.19068;
  void * D.19069;
  struct MonoJitInfo * D.19070;
  int D.19071;
  sizetype D.19072;
  guint8 * D.19073;
  void * D.19074;
  int D.19075;
  sizetype D.19076;
  guint8 * D.19077;
  _Bool D.19078;
  long int D.19079;
  long int D.19080;
  int D.19083;
  struct MonoJitInfo * D.19084;
  _Bool D.19085;
  long int D.19086;
  long int D.19087;
  struct MonoJitInfo * D.19090;
  struct MonoJitInfoTableChunk * chunk;
  void * start;
  int chunk_pos;
  int pos;
  void found = <<< error >>>;

  start = ji->code_start;
  chunk_pos = jit_info_table_index (table, start);
  D.19052 = table->num_chunks;
  D.19053 = D.19052 <= chunk_pos;
  D.19054 = (long int) D.19053;
  D.19055 = __builtin_expect (D.19054, 0);
  if (D.19055 != 0) goto <D.19056>; else goto <D.19057>;
  <D.19056>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 795, "chunk_pos < table->num_chunks");
  <D.19057>:
  D.19058 = table->chunks[chunk_pos];
  pos = jit_info_table_chunk_index (D.19058, 0B, start);
  <D.18142>:
  chunk = table->chunks[chunk_pos];
  goto <D.18140>;
  <D.18139>:
  D.19059 = chunk->data[pos];
  if (D.19059 == ji) goto found; else goto <D.19060>;
  <D.19060>:
  D.19061 = chunk->data[pos];
  D.19062 = D.19061->d.method;
  D.19063 = D.19062 != 0B;
  D.19064 = (long int) D.19063;
  D.19065 = __builtin_expect (D.19064, 0);
  if (D.19065 != 0) goto <D.19066>; else goto <D.19067>;
  <D.19066>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 806, "IS_JIT_INFO_TOMBSTONE (chunk->data [pos])");
  <D.19067>:
  D.19068 = chunk->data[pos];
  D.19069 = D.19068->code_start;
  D.19070 = chunk->data[pos];
  D.19071 = D.19070->code_size;
  D.19072 = (sizetype) D.19071;
  D.19073 = D.19069 + D.19072;
  D.19074 = ji->code_start;
  D.19075 = ji->code_size;
  D.19076 = (sizetype) D.19075;
  D.19077 = D.19074 + D.19076;
  D.19078 = D.19073 > D.19077;
  D.19079 = (long int) D.19078;
  D.19080 = __builtin_expect (D.19079, 0);
  if (D.19080 != 0) goto <D.19081>; else goto <D.19082>;
  <D.19081>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 808, "(guint8*)chunk->data [pos]->code_start + chunk->data [pos]->code_size <= (guint8*)ji->code_start + ji->code_size");
  <D.19082>:
  pos = pos + 1;
  <D.18140>:
  D.19083 = chunk->num_elements;
  if (D.19083 > pos) goto <D.18139>; else goto <D.18141>;
  <D.18141>:
  chunk_pos = chunk_pos + 1;
  pos = 0;
  D.19052 = table->num_chunks;
  if (D.19052 > chunk_pos) goto <D.18142>; else goto <D.18143>;
  <D.18143>:
  found:
  D.19084 = chunk->data[pos];
  D.19085 = D.19084 != ji;
  D.19086 = (long int) D.19085;
  D.19087 = __builtin_expect (D.19086, 0);
  if (D.19087 != 0) goto <D.19088>; else goto <D.19089>;
  <D.19088>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 818, "chunk->data [pos] == ji");
  <D.19089>:
  D.19090 = mono_jit_info_make_tombstone (ji);
  chunk->data[pos] = D.19090;
}


mono_jit_info_make_tombstone (struct MonoJitInfo * ji)
{
  void * D.19091;
  int D.19092;
  struct MonoJitInfo * D.19093;
  struct MonoJitInfo * tombstone;

  tombstone = monoeg_malloc0 (48);
  D.19091 = ji->code_start;
  tombstone->code_start = D.19091;
  D.19092 = ji->code_size;
  tombstone->code_size = D.19092;
  tombstone->d.method = 0B;
  D.19093 = tombstone;
  return D.19093;
}


mono_jit_info_free_or_queue (struct MonoDomain * domain, struct MonoJitInfo * ji)
{
  int D.19095;
  struct GSList * D.19099;
  struct GSList * D.19100;

  D.19095 = domain->num_jit_info_tables;
  if (D.19095 <= 1) goto <D.19096>; else goto <D.19097>;
  <D.19096>:
  mono_thread_hazardous_free_or_queue (ji, monoeg_g_free, 1, 0);
  goto <D.19098>;
  <D.19097>:
  D.19099 = domain->jit_info_free_queue;
  D.19100 = monoeg_g_slist_prepend (D.19099, ji);
  domain->jit_info_free_queue = D.19100;
  <D.19098>:
}


__attribute__((visibility ("hidden")))
mono_jit_info_add_aot_module (struct MonoImage * image, void * start, void * end)
{
  _Bool D.19103;
  long int D.19104;
  long int D.19105;
  struct MonoDomain * mono_root_domain.4;
  _Bool D.19109;
  long int D.19110;
  long int D.19111;
  struct MonoJitInfoTable * D.19114;
  int D.19117;
  int D.19118;
  struct MonoJitInfoTable * D.19119;
  long int end.5;
  long int start.6;
  long int D.19122;
  int D.19123;
  struct MonoJitInfoTable * volatile * D.19124;
  _Bool D.19127;
  long int D.19128;
  long int D.19129;
  struct MonoJitInfo * ji;

  {
    int ret;

    ret = pthread_mutex_lock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19101>; else goto <D.19102>;
    <D.19101>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.19102>:
    D.19103 = ret != 0;
    D.19104 = (long int) D.19103;
    D.19105 = __builtin_expect (D.19104, 0);
    if (D.19105 != 0) goto <D.19106>; else goto <D.19107>;
    <D.19106>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 848, "ret == 0");
    <D.19107>:
  }
  mono_root_domain.4 = mono_root_domain;
  D.19109 = mono_root_domain.4 == 0B;
  D.19110 = (long int) D.19109;
  D.19111 = __builtin_expect (D.19110, 0);
  if (D.19111 != 0) goto <D.19112>; else goto <D.19113>;
  <D.19112>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 854, "mono_root_domain");
  <D.19113>:
  mono_root_domain.4 = mono_root_domain;
  D.19114 = mono_root_domain.4->aot_modules;
  if (D.19114 == 0B) goto <D.19115>; else goto <D.19116>;
  <D.19115>:
  mono_root_domain.4 = mono_root_domain;
  D.19117 = mono_root_domain.4->num_jit_info_tables;
  D.19118 = D.19117 + 1;
  mono_root_domain.4->num_jit_info_tables = D.19118;
  mono_root_domain.4 = mono_root_domain;
  mono_root_domain.4 = mono_root_domain;
  D.19119 = jit_info_table_new (mono_root_domain.4);
  mono_root_domain.4->aot_modules = D.19119;
  <D.19116>:
  ji = monoeg_malloc0 (48);
  ji->d.image = image;
  ji->code_start = start;
  end.5 = (long int) end;
  start.6 = (long int) start;
  D.19122 = end.5 - start.6;
  D.19123 = (int) D.19122;
  ji->code_size = D.19123;
  mono_root_domain.4 = mono_root_domain;
  mono_root_domain.4 = mono_root_domain;
  D.19124 = &mono_root_domain.4->aot_modules;
  jit_info_table_add (mono_root_domain.4, D.19124, ji);
  {
    int ret;

    ret = pthread_mutex_unlock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19125>; else goto <D.19126>;
    <D.19125>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19126>:
    D.19127 = ret != 0;
    D.19128 = (long int) D.19127;
    D.19129 = __builtin_expect (D.19128, 0);
    if (D.19129 != 0) goto <D.19130>; else goto <D.19131>;
    <D.19130>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 866, "ret == 0");
    <D.19131>:
  }
}


__attribute__((visibility ("hidden")))
mono_install_jit_info_find_in_aot (struct MonoJitInfo * (*MonoJitInfoFindInAot) (struct MonoDomain *, struct MonoImage *, void *) func)
{
  jit_info_find_in_aot_func = func;
}


mono_jit_info_get_code_start (struct MonoJitInfo * ji)
{
  void * D.19132;

  D.19132 = ji->code_start;
  return D.19132;
}


mono_jit_info_get_code_size (struct MonoJitInfo * ji)
{
  int D.19134;

  D.19134 = ji->code_size;
  return D.19134;
}


mono_jit_info_get_method (struct MonoJitInfo * ji)
{
  long unsigned int D.19136;
  long unsigned int D.19137;
  _Bool D.19138;
  long int D.19139;
  long int D.19140;
  struct MonoMethod * D.19143;

  D.19136 = BIT_FIELD_REF <*ji, 64, 256>;
  D.19137 = D.19136 & 549755813888;
  D.19138 = D.19137 != 0;
  D.19139 = (long int) D.19138;
  D.19140 = __builtin_expect (D.19139, 0);
  if (D.19140 != 0) goto <D.19141>; else goto <D.19142>;
  <D.19141>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 890, "!ji->async");
  <D.19142>:
  D.19143 = ji->d.method;
  return D.19143;
}


__attribute__((visibility ("hidden")))
mono_jit_code_hash_init (struct MonoInternalHashTable * jit_code_hash)
{
  mono_internal_hash_table_init (jit_code_hash, mono_aligned_addr_hash, jit_info_key_extract, jit_info_next_value);
}


jit_info_next_value (void * value)
{
  void * * D.19145;
  struct MonoJitInfo * info;

  info = value;
  D.19145 = &info->next_jit_code_hash;
  return D.19145;
}


jit_info_key_extract (void * value)
{
  void * D.19147;
  struct MonoJitInfo * info;

  info = value;
  D.19147 = info->d.method;
  return D.19147;
}


__attribute__((visibility ("hidden")))
mono_jit_info_get_generic_jit_info (struct MonoJitInfo * ji)
{
  long unsigned int D.19149;
  long unsigned int D.19150;
  struct MonoGenericJitInfo * D.19153;
  <unnamed-unsigned:15> D.19154;
  int D.19155;

  D.19149 = BIT_FIELD_REF <*ji, 64, 256>;
  D.19150 = D.19149 & 70368744177664;
  if (D.19150 != 0) goto <D.19151>; else goto <D.19152>;
  <D.19151>:
  D.19154 = ji->num_clauses;
  D.19155 = (int) D.19154;
  D.19153 = &ji->clauses[D.19155];
  return D.19153;
  <D.19152>:
  D.19153 = 0B;
  return D.19153;
}


__attribute__((visibility ("hidden")))
mono_jit_info_get_generic_sharing_context (struct MonoJitInfo * ji)
{
  struct MonoGenericSharingContext * D.19159;
  struct MonoGenericJitInfo * gi;

  gi = mono_jit_info_get_generic_jit_info (ji);
  if (gi != 0B) goto <D.19157>; else goto <D.19158>;
  <D.19157>:
  D.19159 = gi->generic_sharing_context;
  return D.19159;
  <D.19158>:
  D.19159 = 0B;
  return D.19159;
}


__attribute__((visibility ("hidden")))
mono_jit_info_set_generic_sharing_context (struct MonoJitInfo * ji, struct MonoGenericSharingContext * gsctx)
{
  _Bool D.19161;
  long int D.19162;
  long int D.19163;
  struct MonoGenericJitInfo * gi;

  gi = mono_jit_info_get_generic_jit_info (ji);
  D.19161 = gi == 0B;
  D.19162 = (long int) D.19161;
  D.19163 = __builtin_expect (D.19162, 0);
  if (D.19163 != 0) goto <D.19164>; else goto <D.19165>;
  <D.19164>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 959, "gi");
  <D.19165>:
  gi->generic_sharing_context = gsctx;
}


__attribute__((visibility ("hidden")))
mono_jit_info_get_try_block_hole_table_info (struct MonoJitInfo * ji)
{
  long unsigned int D.19166;
  long unsigned int D.19167;
  <unnamed-unsigned:15> D.19170;
  int D.19171;
  long unsigned int D.19172;
  struct MonoTryBlockHoleTableJitInfo * D.19175;

  D.19166 = BIT_FIELD_REF <*ji, 64, 256>;
  D.19167 = D.19166 & 35184372088832;
  if (D.19167 != 0) goto <D.19168>; else goto <D.19169>;
  <D.19168>:
  {
    char * ptr;

    D.19170 = ji->num_clauses;
    D.19171 = (int) D.19170;
    ptr = &ji->clauses[D.19171];
    D.19166 = BIT_FIELD_REF <*ji, 64, 256>;
    D.19172 = D.19166 & 70368744177664;
    if (D.19172 != 0) goto <D.19173>; else goto <D.19174>;
    <D.19173>:
    ptr = ptr + 32;
    <D.19174>:
    D.19175 = ptr;
    return D.19175;
  }
  <D.19169>:
  D.19175 = 0B;
  return D.19175;
}


__attribute__((visibility ("hidden")))
mono_jit_info_get_arch_eh_info (struct MonoJitInfo * ji)
{
  long unsigned int D.19177;
  long unsigned int D.19178;
  <unnamed-unsigned:15> D.19181;
  int D.19182;
  long unsigned int D.19183;
  long unsigned int D.19186;
  struct MonoArchEHJitInfo * D.19189;

  D.19177 = BIT_FIELD_REF <*ji, 64, 256>;
  D.19178 = D.19177 & 17592186044416;
  if (D.19178 != 0) goto <D.19179>; else goto <D.19180>;
  <D.19179>:
  {
    char * ptr;

    D.19181 = ji->num_clauses;
    D.19182 = (int) D.19181;
    ptr = &ji->clauses[D.19182];
    D.19177 = BIT_FIELD_REF <*ji, 64, 256>;
    D.19183 = D.19177 & 70368744177664;
    if (D.19183 != 0) goto <D.19184>; else goto <D.19185>;
    <D.19184>:
    ptr = ptr + 32;
    <D.19185>:
    D.19177 = BIT_FIELD_REF <*ji, 64, 256>;
    D.19186 = D.19177 & 35184372088832;
    if (D.19186 != 0) goto <D.19187>; else goto <D.19188>;
    <D.19187>:
    ptr = ptr + 4;
    <D.19188>:
    D.19189 = ptr;
    return D.19189;
  }
  <D.19180>:
  D.19189 = 0B;
  return D.19189;
}


__attribute__((visibility ("hidden")))
mono_jit_info_get_cas_info (struct MonoJitInfo * ji)
{
  long unsigned int D.19191;
  long unsigned int D.19192;
  <unnamed-unsigned:15> D.19195;
  int D.19196;
  long unsigned int D.19197;
  long unsigned int D.19200;
  long unsigned int D.19203;
  struct MonoMethodCasInfo * D.19206;

  D.19191 = BIT_FIELD_REF <*ji, 64, 256>;
  D.19192 = D.19191 & 140737488355328;
  if (D.19192 != 0) goto <D.19193>; else goto <D.19194>;
  <D.19193>:
  {
    char * ptr;

    D.19195 = ji->num_clauses;
    D.19196 = (int) D.19195;
    ptr = &ji->clauses[D.19196];
    D.19191 = BIT_FIELD_REF <*ji, 64, 256>;
    D.19197 = D.19191 & 70368744177664;
    if (D.19197 != 0) goto <D.19198>; else goto <D.19199>;
    <D.19198>:
    ptr = ptr + 32;
    <D.19199>:
    D.19191 = BIT_FIELD_REF <*ji, 64, 256>;
    D.19200 = D.19191 & 35184372088832;
    if (D.19200 != 0) goto <D.19201>; else goto <D.19202>;
    <D.19201>:
    ptr = ptr + 4;
    <D.19202>:
    D.19191 = BIT_FIELD_REF <*ji, 64, 256>;
    D.19203 = D.19191 & 17592186044416;
    if (D.19203 != 0) goto <D.19204>; else goto <D.19205>;
    <D.19204>:
    ptr = ptr + 4;
    <D.19205>:
    D.19206 = ptr;
    return D.19206;
  }
  <D.19194>:
  D.19206 = 0B;
  return D.19206;
}


__attribute__((visibility ("hidden")))
mono_install_create_domain_hook (void (*MonoCreateDomainFunc) (struct MonoDomain *) func)
{
  create_domain_hook = func;
}


__attribute__((visibility ("hidden")))
mono_install_free_domain_hook (void (*MonoFreeDomainFunc) (struct MonoDomain *) func)
{
  free_domain_hook = func;
}


mono_string_equal (struct MonoString * s1, struct MonoString * s2)
{
  mono_bool D.19210;
  mono_unichar2 * D.19213;
  mono_unichar2 * D.19214;
  int D.19215;
  long unsigned int D.19216;
  int D.19217;
  _Bool D.19218;
  int l1;
  int l2;

  l1 = mono_string_length (s1);
  l2 = mono_string_length (s2);
  if (s1 == s2) goto <D.19208>; else goto <D.19209>;
  <D.19208>:
  D.19210 = 1;
  return D.19210;
  <D.19209>:
  if (l1 != l2) goto <D.19211>; else goto <D.19212>;
  <D.19211>:
  D.19210 = 0;
  return D.19210;
  <D.19212>:
  D.19213 = mono_string_chars (s1);
  D.19214 = mono_string_chars (s2);
  D.19215 = l1 * 2;
  D.19216 = (long unsigned int) D.19215;
  D.19217 = memcmp (D.19213, D.19214, D.19216);
  D.19218 = D.19217 == 0;
  D.19210 = (mono_bool) D.19218;
  return D.19210;
}


mono_string_hash (struct MonoString * s)
{
  unsigned int D.19220;
  unsigned int D.19221;
  short unsigned int D.19222;
  unsigned int D.19223;
  unsigned int D.19224;
  const guint16 * p;
  int i;
  int len;
  guint h;

  p = mono_string_chars (s);
  len = mono_string_length (s);
  h = 0;
  i = 0;
  goto <D.18256>;
  <D.18255>:
  D.19220 = h << 5;
  D.19221 = D.19220 - h;
  D.19222 = *p;
  D.19223 = (unsigned int) D.19222;
  h = D.19221 + D.19223;
  p = p + 2;
  i = i + 1;
  <D.18256>:
  if (i < len) goto <D.18255>; else goto <D.18257>;
  <D.18257>:
  D.19224 = h;
  return D.19224;
}


mono_domain_create ()
{
  _Bool D.19228;
  long int D.19229;
  long int D.19230;
  unsigned int domain_shadow_serial.7;
  unsigned int domain_shadow_serial.8;
  unsigned int D.19235;
  void * domain_gc_desc.9;
  unsigned int D.19239;
  long unsigned int D.19240;
  unsigned int D.19241;
  long unsigned int D.19242;
  long unsigned int D.19243;
  unsigned int D.19244;
  int D.19245;
  void * D.19246;
  _Bool D.19249;
  long int D.19250;
  long int D.19251;
  struct MonoGHashTable * * D.19254;
  int shadow_serial.10;
  struct MonoMemPool * D.19256;
  struct MonoCodeManager * D.19257;
  struct LockFreeMempool * D.19258;
  struct MonoGHashTable * D.19259;
  struct GPtrArray * D.19260;
  struct GHashTable * D.19261;
  struct MonoInternalHashTable * D.19262;
  struct MonoGHashTable * D.19263;
  struct MonoJitInfoTable * D.19264;
  struct GHashTable * D.19265;
  struct GHashTable * D.19266;
  struct CRITICAL_SECTION * D.19267;
  struct CRITICAL_SECTION * D.19268;
  struct CRITICAL_SECTION * D.19269;
  struct CRITICAL_SECTION * D.19270;
  _Bool D.19273;
  long int D.19274;
  long int D.19275;
  _Bool D.19280;
  long int D.19281;
  long int D.19282;
  struct MonoPerfCounters * mono_perfcounters.11;
  unsigned int D.19286;
  unsigned int D.19287;
  unsigned int D.19288;
  unsigned int D.19289;
  void (*<T1ad2>) (struct MonoDomain *) create_domain_hook.12;
  struct MonoDomain * D.19293;
  struct MonoDomain * domain;
  guint32 shadow_serial;

  {
    int ret;

    ret = pthread_mutex_lock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19226>; else goto <D.19227>;
    <D.19226>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.19227>:
    D.19228 = ret != 0;
    D.19229 = (long int) D.19228;
    D.19230 = __builtin_expect (D.19229, 0);
    if (D.19230 != 0) goto <D.19231>; else goto <D.19232>;
    <D.19231>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1234, "ret == 0");
    <D.19232>:
  }
  domain_shadow_serial.7 = domain_shadow_serial;
  domain_shadow_serial.8 = domain_shadow_serial.7;
  D.19235 = domain_shadow_serial.8 + 1;
  domain_shadow_serial = D.19235;
  shadow_serial = domain_shadow_serial.8;
  domain_gc_desc.9 = domain_gc_desc;
  if (domain_gc_desc.9 == 0B) goto <D.19237>; else goto <D.19238>;
  <D.19237>:
  {
    unsigned int i;
    unsigned int bit;

    bit = 0;
    i = 64;
    goto <D.18297>;
    <D.18296>:
    bit = i / 8;
    D.19239 = bit / 32;
    D.19240 = domain_gc_bitmap[D.19239];
    D.19241 = bit & 31;
    D.19242 = 1 << D.19241;
    D.19243 = D.19240 | D.19242;
    domain_gc_bitmap[D.19239] = D.19243;
    i = i + 8;
    <D.18297>:
    if (i <= 135) goto <D.18296>; else goto <D.18298>;
    <D.18298>:
    D.19244 = bit + 1;
    D.19245 = (int) D.19244;
    D.19246 = mono_gc_make_descr_from_bitmap (&domain_gc_bitmap, D.19245);
    domain_gc_desc = D.19246;
  }
  <D.19238>:
  {
    int ret;

    ret = pthread_mutex_unlock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19247>; else goto <D.19248>;
    <D.19247>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19248>:
    D.19249 = ret != 0;
    D.19250 = (long int) D.19249;
    D.19251 = __builtin_expect (D.19250, 0);
    if (D.19251 != 0) goto <D.19252>; else goto <D.19253>;
    <D.19252>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1245, "ret == 0");
    <D.19253>:
  }
  domain_gc_desc.9 = domain_gc_desc;
  domain = mono_gc_alloc_fixed (704, domain_gc_desc.9);
  D.19254 = &domain->env;
  mono_gc_register_root (D.19254, 48, 0B);
  shadow_serial.10 = (int) shadow_serial;
  domain->shadow_serial = shadow_serial.10;
  domain->domain = 0B;
  domain->setup = 0B;
  domain->friendly_name = 0B;
  domain->search_path = 0B;
  mono_profiler_appdomain_event (domain, 0);
  D.19256 = mono_mempool_new ();
  domain->mp = D.19256;
  D.19257 = mono_code_manager_new ();
  domain->code_mp = D.19257;
  D.19258 = lock_free_mempool_new ();
  domain->lock_free_mp = D.19258;
  D.19259 = mono_g_hash_table_new_type (mono_string_hash, mono_string_equal, 3);
  domain->env = D.19259;
  domain->domain_assemblies = 0B;
  domain->assembly_bindings = 0B;
  domain->assembly_bindings_parsed = 0;
  D.19260 = monoeg_g_ptr_array_new ();
  domain->class_vtable_array = D.19260;
  D.19261 = monoeg_g_hash_table_new (mono_ptrarray_hash, mono_ptrarray_equal);
  domain->proxy_vtable_hash = D.19261;
  domain->static_data_array = 0B;
  D.19262 = &domain->jit_code_hash;
  mono_jit_code_hash_init (D.19262);
  D.19263 = mono_g_hash_table_new_type (mono_string_hash, mono_string_equal, 3);
  domain->ldstr_table = D.19263;
  domain->num_jit_info_tables = 1;
  D.19264 = jit_info_table_new (domain);
  domain->jit_info_table = D.19264;
  domain->jit_info_free_queue = 0B;
  D.19265 = monoeg_g_hash_table_new (mono_aligned_addr_hash, 0B);
  domain->finalizable_objects_hash = D.19265;
  D.19266 = monoeg_g_hash_table_new (mono_aligned_addr_hash, 0B);
  domain->ftnptrs_hash = D.19266;
  D.19267 = &domain->lock;
  InitializeCriticalSection (D.19267);
  D.19268 = &domain->assemblies_lock;
  InitializeCriticalSection (D.19268);
  D.19269 = &domain->jit_code_hash_lock;
  InitializeCriticalSection (D.19269);
  D.19270 = &domain->finalizable_objects_hash_lock;
  InitializeCriticalSection (D.19270);
  domain->method_rgctx_hash = 0B;
  {
    int ret;

    ret = pthread_mutex_lock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19271>; else goto <D.19272>;
    <D.19271>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.19272>:
    D.19273 = ret != 0;
    D.19274 = (long int) D.19273;
    D.19275 = __builtin_expect (D.19274, 0);
    if (D.19275 != 0) goto <D.19276>; else goto <D.19277>;
    <D.19276>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1292, "ret == 0");
    <D.19277>:
  }
  domain_id_alloc (domain);
  {
    int ret;

    ret = pthread_mutex_unlock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19278>; else goto <D.19279>;
    <D.19278>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19279>:
    D.19280 = ret != 0;
    D.19281 = (long int) D.19280;
    D.19282 = __builtin_expect (D.19281, 0);
    if (D.19282 != 0) goto <D.19283>; else goto <D.19284>;
    <D.19283>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1294, "ret == 0");
    <D.19284>:
  }
  mono_perfcounters.11 = mono_perfcounters;
  D.19286 = mono_perfcounters.11->loader_appdomains;
  D.19287 = D.19286 + 1;
  mono_perfcounters.11->loader_appdomains = D.19287;
  mono_perfcounters.11 = mono_perfcounters;
  D.19288 = mono_perfcounters.11->loader_total_appdomains;
  D.19289 = D.19288 + 1;
  mono_perfcounters.11->loader_total_appdomains = D.19289;
  mono_debug_domain_create (domain);
  create_domain_hook.12 = create_domain_hook;
  if (create_domain_hook.12 != 0B) goto <D.19291>; else goto <D.19292>;
  <D.19291>:
  create_domain_hook.12 = create_domain_hook;
  create_domain_hook.12 (domain);
  <D.19292>:
  mono_profiler_appdomain_loaded (domain, 0);
  D.19293 = domain;
  return D.19293;
}


mono_ptrarray_equal (void * * s1, void * * s2)
{
  void * D.19295;
  long int D.19296;
  void * D.19297;
  long int D.19298;
  int D.19299;
  gboolean D.19302;
  void * * D.19303;
  void * * D.19304;
  long unsigned int D.19305;
  long unsigned int D.19306;
  int D.19307;
  _Bool D.19308;
  int len;

  D.19295 = *s1;
  D.19296 = (long int) D.19295;
  len = (int) D.19296;
  D.19297 = *s2;
  D.19298 = (long int) D.19297;
  D.19299 = (int) D.19298;
  if (D.19299 != len) goto <D.19300>; else goto <D.19301>;
  <D.19300>:
  D.19302 = 0;
  return D.19302;
  <D.19301>:
  D.19303 = s1 + 8;
  D.19304 = s2 + 8;
  D.19305 = (long unsigned int) len;
  D.19306 = D.19305 * 8;
  D.19307 = memcmp (D.19303, D.19304, D.19306);
  D.19308 = D.19307 == 0;
  D.19302 = (gboolean) D.19308;
  return D.19302;
}


mono_ptrarray_hash (void * * s)
{
  void * D.19310;
  long int D.19311;
  long unsigned int D.19312;
  long unsigned int D.19313;
  void * * D.19314;
  void * D.19315;
  long int D.19316;
  unsigned int D.19317;
  guint D.19318;
  int i;
  int len;
  guint hash;

  D.19310 = *s;
  D.19311 = (long int) D.19310;
  len = (int) D.19311;
  hash = 0;
  i = 1;
  goto <D.18270>;
  <D.18269>:
  D.19312 = (long unsigned int) i;
  D.19313 = D.19312 * 8;
  D.19314 = s + D.19313;
  D.19315 = *D.19314;
  D.19316 = (long int) D.19315;
  D.19317 = (unsigned int) D.19316;
  hash = D.19317 + hash;
  i = i + 1;
  <D.18270>:
  if (i < len) goto <D.18269>; else goto <D.18271>;
  <D.18271>:
  D.19318 = hash;
  return D.19318;
}


lock_free_mempool_new ()
{
  struct LockFreeMempool * D.19320;

  D.19320 = monoeg_malloc0 (16);
  return D.19320;
}


domain_id_alloc (struct MonoDomain * domain)
{
  struct MonoDomain * * appdomains_list.13;
  short unsigned int appdomain_list_size.14;
  long unsigned int D.19326;
  long unsigned int D.19327;
  void * D.19328;
  short unsigned int appdomain_next.15;
  long unsigned int D.19330;
  long unsigned int D.19331;
  struct MonoDomain * * D.19332;
  struct MonoDomain * D.19333;
  int D.19336;
  int D.19341;
  long unsigned int D.19346;
  long unsigned int D.19347;
  short unsigned int D.19348;
  long unsigned int D.19349;
  long unsigned int D.19350;
  struct MonoDomain * * D.19351;
  short unsigned int appdomain_next.16;
  short unsigned int D.19353;
  int D.19356;
  int id;
  int i;

  id = -1;
  appdomains_list.13 = appdomains_list;
  if (appdomains_list.13 == 0B) goto <D.19323>; else goto <D.19324>;
  <D.19323>:
  appdomain_list_size = 2;
  appdomain_list_size.14 = appdomain_list_size;
  D.19326 = (long unsigned int) appdomain_list_size.14;
  D.19327 = D.19326 * 8;
  D.19328 = mono_gc_alloc_fixed (D.19327, 0B);
  appdomains_list = D.19328;
  <D.19324>:
  appdomain_next.15 = appdomain_next;
  i = (int) appdomain_next.15;
  goto <D.18279>;
  <D.18278>:
  appdomains_list.13 = appdomains_list;
  D.19330 = (long unsigned int) i;
  D.19331 = D.19330 * 8;
  D.19332 = appdomains_list.13 + D.19331;
  D.19333 = *D.19332;
  if (D.19333 == 0B) goto <D.19334>; else goto <D.19335>;
  <D.19334>:
  id = i;
  goto <D.18277>;
  <D.19335>:
  i = i + 1;
  <D.18279>:
  appdomain_list_size.14 = appdomain_list_size;
  D.19336 = (int) appdomain_list_size.14;
  if (D.19336 > i) goto <D.18278>; else goto <D.18277>;
  <D.18277>:
  if (id == -1) goto <D.19337>; else goto <D.19338>;
  <D.19337>:
  i = 0;
  goto <D.18282>;
  <D.18281>:
  appdomains_list.13 = appdomains_list;
  D.19330 = (long unsigned int) i;
  D.19331 = D.19330 * 8;
  D.19332 = appdomains_list.13 + D.19331;
  D.19333 = *D.19332;
  if (D.19333 == 0B) goto <D.19339>; else goto <D.19340>;
  <D.19339>:
  id = i;
  goto <D.18280>;
  <D.19340>:
  i = i + 1;
  <D.18282>:
  appdomain_next.15 = appdomain_next;
  D.19341 = (int) appdomain_next.15;
  if (D.19341 > i) goto <D.18281>; else goto <D.18280>;
  <D.18280>:
  <D.19338>:
  if (id == -1) goto <D.19342>; else goto <D.19343>;
  <D.19342>:
  {
    struct MonoDomain * * new_list;
    int new_size;

    appdomain_list_size.14 = appdomain_list_size;
    D.19336 = (int) appdomain_list_size.14;
    new_size = D.19336 * 2;
    if (new_size > 65535) goto <D.19344>; else goto <D.19345>;
    <D.19344>:
    monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "domain.c", 1208);
    <D.19345>:
    appdomain_list_size.14 = appdomain_list_size;
    id = (int) appdomain_list_size.14;
    D.19346 = (long unsigned int) new_size;
    D.19347 = D.19346 * 8;
    new_list = mono_gc_alloc_fixed (D.19347, 0B);
    appdomains_list.13 = appdomains_list;
    appdomain_list_size.14 = appdomain_list_size;
    D.19326 = (long unsigned int) appdomain_list_size.14;
    D.19327 = D.19326 * 8;
    memcpy (new_list, appdomains_list.13, D.19327);
    appdomains_list.13 = appdomains_list;
    mono_gc_free_fixed (appdomains_list.13);
    appdomains_list = new_list;
    D.19348 = (short unsigned int) new_size;
    appdomain_list_size = D.19348;
  }
  <D.19343>:
  domain->domain_id = id;
  appdomains_list.13 = appdomains_list;
  D.19349 = (long unsigned int) id;
  D.19350 = D.19349 * 8;
  D.19351 = appdomains_list.13 + D.19350;
  *D.19351 = domain;
  appdomain_next.15 = appdomain_next;
  appdomain_next.16 = appdomain_next.15;
  D.19353 = appdomain_next.16 + 1;
  appdomain_next = D.19353;
  appdomain_next.15 = appdomain_next;
  appdomain_list_size.14 = appdomain_list_size;
  if (appdomain_next.15 > appdomain_list_size.14) goto <D.19354>; else goto <D.19355>;
  <D.19354>:
  appdomain_next = 0;
  <D.19355>:
  D.19356 = id;
  return D.19356;
}


mono_init (const char * domain_name)
{
  struct MonoDomain * D.19358;

  D.19358 = mono_init_internal (domain_name, 0B, "v2.0.50727");
  return D.19358;
}


mono_init_internal (const char * filename, const char * exe_filename, const char * runtime_version)
{
  struct MonoDomain * domain.17;
  int D.19363;
  struct MonoDomain * domain.18;
  unsigned int appdomain_thread_id.19;
  const struct MonoRuntimeInfo * D.19373;
  const struct MonoRuntimeInfo * D.19374;
  const char[12] * D.19377;
  const struct MonoRuntimeInfo * D.19378;
  const struct MonoRuntimeInfo * current_runtime.20;
  <unnamed type> status.21;
  const char * D.19386;
  const char[4] * D.19387;
  const char * D.19388;
  const char * D.19389;
  struct MonoImage * D.19391;
  struct MonoImage * D.19392;
  struct MonoClass * D.19393;
  struct MonoClass * D.19394;
  _Bool D.19395;
  long int D.19396;
  long int D.19397;
  struct MonoClass * D.19400;
  struct MonoClass * D.19401;
  _Bool D.19402;
  long int D.19403;
  long int D.19404;
  struct MonoClass * D.19407;
  struct MonoClass * D.19408;
  _Bool D.19409;
  long int D.19410;
  long int D.19411;
  struct MonoClass * D.19414;
  struct MonoClass * D.19415;
  _Bool D.19416;
  long int D.19417;
  long int D.19418;
  struct MonoClass * D.19421;
  struct MonoClass * D.19422;
  _Bool D.19423;
  long int D.19424;
  long int D.19425;
  struct MonoClass * D.19428;
  struct MonoClass * D.19429;
  _Bool D.19430;
  long int D.19431;
  long int D.19432;
  struct MonoClass * D.19435;
  struct MonoClass * D.19436;
  _Bool D.19437;
  long int D.19438;
  long int D.19439;
  struct MonoClass * D.19442;
  struct MonoClass * D.19443;
  _Bool D.19444;
  long int D.19445;
  long int D.19446;
  struct MonoClass * D.19449;
  struct MonoClass * D.19450;
  _Bool D.19451;
  long int D.19452;
  long int D.19453;
  struct MonoClass * D.19456;
  struct MonoClass * D.19457;
  _Bool D.19458;
  long int D.19459;
  long int D.19460;
  struct MonoClass * D.19463;
  struct MonoClass * D.19464;
  _Bool D.19465;
  long int D.19466;
  long int D.19467;
  struct MonoClass * D.19470;
  struct MonoClass * D.19471;
  _Bool D.19472;
  long int D.19473;
  long int D.19474;
  struct MonoClass * D.19477;
  struct MonoClass * D.19478;
  _Bool D.19479;
  long int D.19480;
  long int D.19481;
  struct MonoClass * D.19484;
  struct MonoClass * D.19485;
  _Bool D.19486;
  long int D.19487;
  long int D.19488;
  struct MonoClass * D.19491;
  struct MonoClass * D.19492;
  _Bool D.19493;
  long int D.19494;
  long int D.19495;
  struct MonoClass * D.19498;
  struct MonoClass * D.19499;
  _Bool D.19500;
  long int D.19501;
  long int D.19502;
  struct MonoClass * D.19505;
  struct MonoClass * D.19506;
  _Bool D.19507;
  long int D.19508;
  long int D.19509;
  struct MonoClass * D.19512;
  struct MonoClass * D.19513;
  _Bool D.19514;
  long int D.19515;
  long int D.19516;
  struct MonoClass * D.19519;
  struct MonoClass * D.19520;
  _Bool D.19521;
  long int D.19522;
  long int D.19523;
  struct MonoClass * D.19526;
  struct MonoClass * D.19527;
  _Bool D.19528;
  long int D.19529;
  long int D.19530;
  struct MonoClass * D.19533;
  struct MonoClass * D.19534;
  _Bool D.19535;
  long int D.19536;
  long int D.19537;
  struct MonoClass * D.19540;
  struct MonoClass * D.19541;
  _Bool D.19542;
  long int D.19543;
  long int D.19544;
  struct MonoClass * D.19547;
  struct MonoClass * D.19548;
  _Bool D.19549;
  long int D.19550;
  long int D.19551;
  struct MonoClass * D.19554;
  struct MonoClass * D.19555;
  _Bool D.19556;
  long int D.19557;
  long int D.19558;
  struct MonoClass * D.19561;
  struct MonoClass * D.19562;
  _Bool D.19563;
  long int D.19564;
  long int D.19565;
  struct MonoClass * D.19568;
  struct MonoClass * D.19569;
  _Bool D.19570;
  long int D.19571;
  long int D.19572;
  struct MonoClass * D.19575;
  struct MonoClass * D.19576;
  _Bool D.19577;
  long int D.19578;
  long int D.19579;
  struct MonoClass * D.19582;
  struct MonoClass * D.19583;
  _Bool D.19584;
  long int D.19585;
  long int D.19586;
  struct MonoClass * D.19589;
  struct MonoClass * D.19590;
  _Bool D.19591;
  long int D.19592;
  long int D.19593;
  struct MonoClass * D.19596;
  struct MonoClass * D.19597;
  _Bool D.19598;
  long int D.19599;
  long int D.19600;
  struct MonoClass * D.19603;
  struct MonoClass * D.19604;
  _Bool D.19605;
  long int D.19606;
  long int D.19607;
  struct MonoClass * D.19610;
  struct MonoClass * D.19611;
  struct _IO_FILE * stderr.22;
  const char * iftmp.23;
  struct MonoClass * D.19619;
  struct MonoClass * D.19620;
  _Bool D.19621;
  long int D.19622;
  long int D.19623;
  struct MonoClass * D.19626;
  struct MonoClass * D.19627;
  _Bool D.19628;
  long int D.19629;
  long int D.19630;
  struct MonoClass * D.19633;
  struct MonoClass * D.19634;
  _Bool D.19635;
  long int D.19636;
  long int D.19637;
  struct MonoClass * D.19640;
  struct MonoClass * D.19641;
  _Bool D.19642;
  long int D.19643;
  long int D.19644;
  struct MonoClass * D.19647;
  struct MonoClass * D.19648;
  _Bool D.19649;
  long int D.19650;
  long int D.19651;
  struct MonoClass * D.19654;
  struct MonoClass * D.19655;
  _Bool D.19656;
  long int D.19657;
  long int D.19658;
  struct MonoClass * D.19661;
  struct MonoClass * D.19662;
  _Bool D.19663;
  long int D.19664;
  long int D.19665;
  struct MonoClass * D.19668;
  struct MonoClass * D.19669;
  _Bool D.19670;
  long int D.19671;
  long int D.19672;
  struct MonoClass * D.19675;
  struct MonoClass * D.19676;
  _Bool D.19677;
  long int D.19678;
  long int D.19679;
  struct MonoClass * D.19682;
  struct MonoClass * D.19683;
  _Bool D.19684;
  long int D.19685;
  long int D.19686;
  struct MonoClass * D.19689;
  struct MonoClass * D.19690;
  _Bool D.19691;
  long int D.19692;
  long int D.19693;
  struct MonoClass * D.19696;
  struct MonoClass * D.19697;
  _Bool D.19698;
  long int D.19699;
  long int D.19700;
  struct MonoClass * D.19703;
  struct MonoClass * D.19704;
  _Bool D.19705;
  long int D.19706;
  long int D.19707;
  struct MonoClass * D.19710;
  struct MonoClass * D.19711;
  _Bool D.19712;
  long int D.19713;
  long int D.19714;
  struct MonoClass * D.19717;
  struct MonoClass * D.19718;
  _Bool D.19719;
  long int D.19720;
  long int D.19721;
  struct MonoClass * D.19724;
  struct MonoClass * D.19725;
  _Bool D.19726;
  long int D.19727;
  long int D.19728;
  struct MonoClass * D.19731;
  struct MonoClass * D.19732;
  struct MonoClass * D.19733;
  struct MonoClass * D.19734;
  struct MonoClass * D.19735;
  struct MonoClass * D.19736;
  struct MonoClass * D.19737;
  struct MonoClass * D.19738;
  struct MonoClass * D.19739;
  struct MonoClass * D.19740;
  struct MonoClass * D.19741;
  gchar * D.19742;
  struct MonoDomain * D.19743;
  static struct MonoDomain * domain = 0B;
  struct MonoAssembly * ass;
  MonoImageOpenStatus status;
  const struct MonoRuntimeInfo * runtimes[7];
  int n;

  try
    {
      ass = 0B;
      status = 0;
      domain.17 = domain;
      if (domain.17 != 0B) goto <D.19361>; else goto <D.19362>;
      <D.19361>:
      monoeg_assertion_message ("* Assertion: should not be reached at %s:%d\n", "domain.c", 1334);
      <D.19362>:
      wapi_init ();
      mono_perfcounters_init ();
      mono_counters_register ("Max native code in a domain", 256, &max_domain_code_size);
      mono_counters_register ("Max code space allocated in a domain", 256, &max_domain_code_alloc);
      mono_counters_register ("Total code space allocated", 256, &total_domain_code_alloc);
      mono_gc_base_init ();
      mono_native_tls_alloc (&appdomain_thread_id, 0B);
      InitializeCriticalSection (&appdomains_mutex);
      mono_metadata_init ();
      mono_images_init ();
      mono_assemblies_init ();
      mono_classes_init ();
      mono_loader_init ();
      mono_reflection_init ();
      mono_runtime_init_tls ();
      D.19363 = mono_gc_is_moving ();
      if (D.19363 == 0) goto <D.19364>; else goto <D.19365>;
      <D.19364>:
      mono_gc_register_root (&appdomains_list, 8, 0B);
      <D.19365>:
      domain.18 = mono_domain_create ();
      domain = domain.18;
      domain.17 = domain;
      mono_root_domain = domain.17;
      domain.17 = domain;
      tls_appdomain = domain.17;
      appdomain_thread_id.19 = appdomain_thread_id;
      domain.17 = domain;
      mono_native_tls_set_value (appdomain_thread_id.19, domain.17);
      domain.17 = domain;
      mono_gc_set_current_thread_appdomain (domain.17);
      if (exe_filename != 0B) goto <D.19368>; else goto <D.19369>;
      <D.19368>:
      get_runtimes_from_exe (exe_filename, &exe_image, &runtimes);
      goto <D.19370>;
      <D.19369>:
      if (runtime_version != 0B) goto <D.19371>; else goto <D.19372>;
      <D.19371>:
      D.19373 = get_runtime_by_version (runtime_version);
      runtimes[0] = D.19373;
      runtimes[1] = 0B;
      <D.19372>:
      <D.19370>:
      D.19374 = runtimes[0];
      if (D.19374 == 0B) goto <D.19375>; else goto <D.19376>;
      <D.19375>:
      {
        const struct MonoRuntimeInfo * default_runtime;

        default_runtime = get_runtime_by_version ("v2.0.50727");
        runtimes[0] = default_runtime;
        runtimes[1] = 0B;
        monoeg_g_print ("WARNING: The runtime version supported by this application is unavailable.\n");
        D.19377 = &default_runtime->runtime_version;
        monoeg_g_print ("Using default runtime: %s\n", D.19377);
      }
      <D.19376>:
      n = 0;
      goto <D.18315>;
      <D.18314>:
      D.19378 = runtimes[n];
      current_runtime = D.19378;
      current_runtime.20 = current_runtime;
      ass = mono_assembly_load_corlib (current_runtime.20, &status);
      status.21 = status;
      if (status.21 > 1) goto <D.18313>; else goto <D.19381>;
      <D.19381>:
      n = n + 1;
      <D.18315>:
      D.19378 = runtimes[n];
      if (D.19378 != 0B) goto <D.19382>; else goto <D.18313>;
      <D.19382>:
      if (ass == 0B) goto <D.18314>; else goto <D.18313>;
      <D.18313>:
      status.21 = status;
      if (status.21 != 0) goto <D.19383>; else goto <D.19385>;
      <D.19385>:
      if (ass == 0B) goto <D.19383>; else goto <D.19384>;
      <D.19383>:
      status.21 = status;
      switch (status.21) <default: <D.19390>, case 0: <D.18321>, case 1: <D.18316>, case 2: <D.18320>, case 3: <D.18319>>
      <D.18316>:
      {
        char * corlib_file;

        D.19386 = mono_assembly_getrootdir ();
        current_runtime.20 = current_runtime;
        D.19387 = &current_runtime.20->framework_version;
        corlib_file = monoeg_g_build_path ("/", D.19386, "mono", D.19387, "mscorlib.dll", 0B);
        monoeg_g_print ("The assembly mscorlib.dll was not found or could not be loaded.\n");
        monoeg_g_print ("It should have been installed in the `%s\' directory.\n", corlib_file);
        monoeg_g_free (corlib_file);
        goto <D.18318>;
      }
      <D.18319>:
      D.19388 = mono_assembly_getrootdir ();
      monoeg_g_print ("The file %s/mscorlib.dll is an invalid CIL image\n", D.19388);
      goto <D.18318>;
      <D.18320>:
      D.19389 = mono_assembly_getrootdir ();
      monoeg_g_print ("Missing assembly reference in %s/mscorlib.dll\n", D.19389);
      goto <D.18318>;
      <D.18321>:
      goto <D.18318>;
      <D.19390>:
      <D.18318>:
      exit (1);
      <D.19384>:
      D.19391 = mono_assembly_get_image (ass);
      mono_defaults.corlib = D.19391;
      D.19392 = mono_defaults.corlib;
      D.19393 = mono_class_from_name (D.19392, "System", "Object");
      mono_defaults.object_class = D.19393;
      D.19394 = mono_defaults.object_class;
      D.19395 = D.19394 == 0B;
      D.19396 = (long int) D.19395;
      D.19397 = __builtin_expect (D.19396, 0);
      if (D.19397 != 0) goto <D.19398>; else goto <D.19399>;
      <D.19398>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1442, "mono_defaults.object_class != 0");
      <D.19399>:
      D.19392 = mono_defaults.corlib;
      D.19400 = mono_class_from_name (D.19392, "System", "Void");
      mono_defaults.void_class = D.19400;
      D.19401 = mono_defaults.void_class;
      D.19402 = D.19401 == 0B;
      D.19403 = (long int) D.19402;
      D.19404 = __builtin_expect (D.19403, 0);
      if (D.19404 != 0) goto <D.19405>; else goto <D.19406>;
      <D.19405>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1446, "mono_defaults.void_class != 0");
      <D.19406>:
      D.19392 = mono_defaults.corlib;
      D.19407 = mono_class_from_name (D.19392, "System", "Boolean");
      mono_defaults.boolean_class = D.19407;
      D.19408 = mono_defaults.boolean_class;
      D.19409 = D.19408 == 0B;
      D.19410 = (long int) D.19409;
      D.19411 = __builtin_expect (D.19410, 0);
      if (D.19411 != 0) goto <D.19412>; else goto <D.19413>;
      <D.19412>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1450, "mono_defaults.boolean_class != 0");
      <D.19413>:
      D.19392 = mono_defaults.corlib;
      D.19414 = mono_class_from_name (D.19392, "System", "Byte");
      mono_defaults.byte_class = D.19414;
      D.19415 = mono_defaults.byte_class;
      D.19416 = D.19415 == 0B;
      D.19417 = (long int) D.19416;
      D.19418 = __builtin_expect (D.19417, 0);
      if (D.19418 != 0) goto <D.19419>; else goto <D.19420>;
      <D.19419>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1454, "mono_defaults.byte_class != 0");
      <D.19420>:
      D.19392 = mono_defaults.corlib;
      D.19421 = mono_class_from_name (D.19392, "System", "SByte");
      mono_defaults.sbyte_class = D.19421;
      D.19422 = mono_defaults.sbyte_class;
      D.19423 = D.19422 == 0B;
      D.19424 = (long int) D.19423;
      D.19425 = __builtin_expect (D.19424, 0);
      if (D.19425 != 0) goto <D.19426>; else goto <D.19427>;
      <D.19426>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1458, "mono_defaults.sbyte_class != 0");
      <D.19427>:
      D.19392 = mono_defaults.corlib;
      D.19428 = mono_class_from_name (D.19392, "System", "Int16");
      mono_defaults.int16_class = D.19428;
      D.19429 = mono_defaults.int16_class;
      D.19430 = D.19429 == 0B;
      D.19431 = (long int) D.19430;
      D.19432 = __builtin_expect (D.19431, 0);
      if (D.19432 != 0) goto <D.19433>; else goto <D.19434>;
      <D.19433>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1462, "mono_defaults.int16_class != 0");
      <D.19434>:
      D.19392 = mono_defaults.corlib;
      D.19435 = mono_class_from_name (D.19392, "System", "UInt16");
      mono_defaults.uint16_class = D.19435;
      D.19436 = mono_defaults.uint16_class;
      D.19437 = D.19436 == 0B;
      D.19438 = (long int) D.19437;
      D.19439 = __builtin_expect (D.19438, 0);
      if (D.19439 != 0) goto <D.19440>; else goto <D.19441>;
      <D.19440>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1466, "mono_defaults.uint16_class != 0");
      <D.19441>:
      D.19392 = mono_defaults.corlib;
      D.19442 = mono_class_from_name (D.19392, "System", "Int32");
      mono_defaults.int32_class = D.19442;
      D.19443 = mono_defaults.int32_class;
      D.19444 = D.19443 == 0B;
      D.19445 = (long int) D.19444;
      D.19446 = __builtin_expect (D.19445, 0);
      if (D.19446 != 0) goto <D.19447>; else goto <D.19448>;
      <D.19447>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1470, "mono_defaults.int32_class != 0");
      <D.19448>:
      D.19392 = mono_defaults.corlib;
      D.19449 = mono_class_from_name (D.19392, "System", "UInt32");
      mono_defaults.uint32_class = D.19449;
      D.19450 = mono_defaults.uint32_class;
      D.19451 = D.19450 == 0B;
      D.19452 = (long int) D.19451;
      D.19453 = __builtin_expect (D.19452, 0);
      if (D.19453 != 0) goto <D.19454>; else goto <D.19455>;
      <D.19454>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1474, "mono_defaults.uint32_class != 0");
      <D.19455>:
      D.19392 = mono_defaults.corlib;
      D.19456 = mono_class_from_name (D.19392, "System", "UIntPtr");
      mono_defaults.uint_class = D.19456;
      D.19457 = mono_defaults.uint_class;
      D.19458 = D.19457 == 0B;
      D.19459 = (long int) D.19458;
      D.19460 = __builtin_expect (D.19459, 0);
      if (D.19460 != 0) goto <D.19461>; else goto <D.19462>;
      <D.19461>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1478, "mono_defaults.uint_class != 0");
      <D.19462>:
      D.19392 = mono_defaults.corlib;
      D.19463 = mono_class_from_name (D.19392, "System", "IntPtr");
      mono_defaults.int_class = D.19463;
      D.19464 = mono_defaults.int_class;
      D.19465 = D.19464 == 0B;
      D.19466 = (long int) D.19465;
      D.19467 = __builtin_expect (D.19466, 0);
      if (D.19467 != 0) goto <D.19468>; else goto <D.19469>;
      <D.19468>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1482, "mono_defaults.int_class != 0");
      <D.19469>:
      D.19392 = mono_defaults.corlib;
      D.19470 = mono_class_from_name (D.19392, "System", "Int64");
      mono_defaults.int64_class = D.19470;
      D.19471 = mono_defaults.int64_class;
      D.19472 = D.19471 == 0B;
      D.19473 = (long int) D.19472;
      D.19474 = __builtin_expect (D.19473, 0);
      if (D.19474 != 0) goto <D.19475>; else goto <D.19476>;
      <D.19475>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1486, "mono_defaults.int64_class != 0");
      <D.19476>:
      D.19392 = mono_defaults.corlib;
      D.19477 = mono_class_from_name (D.19392, "System", "UInt64");
      mono_defaults.uint64_class = D.19477;
      D.19478 = mono_defaults.uint64_class;
      D.19479 = D.19478 == 0B;
      D.19480 = (long int) D.19479;
      D.19481 = __builtin_expect (D.19480, 0);
      if (D.19481 != 0) goto <D.19482>; else goto <D.19483>;
      <D.19482>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1490, "mono_defaults.uint64_class != 0");
      <D.19483>:
      D.19392 = mono_defaults.corlib;
      D.19484 = mono_class_from_name (D.19392, "System", "Single");
      mono_defaults.single_class = D.19484;
      D.19485 = mono_defaults.single_class;
      D.19486 = D.19485 == 0B;
      D.19487 = (long int) D.19486;
      D.19488 = __builtin_expect (D.19487, 0);
      if (D.19488 != 0) goto <D.19489>; else goto <D.19490>;
      <D.19489>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1494, "mono_defaults.single_class != 0");
      <D.19490>:
      D.19392 = mono_defaults.corlib;
      D.19491 = mono_class_from_name (D.19392, "System", "Double");
      mono_defaults.double_class = D.19491;
      D.19492 = mono_defaults.double_class;
      D.19493 = D.19492 == 0B;
      D.19494 = (long int) D.19493;
      D.19495 = __builtin_expect (D.19494, 0);
      if (D.19495 != 0) goto <D.19496>; else goto <D.19497>;
      <D.19496>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1498, "mono_defaults.double_class != 0");
      <D.19497>:
      D.19392 = mono_defaults.corlib;
      D.19498 = mono_class_from_name (D.19392, "System", "Char");
      mono_defaults.char_class = D.19498;
      D.19499 = mono_defaults.char_class;
      D.19500 = D.19499 == 0B;
      D.19501 = (long int) D.19500;
      D.19502 = __builtin_expect (D.19501, 0);
      if (D.19502 != 0) goto <D.19503>; else goto <D.19504>;
      <D.19503>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1502, "mono_defaults.char_class != 0");
      <D.19504>:
      D.19392 = mono_defaults.corlib;
      D.19505 = mono_class_from_name (D.19392, "System", "String");
      mono_defaults.string_class = D.19505;
      D.19506 = mono_defaults.string_class;
      D.19507 = D.19506 == 0B;
      D.19508 = (long int) D.19507;
      D.19509 = __builtin_expect (D.19508, 0);
      if (D.19509 != 0) goto <D.19510>; else goto <D.19511>;
      <D.19510>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1506, "mono_defaults.string_class != 0");
      <D.19511>:
      D.19392 = mono_defaults.corlib;
      D.19512 = mono_class_from_name (D.19392, "System", "Enum");
      mono_defaults.enum_class = D.19512;
      D.19513 = mono_defaults.enum_class;
      D.19514 = D.19513 == 0B;
      D.19515 = (long int) D.19514;
      D.19516 = __builtin_expect (D.19515, 0);
      if (D.19516 != 0) goto <D.19517>; else goto <D.19518>;
      <D.19517>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1510, "mono_defaults.enum_class != 0");
      <D.19518>:
      D.19392 = mono_defaults.corlib;
      D.19519 = mono_class_from_name (D.19392, "System", "Array");
      mono_defaults.array_class = D.19519;
      D.19520 = mono_defaults.array_class;
      D.19521 = D.19520 == 0B;
      D.19522 = (long int) D.19521;
      D.19523 = __builtin_expect (D.19522, 0);
      if (D.19523 != 0) goto <D.19524>; else goto <D.19525>;
      <D.19524>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1514, "mono_defaults.array_class != 0");
      <D.19525>:
      D.19392 = mono_defaults.corlib;
      D.19526 = mono_class_from_name (D.19392, "System", "Delegate");
      mono_defaults.delegate_class = D.19526;
      D.19527 = mono_defaults.delegate_class;
      D.19528 = D.19527 == 0B;
      D.19529 = (long int) D.19528;
      D.19530 = __builtin_expect (D.19529, 0);
      if (D.19530 != 0) goto <D.19531>; else goto <D.19532>;
      <D.19531>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1518, "mono_defaults.delegate_class != 0");
      <D.19532>:
      D.19392 = mono_defaults.corlib;
      D.19533 = mono_class_from_name (D.19392, "System", "MulticastDelegate");
      mono_defaults.multicastdelegate_class = D.19533;
      D.19534 = mono_defaults.multicastdelegate_class;
      D.19535 = D.19534 == 0B;
      D.19536 = (long int) D.19535;
      D.19537 = __builtin_expect (D.19536, 0);
      if (D.19537 != 0) goto <D.19538>; else goto <D.19539>;
      <D.19538>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1522, "mono_defaults.multicastdelegate_class != 0");
      <D.19539>:
      D.19392 = mono_defaults.corlib;
      D.19540 = mono_class_from_name (D.19392, "System.Runtime.Remoting.Messaging", "AsyncResult");
      mono_defaults.asyncresult_class = D.19540;
      D.19541 = mono_defaults.asyncresult_class;
      D.19542 = D.19541 == 0B;
      D.19543 = (long int) D.19542;
      D.19544 = __builtin_expect (D.19543, 0);
      if (D.19544 != 0) goto <D.19545>; else goto <D.19546>;
      <D.19545>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1527, "mono_defaults.asyncresult_class != 0");
      <D.19546>:
      D.19392 = mono_defaults.corlib;
      D.19547 = mono_class_from_name (D.19392, "System.Threading", "ManualResetEvent");
      mono_defaults.manualresetevent_class = D.19547;
      D.19548 = mono_defaults.manualresetevent_class;
      D.19549 = D.19548 == 0B;
      D.19550 = (long int) D.19549;
      D.19551 = __builtin_expect (D.19550, 0);
      if (D.19551 != 0) goto <D.19552>; else goto <D.19553>;
      <D.19552>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1531, "mono_defaults.manualresetevent_class != 0");
      <D.19553>:
      D.19392 = mono_defaults.corlib;
      D.19554 = mono_class_from_name (D.19392, "System", "RuntimeTypeHandle");
      mono_defaults.typehandle_class = D.19554;
      D.19555 = mono_defaults.typehandle_class;
      D.19556 = D.19555 == 0B;
      D.19557 = (long int) D.19556;
      D.19558 = __builtin_expect (D.19557, 0);
      if (D.19558 != 0) goto <D.19559>; else goto <D.19560>;
      <D.19559>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1535, "mono_defaults.typehandle_class != 0");
      <D.19560>:
      D.19392 = mono_defaults.corlib;
      D.19561 = mono_class_from_name (D.19392, "System", "RuntimeMethodHandle");
      mono_defaults.methodhandle_class = D.19561;
      D.19562 = mono_defaults.methodhandle_class;
      D.19563 = D.19562 == 0B;
      D.19564 = (long int) D.19563;
      D.19565 = __builtin_expect (D.19564, 0);
      if (D.19565 != 0) goto <D.19566>; else goto <D.19567>;
      <D.19566>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1539, "mono_defaults.methodhandle_class != 0");
      <D.19567>:
      D.19392 = mono_defaults.corlib;
      D.19568 = mono_class_from_name (D.19392, "System", "RuntimeFieldHandle");
      mono_defaults.fieldhandle_class = D.19568;
      D.19569 = mono_defaults.fieldhandle_class;
      D.19570 = D.19569 == 0B;
      D.19571 = (long int) D.19570;
      D.19572 = __builtin_expect (D.19571, 0);
      if (D.19572 != 0) goto <D.19573>; else goto <D.19574>;
      <D.19573>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1543, "mono_defaults.fieldhandle_class != 0");
      <D.19574>:
      D.19392 = mono_defaults.corlib;
      D.19575 = mono_class_from_name (D.19392, "System", "Type");
      mono_defaults.systemtype_class = D.19575;
      D.19576 = mono_defaults.systemtype_class;
      D.19577 = D.19576 == 0B;
      D.19578 = (long int) D.19577;
      D.19579 = __builtin_expect (D.19578, 0);
      if (D.19579 != 0) goto <D.19580>; else goto <D.19581>;
      <D.19580>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1547, "mono_defaults.systemtype_class != 0");
      <D.19581>:
      D.19392 = mono_defaults.corlib;
      D.19582 = mono_class_from_name (D.19392, "System", "MonoType");
      mono_defaults.monotype_class = D.19582;
      D.19583 = mono_defaults.monotype_class;
      D.19584 = D.19583 == 0B;
      D.19585 = (long int) D.19584;
      D.19586 = __builtin_expect (D.19585, 0);
      if (D.19586 != 0) goto <D.19587>; else goto <D.19588>;
      <D.19587>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1551, "mono_defaults.monotype_class != 0");
      <D.19588>:
      D.19392 = mono_defaults.corlib;
      D.19589 = mono_class_from_name (D.19392, "System", "Exception");
      mono_defaults.exception_class = D.19589;
      D.19590 = mono_defaults.exception_class;
      D.19591 = D.19590 == 0B;
      D.19592 = (long int) D.19591;
      D.19593 = __builtin_expect (D.19592, 0);
      if (D.19593 != 0) goto <D.19594>; else goto <D.19595>;
      <D.19594>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1555, "mono_defaults.exception_class != 0");
      <D.19595>:
      D.19392 = mono_defaults.corlib;
      D.19596 = mono_class_from_name (D.19392, "System.Threading", "ThreadAbortException");
      mono_defaults.threadabortexception_class = D.19596;
      D.19597 = mono_defaults.threadabortexception_class;
      D.19598 = D.19597 == 0B;
      D.19599 = (long int) D.19598;
      D.19600 = __builtin_expect (D.19599, 0);
      if (D.19600 != 0) goto <D.19601>; else goto <D.19602>;
      <D.19601>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1559, "mono_defaults.threadabortexception_class != 0");
      <D.19602>:
      D.19392 = mono_defaults.corlib;
      D.19603 = mono_class_from_name (D.19392, "System.Threading", "Thread");
      mono_defaults.thread_class = D.19603;
      D.19604 = mono_defaults.thread_class;
      D.19605 = D.19604 == 0B;
      D.19606 = (long int) D.19605;
      D.19607 = __builtin_expect (D.19606, 0);
      if (D.19607 != 0) goto <D.19608>; else goto <D.19609>;
      <D.19608>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1563, "mono_defaults.thread_class != 0");
      <D.19609>:
      D.19392 = mono_defaults.corlib;
      D.19610 = mono_class_from_name (D.19392, "System.Threading", "InternalThread");
      mono_defaults.internal_thread_class = D.19610;
      D.19611 = mono_defaults.internal_thread_class;
      if (D.19611 == 0B) goto <D.19612>; else goto <D.19613>;
      <D.19612>:
      stderr.22 = stderr;
      fprintf (stderr.22, "Corlib too old for this runtime.\n");
      stderr.22 = stderr;
      D.19392 = mono_defaults.corlib;
      if (D.19392 != 0B) goto <D.19616>; else goto <D.19617>;
      <D.19616>:
      D.19392 = mono_defaults.corlib;
      iftmp.23 = mono_image_get_filename (D.19392);
      goto <D.19618>;
      <D.19617>:
      iftmp.23 = "unknown";
      <D.19618>:
      fprintf (stderr.22, "Loaded from: %s\n", iftmp.23);
      exit (1);
      <D.19613>:
      D.19392 = mono_defaults.corlib;
      D.19619 = mono_class_from_name (D.19392, "System", "AppDomain");
      mono_defaults.appdomain_class = D.19619;
      D.19620 = mono_defaults.appdomain_class;
      D.19621 = D.19620 == 0B;
      D.19622 = (long int) D.19621;
      D.19623 = __builtin_expect (D.19622, 0);
      if (D.19623 != 0) goto <D.19624>; else goto <D.19625>;
      <D.19624>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1577, "mono_defaults.appdomain_class != 0");
      <D.19625>:
      D.19392 = mono_defaults.corlib;
      D.19626 = mono_class_from_name (D.19392, "System.Runtime.Remoting.Proxies", "TransparentProxy");
      mono_defaults.transparent_proxy_class = D.19626;
      D.19627 = mono_defaults.transparent_proxy_class;
      D.19628 = D.19627 == 0B;
      D.19629 = (long int) D.19628;
      D.19630 = __builtin_expect (D.19629, 0);
      if (D.19630 != 0) goto <D.19631>; else goto <D.19632>;
      <D.19631>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1582, "mono_defaults.transparent_proxy_class != 0");
      <D.19632>:
      D.19392 = mono_defaults.corlib;
      D.19633 = mono_class_from_name (D.19392, "System.Runtime.Remoting.Proxies", "RealProxy");
      mono_defaults.real_proxy_class = D.19633;
      D.19634 = mono_defaults.real_proxy_class;
      D.19635 = D.19634 == 0B;
      D.19636 = (long int) D.19635;
      D.19637 = __builtin_expect (D.19636, 0);
      if (D.19637 != 0) goto <D.19638>; else goto <D.19639>;
      <D.19638>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1586, "mono_defaults.real_proxy_class != 0");
      <D.19639>:
      D.19392 = mono_defaults.corlib;
      D.19640 = mono_class_from_name (D.19392, "System", "MarshalByRefObject");
      mono_defaults.marshalbyrefobject_class = D.19640;
      D.19641 = mono_defaults.marshalbyrefobject_class;
      D.19642 = D.19641 == 0B;
      D.19643 = (long int) D.19642;
      D.19644 = __builtin_expect (D.19643, 0);
      if (D.19644 != 0) goto <D.19645>; else goto <D.19646>;
      <D.19645>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1590, "mono_defaults.marshalbyrefobject_class != 0");
      <D.19646>:
      D.19392 = mono_defaults.corlib;
      D.19647 = mono_class_from_name (D.19392, "System.Runtime.Remoting", "IRemotingTypeInfo");
      mono_defaults.iremotingtypeinfo_class = D.19647;
      D.19648 = mono_defaults.iremotingtypeinfo_class;
      D.19649 = D.19648 == 0B;
      D.19650 = (long int) D.19649;
      D.19651 = __builtin_expect (D.19650, 0);
      if (D.19651 != 0) goto <D.19652>; else goto <D.19653>;
      <D.19652>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1594, "mono_defaults.iremotingtypeinfo_class != 0");
      <D.19653>:
      D.19392 = mono_defaults.corlib;
      D.19654 = mono_class_from_name (D.19392, "System.Runtime.Remoting.Messaging", "MonoMethodMessage");
      mono_defaults.mono_method_message_class = D.19654;
      D.19655 = mono_defaults.mono_method_message_class;
      D.19656 = D.19655 == 0B;
      D.19657 = (long int) D.19656;
      D.19658 = __builtin_expect (D.19657, 0);
      if (D.19658 != 0) goto <D.19659>; else goto <D.19660>;
      <D.19659>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1599, "mono_defaults.mono_method_message_class != 0");
      <D.19660>:
      D.19392 = mono_defaults.corlib;
      D.19661 = mono_class_from_name (D.19392, "System.Reflection", "FieldInfo");
      mono_defaults.field_info_class = D.19661;
      D.19662 = mono_defaults.field_info_class;
      D.19663 = D.19662 == 0B;
      D.19664 = (long int) D.19663;
      D.19665 = __builtin_expect (D.19664, 0);
      if (D.19665 != 0) goto <D.19666>; else goto <D.19667>;
      <D.19666>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1603, "mono_defaults.field_info_class != 0");
      <D.19667>:
      D.19392 = mono_defaults.corlib;
      D.19668 = mono_class_from_name (D.19392, "System.Reflection", "MethodInfo");
      mono_defaults.method_info_class = D.19668;
      D.19669 = mono_defaults.method_info_class;
      D.19670 = D.19669 == 0B;
      D.19671 = (long int) D.19670;
      D.19672 = __builtin_expect (D.19671, 0);
      if (D.19672 != 0) goto <D.19673>; else goto <D.19674>;
      <D.19673>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1607, "mono_defaults.method_info_class != 0");
      <D.19674>:
      D.19392 = mono_defaults.corlib;
      D.19675 = mono_class_from_name (D.19392, "System.Text", "StringBuilder");
      mono_defaults.stringbuilder_class = D.19675;
      D.19676 = mono_defaults.stringbuilder_class;
      D.19677 = D.19676 == 0B;
      D.19678 = (long int) D.19677;
      D.19679 = __builtin_expect (D.19678, 0);
      if (D.19679 != 0) goto <D.19680>; else goto <D.19681>;
      <D.19680>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1611, "mono_defaults.stringbuilder_class != 0");
      <D.19681>:
      D.19392 = mono_defaults.corlib;
      D.19682 = mono_class_from_name (D.19392, "System", "Math");
      mono_defaults.math_class = D.19682;
      D.19683 = mono_defaults.math_class;
      D.19684 = D.19683 == 0B;
      D.19685 = (long int) D.19684;
      D.19686 = __builtin_expect (D.19685, 0);
      if (D.19686 != 0) goto <D.19687>; else goto <D.19688>;
      <D.19687>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1615, "mono_defaults.math_class != 0");
      <D.19688>:
      D.19392 = mono_defaults.corlib;
      D.19689 = mono_class_from_name (D.19392, "System.Diagnostics", "StackFrame");
      mono_defaults.stack_frame_class = D.19689;
      D.19690 = mono_defaults.stack_frame_class;
      D.19691 = D.19690 == 0B;
      D.19692 = (long int) D.19691;
      D.19693 = __builtin_expect (D.19692, 0);
      if (D.19693 != 0) goto <D.19694>; else goto <D.19695>;
      <D.19694>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1619, "mono_defaults.stack_frame_class != 0");
      <D.19695>:
      D.19392 = mono_defaults.corlib;
      D.19696 = mono_class_from_name (D.19392, "System.Diagnostics", "StackTrace");
      mono_defaults.stack_trace_class = D.19696;
      D.19697 = mono_defaults.stack_trace_class;
      D.19698 = D.19697 == 0B;
      D.19699 = (long int) D.19698;
      D.19700 = __builtin_expect (D.19699, 0);
      if (D.19700 != 0) goto <D.19701>; else goto <D.19702>;
      <D.19701>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1623, "mono_defaults.stack_trace_class != 0");
      <D.19702>:
      D.19392 = mono_defaults.corlib;
      D.19703 = mono_class_from_name (D.19392, "System.Runtime.InteropServices", "Marshal");
      mono_defaults.marshal_class = D.19703;
      D.19704 = mono_defaults.marshal_class;
      D.19705 = D.19704 == 0B;
      D.19706 = (long int) D.19705;
      D.19707 = __builtin_expect (D.19706, 0);
      if (D.19707 != 0) goto <D.19708>; else goto <D.19709>;
      <D.19708>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1627, "mono_defaults.marshal_class != 0");
      <D.19709>:
      D.19392 = mono_defaults.corlib;
      D.19710 = mono_class_from_name (D.19392, "System", "TypedReference");
      mono_defaults.typed_reference_class = D.19710;
      D.19711 = mono_defaults.typed_reference_class;
      D.19712 = D.19711 == 0B;
      D.19713 = (long int) D.19712;
      D.19714 = __builtin_expect (D.19713, 0);
      if (D.19714 != 0) goto <D.19715>; else goto <D.19716>;
      <D.19715>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1631, "mono_defaults.typed_reference_class != 0");
      <D.19716>:
      D.19392 = mono_defaults.corlib;
      D.19717 = mono_class_from_name (D.19392, "System", "RuntimeArgumentHandle");
      mono_defaults.argumenthandle_class = D.19717;
      D.19718 = mono_defaults.argumenthandle_class;
      D.19719 = D.19718 == 0B;
      D.19720 = (long int) D.19719;
      D.19721 = __builtin_expect (D.19720, 0);
      if (D.19721 != 0) goto <D.19722>; else goto <D.19723>;
      <D.19722>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1635, "mono_defaults.argumenthandle_class != 0");
      <D.19723>:
      D.19392 = mono_defaults.corlib;
      D.19724 = mono_class_from_name (D.19392, "System.Threading", "Monitor");
      mono_defaults.monitor_class = D.19724;
      D.19725 = mono_defaults.monitor_class;
      D.19726 = D.19725 == 0B;
      D.19727 = (long int) D.19726;
      D.19728 = __builtin_expect (D.19727, 0);
      if (D.19728 != 0) goto <D.19729>; else goto <D.19730>;
      <D.19729>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1639, "mono_defaults.monitor_class != 0");
      <D.19730>:
      D.19392 = mono_defaults.corlib;
      D.19731 = mono_class_from_name (D.19392, "System.Security", "RuntimeSecurityFrame");
      mono_defaults.runtimesecurityframe_class = D.19731;
      D.19392 = mono_defaults.corlib;
      D.19732 = mono_class_from_name (D.19392, "System.Threading", "ExecutionContext");
      mono_defaults.executioncontext_class = D.19732;
      D.19392 = mono_defaults.corlib;
      D.19733 = mono_class_from_name (D.19392, "System.Runtime.CompilerServices", "InternalsVisibleToAttribute");
      mono_defaults.internals_visible_class = D.19733;
      D.19392 = mono_defaults.corlib;
      D.19734 = mono_class_from_name (D.19392, "System.Runtime.ConstrainedExecution", "CriticalFinalizerObject");
      mono_defaults.critical_finalizer_object = D.19734;
      mono_assembly_load_friends (ass);
      D.19392 = mono_defaults.corlib;
      D.19735 = mono_class_from_name (D.19392, "System.Runtime.InteropServices", "SafeHandle");
      mono_defaults.safehandle_class = D.19735;
      D.19392 = mono_defaults.corlib;
      D.19736 = mono_class_from_name (D.19392, "System.Runtime.InteropServices", "HandleRef");
      mono_defaults.handleref_class = D.19736;
      D.19392 = mono_defaults.corlib;
      D.19737 = mono_class_from_name (D.19392, "System", "Attribute");
      mono_defaults.attribute_class = D.19737;
      D.19392 = mono_defaults.corlib;
      D.19738 = mono_class_from_name (D.19392, "System.Reflection", "CustomAttributeData");
      mono_defaults.customattribute_data_class = D.19738;
      D.19520 = mono_defaults.array_class;
      mono_class_init (D.19520);
      D.19392 = mono_defaults.corlib;
      D.19739 = mono_class_from_name (D.19392, "System", "Nullable`1");
      mono_defaults.generic_nullable_class = D.19739;
      D.19392 = mono_defaults.corlib;
      D.19740 = mono_class_from_name (D.19392, "System.Collections.Generic", "IList`1");
      mono_defaults.generic_ilist_class = D.19740;
      D.19392 = mono_defaults.corlib;
      D.19741 = mono_class_from_name (D.19392, "System.Collections.Generic", "IReadOnlyList`1");
      mono_defaults.generic_ireadonlylist_class = D.19741;
      domain.17 = domain;
      D.19742 = monoeg_g_path_get_basename (filename);
      domain.17->friendly_name = D.19742;
      domain.17 = domain;
      _mono_debug_init_corlib (domain.17);
      D.19743 = domain;
      return D.19743;
    }
  finally
    {
      status = {CLOBBER};
      runtimes = {CLOBBER};
    }
}


mono_native_tls_alloc (pthread_key_t * key, void * destructor)
{
  int D.19746;
  void (*<Tc6>) (void *) destructor.24;
  int D.19748;
  _Bool D.19749;

  destructor.24 = (void (*<Tc6>) (void *)) destructor;
  D.19748 = pthread_key_create (key, destructor.24);
  D.19749 = D.19748 == 0;
  D.19746 = (int) D.19749;
  return D.19746;
}


mono_native_tls_set_value (pthread_key_t key, void * value)
{
  int D.19751;
  int D.19752;
  _Bool D.19753;

  D.19752 = pthread_setspecific (key, value);
  D.19753 = D.19752 == 0;
  D.19751 = (int) D.19753;
  return D.19751;
}


get_runtimes_from_exe (const char * exe_file, struct MonoImage * * exe_image, const struct MonoRuntimeInfo * * runtimes)
{
  struct GSList * D.19757;
  int n.25;
  long unsigned int D.19763;
  long unsigned int D.19764;
  const struct MonoRuntimeInfo * * D.19765;
  struct GSList * iftmp.26;
  long unsigned int D.19770;
  long unsigned int D.19771;
  const struct MonoRuntimeInfo * * D.19772;
  char * D.19773;
  const struct MonoRuntimeInfo * D.19776;
  const struct MonoRuntimeInfo * * D.19777;
  const struct MonoRuntimeInfo * D.19782;
  char * D.19783;
  const struct MonoRuntimeInfo * D.19784;
  struct AppConfigInfo * app_config;
  char * version;
  const struct MonoRuntimeInfo * runtime;
  struct MonoImage * image;

  runtime = 0B;
  image = 0B;
  app_config = app_config_parse (exe_file);
  if (app_config != 0B) goto <D.19755>; else goto <D.19756>;
  <D.19755>:
  D.19757 = app_config->supported_runtimes;
  if (D.19757 != 0B) goto <D.19758>; else goto <D.19759>;
  <D.19758>:
  {
    int n;
    struct GSList * list;

    n = 0;
    list = app_config->supported_runtimes;
    goto <D.18637>;
    <D.18636>:
    version = list->data;
    runtime = get_runtime_by_version (version);
    if (runtime != 0B) goto <D.19760>; else goto <D.19761>;
    <D.19760>:
    n.25 = n;
    n = n.25 + 1;
    D.19763 = (long unsigned int) n.25;
    D.19764 = D.19763 * 8;
    D.19765 = runtimes + D.19764;
    *D.19765 = runtime;
    <D.19761>:
    if (list != 0B) goto <D.19767>; else goto <D.19768>;
    <D.19767>:
    iftmp.26 = list->next;
    goto <D.19769>;
    <D.19768>:
    iftmp.26 = 0B;
    <D.19769>:
    list = iftmp.26;
    <D.18637>:
    if (list != 0B) goto <D.18636>; else goto <D.18638>;
    <D.18638>:
    D.19770 = (long unsigned int) n;
    D.19771 = D.19770 * 8;
    D.19772 = runtimes + D.19771;
    *D.19772 = 0B;
    app_config_free (app_config);
    return;
  }
  <D.19759>:
  D.19773 = app_config->required_runtime;
  if (D.19773 != 0B) goto <D.19774>; else goto <D.19775>;
  <D.19774>:
  D.19773 = app_config->required_runtime;
  D.19776 = get_runtime_by_version (D.19773);
  *runtimes = D.19776;
  D.19777 = runtimes + 8;
  *D.19777 = 0B;
  app_config_free (app_config);
  return;
  <D.19775>:
  app_config_free (app_config);
  <D.19756>:
  image = mono_assembly_open_from_bundle (exe_file, 0B, 0);
  if (image == 0B) goto <D.19778>; else goto <D.19779>;
  <D.19778>:
  image = mono_image_open (exe_file, 0B);
  <D.19779>:
  if (image == 0B) goto <D.19780>; else goto <D.19781>;
  <D.19780>:
  D.19782 = get_runtime_by_version ("v2.0.50727");
  *runtimes = D.19782;
  D.19777 = runtimes + 8;
  *D.19777 = 0B;
  return;
  <D.19781>:
  *exe_image = image;
  D.19783 = image->version;
  D.19784 = get_runtime_by_version (D.19783);
  *runtimes = D.19784;
  D.19777 = runtimes + 8;
  *D.19777 = 0B;
}


app_config_parse (const char * exe_filename)
{
  gchar * text.27;
  char * text.28;
  long unsigned int len.29;
  int D.19792;
  struct AppConfigInfo * D.19795;
  long unsigned int len.30;
  long int len.31;
  int D.19798;
  struct AppConfigInfo * app_config;
  struct GMarkupParseContext * context;
  char * text;
  gsize len;
  const char * bundled_config;
  char * config_filename;

  try
    {
      bundled_config = mono_config_string_for_assembly_file (exe_filename);
      if (bundled_config != 0B) goto <D.19786>; else goto <D.19787>;
      <D.19786>:
      text.27 = monoeg_strdup (bundled_config);
      text = text.27;
      text.28 = text;
      len.29 = __strlen_g (text.28);
      len = len.29;
      goto <D.19791>;
      <D.19787>:
      config_filename = monoeg_g_strconcat (exe_filename, ".config", 0B);
      D.19792 = monoeg_g_file_get_contents (config_filename, &text, &len, 0B);
      if (D.19792 == 0) goto <D.19793>; else goto <D.19794>;
      <D.19793>:
      monoeg_g_free (config_filename);
      D.19795 = 0B;
      return D.19795;
      <D.19794>:
      monoeg_g_free (config_filename);
      <D.19791>:
      app_config = monoeg_malloc0 (24);
      context = monoeg_g_markup_parse_context_new (&mono_parser, 0, app_config, 0B);
      text.28 = text;
      len.30 = len;
      len.31 = (long int) len.30;
      D.19798 = monoeg_g_markup_parse_context_parse (context, text.28, len.31, 0B);
      if (D.19798 != 0) goto <D.19799>; else goto <D.19800>;
      <D.19799>:
      monoeg_g_markup_parse_context_end_parse (context, 0B);
      <D.19800>:
      monoeg_g_markup_parse_context_free (context);
      text.28 = text;
      monoeg_g_free (text.28);
      D.19795 = app_config;
      return D.19795;
    }
  finally
    {
      text = {CLOBBER};
      len = {CLOBBER};
    }
}


end_element (struct GMarkupParseContext * context, const gchar * element_name, void * user_data, struct GError * * error)
{
  int D.19803;
  int D.19806;
  int D.19807;
  int D.19809;
  int D.19812;
  int D.19813;
  struct AppConfigInfo * app_config;

  app_config = user_data;
  D.19803 = strcmp (element_name, "configuration");
  if (D.19803 == 0) goto <D.19804>; else goto <D.19805>;
  <D.19804>:
  D.19806 = app_config->configuration_count;
  D.19807 = D.19806 + -1;
  app_config->configuration_count = D.19807;
  goto <D.19808>;
  <D.19805>:
  D.19809 = strcmp (element_name, "startup");
  if (D.19809 == 0) goto <D.19810>; else goto <D.19811>;
  <D.19810>:
  D.19812 = app_config->startup_count;
  D.19813 = D.19812 + -1;
  app_config->startup_count = D.19813;
  <D.19811>:
  <D.19808>:
}


__attribute__((__gnu_inline__, nothrow, leaf, pure))
strcmp (const char * __s1, const char * __s2)
{
  int iftmp.32;
  int iftmp.33;
  int D.19822;
  char * __p1;
  char * __p2;
  int __ret;

  __p1 = __s1;
  __p2 = __s2;
  __asm__ __volatile__("   slr   0,0
0: clst  %1,%2
   jo    0b
   ipm   %0
   srl   %0,28" : "=d" __ret, "=&a" __p1, "=&a" __p2 : "1" __p1, "2" __p2 : "0", "memory", "cc");
  if (__ret != 0) goto <D.19815>; else goto <D.19816>;
  <D.19815>:
  if (__ret == 1) goto <D.19818>; else goto <D.19819>;
  <D.19818>:
  iftmp.33 = -1;
  goto <D.19820>;
  <D.19819>:
  iftmp.33 = 1;
  <D.19820>:
  iftmp.32 = iftmp.33;
  goto <D.19821>;
  <D.19816>:
  iftmp.32 = 0;
  <D.19821>:
  __ret = iftmp.32;
  D.19822 = __ret;
  return D.19822;
}


start_element (struct GMarkupParseContext * context, const gchar * element_name, const gchar * * attribute_names, const gchar * * attribute_values, void * user_data, struct GError * * error)
{
  int D.19824;
  int D.19827;
  int D.19828;
  int D.19829;
  int D.19832;
  int D.19833;
  signed long D.19834;
  long unsigned int D.19835;
  long unsigned int D.19836;
  int D.19839;
  char * D.19842;
  int D.19844;
  struct GSList * D.19847;
  struct GSList * D.19848;
  struct AppConfigInfo * app_config;

  app_config = user_data;
  D.19824 = strcmp (element_name, "configuration");
  if (D.19824 == 0) goto <D.19825>; else goto <D.19826>;
  <D.19825>:
  D.19827 = app_config->configuration_count;
  D.19828 = D.19827 + 1;
  app_config->configuration_count = D.19828;
  return;
  <D.19826>:
  D.19829 = strcmp (element_name, "startup");
  if (D.19829 == 0) goto <D.19830>; else goto <D.19831>;
  <D.19830>:
  D.19832 = app_config->startup_count;
  D.19833 = D.19832 + 1;
  app_config->startup_count = D.19833;
  return;
  <D.19831>:
  D.19834 = BIT_FIELD_REF <*app_config, 64, 128>;
  D.19835 = (long unsigned int) D.19834;
  D.19836 = D.19835;
  if (D.19836 != 4294967297) goto <D.19837>; else goto <D.19838>;
  <D.19837>:
  return;
  <D.19838>:
  D.19839 = strcmp (element_name, "requiredRuntime");
  if (D.19839 == 0) goto <D.19840>; else goto <D.19841>;
  <D.19840>:
  D.19842 = get_attribute_value (attribute_names, attribute_values, "version");
  app_config->required_runtime = D.19842;
  goto <D.19843>;
  <D.19841>:
  D.19844 = strcmp (element_name, "supportedRuntime");
  if (D.19844 == 0) goto <D.19845>; else goto <D.19846>;
  <D.19845>:
  {
    char * version;

    version = get_attribute_value (attribute_names, attribute_values, "version");
    D.19847 = app_config->supported_runtimes;
    D.19848 = monoeg_g_slist_append (D.19847, version);
    app_config->supported_runtimes = D.19848;
  }
  <D.19846>:
  <D.19843>:
}


get_attribute_value (const gchar * * attribute_names, const gchar * * attribute_values, const char * att_name)
{
  long unsigned int D.19850;
  long unsigned int D.19851;
  const gchar * * D.19852;
  const gchar * D.19853;
  int D.19854;
  char * D.19857;
  const gchar * * D.19858;
  const gchar * D.19859;
  int n;

  n = 0;
  goto <D.18576>;
  <D.18575>:
  D.19850 = (long unsigned int) n;
  D.19851 = D.19850 * 8;
  D.19852 = attribute_names + D.19851;
  D.19853 = *D.19852;
  D.19854 = strcmp (D.19853, att_name);
  if (D.19854 == 0) goto <D.19855>; else goto <D.19856>;
  <D.19855>:
  D.19850 = (long unsigned int) n;
  D.19851 = D.19850 * 8;
  D.19858 = attribute_values + D.19851;
  D.19859 = *D.19858;
  D.19857 = monoeg_strdup (D.19859);
  return D.19857;
  <D.19856>:
  n = n + 1;
  <D.18576>:
  D.19850 = (long unsigned int) n;
  D.19851 = D.19850 * 8;
  D.19852 = attribute_names + D.19851;
  D.19853 = *D.19852;
  if (D.19853 != 0B) goto <D.18575>; else goto <D.18577>;
  <D.18577>:
  D.19857 = 0B;
  return D.19857;
}


monoeg_strdup (const gchar * str)
{
  gchar * D.19863;

  if (str != 0B) goto <D.19861>; else goto <D.19862>;
  <D.19861>:
  D.19863 = __strdup (str);
  return D.19863;
  <D.19862>:
  D.19863 = 0B;
  return D.19863;
}


__attribute__((__gnu_inline__))
__strlen_g (const char * __str)
{
  size_t D.19865;
  long int __ptr.34;
  long int __str.35;
  long int D.19868;
  char * __ptr;
  char * __tmp;

  __ptr = 0B;
  __tmp = __str;
  __asm__ __volatile__("   la    0,0
0: srst  %0,%1
   jo    0b
" : "=&a" __ptr, "=&a" __tmp : "0" __ptr, "1" __tmp : "0", "memory", "cc");
  __ptr.34 = (long int) __ptr;
  __str.35 = (long int) __str;
  D.19868 = __ptr.34 - __str.35;
  D.19865 = (size_t) D.19868;
  return D.19865;
}


app_config_free (struct AppConfigInfo * app_config)
{
  struct GSList * iftmp.36;
  struct GSList * D.19874;
  char * D.19875;
  char * rt;
  struct GSList * list;

  list = app_config->supported_runtimes;
  goto <D.18611>;
  <D.18610>:
  rt = list->data;
  monoeg_g_free (rt);
  if (list != 0B) goto <D.19871>; else goto <D.19872>;
  <D.19871>:
  iftmp.36 = list->next;
  goto <D.19873>;
  <D.19872>:
  iftmp.36 = 0B;
  <D.19873>:
  list = iftmp.36;
  <D.18611>:
  if (list != 0B) goto <D.18610>; else goto <D.18612>;
  <D.18612>:
  D.19874 = app_config->supported_runtimes;
  monoeg_g_slist_free (D.19874);
  D.19875 = app_config->required_runtime;
  monoeg_g_free (D.19875);
  monoeg_g_free (app_config);
}


get_runtime_by_version (const char * version)
{
  const struct MonoRuntimeInfo * D.19878;
  const char[12] * D.19879;
  int D.19880;
  long unsigned int D.19883;
  const char * D.19886;
  char D.19887;
  int D.19888;
  int D.19891;
  int n;
  int max;
  int vlen;

  max = 6;
  if (version == 0B) goto <D.19876>; else goto <D.19877>;
  <D.19876>:
  D.19878 = 0B;
  return D.19878;
  <D.19877>:
  n = 0;
  goto <D.18620>;
  <D.18619>:
  D.19879 = &supported_runtimes[n].runtime_version;
  D.19880 = strcmp (version, D.19879);
  if (D.19880 == 0) goto <D.19881>; else goto <D.19882>;
  <D.19881>:
  D.19878 = &supported_runtimes[n];
  return D.19878;
  <D.19882>:
  n = n + 1;
  <D.18620>:
  if (n < max) goto <D.18619>; else goto <D.18621>;
  <D.18621>:
  D.19883 = __strlen_g (version);
  vlen = (int) D.19883;
  if (vlen > 3) goto <D.19884>; else goto <D.19885>;
  <D.19884>:
  D.19886 = version + 1;
  D.19887 = *D.19886;
  D.19888 = (int) D.19887;
  if (D.19888 > 51) goto <D.19889>; else goto <D.19890>;
  <D.19889>:
  n = 0;
  goto <D.18623>;
  <D.18622>:
  D.19879 = &supported_runtimes[n].runtime_version;
  D.19891 = strncmp (version, D.19879, 4);
  if (D.19891 == 0) goto <D.19892>; else goto <D.19893>;
  <D.19892>:
  D.19878 = &supported_runtimes[n];
  return D.19878;
  <D.19893>:
  n = n + 1;
  <D.18623>:
  if (n < max) goto <D.18622>; else goto <D.18624>;
  <D.18624>:
  <D.19890>:
  <D.19885>:
  D.19878 = 0B;
  return D.19878;
}


__attribute__((__artificial__, __gnu_inline__, __always_inline__))
fprintf (struct FILE * restrict __stream, const char * restrict __fmt)
{
  int D.19895;

  D.19895 = __fprintf_chk (__stream, 1, __fmt, __builtin_va_arg_pack ());
  return D.19895;
}


mono_init_from_assembly (const char * domain_name, const char * filename)
{
  struct MonoDomain * D.19897;

  D.19897 = mono_init_internal (domain_name, filename, 0B);
  return D.19897;
}


mono_init_version (const char * domain_name, const char * version)
{
  struct MonoDomain * D.19899;

  D.19899 = mono_init_internal (domain_name, 0B, version);
  return D.19899;
}


__attribute__((visibility ("hidden")))
mono_cleanup ()
{
  unsigned int appdomain_thread_id.37;

  mono_close_exe_image ();
  mono_defaults.corlib = 0B;
  mono_config_cleanup ();
  mono_loader_cleanup ();
  mono_classes_cleanup ();
  mono_assemblies_cleanup ();
  mono_images_cleanup ();
  mono_debug_cleanup ();
  mono_metadata_cleanup ();
  appdomain_thread_id.37 = appdomain_thread_id;
  mono_native_tls_free (appdomain_thread_id.37);
  DeleteCriticalSection (&appdomains_mutex);
  wapi_cleanup ();
}


mono_native_tls_free (pthread_key_t key)
{
  pthread_key_delete (key);
}


__attribute__((visibility ("hidden")))
mono_close_exe_image ()
{
  struct MonoImage * exe_image.38;

  exe_image.38 = exe_image;
  if (exe_image.38 != 0B) goto <D.19903>; else goto <D.19904>;
  <D.19903>:
  exe_image.38 = exe_image;
  mono_image_close (exe_image.38);
  <D.19904>:
}


mono_get_root_domain ()
{
  struct MonoDomain * D.19905;

  D.19905 = mono_root_domain;
  return D.19905;
}


mono_domain_get ()
{
  struct MonoDomain * D.19907;

  D.19907 = tls_appdomain;
  return D.19907;
}


__attribute__((visibility ("hidden")))
mono_domain_unset ()
{
  unsigned int appdomain_thread_id.39;

  tls_appdomain = 0B;
  appdomain_thread_id.39 = appdomain_thread_id;
  mono_native_tls_set_value (appdomain_thread_id.39, 0B);
  mono_gc_set_current_thread_appdomain (0B);
}


__attribute__((visibility ("hidden")))
mono_domain_set_internal_with_options (struct MonoDomain * domain, gboolean migrate_exception)
{
  struct MonoDomain * D.19910;
  unsigned int appdomain_thread_id.40;
  struct MonoInternalThread * D.19914;
  struct MonoInternalThread * D.19915;
  struct MonoAppContext * * D.19916;
  struct MonoAppContext * D.19917;
  struct MonoException * D.19920;
  struct MonoVTable * D.19923;
  struct MonoDomain * D.19924;
  _Bool D.19925;
  long int D.19926;
  long int D.19927;
  struct MonoException * * D.19930;
  struct MonoException * D.19931;
  _Bool D.19932;
  long int D.19933;
  long int D.19934;
  struct MonoInternalThread * thread;

  D.19910 = mono_domain_get ();
  if (D.19910 == domain) goto <D.19911>; else goto <D.19912>;
  <D.19911>:
  return;
  <D.19912>:
  tls_appdomain = domain;
  appdomain_thread_id.40 = appdomain_thread_id;
  mono_native_tls_set_value (appdomain_thread_id.40, domain);
  mono_gc_set_current_thread_appdomain (domain);
  D.19914 = mono_thread_internal_current ();
  D.19915 = mono_thread_internal_current ();
  D.19916 = &D.19915->current_appcontext;
  D.19917 = domain->default_context;
  mono_gc_wbarrier_set_field (D.19914, D.19916, D.19917);
  if (migrate_exception != 0) goto <D.19918>; else goto <D.19919>;
  <D.19918>:
  thread = mono_thread_internal_current ();
  D.19920 = thread->abort_exc;
  if (D.19920 == 0B) goto <D.19921>; else goto <D.19922>;
  <D.19921>:
  return;
  <D.19922>:
  D.19920 = thread->abort_exc;
  D.19923 = D.19920->object.vtable;
  D.19924 = D.19923->domain;
  D.19925 = D.19924 == domain;
  D.19926 = (long int) D.19925;
  D.19927 = __builtin_expect (D.19926, 0);
  if (D.19927 != 0) goto <D.19928>; else goto <D.19929>;
  <D.19928>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1830, "thread->abort_exc->object.vtable->domain != domain");
  <D.19929>:
  D.19930 = &thread->abort_exc;
  D.19931 = mono_get_exception_thread_abort ();
  mono_gc_wbarrier_set_field (thread, D.19930, D.19931);
  D.19920 = thread->abort_exc;
  D.19923 = D.19920->object.vtable;
  D.19924 = D.19923->domain;
  D.19932 = D.19924 != domain;
  D.19933 = (long int) D.19932;
  D.19934 = __builtin_expect (D.19933, 0);
  if (D.19934 != 0) goto <D.19935>; else goto <D.19936>;
  <D.19935>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1832, "thread->abort_exc->object.vtable->domain == domain");
  <D.19936>:
  <D.19919>:
}


mono_domain_set_internal (struct MonoDomain * domain)
{
  mono_domain_set_internal_with_options (domain, 1);
}


mono_domain_foreach (void (*MonoDomainFunc) (struct MonoDomain *, void *) func, void * user_data)
{
  _Bool D.19940;
  long int D.19941;
  long int D.19942;
  short unsigned int appdomain_list_size.41;
  long unsigned int D.19946;
  long unsigned int D.19947;
  struct MonoDomain * * appdomains_list.42;
  _Bool D.19951;
  long int D.19952;
  long int D.19953;
  long unsigned int D.19956;
  long unsigned int D.19957;
  struct MonoDomain * * D.19958;
  struct MonoDomain * D.19959;
  int i;
  int size;
  struct MonoDomain * * copy;

  {
    int ret;

    ret = pthread_mutex_lock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19938>; else goto <D.19939>;
    <D.19938>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.19939>:
    D.19940 = ret != 0;
    D.19941 = (long int) D.19940;
    D.19942 = __builtin_expect (D.19941, 0);
    if (D.19942 != 0) goto <D.19943>; else goto <D.19944>;
    <D.19943>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1859, "ret == 0");
    <D.19944>:
  }
  appdomain_list_size.41 = appdomain_list_size;
  size = (int) appdomain_list_size.41;
  appdomain_list_size.41 = appdomain_list_size;
  D.19946 = (long unsigned int) appdomain_list_size.41;
  D.19947 = D.19946 * 8;
  copy = mono_gc_alloc_fixed (D.19947, 0B);
  appdomains_list.42 = appdomains_list;
  appdomain_list_size.41 = appdomain_list_size;
  D.19946 = (long unsigned int) appdomain_list_size.41;
  D.19947 = D.19946 * 8;
  memcpy (copy, appdomains_list.42, D.19947);
  {
    int ret;

    ret = pthread_mutex_unlock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.19949>; else goto <D.19950>;
    <D.19949>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19950>:
    D.19951 = ret != 0;
    D.19952 = (long int) D.19951;
    D.19953 = __builtin_expect (D.19952, 0);
    if (D.19953 != 0) goto <D.19954>; else goto <D.19955>;
    <D.19954>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1863, "ret == 0");
    <D.19955>:
  }
  i = 0;
  goto <D.18365>;
  <D.18364>:
  D.19956 = (long unsigned int) i;
  D.19957 = D.19956 * 8;
  D.19958 = copy + D.19957;
  D.19959 = *D.19958;
  if (D.19959 != 0B) goto <D.19960>; else goto <D.19961>;
  <D.19960>:
  D.19956 = (long unsigned int) i;
  D.19957 = D.19956 * 8;
  D.19958 = copy + D.19957;
  D.19959 = *D.19958;
  func (D.19959, user_data);
  <D.19961>:
  i = i + 1;
  <D.18365>:
  if (i < size) goto <D.18364>; else goto <D.18366>;
  <D.18366>:
  mono_gc_free_fixed (copy);
}


mono_domain_assembly_open (struct MonoDomain * domain, const char * name)
{
  union mono_mutex_t * D.19962;
  _Bool D.19965;
  long int D.19966;
  long int D.19967;
  const char * D.19970;
  int D.19971;
  _Bool D.19976;
  long int D.19977;
  long int D.19978;
  struct MonoAssembly * D.19981;
  _Bool D.19984;
  long int D.19985;
  long int D.19986;
  struct MonoDomain * D.19989;
  struct MonoDomain * current;
  struct MonoAssembly * ass;
  struct GSList * tmp;

  {
    int ret;

    D.19962 = &domain->assemblies_lock.mutex;
    ret = pthread_mutex_lock (D.19962);
    if (ret != 0) goto <D.19963>; else goto <D.19964>;
    <D.19963>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.19964>:
    D.19965 = ret != 0;
    D.19966 = (long int) D.19965;
    D.19967 = __builtin_expect (D.19966, 0);
    if (D.19967 != 0) goto <D.19968>; else goto <D.19969>;
    <D.19968>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1887, "ret == 0");
    <D.19969>:
  }
  tmp = domain->domain_assemblies;
  goto <D.18377>;
  <D.18376>:
  ass = tmp->data;
  D.19970 = ass->aname.name;
  D.19971 = strcmp (name, D.19970);
  if (D.19971 == 0) goto <D.19972>; else goto <D.19973>;
  <D.19972>:
  {
    int ret;

    D.19962 = &domain->assemblies_lock.mutex;
    ret = pthread_mutex_unlock (D.19962);
    if (ret != 0) goto <D.19974>; else goto <D.19975>;
    <D.19974>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19975>:
    D.19976 = ret != 0;
    D.19977 = (long int) D.19976;
    D.19978 = __builtin_expect (D.19977, 0);
    if (D.19978 != 0) goto <D.19979>; else goto <D.19980>;
    <D.19979>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1891, "ret == 0");
    <D.19980>:
  }
  D.19981 = ass;
  return D.19981;
  <D.19973>:
  tmp = tmp->next;
  <D.18377>:
  if (tmp != 0B) goto <D.18376>; else goto <D.18378>;
  <D.18378>:
  {
    int ret;

    D.19962 = &domain->assemblies_lock.mutex;
    ret = pthread_mutex_unlock (D.19962);
    if (ret != 0) goto <D.19982>; else goto <D.19983>;
    <D.19982>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.19983>:
    D.19984 = ret != 0;
    D.19985 = (long int) D.19984;
    D.19986 = __builtin_expect (D.19985, 0);
    if (D.19986 != 0) goto <D.19987>; else goto <D.19988>;
    <D.19987>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1895, "ret == 0");
    <D.19988>:
  }
  D.19989 = mono_domain_get ();
  if (D.19989 != domain) goto <D.19990>; else goto <D.19991>;
  <D.19990>:
  current = mono_domain_get ();
  mono_domain_set (domain, 0);
  ass = mono_assembly_open (name, 0B);
  mono_domain_set (current, 0);
  goto <D.19992>;
  <D.19991>:
  ass = mono_assembly_open (name, 0B);
  <D.19992>:
  D.19981 = ass;
  return D.19981;
}


mono_domain_free (struct MonoDomain * domain, gboolean force)
{
  struct MonoDomain * mono_root_domain.43;
  int mono_dont_free_domains.44;
  _Bool D.20004;
  long int D.20005;
  long int D.20006;
  struct MonoDomain * * appdomains_list.45;
  int D.20010;
  long unsigned int D.20011;
  long unsigned int D.20012;
  struct MonoDomain * * D.20013;
  _Bool D.20016;
  long int D.20017;
  long int D.20018;
  struct GHashTable * D.20021;
  struct MonoGHashTable * D.20024;
  struct MonoGHashTable * D.20025;
  struct MonoTlsDataRecord * D.20026;
  struct MonoGHashTable * D.20029;
  struct MonoGHashTable * D.20032;
  struct GPtrArray * D.20035;
  void * * D.20038;
  long unsigned int D.20039;
  long unsigned int D.20040;
  void * * D.20041;
  void * D.20042;
  unsigned int D.20043;
  unsigned int i.46;
  struct MonoGHashTable * * D.20045;
  struct MonoImage * D.20048;
  long unsigned int D.20050;
  long unsigned int D.20051;
  char * D.20052;
  const char * D.20053;
  int D.20054;
  int D.20055;
  struct MonoImage * D.20062;
  long unsigned int D.20064;
  long unsigned int D.20065;
  const char * D.20066;
  int D.20067;
  int D.20068;
  struct GSList * D.20073;
  void (*<T1ad2>) (struct MonoDomain *) free_domain_hook.47;
  gchar * * D.20077;
  struct GHashTable * D.20080;
  void * * D.20081;
  struct MonoInternalHashTable * D.20084;
  struct MonoJitInfoTable * D.20085;
  struct MonoJitInfoTable * D.20088;
  int D.20089;
  _Bool D.20090;
  long int D.20091;
  long int D.20092;
  struct MonoJitInfoTable * D.20095;
  struct GSList * D.20096;
  _Bool D.20097;
  long int D.20098;
  long int D.20099;
  struct MonoCodeManager * D.20102;
  int total_domain_code_alloc.48;
  int D.20104;
  int max_domain_code_alloc.49;
  int D.20106;
  int code_size.50;
  int max_domain_code_size.51;
  int D.20109;
  struct MonoMemPool * D.20110;
  struct LockFreeMempool * D.20111;
  struct GHashTable * D.20112;
  struct GHashTable * D.20113;
  struct GHashTable * D.20116;
  struct GHashTable * D.20119;
  struct GHashTable * D.20122;
  struct CRITICAL_SECTION * D.20125;
  struct CRITICAL_SECTION * D.20126;
  struct CRITICAL_SECTION * D.20127;
  struct CRITICAL_SECTION * D.20128;
  struct MonoPerfCounters * mono_perfcounters.52;
  unsigned int D.20130;
  unsigned int D.20131;
  int code_size;
  int code_alloc;
  struct GSList * tmp;
  void * * p;

  try
    {
      mono_root_domain.43 = mono_root_domain;
      if (domain == mono_root_domain.43) goto <D.19995>; else goto <D.19996>;
      <D.19995>:
      if (force == 0) goto <D.19997>; else goto <D.19998>;
      <D.19997>:
      monoeg_g_log (0B, 16, "cant unload root domain");
      return;
      <D.19998>:
      <D.19996>:
      mono_dont_free_domains.44 = mono_dont_free_domains;
      if (mono_dont_free_domains.44 != 0) goto <D.20000>; else goto <D.20001>;
      <D.20000>:
      return;
      <D.20001>:
      mono_profiler_appdomain_event (domain, 2);
      mono_debug_domain_unload (domain);
      {
        int ret;

        ret = pthread_mutex_lock (&appdomains_mutex.mutex);
        if (ret != 0) goto <D.20002>; else goto <D.20003>;
        <D.20002>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
        <D.20003>:
        D.20004 = ret != 0;
        D.20005 = (long int) D.20004;
        D.20006 = __builtin_expect (D.20005, 0);
        if (D.20006 != 0) goto <D.20007>; else goto <D.20008>;
        <D.20007>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1938, "ret == 0");
        <D.20008>:
      }
      appdomains_list.45 = appdomains_list;
      D.20010 = domain->domain_id;
      D.20011 = (long unsigned int) D.20010;
      D.20012 = D.20011 * 8;
      D.20013 = appdomains_list.45 + D.20012;
      *D.20013 = 0B;
      {
        int ret;

        ret = pthread_mutex_unlock (&appdomains_mutex.mutex);
        if (ret != 0) goto <D.20014>; else goto <D.20015>;
        <D.20014>:
        monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
        <D.20015>:
        D.20016 = ret != 0;
        D.20017 = (long int) D.20016;
        D.20018 = __builtin_expect (D.20017, 0);
        if (D.20018 != 0) goto <D.20019>; else goto <D.20020>;
        <D.20019>:
        monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1940, "ret == 0");
        <D.20020>:
      }
      D.20021 = domain->special_static_fields;
      if (D.20021 != 0B) goto <D.20022>; else goto <D.20023>;
      <D.20022>:
      D.20021 = domain->special_static_fields;
      mono_alloc_special_static_data_free (D.20021);
      D.20021 = domain->special_static_fields;
      monoeg_g_hash_table_destroy (D.20021);
      domain->special_static_fields = 0B;
      <D.20023>:
      D.20024 = domain->ldstr_table;
      mono_g_hash_table_destroy (D.20024);
      domain->ldstr_table = 0B;
      D.20025 = domain->env;
      mono_g_hash_table_destroy (D.20025);
      domain->env = 0B;
      D.20026 = domain->tlsrec_list;
      if (D.20026 != 0B) goto <D.20027>; else goto <D.20028>;
      <D.20027>:
      mono_thread_destroy_domain_tls (domain);
      domain->tlsrec_list = 0B;
      <D.20028>:
      mono_reflection_cleanup_domain (domain);
      D.20029 = domain->type_hash;
      if (D.20029 != 0B) goto <D.20030>; else goto <D.20031>;
      <D.20030>:
      D.20029 = domain->type_hash;
      mono_g_hash_table_destroy (D.20029);
      domain->type_hash = 0B;
      <D.20031>:
      D.20032 = domain->type_init_exception_hash;
      if (D.20032 != 0B) goto <D.20033>; else goto <D.20034>;
      <D.20033>:
      D.20032 = domain->type_init_exception_hash;
      mono_g_hash_table_destroy (D.20032);
      domain->type_init_exception_hash = 0B;
      <D.20034>:
      D.20035 = domain->class_vtable_array;
      if (D.20035 != 0B) goto <D.20036>; else goto <D.20037>;
      <D.20036>:
      {
        int i;

        i = 0;
        goto <D.18396>;
        <D.18395>:
        D.20035 = domain->class_vtable_array;
        D.20038 = D.20035->pdata;
        D.20039 = (long unsigned int) i;
        D.20040 = D.20039 * 8;
        D.20041 = D.20038 + D.20040;
        D.20042 = *D.20041;
        unregister_vtable_reflection_type (D.20042);
        i = i + 1;
        <D.18396>:
        D.20035 = domain->class_vtable_array;
        D.20043 = D.20035->len;
        i.46 = (unsigned int) i;
        if (D.20043 > i.46) goto <D.18395>; else goto <D.18397>;
        <D.18397>:
      }
      <D.20037>:
      tmp = domain->domain_assemblies;
      goto <D.18400>;
      <D.18399>:
      {
        struct MonoAssembly * ass;

        ass = tmp->data;
        mono_assembly_release_gc_roots (ass);
      }
      tmp = tmp->next;
      <D.18400>:
      if (tmp != 0B) goto <D.18399>; else goto <D.18401>;
      <D.18401>:
      p = &domain->setup;
      goto <D.18403>;
      <D.18402>:
      *p = 0B;
      p = p + 8;
      <D.18403>:
      D.20045 = &domain->env;
      if (D.20045 > p) goto <D.18402>; else goto <D.18404>;
      <D.18404>:
      mono_gc_clear_domain (domain);
      tmp = domain->domain_assemblies;
      goto <D.18408>;
      <D.18407>:
      {
        struct MonoAssembly * ass;

        ass = tmp->data;
        D.20048 = ass->image;
        if (D.20048 == 0B) goto <D.20046>; else goto <D.20049>;
        <D.20049>:
        D.20048 = ass->image;
        D.20050 = BIT_FIELD_REF <*D.20048, 64, 192>;
        D.20051 = D.20050 & 268435456;
        if (D.20051 == 0) goto <D.20046>; else goto <D.20047>;
        <D.20046>:
        // predicted unlikely by continue predictor.
        goto <D.18406>;
        <D.20047>:
        D.20052 = domain->friendly_name;
        D.20053 = ass->aname.name;
        D.20054 = ass->ref_count;
        mono_trace (64, 1, "Unloading domain %s[%p], assembly %s[%p], ref_count=%d", D.20052, domain, D.20053, ass, D.20054);
        D.20055 = mono_assembly_close_except_image_pools (ass);
        if (D.20055 == 0) goto <D.20056>; else goto <D.20057>;
        <D.20056>:
        tmp->data = 0B;
        <D.20057>:
      }
      <D.18406>:
      tmp = tmp->next;
      <D.18408>:
      if (tmp != 0B) goto <D.18407>; else goto <D.18409>;
      <D.18409>:
      tmp = domain->domain_assemblies;
      goto <D.18413>;
      <D.18412>:
      {
        struct MonoAssembly * ass;

        ass = tmp->data;
        if (ass == 0B) goto <D.20058>; else goto <D.20059>;
        <D.20058>:
        // predicted unlikely by continue predictor.
        goto <D.18411>;
        <D.20059>:
        D.20062 = ass->image;
        if (D.20062 == 0B) goto <D.20060>; else goto <D.20063>;
        <D.20063>:
        D.20062 = ass->image;
        D.20064 = BIT_FIELD_REF <*D.20062, 64, 192>;
        D.20065 = D.20064 & 268435456;
        if (D.20065 != 0) goto <D.20060>; else goto <D.20061>;
        <D.20060>:
        // predicted unlikely by continue predictor.
        goto <D.18411>;
        <D.20061>:
        D.20052 = domain->friendly_name;
        D.20066 = ass->aname.name;
        D.20067 = ass->ref_count;
        mono_trace (64, 1, "Unloading domain %s[%p], assembly %s[%p], ref_count=%d", D.20052, domain, D.20066, ass, D.20067);
        D.20068 = mono_assembly_close_except_image_pools (ass);
        if (D.20068 == 0) goto <D.20069>; else goto <D.20070>;
        <D.20069>:
        tmp->data = 0B;
        <D.20070>:
      }
      <D.18411>:
      tmp = tmp->next;
      <D.18413>:
      if (tmp != 0B) goto <D.18412>; else goto <D.18414>;
      <D.18414>:
      tmp = domain->domain_assemblies;
      goto <D.18417>;
      <D.18416>:
      {
        struct MonoAssembly * ass;

        ass = tmp->data;
        if (ass != 0B) goto <D.20071>; else goto <D.20072>;
        <D.20071>:
        mono_assembly_close_finish (ass);
        <D.20072>:
      }
      tmp = tmp->next;
      <D.18417>:
      if (tmp != 0B) goto <D.18416>; else goto <D.18418>;
      <D.18418>:
      D.20073 = domain->domain_assemblies;
      monoeg_g_slist_free (D.20073);
      domain->domain_assemblies = 0B;
      mono_profiler_appdomain_event (domain, 3);
      free_domain_hook.47 = free_domain_hook;
      if (free_domain_hook.47 != 0B) goto <D.20075>; else goto <D.20076>;
      <D.20075>:
      free_domain_hook.47 = free_domain_hook;
      free_domain_hook.47 (domain);
      <D.20076>:
      D.20077 = domain->search_path;
      if (D.20077 != 0B) goto <D.20078>; else goto <D.20079>;
      <D.20078>:
      D.20077 = domain->search_path;
      monoeg_g_strfreev (D.20077);
      domain->search_path = 0B;
      <D.20079>:
      domain->create_proxy_for_type_method = 0B;
      domain->private_invoke_method = 0B;
      domain->default_context = 0B;
      domain->out_of_memory_ex = 0B;
      domain->null_reference_ex = 0B;
      domain->stack_overflow_ex = 0B;
      domain->ephemeron_tombstone = 0B;
      domain->entry_assembly = 0B;
      D.20052 = domain->friendly_name;
      monoeg_g_free (D.20052);
      domain->friendly_name = 0B;
      D.20035 = domain->class_vtable_array;
      monoeg_g_ptr_array_free (D.20035, 1);
      domain->class_vtable_array = 0B;
      D.20080 = domain->proxy_vtable_hash;
      monoeg_g_hash_table_destroy (D.20080);
      domain->proxy_vtable_hash = 0B;
      D.20081 = domain->static_data_array;
      if (D.20081 != 0B) goto <D.20082>; else goto <D.20083>;
      <D.20082>:
      D.20081 = domain->static_data_array;
      mono_gc_free_fixed (D.20081);
      domain->static_data_array = 0B;
      <D.20083>:
      D.20084 = &domain->jit_code_hash;
      mono_internal_hash_table_destroy (D.20084);
      mono_thread_hazardous_try_free_all ();
      D.20085 = domain->aot_modules;
      if (D.20085 != 0B) goto <D.20086>; else goto <D.20087>;
      <D.20086>:
      D.20088 = domain->aot_modules;
      jit_info_table_free (D.20088);
      <D.20087>:
      D.20089 = domain->num_jit_info_tables;
      D.20090 = D.20089 != 1;
      D.20091 = (long int) D.20090;
      D.20092 = __builtin_expect (D.20091, 0);
      if (D.20092 != 0) goto <D.20093>; else goto <D.20094>;
      <D.20093>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2068, "domain->num_jit_info_tables == 1");
      <D.20094>:
      D.20095 = domain->jit_info_table;
      jit_info_table_free (D.20095);
      domain->jit_info_table = 0B;
      D.20096 = domain->jit_info_free_queue;
      D.20097 = D.20096 != 0B;
      D.20098 = (long int) D.20097;
      D.20099 = __builtin_expect (D.20098, 0);
      if (D.20099 != 0) goto <D.20100>; else goto <D.20101>;
      <D.20100>:
      monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2071, "!domain->jit_info_free_queue");
      <D.20101>:
      D.20102 = domain->code_mp;
      code_alloc = mono_code_manager_size (D.20102, &code_size);
      total_domain_code_alloc.48 = total_domain_code_alloc;
      D.20104 = total_domain_code_alloc.48 + code_alloc;
      total_domain_code_alloc = D.20104;
      max_domain_code_alloc.49 = max_domain_code_alloc;
      D.20106 = MAX_EXPR <code_alloc, max_domain_code_alloc.49>;
      max_domain_code_alloc = D.20106;
      code_size.50 = code_size;
      max_domain_code_size.51 = max_domain_code_size;
      D.20109 = MAX_EXPR <code_size.50, max_domain_code_size.51>;
      max_domain_code_size = D.20109;
      D.20110 = domain->mp;
      mono_mempool_invalidate (D.20110);
      D.20102 = domain->code_mp;
      mono_code_manager_invalidate (D.20102);
      D.20111 = domain->lock_free_mp;
      lock_free_mempool_free (D.20111);
      domain->lock_free_mp = 0B;
      D.20112 = domain->finalizable_objects_hash;
      monoeg_g_hash_table_destroy (D.20112);
      domain->finalizable_objects_hash = 0B;
      D.20113 = domain->method_rgctx_hash;
      if (D.20113 != 0B) goto <D.20114>; else goto <D.20115>;
      <D.20114>:
      D.20113 = domain->method_rgctx_hash;
      monoeg_g_hash_table_destroy (D.20113);
      domain->method_rgctx_hash = 0B;
      <D.20115>:
      D.20116 = domain->generic_virtual_cases;
      if (D.20116 != 0B) goto <D.20117>; else goto <D.20118>;
      <D.20117>:
      D.20116 = domain->generic_virtual_cases;
      monoeg_g_hash_table_destroy (D.20116);
      domain->generic_virtual_cases = 0B;
      <D.20118>:
      D.20119 = domain->generic_virtual_thunks;
      if (D.20119 != 0B) goto <D.20120>; else goto <D.20121>;
      <D.20120>:
      D.20119 = domain->generic_virtual_thunks;
      monoeg_g_hash_table_destroy (D.20119);
      domain->generic_virtual_thunks = 0B;
      <D.20121>:
      D.20122 = domain->ftnptrs_hash;
      if (D.20122 != 0B) goto <D.20123>; else goto <D.20124>;
      <D.20123>:
      D.20122 = domain->ftnptrs_hash;
      monoeg_g_hash_table_destroy (D.20122);
      domain->ftnptrs_hash = 0B;
      <D.20124>:
      D.20125 = &domain->finalizable_objects_hash_lock;
      DeleteCriticalSection (D.20125);
      D.20126 = &domain->assemblies_lock;
      DeleteCriticalSection (D.20126);
      D.20127 = &domain->jit_code_hash_lock;
      DeleteCriticalSection (D.20127);
      D.20128 = &domain->lock;
      DeleteCriticalSection (D.20128);
      domain->setup = 0B;
      D.20045 = &domain->env;
      mono_gc_deregister_root (D.20045);
      mono_gc_free_fixed (domain);
      mono_perfcounters.52 = mono_perfcounters;
      D.20130 = mono_perfcounters.52->loader_appdomains;
      D.20131 = D.20130 + 4294967295;
      mono_perfcounters.52->loader_appdomains = D.20131;
      mono_root_domain.43 = mono_root_domain;
      if (domain == mono_root_domain.43) goto <D.20132>; else goto <D.20133>;
      <D.20132>:
      mono_root_domain = 0B;
      <D.20133>:
    }
  finally
    {
      code_size = {CLOBBER};
    }
}


unregister_vtable_reflection_type (struct MonoVTable * vtable)
{
  struct MonoVTable * D.20137;
  struct MonoClass * D.20138;
  struct MonoClass * D.20139;
  int D.20142;
  void * * D.20145;
  struct MonoObject * type;

  type = vtable->type;
  D.20137 = type->vtable;
  D.20138 = D.20137->klass;
  D.20139 = mono_defaults.monotype_class;
  if (D.20138 != D.20139) goto <D.20140>; else goto <D.20141>;
  <D.20140>:
  D.20142 = mono_gc_is_moving ();
  if (D.20142 != 0) goto <D.20143>; else goto <D.20144>;
  <D.20143>:
  D.20145 = &vtable->type;
  mono_gc_deregister_root (D.20145);
  <D.20144>:
  <D.20141>:
}


lock_free_mempool_free (struct LockFreeMempool * mp)
{
  int D.20146;
  long unsigned int D.20147;
  struct LockFreeMempoolChunk * chunk;
  struct LockFreeMempoolChunk * next;

  chunk = mp->chunks;
  goto <D.18215>;
  <D.18214>:
  next = chunk->prev;
  D.20146 = mono_pagesize ();
  D.20147 = (long unsigned int) D.20146;
  mono_vfree (chunk, D.20147);
  chunk = next;
  <D.18215>:
  if (chunk != 0B) goto <D.18214>; else goto <D.18216>;
  <D.18216>:
}


mono_domain_get_by_id (gint32 domainid)
{
  _Bool D.20150;
  long int D.20151;
  long int D.20152;
  short unsigned int appdomain_list_size.53;
  int D.20156;
  struct MonoDomain * * appdomains_list.54;
  long unsigned int D.20160;
  long unsigned int D.20161;
  struct MonoDomain * * D.20162;
  _Bool D.20166;
  long int D.20167;
  long int D.20168;
  struct MonoDomain * D.20171;
  struct MonoDomain * domain;

  {
    int ret;

    ret = pthread_mutex_lock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.20148>; else goto <D.20149>;
    <D.20148>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20149>:
    D.20150 = ret != 0;
    D.20151 = (long int) D.20150;
    D.20152 = __builtin_expect (D.20151, 0);
    if (D.20152 != 0) goto <D.20153>; else goto <D.20154>;
    <D.20153>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2144, "ret == 0");
    <D.20154>:
  }
  appdomain_list_size.53 = appdomain_list_size;
  D.20156 = (int) appdomain_list_size.53;
  if (D.20156 > domainid) goto <D.20157>; else goto <D.20158>;
  <D.20157>:
  appdomains_list.54 = appdomains_list;
  D.20160 = (long unsigned int) domainid;
  D.20161 = D.20160 * 8;
  D.20162 = appdomains_list.54 + D.20161;
  domain = *D.20162;
  goto <D.20163>;
  <D.20158>:
  domain = 0B;
  <D.20163>:
  {
    int ret;

    ret = pthread_mutex_unlock (&appdomains_mutex.mutex);
    if (ret != 0) goto <D.20164>; else goto <D.20165>;
    <D.20164>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20165>:
    D.20166 = ret != 0;
    D.20167 = (long int) D.20166;
    D.20168 = __builtin_expect (D.20167, 0);
    if (D.20168 != 0) goto <D.20169>; else goto <D.20170>;
    <D.20169>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2149, "ret == 0");
    <D.20170>:
  }
  D.20171 = domain;
  return D.20171;
}


mono_domain_get_id (struct MonoDomain * domain)
{
  int32_t D.20173;

  D.20173 = domain->domain_id;
  return D.20173;
}


__attribute__((visibility ("hidden")))
mono_domain_alloc (struct MonoDomain * domain, guint size)
{
  union mono_mutex_t * D.20175;
  _Bool D.20178;
  long int D.20179;
  long int D.20180;
  struct MonoPerfCounters * mono_perfcounters.55;
  unsigned int D.20184;
  unsigned int D.20185;
  struct MonoMemPool * D.20186;
  _Bool D.20189;
  long int D.20190;
  long int D.20191;
  void * D.20194;
  void * res;

  {
    int ret;

    D.20175 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.20175);
    if (ret != 0) goto <D.20176>; else goto <D.20177>;
    <D.20176>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20177>:
    D.20178 = ret != 0;
    D.20179 = (long int) D.20178;
    D.20180 = __builtin_expect (D.20179, 0);
    if (D.20180 != 0) goto <D.20181>; else goto <D.20182>;
    <D.20181>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2170, "ret == 0");
    <D.20182>:
  }
  mono_perfcounters.55 = mono_perfcounters;
  mono_perfcounters.55 = mono_perfcounters;
  D.20184 = mono_perfcounters.55->loader_bytes;
  D.20185 = D.20184 + size;
  mono_perfcounters.55->loader_bytes = D.20185;
  D.20186 = domain->mp;
  res = mono_mempool_alloc (D.20186, size);
  {
    int ret;

    D.20175 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.20175);
    if (ret != 0) goto <D.20187>; else goto <D.20188>;
    <D.20187>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20188>:
    D.20189 = ret != 0;
    D.20190 = (long int) D.20189;
    D.20191 = __builtin_expect (D.20190, 0);
    if (D.20191 != 0) goto <D.20192>; else goto <D.20193>;
    <D.20192>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2175, "ret == 0");
    <D.20193>:
  }
  D.20194 = res;
  return D.20194;
}


__attribute__((visibility ("hidden")))
mono_domain_alloc0 (struct MonoDomain * domain, guint size)
{
  union mono_mutex_t * D.20196;
  _Bool D.20199;
  long int D.20200;
  long int D.20201;
  struct MonoPerfCounters * mono_perfcounters.56;
  unsigned int D.20205;
  unsigned int D.20206;
  struct MonoMemPool * D.20207;
  _Bool D.20210;
  long int D.20211;
  long int D.20212;
  void * D.20215;
  void * res;

  {
    int ret;

    D.20196 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.20196);
    if (ret != 0) goto <D.20197>; else goto <D.20198>;
    <D.20197>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20198>:
    D.20199 = ret != 0;
    D.20200 = (long int) D.20199;
    D.20201 = __builtin_expect (D.20200, 0);
    if (D.20201 != 0) goto <D.20202>; else goto <D.20203>;
    <D.20202>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2190, "ret == 0");
    <D.20203>:
  }
  mono_perfcounters.56 = mono_perfcounters;
  mono_perfcounters.56 = mono_perfcounters;
  D.20205 = mono_perfcounters.56->loader_bytes;
  D.20206 = D.20205 + size;
  mono_perfcounters.56->loader_bytes = D.20206;
  D.20207 = domain->mp;
  res = mono_mempool_alloc0 (D.20207, size);
  {
    int ret;

    D.20196 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.20196);
    if (ret != 0) goto <D.20208>; else goto <D.20209>;
    <D.20208>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20209>:
    D.20210 = ret != 0;
    D.20211 = (long int) D.20210;
    D.20212 = __builtin_expect (D.20211, 0);
    if (D.20212 != 0) goto <D.20213>; else goto <D.20214>;
    <D.20213>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2195, "ret == 0");
    <D.20214>:
  }
  D.20215 = res;
  return D.20215;
}


__attribute__((visibility ("hidden")))
mono_domain_alloc0_lock_free (struct MonoDomain * domain, guint size)
{
  void * D.20217;
  struct LockFreeMempool * D.20218;

  D.20218 = domain->lock_free_mp;
  D.20217 = lock_free_mempool_alloc0 (D.20218, size);
  return D.20217;
}


lock_free_mempool_alloc0 (struct LockFreeMempool * mp, guint size)
{
  unsigned int D.20220;
  int size.57;
  int * D.20224;
  int size.58;
  unsigned int oldpos.59;
  unsigned int D.20227;
  int D.20228;
  unsigned int D.20229;
  int D.20232;
  unsigned int D.20233;
  unsigned int D.20234;
  _Bool D.20235;
  long int D.20236;
  long int D.20237;
  int D.20240;
  guint8 * D.20242;
  sizetype D.20243;
  void * D.20244;
  struct LockFreeMempoolChunk * chunk;
  void * res;
  int oldpos;

  D.20220 = size + 7;
  size = D.20220 & 4294967288;
  chunk = mp->current;
  if (chunk == 0B) goto <D.20221>; else goto <D.20222>;
  <D.20221>:
  size.57 = (int) size;
  chunk = lock_free_mempool_chunk_new (mp, size.57);
  mono_memory_barrier ();
  mp->current = chunk;
  <D.20222>:
  D.20224 = &chunk->pos;
  size.58 = (int) size;
  oldpos = InterlockedExchangeAdd (D.20224, size.58);
  oldpos.59 = (unsigned int) oldpos;
  D.20227 = oldpos.59 + size;
  D.20228 = chunk->size;
  D.20229 = (unsigned int) D.20228;
  if (D.20227 > D.20229) goto <D.20230>; else goto <D.20231>;
  <D.20230>:
  size.57 = (int) size;
  chunk = lock_free_mempool_chunk_new (mp, size.57);
  D.20232 = chunk->pos;
  D.20233 = (unsigned int) D.20232;
  D.20234 = D.20233 + size;
  D.20228 = chunk->size;
  D.20229 = (unsigned int) D.20228;
  D.20235 = D.20234 > D.20229;
  D.20236 = (long int) D.20235;
  D.20237 = __builtin_expect (D.20236, 0);
  if (D.20237 != 0) goto <D.20238>; else goto <D.20239>;
  <D.20238>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1085, "chunk->pos + size <= chunk->size");
  <D.20239>:
  res = chunk->mem;
  D.20232 = chunk->pos;
  D.20233 = (unsigned int) D.20232;
  D.20234 = D.20233 + size;
  D.20240 = (int) D.20234;
  chunk->pos = D.20240;
  mono_memory_barrier ();
  mp->current = chunk;
  goto <D.20241>;
  <D.20231>:
  D.20242 = chunk->mem;
  D.20243 = (sizetype) oldpos;
  res = D.20242 + D.20243;
  <D.20241>:
  D.20244 = res;
  return D.20244;
}


InterlockedExchangeAdd (volatile gint32 * val, gint32 add)
{
  gint32 D.20246;
  unsigned int add.60;
  unsigned int D.20248;

  add.60 = (unsigned int) add;
  D.20248 = __sync_fetch_and_add_4 (val, add.60);
  D.20246 = (gint32) D.20248;
  return D.20246;
}


lock_free_mempool_chunk_new (struct LockFreeMempool * mp, int len)
{
  int D.20250;
  long unsigned int D.20251;
  long unsigned int D.20252;
  long unsigned int D.20253;
  long unsigned int D.20254;
  _Bool D.20255;
  long int D.20256;
  long int D.20257;
  char * D.20260;
  long int D.20261;
  long int D.20262;
  long int D.20263;
  guint8 * D.20264;
  sizetype D.20265;
  char * D.20266;
  long int D.20267;
  guint8 * D.20268;
  long int D.20269;
  long int D.20270;
  int D.20271;
  struct LockFreeMempoolChunk * * D.20272;
  void * D.20273;
  struct LockFreeMempoolChunk * D.20275;
  struct LockFreeMempoolChunk * chunk;
  struct LockFreeMempoolChunk * prev;
  int size;

  size = mono_pagesize ();
  goto <D.18225>;
  <D.18224>:
  D.20250 = mono_pagesize ();
  size = D.20250 + size;
  <D.18225>:
  D.20251 = (long unsigned int) size;
  D.20252 = D.20251 + 18446744073709551592;
  D.20253 = (long unsigned int) len;
  if (D.20252 < D.20253) goto <D.18224>; else goto <D.18226>;
  <D.18226>:
  D.20254 = (long unsigned int) size;
  chunk = mono_valloc (0B, D.20254, 3);
  D.20255 = chunk == 0B;
  D.20256 = (long int) D.20255;
  D.20257 = __builtin_expect (D.20256, 0);
  if (D.20257 != 0) goto <D.20258>; else goto <D.20259>;
  <D.20258>:
  monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 1044, "chunk");
  <D.20259>:
  D.20260 = chunk + 24;
  D.20261 = (long int) D.20260;
  D.20262 = D.20261 + 15;
  D.20263 = D.20262 & -16;
  D.20264 = (guint8 *) D.20263;
  chunk->mem = D.20264;
  D.20265 = (sizetype) size;
  D.20266 = chunk + D.20265;
  D.20267 = (long int) D.20266;
  D.20268 = chunk->mem;
  D.20269 = (long int) D.20268;
  D.20270 = D.20267 - D.20269;
  D.20271 = (int) D.20270;
  chunk->size = D.20271;
  chunk->pos = 0;
  <D.18228>:
  prev = mp->chunks;
  D.20272 = &mp->chunks;
  D.20273 = InterlockedCompareExchangePointer (D.20272, chunk, prev);
  if (D.20273 == prev) goto <D.18227>; else goto <D.20274>;
  <D.20274>:
  goto <D.18228>;
  <D.18227>:
  chunk->prev = prev;
  D.20275 = chunk;
  return D.20275;
}


InterlockedCompareExchangePointer (void * volatile * dest, void * exch, void * comp)
{
  void * D.20277;
  long unsigned int comp.61;
  long unsigned int exch.62;
  long unsigned int D.20280;

  comp.61 = (long unsigned int) comp;
  exch.62 = (long unsigned int) exch;
  D.20280 = __sync_val_compare_and_swap_8 (dest, comp.61, exch.62);
  D.20277 = (void *) D.20280;
  return D.20277;
}


__attribute__((visibility ("hidden")))
mono_domain_code_reserve (struct MonoDomain * domain, int size)
{
  union mono_mutex_t * D.20282;
  _Bool D.20285;
  long int D.20286;
  long int D.20287;
  struct MonoCodeManager * D.20290;
  _Bool D.20293;
  long int D.20294;
  long int D.20295;
  void * D.20298;
  void * res;

  {
    int ret;

    D.20282 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.20282);
    if (ret != 0) goto <D.20283>; else goto <D.20284>;
    <D.20283>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20284>:
    D.20285 = ret != 0;
    D.20286 = (long int) D.20285;
    D.20287 = __builtin_expect (D.20286, 0);
    if (D.20287 != 0) goto <D.20288>; else goto <D.20289>;
    <D.20288>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2216, "ret == 0");
    <D.20289>:
  }
  D.20290 = domain->code_mp;
  res = mono_code_manager_reserve (D.20290, size);
  {
    int ret;

    D.20282 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.20282);
    if (ret != 0) goto <D.20291>; else goto <D.20292>;
    <D.20291>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20292>:
    D.20293 = ret != 0;
    D.20294 = (long int) D.20293;
    D.20295 = __builtin_expect (D.20294, 0);
    if (D.20295 != 0) goto <D.20296>; else goto <D.20297>;
    <D.20296>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2218, "ret == 0");
    <D.20297>:
  }
  D.20298 = res;
  return D.20298;
}


__attribute__((visibility ("hidden")))
mono_domain_code_reserve_align (struct MonoDomain * domain, int size, int alignment)
{
  union mono_mutex_t * D.20300;
  _Bool D.20303;
  long int D.20304;
  long int D.20305;
  struct MonoCodeManager * D.20308;
  _Bool D.20311;
  long int D.20312;
  long int D.20313;
  void * D.20316;
  void * res;

  {
    int ret;

    D.20300 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.20300);
    if (ret != 0) goto <D.20301>; else goto <D.20302>;
    <D.20301>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20302>:
    D.20303 = ret != 0;
    D.20304 = (long int) D.20303;
    D.20305 = __builtin_expect (D.20304, 0);
    if (D.20305 != 0) goto <D.20306>; else goto <D.20307>;
    <D.20306>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2233, "ret == 0");
    <D.20307>:
  }
  D.20308 = domain->code_mp;
  res = mono_code_manager_reserve_align (D.20308, size, alignment);
  {
    int ret;

    D.20300 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.20300);
    if (ret != 0) goto <D.20309>; else goto <D.20310>;
    <D.20309>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20310>:
    D.20311 = ret != 0;
    D.20312 = (long int) D.20311;
    D.20313 = __builtin_expect (D.20312, 0);
    if (D.20313 != 0) goto <D.20314>; else goto <D.20315>;
    <D.20314>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2235, "ret == 0");
    <D.20315>:
  }
  D.20316 = res;
  return D.20316;
}


__attribute__((visibility ("hidden")))
mono_domain_code_commit (struct MonoDomain * domain, void * data, int size, int newsize)
{
  union mono_mutex_t * D.20318;
  _Bool D.20321;
  long int D.20322;
  long int D.20323;
  struct MonoCodeManager * D.20326;
  _Bool D.20329;
  long int D.20330;
  long int D.20331;

  {
    int ret;

    D.20318 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.20318);
    if (ret != 0) goto <D.20319>; else goto <D.20320>;
    <D.20319>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20320>:
    D.20321 = ret != 0;
    D.20322 = (long int) D.20321;
    D.20323 = __builtin_expect (D.20322, 0);
    if (D.20323 != 0) goto <D.20324>; else goto <D.20325>;
    <D.20324>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2248, "ret == 0");
    <D.20325>:
  }
  D.20326 = domain->code_mp;
  mono_code_manager_commit (D.20326, data, size, newsize);
  {
    int ret;

    D.20318 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.20318);
    if (ret != 0) goto <D.20327>; else goto <D.20328>;
    <D.20327>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20328>:
    D.20329 = ret != 0;
    D.20330 = (long int) D.20329;
    D.20331 = __builtin_expect (D.20330, 0);
    if (D.20331 != 0) goto <D.20332>; else goto <D.20333>;
    <D.20332>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2250, "ret == 0");
    <D.20333>:
  }
}


__attribute__((visibility ("hidden")))
nacl_domain_get_code_dest (struct MonoDomain * domain, void * data)
{
  void * D.20334;

  D.20334 = data;
  return D.20334;
}


__attribute__((visibility ("hidden")))
nacl_domain_code_validate (struct MonoDomain * domain, guint8 * * buf_base, int buf_size, guint8 * * code_end)
{

}


__attribute__((visibility ("hidden")))
mono_domain_code_foreach (struct MonoDomain * domain, int (*MonoCodeManagerFunc) (void *, int, int, void *) func, void * user_data)
{
  union mono_mutex_t * D.20336;
  _Bool D.20339;
  long int D.20340;
  long int D.20341;
  struct MonoCodeManager * D.20344;
  _Bool D.20347;
  long int D.20348;
  long int D.20349;

  {
    int ret;

    D.20336 = &domain->lock.mutex;
    ret = pthread_mutex_lock (D.20336);
    if (ret != 0) goto <D.20337>; else goto <D.20338>;
    <D.20337>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_lock result %d", ret);
    <D.20338>:
    D.20339 = ret != 0;
    D.20340 = (long int) D.20339;
    D.20341 = __builtin_expect (D.20340, 0);
    if (D.20341 != 0) goto <D.20342>; else goto <D.20343>;
    <D.20342>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2317, "ret == 0");
    <D.20343>:
  }
  D.20344 = domain->code_mp;
  mono_code_manager_foreach (D.20344, func, user_data);
  {
    int ret;

    D.20336 = &domain->lock.mutex;
    ret = pthread_mutex_unlock (D.20336);
    if (ret != 0) goto <D.20345>; else goto <D.20346>;
    <D.20345>:
    monoeg_g_log (0B, 16, "Bad call to mono_mutex_unlock result %d", ret);
    <D.20346>:
    D.20347 = ret != 0;
    D.20348 = (long int) D.20347;
    D.20349 = __builtin_expect (D.20348, 0);
    if (D.20349 != 0) goto <D.20350>; else goto <D.20351>;
    <D.20350>:
    monoeg_assertion_message ("* Assertion at %s:%d, condition `%s\' not met\n", "domain.c", 2319, "ret == 0");
    <D.20351>:
  }
}


mono_context_set (struct MonoAppContext * new_context)
{
  struct MonoInternalThread * D.20352;
  struct MonoInternalThread * D.20353;
  struct MonoAppContext * * D.20354;

  D.20352 = mono_thread_internal_current ();
  D.20353 = mono_thread_internal_current ();
  D.20354 = &D.20353->current_appcontext;
  mono_gc_wbarrier_set_field (D.20352, D.20354, new_context);
}


mono_context_get ()
{
  struct MonoAppContext * D.20355;
  struct MonoInternalThread * D.20356;

  D.20356 = mono_thread_internal_current ();
  D.20355 = D.20356->current_appcontext;
  return D.20355;
}


mono_domain_add_class_static_data (struct MonoDomain * domain, struct MonoClass * klass, void * data, guint32 * bitmap)
{
  void * * D.20358;
  void * * D.20361;
  void * D.20362;
  long int D.20363;
  void * D.20364;
  long int D.20365;
  int D.20368;
  long unsigned int D.20369;
  long unsigned int D.20370;
  void * iftmp.63;
  int D.20372;
  long unsigned int D.20376;
  long unsigned int D.20377;
  void * * D.20378;
  long int D.20379;
  void * D.20380;
  long unsigned int D.20382;
  long unsigned int D.20383;
  void * iftmp.64;
  int D.20385;
  long int D.20389;
  void * D.20390;
  void * * D.20391;
  long int D.20392;
  void * D.20393;
  int next.65;
  long unsigned int D.20395;
  long unsigned int D.20396;
  void * * D.20397;
  int next;

  D.20358 = domain->static_data_array;
  if (D.20358 != 0B) goto <D.20359>; else goto <D.20360>;
  <D.20359>:
  {
    int size;

    D.20358 = domain->static_data_array;
    D.20361 = D.20358 + 8;
    D.20362 = *D.20361;
    D.20363 = (long int) D.20362;
    size = (int) D.20363;
    D.20358 = domain->static_data_array;
    D.20364 = *D.20358;
    D.20365 = (long int) D.20364;
    next = (int) D.20365;
    if (next >= size) goto <D.20366>; else goto <D.20367>;
    <D.20366>:
    {
      void * * new_array;

      D.20368 = size * 2;
      D.20369 = (long unsigned int) D.20368;
      D.20370 = D.20369 * 8;
      D.20372 = mono_gc_is_moving ();
      if (D.20372 != 0) goto <D.20373>; else goto <D.20374>;
      <D.20373>:
      iftmp.63 = mono_gc_make_root_descr_all_refs (0);
      goto <D.20375>;
      <D.20374>:
      iftmp.63 = 0B;
      <D.20375>:
      new_array = mono_gc_alloc_fixed (D.20370, iftmp.63);
      D.20358 = domain->static_data_array;
      D.20376 = (long unsigned int) size;
      D.20377 = D.20376 * 8;
      mono_gc_memmove_aligned (new_array, D.20358, D.20377);
      size = size * 2;
      D.20378 = new_array + 8;
      D.20379 = (long int) size;
      D.20380 = (void *) D.20379;
      *D.20378 = D.20380;
      D.20358 = domain->static_data_array;
      mono_gc_free_fixed (D.20358);
      domain->static_data_array = new_array;
    }
    <D.20367>:
  }
  goto <D.20381>;
  <D.20360>:
  {
    int size;
    void * * new_array;

    size = 32;
    D.20382 = (long unsigned int) size;
    D.20383 = D.20382 * 8;
    D.20385 = mono_gc_is_moving ();
    if (D.20385 != 0) goto <D.20386>; else goto <D.20387>;
    <D.20386>:
    iftmp.64 = mono_gc_make_root_descr_all_refs (0);
    goto <D.20388>;
    <D.20387>:
    iftmp.64 = 0B;
    <D.20388>:
    new_array = mono_gc_alloc_fixed (D.20383, iftmp.64);
    next = 2;
    D.20389 = (long int) next;
    D.20390 = (void *) D.20389;
    *new_array = D.20390;
    D.20391 = new_array + 8;
    D.20392 = (long int) size;
    D.20393 = (void *) D.20392;
    *D.20391 = D.20393;
    domain->static_data_array = new_array;
  }
  <D.20381>:
  D.20358 = domain->static_data_array;
  next.65 = next;
  next = next.65 + 1;
  D.20395 = (long unsigned int) next.65;
  D.20396 = D.20395 * 8;
  D.20397 = D.20358 + D.20396;
  *D.20397 = data;
  D.20358 = domain->static_data_array;
  D.20389 = (long int) next;
  D.20390 = (void *) D.20389;
  *D.20358 = D.20390;
}


mono_get_corlib ()
{
  struct MonoImage * D.20398;

  D.20398 = mono_defaults.corlib;
  return D.20398;
}


mono_get_object_class ()
{
  struct MonoClass * D.20400;

  D.20400 = mono_defaults.object_class;
  return D.20400;
}


mono_get_byte_class ()
{
  struct MonoClass * D.20402;

  D.20402 = mono_defaults.byte_class;
  return D.20402;
}


mono_get_void_class ()
{
  struct MonoClass * D.20404;

  D.20404 = mono_defaults.void_class;
  return D.20404;
}


mono_get_boolean_class ()
{
  struct MonoClass * D.20406;

  D.20406 = mono_defaults.boolean_class;
  return D.20406;
}


mono_get_sbyte_class ()
{
  struct MonoClass * D.20408;

  D.20408 = mono_defaults.sbyte_class;
  return D.20408;
}


mono_get_int16_class ()
{
  struct MonoClass * D.20410;

  D.20410 = mono_defaults.int16_class;
  return D.20410;
}


mono_get_uint16_class ()
{
  struct MonoClass * D.20412;

  D.20412 = mono_defaults.uint16_class;
  return D.20412;
}


mono_get_int32_class ()
{
  struct MonoClass * D.20414;

  D.20414 = mono_defaults.int32_class;
  return D.20414;
}


mono_get_uint32_class ()
{
  struct MonoClass * D.20416;

  D.20416 = mono_defaults.uint32_class;
  return D.20416;
}


mono_get_intptr_class ()
{
  struct MonoClass * D.20418;

  D.20418 = mono_defaults.int_class;
  return D.20418;
}


mono_get_uintptr_class ()
{
  struct MonoClass * D.20420;

  D.20420 = mono_defaults.uint_class;
  return D.20420;
}


mono_get_int64_class ()
{
  struct MonoClass * D.20422;

  D.20422 = mono_defaults.int64_class;
  return D.20422;
}


mono_get_uint64_class ()
{
  struct MonoClass * D.20424;

  D.20424 = mono_defaults.uint64_class;
  return D.20424;
}


mono_get_single_class ()
{
  struct MonoClass * D.20426;

  D.20426 = mono_defaults.single_class;
  return D.20426;
}


mono_get_double_class ()
{
  struct MonoClass * D.20428;

  D.20428 = mono_defaults.double_class;
  return D.20428;
}


mono_get_char_class ()
{
  struct MonoClass * D.20430;

  D.20430 = mono_defaults.char_class;
  return D.20430;
}


mono_get_string_class ()
{
  struct MonoClass * D.20432;

  D.20432 = mono_defaults.string_class;
  return D.20432;
}


mono_get_enum_class ()
{
  struct MonoClass * D.20434;

  D.20434 = mono_defaults.enum_class;
  return D.20434;
}


mono_get_array_class ()
{
  struct MonoClass * D.20436;

  D.20436 = mono_defaults.array_class;
  return D.20436;
}


mono_get_thread_class ()
{
  struct MonoClass * D.20438;

  D.20438 = mono_defaults.thread_class;
  return D.20438;
}


mono_get_exception_class ()
{
  struct MonoClass * D.20440;

  D.20440 = mono_defaults.exception_class;
  return D.20440;
}


__attribute__((visibility ("hidden")))
mono_get_runtime_info ()
{
  const struct MonoRuntimeInfo * D.20442;

  D.20442 = current_runtime;
  return D.20442;
}


__attribute__((visibility ("hidden")))
mono_debugger_check_runtime_version (const char * filename)
{
  gchar * D.20446;
  const struct MonoRuntimeInfo * current_runtime.66;
  const char[12] * D.20450;
  const char[12] * D.20451;
  const struct MonoRuntimeInfo * runtimes[7];
  const struct MonoRuntimeInfo * rinfo;
  struct MonoImage * image;

  try
    {
      get_runtimes_from_exe (filename, &image, &runtimes);
      rinfo = runtimes[0];
      if (rinfo == 0B) goto <D.20444>; else goto <D.20445>;
      <D.20444>:
      D.20446 = monoeg_g_strdup_printf ("Cannot get runtime version from assembly `%s\'", filename);
      return D.20446;
      <D.20445>:
      current_runtime.66 = current_runtime;
      if (rinfo != current_runtime.66) goto <D.20448>; else goto <D.20449>;
      <D.20448>:
      current_runtime.66 = current_runtime;
      D.20450 = &current_runtime.66->runtime_version;
      D.20451 = &rinfo->runtime_version;
      D.20446 = monoeg_g_strdup_printf ("The Mono Debugger is currently using the `%s\' runtime, but the assembly `%s\' requires version `%s\'", D.20450, filename, D.20451);
      return D.20446;
      <D.20449>:
      D.20446 = 0B;
      return D.20446;
    }
  finally
    {
      runtimes = {CLOBBER};
      image = {CLOBBER};
    }
}


__attribute__((visibility ("hidden")))
mono_framework_version ()
{
  int D.20454;
  const struct MonoRuntimeInfo * current_runtime.67;
  char D.20456;
  int D.20457;

  current_runtime.67 = current_runtime;
  D.20456 = current_runtime.67->framework_version[0];
  D.20457 = (int) D.20456;
  D.20454 = D.20457 + -48;
  return D.20454;
}


