decompiled_code:
__int64 __fastcall umfpack_zi_report_symbolic(__int64 a1, double *a2)
{
int v2; // er15
__int64 result; // rax
int v4; // ebx
__int64 v5; // r14
__int64 v6; // r13
unsigned int v7; // er12
unsigned int v8; // ebp
int v9; // eax
int v10; // eax
unsigned int v11; // ebp
__int64 v12; // rdi
__int64 v13; // rbp
int v14; // er12
unsigned int v15; // ebx
__int64 (*v16)(const char *, ...); // rcx
int v17; // ebx
__int64 v18; // rdi
__int64 v19; // rax
int v20; // ebx
int v21; // er12
__int64 v22; // rbx
int v23; // eax
unsigned int v24; // er12
__int64 v25; // rsi
__int64 v26; // [rsp+8h] [rbp-90h]
__int64 v27; // [rsp+10h] [rbp-88h]
__int64 v28; // [rsp+18h] [rbp-80h]
unsigned int v29; // [rsp+20h] [rbp-78h]
int v30; // [rsp+20h] [rbp-78h]
int v31; // [rsp+24h] [rbp-74h]
__int64 v32; // [rsp+28h] [rbp-70h]
_DWORD *v34; // [rsp+38h] [rbp-60h]
__int64 v35; // [rsp+40h] [rbp-58h]
__int64 v36; // [rsp+48h] [rbp-50h]
__int64 v37; // [rsp+50h] [rbp-48h]
unsigned int v38; // [rsp+58h] [rbp-40h]
unsigned int v39; // [rsp+5Ch] [rbp-3Ch]

if ( !a2 )
return 0LL;
v2 = (int)*a2;
result = 0LL;
if ( v2 <= 2 )
return result;
if ( amd_printf )
amd_printf("Symbolic object: ");
if ( !(unsigned int)umfzi_valid_symbolic(a1) )
{
result = 4294967292LL;
if ( amd_printf )
{
amd_printf("ERROR: invalid\n");
result = 4294967292LL;
}
return result;
}
v38 = *(_DWORD *)(a1 + 208);
v39 = *(_DWORD *)(a1 + 212);
v4 = *(_DWORD *)(a1 + 64);
v31 = *(_DWORD *)(a1 + 204);
v32 = *(_QWORD *)(a1 + 72);
v36 = *(_QWORD *)(a1 + 80);
v37 = *(_QWORD *)(a1 + 88);
v26 = *(_QWORD *)(a1 + 104);
v5 = *(_QWORD *)(a1 + 112);
v6 = *(_QWORD *)(a1 + 120);
v27 = *(_QWORD *)(a1 + 128);
if ( v2 <= 3 )
goto LABEL_61;
v7 = *(_DWORD *)(a1 + 96);
v8 = *(_DWORD *)(a1 + 100);
if ( amd_printf )
{
v29 = *(_DWORD *)(a1 + 216);
amd_printf("\n matrix to be factorized:\n");
if ( amd_printf )
{
amd_printf("\tn_row: %d n_col: %d\n", v38, v39);
if ( amd_printf )
{
amd_printf("\tnumber of entries: %d\n", v29);
if ( amd_printf )
{
amd_printf(" block size used for dense matrix kernels: %d\n", *(unsigned int *)(a1 + 220));
if ( amd_printf )
amd_printf(" strategy used: ");
}
}
}
}
if ( *(_DWORD *)(a1 + 236) == 3 )
{
if ( amd_printf && (amd_printf("symmetric\n"), amd_printf) )
{
amd_printf(" ordering used: ");
v10 = *(_DWORD *)(a1 + 240);
if ( v10 == 1 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("amd on A\n");
goto LABEL_40;
}
}
else
{
v10 = *(_DWORD *)(a1 + 240);
if ( v10 == 1 )
goto LABEL_43;
}
if ( v10 != 2 )
{
if ( v10 != 6 )
{
if ( v10 == 3 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("metis on A");
}
goto LABEL_40;
}
if ( !amd_printf )
goto LABEL_43;
LABEL_37:
amd_printf("user function");
goto LABEL_40;
}
if ( !amd_printf )
goto LABEL_43;
}
else
{
if ( amd_printf && (amd_printf("unsymmetric\n"), amd_printf) )
{
amd_printf(" ordering used: ");
v9 = *(_DWORD *)(a1 + 240);
if ( v9 == 1 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("colamd on A\n");
goto LABEL_40;
}
}
else
{
v9 = *(_DWORD *)(a1 + 240);
if ( v9 == 1 )
goto LABEL_43;
}
if ( v9 != 2 )
{
if ( v9 != 6 )
{
if ( v9 == 3 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("metis on A'A");
}
goto LABEL_40;
}
if ( !amd_printf )
goto LABEL_43;
goto LABEL_37;
}
if ( !amd_printf )
goto LABEL_43;
}
amd_printf("user permutation");
LABEL_40:
if ( amd_printf )
{
amd_printf("\n");
if ( amd_printf )
amd_printf(" performn column etree postorder: ");
}
LABEL_43:
if ( *(_DWORD *)(a1 + 244) )
{
if ( !amd_printf )
goto LABEL_129;
amd_printf("no\n");
}
else
{
if ( !amd_printf )
{
LABEL_129:
if ( *(_DWORD *)(a1 + 248) )
goto LABEL_61;
goto LABEL_130;
}
amd_printf("yes\n");
}
if ( !amd_printf )
goto LABEL_129;
amd_printf(" prefer diagonal pivoting (attempt P=Q): ");
if ( *(_DWORD *)(a1 + 248) )
{
if ( amd_printf )
{
amd_printf("yes\n");
LABEL_50:
if ( amd_printf )
{
amd_printf(" variable-size part of Numeric object:\n");
if ( amd_printf )
{
amd_printf(
"\tminimum initial size (Units): %.20g (MBytes): %.1f\n",
*(double *)(a1 + 32),
*(double *)(a1 + 32) * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(
"\testimated peak size (Units): %.20g (MBytes): %.1f\n",
*(double *)a1,
*(double *)a1 * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(
"\testimated final size (Units): %.20g (MBytes): %.1f\n",
*(double *)(a1 + 8),
*(double *)(a1 + 8) * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(
" symbolic factorization memory usage (Units): %.20g (MBytes): %.1f\n",
*(double *)(a1 + 16),
*(double *)(a1 + 16) * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(" frontal matrices / supercolumns:\n");
if ( amd_printf )
{
amd_printf("\tnumber of frontal chains: %d\n", (unsigned int)v4);
if ( amd_printf )
{
amd_printf("\tnumber of frontal matrices: %d\n", (unsigned int)v31);
if ( amd_printf )
{
amd_printf("\tlargest frontal matrix row dimension: %d\n", v7);
if ( amd_printf )
amd_printf("\tlargest frontal matrix column dimension: %d\n", v8);
}
}
}
}
}
}
}
}
}
goto LABEL_61;
}
goto LABEL_61;
}
LABEL_130:
if ( amd_printf )
{
amd_printf("no\n");
goto LABEL_50;
}
LABEL_61:
if ( v4 > 0 )
{
v34 = (_DWORD *)(v26 + 4LL * v31);
v35 = (unsigned int)v4;
v28 = 0LL;
v11 = 0;
while ( 1 )
{
LODWORD(v22) = *(_DWORD *)(v32 + 4 * v28);
v23 = *(_DWORD *)(v32 + 4 * v28 + 4);
v30 = v23 - 1;
if ( v2 > 3 )
{
if ( amd_printf )
{
amd_printf(
"\n Frontal chain: %d. Frontal matrices %d to %d\n",
(unsigned int)v28,
(unsigned int)v22,
(unsigned int)(v23 - 1));
if ( amd_printf )
amd_printf(
"\tLargest frontal matrix in Frontal chain: %d-by-%d\n",
*(unsigned int *)(v36 + 4 * v28),
*(unsigned int *)(v37 + 4 * v28));
}
}
if ( (int)v22 <= v30 )
break;
if ( v2 > 3 && *v34 )
{
LABEL_87:
v16 = amd_printf;
v17 = 0;
if ( amd_printf )
{
LABEL_88:
v16("\tFront: %d placeholder for %d empty columns\n", (unsigned int)v31);
if ( v17 )
goto LABEL_89;
}
}
LABEL_106:
if ( v35 == ++v28 )
goto LABEL_89;
}
v22 = (int)v22;
while ( 1 )
{
v24 = *(_DWORD *)(v26 + 4 * v22);
if ( v2 <= 3 )
{
if ( *(_DWORD *)(v27 + 4 * v22) == -1 )
goto LABEL_115;
goto LABEL_114;
}
if ( !amd_printf )
break;
amd_printf("\tFront: %d pivot cols: %d (pivot columns %d to %d)\n", (unsigned int)v22, v24, v11, v24 + v11 - 1);
if ( !amd_printf )
break;
amd_printf(
"\t pivot row candidates: %d to %d\n",
*(unsigned int *)(v5 + 4LL * *(int *)(v6 + 4 * v22)),
(unsigned int)(*(_DWORD *)(v5 + 4 * v22 + 4) - 1));
if ( !amd_printf )
break;
amd_printf("\t leftmost descendant: %d\n", *(unsigned int *)(v6 + 4 * v22));
if ( !amd_printf )
break;
amd_printf("\t 1st new candidate row : %d\n", *(unsigned int *)(v5 + 4 * v22));
if ( !amd_printf )
break;
amd_printf("\t parent:");
v25 = *(unsigned int *)(v27 + 4 * v22);
if ( (_DWORD)v25 != -1 )
goto LABEL_123;
if ( amd_printf )
amd_printf(" (none)\n");
LABEL_114:
if ( (_DWORD)v22 == 20 && v2 == 4 && v31 > 21 )
{
if ( !amd_printf )
goto LABEL_89;
amd_printf("\t...\n");
if ( *v34 )
{
v16 = amd_printf;
if ( !amd_printf )
goto LABEL_89;
v17 = 1;
goto LABEL_88;
}
v12 = v39;
if ( (int)v38 >= (int)v39 )
v12 = v38;
v13 = umf_i_malloc(v12, 4LL);
if ( !v13 )
goto LABEL_97;
LABEL_78:
if ( amd_printf )
amd_printf("\nInitial column permutation, Q1: ");
v14 = umf_i_report_perm(v39, *(_QWORD *)(a1 + 136), v13, (unsigned int)v2, 0LL);
if ( amd_printf )
amd_printf("\nInitial row permutation, P1: ");
v15 = umf_i_report_perm(v38, *(_QWORD *)(a1 + 144), v13, (unsigned int)v2, 0LL);
umf_i_free(v13);
result = v14 | v15;
if ( v14 | v15 )
return 4294967292LL;
if ( amd_printf )
{
amd_printf(" Symbolic object: ");
goto LABEL_94;
}
return result;
}
LABEL_115:
v11 += v24;
if ( v30 < (int)++v22 )
{
if ( v2 > 3 && *v34 )
goto LABEL_87;
goto LABEL_106;
}
}
v25 = *(unsigned int *)(v27 + 4 * v22);
if ( (_DWORD)v25 == -1 )
goto LABEL_114;
LABEL_123:
if ( amd_printf )
amd_printf(" %d\n", v25);
goto LABEL_114;
}
LABEL_89:
v18 = v39;
if ( (int)v38 >= (int)v39 )
v18 = v38;
v19 = umf_i_malloc(v18, 4LL);
v13 = v19;
if ( v19 )
{
if ( v2 > 3 )
goto LABEL_78;
v20 = umf_i_report_perm(v39, *(_QWORD *)(a1 + 136), v19, 3LL, 0LL);
v21 = umf_i_report_perm(v38, *(_QWORD *)(a1 + 144), v13, 3LL, 0LL);
umf_i_free(v13);
if ( v20 | v21 )
{
result = 4294967292LL;
}
else
{
LABEL_94:
if ( amd_printf )
amd_printf("OK\n\n");
result = 0LL;
}
}
else
{
LABEL_97:
result = 0xFFFFFFFFLL;
if ( amd_printf )
{
amd_printf("ERROR: out of memory to check Symbolic object\n\n");
result = 0xFFFFFFFFLL;
}
}
return result;
}

