fci_fp_rule_cmd (struct fci_msg_t * msg, uint16_t * fci_ret, struct fpp_fp_rule_cmd_t * reply_buf, uint32_t * reply_len)
{
  char * next_rule;
  struct fci_fp_rule_info_t rule;
  char * next_rule;
  struct fci_fp_rule_info_t rule;
  pfe_ct_fp_flags_t flags;
  errno_t ret;
  struct fpp_fp_rule_cmd_t * fp_cmd;
  long unsigned int _1;
  short unsigned int _2;
  int _3;
  <unnamed type> _4;
  int _5;
  <unnamed type> _6;
  int _7;
  unsigned char _8;
  uint8_t[16] * _9;
  long unsigned int _10;
  long unsigned int _11;
  short unsigned int _12;
  uint8_t[16] * _13;
  uint8_t[16] * _14;
  struct fpp_fp_rule_props_t * _15;
  char * _16;
  char * next_rule.2_17;
  long unsigned int _18;
  long unsigned int _19;
  short unsigned int _20;
  <unnamed type> _21;
  struct fpp_fp_rule_props_t * _22;
  char * _23;
  char * next_rule.3_24;
  long unsigned int _25;
  long unsigned int _26;
  short unsigned int _27;
  <unnamed type> _28;
  errno_t _84;

  <bb 2> :
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  ret_40 = 0;
  # DEBUG ret => ret_40
  # DEBUG BEGIN_STMT
  _1 = *reply_len_42(D);
  if (_1 <= 47)
    goto <bb 3>; [INV]
  else
    goto <bb 4>; [INV]

  <bb 3> :
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  ret_83 = 22;
  # DEBUG ret => ret_83
  goto <bb 32>; [INV]

  <bb 4> :
  # DEBUG BEGIN_STMT
  *reply_len_42(D) = 0;
  # DEBUG BEGIN_STMT
  fp_cmd_45 = &msg_44(D)->msg_cmd.payload;
  # DEBUG fp_cmd => fp_cmd_45
  # DEBUG BEGIN_STMT
  _2 = fp_cmd_45->action;
  _3 = (int) _2;
  switch (_3) <default: <L36> [INV], case 0: <L2> [INV], case 1: <L22> [INV], case 6: <L26> [INV], case 7: <L31> [INV]>

  <bb 5> :
<L2>:
  # DEBUG BEGIN_STMT
  flags_68 = 0;
  # DEBUG flags => flags_68
  # DEBUG BEGIN_STMT
  _4 = fp_cmd_45->r.match_action;
  _5 = (int) _4;
  switch (_5) <default: <L6> [INV], case 0: <L3> [INV], case 1: <L4> [INV], case 2: <L40> [INV]>

  <bb 6> :
<L3>:
  # DEBUG BEGIN_STMT
  flags_70 = flags_68 | 4;
  # DEBUG flags => flags_70
  # DEBUG BEGIN_STMT
  goto <bb 9>; [INV]

  <bb 7> :
<L4>:
  # DEBUG BEGIN_STMT
  flags_69 = flags_68 | 2;
  # DEBUG flags => flags_69
  # DEBUG BEGIN_STMT
  goto <bb 9>; [INV]

  <bb 8> :
<L6>:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 3;
  # DEBUG BEGIN_STMT
  ret_72 = 22;
  # DEBUG ret => ret_72

  <bb 9> :
  # ret_29 = PHI <ret_40(6), ret_40(7), ret_40(5), ret_72(8)>
  # flags_32 = PHI <flags_70(6), flags_69(7), flags_68(5), flags_68(8)>
<L40>:
  # DEBUG flags => flags_32
  # DEBUG ret => ret_29
  # DEBUG BEGIN_STMT
  if (ret_29 == 0)
    goto <bb 10>; [INV]
  else
    goto <bb 32>; [INV]

  <bb 10> :
  # DEBUG BEGIN_STMT
  _6 = fp_cmd_45->r.offset_from;
  _7 = (int) _6;
  switch (_7) <default: <L12> [INV], case 2: <L41> [INV], case 3: <L10> [INV], case 4: <L11> [INV]>

  <bb 11> :
<L10>:
  # DEBUG BEGIN_STMT
  flags_74 = flags_32 | 8;
  # DEBUG flags => flags_74
  # DEBUG BEGIN_STMT
  goto <bb 14>; [INV]

  <bb 12> :
<L11>:
  # DEBUG BEGIN_STMT
  flags_73 = flags_32 | 16;
  # DEBUG flags => flags_73
  # DEBUG BEGIN_STMT
  goto <bb 14>; [INV]

  <bb 13> :
<L12>:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 3;
  # DEBUG BEGIN_STMT
  ret_76 = 22;
  # DEBUG ret => ret_76

  <bb 14> :
  # ret_30 = PHI <ret_29(10), ret_29(11), ret_29(12), ret_76(13)>
  # flags_33 = PHI <flags_32(10), flags_74(11), flags_73(12), flags_32(13)>
<L41>:
  # DEBUG flags => flags_33
  # DEBUG ret => ret_30
  # DEBUG BEGIN_STMT
  if (ret_30 == 0)
    goto <bb 15>; [INV]
  else
    goto <bb 32>; [INV]

  <bb 15> :
  # DEBUG BEGIN_STMT
  _8 = fp_cmd_45->r.invert;
  if (_8 == 1)
    goto <bb 16>; [INV]
  else
    goto <bb 17>; [INV]

  <bb 16> :
  # DEBUG BEGIN_STMT
  flags_77 = flags_33 | 1;
  # DEBUG flags => flags_77

  <bb 17> :
  # flags_34 = PHI <flags_33(15), flags_77(16)>
  # DEBUG flags => flags_34
  # DEBUG BEGIN_STMT
  _9 = &fp_cmd_45->r.rule_name;
  _10 = fp_cmd_45->r.data;
  _11 = fp_cmd_45->r.mask;
  _12 = fp_cmd_45->r.offset;
  _13 = &fp_cmd_45->r.next_rule_name;
  ret_79 = fci_fp_db_create_rule (_9, _10, _11, _12, flags_34, _13);
  # DEBUG ret => ret_79
  # DEBUG BEGIN_STMT
  if (ret_79 == 0)
    goto <bb 18>; [INV]
  else
    goto <bb 19>; [INV]

  <bb 18> :
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 0;
  goto <bb 32>; [INV]

  <bb 19> :
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 3;
  goto <bb 32>; [INV]

  <bb 20> :
<L22>:
  # DEBUG BEGIN_STMT
  _14 = &fp_cmd_45->r.rule_name;
  ret_65 = fci_fp_db_destroy_rule (_14);
  # DEBUG ret => ret_65
  # DEBUG BEGIN_STMT
  if (ret_65 == 0)
    goto <bb 21>; [INV]
  else
    goto <bb 22>; [INV]

  <bb 21> :
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 0;
  goto <bb 32>; [INV]

  <bb 22> :
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 3;
  goto <bb 32>; [INV]

  <bb 23> :
<L26>:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  ret_57 = fci_fp_db_get_first_rule (&rule, &next_rule);
  # DEBUG ret => ret_57
  # DEBUG BEGIN_STMT
  if (ret_57 == 0)
    goto <bb 24>; [INV]
  else
    goto <bb 25>; [INV]

  <bb 24> :
  # DEBUG BEGIN_STMT
  _15 = &reply_buf_50(D)->r;
  _16 = rule.rule_name;
  next_rule.2_17 = next_rule;
  _18 = rule.data;
  _19 = rule.mask;
  _20 = rule.offset;
  _21 = rule.flags;
  fci_fp_construct_rule_reply (_15, _16, next_rule.2_17, _18, _19, _20, _21);
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 0;
  # DEBUG BEGIN_STMT
  *reply_len_42(D) = 48;
  goto <bb 26>; [INV]

  <bb 25> :
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 61986;

  <bb 26> :
  # DEBUG BEGIN_STMT
  rule ={v} {CLOBBER};
  next_rule ={v} {CLOBBER};
  goto <bb 32>; [INV]

  <bb 27> :
<L31>:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  ret_47 = fci_fp_db_get_next_rule (&rule, &next_rule);
  # DEBUG ret => ret_47
  # DEBUG BEGIN_STMT
  if (ret_47 == 0)
    goto <bb 28>; [INV]
  else
    goto <bb 29>; [INV]

  <bb 28> :
  # DEBUG BEGIN_STMT
  _22 = &reply_buf_50(D)->r;
  _23 = rule.rule_name;
  next_rule.3_24 = next_rule;
  _25 = rule.data;
  _26 = rule.mask;
  _27 = rule.offset;
  _28 = rule.flags;
  fci_fp_construct_rule_reply (_22, _23, next_rule.3_24, _25, _26, _27, _28);
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 0;
  # DEBUG BEGIN_STMT
  *reply_len_42(D) = 48;
  goto <bb 30>; [INV]

  <bb 29> :
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 61986;

  <bb 30> :
  # DEBUG BEGIN_STMT
  rule ={v} {CLOBBER};
  next_rule ={v} {CLOBBER};
  goto <bb 32>; [INV]

  <bb 31> :
<L36>:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  *fci_ret_48(D) = 4;
  # DEBUG BEGIN_STMT

  <bb 32> :
  # ret_31 = PHI <ret_83(3), ret_30(14), ret_65(22), ret_57(26), ret_47(30), ret_40(31), ret_29(9), ret_79(19), ret_79(18), ret_65(21)>
  # DEBUG ret => ret_31
  # DEBUG BEGIN_STMT
  _84 = ret_31;
  return _84;

}


