GC_generic_or_special_malloc (word lb, int knd)
{
  void * D.5299;

  switch (knd) <default: <D.5202>, case 0: <D.5198>, case 1: <D.5199>, case 2: <D.5200>, case 3: <D.5201>>
  <D.5198>:
  D.5299 = GC_malloc_atomic (lb);
  return D.5299;
  <D.5199>:
  D.5299 = GC_malloc (lb);
  return D.5299;
  <D.5200>:
  D.5299 = GC_malloc_uncollectable (lb);
  return D.5299;
  <D.5201>:
  D.5299 = GC_malloc_atomic_uncollectable (lb);
  return D.5299;
  <D.5202>:
  D.5299 = GC_generic_malloc (lb, knd);
  return D.5299;
}


GC_realloc (void * p, size_t lb)
{
  void * D.5303;
  long unsigned int p.0;
  long unsigned int D.5305;
  long unsigned int h.1;
  long unsigned int D.5307;
  struct bottom_index * D.5308;
  long unsigned int D.5309;
  long unsigned int D.5310;
  unsigned char D.5311;
  long unsigned int D.5314;
  long unsigned int D.5315;
  int D.5316;
  int D.5319;
  long unsigned int D.5322;
  long unsigned int GC_non_gc_bytes.2;
  long unsigned int GC_non_gc_bytes.3;
  int GC_all_interior_pointers.4;
  unsigned int GC_all_interior_pointers.5;
  unsigned int D.5327;
  long unsigned int D.5330;
  long unsigned int D.5335;
  void * D.5336;
  register struct hblk * h;
  register struct hdr * hhdr;
  register word sz;
  register word orig_sz;
  int obj_kind;

  if (p == 0B) goto <D.5301>; else goto <D.5302>;
  <D.5301>:
  D.5303 = GC_malloc (lb);
  return D.5303;
  <D.5302>:
  p.0 = (long unsigned int) p;
  D.5305 = p.0 & 4294963200;
  h = (struct hblk *) D.5305;
  h.1 = (long unsigned int) h;
  D.5307 = h.1 >> 22;
  D.5308 = GC_arrays._top_index[D.5307];
  h.1 = (long unsigned int) h;
  D.5309 = h.1 >> 12;
  D.5310 = D.5309 & 1023;
  hhdr = D.5308->index[D.5310];
  sz = hhdr->hb_sz;
  D.5311 = hhdr->hb_obj_kind;
  obj_kind = (int) D.5311;
  sz = sz << 2;
  orig_sz = sz;
  if (sz > 2048) goto <D.5312>; else goto <D.5313>;
  <D.5312>:
  {
    register word descr;

    D.5314 = sz + 4095;
    sz = D.5314 & 4294963200;
    D.5315 = sz >> 2;
    hhdr->hb_sz = D.5315;
    descr = GC_obj_kinds[obj_kind].ok_descriptor;
    D.5316 = GC_obj_kinds[obj_kind].ok_relocate_descr;
    if (D.5316 != 0) goto <D.5317>; else goto <D.5318>;
    <D.5317>:
    descr = descr + sz;
    <D.5318>:
    hhdr->hb_descr = descr;
    D.5319 = obj_kind & -2;
    if (D.5319 == 2) goto <D.5320>; else goto <D.5321>;
    <D.5320>:
    D.5322 = sz - orig_sz;
    GC_non_gc_bytes.2 = GC_non_gc_bytes;
    GC_non_gc_bytes.3 = D.5322 + GC_non_gc_bytes.2;
    GC_non_gc_bytes = GC_non_gc_bytes.3;
    <D.5321>:
  }
  <D.5313>:
  GC_all_interior_pointers.4 = GC_all_interior_pointers;
  GC_all_interior_pointers.5 = (unsigned int) GC_all_interior_pointers.4;
  D.5327 = lb + GC_all_interior_pointers.5;
  if (D.5327 <= sz) goto <D.5328>; else goto <D.5329>;
  <D.5328>:
  D.5330 = sz >> 1;
  if (D.5330 <= lb) goto <D.5331>; else goto <D.5332>;
  <D.5331>:
  if (orig_sz > lb) goto <D.5333>; else goto <D.5334>;
  <D.5333>:
  D.5335 = orig_sz - lb;
  D.5336 = p + lb;
  memset (D.5336, 0, D.5335);
  <D.5334>:
  D.5303 = p;
  return D.5303;
  <D.5332>:
  {
    void * result;

    result = GC_generic_or_special_malloc (lb, obj_kind);
    if (result == 0B) goto <D.5337>; else goto <D.5338>;
    <D.5337>:
    D.5303 = 0B;
    return D.5303;
    <D.5338>:
    memcpy (result, p, lb);
    GC_free (p);
    D.5303 = result;
    return D.5303;
  }
  <D.5329>:
  {
    void * result;

    result = GC_generic_or_special_malloc (lb, obj_kind);
    if (result == 0B) goto <D.5339>; else goto <D.5340>;
    <D.5339>:
    D.5303 = 0B;
    return D.5303;
    <D.5340>:
    memcpy (result, p, sz);
    GC_free (p);
    D.5303 = result;
    return D.5303;
  }
}