canonical_decompiled_code:
__int64 __fastcall func0(__int64 a1, double *a2)
{
int v2; // er15
__int64 result; // rax
int v4; // ebx
__int64 v5; // r14
__int64 v6; // r13
unsigned int v7; // er12
unsigned int v8; // ebp
int v9; // eax
int v10; // eax
unsigned int v11; // ebp
__int64 v12; // rdi
__int64 v13; // rbp
int v14; // er12
unsigned int v15; // ebx
__int64 (*v16)(const char *, ...); // rcx
int v17; // ebx
__int64 v18; // rdi
__int64 v19; // rax
int v20; // ebx
int v21; // er12
__int64 v22; // rbx
int v23; // eax
unsigned int v24; // er12
__int64 v25; // rsi
__int64 v26; // [rsp+8h] [rbp-90h]
__int64 v27; // [rsp+10h] [rbp-88h]
__int64 v28; // [rsp+18h] [rbp-80h]
unsigned int v29; // [rsp+20h] [rbp-78h]
int v30; // [rsp+20h] [rbp-78h]
int v31; // [rsp+24h] [rbp-74h]
__int64 v32; // [rsp+28h] [rbp-70h]
_DWORD *v34; // [rsp+38h] [rbp-60h]
__int64 v35; // [rsp+40h] [rbp-58h]
__int64 v36; // [rsp+48h] [rbp-50h]
__int64 v37; // [rsp+50h] [rbp-48h]
unsigned int v38; // [rsp+58h] [rbp-40h]
unsigned int v39; // [rsp+5Ch] [rbp-3Ch]

if ( !a2 )
return 0LL;
v2 = (int)*a2;
result = 0LL;
if ( v2 <= 2 )
return result;
if ( amd_printf )
amd_printf("Symbolic object: ");
if ( !(unsigned int)umfzi_valid_symbolic(a1) )
{
result = 4294967292LL;
if ( amd_printf )
{
amd_printf("ERROR: invalid\n");
result = 4294967292LL;
}
return result;
}
v38 = *(_DWORD *)(a1 + 208);
v39 = *(_DWORD *)(a1 + 212);
v4 = *(_DWORD *)(a1 + 64);
v31 = *(_DWORD *)(a1 + 204);
v32 = *(_QWORD *)(a1 + 72);
v36 = *(_QWORD *)(a1 + 80);
v37 = *(_QWORD *)(a1 + 88);
v26 = *(_QWORD *)(a1 + 104);
v5 = *(_QWORD *)(a1 + 112);
v6 = *(_QWORD *)(a1 + 120);
v27 = *(_QWORD *)(a1 + 128);
if ( v2 <= 3 )
goto LABEL_61;
v7 = *(_DWORD *)(a1 + 96);
v8 = *(_DWORD *)(a1 + 100);
if ( amd_printf )
{
v29 = *(_DWORD *)(a1 + 216);
amd_printf("\n matrix to be factorized:\n");
if ( amd_printf )
{
amd_printf("\tn_row: %d n_col: %d\n", v38, v39);
if ( amd_printf )
{
amd_printf("\tnumber of entries: %d\n", v29);
if ( amd_printf )
{
amd_printf(" block size used for dense matrix kernels: %d\n", *(unsigned int *)(a1 + 220));
if ( amd_printf )
amd_printf(" strategy used: ");
}
}
}
}
if ( *(_DWORD *)(a1 + 236) == 3 )
{
if ( amd_printf && (amd_printf("symmetric\n"), amd_printf) )
{
amd_printf(" ordering used: ");
v10 = *(_DWORD *)(a1 + 240);
if ( v10 == 1 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("amd on A\n");
goto LABEL_40;
}
}
else
{
v10 = *(_DWORD *)(a1 + 240);
if ( v10 == 1 )
goto LABEL_43;
}
if ( v10 != 2 )
{
if ( v10 != 6 )
{
if ( v10 == 3 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("metis on A");
}
goto LABEL_40;
}
if ( !amd_printf )
goto LABEL_43;
LABEL_37:
amd_printf("user function");
goto LABEL_40;
}
if ( !amd_printf )
goto LABEL_43;
}
else
{
if ( amd_printf && (amd_printf("unsymmetric\n"), amd_printf) )
{
amd_printf(" ordering used: ");
v9 = *(_DWORD *)(a1 + 240);
if ( v9 == 1 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("colamd on A\n");
goto LABEL_40;
}
}
else
{
v9 = *(_DWORD *)(a1 + 240);
if ( v9 == 1 )
goto LABEL_43;
}
if ( v9 != 2 )
{
if ( v9 != 6 )
{
if ( v9 == 3 )
{
if ( !amd_printf )
goto LABEL_43;
amd_printf("metis on A'A");
}
goto LABEL_40;
}
if ( !amd_printf )
goto LABEL_43;
goto LABEL_37;
}
if ( !amd_printf )
goto LABEL_43;
}
amd_printf("user permutation");
LABEL_40:
if ( amd_printf )
{
amd_printf("\n");
if ( amd_printf )
amd_printf(" performn column etree postorder: ");
}
LABEL_43:
if ( *(_DWORD *)(a1 + 244) )
{
if ( !amd_printf )
goto LABEL_129;
amd_printf("no\n");
}
else
{
if ( !amd_printf )
{
LABEL_129:
if ( *(_DWORD *)(a1 + 248) )
goto LABEL_61;
goto LABEL_130;
}
amd_printf("yes\n");
}
if ( !amd_printf )
goto LABEL_129;
amd_printf(" prefer diagonal pivoting (attempt P=Q): ");
if ( *(_DWORD *)(a1 + 248) )
{
if ( amd_printf )
{
amd_printf("yes\n");
LABEL_50:
if ( amd_printf )
{
amd_printf(" variable-size part of Numeric object:\n");
if ( amd_printf )
{
amd_printf(
"\tminimum initial size (Units): %.20g (MBytes): %.1f\n",
*(double *)(a1 + 32),
*(double *)(a1 + 32) * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(
"\testimated peak size (Units): %.20g (MBytes): %.1f\n",
*(double *)a1,
*(double *)a1 * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(
"\testimated final size (Units): %.20g (MBytes): %.1f\n",
*(double *)(a1 + 8),
*(double *)(a1 + 8) * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(
" symbolic factorization memory usage (Units): %.20g (MBytes): %.1f\n",
*(double *)(a1 + 16),
*(double *)(a1 + 16) * 8.0 * 0.00000095367431640625);
if ( amd_printf )
{
amd_printf(" frontal matrices / supercolumns:\n");
if ( amd_printf )
{
amd_printf("\tnumber of frontal chains: %d\n", (unsigned int)v4);
if ( amd_printf )
{
amd_printf("\tnumber of frontal matrices: %d\n", (unsigned int)v31);
if ( amd_printf )
{
amd_printf("\tlargest frontal matrix row dimension: %d\n", v7);
if ( amd_printf )
amd_printf("\tlargest frontal matrix column dimension: %d\n", v8);
}
}
}
}
}
}
}
}
}
goto LABEL_61;
}
goto LABEL_61;
}
LABEL_130:
if ( amd_printf )
{
amd_printf("no\n");
goto LABEL_50;
}
LABEL_61:
if ( v4 > 0 )
{
v34 = (_DWORD *)(v26 + 4LL * v31);
v35 = (unsigned int)v4;
v28 = 0LL;
v11 = 0;
while ( 1 )
{
LODWORD(v22) = *(_DWORD *)(v32 + 4 * v28);
v23 = *(_DWORD *)(v32 + 4 * v28 + 4);
v30 = v23 - 1;
if ( v2 > 3 )
{
if ( amd_printf )
{
amd_printf(
"\n Frontal chain: %d. Frontal matrices %d to %d\n",
(unsigned int)v28,
(unsigned int)v22,
(unsigned int)(v23 - 1));
if ( amd_printf )
amd_printf(
"\tLargest frontal matrix in Frontal chain: %d-by-%d\n",
*(unsigned int *)(v36 + 4 * v28),
*(unsigned int *)(v37 + 4 * v28));
}
}
if ( (int)v22 <= v30 )
break;
if ( v2 > 3 && *v34 )
{
LABEL_87:
v16 = amd_printf;
v17 = 0;
if ( amd_printf )
{
LABEL_88:
v16("\tFront: %d placeholder for %d empty columns\n", (unsigned int)v31);
if ( v17 )
goto LABEL_89;
}
}
LABEL_106:
if ( v35 == ++v28 )
goto LABEL_89;
}
v22 = (int)v22;
while ( 1 )
{
v24 = *(_DWORD *)(v26 + 4 * v22);
if ( v2 <= 3 )
{
if ( *(_DWORD *)(v27 + 4 * v22) == -1 )
goto LABEL_115;
goto LABEL_114;
}
if ( !amd_printf )
break;
amd_printf("\tFront: %d pivot cols: %d (pivot columns %d to %d)\n", (unsigned int)v22, v24, v11, v24 + v11 - 1);
if ( !amd_printf )
break;
amd_printf(
"\t pivot row candidates: %d to %d\n",
*(unsigned int *)(v5 + 4LL * *(int *)(v6 + 4 * v22)),
(unsigned int)(*(_DWORD *)(v5 + 4 * v22 + 4) - 1));
if ( !amd_printf )
break;
amd_printf("\t leftmost descendant: %d\n", *(unsigned int *)(v6 + 4 * v22));
if ( !amd_printf )
break;
amd_printf("\t 1st new candidate row : %d\n", *(unsigned int *)(v5 + 4 * v22));
if ( !amd_printf )
break;
amd_printf("\t parent:");
v25 = *(unsigned int *)(v27 + 4 * v22);
if ( (_DWORD)v25 != -1 )
goto LABEL_123;
if ( amd_printf )
amd_printf(" (none)\n");
LABEL_114:
if ( (_DWORD)v22 == 20 && v2 == 4 && v31 > 21 )
{
if ( !amd_printf )
goto LABEL_89;
amd_printf("\t...\n");
if ( *v34 )
{
v16 = amd_printf;
if ( !amd_printf )
goto LABEL_89;
v17 = 1;
goto LABEL_88;
}
v12 = v39;
if ( (int)v38 >= (int)v39 )
v12 = v38;
v13 = umf_i_malloc(v12, 4LL);
if ( !v13 )
goto LABEL_97;
LABEL_78:
if ( amd_printf )
amd_printf("\nInitial column permutation, Q1: ");
v14 = umf_i_report_perm(v39, *(_QWORD *)(a1 + 136), v13, (unsigned int)v2, 0LL);
if ( amd_printf )
amd_printf("\nInitial row permutation, P1: ");
v15 = umf_i_report_perm(v38, *(_QWORD *)(a1 + 144), v13, (unsigned int)v2, 0LL);
umf_i_free(v13);
result = v14 | v15;
if ( v14 | v15 )
return 4294967292LL;
if ( amd_printf )
{
amd_printf(" Symbolic object: ");
goto LABEL_94;
}
return result;
}
LABEL_115:
v11 += v24;
if ( v30 < (int)++v22 )
{
if ( v2 > 3 && *v34 )
goto LABEL_87;
goto LABEL_106;
}
}
v25 = *(unsigned int *)(v27 + 4 * v22);
if ( (_DWORD)v25 == -1 )
goto LABEL_114;
LABEL_123:
if ( amd_printf )
amd_printf(" %d\n", v25);
goto LABEL_114;
}
LABEL_89:
v18 = v39;
if ( (int)v38 >= (int)v39 )
v18 = v38;
v19 = umf_i_malloc(v18, 4LL);
v13 = v19;
if ( v19 )
{
if ( v2 > 3 )
goto LABEL_78;
v20 = umf_i_report_perm(v39, *(_QWORD *)(a1 + 136), v19, 3LL, 0LL);
v21 = umf_i_report_perm(v38, *(_QWORD *)(a1 + 144), v13, 3LL, 0LL);
umf_i_free(v13);
if ( v20 | v21 )
{
result = 4294967292LL;
}
else
{
LABEL_94:
if ( amd_printf )
amd_printf("OK\n\n");
result = 0LL;
}
}
else
{
LABEL_97:
result = 0xFFFFFFFFLL;
if ( amd_printf )
{
amd_printf("ERROR: out of memory to check Symbolic object\n\n");
result = 0xFFFFFFFFLL;
}
}
return result;
}

original_code:
int umfpack_zi_report_symbolic
(
    void *SymbolicHandle,
    const double Control [20]
)
{
    int n_row, n_col, nz, nchains, nfr, maxnrows, maxncols, prl,
 k, chain, frontid, frontid1, frontid2, kk, *Chain_start, *W,
 *Chain_maxrows, *Chain_maxcols, *Front_npivcol, *Front_1strow,
 *Front_leftmostdesc, *Front_parent, done, status1, status2 ;
    SymbolicType *Symbolic ;
    prl = ((Control != (double *) ((void *)0)) ? (((Control [0]) != (Control [0])) ? 1 : Control [0]) : 1) ;
    if (prl <= 2)
    {
 return ((0)) ;
    }
    { if (amd_printf != ((void *)0)) (void) amd_printf ("Symbolic object: ") ; } ;
    Symbolic = (SymbolicType *) SymbolicHandle ;
    if (!umfzi_valid_symbolic (Symbolic))
    {
 { if (amd_printf != ((void *)0)) (void) amd_printf ("ERROR: invalid\n") ; } ;
 return ((-4)) ;
    }
    n_row = Symbolic->n_row ;
    n_col = Symbolic->n_col ;
    nz = Symbolic->nz ;
    nchains = Symbolic->nchains ;
    nfr = Symbolic->nfr ;
    maxnrows = Symbolic->maxnrows ;
    maxncols = Symbolic->maxncols ;
    Chain_start = Symbolic->Chain_start ;
    Chain_maxrows = Symbolic->Chain_maxrows ;
    Chain_maxcols = Symbolic->Chain_maxcols ;
    Front_npivcol = Symbolic->Front_npivcol ;
    Front_1strow = Symbolic->Front_1strow ;
    Front_leftmostdesc = Symbolic->Front_leftmostdesc ;
    Front_parent = Symbolic->Front_parent ;
    if (prl >= 4)
    {
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\n    matrix to be factorized:\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tn_row: ""%d"" n_col: ""%d""\n", n_row, n_col) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tnumber of entries: ""%d""\n", nz) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    block size used for dense matrix kernels:   ""%d""\n", Symbolic->nb) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    strategy used:                              ") ; } ;
 if (Symbolic->strategy == 3)
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("symmetric\n") ; } ;
            { if (amd_printf != ((void *)0)) (void) amd_printf ("    ordering used:                              ") ; } ;
            if (Symbolic->ordering == 1)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("amd on A\n") ; } ;
            }
            else if (Symbolic->ordering == 2)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user permutation") ; } ;
            }
            else if (Symbolic->ordering == 6)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user function") ; } ;
            }
            else if (Symbolic->ordering == 3)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("metis on A") ; } ;
            }
 }
 else
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("unsymmetric\n") ; } ;
            { if (amd_printf != ((void *)0)) (void) amd_printf ("    ordering used:                              ") ; } ;
            if (Symbolic->ordering == 1)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("colamd on A\n") ; } ;
            }
            else if (Symbolic->ordering == 2)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user permutation") ; } ;
            }
            else if (Symbolic->ordering == 6)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user function") ; } ;
            }
            else if (Symbolic->ordering == 3)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("metis on A'A") ; } ;
            }
 }
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    performn column etree postorder:            ") ; } ;
 if (Symbolic->fixQ)
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("no\n") ; } ;
 }
 else
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("yes\n") ; } ;
 }
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    prefer diagonal pivoting (attempt P=Q):     ") ; } ;
 if (Symbolic->prefer_diagonal)
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("yes\n") ; } ;
 }
 else
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("no\n") ; } ;
 }
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    variable-size part of Numeric object:\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tminimum initial size (Units): %.20g  (MBytes): %.1f\n", Symbolic->dnum_mem_init_usage, (((Symbolic->dnum_mem_init_usage) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\testimated peak size (Units):  %.20g  (MBytes): %.1f\n", Symbolic->num_mem_usage_est, (((Symbolic->num_mem_usage_est) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\testimated final size (Units): %.20g  (MBytes): %.1f\n", Symbolic->num_mem_size_est, (((Symbolic->num_mem_size_est) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    symbolic factorization memory usage (Units):" " %.20g  (MBytes): %.1f\n", Symbolic->peak_sym_usage, (((Symbolic->peak_sym_usage) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    frontal matrices / supercolumns:\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tnumber of frontal chains: ""%d""\n", nchains) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tnumber of frontal matrices: ""%d""\n", nfr) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tlargest frontal matrix row dimension: ""%d""\n", maxnrows) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tlargest frontal matrix column dimension: ""%d""\n",maxncols) ; };
    }
    k = 0 ;
    done = (0) ;
    for (chain = 0 ; chain < nchains ; chain++)
    {
 frontid1 = Chain_start [chain] ;
 frontid2 = Chain_start [chain+1] - 1 ;
 { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\n    Frontal chain: ""%d"".  Frontal matrices ""%d"" to ""%d""\n", (chain), (frontid1), (frontid2)) ; } ; } } ;
 { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\tLargest frontal matrix in Frontal chain: ""%d""-by-""%d""\n", Chain_maxrows [chain], Chain_maxcols [chain]) ; } ; } } ;
 for (frontid = frontid1 ; frontid <= frontid2 ; frontid++)
 {
     kk = Front_npivcol [frontid] ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\tFront: ""%d""  pivot cols: ""%d"" (pivot columns ""%d"" to " "%d"")\n", (frontid), kk, (k), (k+kk-1)) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    pivot row candidates: ""%d"" to ""%d""\n", (Front_1strow [Front_leftmostdesc [frontid]]), (Front_1strow [frontid+1]-1)) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    leftmost descendant: ""%d""\n", (Front_leftmostdesc [frontid])) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    1st new candidate row : ""%d""\n", (Front_1strow [frontid])) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    parent:") ; } ; } } ;
     if (Front_parent [frontid] == (-1))
     {
  { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf (" (none)\n") ; } ; } } ;
     }
     else
     {
  { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf (" ""%d""\n", (Front_parent [frontid])) ; } ; } } ;
     }
     done = (frontid == 20 && frontid < nfr-1 && prl == 4) ;
     if (done)
     {
  { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t...\n") ; } ; } } ;
  break ;
     }
     k += kk ;
 }
 if (Front_npivcol [nfr] != 0)
 {
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\tFront: ""%d"" placeholder for ""%d"" empty columns\n", (nfr), Front_npivcol [nfr]) ; } ; } } ;
 }
 if (done)
 {
     break ;
 }
    }
    W = (int *) umf_i_malloc ((((n_row) > (n_col)) ? (n_row) : (n_col)), sizeof (int)) ;
    if (!W)
    {
 { if (amd_printf != ((void *)0)) (void) amd_printf ("ERROR: out of memory to check Symbolic object\n\n") ; } ;
 return ((-1)) ;
    }
    { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\nInitial column permutation, Q1: ") ; } ; } } ;
    status1 = umf_i_report_perm (n_col, Symbolic->Cperm_init, W, prl, 0) ;
    { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\nInitial row permutation, P1: ") ; } ; } } ;
    status2 = umf_i_report_perm (n_row, Symbolic->Rperm_init, W, prl, 0) ;
    (void) umf_i_free ((void *) W) ;
    if (status1 != (0) || status2 != (0))
    {
 return ((-4)) ;
    }
    { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("    Symbolic object:  ") ; } ; } } ;
    { if (amd_printf != ((void *)0)) (void) amd_printf ("OK\n\n") ; } ;
    return ((0)) ;
}

