__attribute__((cold))
pfe_hif_chnl_create_cfg.isra.0 (struct pfe_hif_chnl_t * * chnl, bool_t minihif)
{
  errno_t ret;
  struct pfe_hif_chnl_t * _2;
  short unsigned int _3;
  struct pfe_hif_chnl_t * _4;
  unsigned int _5;
  long unsigned int _6;
  struct pfe_hif_chnl_t * _8;
  struct pfe_hif_chnl_t * _11;
  oal_spinlock_t * _12;
  struct pfe_hif_chnl_t * _13;
  oal_spinlock_t * _14;
  struct pfe_hif_chnl_t * _15;
  short unsigned int _16;

  <bb 7> [local count: 1073741824]:
  # DEBUG bmu s=> bmu

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _2 = *chnl_1(D);
  # DEBUG D#41 => &_2->lock
  _3 = MEM[(const oal_mutex_t *)_2 + 64B];
  # DEBUG D#4 => D#41
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_3);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _4 = *chnl_1(D);
  _5 = _4->cbus_base_va;
  _6 = _4->id;
  ret_7 = pfe_hif_chnl_cfg_init (_5, _6);
  # DEBUG ret => ret_7
  # DEBUG BEGIN_STMT
  if (ret_7 != 0)
    goto <bb 6>; [100.00%]
  else
    goto <bb 3>; [0.00%]

  <bb 3> [count: 0]:
  # DEBUG BEGIN_STMT
  _8 = *chnl_1(D);
  ret_10 = pfe_hif_chnl_init (_8, minihif_9(D));
  # DEBUG ret => ret_10
  # DEBUG BEGIN_STMT
  if (ret_10 != 0)
    goto <bb 4>; [0.00%]
  else
    goto <bb 5>; [0.00%]

  <bb 4> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _11 = *chnl_1(D);
  _12 = &_11->lock;
  oal_spinlock_destroy (_12);
  # DEBUG BEGIN_STMT
  _13 = *chnl_1(D);
  _14 = &_13->rx_lock;
  oal_spinlock_destroy (_14);
  goto <bb 6>; [0.00%]

  <bb 5> [count: 0]:
  # DEBUG BEGIN_STMT
  _15 = *chnl_1(D);
  # DEBUG D#42 => &_15->lock
  _16 = MEM[(const oal_mutex_t *)_15 + 64B];
  # DEBUG D#6 => D#42
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_16);

  <bb 6> [local count: 1073741824]:
  # ret_17 = PHI <ret_7(2), ret_10(4), 0(5)>
  # DEBUG ret => ret_17
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return ret_17;

}


oal_spinlock_unlock.isra.0 (const oal_mutex_t ISRA.31)
{
  short unsigned int _2;
  int _3;

  <bb 3> [local count: 1073741824]:
  # DEBUG D#5 s=> spinlock
  # DEBUG spinlock => D#5

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  _2 = ISRA.31_6(D);
  # DEBUG D#2 => D#5
  _3 = oal_mutex_unlock.isra.0 (_2);
  return _3;

}


oal_spinlock_lock.isra.0 (const oal_mutex_t ISRA.29)
{
  short unsigned int _2;
  int _3;

  <bb 3> [local count: 1073741824]:
  # DEBUG D#3 s=> spinlock
  # DEBUG spinlock => D#3

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  _2 = ISRA.29_6(D);
  # DEBUG D#1 => D#3
  _3 = oal_mutex_lock.isra.0 (_2);
  return _3;

}


oal_mutex_unlock.isra.0 (const oal_mutex_t ISRA.27)
{
  errno_t retval;
  short unsigned int _2;
  int _3;
  unsigned char _4;
  void (*<T4e5>) (void) _5;

  <bb 6> [local count: 1073741824]:
  # DEBUG mutex s=> mutex

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG retval => 22
  # DEBUG BEGIN_STMT
  _2 = ISRA.27_10(D);
  if (_2 <= 255)
    goto <bb 3>; [65.00%]
  else
    goto <bb 5>; [35.00%]

  <bb 3> [local count: 697932186]:
  # DEBUG BEGIN_STMT
  _3 = (int) _2;
  _4 = mutex_alloc[_3];
  if (_4 != 0)
    goto <bb 4>; [65.00%]
  else
    goto <bb 5>; [35.00%]

  <bb 4> [local count: 453655921]:
  # DEBUG BEGIN_STMT
  _5 = SchM_Exit_Eth_43_PFE_ETH_EXCLUSIVE_AREA_ID[_3];
  _5 ();
  # DEBUG BEGIN_STMT
  # DEBUG retval => 0

  <bb 5> [local count: 1073741824]:
  # retval_6 = PHI <22(2), 22(3), 0(4)>
  # DEBUG retval => retval_6
  # DEBUG BEGIN_STMT
  return retval_6;

}


oal_mutex_lock.isra.0 (const oal_mutex_t ISRA.25)
{
  errno_t retval;
  short unsigned int _2;
  int _3;
  unsigned char _4;
  void (*<T4e5>) (void) _5;

  <bb 6> [local count: 1073741824]:
  # DEBUG mutex s=> mutex

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG retval => 22
  # DEBUG BEGIN_STMT
  _2 = ISRA.25_10(D);
  if (_2 <= 255)
    goto <bb 3>; [65.00%]
  else
    goto <bb 5>; [35.00%]

  <bb 3> [local count: 697932186]:
  # DEBUG BEGIN_STMT
  _3 = (int) _2;
  _4 = mutex_alloc[_3];
  if (_4 != 0)
    goto <bb 4>; [65.00%]
  else
    goto <bb 5>; [35.00%]

  <bb 4> [local count: 453655921]:
  # DEBUG BEGIN_STMT
  _5 = SchM_Enter_Eth_43_PFE_ETH_EXCLUSIVE_AREA_ID[_3];
  _5 ();
  # DEBUG BEGIN_STMT
  # DEBUG retval => 0

  <bb 5> [local count: 1073741824]:
  # retval_6 = PHI <22(2), 22(3), 0(4)>
  # DEBUG retval => retval_6
  # DEBUG BEGIN_STMT
  return retval_6;

}


pfe_hif_chnl_get_lmem_hdr_size (const struct pfe_hif_chnl_t * chnl)
{
  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG lmem_header_size => 0
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return 0;

}


pfe_hif_chnl_set_lmem_hdr_size (struct pfe_hif_chnl_t * chnl, uint16_t lmem_header_size)
{
  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return;

}


pfe_hif_chnl_tx_fifo_is_below_wm (const struct pfe_hif_chnl_t * chnl)
{
  bool_t is_below_wm;
  struct pfe_hif_ring_t * _1;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->tx_ring;
  is_below_wm_4 = pfe_hif_ring_is_below_wm (_1);
  # DEBUG is_below_wm => is_below_wm_4
  # DEBUG BEGIN_STMT
  return is_below_wm_4;

}


pfe_hif_chnl_get_rx_cnt (const struct pfe_hif_chnl_t * chnl)
{
  uint32_t rx_cnt;
  unsigned int _1;
  long unsigned int _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->cbus_base_va;
  _2 = chnl_4(D)->id;
  rx_cnt_6 = pfe_hif_chnl_cfg_get_rx_cnt (_1, _2);
  # DEBUG rx_cnt => rx_cnt_6
  # DEBUG BEGIN_STMT
  return rx_cnt_6;

}


pfe_hif_chnl_get_tx_cnt (const struct pfe_hif_chnl_t * chnl)
{
  uint32_t tx_cnt;
  unsigned int _1;
  long unsigned int _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->cbus_base_va;
  _2 = chnl_4(D)->id;
  tx_cnt_6 = pfe_hif_chnl_cfg_get_tx_cnt (_1, _2);
  # DEBUG tx_cnt => tx_cnt_6
  # DEBUG BEGIN_STMT
  return tx_cnt_6;

}


__attribute__((cold))
pfe_hif_chnl_dump_ring (const struct pfe_hif_chnl_t * chnl, bool_t dump_rx, bool_t dump_tx)
{
  struct pfe_hif_ring_t * _1;
  struct pfe_hif_ring_t * _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  if (dump_rx_5(D) != 0)
    goto <bb 3>; [0.04%]
  else
    goto <bb 4>; [99.96%]

  <bb 3> [local count: 429497]:
  # DEBUG BEGIN_STMT
  _1 = chnl_7(D)->rx_ring;
  pfe_hif_ring_dump (_1, "RX");

  <bb 4> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  if (dump_tx_9(D) != 0)
    goto <bb 5>; [0.04%]
  else
    goto <bb 6>; [99.96%]

  <bb 5> [local count: 429497]:
  # DEBUG BEGIN_STMT
  _2 = chnl_7(D)->tx_ring;
  pfe_hif_ring_dump (_2, "TX");

  <bb 6> [local count: 1073741824]:
  return;

}