memset (void * __dest, int __ch, size_t __len)
{
  int D.5344;
  int D.5349;
  void * D.5351;
  unsigned int D.5352;

  D.5344 = __builtin_constant_p (__len);
  if (D.5344 != 0) goto <D.5345>; else goto <D.5346>;
  <D.5345>:
  if (__len == 0) goto <D.5347>; else goto <D.5348>;
  <D.5347>:
  D.5349 = __builtin_constant_p (__ch);
  if (D.5349 == 0) goto <D.5342>; else goto <D.5350>;
  <D.5350>:
  if (__ch != 0) goto <D.5342>; else goto <D.5343>;
  <D.5342>:
  __warn_memset_zero_len ();
  D.5351 = __dest;
  return D.5351;
  <D.5343>:
  <D.5348>:
  <D.5346>:
  D.5352 = __builtin_object_size (__dest, 0);
  D.5351 = __builtin___memset_chk (__dest, __ch, __len, D.5352);
  return D.5351;
}


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

  D.5355 = __builtin_object_size (__dest, 0);
  D.5354 = __builtin___memcpy_chk (__dest, __src, __len, D.5355);
  return D.5354;
}


GC_generic_malloc_ignore_off_page (size_t lb, int k)
{
  int GC_all_interior_pointers.6;
  long unsigned int GC_all_interior_pointers.7;
  long unsigned int D.5359;
  char * D.5362;
  unsigned int GC_all_interior_pointers.8;
  unsigned int D.5364;
  unsigned int D.5365;
  long unsigned int D.5366;
  long unsigned int D.5367;
  int GC_have_errors.9;
  int D.5371;
  int GC_debugging_started.10;
  long unsigned int D.5379;
  word * D.5381;
  sizetype D.5382;
  sizetype D.5383;
  word * D.5384;
  sizetype D.5385;
  sizetype D.5386;
  word * D.5387;
  long unsigned int D.5388;
  long unsigned int D.5389;
  void * (*<T633>) (size_t) GC_oom_fn.11;
  register char * result;
  word lw;
  word n_blocks;
  GC_bool init;

  GC_all_interior_pointers.6 = GC_all_interior_pointers;
  GC_all_interior_pointers.7 = (long unsigned int) GC_all_interior_pointers.6;
  D.5359 = 2048 - GC_all_interior_pointers.7;
  if (D.5359 >= lb) goto <D.5360>; else goto <D.5361>;
  <D.5360>:
  D.5362 = GC_generic_malloc (lb, k);
  return D.5362;
  <D.5361>:
  GC_all_interior_pointers.6 = GC_all_interior_pointers;
  GC_all_interior_pointers.8 = (unsigned int) GC_all_interior_pointers.6;
  D.5364 = GC_all_interior_pointers.8 + lb;
  D.5365 = D.5364 + 3;
  lw = D.5365 >> 2;
  D.5366 = lw << 2;
  D.5367 = D.5366 + 4095;
  n_blocks = D.5367 >> 12;
  init = GC_obj_kinds[k].ok_init;
  GC_have_errors.9 = GC_have_errors;
  if (GC_have_errors.9 != 0) goto <D.5369>; else goto <D.5370>;
  <D.5369>:
  GC_print_all_errors ();
  <D.5370>:
  GC_notify_or_invoke_finalizers ();
  D.5371 = pthread_mutex_trylock (&GC_allocate_ml);
  if (D.5371 != 0) goto <D.5372>; else goto <D.5373>;
  <D.5372>:
  GC_lock ();
  <D.5373>:
  result = GC_alloc_large (lw, k, 1);
  if (result != 0B) goto <D.5374>; else goto <D.5375>;
  <D.5374>:
  GC_debugging_started.10 = GC_debugging_started;
  if (GC_debugging_started.10 != 0) goto <D.5377>; else goto <D.5378>;
  <D.5377>:
  D.5379 = n_blocks * 4096;
  memset (result, 0, D.5379);
  goto <D.5380>;
  <D.5378>:
  MEM[(word *)result] = 0;
  D.5381 = result + 4;
  *D.5381 = 0;
  D.5382 = lw + 1073741823;
  D.5383 = D.5382 * 4;
  D.5384 = result + D.5383;
  *D.5384 = 0;
  D.5385 = lw + 1073741822;
  D.5386 = D.5385 * 4;
  D.5387 = result + D.5386;
  *D.5387 = 0;
  <D.5380>:
  <D.5375>:
  D.5388 = GC_arrays._words_allocd;
  D.5389 = D.5388 + lw;
  GC_arrays._words_allocd = D.5389;
  pthread_mutex_unlock (&GC_allocate_ml);
  if (result == 0B) goto <D.5390>; else goto <D.5391>;
  <D.5390>:
  GC_oom_fn.11 = GC_oom_fn;
  D.5362 = GC_oom_fn.11 (lb);
  return D.5362;
  <D.5391>:
  if (init != 0) goto <D.5393>; else goto <D.5394>;
  <D.5393>:
  GC_debugging_started.10 = GC_debugging_started;
  if (GC_debugging_started.10 == 0) goto <D.5395>; else goto <D.5396>;
  <D.5395>:
  D.5379 = n_blocks * 4096;
  memset (result, 0, D.5379);
  <D.5396>:
  <D.5394>:
  D.5362 = result;
  return D.5362;
}