canonical_original_code:
int umfpack_zi_report_symbolic(void *SymbolicHandle, double Control[20])
{
    int n_row; int n_col; int nz; int nchains; int nfr; int maxnrows; int maxncols; int prl; int k; int chain; int frontid; int frontid1; int frontid2; int kk; int *Chain_start; int *W; int *Chain_maxrows; int *Chain_maxcols; int *Front_npivcol; int *Front_1strow; int *Front_leftmostdesc; int *Front_parent; int done; int status1; int status2;
    struct SymbolicType *Symbolic;
    prl = ((Control != (double *) ((void *)0)) ? (((Control [0]) != (Control [0])) ? 1 : Control [0]) : 1) ;
    if (prl <= 2)
    {
 return ((0)) ;
    }
    { if (amd_printf != ((void *)0)) (void) amd_printf ("Symbolic object: ") ; } ;
    Symbolic = (struct SymbolicType *) SymbolicHandle ;
    if (!umfzi_valid_symbolic (Symbolic))
    {
 { if (amd_printf != ((void *)0)) (void) amd_printf ("ERROR: invalid\n") ; } ;
 return ((-4)) ;
    }
    n_row = Symbolic->n_row ;
    n_col = Symbolic->n_col ;
    nz = Symbolic->nz ;
    nchains = Symbolic->nchains ;
    nfr = Symbolic->nfr ;
    maxnrows = Symbolic->maxnrows ;
    maxncols = Symbolic->maxncols ;
    Chain_start = Symbolic->Chain_start ;
    Chain_maxrows = Symbolic->Chain_maxrows ;
    Chain_maxcols = Symbolic->Chain_maxcols ;
    Front_npivcol = Symbolic->Front_npivcol ;
    Front_1strow = Symbolic->Front_1strow ;
    Front_leftmostdesc = Symbolic->Front_leftmostdesc ;
    Front_parent = Symbolic->Front_parent ;
    if (prl >= 4)
    {
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\n    matrix to be factorized:\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tn_row: ""%d"" n_col: ""%d""\n", n_row, n_col) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tnumber of entries: ""%d""\n", nz) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    block size used for dense matrix kernels:   ""%d""\n", Symbolic->nb) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    strategy used:                              ") ; } ;
 if (Symbolic->strategy == 3)
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("symmetric\n") ; } ;
            { if (amd_printf != ((void *)0)) (void) amd_printf ("    ordering used:                              ") ; } ;
            if (Symbolic->ordering == 1)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("amd on A\n") ; } ;
            }
            else if (Symbolic->ordering == 2)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user permutation") ; } ;
            }
            else if (Symbolic->ordering == 6)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user function") ; } ;
            }
            else if (Symbolic->ordering == 3)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("metis on A") ; } ;
            }
 }
 else
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("unsymmetric\n") ; } ;
            { if (amd_printf != ((void *)0)) (void) amd_printf ("    ordering used:                              ") ; } ;
            if (Symbolic->ordering == 1)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("colamd on A\n") ; } ;
            }
            else if (Symbolic->ordering == 2)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user permutation") ; } ;
            }
            else if (Symbolic->ordering == 6)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("user function") ; } ;
            }
            else if (Symbolic->ordering == 3)
            {
                { if (amd_printf != ((void *)0)) (void) amd_printf ("metis on A'A") ; } ;
            }
 }
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    performn column etree postorder:            ") ; } ;
 if (Symbolic->fixQ)
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("no\n") ; } ;
 }
 else
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("yes\n") ; } ;
 }
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    prefer diagonal pivoting (attempt P=Q):     ") ; } ;
 if (Symbolic->prefer_diagonal)
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("yes\n") ; } ;
 }
 else
 {
     { if (amd_printf != ((void *)0)) (void) amd_printf ("no\n") ; } ;
 }
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    variable-size part of Numeric object:\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tminimum initial size (Units): %.20g  (MBytes): %.1f\n", Symbolic->dnum_mem_init_usage, (((Symbolic->dnum_mem_init_usage) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\testimated peak size (Units):  %.20g  (MBytes): %.1f\n", Symbolic->num_mem_usage_est, (((Symbolic->num_mem_usage_est) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\testimated final size (Units): %.20g  (MBytes): %.1f\n", Symbolic->num_mem_size_est, (((Symbolic->num_mem_size_est) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    symbolic factorization memory usage (Units):" " %.20g  (MBytes): %.1f\n", Symbolic->peak_sym_usage, (((Symbolic->peak_sym_usage) * sizeof (Unit)) / 1048576.0)) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("    frontal matrices / supercolumns:\n") ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tnumber of frontal chains: ""%d""\n", nchains) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tnumber of frontal matrices: ""%d""\n", nfr) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tlargest frontal matrix row dimension: ""%d""\n", maxnrows) ; } ;
 { if (amd_printf != ((void *)0)) (void) amd_printf ("\tlargest frontal matrix column dimension: ""%d""\n",maxncols) ; };
    }
    k = 0 ;
    done = (0) ;
    for (chain = 0 ; chain < nchains ; chain++)
    {
 frontid1 = Chain_start [chain] ;
 frontid2 = Chain_start [chain+1] - 1 ;
 { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\n    Frontal chain: ""%d"".  Frontal matrices ""%d"" to ""%d""\n", (chain), (frontid1), (frontid2)) ; } ; } } ;
 { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\tLargest frontal matrix in Frontal chain: ""%d""-by-""%d""\n", Chain_maxrows [chain], Chain_maxcols [chain]) ; } ; } } ;
 for (frontid = frontid1 ; frontid <= frontid2 ; frontid++)
 {
     kk = Front_npivcol [frontid] ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\tFront: ""%d""  pivot cols: ""%d"" (pivot columns ""%d"" to " "%d"")\n", (frontid), kk, (k), (k+kk-1)) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    pivot row candidates: ""%d"" to ""%d""\n", (Front_1strow [Front_leftmostdesc [frontid]]), (Front_1strow [frontid+1]-1)) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    leftmost descendant: ""%d""\n", (Front_leftmostdesc [frontid])) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    1st new candidate row : ""%d""\n", (Front_1strow [frontid])) ; } ; } } ;
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t    parent:") ; } ; } } ;
     if (Front_parent [frontid] == (-1))
     {
  { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf (" (none)\n") ; } ; } } ;
     }
     else
     {
  { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf (" ""%d""\n", (Front_parent [frontid])) ; } ; } } ;
     }
     done = (frontid == 20 && frontid < nfr-1 && prl == 4) ;
     if (done)
     {
  { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\t...\n") ; } ; } } ;
  break ;
     }
     k += kk ;
 }
 if (Front_npivcol [nfr] != 0)
 {
     { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\tFront: ""%d"" placeholder for ""%d"" empty columns\n", (nfr), Front_npivcol [nfr]) ; } ; } } ;
 }
 if (done)
 {
     break ;
 }
    }
    W = (int *) umf_i_malloc ((((n_row) > (n_col)) ? (n_row) : (n_col)), sizeof (int)) ;
    if (!W)
    {
 { if (amd_printf != ((void *)0)) (void) amd_printf ("ERROR: out of memory to check Symbolic object\n\n") ; } ;
 return ((-1)) ;
    }
    { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\nInitial column permutation, Q1: ") ; } ; } } ;
    status1 = umf_i_report_perm (n_col, Symbolic->Cperm_init, W, prl, 0) ;
    { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("\nInitial row permutation, P1: ") ; } ; } } ;
    status2 = umf_i_report_perm (n_row, Symbolic->Rperm_init, W, prl, 0) ;
    (void) umf_i_free ((void *) W) ;
    if (status1 != (0) || status2 != (0))
    {
 return ((-4)) ;
    }
    { if (prl >= (4)) { { if (amd_printf != ((void *)0)) (void) amd_printf ("    Symbolic object:  ") ; } ; } } ;
    { if (amd_printf != ((void *)0)) (void) amd_printf ("OK\n\n") ; } ;
    return ((0)) ;
}

variable_types:
SymbolicHandle
void *

variable_types:
Control
double [20]

variable_types: nz int

variable_types: nchains int

variable_types: nfr int

variable_types: maxnrows int

variable_types: maxncols int

variable_types: prl int

variable_types: k int

variable_types: chain int

variable_types: frontid int

variable_types: kk int

variable_types:
W
int *

variable_types: done int

variable_types: struct SymbolicType { double num_mem_usage_est; int valid; } *


original_code:
void amd_l1
(
    long n,
    const long Ap [ ],
    const long Ai [ ],
    long P [ ],
    long Pinv [ ],
    long Len [ ],
    long slen,
    long S [ ],
    double Control [ ],
    double Info [ ]
)
{
    long i, j, k, p, pfree, iwlen, pj, p1, p2, pj2, *Iw, *Pe, *Nv, *Head,
 *Elen, *Degree, *s, *W, *Sp, *Tp ;
    ;
    iwlen = slen - 6*n ;
    s = S ;
    Pe = s ; s += n ;
    Nv = s ; s += n ;
    Head = s ; s += n ;
    Elen = s ; s += n ;
    Degree = s ; s += n ;
    W = s ; s += n ;
    Iw = s ; s += iwlen ;
    ;
    Sp = Nv ;
    Tp = W ;
    pfree = 0 ;
    for (j = 0 ; j < n ; j++)
    {
 Pe [j] = pfree ;
 Sp [j] = pfree ;
 pfree += Len [j] ;
    }
    ;
    for (k = 0 ; k < n ; k++)
    {
 ;
 p1 = Ap [k] ;
 p2 = Ap [k+1] ;
 for (p = p1 ; p < p2 ; )
 {
     j = Ai [p] ;
     ;
     if (j < k)
     {
  ;
  ;
  Iw [Sp [j]++] = k ;
  Iw [Sp [k]++] = j ;
  p++ ;
     }
     else if (j == k)
     {
  p++ ;
  break ;
     }
     else
     {
  break ;
     }
     ;
     pj2 = Ap [j+1] ;
     for (pj = Tp [j] ; pj < pj2 ; )
     {
  i = Ai [pj] ;
  ;
  if (i < k)
  {
      ;
      ;
      Iw [Sp [i]++] = j ;
      Iw [Sp [j]++] = i ;
      pj++ ;
  }
  else if (i == k)
  {
      pj++ ;
      break ;
  }
  else
  {
      break ;
  }
     }
     Tp [j] = pj ;
 }
 Tp [k] = p ;
    }
    for (j = 0 ; j < n ; j++)
    {
 for (pj = Tp [j] ; pj < Ap [j+1] ; pj++)
 {
     i = Ai [pj] ;
     ;
     ;
     ;
     Iw [Sp [i]++] = j ;
     Iw [Sp [j]++] = i ;
 }
    }
    amd_l2 (n, Pe, Iw, Len, iwlen, pfree,
 Nv, Pinv, P, Head, Elen, Degree, W, Control, Info) ;
}