__attribute__((cold))
pfe_hif_chnl_destroy (struct pfe_hif_chnl_t * chnl)
{
  struct pfe_hif_ring_t * _1;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  if (chnl_4(D) != 0B)
    goto <bb 3>; [0.04%]
  else
    goto <bb 6>; [99.96%]

  <bb 3> [local count: 429497]:
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_irq_mask (chnl_4(D));
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_rx_irq_mask (chnl_4(D));
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_tx_irq_mask (chnl_4(D));
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_rx_disable (chnl_4(D));
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_tx_disable (chnl_4(D));
  # DEBUG BEGIN_STMT
  chnl_4(D)->rx_cbk.cbk = 0B;
  # DEBUG BEGIN_STMT
  chnl_4(D)->tx_cbk.cbk = 0B;
  # DEBUG BEGIN_STMT
  chnl_4(D)->rx_oob_cbk.cbk = 0B;
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->rx_ring;
  if (_1 != 0B)
    goto <bb 4>; [0.00%]
  else
    goto <bb 5>; [0.00%]

  <bb 4> [count: 0]:
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_destroy_inval_rx_ring (chnl_4(D));

  <bb 5> [count: 0]:
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_destroy_rings (chnl_4(D));

  <bb 6> [local count: 1073312328]:
  return;

}


__attribute__((cold))
pfe_hif_chnl_destroy_inval_rx_ring (struct pfe_hif_chnl_t * chnl)
{
  void * buf_pa;
  struct pfe_hif_ring_t * _1;
  int _2;
  struct pfe_hif_ring_t * _3;

  <bb 2> [local count: 118111600]:
  # DEBUG BEGIN_STMT
  buf_pa = 0B;
  # DEBUG BEGIN_STMT

  <bb 3> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_7(D)->rx_ring;
  _2 = pfe_hif_ring_drain_buf (_1, &buf_pa);
  if (_2 == 0)
    goto <bb 5>; [89.00%]
  else
    goto <bb 4>; [11.00%]

  <bb 5> [local count: 955630223]:
  goto <bb 3>; [100.00%]

  <bb 4> [local count: 118111601]:
  # DEBUG BEGIN_STMT
  _3 = chnl_7(D)->rx_ring;
  pfe_hif_ring_invalidate (_3);
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_flush_rx_bd_fifo (chnl_7(D));
  # DEBUG BEGIN_STMT
  buf_pa ={v} {CLOBBER};
  return;

}


__attribute__((cold))
pfe_hif_chnl_destroy_rings (struct pfe_hif_chnl_t * chnl)
{
  struct pfe_hif_ring_t * _1;
  struct pfe_hif_ring_t * _2;
  unsigned int _3;
  long unsigned int _4;
  struct pfe_hif_ring_t * _5;
  short unsigned int _18;

  <bb 2> [count: 0]:
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_rx_disable (chnl_9(D));
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_tx_disable (chnl_9(D));
  # DEBUG BEGIN_STMT
  _1 = chnl_9(D)->rx_ring;
  if (_1 != 0B)
    goto <bb 3>; [0.00%]
  else
    goto <bb 4>; [0.00%]

  <bb 3> [count: 0]:
  # DEBUG BEGIN_STMT
  pfe_hif_ring_destroy (_1);
  # DEBUG BEGIN_STMT
  chnl_9(D)->rx_ring = 0B;

  <bb 4> [count: 0]:
  # DEBUG BEGIN_STMT
  _2 = chnl_9(D)->tx_ring;
  if (_2 != 0B)
    goto <bb 5>; [0.00%]
  else
    goto <bb 6>; [0.00%]

  <bb 5> [count: 0]:
  # DEBUG BEGIN_STMT
  _3 = chnl_9(D)->cbus_base_va;
  _4 = chnl_9(D)->id;
  pfe_hif_chnl_cfg_is_tx_bdp_fifo_empty (_3, _4);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _5 = chnl_9(D)->tx_ring;
  pfe_hif_ring_destroy (_5);
  # DEBUG BEGIN_STMT
  chnl_9(D)->tx_ring = 0B;

  <bb 6> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG D#22 => &chnl_9(D)->lock
  _18 = MEM[(const oal_mutex_t *)chnl_9(D) + 64B];
  # DEBUG D#4 => D#22
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_18);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_destroy_chnl (chnl_9(D));
  return;

}


__attribute__((cold))
pfe_hif_chnl_destroy_chnl (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  oal_spinlock_t * _3;
  oal_spinlock_t * _4;
  short unsigned int _8;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  _1 = chnl_6(D)->cbus_base_va;
  _2 = chnl_6(D)->id;
  pfe_hif_chnl_cfg_fini (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#7 => &chnl_6(D)->lock
  _8 = MEM[(const oal_mutex_t *)chnl_6(D) + 64B];
  # DEBUG D#6 => D#7
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_8);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _3 = &chnl_6(D)->lock;
  # DEBUG spinlock => _3
  # DEBUG INLINE_ENTRY oal_spinlock_destroy
  # DEBUG BEGIN_STMT
  # DEBUG mutex => _3
  # DEBUG INLINE_ENTRY oal_mutex_destroy
  # DEBUG BEGIN_STMT
  oal_mutex_destroy_internal (_3);
  # DEBUG mutex => NULL
  # DEBUG spinlock => NULL
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _4 = &chnl_6(D)->rx_lock;
  # DEBUG spinlock => _4
  # DEBUG INLINE_ENTRY oal_spinlock_destroy
  # DEBUG BEGIN_STMT
  # DEBUG mutex => _4
  # DEBUG INLINE_ENTRY oal_mutex_destroy
  # DEBUG BEGIN_STMT
  oal_mutex_destroy_internal (_4);
  # DEBUG mutex => NULL
  # DEBUG spinlock => NULL
  # DEBUG BEGIN_STMT
  return;

}


__attribute__((cold))
pfe_hif_chnl_flush_rx_bd_fifo (struct pfe_hif_chnl_t * chnl)
{
  errno_t ret;
  uint32_t ii;
  void * tx_buf_va;
  long unsigned int _1;
  unsigned char _2;
  int _3;
  int _4;
  long unsigned int _5;
  long unsigned int _6;
  long unsigned int _7;
  long unsigned int _8;
  long unsigned int _9;
  long unsigned int _10;
  long unsigned int _11;
  long unsigned int _12;
  long unsigned int _13;
  long unsigned int _14;
  struct pfe_hif_ring_t * _15;
  long unsigned int _17;

  <bb 2> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  tx_buf_va = &dummy_tx_buf;
  # DEBUG BEGIN_STMT
  # DEBUG tx_hdr => &dummy_tx_buf
  # DEBUG BEGIN_STMT
  _1 = chnl_19(D)->id;
  _2 = (unsigned char) _1;
  _17 = _1 & 255;
  _3 = (int) _17;
  _4 = _3 + 6;
  _5 = 1 << _4;
  _6 = _5 >> 24;
  _7 = _5 >> 8;
  _8 = _7 & 65280;
  _9 = _6 | _8;
  _10 = _5 << 8;
  _11 = _10 & 16711680;
  _12 = _9 | _11;
  _13 = _5 << 24;
  _14 = _12 | _13;
  MEM[(struct pfe_ct_hif_tx_hdr_t *)&dummy_tx_buf].e_phy_ifs = _14;
  # DEBUG BEGIN_STMT
  MEM[(struct pfe_ct_hif_tx_hdr_t *)&dummy_tx_buf].flags = 192;
  # DEBUG BEGIN_STMT
  MEM[(struct pfe_ct_hif_tx_hdr_t *)&dummy_tx_buf].chid = _2;
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_rx_enable (chnl_19(D));
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_tx_enable (chnl_19(D));
  # DEBUG BEGIN_STMT
  _15 = chnl_19(D)->rx_ring;
  ii_25 = pfe_hif_ring_get_len (_15);
  # DEBUG ii => ii_25
  # DEBUG BEGIN_STMT
  ret_27 = pfe_hif_chnl_flush_rx_bd_fifo_send_pkt (chnl_19(D), ii_25, &tx_buf_va);
  # DEBUG ret => ret_27
  # DEBUG BEGIN_STMT
  tx_buf_va ={v} {CLOBBER};
  return ret_27;

}