GC_malloc_ignore_off_page (size_t lb)
{
  void * D.5398;

  D.5398 = GC_generic_malloc_ignore_off_page (lb, 1);
  return D.5398;
}


GC_malloc_atomic_ignore_off_page (size_t lb)
{
  void * D.5400;

  D.5400 = GC_generic_malloc_ignore_off_page (lb, 0);
  return D.5400;
}


GC_incr_words_allocd (size_t n)
{
  long unsigned int D.5402;
  long unsigned int D.5403;

  D.5402 = GC_arrays._words_allocd;
  D.5403 = D.5402 + n;
  GC_arrays._words_allocd = D.5403;
}


GC_incr_mem_freed (size_t n)
{
  long unsigned int D.5404;
  long unsigned int D.5405;

  D.5404 = GC_arrays._mem_freed;
  D.5405 = D.5404 + n;
  GC_arrays._mem_freed = D.5405;
}


GC_generic_malloc_words_small_inner (word lw, int k)
{
  unsigned int k.12;
  unsigned int D.5407;
  char * * D.5408;
  long unsigned int D.5409;
  int GC_is_initialized.13;
  struct hblk * * D.5417;
  int D.5419;
  char * D.5420;
  char * D.5423;
  void * (*<T633>) (size_t) GC_oom_fn.14;
  long unsigned int D.5425;
  char * D.5426;
  long unsigned int D.5427;
  long unsigned int D.5428;
  register char * op;
  register char * * opp;
  register struct obj_kind * kind;

  k.12 = (unsigned int) k;
  D.5407 = k.12 * 20;
  kind = &GC_obj_kinds + D.5407;
  D.5408 = kind->ok_freelist;
  D.5409 = lw * 4;
  opp = D.5408 + D.5409;
  op = *opp;
  if (op == 0B) goto <D.5410>; else goto <D.5411>;
  <D.5410>:
  GC_is_initialized.13 = GC_is_initialized;
  if (GC_is_initialized.13 == 0) goto <D.5413>; else goto <D.5414>;
  <D.5413>:
  GC_init_inner ();
  <D.5414>:
  D.5417 = kind->ok_reclaim_list;
  if (D.5417 != 0B) goto <D.5415>; else goto <D.5418>;
  <D.5418>:
  D.5419 = GC_alloc_reclaim_list (kind);
  if (D.5419 != 0) goto <D.5415>; else goto <D.5416>;
  <D.5415>:
  D.5420 = GC_allocobj (lw, k);
  op = GC_clear_stack (D.5420);
  <D.5416>:
  if (op == 0B) goto <D.5421>; else goto <D.5422>;
  <D.5421>:
  pthread_mutex_unlock (&GC_allocate_ml);
  GC_oom_fn.14 = GC_oom_fn;
  D.5425 = lw << 2;
  D.5423 = GC_oom_fn.14 (D.5425);
  return D.5423;
  <D.5422>:
  <D.5411>:
  D.5426 = MEM[(char * *)op];
  *opp = D.5426;
  MEM[(char * *)op] = 0B;
  D.5427 = GC_arrays._words_allocd;
  D.5428 = D.5427 + lw;
  GC_arrays._words_allocd = D.5428;
  D.5423 = op;
  return D.5423;
}


GC_generic_malloc_words_small (size_t lw, int k)
{
  int GC_have_errors.15;
  int D.5433;
  char * D.5436;
  register char * op;

  GC_have_errors.15 = GC_have_errors;
  if (GC_have_errors.15 != 0) goto <D.5431>; else goto <D.5432>;
  <D.5431>:
  GC_print_all_errors ();
  <D.5432>:
  GC_notify_or_invoke_finalizers ();
  D.5433 = pthread_mutex_trylock (&GC_allocate_ml);
  if (D.5433 != 0) goto <D.5434>; else goto <D.5435>;
  <D.5434>:
  GC_lock ();
  <D.5435>:
  op = GC_generic_malloc_words_small_inner (lw, k);
  pthread_mutex_unlock (&GC_allocate_ml);
  D.5436 = op;
  return D.5436;
}