canonical_original_code:
void amd_l1(long n, long Ap[], long Ai[], long P[], long Pinv[], long Len[], long slen, long S[], double Control[], double Info[])
{
    long i; long j; long k; long p; long pfree; long iwlen; long pj; long p1; long p2; long pj2; long *Iw; long *Pe; long *Nv; long *Head; long *Elen; long *Degree; long *s; long *W; long *Sp; long *Tp;
    ;
    iwlen = slen - 6*n ;
    s = S ;
    Pe = s ; s += n ;
    Nv = s ; s += n ;
    Head = s ; s += n ;
    Elen = s ; s += n ;
    Degree = s ; s += n ;
    W = s ; s += n ;
    Iw = s ; s += iwlen ;
    ;
    Sp = Nv ;
    Tp = W ;
    pfree = 0 ;
    for (j = 0 ; j < n ; j++)
    {
 Pe [j] = pfree ;
 Sp [j] = pfree ;
 pfree += Len [j] ;
    }
    ;
    for (k = 0 ; k < n ; k++)
    {
 ;
 p1 = Ap [k] ;
 p2 = Ap [k+1] ;
 for (p = p1 ; p < p2 ; )
 {
     j = Ai [p] ;
     ;
     if (j < k)
     {
  ;
  ;
  Iw [Sp [j]++] = k ;
  Iw [Sp [k]++] = j ;
  p++ ;
     }
     else if (j == k)
     {
  p++ ;
  break ;
     }
     else
     {
  break ;
     }
     ;
     pj2 = Ap [j+1] ;
     for (pj = Tp [j] ; pj < pj2 ; )
     {
  i = Ai [pj] ;
  ;
  if (i < k)
  {
      ;
      ;
      Iw [Sp [i]++] = j ;
      Iw [Sp [j]++] = i ;
      pj++ ;
  }
  else if (i == k)
  {
      pj++ ;
      break ;
  }
  else
  {
      break ;
  }
     }
     Tp [j] = pj ;
 }
 Tp [k] = p ;
    }
    for (j = 0 ; j < n ; j++)
    {
 for (pj = Tp [j] ; pj < Ap [j+1] ; pj++)
 {
     i = Ai [pj] ;
     ;
     ;
     ;
     Iw [Sp [i]++] = j ;
     Iw [Sp [j]++] = i ;
 }
    }
    amd_l2 (n, Pe, Iw, Len, iwlen, pfree,
 Nv, Pinv, P, Head, Elen, Degree, W, Control, Info) ;
}

variable_types: n long

variable_types:
Ap
long []

variable_types:
Ai
long []

variable_types:
P
long []

variable_types:
Pinv
long []

variable_types:
Len
long []

variable_types: slen long

variable_types:
S
long []

variable_types:
Control
double []

variable_types:
Info
double []

variable_types: i long

variable_types: j long

variable_types: k long

variable_types: p long

variable_types: pfree long

variable_types: iwlen long

variable_types: pj long

variable_types:
Iw
long *

variable_types:
Pe
long *

variable_types:
Nv
long *

variable_types:
Head
long *

variable_types:
Elen
long *

variable_types:
Degree
long *

variable_types:
s
long *

variable_types:
W
long *

variable_types:
Sp
long *

variable_types:
Tp
long *

return_type: void


original_code:
void amd_1
(
    int n,
    const int Ap [ ],
    const int Ai [ ],
    int P [ ],
    int Pinv [ ],
    int Len [ ],
    int slen,
    int S [ ],
    double Control [ ],
    double Info [ ]
)
{
    int i, j, k, p, pfree, iwlen, pj, p1, p2, pj2, *Iw, *Pe, *Nv, *Head,
 *Elen, *Degree, *s, *W, *Sp, *Tp ;
    ;
    iwlen = slen - 6*n ;
    s = S ;
    Pe = s ; s += n ;
    Nv = s ; s += n ;
    Head = s ; s += n ;
    Elen = s ; s += n ;
    Degree = s ; s += n ;
    W = s ; s += n ;
    Iw = s ; s += iwlen ;
    ;
    Sp = Nv ;
    Tp = W ;
    pfree = 0 ;
    for (j = 0 ; j < n ; j++)
    {
 Pe [j] = pfree ;
 Sp [j] = pfree ;
 pfree += Len [j] ;
    }
    ;
    for (k = 0 ; k < n ; k++)
    {
 ;
 p1 = Ap [k] ;
 p2 = Ap [k+1] ;
 for (p = p1 ; p < p2 ; )
 {
     j = Ai [p] ;
     ;
     if (j < k)
     {
  ;
  ;
  Iw [Sp [j]++] = k ;
  Iw [Sp [k]++] = j ;
  p++ ;
     }
     else if (j == k)
     {
  p++ ;
  break ;
     }
     else
     {
  break ;
     }
     ;
     pj2 = Ap [j+1] ;
     for (pj = Tp [j] ; pj < pj2 ; )
     {
  i = Ai [pj] ;
  ;
  if (i < k)
  {
      ;
      ;
      Iw [Sp [i]++] = j ;
      Iw [Sp [j]++] = i ;
      pj++ ;
  }
  else if (i == k)
  {
      pj++ ;
      break ;
  }
  else
  {
      break ;
  }
     }
     Tp [j] = pj ;
 }
 Tp [k] = p ;
    }
    for (j = 0 ; j < n ; j++)
    {
 for (pj = Tp [j] ; pj < Ap [j+1] ; pj++)
 {
     i = Ai [pj] ;
     ;
     ;
     ;
     Iw [Sp [i]++] = j ;
     Iw [Sp [j]++] = i ;
 }
    }
    amd_2 (n, Pe, Iw, Len, iwlen, pfree,
 Nv, Pinv, P, Head, Elen, Degree, W, Control, Info) ;
}

canonical_original_code:
void amd_1(int n, int Ap[], int Ai[], int P[], int Pinv[], int Len[], int slen, int S[], double Control[], double Info[])
{
    int i; int j; int k; int p; int pfree; int iwlen; int pj; int p1; int p2; int pj2; int *Iw; int *Pe; int *Nv; int *Head; int *Elen; int *Degree; int *s; int *W; int *Sp; int *Tp;
    ;
    iwlen = slen - 6*n ;
    s = S ;
    Pe = s ; s += n ;
    Nv = s ; s += n ;
    Head = s ; s += n ;
    Elen = s ; s += n ;
    Degree = s ; s += n ;
    W = s ; s += n ;
    Iw = s ; s += iwlen ;
    ;
    Sp = Nv ;
    Tp = W ;
    pfree = 0 ;
    for (j = 0 ; j < n ; j++)
    {
 Pe [j] = pfree ;
 Sp [j] = pfree ;
 pfree += Len [j] ;
    }
    ;
    for (k = 0 ; k < n ; k++)
    {
 ;
 p1 = Ap [k] ;
 p2 = Ap [k+1] ;
 for (p = p1 ; p < p2 ; )
 {
     j = Ai [p] ;
     ;
     if (j < k)
     {
  ;
  ;
  Iw [Sp [j]++] = k ;
  Iw [Sp [k]++] = j ;
  p++ ;
     }
     else if (j == k)
     {
  p++ ;
  break ;
     }
     else
     {
  break ;
     }
     ;
     pj2 = Ap [j+1] ;
     for (pj = Tp [j] ; pj < pj2 ; )
     {
  i = Ai [pj] ;
  ;
  if (i < k)
  {
      ;
      ;
      Iw [Sp [i]++] = j ;
      Iw [Sp [j]++] = i ;
      pj++ ;
  }
  else if (i == k)
  {
      pj++ ;
      break ;
  }
  else
  {
      break ;
  }
     }
     Tp [j] = pj ;
 }
 Tp [k] = p ;
    }
    for (j = 0 ; j < n ; j++)
    {
 for (pj = Tp [j] ; pj < Ap [j+1] ; pj++)
 {
     i = Ai [pj] ;
     ;
     ;
     ;
     Iw [Sp [i]++] = j ;
     Iw [Sp [j]++] = i ;
 }
    }
    amd_2 (n, Pe, Iw, Len, iwlen, pfree,
 Nv, Pinv, P, Head, Elen, Degree, W, Control, Info) ;
}

variable_types: n int

variable_types:
Ap
int []

variable_types:
Ai
int []

variable_types:
P
int []

variable_types:
Pinv
int []

variable_types:
Len
int []

variable_types: slen int

variable_types:
S
int []

variable_types:
Control
double []

variable_types:
Info
double []

variable_types: i int

variable_types: j int

variable_types: k int

variable_types: p int

variable_types: pfree int

variable_types: iwlen int

variable_types: pj int

variable_types:
Iw
int *

variable_types:
Pe
int *

variable_types:
Nv
int *

variable_types:
Head
int *

variable_types:
Elen
int *

variable_types:
Degree
int *

variable_types:
s
int *

variable_types:
W
int *

variable_types:
Sp
int *

variable_types:
Tp
int *


decompiled_code:
__int64 __fastcall amd_valid(int a1, int a2, int *a3, __int64 a4)
{
int *v5; // r9
__int64 v6; // rbp
unsigned int v7; // ecx
int v8; // esi
int v9; // eax
int *v10; // rdx
unsigned __int64 v11; // r12
int v12; // eax
int v13; // esi

if ( a1 < 0 || a2 < 0 )
return (unsigned int)-2;
if ( !a3 || !a4 )
return (unsigned int)-2;
if ( a3[a2] < 0 || *a3 )
return (unsigned int)-2;
if ( a2 <= 0 )
return 0;
v5 = a3;
v6 = (__int64)&a3[a2 - 1 + 1];
v7 = 0;
while ( 1 )
{
v8 = *v5;
v9 = v5[1];
if ( *v5 > v9 )
return (unsigned int)-2;
if ( v8 < v9 )
break;
LABEL_17:
if ( ++v5 == (int *)v6 )
return v7;
}
v10 = (int *)(a4 + 4LL * v8);
v11 = a4 + 4 + 4 * (v8 + (unsigned __int64)(unsigned int)(v9 - 1 - v8));
v12 = -1;
while ( 1 )
{
v13 = v12;
v12 = *v10;
if ( *v10 < 0 || a1 <= v12 )
return (unsigned int)-2;
if ( v12 <= v13 )
v7 = 1;
if ( ++v10 == (int *)v11 )
goto LABEL_17;
}
}

canonical_decompiled_code:
__int64 __fastcall func0(int a1, int a2, int *a3, __int64 a4)
{
int *v5; // r9
__int64 v6; // rbp
unsigned int v7; // ecx
int v8; // esi
int v9; // eax
int *v10; // rdx
unsigned __int64 v11; // r12
int v12; // eax
int v13; // esi

if ( a1 < 0 || a2 < 0 )
return (unsigned int)-2;
if ( !a3 || !a4 )
return (unsigned int)-2;
if ( a3[a2] < 0 || *a3 )
return (unsigned int)-2;
if ( a2 <= 0 )
return 0;
v5 = a3;
v6 = (__int64)&a3[a2 - 1 + 1];
v7 = 0;
while ( 1 )
{
v8 = *v5;
v9 = v5[1];
if ( *v5 > v9 )
return (unsigned int)-2;
if ( v8 < v9 )
break;
LABEL_17:
if ( ++v5 == (int *)v6 )
return v7;
}
v10 = (int *)(a4 + 4LL * v8);
v11 = a4 + 4 + 4 * (v8 + (unsigned __int64)(unsigned int)(v9 - 1 - v8));
v12 = -1;
while ( 1 )
{
v13 = v12;
v12 = *v10;
if ( *v10 < 0 || a1 <= v12 )
return (unsigned int)-2;
if ( v12 <= v13 )
v7 = 1;
if ( ++v10 == (int *)v11 )
goto LABEL_17;
}
}

original_code:
int amd_valid
(
    int n_row,
    int n_col,
    const int Ap [ ],
    const int Ai [ ]
)
{
    int nz, j, p1, p2, ilast, i, p, result = 0 ;
    if (n_row < 0 || n_col < 0 || Ap == ((void *)0) || Ai == ((void *)0))
    {
 return (-2) ;
    }
    nz = Ap [n_col] ;
    if (Ap [0] != 0 || nz < 0)
    {
 ;
 return (-2) ;
    }
    for (j = 0 ; j < n_col ; j++)
    {
 p1 = Ap [j] ;
 p2 = Ap [j+1] ;
 ;
 if (p1 > p2)
 {
     ;
     return (-2) ;
 }
 ilast = (-1) ;
 for (p = p1 ; p < p2 ; p++)
 {
     i = Ai [p] ;
     ;
     if (i < 0 || i >= n_row)
     {
  ;
  return (-2) ;
     }
     if (i <= ilast)
     {
  ;
  result = 1 ;
     }
     ilast = i ;
 }
    }
    return (result) ;
}

canonical_original_code:
int amd_valid(int n_row, int n_col, int Ap[], int Ai[])
{
    int nz; int j; int p1; int p2; int ilast; int i; int p; int result = 0;
    if (n_row < 0 || n_col < 0 || Ap == ((void *)0) || Ai == ((void *)0))
    {
 return (-2) ;
    }
    nz = Ap [n_col] ;
    if (Ap [0] != 0 || nz < 0)
    {
 ;
 return (-2) ;
    }
    for (j = 0 ; j < n_col ; j++)
    {
 p1 = Ap [j] ;
 p2 = Ap [j+1] ;
 ;
 if (p1 > p2)
 {
     ;
     return (-2) ;
 }
 ilast = (-1) ;
 for (p = p1 ; p < p2 ; p++)
 {
     i = Ai [p] ;
     ;
     if (i < 0 || i >= n_row)
     {
  ;
  return (-2) ;
     }
     if (i <= ilast)
     {
  ;
  result = 1 ;
     }
     ilast = i ;
 }
    }
    return (result) ;
}

variable_types:
Ap
int []

variable_types:
Ai
int []

variable_types: nz int

variable_types: ilast int

variable_types: i int

variable_types: result int

return_type: int