__attribute__((cold))
pfe_hif_chnl_flush_rx_bd_fifo_send_pkt (struct pfe_hif_chnl_t * chnl, uint32_t ii, void * * tx_buf_va)
{
  uint32_t count;
  const void * tx_buf_pa;
  bool_t lifm;
  uint32_t len;
  void * buf_pa;
  errno_t ret;
  struct pfe_hif_ring_t * _1;
  long unsigned int _2;
  void * _3;
  int _4;
  struct pfe_hif_ring_t * _5;
  int _6;
  struct pfe_hif_ring_t * _7;
  int _8;
  unsigned int _9;
  long unsigned int _10;
  unsigned char _11;

  <bb 2> [local count: 6921463]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  # DEBUG rx_buf_va => 0B
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG count => ii_20(D)
  # DEBUG BEGIN_STMT
  tx_buf_pa_23 = *tx_buf_va_22(D);
  # DEBUG tx_buf_pa => tx_buf_pa_23
  # DEBUG BEGIN_STMT
  # DEBUG rx_buf_va => &dummy_rx_buf
  # DEBUG BEGIN_STMT
  # DEBUG rx_buf_pa => &dummy_rx_buf
  # DEBUG BEGIN_STMT
  goto <bb 12>; [100.00%]

  <bb 3> [local count: 118111599]:
  # DEBUG BEGIN_STMT
  _1 = chnl_24(D)->rx_ring;
  _2 = pfe_hif_ring_get_fill_level (_1);
  if (_2 == 0)
    goto <bb 4>; [33.00%]
  else
    goto <bb 5>; [67.00%]

  <bb 4> [local count: 38976828]:
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_supply_rx_buf (chnl_24(D), &dummy_rx_buf, 1544);

  <bb 5> [local count: 118111599]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _3 = *tx_buf_va_22(D);
  pfe_hif_chnl_tx (chnl_24(D), tx_buf_pa_23, _3, 80, 1);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  oal_time_usleep (500);
  # DEBUG BEGIN_STMT

  <bb 6> [local count: 1073741819]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _4 = pfe_hif_chnl_get_tx_conf (chnl_24(D));
  if (_4 == 0)
    goto <bb 18>; [89.00%]
  else
    goto <bb 15>; [11.00%]

  <bb 18> [local count: 955630218]:
  goto <bb 6>; [100.00%]

  <bb 15> [local count: 118111600]:

  <bb 7> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _5 = chnl_24(D)->rx_ring;
  _6 = pfe_hif_ring_dequeue_buf (_5, &buf_pa, &len, &lifm);
  if (_6 == 0)
    goto <bb 17>; [89.00%]
  else
    goto <bb 8>; [11.00%]

  <bb 17> [local count: 955630224]:
  goto <bb 7>; [100.00%]

  <bb 8> [local count: 118111601]:
  # DEBUG BEGIN_STMT
  if (count_13 != 0)
    goto <bb 9>; [99.96%]
  else
    goto <bb 14>; [0.04%]

  <bb 9> [local count: 118064356]:
  # DEBUG BEGIN_STMT
  count_33 = count_13 + 4294967295;
  # DEBUG count => count_33
  goto <bb 12>; [100.00%]

  <bb 14> [local count: 47245]:

  <bb 10> [local count: 429497]:
  # DEBUG ret => NULL
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _7 = chnl_24(D)->rx_ring;
  _8 = pfe_hif_ring_drain_buf (_7, &buf_pa);
  if (_8 == 0)
    goto <bb 16>; [89.00%]
  else
    goto <bb 11>; [11.00%]

  <bb 16> [local count: 382252]:
  goto <bb 10>; [100.00%]

  <bb 11> [local count: 47245]:
  # DEBUG BEGIN_STMT
  *tx_buf_va_22(D) = 0B;
  # DEBUG BEGIN_STMT
  # DEBUG rx_buf_va => 0B
  # DEBUG BEGIN_STMT
  goto <bb 13>; [100.00%]

  <bb 12> [local count: 124985820]:
  # count_13 = PHI <ii_20(D)(2), count_33(9)>
  # DEBUG count => count_13
  # DEBUG BEGIN_STMT
  _9 = chnl_24(D)->cbus_base_va;
  _10 = chnl_24(D)->id;
  _11 = pfe_hif_chnl_cfg_is_rx_bdp_fifo_empty (_9, _10);
  if (_11 == 0)
    goto <bb 3>; [94.50%]
  else
    goto <bb 13>; [5.50%]

  <bb 13> [local count: 6921465]:
  # ret_12 = PHI <110(11), 0(12)>
  # DEBUG ret => ret_12
  # DEBUG BEGIN_STMT
  buf_pa ={v} {CLOBBER};
  len ={v} {CLOBBER};
  lifm ={v} {CLOBBER};
  return ret_12;

}


__attribute__((hot))
pfe_hif_chnl_is_tx_dma_active (const struct pfe_hif_chnl_t * chnl)
{
  bool_t is_tx_active;
  unsigned int _1;
  long unsigned int _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->cbus_base_va;
  _2 = chnl_4(D)->id;
  is_tx_active_6 = pfe_hif_chnl_cfg_is_tx_dma_active (_1, _2);
  # DEBUG is_tx_active => is_tx_active_6
  # DEBUG BEGIN_STMT
  return is_tx_active_6;

}


__attribute__((hot))
pfe_hif_chnl_is_rx_dma_active (const struct pfe_hif_chnl_t * chnl)
{
  bool_t is_rx_active;
  unsigned int _1;
  long unsigned int _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->cbus_base_va;
  _2 = chnl_4(D)->id;
  is_rx_active_6 = pfe_hif_chnl_cfg_is_rx_dma_active (_1, _2);
  # DEBUG is_rx_active => is_rx_active_6
  # DEBUG BEGIN_STMT
  return is_rx_active_6;

}


__attribute__((cold))
pfe_hif_chnl_init (struct pfe_hif_chnl_t * chnl, bool_t minihif)
{
  struct pfe_hif_ring_t * rx_ring;
  struct pfe_hif_ring_t * tx_ring;
  errno_t ret;
  long unsigned int _1;
  struct pfe_hif_ring_t * _2;
  struct pfe_hif_ring_t * _3;
  const struct Eth_43_PFE_ConfigType * Eth_43_PFE_InternalCfgPtr.17_4;
  const struct Eth_43_PFE_HifCfgType * _5;
  short unsigned int _6;
  short unsigned int _7;
  unsigned int memory.21_21;
  unsigned int meta_memory.22_22;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  rx_ring = 0B;
  # DEBUG BEGIN_STMT
  if (minihif_12(D) == 0)
    goto <bb 3>; [0.00%]
  else
    goto <bb 5>; [100.00%]

  <bb 3> [count: 0]:
  # DEBUG BEGIN_STMT
  _1 = chnl_13(D)->id;
  _2 = &tx_rings_memory[_1];
  tx_ring = _2;
  # DEBUG BEGIN_STMT
  _3 = &rx_rings_memory[_1];
  rx_ring = _3;
  # DEBUG BEGIN_STMT
  ret_17 = pfe_hif_chnl_init_tx_rx_ring (chnl_13(D), &tx_ring, &rx_ring);
  # DEBUG ret => ret_17
  # DEBUG BEGIN_STMT
  if (ret_17 == 0)
    goto <bb 4>; [0.00%]
  else
    goto <bb 5>; [0.00%]

  <bb 4> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG D#40 => &chnl_13(D)->rx_pool
  Eth_43_PFE_InternalCfgPtr.17_4 = Eth_43_PFE_InternalCfgPtr;
  _5 = Eth_43_PFE_InternalCfgPtr.17_4->pHif;
  _6 = _5->u16RxBufSize;
  _7 = _5->u16RxBufNum;
  # DEBUG pool => D#40
  # DEBUG memory => &rx_buf_mem[0]
  # DEBUG meta_memory => &rx_meta_buf_mem[0]
  # DEBUG buf_size => _6
  # DEBUG buf_num => _7
  # DEBUG INLINE_ENTRY rx_pool_init
  # DEBUG BEGIN_STMT
  memory.21_21 = (unsigned int) &rx_buf_mem[0];
  MEM[(struct rx_pool_t *)chnl_13(D) + 16B].base_addr = memory.21_21;
  # DEBUG BEGIN_STMT
  meta_memory.22_22 = (unsigned int) &rx_meta_buf_mem[0];
  MEM[(struct rx_pool_t *)chnl_13(D) + 16B].meta_base_addr = meta_memory.22_22;
  # DEBUG BEGIN_STMT
  MEM[(struct rx_pool_t *)chnl_13(D) + 16B].buf_size = _6;
  # DEBUG BEGIN_STMT
  MEM[(struct rx_pool_t *)chnl_13(D) + 16B].buf_number = _7;
  # DEBUG BEGIN_STMT
  MEM[(struct rx_pool_t *)chnl_13(D) + 16B].get_idx = 0;
  # DEBUG pool => NULL
  # DEBUG memory => NULL
  # DEBUG meta_memory => NULL
  # DEBUG buf_size => NULL
  # DEBUG buf_num => NULL
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_refill_rx_buffers (chnl_13(D));

  <bb 5> [local count: 1073741824]:
  # ret_8 = PHI <0(2), ret_17(3), 0(4)>
  # DEBUG ret => ret_8
  # DEBUG BEGIN_STMT
  tx_ring ={v} {CLOBBER};
  rx_ring ={v} {CLOBBER};
  return ret_8;

}