GC_generic_malloc_many (word lb, int k, char * * result)
{
  int GC_all_interior_pointers.16;
  long unsigned int GC_all_interior_pointers.17;
  long unsigned int D.5440;
  long unsigned int D.5445;
  long unsigned int D.5446;
  long unsigned int D.5447;
  int GC_have_errors.18;
  int D.5451;
  int GC_is_initialized.19;
  int GC_incremental.20;
  int GC_dont_gc.21;
  long unsigned int D.5463;
  long unsigned int hbp.22;
  long unsigned int D.5465;
  struct bottom_index * D.5466;
  long unsigned int D.5467;
  long unsigned int D.5468;
  struct hblk * D.5469;
  long unsigned int GC_gc_no.23;
  short unsigned int D.5471;
  long int D.5474;
  long unsigned int D.5475;
  long unsigned int D.5476;
  long unsigned int my_words_allocd_tmp.24;
  long unsigned int D.5478;
  long unsigned int GC_fl_builder_count.25;
  long unsigned int GC_fl_builder_count.26;
  int D.5481;
  long unsigned int my_words_allocd.27;
  long unsigned int GC_fl_builder_count.28;
  int D.5490;
  char * * D.5493;
  long unsigned int my_words_allocd.29;
  char * D.5499;
  long unsigned int D.5500;
  int D.5503;
  long unsigned int h.30;
  long unsigned int D.5507;
  struct bottom_index * D.5508;
  long unsigned int D.5509;
  long unsigned int D.5510;
  struct hdr * D.5511;
  long unsigned int D.5512;
  long unsigned int D.5513;
  long unsigned int D.5514;
  char * op;
  char * p;
  char * * opp;
  word lw;
  word my_words_allocd;
  struct obj_kind * ok;
  void out = <<< error >>>;

  try
    {
      my_words_allocd = 0;
      ok = &GC_obj_kinds[k];
      GC_all_interior_pointers.16 = GC_all_interior_pointers;
      GC_all_interior_pointers.17 = (long unsigned int) GC_all_interior_pointers.16;
      D.5440 = 2048 - GC_all_interior_pointers.17;
      if (D.5440 < lb) goto <D.5441>; else goto <D.5442>;
      <D.5441>:
      op = GC_generic_malloc (lb, k);
      if (op != 0B) goto <D.5443>; else goto <D.5444>;
      <D.5443>:
      MEM[(char * *)op] = 0B;
      <D.5444>:
      *result = op;
      return;
      <D.5442>:
      GC_all_interior_pointers.16 = GC_all_interior_pointers;
      GC_all_interior_pointers.17 = (long unsigned int) GC_all_interior_pointers.16;
      D.5445 = lb + GC_all_interior_pointers.17;
      D.5446 = D.5445 + 7;
      D.5447 = D.5446 >> 2;
      lw = D.5447 & 4294967294;
      GC_have_errors.18 = GC_have_errors;
      if (GC_have_errors.18 != 0) goto <D.5449>; else goto <D.5450>;
      <D.5449>:
      GC_print_all_errors ();
      <D.5450>:
      GC_notify_or_invoke_finalizers ();
      D.5451 = pthread_mutex_trylock (&GC_allocate_ml);
      if (D.5451 != 0) goto <D.5452>; else goto <D.5453>;
      <D.5452>:
      GC_lock ();
      <D.5453>:
      GC_is_initialized.19 = GC_is_initialized;
      if (GC_is_initialized.19 == 0) goto <D.5455>; else goto <D.5456>;
      <D.5455>:
      GC_init_inner ();
      <D.5456>:
      GC_incremental.20 = GC_incremental;
      if (GC_incremental.20 != 0) goto <D.5458>; else goto <D.5459>;
      <D.5458>:
      GC_dont_gc.21 = GC_dont_gc;
      if (GC_dont_gc.21 == 0) goto <D.5461>; else goto <D.5462>;
      <D.5461>:
      GC_collecting = 1;
      GC_collect_a_little_inner (1);
      GC_collecting = 0;
      <D.5462>:
      <D.5459>:
      {
        struct hblk * * rlh;
        struct hblk * hbp;
        struct hdr * hhdr;

        rlh = ok->ok_reclaim_list;
        D.5463 = lw * 4;
        rlh = rlh + D.5463;
        goto <D.5266>;
        <D.5265>:
        hbp.22 = (long unsigned int) hbp;
        D.5465 = hbp.22 >> 22;
        D.5466 = GC_arrays._top_index[D.5465];
        hbp.22 = (long unsigned int) hbp;
        D.5467 = hbp.22 >> 12;
        D.5468 = D.5467 & 1023;
        hhdr = D.5466->index[D.5468];
        D.5469 = hhdr->hb_next;
        *rlh = D.5469;
        GC_gc_no.23 = GC_gc_no;
        D.5471 = (short unsigned int) GC_gc_no.23;
        hhdr->hb_last_reclaimed = D.5471;
        {
          signed_word my_words_allocd_tmp;

          my_words_allocd_tmp = GC_words_allocd_tmp;
          if (my_words_allocd_tmp != 0) goto <D.5472>; else goto <D.5473>;
          <D.5472>:
          D.5474 = -my_words_allocd_tmp;
          D.5475 = (long unsigned int) D.5474;
          GC_atomic_add (&GC_words_allocd_tmp, D.5475);
          D.5476 = GC_arrays._words_allocd;
          my_words_allocd_tmp.24 = (long unsigned int) my_words_allocd_tmp;
          D.5478 = D.5476 + my_words_allocd_tmp.24;
          GC_arrays._words_allocd = D.5478;
          <D.5473>:
        }
        GC_acquire_mark_lock ();
        GC_fl_builder_count.25 = GC_fl_builder_count;
        GC_fl_builder_count.26 = GC_fl_builder_count.25 + 1;
        GC_fl_builder_count = GC_fl_builder_count.26;
        pthread_mutex_unlock (&GC_allocate_ml);
        GC_release_mark_lock ();
        D.5481 = ok->ok_init;
        op = GC_reclaim_generic (hbp, hhdr, lw, D.5481, 0, &my_words_allocd);
        if (op != 0B) goto <D.5482>; else goto <D.5483>;
        <D.5482>:
        *result = op;
        my_words_allocd.27 = my_words_allocd;
        GC_atomic_add (&GC_words_allocd_tmp, my_words_allocd.27);
        GC_acquire_mark_lock ();
        GC_fl_builder_count.25 = GC_fl_builder_count;
        GC_fl_builder_count.28 = GC_fl_builder_count.25 + 4294967295;
        GC_fl_builder_count = GC_fl_builder_count.28;
        GC_fl_builder_count.25 = GC_fl_builder_count;
        if (GC_fl_builder_count.25 == 0) goto <D.5486>; else goto <D.5487>;
        <D.5486>:
        GC_notify_all_builder ();
        <D.5487>:
        GC_release_mark_lock ();
        GC_clear_stack (0);
        return;
        <D.5483>:
        GC_acquire_mark_lock ();
        GC_fl_builder_count.25 = GC_fl_builder_count;
        GC_fl_builder_count.28 = GC_fl_builder_count.25 + 4294967295;
        GC_fl_builder_count = GC_fl_builder_count.28;
        GC_fl_builder_count.25 = GC_fl_builder_count;
        if (GC_fl_builder_count.25 == 0) goto <D.5488>; else goto <D.5489>;
        <D.5488>:
        GC_notify_all_builder ();
        <D.5489>:
        GC_release_mark_lock ();
        D.5490 = pthread_mutex_trylock (&GC_allocate_ml);
        if (D.5490 != 0) goto <D.5491>; else goto <D.5492>;
        <D.5491>:
        GC_lock ();
        <D.5492>:
        <D.5266>:
        hbp = *rlh;
        if (hbp != 0B) goto <D.5265>; else goto <D.5267>;
        <D.5267>:
      }
      D.5493 = GC_obj_kinds[k].ok_freelist;
      D.5463 = lw * 4;
      opp = D.5493 + D.5463;
      op = *opp;
      if (op != 0B) goto <D.5494>; else goto <D.5495>;
      <D.5494>:
      *opp = 0B;
      my_words_allocd = 0;
      p = op;
      goto <D.5270>;
      <D.5269>:
      my_words_allocd.27 = my_words_allocd;
      my_words_allocd.29 = my_words_allocd.27 + lw;
      my_words_allocd = my_words_allocd.29;
      my_words_allocd.27 = my_words_allocd;
      if (my_words_allocd.27 > 1023) goto <D.5497>; else goto <D.5498>;
      <D.5497>:
      D.5499 = MEM[(char * *)p];
      *opp = D.5499;
      MEM[(char * *)p] = 0B;
      goto <D.5268>;
      <D.5498>:
      p = MEM[(char * *)p];
      <D.5270>:
      if (p != 0B) goto <D.5269>; else goto <D.5268>;
      <D.5268>:
      D.5476 = GC_arrays._words_allocd;
      my_words_allocd.27 = my_words_allocd;
      D.5500 = D.5476 + my_words_allocd.27;
      GC_arrays._words_allocd = D.5500;
      goto out;
      <D.5495>:
      {
        struct hblk * h;

        h = GC_allochblk (lw, k, 0);
        if (h != 0B) goto <D.5501>; else goto <D.5502>;
        <D.5501>:
        D.5503 = k & -2;
        if (D.5503 == 2) goto <D.5504>; else goto <D.5505>;
        <D.5504>:
        h.30 = (long unsigned int) h;
        D.5507 = h.30 >> 22;
        D.5508 = GC_arrays._top_index[D.5507];
        h.30 = (long unsigned int) h;
        D.5509 = h.30 >> 12;
        D.5510 = D.5509 & 1023;
        D.5511 = D.5508->index[D.5510];
        GC_set_hdr_marks (D.5511);
        <D.5505>:
        D.5476 = GC_arrays._words_allocd;
        D.5512 = 1024 % lw;
        D.5513 = D.5476 - D.5512;
        D.5514 = D.5513 + 1024;
        GC_arrays._words_allocd = D.5514;
        GC_acquire_mark_lock ();
        GC_fl_builder_count.25 = GC_fl_builder_count;
        GC_fl_builder_count.26 = GC_fl_builder_count.25 + 1;
        GC_fl_builder_count = GC_fl_builder_count.26;
        pthread_mutex_unlock (&GC_allocate_ml);
        GC_release_mark_lock ();
        D.5481 = ok->ok_init;
        op = GC_build_fl (h, lw, D.5481, 0B);
        *result = op;
        GC_acquire_mark_lock ();
        GC_fl_builder_count.25 = GC_fl_builder_count;
        GC_fl_builder_count.28 = GC_fl_builder_count.25 + 4294967295;
        GC_fl_builder_count = GC_fl_builder_count.28;
        GC_fl_builder_count.25 = GC_fl_builder_count;
        if (GC_fl_builder_count.25 == 0) goto <D.5515>; else goto <D.5516>;
        <D.5515>:
        GC_notify_all_builder ();
        <D.5516>:
        GC_release_mark_lock ();
        GC_clear_stack (0);
        return;
        <D.5502>:
      }
      op = GC_generic_malloc_inner (lb, k);
      if (op != 0B) goto <D.5517>; else goto <D.5518>;
      <D.5517>:
      MEM[(char * *)op] = 0B;
      <D.5518>:
      out:
      *result = op;
      pthread_mutex_unlock (&GC_allocate_ml);
      GC_clear_stack (0);
    }
  finally
    {
      my_words_allocd = {CLOBBER};
    }
}