fci_fp_table_cmd (struct fci_msg_t * msg, uint16_t * fci_ret, struct fpp_fp_table_cmd_t * reply_buf, uint32_t * reply_len)
{
  char * next_rule;
  struct fci_fp_rule_info_t rule;
  errno_t ret;
  struct fpp_fp_table_cmd_t * fp_cmd;
  long unsigned int _1;
  short unsigned int _2;
  int _3;
  uint8_t[16] * _4;
  uint8_t[16] * _5;
  uint8_t[16] * _6;
  uint8_t[16] * _7;
  short unsigned int _8;
  short unsigned int _9;
  uint8_t[16] * _10;
  uint8_t[16] * _11;
  struct fpp_fp_rule_props_t * _12;
  char * _13;
  char * next_rule.0_14;
  long unsigned int _15;
  long unsigned int _16;
  short unsigned int _17;
  <unnamed type> _18;
  uint8_t[16] * _19;
  struct fpp_fp_rule_props_t * _20;
  char * _21;
  char * next_rule.1_22;
  long unsigned int _23;
  long unsigned int _24;
  short unsigned int _25;
  <unnamed type> _26;
  errno_t _69;

  <bb 2> :
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  ret_29 = 0;
  # DEBUG ret => ret_29
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  _1 = *reply_len_31(D);
  if (_1 <= 47)
    goto <bb 3>; [INV]
  else
    goto <bb 4>; [INV]

  <bb 3> :
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  ret_68 = 22;
  # DEBUG ret => ret_68
  goto <bb 24>; [INV]

  <bb 4> :
  # DEBUG BEGIN_STMT
  *reply_len_31(D) = 0;
  # DEBUG BEGIN_STMT
  fp_cmd_34 = &msg_33(D)->msg_cmd.payload;
  # DEBUG fp_cmd => fp_cmd_34
  # DEBUG BEGIN_STMT
  _2 = fp_cmd_34->action;
  _3 = (int) _2;
  switch (_3) <default: <L26> [INV], case 0: <L2> [INV], case 1: <L6> [INV], case 6: <L18> [INV], case 7: <L22> [INV], case 10: <L10> [INV], case 11: <L14> [INV]>

  <bb 5> :
<L2>:
  # DEBUG BEGIN_STMT
  _4 = &fp_cmd_34->table_info.t.table_name;
  ret_64 = fci_fp_db_create_table (_4);
  # DEBUG ret => ret_64
  # DEBUG BEGIN_STMT
  if (ret_64 == 0)
    goto <bb 6>; [INV]
  else
    goto <bb 7>; [INV]

  <bb 6> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 0;
  goto <bb 24>; [INV]

  <bb 7> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 3;
  goto <bb 24>; [INV]

  <bb 8> :
<L6>:
  # DEBUG BEGIN_STMT
  _5 = &fp_cmd_34->table_info.t.table_name;
  ret_60 = fci_fp_db_destroy_table (_5, 0);
  # DEBUG ret => ret_60
  # DEBUG BEGIN_STMT
  if (ret_60 == 0)
    goto <bb 9>; [INV]
  else
    goto <bb 10>; [INV]

  <bb 9> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 0;
  goto <bb 24>; [INV]

  <bb 10> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 3;
  goto <bb 24>; [INV]

  <bb 11> :
<L10>:
  # DEBUG BEGIN_STMT
  _6 = &fp_cmd_34->table_info.t.table_name;
  _7 = &fp_cmd_34->table_info.t.rule_name;
  _8 = fp_cmd_34->table_info.t.position;
  _9 = _8 r>> 8;
  ret_41 = fci_fp_db_add_rule_to_table (_6, _7, _9);
  # DEBUG ret => ret_41
  # DEBUG BEGIN_STMT
  if (ret_41 == 0)
    goto <bb 12>; [INV]
  else
    goto <bb 13>; [INV]

  <bb 12> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 0;
  goto <bb 24>; [INV]

  <bb 13> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 3;
  goto <bb 24>; [INV]

  <bb 14> :
<L14>:
  # DEBUG BEGIN_STMT
  _10 = &fp_cmd_34->table_info.t.rule_name;
  ret_36 = fci_fp_db_remove_rule_from_table (_10);
  # DEBUG ret => ret_36
  # DEBUG BEGIN_STMT
  if (ret_36 == 0)
    goto <bb 15>; [INV]
  else
    goto <bb 16>; [INV]

  <bb 15> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 0;
  goto <bb 24>; [INV]

  <bb 16> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 3;
  goto <bb 24>; [INV]

  <bb 17> :
<L18>:
  # DEBUG BEGIN_STMT
  rule.rule_name = 0B;
  # DEBUG BEGIN_STMT
  next_rule = 0B;
  # DEBUG BEGIN_STMT
  _11 = &fp_cmd_34->table_info.t.table_name;
  ret_54 = fci_fp_db_get_table_first_rule (_11, &rule, &next_rule);
  # DEBUG ret => ret_54
  # DEBUG BEGIN_STMT
  if (ret_54 == 0)
    goto <bb 18>; [INV]
  else
    goto <bb 19>; [INV]

  <bb 18> :
  # DEBUG BEGIN_STMT
  _12 = &reply_buf_47(D)->table_info.r;
  _13 = rule.rule_name;
  next_rule.0_14 = next_rule;
  _15 = rule.data;
  _16 = rule.mask;
  _17 = rule.offset;
  _18 = rule.flags;
  fci_fp_construct_rule_reply (_12, _13, next_rule.0_14, _15, _16, _17, _18);
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 0;
  # DEBUG BEGIN_STMT
  *reply_len_31(D) = 48;
  goto <bb 24>; [INV]

  <bb 19> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 61986;
  goto <bb 24>; [INV]

  <bb 20> :
<L22>:
  # DEBUG BEGIN_STMT
  _19 = &fp_cmd_34->table_info.t.table_name;
  ret_45 = fci_fp_db_get_table_next_rule (_19, &rule, &next_rule);
  # DEBUG ret => ret_45
  # DEBUG BEGIN_STMT
  if (ret_45 == 0)
    goto <bb 21>; [INV]
  else
    goto <bb 22>; [INV]

  <bb 21> :
  # DEBUG BEGIN_STMT
  _20 = &reply_buf_47(D)->table_info.r;
  _21 = rule.rule_name;
  next_rule.1_22 = next_rule;
  _23 = rule.data;
  _24 = rule.mask;
  _25 = rule.offset;
  _26 = rule.flags;
  fci_fp_construct_rule_reply (_20, _21, next_rule.1_22, _23, _24, _25, _26);
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 0;
  # DEBUG BEGIN_STMT
  *reply_len_31(D) = 48;
  goto <bb 24>; [INV]

  <bb 22> :
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 61986;
  goto <bb 24>; [INV]

  <bb 23> :
<L26>:
  # DEBUG BEGIN_STMT
  # DEBUG BEGIN_STMT
  *fci_ret_37(D) = 4;
  # DEBUG BEGIN_STMT

  <bb 24> :
  # ret_27 = PHI <ret_68(3), ret_64(7), ret_60(10), ret_41(13), ret_36(16), ret_54(19), ret_45(22), ret_29(23), ret_64(6), ret_60(9), ret_41(12), ret_36(15), ret_54(18), ret_45(21)>
  # DEBUG ret => ret_27
  # DEBUG BEGIN_STMT
  _69 = ret_27;
  rule ={v} {CLOBBER};
  next_rule ={v} {CLOBBER};
  return _69;

}