pfe_hif_chnl_init_tx_rx_ring (struct pfe_hif_chnl_t * chnl, struct pfe_hif_ring_t * * tx_ring, struct pfe_hif_ring_t * * rx_ring)
{
  errno_t ret;
  struct pfe_hif_ring_t * _1;
  const struct Eth_43_PFE_ConfigType * Eth_43_PFE_InternalCfgPtr.19_2;
  const struct Eth_43_PFE_HifCfgType * _3;
  short unsigned int _4;
  long unsigned int _5;
  struct pfe_hif_ring_t * _6;
  struct pfe_hif_ring_t * _7;
  int _8;
  struct pfe_hif_ring_t * _9;
  struct pfe_hif_ring_t * _10;
  const struct Eth_43_PFE_ConfigType * Eth_43_PFE_InternalCfgPtr.20_11;
  const struct Eth_43_PFE_HifCfgType * _12;
  short unsigned int _13;
  long unsigned int _14;
  struct pfe_hif_ring_t * _15;
  struct pfe_hif_ring_t * _16;
  struct pfe_hif_ring_t * _17;
  int _18;
  struct pfe_hif_ring_t * _19;
  struct pfe_hif_ring_t * _20;

  <bb 2> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  # DEBUG bNocpy => 0
  # DEBUG BEGIN_STMT
  _1 = *rx_ring_24(D);
  Eth_43_PFE_InternalCfgPtr.19_2 = Eth_43_PFE_InternalCfgPtr;
  _3 = Eth_43_PFE_InternalCfgPtr.19_2->pHif;
  _4 = _3->u16RxBDNum;
  _5 = (long unsigned int) _4;
  ret_26 = pfe_hif_ring_create (_1, _5, 1, 0);
  # DEBUG ret => ret_26
  # DEBUG BEGIN_STMT
  if (ret_26 != 0)
    goto <bb 3>; [0.00%]
  else
    goto <bb 4>; [0.00%]

  <bb 3> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _6 = *rx_ring_24(D);
  pfe_hif_ring_destroy (_6);
  # DEBUG BEGIN_STMT
  # DEBUG ret => 117
  goto <bb 10>; [0.00%]

  <bb 4> [count: 0]:
  # DEBUG BEGIN_STMT
  _7 = *rx_ring_24(D);
  _8 = pfe_hif_chnl_set_rx_ring (chnl_27(D), _7);
  if (_8 != 0)
    goto <bb 5>; [0.00%]
  else
    goto <bb 6>; [0.00%]

  <bb 5> [count: 0]:
  # DEBUG BEGIN_STMT
  _9 = *rx_ring_24(D);
  pfe_hif_ring_destroy (_9);
  # DEBUG BEGIN_STMT
  # DEBUG ret => 117
  goto <bb 10>; [0.00%]

  <bb 6> [count: 0]:
  # DEBUG BEGIN_STMT
  _10 = *tx_ring_29(D);
  Eth_43_PFE_InternalCfgPtr.20_11 = Eth_43_PFE_InternalCfgPtr;
  _12 = Eth_43_PFE_InternalCfgPtr.20_11->pHif;
  _13 = _12->u16TxBDNum;
  _14 = (long unsigned int) _13;
  ret_31 = pfe_hif_ring_create (_10, _14, 0, 0);
  # DEBUG ret => ret_31
  # DEBUG BEGIN_STMT
  if (ret_31 != 0)
    goto <bb 7>; [0.00%]
  else
    goto <bb 8>; [0.00%]

  <bb 7> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _15 = *rx_ring_24(D);
  pfe_hif_ring_destroy (_15);
  # DEBUG BEGIN_STMT
  _16 = *tx_ring_29(D);
  pfe_hif_ring_destroy (_16);
  # DEBUG BEGIN_STMT
  # DEBUG ret => 117
  goto <bb 10>; [0.00%]

  <bb 8> [count: 0]:
  # DEBUG BEGIN_STMT
  _17 = *tx_ring_29(D);
  _18 = pfe_hif_chnl_set_tx_ring (chnl_27(D), _17);
  if (_18 != 0)
    goto <bb 9>; [0.00%]
  else
    goto <bb 10>; [0.00%]

  <bb 9> [count: 0]:
  # DEBUG BEGIN_STMT
  _19 = *rx_ring_24(D);
  pfe_hif_ring_destroy (_19);
  # DEBUG BEGIN_STMT
  _20 = *tx_ring_29(D);
  pfe_hif_ring_destroy (_20);
  # DEBUG BEGIN_STMT
  # DEBUG ret => 117

  <bb 10> [count: 0]:
  # ret_21 = PHI <117(3), 117(5), 117(7), 0(8), 117(9)>
  # DEBUG ret => ret_21
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return ret_21;

}


__attribute__((cold))
pfe_hif_chnl_set_tx_ring (struct pfe_hif_chnl_t * chnl, struct pfe_hif_ring_t * ring)
{
  uint32_t wb_tbl_len;
  errno_t ret;
  const void * wb_tbl_pa;
  const void * tx_ring_pa;
  unsigned int _1;
  long unsigned int _2;
  unsigned int _3;
  long unsigned int _4;
  short unsigned int _17;
  short unsigned int _18;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG wb_tbl_len => 0
  # DEBUG BEGIN_STMT
  tx_ring_pa_10 = pfe_hif_ring_get_base_pa (ring_9(D));
  # DEBUG tx_ring_pa => tx_ring_pa_10
  # DEBUG BEGIN_STMT
  wb_tbl_pa_11 = pfe_hif_ring_get_wb_tbl_pa (ring_9(D));
  # DEBUG wb_tbl_pa => wb_tbl_pa_11
  # DEBUG BEGIN_STMT
  if (tx_ring_pa_10 == 0B)
    goto <bb 7>; [31.91%]
  else
    goto <bb 3>; [68.09%]

  <bb 3> [local count: 731110809]:
  # DEBUG BEGIN_STMT
  # DEBUG D#38 => &chnl_12(D)->lock
  _17 = MEM[(const oal_mutex_t *)chnl_12(D) + 64B];
  # DEBUG D#4 => D#38
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_17);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_12(D)->cbus_base_va;
  if (_1 != 0)
    goto <bb 4>; [33.00%]
  else
    goto <bb 6>; [67.00%]

  <bb 4> [local count: 241266567]:
  # DEBUG BEGIN_STMT
  _2 = chnl_12(D)->id;
  pfe_hif_chnl_cfg_set_tx_bd_ring_addr (_1, _2, tx_ring_pa_10);
  # DEBUG BEGIN_STMT
  if (wb_tbl_pa_11 != 0B)
    goto <bb 5>; [0.04%]
  else
    goto <bb 6>; [99.96%]

  <bb 5> [local count: 96507]:
  # DEBUG BEGIN_STMT
  wb_tbl_len_14 = pfe_hif_ring_get_wb_tbl_len (ring_9(D));
  # DEBUG wb_tbl_len => wb_tbl_len_14
  # DEBUG BEGIN_STMT
  _3 = chnl_12(D)->cbus_base_va;
  _4 = chnl_12(D)->id;
  pfe_hif_chnl_cfg_set_tx_wb_table (_3, _4, wb_tbl_pa_11, wb_tbl_len_14);

  <bb 6> [local count: 731110809]:
  # DEBUG BEGIN_STMT
  chnl_12(D)->tx_ring = ring_9(D);
  # DEBUG BEGIN_STMT
  # DEBUG D#39 => &chnl_12(D)->lock
  _18 = MEM[(const oal_mutex_t *)chnl_12(D) + 64B];
  # DEBUG D#6 => D#39
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_18);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0

  <bb 7> [local count: 1073741824]:
  # ret_5 = PHI <117(2), 0(6)>
  # DEBUG ret => ret_5
  # DEBUG BEGIN_STMT
  return ret_5;

}


__attribute__((cold))
pfe_hif_chnl_set_rx_ring (struct pfe_hif_chnl_t * chnl, struct pfe_hif_ring_t * ring)
{
  uint32_t wb_tbl_len;
  errno_t ret;
  const void * wb_tbl_pa;
  const void * rx_ring_pa;
  unsigned int _1;
  long unsigned int _2;
  unsigned int _3;
  long unsigned int _4;
  short unsigned int _17;
  short unsigned int _18;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG wb_tbl_len => 0
  # DEBUG BEGIN_STMT
  rx_ring_pa_10 = pfe_hif_ring_get_base_pa (ring_9(D));
  # DEBUG rx_ring_pa => rx_ring_pa_10
  # DEBUG BEGIN_STMT
  wb_tbl_pa_11 = pfe_hif_ring_get_wb_tbl_pa (ring_9(D));
  # DEBUG wb_tbl_pa => wb_tbl_pa_11
  # DEBUG BEGIN_STMT
  if (rx_ring_pa_10 == 0B)
    goto <bb 7>; [31.91%]
  else
    goto <bb 3>; [68.09%]

  <bb 3> [local count: 731110809]:
  # DEBUG BEGIN_STMT
  # DEBUG D#36 => &chnl_12(D)->lock
  _17 = MEM[(const oal_mutex_t *)chnl_12(D) + 64B];
  # DEBUG D#4 => D#36
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_17);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_12(D)->cbus_base_va;
  if (_1 != 0)
    goto <bb 4>; [33.00%]
  else
    goto <bb 6>; [67.00%]

  <bb 4> [local count: 241266567]:
  # DEBUG BEGIN_STMT
  _2 = chnl_12(D)->id;
  pfe_hif_chnl_cfg_set_rx_bd_ring_addr (_1, _2, rx_ring_pa_10);
  # DEBUG BEGIN_STMT
  if (wb_tbl_pa_11 != 0B)
    goto <bb 5>; [0.04%]
  else
    goto <bb 6>; [99.96%]

  <bb 5> [local count: 96507]:
  # DEBUG BEGIN_STMT
  wb_tbl_len_14 = pfe_hif_ring_get_wb_tbl_len (ring_9(D));
  # DEBUG wb_tbl_len => wb_tbl_len_14
  # DEBUG BEGIN_STMT
  _3 = chnl_12(D)->cbus_base_va;
  _4 = chnl_12(D)->id;
  pfe_hif_chnl_cfg_set_rx_wb_table (_3, _4, wb_tbl_pa_11, wb_tbl_len_14);

  <bb 6> [local count: 731110809]:
  # DEBUG BEGIN_STMT
  chnl_12(D)->rx_ring = ring_9(D);
  # DEBUG BEGIN_STMT
  # DEBUG D#37 => &chnl_12(D)->lock
  _18 = MEM[(const oal_mutex_t *)chnl_12(D) + 64B];
  # DEBUG D#6 => D#37
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_18);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0

  <bb 7> [local count: 1073741824]:
  # ret_5 = PHI <117(2), 0(6)>
  # DEBUG ret => ret_5
  # DEBUG BEGIN_STMT
  return ret_5;

}