GC_atomic_add (volatile GC_word * addr, GC_word how_much)
{
  long unsigned int D.5522;
  int D.5523;
  GC_word D.5524;
  GC_word old;

  <D.4314>:
  old = *addr;
  D.5522 = old + how_much;
  D.5523 = GC_compare_and_exchange (addr, old, D.5522);
  if (D.5523 == 0) goto <D.4314>; else goto <D.4315>;
  <D.4315>:
  D.5524 = old;
  return D.5524;
}


GC_compare_and_exchange (volatile GC_word * addr, GC_word old, GC_word new_val)
{
  GC_bool D.5526;
  char result;

  __asm__ __volatile__("lock; cmpxchgl %2, %0; setz %1" : "=m" *addr, "=q" result : "r" new_val, "a" old, "m" *addr : "memory");
  D.5526 = (GC_bool) result;
  return D.5526;
}


GC_malloc_many (size_t lb)
{
  void * D.5528;
  char * result;

  try
    {
      GC_generic_malloc_many (lb, 1, &result);
      D.5528 = result;
      return D.5528;
    }
  finally
    {
      result = {CLOBBER};
    }
}


GC_malloc_uncollectable (size_t lb)
{
  int GC_all_interior_pointers.31;
  long unsigned int GC_all_interior_pointers.32;
  long unsigned int D.5533;
  int D.5540;
  char * D.5545;
  long unsigned int D.5546;
  long unsigned int D.5547;
  long unsigned int D.5548;
  long unsigned int GC_non_gc_bytes.33;
  long unsigned int GC_non_gc_bytes.34;
  void * D.5551;
  long unsigned int op.35;
  long unsigned int D.5556;
  long unsigned int h.36;
  long unsigned int D.5558;
  struct bottom_index * D.5559;
  long unsigned int D.5560;
  long unsigned int D.5561;
  struct hdr * D.5562;
  int D.5563;
  register char * op;
  register char * * opp;
  register word lw;

  GC_all_interior_pointers.31 = GC_all_interior_pointers;
  GC_all_interior_pointers.32 = (long unsigned int) GC_all_interior_pointers.31;
  D.5533 = 2048 - GC_all_interior_pointers.32;
  if (D.5533 >= lb) goto <D.5534>; else goto <D.5535>;
  <D.5534>:
  GC_all_interior_pointers.31 = GC_all_interior_pointers;
  if (GC_all_interior_pointers.31 != 0) goto <D.5536>; else goto <D.5537>;
  <D.5536>:
  if (lb != 0) goto <D.5538>; else goto <D.5539>;
  <D.5538>:
  lb = lb + 4294967295;
  <D.5539>:
  <D.5537>:
  lw = GC_arrays._size_map[lb];
  opp = &GC_arrays._uobjfreelist[lw];
  D.5540 = pthread_mutex_trylock (&GC_allocate_ml);
  if (D.5540 != 0) goto <D.5541>; else goto <D.5542>;
  <D.5541>:
  GC_lock ();
  <D.5542>:
  op = *opp;
  if (op != 0B) goto <D.5543>; else goto <D.5544>;
  <D.5543>:
  D.5545 = MEM[(char * *)op];
  *opp = D.5545;
  MEM[(char * *)op] = 0B;
  D.5546 = GC_arrays._words_allocd;
  D.5547 = D.5546 + lw;
  GC_arrays._words_allocd = D.5547;
  D.5548 = lw << 2;
  GC_non_gc_bytes.33 = GC_non_gc_bytes;
  GC_non_gc_bytes.34 = D.5548 + GC_non_gc_bytes.33;
  GC_non_gc_bytes = GC_non_gc_bytes.34;
  pthread_mutex_unlock (&GC_allocate_ml);
  D.5551 = op;
  return D.5551;
  <D.5544>:
  pthread_mutex_unlock (&GC_allocate_ml);
  op = GC_generic_malloc (lb, 2);
  goto <D.5552>;
  <D.5535>:
  op = GC_generic_malloc (lb, 2);
  <D.5552>:
  if (op == 0B) goto <D.5553>; else goto <D.5554>;
  <D.5553>:
  D.5551 = 0B;
  return D.5551;
  <D.5554>:
  {
    register struct hblk * h;

    op.35 = (long unsigned int) op;
    D.5556 = op.35 & 4294963200;
    h = (struct hblk *) D.5556;
    h.36 = (long unsigned int) h;
    D.5558 = h.36 >> 22;
    D.5559 = GC_arrays._top_index[D.5558];
    h.36 = (long unsigned int) h;
    D.5560 = h.36 >> 12;
    D.5561 = D.5560 & 1023;
    D.5562 = D.5559->index[D.5561];
    lw = D.5562->hb_sz;
    D.5563 = pthread_mutex_trylock (&GC_allocate_ml);
    if (D.5563 != 0) goto <D.5564>; else goto <D.5565>;
    <D.5564>:
    GC_lock ();
    <D.5565>:
    GC_set_mark_bit (op);
    D.5548 = lw << 2;
    GC_non_gc_bytes.33 = GC_non_gc_bytes;
    GC_non_gc_bytes.34 = D.5548 + GC_non_gc_bytes.33;
    GC_non_gc_bytes = GC_non_gc_bytes.34;
    pthread_mutex_unlock (&GC_allocate_ml);
    D.5551 = op;
    return D.5551;
  }
}