original_code:
long umf_l_singletons
(
    long n_row,
    long n_col,
    const long Ap [ ],
    const long Ai [ ],
    const long Quser [ ],
    long strategy,
    long do_singletons,
    long Cdeg [ ],
    long Cperm [ ],
    long Rdeg [ ],
    long Rperm [ ],
    long InvRperm [ ],
    long *p_n1,
    long *p_n1c,
    long *p_n1r,
    long *p_nempty_col,
    long *p_nempty_row,
    long *p_is_sym,
    long *p_max_rdeg,
    long Rp [ ],
    long Ri [ ],
    long W [ ],
    long Next [ ]
)
{
    long n1, s, col, row, p, p1, p2, cdeg, last_row, is_sym, k,
 nempty_row, nempty_col, max_cdeg, max_rdeg, n1c, n1r ;
    if (Ap [0] != 0 || Ap [n_col] < 0)
    {
 return ((-8)) ;
    }
    for (row = 0 ; row < n_row ; row++)
    {
 Rdeg [row] = 0 ;
    }
    for (col = 0 ; col < n_col ; col++)
    {
 p1 = Ap [col] ;
 p2 = Ap [col+1] ;
 cdeg = p2 - p1 ;
 if (cdeg < 0)
 {
     return ((-8)) ;
 }
 last_row = (-1) ;
 for (p = p1 ; p < p2 ; p++)
 {
     row = Ai [p] ;
     if (row <= last_row || row >= n_row)
     {
  return ((-8)) ;
     }
     Rdeg [row]++ ;
     last_row = row ;
 }
 Cdeg [col] = cdeg ;
    }
    if (!do_singletons)
    {
        n1 = 0 ;
        n1r = 0 ;
        n1c = 0 ;
    }
    else if (Quser != (long *) ((void *)0))
    {
 if (strategy == 1)
 {
     n1 = find_user_singletons (n_row, n_col, Ap, Ai, Quser,
      Cdeg, Rdeg, Cperm, Rperm, &n1r, &n1c, Rp, Ri, W) ;
 }
 else
 {
     n1 = 0 ;
     n1r = 0 ;
     n1c = 0 ;
 }
    }
    else
    {
 n1 = find_any_singletons (n_row, n_col, Ap, Ai,
  Cdeg, Rdeg, Cperm, Rperm, &n1r, &n1c, Rp, Ri, W, Next) ;
    }
    nempty_col = finish_permutation (n1, n_col, Cdeg, Quser, Cperm, &max_cdeg) ;
    if (Quser != (long *) ((void *)0) && strategy == 3)
    {
 ;
 nempty_row = finish_permutation (n1, n_row, Rdeg, Quser, Rperm,
     &max_rdeg) ;
    }
    else
    {
 nempty_row = finish_permutation (n1, n_row, Rdeg, (long *) ((void *)0), Rperm,
     &max_rdeg) ;
    }
    for (k = 0 ; k < n_row ; k++)
    {
 ;
 InvRperm [Rperm [k]] = k ;
    }
    if (n_row == n_col && nempty_row == nempty_col)
    {
 is_sym = (1) ;
 for (s = n1 ; is_sym &&
            s < n_col - nempty_col ; s++)
 {
     if (Cperm [s] != Rperm [s])
     {
  is_sym = (0) ;
     }
 }
    }
    else
    {
 is_sym = (0) ;
    }
    ;
    ;
    ;
    *p_n1 = n1 ;
    *p_n1r = n1r ;
    *p_n1c = n1c ;
    *p_is_sym = is_sym ;
    *p_nempty_col = nempty_col ;
    *p_nempty_row = nempty_row ;
    *p_max_rdeg = max_rdeg ;
    return ((0)) ;
}

canonical_original_code:
long umf_l_singletons(long n_row, long n_col, long Ap[], long Ai[], long Quser[], long strategy, long do_singletons, long Cdeg[], long Cperm[], long Rdeg[], long Rperm[], long InvRperm[], long *p_n1, long *p_n1c, long *p_n1r, long *p_nempty_col, long *p_nempty_row, long *p_is_sym, long *p_max_rdeg, long Rp[], long Ri[], long W[], long Next[])
{
    long n1; long s; long col; long row; long p; long p1; long p2; long cdeg; long last_row; long is_sym; long k; long nempty_row; long nempty_col; long max_cdeg; long max_rdeg; long n1c; long n1r;
    if (Ap [0] != 0 || Ap [n_col] < 0)
    {
 return ((-8)) ;
    }
    for (row = 0 ; row < n_row ; row++)
    {
 Rdeg [row] = 0 ;
    }
    for (col = 0 ; col < n_col ; col++)
    {
 p1 = Ap [col] ;
 p2 = Ap [col+1] ;
 cdeg = p2 - p1 ;
 if (cdeg < 0)
 {
     return ((-8)) ;
 }
 last_row = (-1) ;
 for (p = p1 ; p < p2 ; p++)
 {
     row = Ai [p] ;
     if (row <= last_row || row >= n_row)
     {
  return ((-8)) ;
     }
     Rdeg [row]++ ;
     last_row = row ;
 }
 Cdeg [col] = cdeg ;
    }
    if (!do_singletons)
    {
        n1 = 0 ;
        n1r = 0 ;
        n1c = 0 ;
    }
    else if (Quser != (long *) ((void *)0))
    {
 if (strategy == 1)
 {
     n1 = find_user_singletons (n_row, n_col, Ap, Ai, Quser,
      Cdeg, Rdeg, Cperm, Rperm, &n1r, &n1c, Rp, Ri, W) ;
 }
 else
 {
     n1 = 0 ;
     n1r = 0 ;
     n1c = 0 ;
 }
    }
    else
    {
 n1 = find_any_singletons (n_row, n_col, Ap, Ai,
  Cdeg, Rdeg, Cperm, Rperm, &n1r, &n1c, Rp, Ri, W, Next) ;
    }
    nempty_col = finish_permutation (n1, n_col, Cdeg, Quser, Cperm, &max_cdeg) ;
    if (Quser != (long *) ((void *)0) && strategy == 3)
    {
 ;
 nempty_row = finish_permutation (n1, n_row, Rdeg, Quser, Rperm,
     &max_rdeg) ;
    }
    else
    {
 nempty_row = finish_permutation (n1, n_row, Rdeg, (long *) ((void *)0), Rperm,
     &max_rdeg) ;
    }
    for (k = 0 ; k < n_row ; k++)
    {
 ;
 InvRperm [Rperm [k]] = k ;
    }
    if (n_row == n_col && nempty_row == nempty_col)
    {
 is_sym = (1) ;
 for (s = n1 ; is_sym &&
            s < n_col - nempty_col ; s++)
 {
     if (Cperm [s] != Rperm [s])
     {
  is_sym = (0) ;
     }
 }
    }
    else
    {
 is_sym = (0) ;
    }
    ;
    ;
    ;
    *p_n1 = n1 ;
    *p_n1r = n1r ;
    *p_n1c = n1c ;
    *p_is_sym = is_sym ;
    *p_nempty_col = nempty_col ;
    *p_nempty_row = nempty_row ;
    *p_max_rdeg = max_rdeg ;
    return ((0)) ;
}

variable_types:
Ap
long []

variable_types:
Ai
long []

variable_types:
Quser
long []

variable_types: strategy long

variable_types:
Cdeg
long []

variable_types:
Cperm
long []

variable_types:
Rdeg
long []

variable_types:
Rperm
long []

variable_types:
InvRperm
long []

variable_types:
Rp
long []

variable_types:
Ri
long []

variable_types:
W
long []

variable_types:
Next
long []

variable_types: s long

variable_types: col long

variable_types: row long

variable_types: p long

variable_types: cdeg long

variable_types: k long

return_type: long


original_code:
static void create_row_form
(
    long n_row,
    long n_col,
    const long Ap [ ],
    const long Ai [ ],
    long Rdeg [ ],
    long Rp [ ],
    long Ri [ ],
    long W [ ]
)
{
    long row, col, p, p2 ;
    Rp [0] = 0 ;
    W [0] = 0 ;
    for (row = 0 ; row < n_row ; row++)
    {
 Rp [row+1] = Rp [row] + Rdeg [row] ;
 W [row] = Rp [row] ;
    }
    for (col = 0 ; col < n_col ; col++)
    {
 p2 = Ap [col+1] ;
 for (p = Ap [col] ; p < p2 ; p++)
 {
     Ri [W [Ai [p]]++] = col ;
 }
    }
}

canonical_original_code:
static void create_row_form(long n_row, long n_col, long Ap[], long Ai[], long Rdeg[], long Rp[], long Ri[], long W[])
{
    long row; long col; long p; long p2;
    Rp [0] = 0 ;
    W [0] = 0 ;
    for (row = 0 ; row < n_row ; row++)
    {
 Rp [row+1] = Rp [row] + Rdeg [row] ;
 W [row] = Rp [row] ;
    }
    for (col = 0 ; col < n_col ; col++)
    {
 p2 = Ap [col+1] ;
 for (p = Ap [col] ; p < p2 ; p++)
 {
     Ri [W [Ai [p]]++] = col ;
 }
    }
}

variable_types:
Ap
long []

variable_types:
Ai
long []


original_code:
static int order_singletons
(
    long k,
    long head,
    long tail,
    long Next [ ],
    long Xdeg [ ], long Xperm [ ], const long Xp [ ], const long Xi [ ],
    long Ydeg [ ], long Yperm [ ], const long Yp [ ], const long Yi [ ]
)
{
    long xpivot, x, y, ypivot, p, p2, deg ;
    while (head != (-1))
    {
 xpivot = head ;
 ;
 head = Next [xpivot] ;
 if (head == (-1)) tail = (-1) ;
 ;
 if (Xdeg [xpivot] != 1)
 {
     ;
     continue ;
 }
 ypivot = (-1) ;
 p2 = Xp [xpivot+1] ;
 for (p = Xp [xpivot] ; p < p2 ; p++)
 {
     y = Xi [p] ;
     ;
     if (Ydeg [y] >= 0)
     {
  ypivot = y ;
  break ;
     }
 }
 ;
 ;
 ;
 ;
 ;
 ;
 p2 = Yp [ypivot+1] ;
 for (p = Yp [ypivot] ; p < p2 ; p++)
 {
     x = Yi [p] ;
     ;
     if (Xdeg [x] < 0) continue ;
     ;
     if (x == xpivot) continue ;
     deg = --(Xdeg [x]) ;
     ;
     if (deg == 1)
     {
  Next [x] = (-1) ;
  if (head == (-1))
  {
      head = x ;
  }
  else
  {
      ;
      Next [tail] = x ;
  }
  tail = x ;
  ;
     }
 }
 Xdeg [xpivot] = (-(1)-2) ;
 Ydeg [ypivot] = (-(Ydeg [ypivot])-2) ;
 Xperm [k] = xpivot ;
 Yperm [k] = ypivot ;
 k++ ;
    }
    return (k) ;
}

canonical_original_code:
static int order_singletons(long k, long head, long tail, long Next[], long Xdeg[], long Xperm[], long Xp[], long Xi[], long Ydeg[], long Yperm[], long Yp[], long Yi[])
{
    long xpivot; long x; long y; long ypivot; long p; long p2; long deg;
    while (head != (-1))
    {
 xpivot = head ;
 ;
 head = Next [xpivot] ;
 if (head == (-1)) tail = (-1) ;
 ;
 if (Xdeg [xpivot] != 1)
 {
     ;
     continue ;
 }
 ypivot = (-1) ;
 p2 = Xp [xpivot+1] ;
 for (p = Xp [xpivot] ; p < p2 ; p++)
 {
     y = Xi [p] ;
     ;
     if (Ydeg [y] >= 0)
     {
  ypivot = y ;
  break ;
     }
 }
 ;
 ;
 ;
 ;
 ;
 ;
 p2 = Yp [ypivot+1] ;
 for (p = Yp [ypivot] ; p < p2 ; p++)
 {
     x = Yi [p] ;
     ;
     if (Xdeg [x] < 0) continue ;
     ;
     if (x == xpivot) continue ;
     deg = --(Xdeg [x]) ;
     ;
     if (deg == 1)
     {
  Next [x] = (-1) ;
  if (head == (-1))
  {
      head = x ;
  }
  else
  {
      ;
      Next [tail] = x ;
  }
  tail = x ;
  ;
     }
 }
 Xdeg [xpivot] = (-(1)-2) ;
 Ydeg [ypivot] = (-(Ydeg [ypivot])-2) ;
 Xperm [k] = xpivot ;
 Yperm [k] = ypivot ;
 k++ ;
    }
    return (k) ;
}

variable_types: head long

variable_types: tail long

variable_types:
Xdeg
long []

variable_types:
Xperm
long []

variable_types:
Xp
long []

variable_types:
Xi
long []

variable_types:
Ydeg
long []

variable_types:
Yperm
long []

variable_types:
Yp
long []

variable_types:
Yi
long []

variable_types: xpivot long

variable_types: x long

variable_types: y long

variable_types: ypivot long

variable_types: deg long


original_code:
static long find_any_singletons
(
    long n_row,
    long n_col,
    const long Ap [ ],
    const long Ai [ ],
    long Cdeg [ ],
    long Rdeg [ ],
    long Cperm [ ],
    long Rperm [ ],
    long *p_n1r,
    long *p_n1c,
    long Rp [ ],
    long Ri [ ],
    long W [ ],
    long Next [ ]
)
{
    long n1, col, row, row_form, head, tail, n1r, n1c ;
    n1 = 0 ;
    n1r = 0 ;
    n1c = 0 ;
    row_form = (0) ;
    head = (-1) ;
    tail = (-1) ;
    for (col = n_col-1 ; col >= 0 ; col--)
    {
 if (Cdeg [col] == 1)
 {
     if (head == (-1)) tail = col ;
     Next [col] = head ;
     head = col ;
     ;
 }
    }
    if (head != (-1))
    {
 create_row_form (n_row, n_col, Ap, Ai, Rdeg, Rp, Ri, W) ;
 row_form = (1) ;
 n1 = order_singletons (0, head, tail, Next,
  Cdeg, Cperm, Ap, Ai,
  Rdeg, Rperm, Rp, Ri
  ) ;
 n1c = n1 ;
    }
    head = (-1) ;
    tail = (-1) ;
    for (row = n_row-1 ; row >= 0 ; row--)
    {
 if (Rdeg [row] == 1)
 {
     if (head == (-1)) tail = row ;
     Next [row] = head ;
     head = row ;
     ;
 }
    }
    if (head != (-1))
    {
 if (!row_form)
 {
     create_row_form (n_row, n_col, Ap, Ai, Rdeg, Rp, Ri, W) ;
 }
 n1 = order_singletons (n1, head, tail, Next,
  Rdeg, Rperm, Rp, Ri,
  Cdeg, Cperm, Ap, Ai
  ) ;
 n1r = n1 - n1c ;
    }
    ;
    *p_n1r = n1r ;
    *p_n1c = n1c ;
    return (n1) ;
}

canonical_original_code:
static long find_any_singletons(long n_row, long n_col, long Ap[], long Ai[], long Cdeg[], long Rdeg[], long Cperm[], long Rperm[], long *p_n1r, long *p_n1c, long Rp[], long Ri[], long W[], long Next[])
{
    long n1; long col; long row; long row_form; long head; long tail; long n1r; long n1c;
    n1 = 0 ;
    n1r = 0 ;
    n1c = 0 ;
    row_form = (0) ;
    head = (-1) ;
    tail = (-1) ;
    for (col = n_col-1 ; col >= 0 ; col--)
    {
 if (Cdeg [col] == 1)
 {
     if (head == (-1)) tail = col ;
     Next [col] = head ;
     head = col ;
     ;
 }
    }
    if (head != (-1))
    {
 create_row_form (n_row, n_col, Ap, Ai, Rdeg, Rp, Ri, W) ;
 row_form = (1) ;
 n1 = order_singletons (0, head, tail, Next,
  Cdeg, Cperm, Ap, Ai,
  Rdeg, Rperm, Rp, Ri
  ) ;
 n1c = n1 ;
    }
    head = (-1) ;
    tail = (-1) ;
    for (row = n_row-1 ; row >= 0 ; row--)
    {
 if (Rdeg [row] == 1)
 {
     if (head == (-1)) tail = row ;
     Next [row] = head ;
     head = row ;
     ;
 }
    }
    if (head != (-1))
    {
 if (!row_form)
 {
     create_row_form (n_row, n_col, Ap, Ai, Rdeg, Rp, Ri, W) ;
 }
 n1 = order_singletons (n1, head, tail, Next,
  Rdeg, Rperm, Rp, Ri,
  Cdeg, Cperm, Ap, Ai
  ) ;
 n1r = n1 - n1c ;
    }
    ;
    *p_n1r = n1r ;
    *p_n1c = n1c ;
    return (n1) ;
}