__attribute__((hot))
pfe_hif_chnl_supply_rx_buf (const struct pfe_hif_chnl_t * chnl, const void * buf_pa, uint32_t size)
{
  errno_t ret;
  struct pfe_hif_ring_t * _1;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->rx_ring;
  ret_7 = pfe_hif_ring_enqueue_buf (_1, buf_pa_4(D), size_5(D), 0, 1);
  # DEBUG ret => ret_7
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return ret_7;

}


__attribute__((hot))
pfe_hif_chnl_release_buf (struct pfe_hif_chnl_t * chnl, const void * buf_va)
{
  errno_t ret;
  struct pfe_hif_ring_t * _1;
  const struct Eth_43_PFE_ConfigType * Eth_43_PFE_InternalCfgPtr.16_2;
  const struct Eth_43_PFE_HifCfgType * _3;
  short unsigned int _4;
  long unsigned int _5;
  short unsigned int _11;
  short unsigned int _12;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG buf_pa => (addr_t) buf_va_6(D)
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG D#34 => &chnl_7(D)->rx_lock
  _11 = MEM[(const oal_mutex_t *)chnl_7(D) + 128B];
  # DEBUG D#4 => D#34
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_11);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_7(D)->rx_ring;
  Eth_43_PFE_InternalCfgPtr.16_2 = Eth_43_PFE_InternalCfgPtr;
  _3 = Eth_43_PFE_InternalCfgPtr.16_2->pHif;
  _4 = _3->u16RxBufSize;
  _5 = (long unsigned int) _4;
  ret_10 = pfe_hif_ring_enqueue_buf (_1, buf_va_6(D), _5, 0, 1);
  # DEBUG ret => ret_10
  # DEBUG BEGIN_STMT
  # DEBUG D#35 => &chnl_7(D)->rx_lock
  _12 = MEM[(const oal_mutex_t *)chnl_7(D) + 128B];
  # DEBUG D#6 => D#35
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_12);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return ret_10;

}


__attribute__((cold))
pfe_hif_chnl_get_meta_size (const struct pfe_hif_chnl_t * chnl)
{
  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG meta_size => 32
  # DEBUG BEGIN_STMT
  return 32;

}


__attribute__((hot))
pfe_hif_chnl_rx_va (struct pfe_hif_chnl_t * chnl, void * * buf_va, uint32_t * len, bool_t * lifm, void * * meta)
{
  uint32_t flags_map[4];
  void * buf_pa;
  errno_t ret;
  struct pfe_hif_ring_t * _1;
  void * buf_pa.13_2;
  <unnamed type> _3;
  long unsigned int _4;
  long unsigned int _5;
  long unsigned int _6;
  long unsigned int _7;
  long unsigned int _8;
  long unsigned int _9;
  long unsigned int _10;
  long unsigned int _11;
  long unsigned int _12;
  long unsigned int _13;
  long unsigned int _14;
  long unsigned int _15;
  long unsigned int _16;
  long unsigned int _17;
  void * _18;
  const void * _19;
  void * _20;
  struct rx_pool_t * _21;
  void * _22;
  void * _23;
  struct pfe_hif_ring_t * _24;
  long unsigned int _25;
  void (*<Te3>) (void *) _26;
  void * _27;

  <bb 2> [local count: 1073741823]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG hif_hdr_ptr => 0B
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  flags_map = *.LC0;
  # DEBUG BEGIN_STMT
  _1 = chnl_33(D)->rx_ring;
  ret_37 = pfe_hif_ring_dequeue_buf (_1, &buf_pa, len_34(D), lifm_35(D));
  # DEBUG ret => ret_37
  # DEBUG BEGIN_STMT
  if (ret_37 == 0)
    goto <bb 3>; [50.00%]
  else
    goto <bb 6>; [50.00%]

  <bb 3> [local count: 536870911]:
  # DEBUG BEGIN_STMT
  buf_pa.13_2 = buf_pa;
  *buf_va_38(D) = buf_pa.13_2;
  # DEBUG BEGIN_STMT
  # DEBUG hif_hdr_ptr => buf_pa.13_2
  # DEBUG BEGIN_STMT
  _3 = MEM[(struct pfe_ct_hif_rx_hdr_t *)buf_pa.13_2].flags;
  _4 = (long unsigned int) _3;
  _5 = _4 >> 24;
  _6 = _4 >> 8;
  _7 = _6 & 65280;
  _8 = _5 | _7;
  _9 = _4 << 8;
  _10 = _9 & 16711680;
  _11 = _8 | _10;
  _12 = _4 << 24;
  _13 = _11 | _12;
  _14 = chnl_33(D)->id;
  _15 = flags_map[_14];
  _16 = _13 & _15;
  if (_16 != 0)
    goto <bb 4>; [33.00%]
  else
    goto <bb 5>; [67.00%]

  <bb 4> [local count: 177167401]:
  # DEBUG BEGIN_STMT
  _17 = MEM[(struct pfe_ct_hif_rx_hdr_t *)buf_pa.13_2].rx_timestamp_s;
  # DEBUG vlan_header => _17
  # DEBUG BEGIN_STMT
  _18 = buf_pa.13_2 + 12;
  _19 = buf_pa.13_2 + 16;
  memmove (_18, _19, 16);
  # DEBUG BEGIN_STMT
  _20 = *buf_va_38(D);
  MEM[(char * {ref-all})_20 + 28B] = _17;

  <bb 5> [local count: 536870911]:
  # DEBUG BEGIN_STMT
  _21 = &chnl_33(D)->rx_pool;
  _22 = *buf_va_38(D);
  _23 = rx_pool_get_meta_buf (_21, _22);
  *meta_42(D) = _23;

  <bb 6> [local count: 1073741823]:
  # DEBUG BEGIN_STMT
  _24 = chnl_33(D)->rx_ring;
  _25 = pfe_hif_ring_get_fill_level (_24);
  if (_25 == 0)
    goto <bb 7>; [50.00%]
  else
    goto <bb 9>; [50.00%]

  <bb 7> [local count: 536870911]:
  # DEBUG BEGIN_STMT
  _26 = chnl_33(D)->rx_oob_cbk.cbk;
  if (_26 != 0B)
    goto <bb 8>; [70.00%]
  else
    goto <bb 9>; [30.00%]

  <bb 8> [local count: 375809638]:
  # DEBUG BEGIN_STMT
  _27 = chnl_33(D)->rx_oob_cbk.arg;
  _26 (_27);

  <bb 9> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  buf_pa ={v} {CLOBBER};
  # DEBUG D#33 => {CLOBBER}
  # DEBUG vlan_header => D#33
  flags_map ={v} {CLOBBER};
  return ret_37;

}


__attribute__((hot))
pfe_hif_chnl_get_tx_conf (struct pfe_hif_chnl_t * chnl)
{
  errno_t ret;
  bool_t lifm;
  unsigned char lifm.12_1;
  struct pfe_hif_ring_t * _2;
  int _3;

  <bb 2> [local count: 114863532]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG ret => 118
  # DEBUG BEGIN_STMT
  goto <bb 4>; [100.00%]

  <bb 3> [local count: 1014686025]:
  # DEBUG BEGIN_STMT
  lifm.12_1 = lifm;
  if (lifm.12_1 == 1)
    goto <bb 5>; [5.50%]
  else
    goto <bb 6>; [94.50%]

  <bb 6> [local count: 958878293]:

  <bb 4> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  _2 = chnl_7(D)->tx_ring;
  _3 = pfe_hif_ring_dequeue_plain (_2, &lifm);
  if (_3 == 0)
    goto <bb 3>; [94.50%]
  else
    goto <bb 5>; [5.50%]

  <bb 5> [local count: 114863532]:
  # ret_4 = PHI <0(3), 118(4)>
  # DEBUG ret => ret_4
  # DEBUG BEGIN_STMT
  lifm ={v} {CLOBBER};
  return ret_4;

}