GC_memalign (size_t align, size_t lb)
{
  _Bool D.5567;
  _Bool D.5568;
  _Bool D.5569;
  void * D.5572;
  _Bool D.5575;
  _Bool D.5576;
  _Bool D.5577;
  void * (*<T633>) (size_t) GC_oom_fn.37;
  long unsigned int D.5583;
  unsigned int D.5584;
  long unsigned int result.38;
  int GC_all_interior_pointers.39;
  size_t new_lb;
  size_t offset;
  char * result;

  D.5567 = align <= 8;
  D.5568 = lb > align;
  D.5569 = D.5567 & D.5568;
  if (D.5569 != 0) goto <D.5570>; else goto <D.5571>;
  <D.5570>:
  D.5572 = GC_malloc (lb);
  return D.5572;
  <D.5571>:
  if (align <= 4) goto <D.5573>; else goto <D.5574>;
  <D.5573>:
  D.5572 = GC_malloc (lb);
  return D.5572;
  <D.5574>:
  D.5575 = align > 2047;
  D.5576 = lb > 2047;
  D.5577 = D.5575 | D.5576;
  if (D.5577 != 0) goto <D.5578>; else goto <D.5579>;
  <D.5578>:
  if (align > 4096) goto <D.5580>; else goto <D.5581>;
  <D.5580>:
  GC_oom_fn.37 = GC_oom_fn;
  D.5572 = GC_oom_fn.37 (2147482623);
  return D.5572;
  <D.5581>:
  D.5583 = MAX_EXPR <lb, 4096>;
  D.5572 = GC_malloc (D.5583);
  return D.5572;
  <D.5579>:
  D.5584 = lb + align;
  new_lb = D.5584 + 4294967295;
  result = GC_malloc (new_lb);
  result.38 = (long unsigned int) result;
  offset = result.38 % align;
  if (offset != 0) goto <D.5586>; else goto <D.5587>;
  <D.5586>:
  offset = align - offset;
  GC_all_interior_pointers.39 = GC_all_interior_pointers;
  if (GC_all_interior_pointers.39 == 0) goto <D.5589>; else goto <D.5590>;
  <D.5589>:
  if (offset > 2048) goto <D.5591>; else goto <D.5592>;
  <D.5591>:
  D.5572 = GC_malloc (4096);
  return D.5572;
  <D.5592>:
  GC_register_displacement (offset);
  <D.5590>:
  <D.5587>:
  result = result + offset;
  D.5572 = result;
  return D.5572;
}