variable_types:
Ap
long []

variable_types:
Cdeg
long []

variable_types:
Rdeg
long []

variable_types:
Cperm
long []

variable_types:
Rperm
long []

variable_types:
Rp
long []

variable_types:
Ri
long []

variable_types:
W
long []

variable_types:
Next
long []

variable_types: col long

variable_types: row long


original_code:
static long find_user_singletons
(
    long n_row,
    long n_col,
    const long Ap [ ],
    const long Ai [ ],
    const long Quser [ ],
    long Cdeg [ ],
    long Rdeg [ ],
    long Cperm [ ],
    long Rperm [ ],
    long *p_n1r,
    long *p_n1c,
    long Rp [ ],
    long Ri [ ],
    long W [ ]
)
{
    long n1, col, row, p, p2, pivcol, pivrow, found, k, n1r, n1c ;
    n1 = 0 ;
    n1r = 0 ;
    n1c = 0 ;
    *p_n1r = 0 ;
    *p_n1c = 0 ;
    pivcol = Quser [0] ;
    found = (Cdeg [pivcol] == 1) ;
    ;
    if (!found)
    {
 for (p = Ap [pivcol] ; p < Ap [pivcol+1] ; p++)
 {
     if (Rdeg [Ai [p]] == 1)
     {
  ;
  found = (1) ;
  break ;
     }
 }
    }
    if (!found)
    {
 return (0) ;
    }
    create_row_form (n_row, n_col, Ap, Ai, Rdeg, Rp, Ri, W) ;
    n1 = 0 ;
    for (k = 0 ; k < n_col ; k++)
    {
 pivcol = Quser [k] ;
 pivrow = (-1) ;
 found = (Cdeg [pivcol] == 1) ;
 if (found)
 {
     ;
     p2 = Ap [pivcol+1] ;
     for (p = Ap [pivcol] ; p < p2 ; p++)
     {
  row = Ai [p] ;
  ;
  if (Rdeg [row] >= 0)
  {
      pivrow = row ;
      break ;
  }
     }
     ;
     ;
     ;
     ;
     ;
     ;
     p2 = Rp [pivrow+1] ;
     for (p = Rp [pivrow] ; p < p2 ; p++)
     {
  col = Ri [p] ;
  ;
  if (Cdeg [col] < 0) continue ;
  ;
  Cdeg [col]-- ;
  ;
     }
     Cdeg [pivcol] = (-(1)-2) ;
     Rdeg [pivrow] = (-(Rdeg [pivrow])-2) ;
     n1c++ ;
 }
 else
 {
     p2 = Ap [pivcol+1] ;
     for (p = Ap [pivcol] ; p < p2 ; p++)
     {
  pivrow = Ai [p] ;
  if (Rdeg [pivrow] == 1)
  {
      ;
      found = (1) ;
      break ;
  }
     }
     if (!found)
     {
  ;
  break ;
     }
     ;
     ;
     ;
     ;
     ;
     p2 = Ap [pivcol+1] ;
     for (p = Ap [pivcol] ; p < p2 ; p++)
     {
  row = Ai [p] ;
  ;
  if (Rdeg [row] < 0) continue ;
  ;
  Rdeg [row]-- ;
  ;
     }
     Cdeg [pivcol] = (-(Cdeg [pivcol])-2) ;
     Rdeg [pivrow] = (-(1)-2) ;
     n1r++ ;
 }
 Cperm [k] = pivcol ;
 Rperm [k] = pivrow ;
 n1++ ;
    }
    ;
    ;
    *p_n1r = n1r ;
    *p_n1c = n1c ;
    return (n1) ;
}

canonical_original_code:
static long find_user_singletons(long n_row, long n_col, long Ap[], long Ai[], long Quser[], long Cdeg[], long Rdeg[], long Cperm[], long Rperm[], long *p_n1r, long *p_n1c, long Rp[], long Ri[], long W[])
{
    long n1; long col; long row; long p; long p2; long pivcol; long pivrow; long found; long k; long n1r; long n1c;
    n1 = 0 ;
    n1r = 0 ;
    n1c = 0 ;
    *p_n1r = 0 ;
    *p_n1c = 0 ;
    pivcol = Quser [0] ;
    found = (Cdeg [pivcol] == 1) ;
    ;
    if (!found)
    {
 for (p = Ap [pivcol] ; p < Ap [pivcol+1] ; p++)
 {
     if (Rdeg [Ai [p]] == 1)
     {
  ;
  found = (1) ;
  break ;
     }
 }
    }
    if (!found)
    {
 return (0) ;
    }
    create_row_form (n_row, n_col, Ap, Ai, Rdeg, Rp, Ri, W) ;
    n1 = 0 ;
    for (k = 0 ; k < n_col ; k++)
    {
 pivcol = Quser [k] ;
 pivrow = (-1) ;
 found = (Cdeg [pivcol] == 1) ;
 if (found)
 {
     ;
     p2 = Ap [pivcol+1] ;
     for (p = Ap [pivcol] ; p < p2 ; p++)
     {
  row = Ai [p] ;
  ;
  if (Rdeg [row] >= 0)
  {
      pivrow = row ;
      break ;
  }
     }
     ;
     ;
     ;
     ;
     ;
     ;
     p2 = Rp [pivrow+1] ;
     for (p = Rp [pivrow] ; p < p2 ; p++)
     {
  col = Ri [p] ;
  ;
  if (Cdeg [col] < 0) continue ;
  ;
  Cdeg [col]-- ;
  ;
     }
     Cdeg [pivcol] = (-(1)-2) ;
     Rdeg [pivrow] = (-(Rdeg [pivrow])-2) ;
     n1c++ ;
 }
 else
 {
     p2 = Ap [pivcol+1] ;
     for (p = Ap [pivcol] ; p < p2 ; p++)
     {
  pivrow = Ai [p] ;
  if (Rdeg [pivrow] == 1)
  {
      ;
      found = (1) ;
      break ;
  }
     }
     if (!found)
     {
  ;
  break ;
     }
     ;
     ;
     ;
     ;
     ;
     p2 = Ap [pivcol+1] ;
     for (p = Ap [pivcol] ; p < p2 ; p++)
     {
  row = Ai [p] ;
  ;
  if (Rdeg [row] < 0) continue ;
  ;
  Rdeg [row]-- ;
  ;
     }
     Cdeg [pivcol] = (-(Cdeg [pivcol])-2) ;
     Rdeg [pivrow] = (-(1)-2) ;
     n1r++ ;
 }
 Cperm [k] = pivcol ;
 Rperm [k] = pivrow ;
 n1++ ;
    }
    ;
    ;
    *p_n1r = n1r ;
    *p_n1c = n1c ;
    return (n1) ;
}

variable_types:
Ai
long []

variable_types:
Quser
long []

variable_types: p long

variable_types: pivcol long

variable_types: pivrow long

variable_types: found long

variable_types: k long


original_code:
static long finish_permutation
(
    long n1,
    long nx,
    long Xdeg [ ],
    const long Xuser [ ],
    long Xperm [ ],
    long *p_max_deg
)
{
    long nempty, x, deg, s, max_deg, k ;
    nempty = 0 ;
    s = n1 ;
    max_deg = 0 ;
    ;
    for (k = 0 ; k < nx ; k++)
    {
 x = (Xuser != (long *) ((void *)0)) ? Xuser [k] : k ;
 ;
 deg = Xdeg [x] ;
 if (deg == 0)
 {
     ;
     ;
     nempty++ ;
     Xperm [nx - nempty] = x ;
 }
 else if (deg > 0)
 {
     ;
     Xperm [s++] = x ;
     max_deg = (((max_deg) > (deg)) ? (max_deg) : (deg)) ;
 }
 else
 {
     Xdeg [x] = (-(deg)-2) ;
 }
    }
    ;
    *p_max_deg = max_deg ;
    return (nempty) ;
}

canonical_original_code:
static long finish_permutation(long n1, long nx, long Xdeg[], long Xuser[], long Xperm[], long *p_max_deg)
{
    long nempty; long x; long deg; long s; long max_deg; long k;
    nempty = 0 ;
    s = n1 ;
    max_deg = 0 ;
    ;
    for (k = 0 ; k < nx ; k++)
    {
 x = (Xuser != (long *) ((void *)0)) ? Xuser [k] : k ;
 ;
 deg = Xdeg [x] ;
 if (deg == 0)
 {
     ;
     ;
     nempty++ ;
     Xperm [nx - nempty] = x ;
 }
 else if (deg > 0)
 {
     ;
     Xperm [s++] = x ;
     max_deg = (((max_deg) > (deg)) ? (max_deg) : (deg)) ;
 }
 else
 {
     Xdeg [x] = (-(deg)-2) ;
 }
    }
    ;
    *p_max_deg = max_deg ;
    return (nempty) ;
}

variable_types: nx long

variable_types:
Xdeg
long []

variable_types:
Xuser
long []

variable_types:
Xperm
long []

variable_types: nempty long

variable_types: x long

variable_types: deg long

variable_types: s long


original_code:
long umfpack_zl_col_to_triplet
(
    long n_col,
    const long Ap [ ],
    long Tj [ ]
)
{
    long nz, j, p, p1, p2, length ;
    if (!Ap || !Tj)
    {
 return ((-5)) ;
    }
    if (n_col <= 0)
    {
 return ((-6)) ;
    }
    if (Ap [0] != 0)
    {
 return ((-8)) ;
    }
    nz = Ap [n_col] ;
    if (nz < 0)
    {
 return ((-8)) ;
    }
    for (j = 0 ; j < n_col ; j++)
    {
 p1 = Ap [j] ;
 p2 = Ap [j+1] ;
 length = p2 - p1 ;
 if (length < 0 || p2 > nz)
 {
     return ((-8)) ;
 }
 for (p = p1 ; p < p2 ; p++)
 {
     Tj [p] = j ;
 }
    }
    return ((0)) ;
}

canonical_original_code:
long umfpack_zl_col_to_triplet(long n_col, long Ap[], long Tj[])
{
    long nz; long j; long p; long p1; long p2; long length;
    if (!Ap || !Tj)
    {
 return ((-5)) ;
    }
    if (n_col <= 0)
    {
 return ((-6)) ;
    }
    if (Ap [0] != 0)
    {
 return ((-8)) ;
    }
    nz = Ap [n_col] ;
    if (nz < 0)
    {
 return ((-8)) ;
    }
    for (j = 0 ; j < n_col ; j++)
    {
 p1 = Ap [j] ;
 p2 = Ap [j+1] ;
 length = p2 - p1 ;
 if (length < 0 || p2 > nz)
 {
     return ((-8)) ;
 }
 for (p = p1 ; p < p2 ; p++)
 {
     Tj [p] = j ;
 }
    }
    return ((0)) ;
}

variable_types:
Ap
long []

variable_types:
Tj
long []

variable_types: nz long

variable_types: j long

variable_types: length long