__attribute__((hot))
pfe_hif_chnl_tx (const struct pfe_hif_chnl_t * chnl, const void * buf_pa, const void * buf_va, uint32_t len, bool_t lifm)
{
  errno_t ret;
  struct pfe_hif_ring_t * _1;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG chnl => chnl_4(D)
  # DEBUG INLINE_ENTRY NULL
  # DEBUG BEGIN_STMT
  # DEBUG lmem_header_size => 0
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG chnl => NULL
  # DEBUG lmem_header_size => 0
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->tx_ring;
  ret_9 = pfe_hif_ring_enqueue_buf (_1, buf_pa_5(D), len_6(D), 0, lifm_7(D));
  # DEBUG ret => ret_9
  # DEBUG BEGIN_STMT
  if (lifm_7(D) == 1)
    goto <bb 3>; [20.24%]
  else
    goto <bb 4>; [79.76%]

  <bb 3> [local count: 217325345]:
  # DEBUG BEGIN_STMT
  pfe_hif_chnl_tx_dma_start (chnl_4(D));

  <bb 4> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  return ret_9;

}


__attribute__((cold, pure))
pfe_hif_chnl_get_tx_fifo_depth (const struct pfe_hif_chnl_t * chnl)
{
  uint32_t tx_fifo_depth;
  struct pfe_hif_ring_t * _1;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->tx_ring;
  tx_fifo_depth_4 = pfe_hif_ring_get_len (_1);
  # DEBUG tx_fifo_depth => tx_fifo_depth_4
  # DEBUG BEGIN_STMT
  return tx_fifo_depth_4;

}


__attribute__((cold, pure))
pfe_hif_chnl_get_rx_fifo_depth (const struct pfe_hif_chnl_t * chnl)
{
  uint32_t rx_fifo_depth;
  struct pfe_hif_ring_t * _1;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->rx_ring;
  rx_fifo_depth_4 = pfe_hif_ring_get_len (_1);
  # DEBUG rx_fifo_depth => rx_fifo_depth_4
  # DEBUG BEGIN_STMT
  return rx_fifo_depth_4;

}


__attribute__((hot, pure))
pfe_hif_chnl_tx_fifo_empty (const struct pfe_hif_chnl_t * chnl)
{
  bool_t is_empty;
  struct pfe_hif_ring_t * _1;
  long unsigned int _2;
  _Bool _3;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_5(D)->tx_ring;
  _2 = pfe_hif_ring_get_fill_level (_1);
  _3 = _2 == 0;
  is_empty_6 = (bool_t) _3;
  # DEBUG is_empty => is_empty_6
  # DEBUG BEGIN_STMT
  return is_empty_6;

}


__attribute__((hot, pure))
pfe_hif_chnl_can_accept_tx_num (const struct pfe_hif_chnl_t * chnl, uint16_t num)
{
  uint32_t ring_len;
  uint32_t fill_level;
  bool_t accept_tx;
  struct pfe_hif_ring_t * _1;
  long unsigned int _2;
  long unsigned int _3;
  long unsigned int _4;
  _Bool _5;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_7(D)->tx_ring;
  fill_level_8 = pfe_hif_ring_get_fill_level (_1);
  # DEBUG fill_level => fill_level_8
  # DEBUG BEGIN_STMT
  ring_len_9 = pfe_hif_ring_get_len (_1);
  # DEBUG ring_len => ring_len_9
  # DEBUG BEGIN_STMT
  _2 = ring_len_9 - fill_level_8;
  _3 = _2 + 4294967295;
  _4 = (long unsigned int) num_10(D);
  _5 = _3 >= _4;
  accept_tx_11 = (bool_t) _5;
  # DEBUG accept_tx => accept_tx_11
  # DEBUG BEGIN_STMT
  return accept_tx_11;

}


__attribute__((hot, pure))
pfe_hif_chnl_can_accept_rx_buf (const struct pfe_hif_chnl_t * chnl)
{
  uint32_t ring_len;
  uint32_t fill_level;
  bool_t accept_rx;
  struct pfe_hif_ring_t * _1;
  long unsigned int _2;
  _Bool _3;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_5(D)->rx_ring;
  fill_level_6 = pfe_hif_ring_get_fill_level (_1);
  # DEBUG fill_level => fill_level_6
  # DEBUG BEGIN_STMT
  ring_len_7 = pfe_hif_ring_get_len (_1);
  # DEBUG ring_len => ring_len_7
  # DEBUG BEGIN_STMT
  _2 = ring_len_7 + 4294967295;
  _3 = _2 > fill_level_6;
  accept_rx_8 = (bool_t) _3;
  # DEBUG accept_rx => accept_rx_8
  # DEBUG BEGIN_STMT
  return accept_rx_8;

}


__attribute__((hot, pure))
pfe_hif_chnl_has_tx_conf (const struct pfe_hif_chnl_t * chnl)
{
  bool_t has_tx_conf;
  struct pfe_hif_ring_t * _1;
  long unsigned int _2;
  _Bool _3;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_5(D)->tx_ring;
  _2 = pfe_hif_ring_get_fill_level (_1);
  _3 = _2 != 0;
  has_tx_conf_6 = (bool_t) _3;
  # DEBUG has_tx_conf => has_tx_conf_6
  # DEBUG BEGIN_STMT
  return has_tx_conf_6;

}


__attribute__((hot))
pfe_hif_chnl_tx_irq_unmask (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _6;
  short unsigned int _7;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#31 => &chnl_3(D)->lock
  _6 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#31
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_6);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_tx_irq_unmask (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#32 => &chnl_3(D)->lock
  _7 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#32
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_7);
  # DEBUG BEGIN_STMT
  return;

}


__attribute__((hot))
pfe_hif_chnl_tx_irq_mask (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _6;
  short unsigned int _7;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#29 => &chnl_3(D)->lock
  _6 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#29
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_6);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_tx_irq_mask (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#30 => &chnl_3(D)->lock
  _7 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#30
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_7);
  # DEBUG BEGIN_STMT
  return;

}


__attribute__((hot))
pfe_hif_chnl_rx_irq_unmask (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _6;
  short unsigned int _7;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#27 => &chnl_3(D)->lock
  _6 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#27
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_6);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_rx_irq_unmask (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#28 => &chnl_3(D)->lock
  _7 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#28
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_7);
  # DEBUG BEGIN_STMT
  return;

}


__attribute__((hot))
pfe_hif_chnl_rx_irq_mask (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _6;
  short unsigned int _7;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#25 => &chnl_3(D)->lock
  _6 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#25
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_6);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_rx_irq_mask (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#26 => &chnl_3(D)->lock
  _7 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#26
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_7);
  # DEBUG BEGIN_STMT
  return;

}


pfe_hif_chnl_set_event_cbk (struct pfe_hif_chnl_t * chnl, pfe_hif_chnl_event_t event, void (*pfe_hif_chnl_cbk_t) (void *) cbk, void * arg)
{
  errno_t ret;
  short unsigned int _14;
  short unsigned int _15;

  <bb 2> [local count: 1073741823]:
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0
  # DEBUG BEGIN_STMT
  # DEBUG D#23 => &chnl_3(D)->lock
  _14 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#23
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_14);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  if (event_5(D) == 2)
    goto <bb 3>; [34.00%]
  else
    goto <bb 4>; [66.00%]

  <bb 3> [local count: 365072220]:
  # DEBUG BEGIN_STMT
  chnl_3(D)->tx_cbk.arg = arg_6(D);
  # DEBUG BEGIN_STMT
  chnl_3(D)->tx_cbk.cbk = cbk_8(D);
  goto <bb 8>; [100.00%]

  <bb 4> [local count: 708669604]:
  # DEBUG BEGIN_STMT
  if (event_5(D) == 1)
    goto <bb 5>; [34.00%]
  else
    goto <bb 6>; [66.00%]

  <bb 5> [local count: 240947665]:
  # DEBUG BEGIN_STMT
  chnl_3(D)->rx_cbk.arg = arg_6(D);
  # DEBUG BEGIN_STMT
  chnl_3(D)->rx_cbk.cbk = cbk_8(D);
  goto <bb 8>; [100.00%]

  <bb 6> [local count: 467721938]:
  # DEBUG BEGIN_STMT
  if (event_5(D) == 4)
    goto <bb 7>; [48.89%]
  else
    goto <bb 8>; [51.11%]

  <bb 7> [local count: 228669255]:
  # DEBUG BEGIN_STMT
  chnl_3(D)->rx_oob_cbk.arg = arg_6(D);
  # DEBUG BEGIN_STMT
  chnl_3(D)->rx_oob_cbk.cbk = cbk_8(D);

  <bb 8> [local count: 1073741824]:
  # ret_1 = PHI <0(3), 0(5), 0(7), 22(6)>
  # DEBUG ret => ret_1
  # DEBUG BEGIN_STMT
  # DEBUG D#24 => &chnl_3(D)->lock
  _15 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#24
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_15);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  return ret_1;

}