GC_malloc_atomic_uncollectable (size_t lb)
{
  int GC_all_interior_pointers.40;
  long unsigned int GC_all_interior_pointers.41;
  long unsigned int D.5596;
  int D.5603;
  char * D.5608;
  long unsigned int D.5609;
  long unsigned int D.5610;
  long unsigned int D.5611;
  long unsigned int GC_non_gc_bytes.42;
  long unsigned int GC_non_gc_bytes.43;
  void * D.5614;
  long unsigned int op.44;
  long unsigned int D.5619;
  long unsigned int h.45;
  long unsigned int D.5621;
  struct bottom_index * D.5622;
  long unsigned int D.5623;
  long unsigned int D.5624;
  struct hdr * D.5625;
  int D.5626;
  register char * op;
  register char * * opp;
  register word lw;

  GC_all_interior_pointers.40 = GC_all_interior_pointers;
  GC_all_interior_pointers.41 = (long unsigned int) GC_all_interior_pointers.40;
  D.5596 = 2048 - GC_all_interior_pointers.41;
  if (D.5596 >= lb) goto <D.5597>; else goto <D.5598>;
  <D.5597>:
  GC_all_interior_pointers.40 = GC_all_interior_pointers;
  if (GC_all_interior_pointers.40 != 0) goto <D.5599>; else goto <D.5600>;
  <D.5599>:
  if (lb != 0) goto <D.5601>; else goto <D.5602>;
  <D.5601>:
  lb = lb + 4294967295;
  <D.5602>:
  <D.5600>:
  lw = GC_arrays._size_map[lb];
  opp = &GC_arrays._auobjfreelist[lw];
  D.5603 = pthread_mutex_trylock (&GC_allocate_ml);
  if (D.5603 != 0) goto <D.5604>; else goto <D.5605>;
  <D.5604>:
  GC_lock ();
  <D.5605>:
  op = *opp;
  if (op != 0B) goto <D.5606>; else goto <D.5607>;
  <D.5606>:
  D.5608 = MEM[(char * *)op];
  *opp = D.5608;
  MEM[(char * *)op] = 0B;
  D.5609 = GC_arrays._words_allocd;
  D.5610 = D.5609 + lw;
  GC_arrays._words_allocd = D.5610;
  D.5611 = lw << 2;
  GC_non_gc_bytes.42 = GC_non_gc_bytes;
  GC_non_gc_bytes.43 = D.5611 + GC_non_gc_bytes.42;
  GC_non_gc_bytes = GC_non_gc_bytes.43;
  pthread_mutex_unlock (&GC_allocate_ml);
  D.5614 = op;
  return D.5614;
  <D.5607>:
  pthread_mutex_unlock (&GC_allocate_ml);
  op = GC_generic_malloc (lb, 3);
  goto <D.5615>;
  <D.5598>:
  op = GC_generic_malloc (lb, 3);
  <D.5615>:
  if (op == 0B) goto <D.5616>; else goto <D.5617>;
  <D.5616>:
  D.5614 = 0B;
  return D.5614;
  <D.5617>:
  {
    register struct hblk * h;

    op.44 = (long unsigned int) op;
    D.5619 = op.44 & 4294963200;
    h = (struct hblk *) D.5619;
    h.45 = (long unsigned int) h;
    D.5621 = h.45 >> 22;
    D.5622 = GC_arrays._top_index[D.5621];
    h.45 = (long unsigned int) h;
    D.5623 = h.45 >> 12;
    D.5624 = D.5623 & 1023;
    D.5625 = D.5622->index[D.5624];
    lw = D.5625->hb_sz;
    D.5626 = pthread_mutex_trylock (&GC_allocate_ml);
    if (D.5626 != 0) goto <D.5627>; else goto <D.5628>;
    <D.5627>:
    GC_lock ();
    <D.5628>:
    GC_set_mark_bit (op);
    D.5611 = lw << 2;
    GC_non_gc_bytes.42 = GC_non_gc_bytes;
    GC_non_gc_bytes.43 = D.5611 + GC_non_gc_bytes.42;
    GC_non_gc_bytes = GC_non_gc_bytes.43;
    pthread_mutex_unlock (&GC_allocate_ml);
    D.5614 = op;
    return D.5614;
  }
}