original_code:
int cholmod_rowdel_mark
(
    size_t kdel,
    cholmod_sparse *R,
    double yk [2],
    int *colmark,
    cholmod_factor *L,
    cholmod_dense *X,
    cholmod_dense *DeltaB,
    cholmod_common *Common
)
{
    double dk, sqrt_dk, xk, dj, fl ;
    double *Lx, *Cx, *W, *Xx, *Nx ;
    int *Li, *Lp, *Lnz, *Ci, *Rj, *Rp, *Iwork ;
    cholmod_sparse *C, Cmatrix ;
    int j, p, pend, kk, lnz, n, Cp [2], do_solve, do_update, left, k,
 right, middle, i, klast, given_row, rnz ;
    size_t s ;
    int ok = 1 ;
    { if (Common == ((void *)0)) { return (0) ; } if (Common->itype != 0 || Common->dtype != 0) { Common->status = (-4) ; return (0) ; } } ;
    { if ((L) == ((void *)0)) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 130, "argument missing", Common) ; } return (0) ; } } ;
    { if ((L)->xtype < (0) || (L)->xtype > (1) || ((L)->xtype != 0 && ((L)->x) == ((void *)0)) || ((L)->xtype == 3 && ((L)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 131, "invalid xtype", Common) ; } return (0) ; } } ;
    n = L->n ;
    k = kdel ;
    if (kdel >= L->n || k < 0)
    {
 cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 136, "k invalid", Common) ;
 return (0) ;
    }
    if (R == ((void *)0))
    {
 Rj = ((void *)0) ;
 rnz = (-1) ;
    }
    else
    {
 { if ((R)->xtype < (0) || (R)->xtype > (3) || ((R)->xtype != 0 && ((R)->x) == ((void *)0)) || ((R)->xtype == 3 && ((R)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 146, "invalid xtype", Common) ; } return (0) ; } } ;
 if (R->ncol != 1 || R->nrow != L->n)
 {
     cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 149, "R invalid", Common) ;
     return (0) ;
 }
 Rj = R->i ;
 Rp = R->p ;
 rnz = Rp [1] ;
    }
    do_solve = (X != ((void *)0)) && (DeltaB != ((void *)0)) ;
    if (do_solve)
    {
 { if ((X)->xtype < (1) || (X)->xtype > (1) || ((X)->xtype != 0 && ((X)->x) == ((void *)0)) || ((X)->xtype == 3 && ((X)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 159, "invalid xtype", Common) ; } return (0) ; } } ;
 { if ((DeltaB)->xtype < (1) || (DeltaB)->xtype > (1) || ((DeltaB)->xtype != 0 && ((DeltaB)->x) == ((void *)0)) || ((DeltaB)->xtype == 3 && ((DeltaB)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 160, "invalid xtype", Common) ; } return (0) ; } } ;
 Xx = X->x ;
 Nx = DeltaB->x ;
 if (X->nrow != L->n || X->ncol != 1 || DeltaB->nrow != L->n ||
  DeltaB->ncol != 1 || Xx == ((void *)0) || Nx == ((void *)0))
 {
     cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 166, "X and/or DeltaB invalid", Common) ;
     return (0) ;
 }
    }
    else
    {
 Xx = ((void *)0) ;
 Nx = ((void *)0) ;
    }
    Common->status = 0 ;
    s = cholmod_mult_size_t (n, 2, &ok) ;
    if (!ok)
    {
 cholmod_error ((-3), "../Modify/cholmod_rowdel.c", 185, "problem too large", Common) ;
 return (0) ;
    }
    cholmod_allocate_work (n, s, s, Common) ;
    if (Common->status < 0)
    {
 return (0) ;
    }
    ;
    if (L->xtype == 0 || L->is_super || L->is_ll)
    {
 cholmod_change_factor (1, 0, 0, 0, 0, L,
  Common) ;
 if (Common->status < 0)
 {
     return (0) ;
 }
    }
    Lp = L->p ;
    Lnz = L->nz ;
    Li = L->i ;
    Lx = L->x ;
    ;
    W = Common->Xwork ;
    Cx = W + n ;
    Iwork = Common->Iwork ;
    Ci = Iwork + n ;
    given_row = (rnz >= 0) ;
    klast = given_row ? rnz : k ;
    ;
    for (kk = 0 ; kk < klast ; kk++)
    {
 j = given_row ? (Rj [kk]) : (kk) ;
 if (j < 0 || j >= k)
 {
     cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 251, "R invalid", Common) ;
     return (0) ;
 }
 ;
 lnz = Lnz [j] ;
 dj = Lx [Lp [j]] ;
 ;
 if (lnz > 1)
 {
     left = Lp [j] ;
     pend = left + lnz ;
     right = pend - 1 ;
     i = Li [right] ;
     if (i < k)
     {
  continue ;
     }
     else if (i == k)
     {
  if (do_solve)
  {
      Xx [j] -= yk [0] * dj * Lx [right] ;
  }
  Lx [right] = 0 ;
     }
     else
     {
  ;
  while (left < right)
  {
      middle = (left + right) / 2 ;
      ;
      if (k > Li [middle])
      {
   left = middle + 1 ;
      }
      else
      {
   right = middle ;
      }
  }
  ;
  if (k == Li [left])
  {
      if (do_solve)
      {
   Xx [j] -= yk [0] * dj * Lx [left] ;
      }
      Lx [left] = 0 ;
  }
     }
 }
    }
    lnz = Lnz [k] - 1 ;
    ;
    ;
    p = Lp [k] ;
    pend = p + lnz + 1 ;
    dk = Lx [p] ;
    Lx [p++] = 1 ;
    ;
    ok = 1 ;
    fl = 0 ;
    if (lnz > 0)
    {
 if (do_solve)
 {
     xk = Xx [k] - yk [0] * dk ;
     for ( ; p < pend ; p++)
     {
  Nx [Li [p]] += Lx [p] * xk ;
     }
 }
 do_update = ((dk) > 0.) ;
 if (!do_update)
 {
     dk = -dk ;
 }
 sqrt_dk = sqrt (dk) ;
 p = Lp [k] + 1 ;
 for (kk = 0 ; kk < lnz ; kk++, p++)
 {
     Ci [kk] = Li [p] ;
     Cx [kk] = Lx [p] * sqrt_dk ;
     Lx [p] = 0 ;
 }
 fl = lnz + 1 ;
 C = &Cmatrix ;
 C->nrow = n ;
 C->ncol = 1 ;
 C->nzmax = lnz ;
 C->sorted = 1 ;
 C->packed = 1 ;
 C->p = Cp ;
 C->i = Ci ;
 C->x = Cx ;
 C->nz = ((void *)0) ;
 C->itype = L->itype ;
 C->xtype = L->xtype ;
 C->dtype = L->dtype ;
 C->z = ((void *)0) ;
 C->stype = 0 ;
 Cp [0] = 0 ;
 Cp [1] = lnz ;
 ok = cholmod_updown_mark (do_update ? (1) : (0), C, colmark,
  L, X, DeltaB, Common) ;
 for (kk = 0 ; kk < lnz ; kk++)
 {
     Cx [kk] = 0 ;
 }
    }
    Common->modfl += fl ;
    if (do_solve)
    {
 Xx [k] = yk [0] ;
    }
    ;
    ;
    return (ok) ;
}

canonical_original_code:
int cholmod_rowdel_mark(unsigned long kdel, struct cholmod_sparse_struct *R, double yk[2], int *colmark, struct cholmod_factor_struct *L, struct cholmod_dense_struct *X, struct cholmod_dense_struct *DeltaB, struct cholmod_common_struct *Common)
{
    double dk; double sqrt_dk; double xk; double dj; double fl;
    double *Lx; double *Cx; double *W; double *Xx; double *Nx;
    int *Li; int *Lp; int *Lnz; int *Ci; int *Rj; int *Rp; int *Iwork;
    struct cholmod_sparse_struct *C; struct cholmod_sparse_struct Cmatrix;
    int j; int p; int pend; int kk; int lnz; int n; int Cp[2]; int do_solve; int do_update; int left; int k; int right; int middle; int i; int klast; int given_row; int rnz;
    unsigned long s;
    int ok = 1;
    { if (Common == ((void *)0)) { return (0) ; } if (Common->itype != 0 || Common->dtype != 0) { Common->status = (-4) ; return (0) ; } } ;
    { if ((L) == ((void *)0)) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 130, "argument missing", Common) ; } return (0) ; } } ;
    { if ((L)->xtype < (0) || (L)->xtype > (1) || ((L)->xtype != 0 && ((L)->x) == ((void *)0)) || ((L)->xtype == 3 && ((L)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 131, "invalid xtype", Common) ; } return (0) ; } } ;
    n = L->n ;
    k = kdel ;
    if (kdel >= L->n || k < 0)
    {
 cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 136, "k invalid", Common) ;
 return (0) ;
    }
    if (R == ((void *)0))
    {
 Rj = ((void *)0) ;
 rnz = (-1) ;
    }
    else
    {
 { if ((R)->xtype < (0) || (R)->xtype > (3) || ((R)->xtype != 0 && ((R)->x) == ((void *)0)) || ((R)->xtype == 3 && ((R)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 146, "invalid xtype", Common) ; } return (0) ; } } ;
 if (R->ncol != 1 || R->nrow != L->n)
 {
     cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 149, "R invalid", Common) ;
     return (0) ;
 }
 Rj = R->i ;
 Rp = R->p ;
 rnz = Rp [1] ;
    }
    do_solve = (X != ((void *)0)) && (DeltaB != ((void *)0)) ;
    if (do_solve)
    {
 { if ((X)->xtype < (1) || (X)->xtype > (1) || ((X)->xtype != 0 && ((X)->x) == ((void *)0)) || ((X)->xtype == 3 && ((X)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 159, "invalid xtype", Common) ; } return (0) ; } } ;
 { if ((DeltaB)->xtype < (1) || (DeltaB)->xtype > (1) || ((DeltaB)->xtype != 0 && ((DeltaB)->x) == ((void *)0)) || ((DeltaB)->xtype == 3 && ((DeltaB)->z) == ((void *)0))) { if (Common->status != (-2)) { cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 160, "invalid xtype", Common) ; } return (0) ; } } ;
 Xx = X->x ;
 Nx = DeltaB->x ;
 if (X->nrow != L->n || X->ncol != 1 || DeltaB->nrow != L->n ||
  DeltaB->ncol != 1 || Xx == ((void *)0) || Nx == ((void *)0))
 {
     cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 166, "X and/or DeltaB invalid", Common) ;
     return (0) ;
 }
    }
    else
    {
 Xx = ((void *)0) ;
 Nx = ((void *)0) ;
    }
    Common->status = 0 ;
    s = cholmod_mult_size_t (n, 2, &ok) ;
    if (!ok)
    {
 cholmod_error ((-3), "../Modify/cholmod_rowdel.c", 185, "problem too large", Common) ;
 return (0) ;
    }
    cholmod_allocate_work (n, s, s, Common) ;
    if (Common->status < 0)
    {
 return (0) ;
    }
    ;
    if (L->xtype == 0 || L->is_super || L->is_ll)
    {
 cholmod_change_factor (1, 0, 0, 0, 0, L,
  Common) ;
 if (Common->status < 0)
 {
     return (0) ;
 }
    }
    Lp = L->p ;
    Lnz = L->nz ;
    Li = L->i ;
    Lx = L->x ;
    ;
    W = Common->Xwork ;
    Cx = W + n ;
    Iwork = Common->Iwork ;
    Ci = Iwork + n ;
    given_row = (rnz >= 0) ;
    klast = given_row ? rnz : k ;
    ;
    for (kk = 0 ; kk < klast ; kk++)
    {
 j = given_row ? (Rj [kk]) : (kk) ;
 if (j < 0 || j >= k)
 {
     cholmod_error ((-4), "../Modify/cholmod_rowdel.c", 251, "R invalid", Common) ;
     return (0) ;
 }
 ;
 lnz = Lnz [j] ;
 dj = Lx [Lp [j]] ;
 ;
 if (lnz > 1)
 {
     left = Lp [j] ;
     pend = left + lnz ;
     right = pend - 1 ;
     i = Li [right] ;
     if (i < k)
     {
  continue ;
     }
     else if (i == k)
     {
  if (do_solve)
  {
      Xx [j] -= yk [0] * dj * Lx [right] ;
  }
  Lx [right] = 0 ;
     }
     else
     {
  ;
  while (left < right)
  {
      middle = (left + right) / 2 ;
      ;
      if (k > Li [middle])
      {
   left = middle + 1 ;
      }
      else
      {
   right = middle ;
      }
  }
  ;
  if (k == Li [left])
  {
      if (do_solve)
      {
   Xx [j] -= yk [0] * dj * Lx [left] ;
      }
      Lx [left] = 0 ;
  }
     }
 }
    }
    lnz = Lnz [k] - 1 ;
    ;
    ;
    p = Lp [k] ;
    pend = p + lnz + 1 ;
    dk = Lx [p] ;
    Lx [p++] = 1 ;
    ;
    ok = 1 ;
    fl = 0 ;
    if (lnz > 0)
    {
 if (do_solve)
 {
     xk = Xx [k] - yk [0] * dk ;
     for ( ; p < pend ; p++)
     {
  Nx [Li [p]] += Lx [p] * xk ;
     }
 }
 do_update = ((dk) > 0.) ;
 if (!do_update)
 {
     dk = -dk ;
 }
 sqrt_dk = sqrt (dk) ;
 p = Lp [k] + 1 ;
 for (kk = 0 ; kk < lnz ; kk++, p++)
 {
     Ci [kk] = Li [p] ;
     Cx [kk] = Lx [p] * sqrt_dk ;
     Lx [p] = 0 ;
 }
 fl = lnz + 1 ;
 C = &Cmatrix ;
 C->nrow = n ;
 C->ncol = 1 ;
 C->nzmax = lnz ;
 C->sorted = 1 ;
 C->packed = 1 ;
 C->p = Cp ;
 C->i = Ci ;
 C->x = Cx ;
 C->nz = ((void *)0) ;
 C->itype = L->itype ;
 C->xtype = L->xtype ;
 C->dtype = L->dtype ;
 C->z = ((void *)0) ;
 C->stype = 0 ;
 Cp [0] = 0 ;
 Cp [1] = lnz ;
 ok = cholmod_updown_mark (do_update ? (1) : (0), C, colmark,
  L, X, DeltaB, Common) ;
 for (kk = 0 ; kk < lnz ; kk++)
 {
     Cx [kk] = 0 ;
 }
    }
    Common->modfl += fl ;
    if (do_solve)
    {
 Xx [k] = yk [0] ;
    }
    ;
    ;
    return (ok) ;
}

variable_types:
kdel
unsigned long

variable_types: struct cholmod_sparse_struct { unsigned long nrow; unsigned long ncol; unsigned long nzmax; void *p; void *i; void *nz; void *x; void *z; int stype; int itype; int xtype; int dtype; int sorted; int packed; } *

variable_types:
yk
double [2]

variable_types:
colmark
int *

variable_types: struct cholmod_factor_struct { unsigned long n; unsigned long minor; void *Perm; void *ColCount; unsigned long nzmax; void *p; void *i; void *x; void *z; void *nz; void *next; void *prev; unsigned long nsuper; unsigned long ssize; unsigned long xsize; unsigned long maxcsize; unsigned long maxesize; void *super; void *pi; void *px; void *s; int ordering; int is_ll; int is_super; int is_monotonic; int itype; int xtype; int dtype; } *

variable_types: struct cholmod_dense_struct { unsigned long nrow; unsigned long ncol; unsigned long nzmax; unsigned long d; void *x; void *z; int xtype; int dtype; } *

variable_types:
DeltaB
struct cholmod_dense_struct *

variable_types: struct cholmod_common_struct { double dbound; double grow0; double grow1; unsigned long grow2; unsigned long maxrank; double supernodal_switch; int supernodal; int final_asis; int final_super; int final_ll; int final_pack; int final_monotonic; int final_resymbol; double zrelax[3]; unsigned long nrelax[3]; int prefer_zomplex; int prefer_upper; int quick_return_if_not_posdef; int print; int precise; int (*print_function)(char *, ...); int try_catch; void (*error_handler)(int status, char *file, int line, char *message); int nmethods; int current; int selected; struct cholmod_method_struct { double lnz; double fl; double prune_dense; double prune_dense2; double nd_oksep; double other_1[4]; unsigned long nd_small; unsigned long other_2[4]; int aggressive; int order_for_lu; int nd_compress; int nd_camd; int nd_components; int ordering; unsigned long other_3[4]; } method[-1]; int postorder; void *(*malloc_memory)(unsigned long); void *(*realloc_memory)(void *, unsigned long); void (*free_memory)(void *); void *(*calloc_memory)(unsigned long, unsigned long); int (*complex_divide)(double ax, double az, double bx, double bz, double *cx, double *cz); double (*hypotenuse)(double x, double y); double metis_memory; double metis_dswitch; unsigned long metis_nswitch; unsigned long nrow; long mark; unsigned long iworksize; unsigned long xworksize; void *Flag; void *Head; void *Xwork; void *Iwork; int itype; int dtype; int no_workspace_reallocate; int status; double fl; double lnz; double anz; double modfl; unsigned long malloc_count; unsigned long memory_usage; unsigned long memory_inuse; double nrealloc_col; double nrealloc_factor; double ndbounds_hit; double rowfacfl; double aatfl; double other1[10]; double SPQR_xstat[4]; double SPQR_grain; double SPQR_small; long SPQR_istat[10]; long other2[6]; int other3[10]; int prefer_binary; int default_nesdis; int called_nd; int blas_ok; int SPQR_shrink; int SPQR_nthreads; unsigned long other4[16]; void *other5[16]; } *