fci_fp_construct_rule_reply (struct fpp_fp_rule_props_t * r, char * rule_name, char * next_rule, uint32_t data, uint32_t mask, uint16_t offset, pfe_ct_fp_flags_t flags)
{
  uint8_t[16] * _1;
  uint8_t[16] * _2;
  unsigned int _3;
  unsigned int _4;
  unsigned int _5;
  unsigned int _6;
  unsigned int _7;
  unsigned int _8;
  unsigned int _9;
  unsigned int _10;
  unsigned int _11;
  unsigned int _12;

  <bb 2> :
  # DEBUG BEGIN_STMT
  _1 = &r_17(D)->rule_name;
  strncpy (_1, rule_name_19(D), 15);
  # DEBUG BEGIN_STMT
  r_17(D)->data = data_21(D);
  # DEBUG BEGIN_STMT
  r_17(D)->mask = mask_23(D);
  # DEBUG BEGIN_STMT
  r_17(D)->offset = offset_25(D);
  # DEBUG BEGIN_STMT
  if (next_rule_27(D) != 0B)
    goto <bb 3>; [INV]
  else
    goto <bb 4>; [INV]

  <bb 3> :
  # DEBUG BEGIN_STMT
  _2 = &r_17(D)->next_rule_name;
  strncpy (_2, next_rule_27(D), 15);

  <bb 4> :
  # DEBUG BEGIN_STMT
  _3 = (unsigned int) flags_29(D);
  _4 = _3 & 4;
  if (_4 != 0)
    goto <bb 5>; [INV]
  else
    goto <bb 6>; [INV]

  <bb 5> :
  # DEBUG BEGIN_STMT
  r_17(D)->match_action = 0;
  goto <bb 9>; [INV]

  <bb 6> :
  # DEBUG BEGIN_STMT
  _5 = (unsigned int) flags_29(D);
  _6 = _5 & 2;
  if (_6 != 0)
    goto <bb 7>; [INV]
  else
    goto <bb 8>; [INV]

  <bb 7> :
  # DEBUG BEGIN_STMT
  r_17(D)->match_action = 1;
  goto <bb 9>; [INV]

  <bb 8> :
  # DEBUG BEGIN_STMT
  r_17(D)->match_action = 2;

  <bb 9> :
  # DEBUG BEGIN_STMT
  _7 = (unsigned int) flags_29(D);
  _8 = _7 & 1;
  if (_8 != 0)
    goto <bb 10>; [INV]
  else
    goto <bb 11>; [INV]

  <bb 10> :
  # DEBUG BEGIN_STMT
  r_17(D)->invert = 1;
  goto <bb 12>; [INV]

  <bb 11> :
  # DEBUG BEGIN_STMT
  r_17(D)->invert = 0;

  <bb 12> :
  # DEBUG BEGIN_STMT
  _9 = (unsigned int) flags_29(D);
  _10 = _9 & 8;
  if (_10 != 0)
    goto <bb 13>; [INV]
  else
    goto <bb 14>; [INV]

  <bb 13> :
  # DEBUG BEGIN_STMT
  r_17(D)->offset_from = 3;
  goto <bb 17>; [INV]

  <bb 14> :
  # DEBUG BEGIN_STMT
  _11 = (unsigned int) flags_29(D);
  _12 = _11 & 16;
  if (_12 != 0)
    goto <bb 15>; [INV]
  else
    goto <bb 16>; [INV]

  <bb 15> :
  # DEBUG BEGIN_STMT
  r_17(D)->offset_from = 4;
  goto <bb 17>; [INV]

  <bb 16> :
  # DEBUG BEGIN_STMT
  r_17(D)->offset_from = 2;

  <bb 17> :
  return;

}