__attribute__((hot))
pfe_hif_chnl_tx_dma_start (const struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->cbus_base_va;
  _2 = chnl_4(D)->id;
  pfe_hif_chnl_cfg_tx_dma_start (_1, _2);
  return;

}


__attribute__((hot))
pfe_hif_chnl_rx_dma_start (const struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  _1 = chnl_4(D)->cbus_base_va;
  _2 = chnl_4(D)->id;
  pfe_hif_chnl_cfg_rx_dma_start (_1, _2);
  return;

}


__attribute__((cold))
pfe_hif_chnl_rx_disable (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _6;
  short unsigned int _7;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#20 => &chnl_3(D)->lock
  _6 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#20
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_6);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_rx_disable (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#21 => &chnl_3(D)->lock
  _7 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#21
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_7);
  # DEBUG BEGIN_STMT
  return;

}


__attribute__((cold))
pfe_hif_chnl_rx_enable (struct pfe_hif_chnl_t * chnl)
{
  errno_t ret;
  struct pfe_hif_ring_t * _1;
  unsigned int _2;
  long unsigned int _3;
  short unsigned int _9;
  short unsigned int _10;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_7(D)->rx_ring;
  if (_1 == 0B)
    goto <bb 4>; [31.91%]
  else
    goto <bb 3>; [68.09%]

  <bb 3> [local count: 731110809]:
  # DEBUG BEGIN_STMT
  # DEBUG D#18 => &chnl_7(D)->lock
  _9 = MEM[(const oal_mutex_t *)chnl_7(D) + 64B];
  # DEBUG D#4 => D#18
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_9);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _2 = chnl_7(D)->cbus_base_va;
  _3 = chnl_7(D)->id;
  pfe_hif_chnl_cfg_rx_enable (_2, _3);
  # DEBUG BEGIN_STMT
  # DEBUG D#19 => &chnl_7(D)->lock
  _10 = MEM[(const oal_mutex_t *)chnl_7(D) + 64B];
  # DEBUG D#6 => D#19
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_10);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0

  <bb 4> [local count: 1073741824]:
  # ret_4 = PHI <117(2), 0(3)>
  # DEBUG ret => ret_4
  # DEBUG BEGIN_STMT
  return ret_4;

}


__attribute__((cold))
pfe_hif_chnl_tx_disable (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _6;
  short unsigned int _7;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#16 => &chnl_3(D)->lock
  _6 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#16
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_6);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_tx_disable (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#17 => &chnl_3(D)->lock
  _7 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#17
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_7);
  # DEBUG BEGIN_STMT
  return;

}


__attribute__((cold))
pfe_hif_chnl_tx_enable (struct pfe_hif_chnl_t * chnl)
{
  errno_t ret;
  struct pfe_hif_ring_t * _1;
  unsigned int _2;
  long unsigned int _3;
  short unsigned int _9;
  short unsigned int _10;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = chnl_7(D)->tx_ring;
  if (_1 == 0B)
    goto <bb 4>; [31.91%]
  else
    goto <bb 3>; [68.09%]

  <bb 3> [local count: 731110809]:
  # DEBUG BEGIN_STMT
  # DEBUG D#14 => &chnl_7(D)->lock
  _9 = MEM[(const oal_mutex_t *)chnl_7(D) + 64B];
  # DEBUG D#4 => D#14
  # DEBUG INLINE_ENTRY oal_spinlock_lock
  # DEBUG D#3 => D#4
  # DEBUG spinlock => D#3
  # DEBUG BEGIN_STMT
  # DEBUG D#1 => D#3
  oal_mutex_lock.isra.0 (_9);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _2 = chnl_7(D)->cbus_base_va;
  _3 = chnl_7(D)->id;
  pfe_hif_chnl_cfg_tx_enable (_2, _3);
  # DEBUG BEGIN_STMT
  # DEBUG D#15 => &chnl_7(D)->lock
  _10 = MEM[(const oal_mutex_t *)chnl_7(D) + 64B];
  # DEBUG D#6 => D#15
  # DEBUG INLINE_ENTRY oal_spinlock_unlock
  # DEBUG D#5 => D#6
  # DEBUG spinlock => D#5
  # DEBUG BEGIN_STMT
  # DEBUG D#2 => D#5
  oal_mutex_unlock.isra.0 (_10);
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG ret => 0

  <bb 4> [local count: 1073741824]:
  # ret_4 = PHI <117(2), 0(3)>
  # DEBUG ret => ret_4
  # DEBUG BEGIN_STMT
  return ret_4;

}


__attribute__((cold, pure))
pfe_hif_chnl_get_id (const struct pfe_hif_chnl_t * chnl)
{
  uint32_t chnl_id;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  chnl_id_3 = chnl_2(D)->id;
  # DEBUG chnl_id => chnl_id_3
  # DEBUG BEGIN_STMT
  return chnl_id_3;

}


__attribute__((cold))
pfe_hif_chnl_create (struct pfe_hif_chnl_t * chnl, addr_t cbus_base_va, uint32_t id, const struct pfe_bmu_t * bmu, bool_t minihif)
{
  errno_t ret;
  struct pfe_hif_chnl_t * chnl.2_1;
  oal_spinlock_t * _2;
  struct pfe_hif_chnl_t * chnl.9_3;
  oal_spinlock_t * _4;
  struct pfe_hif_chnl_t * chnl.11_5;
  oal_spinlock_t * _6;
  int _23;
  int _24;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  if (id_9(D) > 999)
    goto <bb 9>; [35.00%]
  else
    goto <bb 3>; [65.00%]

  <bb 3> [local count: 697932186]:
  # DEBUG BEGIN_STMT
  if (id_9(D) > 3)
    goto <bb 9>; [35.00%]
  else
    goto <bb 4>; [65.00%]

  <bb 4> [local count: 453655921]:
  # DEBUG BEGIN_STMT
  chnl.2_1 = chnl;
  if (chnl.2_1 == 0B)
    goto <bb 9>; [31.91%]
  else
    goto <bb 5>; [68.09%]

  <bb 5> [local count: 308894316]:
  # DEBUG BEGIN_STMT
  chnl.2_1->cbus_base_va = cbus_base_va_11(D);
  # DEBUG BEGIN_STMT
  chnl.2_1->id = id_9(D);
  # DEBUG BEGIN_STMT
  chnl.2_1->tx_ring = 0B;
  # DEBUG BEGIN_STMT
  chnl.2_1->rx_ring = 0B;
  # DEBUG BEGIN_STMT
  chnl.2_1->lock = 8;
  # DEBUG BEGIN_STMT
  _2 = &chnl.2_1->lock;
  # DEBUG spinlock => _2
  # DEBUG INLINE_ENTRY oal_spinlock_init
  # DEBUG BEGIN_STMT
  # DEBUG mutex => _2
  # DEBUG INLINE_ENTRY oal_mutex_init
  # DEBUG BEGIN_STMT
  _23 = oal_mutex_init_internal (_2);
  # DEBUG mutex => NULL
  # DEBUG spinlock => NULL
  if (_23 != 0)
    goto <bb 9>; [67.00%]
  else
    goto <bb 6>; [33.00%]

  <bb 6> [local count: 101935124]:
  # DEBUG BEGIN_STMT
  chnl.9_3 = chnl;
  chnl.9_3->rx_lock = 9;
  # DEBUG BEGIN_STMT
  _4 = &chnl.9_3->rx_lock;
  # DEBUG spinlock => _4
  # DEBUG INLINE_ENTRY oal_spinlock_init
  # DEBUG BEGIN_STMT
  # DEBUG mutex => _4
  # DEBUG INLINE_ENTRY oal_mutex_init
  # DEBUG BEGIN_STMT
  _24 = oal_mutex_init_internal (_4);
  # DEBUG mutex => NULL
  # DEBUG spinlock => NULL
  if (_24 != 0)
    goto <bb 7>; [100.00%]
  else
    goto <bb 8>; [0.00%]

  <bb 7> [local count: 101935124]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  chnl.11_5 = chnl;
  _6 = &chnl.11_5->lock;
  oal_spinlock_destroy (_6);
  # DEBUG BEGIN_STMT
  # DEBUG ret => 120
  goto <bb 9>; [100.00%]

  <bb 8> [count: 0]:
  # DEBUG BEGIN_STMT
  # DEBUG D#43 => bmu_18(D)
  ret_21 = pfe_hif_chnl_create_cfg.isra.0 (&chnl, minihif_19(D));
  # DEBUG ret => ret_21

  <bb 9> [local count: 1073741824]:
  # ret_7 = PHI <19(2), 19(3), 22(4), 120(5), 120(7), ret_21(8)>
  # DEBUG ret => ret_7
  # DEBUG BEGIN_STMT
  return ret_7;

}