variable_types: dk double

variable_types: xk double

variable_types: dj double

variable_types: fl double

variable_types:
Lx
double *

variable_types:
Cx
double *

variable_types:
W
double *

variable_types:
Xx
double *

variable_types:
Nx
double *

variable_types:
Li
int *

variable_types:
Lp
int *

variable_types:
Lnz
int *

variable_types:
Ci
int *

variable_types:
Rj
int *

variable_types:
Rp
int *

variable_types:
Iwork
int *

variable_types: j int

variable_types: p int

variable_types: pend int

variable_types: kk int

variable_types: lnz int

variable_types: n int

variable_types:
Cp
int [2]

variable_types: left int

variable_types: k int

variable_types: right int

variable_types: middle int

variable_types: i int

variable_types: klast int

variable_types: rnz int

variable_types:
s
unsigned long

variable_types: ok int

user_defined_types: struct cholmod_common_struct { double dbound; double grow0; double grow1; unsigned long grow2; unsigned long maxrank; double supernodal_switch; int supernodal; int final_asis; int final_super; int final_ll; int final_pack; int final_monotonic; int final_resymbol; double zrelax[3]; unsigned long nrelax[3]; int prefer_zomplex; int prefer_upper; int quick_return_if_not_posdef; int print; int precise; int (*print_function)(char *, ...); int try_catch; void (*error_handler)(int status, char *file, int line, char *message); int nmethods; int current; int selected; struct cholmod_method_struct method[-1]; int postorder; void *(*malloc_memory)(unsigned long); void *(*realloc_memory)(void *, unsigned long); void (*free_memory)(void *); void *(*calloc_memory)(unsigned long, unsigned long); int (*complex_divide)(double ax, double az, double bx, double bz, double *cx, double *cz); double (*hypotenuse)(double x, double y); double metis_memory; double metis_dswitch; unsigned long metis_nswitch; unsigned long nrow; long mark; unsigned long iworksize; unsigned long xworksize; void *Flag; void *Head; void *Xwork; void *Iwork; int itype; int dtype; int no_workspace_reallocate; int status; double fl; double lnz; double anz; double modfl; unsigned long malloc_count; unsigned long memory_usage; unsigned long memory_inuse; double nrealloc_col; double nrealloc_factor; double ndbounds_hit; double rowfacfl; double aatfl; double other1[10]; double SPQR_xstat[4]; double SPQR_grain; double SPQR_small; long SPQR_istat[10]; long other2[6]; int other3[10]; int prefer_binary; int default_nesdis; int called_nd; int blas_ok; int SPQR_shrink; int SPQR_nthreads; unsigned long other4[16]; void *other5[16]; }


decompiled_code:
__int64 __fastcall cholmod_rowdel(unsigned __int64 a1, __int64 a2, unsigned __int64 *a3)
{
__int64 v4; // [rsp+0h] [rbp-20h]
__int64 v5[3]; // [rsp+8h] [rbp-18h] BYREF

v5[0] = 0LL;
v5[1] = 0LL;
return cholmod_rowdel_mark(a1, a2, (double *)v5, 0LL, a3, 0LL, 0LL, v4);
}

canonical_decompiled_code:
__int64 __fastcall func1(unsigned __int64 a1, __int64 a2, unsigned __int64 *a3)
{
__int64 v4; // [rsp+0h] [rbp-20h]
__int64 v5[3]; // [rsp+8h] [rbp-18h] BYREF

v5[0] = 0LL;
v5[1] = 0LL;
return func0(a1, a2, (double *)v5, 0LL, a3, 0LL, 0LL, v4);
}

original_code:
int cholmod_rowdel
(
    size_t k,
    cholmod_sparse *R,
    cholmod_factor *L,
    cholmod_common *Common
)
{
    double yk [2] ;
    yk [0] = 0. ;
    yk [1] = 0. ;
    return (cholmod_rowdel_mark (k, R, yk, ((void *)0), L, ((void *)0), ((void *)0), Common)) ;
}

canonical_original_code:
int cholmod_rowdel(unsigned long k, struct cholmod_sparse_struct *R, struct cholmod_factor_struct *L, struct cholmod_common_struct *Common)
{
    double yk[2];
    yk [0] = 0. ;
    yk [1] = 0. ;
    return (cholmod_rowdel_mark (k, R, yk, ((void *)0), L, ((void *)0), ((void *)0), Common)) ;
}

variable_types:
k
unsigned long

variable_types: struct cholmod_sparse_struct { unsigned long nrow; unsigned long ncol; unsigned long nzmax; void *p; void *i; void *nz; void *x; void *z; int stype; int itype; int xtype; int dtype; int sorted; int packed; } *

variable_types: struct cholmod_factor_struct { unsigned long n; unsigned long minor; void *Perm; void *ColCount; unsigned long nzmax; void *p; void *i; void *x; void *z; void *nz; void *next; void *prev; unsigned long nsuper; unsigned long ssize; unsigned long xsize; unsigned long maxcsize; unsigned long maxesize; void *super; void *pi; void *px; void *s; int ordering; int is_ll; int is_super; int is_monotonic; int itype; int xtype; int dtype; } *

variable_types: struct cholmod_common_struct { double dbound; double grow0; double grow1; unsigned long grow2; unsigned long maxrank; double supernodal_switch; int supernodal; int final_asis; int final_super; int final_ll; int final_pack; int final_monotonic; int final_resymbol; double zrelax[3]; unsigned long nrelax[3]; int prefer_zomplex; int prefer_upper; int quick_return_if_not_posdef; int print; int precise; int (*print_function)(char *, ...); int try_catch; void (*error_handler)(int status, char *file, int line, char *message); int nmethods; int current; int selected; struct cholmod_method_struct { double lnz; double fl; double prune_dense; double prune_dense2; double nd_oksep; double other_1[4]; unsigned long nd_small; unsigned long other_2[4]; int aggressive; int order_for_lu; int nd_compress; int nd_camd; int nd_components; int ordering; unsigned long other_3[4]; } method[-1]; int postorder; void *(*malloc_memory)(unsigned long); void *(*realloc_memory)(void *, unsigned long); void (*free_memory)(void *); void *(*calloc_memory)(unsigned long, unsigned long); int (*complex_divide)(double ax, double az, double bx, double bz, double *cx, double *cz); double (*hypotenuse)(double x, double y); double metis_memory; double metis_dswitch; unsigned long metis_nswitch; unsigned long nrow; long mark; unsigned long iworksize; unsigned long xworksize; void *Flag; void *Head; void *Xwork; void *Iwork; int itype; int dtype; int no_workspace_reallocate; int status; double fl; double lnz; double anz; double modfl; unsigned long malloc_count; unsigned long memory_usage; unsigned long memory_inuse; double nrealloc_col; double nrealloc_factor; double ndbounds_hit; double rowfacfl; double aatfl; double other1[10]; double SPQR_xstat[4]; double SPQR_grain; double SPQR_small; long SPQR_istat[10]; long other2[6]; int other3[10]; int prefer_binary; int default_nesdis; int called_nd; int blas_ok; int SPQR_shrink; int SPQR_nthreads; unsigned long other4[16]; void *other5[16]; } *

variable_types:
yk
double [2]


decompiled_code:
__int64 __fastcall cholmod_rowdel_solve(unsigned __int64 a1, __int64 a2, double *a3, unsigned __int64 *a4, __int64 a5, __int64 a6, __int64 a7)
{
return cholmod_rowdel_mark(a1, a2, a3, 0LL, a4, a5, a6, a7);
}

canonical_decompiled_code:
__int64 __fastcall func2(unsigned __int64 a1, __int64 a2, double *a3, unsigned __int64 *a4, __int64 a5, __int64 a6, __int64 a7)
{
return func0(a1, a2, a3, 0LL, a4, a5, a6, a7);
}

original_code:
int cholmod_rowdel_solve
(
    size_t k,
    cholmod_sparse *R,
    double yk [2],
    cholmod_factor *L,
    cholmod_dense *X,
    cholmod_dense *DeltaB,
    cholmod_common *Common
)
{
    return (cholmod_rowdel_mark (k, R, yk, ((void *)0), L, X, DeltaB, Common)) ;
}

canonical_original_code:
int cholmod_rowdel_solve(unsigned long k, struct cholmod_sparse_struct *R, double yk[2], struct cholmod_factor_struct *L, struct cholmod_dense_struct *X, struct cholmod_dense_struct *DeltaB, struct cholmod_common_struct *Common)
{
    return (cholmod_rowdel_mark (k, R, yk, ((void *)0), L, X, DeltaB, Common)) ;
}

variable_types: struct cholmod_dense_struct { unsigned long nrow; unsigned long ncol; unsigned long nzmax; unsigned long d; void *x; void *z; int xtype; int dtype; } *

variable_types:
DeltaB
struct cholmod_dense_struct *

user_defined_types: struct cholmod_sparse_struct { unsigned long nrow; unsigned long ncol; unsigned long nzmax; void *p; void *i; void *nz; void *x; void *z; int stype; int itype; int xtype; int dtype; int sorted; int packed; }

user_defined_types: struct cholmod_factor_struct { unsigned long n; unsigned long minor; void *Perm; void *ColCount; unsigned long nzmax; void *p; void *i; void *x; void *z; void *nz; void *next; void *prev; unsigned long nsuper; unsigned long ssize; unsigned long xsize; unsigned long maxcsize; unsigned long maxesize; void *super; void *pi; void *px; void *s; int ordering; int is_ll; int is_super; int is_monotonic; int itype; int xtype; int dtype; }

user_defined_types: struct cholmod_method_struct { double lnz; double fl; double prune_dense; double prune_dense2; double nd_oksep; double other_1[4]; unsigned long nd_small; unsigned long other_2[4]; int aggressive; int order_for_lu; int nd_compress; int nd_camd; int nd_components; int ordering; unsigned long other_3[4]; }


original_code:
long umfpack_zl_scale
(
    double Xx [ ],
    double Xz [ ],
    const double Bx [ ],
    const double Bz [ ],
    void *NumericHandle
)
{
    NumericType *Numeric ;
    long n, i ;
    double *Rs ;
    long split = ((Xz) != (double *) ((void *)0)) && ((Bz) != (double *) ((void *)0)) ;
    Numeric = (NumericType *) NumericHandle ;
    if (!umfzl_valid_numeric (Numeric))
    {
 return ((-3)) ;
    }
    n = Numeric->n_row ;
    Rs = Numeric->Rs ;
    if (!Xx || !Bx)
    {
 return ((-5)) ;
    }
    if (Rs != (double *) ((void *)0))
    {
 if (Numeric->do_recip)
 {
     if (split)
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [i] = Bx [i] * Rs [i] ;
      Xz [i] = Bz [i] * Rs [i] ;
  }
     }
     else
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [2*i ] = Bx [2*i ] * Rs [i] ;
      Xx [2*i+1] = Bx [2*i+1] * Rs [i] ;
  }
     }
 }
 else
 {
     if (split)
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [i] = Bx [i] / Rs [i] ;
      Xz [i] = Bz [i] / Rs [i] ;
  }
     }
     else
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [2*i ] = Bx [2*i ] / Rs [i] ;
      Xx [2*i+1] = Bx [2*i+1] / Rs [i] ;
  }
     }
 }
    }
    else
    {
        if (split)
 {
     for (i = 0 ; i < n ; i++)
     {
  Xx [i] = Bx [i] ;
  Xz [i] = Bz [i] ;
     }
 }
 else
 {
     for (i = 0 ; i < n ; i++)
     {
  Xx [2*i ] = Bx [2*i ] ;
  Xx [2*i+1] = Bx [2*i+1] ;
     }
 }
    }
    return ((0)) ;
}

canonical_original_code:
long umfpack_zl_scale(double Xx[], double Xz[], double Bx[], double Bz[], void *NumericHandle)
{
    struct NumericType *Numeric;
    long n; long i;
    double *Rs;
    long split = ((Xz) != (double *) ((void *)0)) && ((Bz) != (double *) ((void *)0));
    Numeric = (struct NumericType *) NumericHandle ;
    if (!umfzl_valid_numeric (Numeric))
    {
 return ((-3)) ;
    }
    n = Numeric->n_row ;
    Rs = Numeric->Rs ;
    if (!Xx || !Bx)
    {
 return ((-5)) ;
    }
    if (Rs != (double *) ((void *)0))
    {
 if (Numeric->do_recip)
 {
     if (split)
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [i] = Bx [i] * Rs [i] ;
      Xz [i] = Bz [i] * Rs [i] ;
  }
     }
     else
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [2*i ] = Bx [2*i ] * Rs [i] ;
      Xx [2*i+1] = Bx [2*i+1] * Rs [i] ;
  }
     }
 }
 else
 {
     if (split)
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [i] = Bx [i] / Rs [i] ;
      Xz [i] = Bz [i] / Rs [i] ;
  }
     }
     else
     {
  for (i = 0 ; i < n ; i++)
  {
      Xx [2*i ] = Bx [2*i ] / Rs [i] ;
      Xx [2*i+1] = Bx [2*i+1] / Rs [i] ;
  }
     }
 }
    }
    else
    {
        if (split)
 {
     for (i = 0 ; i < n ; i++)
     {
  Xx [i] = Bx [i] ;
  Xz [i] = Bz [i] ;
     }
 }
 else
 {
     for (i = 0 ; i < n ; i++)
     {
  Xx [2*i ] = Bx [2*i ] ;
  Xx [2*i+1] = Bx [2*i+1] ;
     }
 }
    }
    return ((0)) ;
}

variable_types:
Xx
double []

variable_types:
Xz
double []

variable_types:
Bx
double []

variable_types:
Bz
double []

variable_types:
NumericHandle
void *

variable_types: struct NumericType { double flops; long scale; long valid; union Unit_union { struct { long size; } header; double xxxxxx; } *Memory; long ihead; long *Rperm; long ulen; struct DoubleComplex { double component[2]; } *D; long do_recip; double *Rs; long n_row; long tail_usage; long maxnrows; } *

variable_types: n long

variable_types: i long

variable_types:
Rs
double *

variable_types: split long

user_defined_types: struct NumericType { double flops; long scale; long valid; union Unit_union *Memory; long ihead; long *Rperm; long ulen; struct DoubleComplex *D; long do_recip; double *Rs; long n_row; long tail_usage; long maxnrows; }