__attribute__((hot))
pfe_hif_chnl_refill_rx_buffers (struct pfe_hif_chnl_t * chnl)
{
  errno_t ret;
  const void * new_buffer_va;
  struct rx_pool_t * _1;
  _Bool _2;
  long int _3;
  long int _4;
  const struct Eth_43_PFE_ConfigType * Eth_43_PFE_InternalCfgPtr.23_5;
  const struct Eth_43_PFE_HifCfgType * _6;
  short unsigned int _7;
  long unsigned int _8;
  _Bool _9;
  long int _10;
  long int _11;
  unsigned char _12;

  <bb 2> [local count: 235843098]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG flags => 0
  # DEBUG BEGIN_STMT
  goto <bb 8>; [100.00%]

  <bb 3> [local count: 1034442873]:
  # DEBUG BEGIN_STMT
  _1 = &chnl_16(D)->rx_pool;
  new_buffer_va_18 = rx_pool_get (_1);
  # DEBUG new_buffer_va => new_buffer_va_18
  # DEBUG BEGIN_STMT
  _2 = new_buffer_va_18 != 0B;
  _3 = (long int) _2;
  _4 = __builtin_expect (_3, 1);
  if (_4 != 0)
    goto <bb 4>; [90.00%]
  else
    goto <bb 9>; [10.00%]

  <bb 4> [local count: 930998585]:
  # DEBUG BEGIN_STMT
  # DEBUG new_buffer_pa => new_buffer_va_18
  # DEBUG BEGIN_STMT
  Eth_43_PFE_InternalCfgPtr.23_5 = Eth_43_PFE_InternalCfgPtr;
  _6 = Eth_43_PFE_InternalCfgPtr.23_5->pHif;
  _7 = _6->u16RxBufSize;
  _8 = (long unsigned int) _7;
  ret_20 = pfe_hif_chnl_supply_rx_buf (chnl_16(D), new_buffer_va_18, _8);
  # DEBUG ret => ret_20
  # DEBUG BEGIN_STMT
  _9 = ret_20 != 0;
  _10 = (long int) _9;
  _11 = __builtin_expect (_10, 0);
  if (_11 != 0)
    goto <bb 9>; [10.00%]
  else
    goto <bb 10>; [90.00%]

  <bb 10> [local count: 837898726]:

  <bb 8> [local count: 1073741824]:
  # DEBUG flags => 0
  # DEBUG BEGIN_STMT
  _12 = pfe_hif_chnl_can_accept_rx_buf (chnl_16(D));
  if (_12 == 1)
    goto <bb 3>; [96.34%]
  else
    goto <bb 9>; [3.66%]

  <bb 9> [local count: 235843097]:
  # DEBUG flags => NULL
  return;

}


pfe_hif_chnl_irq_unmask (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _8;
  short unsigned int _9;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#12 => &chnl_3(D)->lock
  _8 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#12
  oal_spinlock_lock.isra.0 (_8);
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_irq_unmask (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#13 => &chnl_3(D)->lock
  _9 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#13
  oal_spinlock_unlock.isra.0 (_9);
  return;

}


pfe_hif_chnl_irq_mask (struct pfe_hif_chnl_t * chnl)
{
  unsigned int _1;
  long unsigned int _2;
  short unsigned int _8;
  short unsigned int _9;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG D#10 => &chnl_3(D)->lock
  _8 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#4 => D#10
  oal_spinlock_lock.isra.0 (_8);
  # DEBUG BEGIN_STMT
  _1 = chnl_3(D)->cbus_base_va;
  _2 = chnl_3(D)->id;
  pfe_hif_chnl_cfg_irq_mask (_1, _2);
  # DEBUG BEGIN_STMT
  # DEBUG D#11 => &chnl_3(D)->lock
  _9 = MEM[(const oal_mutex_t *)chnl_3(D) + 64B];
  # DEBUG D#6 => D#11
  oal_spinlock_unlock.isra.0 (_9);
  return;

}


__attribute__((hot))
pfe_hif_chnl_isr (struct pfe_hif_chnl_t * chnl)
{
  pfe_hif_chnl_event_t events;
  errno_t ret;
  unsigned int _1;
  long unsigned int _2;
  <unnamed type> events.0_3;
  void (*<Te3>) (void *) _4;
  void * _5;
  <unnamed type> events.1_6;
  void (*<Te3>) (void *) _7;
  void * _8;
  <unnamed type> _19;
  short unsigned int _21;
  short unsigned int _22;
  <unnamed type> _23;

  <bb 2> [local count: 1073741823]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG D#8 => &chnl_11(D)->lock
  _21 = MEM[(const oal_mutex_t *)chnl_11(D) + 64B];
  # DEBUG D#4 => D#8
  oal_spinlock_lock.isra.0 (_21);
  # DEBUG BEGIN_STMT
  _1 = chnl_11(D)->cbus_base_va;
  _2 = chnl_11(D)->id;
  ret_15 = pfe_hif_chnl_cfg_isr (_1, _2, &events);
  # DEBUG ret => ret_15
  # DEBUG BEGIN_STMT
  # DEBUG D#9 => &chnl_11(D)->lock
  _22 = MEM[(const oal_mutex_t *)chnl_11(D) + 64B];
  # DEBUG D#6 => D#9
  oal_spinlock_unlock.isra.0 (_22);
  # DEBUG BEGIN_STMT
  events.0_3 = events;
  _19 = events.0_3 & 1;
  if (_19 != 0)
    goto <bb 3>; [50.00%]
  else
    goto <bb 5>; [50.00%]

  <bb 3> [local count: 536870911]:
  # DEBUG BEGIN_STMT
  _4 = chnl_11(D)->rx_cbk.cbk;
  if (_4 != 0B)
    goto <bb 4>; [70.00%]
  else
    goto <bb 5>; [30.00%]

  <bb 4> [local count: 375809638]:
  # DEBUG BEGIN_STMT
  _5 = chnl_11(D)->rx_cbk.arg;
  _4 (_5);

  <bb 5> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  events.1_6 = events;
  _23 = events.1_6 & 2;
  if (_23 != 0)
    goto <bb 6>; [50.00%]
  else
    goto <bb 8>; [50.00%]

  <bb 6> [local count: 536870913]:
  # DEBUG BEGIN_STMT
  _7 = chnl_11(D)->tx_cbk.cbk;
  if (_7 != 0B)
    goto <bb 7>; [70.00%]
  else
    goto <bb 8>; [30.00%]

  <bb 7> [local count: 375809639]:
  # DEBUG BEGIN_STMT
  _8 = chnl_11(D)->tx_cbk.arg;
  _7 (_8);

  <bb 8> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  events ={v} {CLOBBER};
  return ret_15;

}


rx_pool_get_meta_buf (const struct rx_pool_t * pool, const void * buf_va)
{
  unsigned int buf_va.14_1;
  unsigned int _2;
  unsigned int _3;
  short unsigned int _4;
  unsigned int _5;
  unsigned int _6;
  unsigned int _7;
  long unsigned int _8;
  long unsigned int _9;
  void * _13;
  unsigned int _14;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  buf_va.14_1 = (unsigned int) buf_va_10(D);
  _2 = pool_12(D)->base_addr;
  _3 = buf_va.14_1 - _2;
  _4 = pool_12(D)->buf_size;
  _5 = (unsigned int) _4;
  _6 = _3 / _5;
  _14 = _6 & 65535;
  # DEBUG index => _14
  # DEBUG BEGIN_STMT
  _7 = pool_12(D)->meta_base_addr;
  _8 = _14 * 32;
  _9 = _7 + _8;
  _13 = (void *) _9;
  return _13;

}


rx_pool_get (struct rx_pool_t * pool)
{
  void * pvBuffer;
  short unsigned int _1;
  short unsigned int _2;
  unsigned int _3;
  unsigned int _4;
  short unsigned int _5;
  unsigned int _6;
  unsigned int _7;
  unsigned int _8;
  short unsigned int _9;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG pvBuffer => 0B
  # DEBUG BEGIN_STMT
  _1 = pool_13(D)->get_idx;
  _2 = pool_13(D)->buf_number;
  if (_1 < _2)
    goto <bb 3>; [71.00%]
  else
    goto <bb 4>; [29.00%]

  <bb 3> [local count: 762356696]:
  # DEBUG BEGIN_STMT
  _3 = pool_13(D)->base_addr;
  _4 = (unsigned int) _1;
  _5 = pool_13(D)->buf_size;
  _6 = (unsigned int) _5;
  _7 = _4 * _6;
  _8 = _3 + _7;
  pvBuffer_14 = (void *) _8;
  # DEBUG pvBuffer => pvBuffer_14
  # DEBUG BEGIN_STMT
  _9 = _1 + 1;
  pool_13(D)->get_idx = _9;

  <bb 4> [local count: 1073741824]:
  # pvBuffer_10 = PHI <0B(2), pvBuffer_14(3)>
  # DEBUG pvBuffer => pvBuffer_10
  # DEBUG BEGIN_STMT
  return pvBuffer_10;

}


oal_spinlock_destroy (oal_spinlock_t * spinlock)
{
  int _3;

  <bb 2> [local count: 1073741824]:
  # DEBUG BEGIN_STMT
  # DEBUG mutex => spinlock_2(D)
  # DEBUG INLINE_ENTRY oal_mutex_destroy
  # DEBUG BEGIN_STMT
  _3 = oal_mutex_destroy_internal (spinlock_2(D));
  # DEBUG mutex => NULL
  return _3;

}


