#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */
typedef int /*<<< orphan*/ FILE;

/* Variables and functions */
int atan(int);
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *);
int /*<<< orphan*/ frdheader(int *, double *, double *, double *, int *,
                             double *, int *, int *, int *, char *, int *,
                             int *, int /*<<< orphan*/ *, char *, int *, int *);
int /*<<< orphan*/ frdselect(double *, double *, int *, int *, int *, char *,
                             int *, int *, int *, int *, int *, int *, int *,
                             int *, int *, char *, int /*<<< orphan*/ *, char *,
                             char *);
int /*<<< orphan*/ frdset(char *, char *, int *, int *, int *, int *, int *,
                          int *, int *, int *, int *, int *, int *, int *);
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ strcat(char *, char *);
scalar_t__ strcmp1(char *, char *);
int /*<<< orphan*/ strcpy(char *, char *);
void frd_se(double *co, int *nk, double *stn, int *inum, int *nmethod,
            int *kode, char *filab, double *fn, double *time, int *nstate_,
            int *istep, int *iinc, int *mode, int *noddiam, char *description,
            int *mi, int *ngraph, int *ne, double *cs, char *set, int *nset,
            int *istartset, int *iendset, int *ialset, double *thicke,
            char *jobnamec, char *output, double *dgdxglob, int *iobject,
            char *objectset) {
  FILE *f1;
  char c[2] = "C", m1[4] = " -1", m2[4] = " -2", m3[4] = " -3", p0[6] = "    0",
       p1[6] = "    1", p2[6] = "    2", p3[6] = "    3", p4[6] = "    4",
       p5[6] = "    5", p6[6] = "    6", p7[6] = "    7", p8[6] = "    8",
       p9[6] = "    9", p10[6] = "   10", p11[6] = "   11", p12[6] = "   12",
       fneig[132] = "", date[8], clock[10], newdate[21], newclock[9],
       material[59] =
           "                                                          ",
       text[2] = " ";
  static int icounter = 0, nkcoords, iaxial;
  int null, one, i, j, k, indexe, nemax, nlayer, noutloc, iset, iselect, ncomp,
      nope, nodes, ifield[7], nfield[2], icomp[7], ifieldstate[*nstate_], two,
      three, icompstate[*nstate_],
      ip0 = 0, ip1 = 1, ip2 = 2, ip3 = 3, ip4 = 4, ip5 = 5, ip6 = 6, ip7 = 7,
      ip8 = 8, ip9 = 9, ip10 = 10, ip11 = 11, ip12 = 12, imat, nelout, nterms,
      nout, noutplus, noutmin, mt = mi[1] + 1;
  int ncomptensor = 2, ifieldtensor[4] = {1, 1}, icomptensor[2] = {0, 1},
      nfieldtensor[2] = {2, 0};
  int iw;
  float ifl;
  double pi, oner;
  strcpy(fneig, jobnamec);
  strcat(fneig, ".frd");
  if ((f1 = fopen(fneig, "ab")) == NULL) {
    printf("*ERROR in frd: cannot open frd file for writing...");
    exit(0);
  }
  pi = 4. * atan(1.);
  null = 0;
  one = 1;
  two = 2;
  three = 3;
  oner = 1.;
  if (*nmethod != 0) {
    nout = 0;
    noutplus = 0;
    noutmin = 0;
    for (i = 0; i < *nk; i++) {
      if (inum[i] == 0)
        continue;
      nout++;
      if (inum[i] > 0)
        noutplus++;
      if (inum[i] < 0)
        noutmin++;
    }
  } else {
    nout = *nk;
  }
  nkcoords = *nk;
  iselect = 1;
  frdset(&filab[4002], set, &iset, istartset, iendset, ialset, inum, &noutloc,
         &nout, nset, &noutmin, &noutplus, &iselect, ngraph);
  frdheader(&icounter, &oner, time, &pi, noddiam, cs, &null, mode, &noutloc,
            description, kode, nmethod, f1, output, istep, iinc);
  if (strcmp1(&objectset[*iobject * 243], "SHAPEENERGY") == 0) {
    fprintf(f1, " -4  SENENER     2    1\n");
  } else if (strcmp1(&objectset[*iobject * 243], "MASS") == 0) {
    fprintf(f1, " -4  SENMASS     2    1\n");
  } else if (strcmp1(&objectset[*iobject * 243], "DISPLACEMENT") == 0) {
    fprintf(f1, " -4  SENDISP     2    1\n");
  } else if (strcmp1(&objectset[*iobject * 243], "EIGENFREQUENCY") == 0) {
    fprintf(f1, " -4  SENFREQ     2    1\n");
  }
  fprintf(f1, " -5  DFDN        1    1    1    0\n");
  fprintf(f1, " -5  DFDNFIL     1    1    2    0\n");
  frdselect(&dgdxglob[2 * *nk * *iobject], dgdxglob, &iset, &nkcoords, inum, m1,
            istartset, iendset, ialset, ngraph, &ncomptensor, ifieldtensor,
            icomptensor, nfieldtensor, &iselect, m2, f1, output, m3);
  fclose(f1);
  return;
}


x86 assembly (clang, -O0):
<frd_se>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x318,%rsp
mov    0xc8(%rbp),%rax
mov    0xc0(%rbp),%rax
mov    0xb8(%rbp),%rax
mov    0xb0(%rbp),%rax
mov    0xa8(%rbp),%rax
mov    0xa0(%rbp),%rax
mov    0x98(%rbp),%rax
mov    0x90(%rbp),%rax
mov    0x88(%rbp),%rax
mov    0x80(%rbp),%rax
mov    0x78(%rbp),%rax
mov    0x70(%rbp),%rax
mov    0x68(%rbp),%rax
mov    0x60(%rbp),%rax
mov    0x58(%rbp),%rax
mov    0x50(%rbp),%rax
mov    0x48(%rbp),%rax
mov    0x40(%rbp),%rax
mov    0x38(%rbp),%rax
mov    0x30(%rbp),%rax
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %rdi,-0x30(%rbp)
mov    %rsi,-0x38(%rbp)
mov    %rdx,-0x40(%rbp)
mov    %rcx,-0x48(%rbp)
mov    %r8,-0x50(%rbp)
mov    %r9,-0x58(%rbp)
mov    0xd87(%rip),%ax
mov    %ax,-0x62(%rbp)
mov    0xd7f(%rip),%eax
mov    %eax,-0x66(%rbp)
mov    0xd7a(%rip),%eax
mov    %eax,-0x6a(%rbp)
mov    0xd75(%rip),%eax
mov    %eax,-0x6e(%rbp)
mov    0xd70(%rip),%eax
mov    %eax,-0x74(%rbp)
mov    0xd6a(%rip),%ax
mov    %ax,-0x70(%rbp)
mov    0xd62(%rip),%eax
mov    %eax,-0x7a(%rbp)
mov    0xd5c(%rip),%ax
mov    %ax,-0x76(%rbp)
mov    0xd54(%rip),%eax
mov    %eax,-0x80(%rbp)
mov    0xd4e(%rip),%ax
mov    %ax,-0x7c(%rbp)
mov    0xd46(%rip),%eax
mov    %eax,-0x86(%rbp)
mov    0xd3d(%rip),%ax
mov    %ax,-0x82(%rbp)
mov    0xd32(%rip),%eax
mov    %eax,-0x8c(%rbp)
mov    0xd29(%rip),%ax
mov    %ax,-0x88(%rbp)
mov    0xd1e(%rip),%eax
mov    %eax,-0x92(%rbp)
mov    0xd15(%rip),%ax
mov    %ax,-0x8e(%rbp)
mov    0xd0a(%rip),%eax
mov    %eax,-0x98(%rbp)
mov    0xd01(%rip),%ax
mov    %ax,-0x94(%rbp)
mov    0xcf6(%rip),%eax
mov    %eax,-0x9e(%rbp)
mov    0xced(%rip),%ax
mov    %ax,-0x9a(%rbp)
mov    0xce2(%rip),%eax
mov    %eax,-0xa4(%rbp)
mov    0xcd9(%rip),%ax
mov    %ax,-0xa0(%rbp)
mov    0xcce(%rip),%eax
mov    %eax,-0xaa(%rbp)
mov    0xcc5(%rip),%ax
mov    %ax,-0xa6(%rbp)
mov    0xcba(%rip),%eax
mov    %eax,-0xb0(%rbp)
mov    0xcb1(%rip),%ax
mov    %ax,-0xac(%rbp)
mov    0xca6(%rip),%eax
mov    %eax,-0xb6(%rbp)
mov    0xc9d(%rip),%ax
mov    %ax,-0xb2(%rbp)
mov    0xc92(%rip),%eax
mov    %eax,-0xbc(%rbp)
mov    0xc89(%rip),%ax
mov    %ax,-0xb8(%rbp)
lea    -0x140(%rbp),%rdi
xor    %esi,%esi
mov    $0x84,%edx
call   1090 <memset@plt>
lea    -0x1c0(%rbp),%rdi
lea    0xd7f(%rip),%rsi
mov    $0x3b,%edx
call   10b0 <memcpy@plt>
mov    0xc52(%rip),%ax
mov    %ax,-0x1c2(%rbp)
mov    0x28(%rbp),%rax
mov    (%rax),%eax
mov    %rsp,%rcx
mov    %rcx,-0x258(%rbp)
mov    %rax,-0x260(%rbp)
mov    0x28(%rbp),%rax
mov    (%rax),%eax
mov    %rax,-0x270(%rbp)
movl   $0x0,-0x274(%rbp)
movl   $0x1,-0x278(%rbp)
movl   $0x2,-0x27c(%rbp)
movl   $0x3,-0x280(%rbp)
movl   $0x4,-0x284(%rbp)
movl   $0x5,-0x288(%rbp)
movl   $0x6,-0x28c(%rbp)
movl   $0x7,-0x290(%rbp)
movl   $0x8,-0x294(%rbp)
movl   $0x9,-0x298(%rbp)
movl   $0xa,-0x29c(%rbp)
movl   $0xb,-0x2a0(%rbp)
movl   $0xc,-0x2a4(%rbp)
mov    0x58(%rbp),%rax
mov    0x4(%rax),%eax
add    $0x1,%eax
mov    %eax,-0x2c0(%rbp)
movl   $0x2,-0x2c4(%rbp)
mov    0xce0(%rip),%rax
mov    %rax,-0x2e0(%rbp)
mov    0xcda(%rip),%rax
mov    %rax,-0x2d8(%rbp)
mov    0xb04(%rip),%rax
mov    %rax,-0x2e8(%rbp)
mov    0xcc6(%rip),%rax
mov    %rax,-0x2f0(%rbp)
lea    -0x140(%rbp),%rdi
mov    0xa8(%rbp),%rsi
call   1030 <strcpy@plt>
lea    -0x140(%rbp),%rdi
lea    0xb34(%rip),%rsi
call   10e0 <strcat@plt>
lea    -0x140(%rbp),%rdi
lea    0xb26(%rip),%rsi
call   10d0 <fopen@plt>
mov    %rax,-0x60(%rbp)
cmp    $0x0,%rax
jne    157b <frd_se+0x39b>
lea    0xb0f(%rip),%rdi
call   1080 <printf@plt>
xor    %edi,%edi
call   10f0 <exit@plt>
mov    $0x1,%edi
call   10c0 <atan@plt>
cvtsi2sd %eax,%xmm1
movsd  0xa77(%rip),%xmm0
mulsd  %xmm1,%xmm0
movsd  %xmm0,-0x300(%rbp)
ff
movl   $0x0,-0x1c8(%rbp)
movl   $0x1,-0x1cc(%rbp)
movl   $0x2,-0x264(%rbp)
movl   $0x3,-0x268(%rbp)
movsd  0xa33(%rip),%xmm0
movsd  %xmm0,-0x308(%rbp)
ff
mov    -0x50(%rbp),%rax
cmpl   $0x0,(%rax)
je     16ab <frd_se+0x4cb>
movl   $0x0,-0x2b4(%rbp)
movl   $0x0,-0x2b8(%rbp)
movl   $0x0,-0x2bc(%rbp)
movl   $0x0,-0x1d0(%rbp)
mov    -0x1d0(%rbp),%eax
mov    -0x38(%rbp),%rcx
cmp    (%rcx),%eax
jge    16a6 <frd_se+0x4c6>
mov    -0x48(%rbp),%rax
movslq -0x1d0(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jne    1636 <frd_se+0x456>
jmp    1692 <frd_se+0x4b2>
mov    -0x2b4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2b4(%rbp)
mov    -0x48(%rbp),%rax
movslq -0x1d0(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jle    1669 <frd_se+0x489>
mov    -0x2b8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2b8(%rbp)
mov    -0x48(%rbp),%rax
movslq -0x1d0(%rbp),%rcx
cmpl   $0x0,(%rax,%rcx,4)
jge    168d <frd_se+0x4ad>
mov    -0x2bc(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2bc(%rbp)
jmp    1692 <frd_se+0x4b2>
mov    -0x1d0(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1d0(%rbp)
jmp    160a <frd_se+0x42a>
jmp    16b7 <frd_se+0x4d7>
mov    -0x38(%rbp),%rax
mov    (%rax),%eax
mov    %eax,-0x2b4(%rbp)
mov    -0x38(%rbp),%rax
mov    (%rax),%eax
mov    %eax,0x29d5(%rip)
movl   $0x1,-0x1f0(%rbp)
mov    0x10(%rbp),%rdi
add    $0xfa2,%rdi
mov    0x78(%rbp),%rsi
mov    0x88(%rbp),%rcx
mov    0x90(%rbp),%r8
mov    0x98(%rbp),%r9
mov    -0x48(%rbp),%r13
mov    0x80(%rbp),%r14
mov    0x60(%rbp),%rax
lea    -0x1ec(%rbp),%rdx
lea    -0x1e8(%rbp),%r12
lea    -0x2b4(%rbp),%r15
lea    -0x2bc(%rbp),%rbx
lea    -0x2b8(%rbp),%r11
lea    -0x1f0(%rbp),%r10
sub    $0x40,%rsp
mov    %r13,(%rsp)
mov    %r12,0x8(%rsp)
mov    %r15,0x10(%rsp)
mov    %r14,0x18(%rsp)
mov    %rbx,0x20(%rsp)
mov    %r11,0x28(%rsp)
mov    %r10,0x30(%rsp)
mov    %rax,0x38(%rsp)
call   1070 <frdset@plt>
add    $0x40,%rsp
mov    0x20(%rbp),%rdx
mov    0x48(%rbp),%r8
mov    0x70(%rbp),%r9
mov    0x40(%rbp),%rax
mov    %rax,-0x318(%rbp)
mov    0x50(%rbp),%r12
mov    -0x58(%rbp),%r15
mov    -0x50(%rbp),%r14
mov    -0x60(%rbp),%rbx
mov    0xb0(%rbp),%r11
mov    0x30(%rbp),%r10
mov    0x38(%rbp),%rax
mov    %rax,-0x310(%rbp)
lea    0x28f2(%rip),%rdi
lea    -0x308(%rbp),%rsi
lea    -0x300(%rbp),%rcx
lea    -0x1c8(%rbp),%rax
lea    -0x1e8(%rbp),%r13
sub    $0x50,%rsp
mov    %rax,(%rsp)
mov    -0x318(%rbp),%rax
mov    %rax,0x8(%rsp)
mov    -0x310(%rbp),%rax
mov    %r13,0x10(%rsp)
mov    %r12,0x18(%rsp)
mov    %r15,0x20(%rsp)
mov    %r14,0x28(%rsp)
mov    %rbx,0x30(%rsp)
mov    %r11,0x38(%rsp)
mov    %r10,0x40(%rsp)
mov    %rax,0x48(%rsp)
call   1100 <frdheader@plt>
add    $0x50,%rsp
mov    0xc8(%rbp),%rdi
mov    0xc0(%rbp),%rax
imul   $0xf3,(%rax),%eax
cltq
add    %rax,%rdi
lea    0x887(%rip),%rsi
call   1050 <strcmp1@plt>
cmp    $0x0,%rax
jne    184e <frd_se+0x66e>
mov    -0x60(%rbp),%rdi
lea    0x879(%rip),%rsi
call   10a0 <fprintf@plt>
jmp    1924 <frd_se+0x744>
mov    0xc8(%rbp),%rdi
mov    0xc0(%rbp),%rax
imul   $0xf3,(%rax),%eax
cltq
add    %rax,%rdi
lea    0x868(%rip),%rsi
call   1050 <strcmp1@plt>
cmp    $0x0,%rax
jne    1892 <frd_se+0x6b2>
mov    -0x60(%rbp),%rdi
lea    0x853(%rip),%rsi
call   10a0 <fprintf@plt>
jmp    191f <frd_se+0x73f>
mov    0xc8(%rbp),%rdi
mov    0xc0(%rbp),%rax
imul   $0xf3,(%rax),%eax
cltq
add    %rax,%rdi
lea    0x842(%rip),%rsi
call   1050 <strcmp1@plt>
cmp    $0x0,%rax
jne    18d6 <frd_se+0x6f6>
mov    -0x60(%rbp),%rdi
lea    0x835(%rip),%rsi
call   10a0 <fprintf@plt>
jmp    191a <frd_se+0x73a>
mov    0xc8(%rbp),%rdi
mov    0xc0(%rbp),%rax
imul   $0xf3,(%rax),%eax
cltq
add    %rax,%rdi
lea    0x824(%rip),%rsi
call   1050 <strcmp1@plt>
cmp    $0x0,%rax
jne    1915 <frd_se+0x735>
mov    -0x60(%rbp),%rdi
lea    0x819(%rip),%rsi
call   10a0 <fprintf@plt>
jmp    191a <frd_se+0x73a>
jmp    191f <frd_se+0x73f>
jmp    1924 <frd_se+0x744>
mov    -0x60(%rbp),%rdi
lea    0x813(%rip),%rsi
call   10a0 <fprintf@plt>
mov    -0x60(%rbp),%rdi
lea    0x826(%rip),%rsi
call   10a0 <fprintf@plt>
mov    0xb8(%rbp),%rdi
mov    -0x38(%rbp),%rax
mov    (%rax),%eax
shl    $0x1,%eax
mov    0xc0(%rbp),%rcx
imul   (%rcx),%eax
cltq
shl    $0x3,%rax
add    %rax,%rdi
mov    0xb8(%rbp),%rsi
mov    -0x48(%rbp),%r8
lea    -0x66(%rbp),%r9
mov    0x88(%rbp),%rax
mov    0x90(%rbp),%rcx
mov    %rcx,-0x340(%rbp)
mov    0x98(%rbp),%rcx
mov    %rcx,-0x338(%rbp)
mov    0x60(%rbp),%rcx
mov    %rcx,-0x330(%rbp)
lea    -0x2e0(%rbp),%r13
lea    -0x2e8(%rbp),%r12
lea    -0x2f0(%rbp),%r15
lea    -0x6a(%rbp),%rbx
mov    -0x60(%rbp),%r11
mov    0xb0(%rbp),%r10
lea    -0x6e(%rbp),%rcx
mov    %rcx,-0x320(%rbp)
lea    -0x1ec(%rbp),%rdx
lea    0x26b7(%rip),%rcx
lea    -0x2c4(%rbp),%r14
mov    %r14,-0x328(%rbp)
lea    -0x1f0(%rbp),%r14
sub    $0x70,%rsp
mov    %rax,(%rsp)
mov    -0x340(%rbp),%rax
mov    %rax,0x8(%rsp)
mov    -0x338(%rbp),%rax
mov    %rax,0x10(%rsp)
mov    -0x330(%rbp),%rax
mov    %rax,0x18(%rsp)
mov    -0x328(%rbp),%rax
mov    %rax,0x20(%rsp)
mov    -0x320(%rbp),%rax
mov    %r13,0x28(%rsp)
mov    %r12,0x30(%rsp)
mov    %r15,0x38(%rsp)
mov    %r14,0x40(%rsp)
mov    %rbx,0x48(%rsp)
mov    %r11,0x50(%rsp)
mov    %r10,0x58(%rsp)
mov    %rax,0x60(%rsp)
call   1040 <frdselect@plt>
add    $0x70,%rsp
mov    -0x60(%rbp),%rdi
call   1060 <fclose@plt>
mov    -0x258(%rbp),%rax
mov    %rax,%rsp
lea    -0x28(%rbp),%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

x86 assembly (clang, -O2):
<frd_se>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x108,%rsp
mov    %r9,0x38(%rsp)
mov    %r8,%r12
mov    %rcx,%r14
mov    %rsi,%r15
mov    %rsp,0x40(%rsp)
mov    0x1d8(%rsp),%rsi
movl   $0x312d20,0x24(%rsp)
movl   $0x322d20,0x20(%rsp)
movl   $0x332d20,0x1c(%rsp)
xorps  %xmm0,%xmm0
movaps %xmm0,0xf0(%rsp)
movaps %xmm0,0xe0(%rsp)
movaps %xmm0,0xd0(%rsp)
movaps %xmm0,0xc0(%rsp)
movaps %xmm0,0xb0(%rsp)
movaps %xmm0,0xa0(%rsp)
movaps %xmm0,0x90(%rsp)
movaps %xmm0,0x80(%rsp)
movl   $0x0,0x100(%rsp)
movl   $0x2,0x8(%rsp)
movaps 0xdaf(%rip),%xmm0
movaps %xmm0,0x70(%rsp)
movabs $0x100000000,%rax
mov    %rax,0x60(%rsp)
movq   $0x2,0x58(%rsp)
lea    0x80(%rsp),%rbp
mov    %rbp,%rdi
call   1030 <strcpy@plt>
lea    0xd8b(%rip),%rsi
mov    %rbp,%rdi
call   10b0 <strcat@plt>
lea    0xd81(%rip),%rsi
mov    %rbp,%rdi
call   10a0 <fopen@plt>
test   %rax,%rax
je     1666 <frd_se+0x4a6>
mov    %rax,%rbx
mov    0x1b0(%rsp),%rbp
mov    0x140(%rsp),%r13
mov    $0x1,%edi
call   1090 <atan@plt>
xorps  %xmm0,%xmm0
cvtsi2sd %eax,%xmm0
mulsd  0xd1f(%rip),%xmm0
movsd  %xmm0,0x50(%rsp)
movl   $0x0,0x18(%rsp)
movabs $0x3ff0000000000000,%rax
mov    %rax,0x48(%rsp)
cmpl   $0x0,(%r12)
mov    (%r15),%r8d
mov    %r15,0x30(%rsp)
mov    %r12,0x28(%rsp)
je     1355 <frd_se+0x195>
mov    %rbx,%r9
test   %r8d,%r8d
jle    1366 <frd_se+0x1a6>
cmp    $0x1,%r8d
jne    1505 <frd_se+0x345>
xor    %edi,%edi
xor    %ebx,%ebx
xor    %edx,%edx
xor    %ecx,%ecx
mov    %rbp,%r12
mov    0x1a8(%rsp),%rsi
test   $0x1,%r8b
je     1377 <frd_se+0x1b7>
mov    (%r14,%rdi,4),%eax
test   %eax,%eax
je     1377 <frd_se+0x1b7>
add    $0x1,%ebx
test   %eax,%eax
jle    165e <frd_se+0x49e>
add    $0x1,%ecx
jmp    1377 <frd_se+0x1b7>
mov    %r8d,(%rsp)
mov    %rbp,%r12
mov    0x1a8(%rsp),%rsi
jmp    1385 <frd_se+0x1c5>
xor    %ecx,%ecx
xor    %edx,%edx
xor    %ebx,%ebx
mov    %rbp,%r12
mov    0x1a8(%rsp),%rsi
mov    %ebx,(%rsp)
mov    %edx,0xc(%rsp)
mov    %ecx,0x10(%rsp)
mov    %r9,%rbx
mov    %r8d,0x2cfc(%rip)
movl   $0x1,0x4(%rsp)
add    $0xfa2,%r13
lea    0x4(%rsp),%r11
lea    0x10(%rsp),%rax
lea    0xc(%rsp),%rbp
mov    %rsp,%r10
lea    0x6c(%rsp),%r15
lea    0x14(%rsp),%rdx
mov    %r13,%rdi
mov    0x1b8(%rsp),%r13
mov    %r13,%rcx
mov    0x1c0(%rsp),%r8
mov    0x1c8(%rsp),%r9
push   0x190(%rsp)
push   %r11
push   %rax
push   %rbp
push   %r12
push   %r10
push   %r15
push   %r14
call   1070 <frdset@plt>
add    $0x40,%rsp
lea    0x18(%rsp),%rax
lea    0x2c87(%rip),%rdi
lea    0x48(%rsp),%rsi
lea    0x50(%rsp),%rcx
mov    0x150(%rsp),%rdx
mov    0x178(%rsp),%r8
mov    0x1a0(%rsp),%r9
push   0x168(%rsp)
push   0x168(%rsp)
push   0x1f0(%rsp)
push   %rbx
push   0x48(%rsp)
push   0x60(%rsp)
push   0x1b0(%rsp)
push   %r15
push   0x1b0(%rsp)
push   %rax
call   10e0 <frdheader@plt>
add    $0x50,%rsp
mov    0x1f0(%rsp),%r15
movslq (%r15),%rax
imul   $0xf3,%rax,%rdi
mov    0x1f8(%rsp),%rbp
add    %rbp,%rdi
lea    0xbe0(%rip),%rsi
call   1050 <strcmp1@plt>
test   %rax,%rax
je     14f3 <frd_se+0x333>
movslq (%r15),%rax
imul   $0xf3,%rax,%rdi
add    %rbp,%rdi
lea    0xbe7(%rip),%rsi
call   1050 <strcmp1@plt>
test   %rax,%rax
je     14fc <frd_se+0x33c>
movslq (%r15),%rax
imul   $0xf3,%rax,%rdi
add    %rbp,%rdi
lea    0xbe7(%rip),%rsi
call   1050 <strcmp1@plt>
test   %rax,%rax
je     1568 <frd_se+0x3a8>
movslq (%r15),%rax
imul   $0xf3,%rax,%rax
add    %rax,%rbp
lea    0xbeb(%rip),%rsi
mov    %rbp,%rdi
call   1050 <strcmp1@plt>
test   %rax,%rax
jne    1581 <frd_se+0x3c1>
lea    0xbe2(%rip),%rdi
jmp    156f <frd_se+0x3af>
lea    0xb6d(%rip),%rdi
jmp    156f <frd_se+0x3af>
lea    0xb82(%rip),%rdi
jmp    156f <frd_se+0x3af>
mov    %r8d,%eax
and    $0xfffffffe,%eax
xor    %edi,%edi
xor    %ebx,%ebx
xor    %edx,%edx
xor    %ecx,%ecx
mov    %rbp,%r12
mov    0x1a8(%rsp),%rsi
jmp    1530 <frd_se+0x370>
add    $0x1,%ecx
add    $0x2,%rdi
cmp    %rdi,%rax
je     1337 <frd_se+0x177>
mov    (%r14,%rdi,4),%ebp
test   %ebp,%ebp
je     1553 <frd_se+0x393>
add    $0x1,%ebx
test   %ebp,%ebp
jle    1550 <frd_se+0x390>
add    $0x1,%ecx
jmp    1553 <frd_se+0x393>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
add    $0x1,%edx
mov    0x4(%r14,%rdi,4),%ebp
test   %ebp,%ebp
je     1523 <frd_se+0x363>
add    $0x1,%ebx
test   %ebp,%ebp
jg     1520 <frd_se+0x360>
add    $0x1,%edx
jmp    1523 <frd_se+0x363>
lea    0xb3c(%rip),%rdi
mov    $0x18,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   10d0 <fwrite@plt>
lea    0xb64(%rip),%rdi
mov    $0x22,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   10d0 <fwrite@plt>
lea    0xb6e(%rip),%rdi
mov    $0x22,%esi
mov    $0x1,%edx
mov    %rbx,%rcx
call   10d0 <fwrite@plt>
mov    0x30(%rsp),%rax
movslq (%rax),%rax
movslq (%r15),%rdi
imul   %rax,%rdi
shl    $0x4,%rdi
mov    0x1e8(%rsp),%rsi
add    %rsi,%rdi
sub    $0x8,%rsp
lea    0x24(%rsp),%rax
lea    0x28(%rsp),%rbp
lea    0x60(%rsp),%r10
lea    0x68(%rsp),%r11
lea    0x78(%rsp),%r15
lea    0x10(%rsp),%r12
lea    0x2a8e(%rip),%rcx
lea    0x1c(%rsp),%rdx
lea    0x2c(%rsp),%r9
mov    %r14,%r8
push   %rax
push   0x1f0(%rsp)
push   %rbx
push   %rbp
lea    0x2c(%rsp),%rax
push   %rax
push   %r10
push   %r11
push   %r15
push   %r12
push   0x1e0(%rsp)
push   0x220(%rsp)
push   0x220(%rsp)
push   %r13
call   1040 <frdselect@plt>
add    $0x70,%rsp
mov    %rbx,%rdi
call   1060 <fclose@plt>
mov    0x40(%rsp),%rsp
add    $0x108,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
add    $0x1,%edx
jmp    1377 <frd_se+0x1b7>
lea    0x9bb(%rip),%rdi
call   1080 <printf@plt>
xor    %edi,%edi
call   10c0 <exit@plt>

LLVM IR (-O0):
@__const.frd_se.c = [2 x i8] c"C\00"
@__const.frd_se.m1 = [4 x i8] c" -1\00"
@__const.frd_se.m2 = [4 x i8] c" -2\00"
@__const.frd_se.m3 = [4 x i8] c" -3\00"
@__const.frd_se.p0 = [6 x i8] c" 0\00"
@__const.frd_se.p1 = [6 x i8] c" 1\00"
@__const.frd_se.p2 = [6 x i8] c" 2\00"
@__const.frd_se.p3 = [6 x i8] c" 3\00"
@__const.frd_se.p4 = [6 x i8] c" 4\00"
@__const.frd_se.p5 = [6 x i8] c" 5\00"
@__const.frd_se.p6 = [6 x i8] c" 6\00"
@__const.frd_se.p7 = [6 x i8] c" 7\00"
@__const.frd_se.p8 = [6 x i8] c" 8\00"
@__const.frd_se.p9 = [6 x i8] c" 9\00"
@__const.frd_se.p10 = [6 x i8] c" 10\00"
@__const.frd_se.p11 = [6 x i8] c" 11\00"
@__const.frd_se.p12 = [6 x i8] c" 12\00"
@__const.frd_se.material = [59 x i8] c" \00"
@__const.frd_se.text = [2 x i8] c" \00"
@frd_se.icounter = internal global i32 0
@frd_se.nkcoords = internal global i32 0
@frd_se.iaxial = internal global i32 0
@__const.frd_se.ifieldtensor = [4 x i32] [i32 1, i32 1, i32 0, i32 0]
@__const.frd_se.icomptensor = [2 x i32] [i32 0, i32 1]
@__const.frd_se.nfieldtensor = [2 x i32] [i32 2, i32 0]
@.str = [5 x i8] c".frd\00"
@.str.1 = [3 x i8] c"ab\00"
@.str.2 = [51 x i8] c"*ERROR in frd: cannot open frd file for writing...\00"
@.str.3 = [12 x i8] c"SHAPEENERGY\00"
@.str.4 = [25 x i8] c" -4 SENENER 2 1\0A\00"
@.str.5 = [5 x i8] c"MASS\00"
@.str.6 = [25 x i8] c" -4 SENMASS 2 1\0A\00"
@.str.7 = [13 x i8] c"DISPLACEMENT\00"
@.str.8 = [25 x i8] c" -4 SENDISP 2 1\0A\00"
@.str.9 = [15 x i8] c"EIGENFREQUENCY\00"
@.str.10 = [25 x i8] c" -4 SENFREQ 2 1\0A\00"
@.str.11 = [35 x i8] c" -5 DFDN 1 1 1 0\0A\00"
@.str.12 = [35 x i8] c" -5 DFDNFIL 1 1 2 0\0A\00"
define void @frd_se(double* %0, i32* %1, double* %2, i32* %3, i32* %4, i32* %5, i8* %6, double* %7, double* %8, i32* %9, i32* %10, i32* %11, i32* %12, i32* %13, i8* %14, i32* %15, i32* %16, i32* %17, double* %18, i8* %19, i32* %20, i32* %21, i32* %22, i32* %23, double* %24, i8* %25, i8* %26, double* %27, i32* %28, i8* %29) {
%31 = alloca double*
%32 = alloca i32*
%33 = alloca double*
%34 = alloca i32*
%35 = alloca i32*
%36 = alloca i32*
%37 = alloca i8*
%38 = alloca double*
%39 = alloca double*
%40 = alloca i32*
%41 = alloca i32*
%42 = alloca i32*
%43 = alloca i32*
%44 = alloca i32*
%45 = alloca i8*
%46 = alloca i32*
%47 = alloca i32*
%48 = alloca i32*
%49 = alloca double*
%50 = alloca i8*
%51 = alloca i32*
%52 = alloca i32*
%53 = alloca i32*
%54 = alloca i32*
%55 = alloca double*
%56 = alloca i8*
%57 = alloca i8*
%58 = alloca double*
%59 = alloca i32*
%60 = alloca i8*
%61 = alloca i32*
%62 = alloca [2 x i8]
%63 = alloca [4 x i8]
%64 = alloca [4 x i8]
%65 = alloca [4 x i8]
%66 = alloca [6 x i8]
%67 = alloca [6 x i8]
%68 = alloca [6 x i8]
%69 = alloca [6 x i8]
%70 = alloca [6 x i8]
%71 = alloca [6 x i8]
%72 = alloca [6 x i8]
%73 = alloca [6 x i8]
%74 = alloca [6 x i8]
%75 = alloca [6 x i8]
%76 = alloca [6 x i8]
%77 = alloca [6 x i8]
%78 = alloca [6 x i8]
%79 = alloca [132 x i8]
%80 = alloca [8 x i8]
%81 = alloca [10 x i8]
%82 = alloca [21 x i8]
%83 = alloca [9 x i8]
%84 = alloca [59 x i8]
%85 = alloca [2 x i8]
%86 = alloca i32
%87 = alloca i32
%88 = alloca i32
%89 = alloca i32
%90 = alloca i32
%91 = alloca i32
%92 = alloca i32
%93 = alloca i32
%94 = alloca i32
%95 = alloca i32
%96 = alloca i32
%97 = alloca i32
%98 = alloca i32
%99 = alloca i32
%100 = alloca [7 x i32]
%101 = alloca [2 x i32]
%102 = alloca [7 x i32]
%103 = alloca i8*
%104 = alloca i64
%105 = alloca i32
%106 = alloca i32
%107 = alloca i64
%108 = alloca i32
%109 = alloca i32
%110 = alloca i32
%111 = alloca i32
%112 = alloca i32
%113 = alloca i32
%114 = alloca i32
%115 = alloca i32
%116 = alloca i32
%117 = alloca i32
%118 = alloca i32
%119 = alloca i32
%120 = alloca i32
%121 = alloca i32
%122 = alloca i32
%123 = alloca i32
%124 = alloca i32
%125 = alloca i32
%126 = alloca i32
%127 = alloca i32
%128 = alloca i32
%129 = alloca [4 x i32]
%130 = alloca [2 x i32]
%131 = alloca [2 x i32]
%132 = alloca i32
%133 = alloca float
%134 = alloca double
%135 = alloca double
store double* %0, double** %31
store i32* %1, i32** %32
store double* %2, double** %33
store i32* %3, i32** %34
store i32* %4, i32** %35
store i32* %5, i32** %36
store i8* %6, i8** %37
store double* %7, double** %38
store double* %8, double** %39
store i32* %9, i32** %40
store i32* %10, i32** %41
store i32* %11, i32** %42
store i32* %12, i32** %43
store i32* %13, i32** %44
store i8* %14, i8** %45
store i32* %15, i32** %46
store i32* %16, i32** %47
store i32* %17, i32** %48
store double* %18, double** %49
store i8* %19, i8** %50
store i32* %20, i32** %51
store i32* %21, i32** %52
store i32* %22, i32** %53
store i32* %23, i32** %54
store double* %24, double** %55
store i8* %25, i8** %56
store i8* %26, i8** %57
store double* %27, double** %58
store i32* %28, i32** %59
store i8* %29, i8** %60
%136 = bitcast [2 x i8]* %62 to i8*
%137 = bitcast [4 x i8]* %63 to i8*
%138 = bitcast [4 x i8]* %64 to i8*
%139 = bitcast [4 x i8]* %65 to i8*
%140 = bitcast [6 x i8]* %66 to i8*
%141 = bitcast [6 x i8]* %67 to i8*
%142 = bitcast [6 x i8]* %68 to i8*
%143 = bitcast [6 x i8]* %69 to i8*
%144 = bitcast [6 x i8]* %70 to i8*
%145 = bitcast [6 x i8]* %71 to i8*
%146 = bitcast [6 x i8]* %72 to i8*
%147 = bitcast [6 x i8]* %73 to i8*
%148 = bitcast [6 x i8]* %74 to i8*
%149 = bitcast [6 x i8]* %75 to i8*
%150 = bitcast [6 x i8]* %76 to i8*
%151 = bitcast [6 x i8]* %77 to i8*
%152 = bitcast [6 x i8]* %78 to i8*
%153 = bitcast [132 x i8]* %79 to i8*
%154 = bitcast [59 x i8]* %84 to i8*
%155 = bitcast [2 x i8]* %85 to i8*
%156 = load i32*, i32** %40
%157 = load i32, i32* %156
%158 = zext i32 %157 to i64
%159 = call i8* @llvm.stacksave()
store i8* %159, i8** %103
%160 = alloca i32, i64 %158
store i64 %158, i64* %104
%161 = load i32*, i32** %40
%162 = load i32, i32* %161
%163 = zext i32 %162 to i64
%164 = alloca i32, i64 %163
store i64 %163, i64* %107
store i32 0, i32* %108
store i32 1, i32* %109
store i32 2, i32* %110
store i32 3, i32* %111
store i32 4, i32* %112
store i32 5, i32* %113
store i32 6, i32* %114
store i32 7, i32* %115
store i32 8, i32* %116
store i32 9, i32* %117
store i32 10, i32* %118
store i32 11, i32* %119
store i32 12, i32* %120
%165 = load i32*, i32** %46
%166 = getelementptr inbounds i32, i32* %165, i64 1
%167 = load i32, i32* %166
%168 = add nsw i32 %167, 1
store i32 %168, i32* %127
store i32 2, i32* %128
%169 = bitcast [4 x i32]* %129 to i8*
%170 = bitcast [2 x i32]* %130 to i8*
%171 = bitcast [2 x i32]* %131 to i8*
%172 = getelementptr inbounds [132 x i8], [132 x i8]* %79, i64 0, i64 0
%173 = load i8*, i8** %56
%174 = call i32 @strcpy(i8* %172, i8* %173)
%175 = getelementptr inbounds [132 x i8], [132 x i8]* %79, i64 0, i64 0
%176 = call i32 @strcat(i8* %175, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%177 = getelementptr inbounds [132 x i8], [132 x i8]* %79, i64 0, i64 0
%178 = call i32* @fopen(i8* %177, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
store i32* %178, i32** %61
%179 = icmp eq i32* %178, null
br i1 %179, label %180, label %183
180: ; preds = %30
%181 = call i32 @printf(i8* getelementptr inbounds ([51 x i8], [51 x i8]* @.str.2, i64 0, i64 0))
%182 = call i32 @exit(i32 0)
unreachable
183: ; preds = %30
%184 = call i32 @atan(i32 1)
%185 = sitofp i32 %184 to double
%186 = fmul double 4.000000e+00, %185
store double %186, double* %134
store i32 0, i32* %86
store i32 1, i32* %87
store i32 2, i32* %105
store i32 3, i32* %106
store double 1.000000e+00, double* %135
%187 = load i32*, i32** %35
%188 = load i32, i32* %187
%189 = icmp ne i32 %188, 0
br i1 %189, label %190, label %231
190: ; preds = %183
store i32 0, i32* %124
store i32 0, i32* %125
store i32 0, i32* %126
store i32 0, i32* %88
br label %191
191: ; preds = %227, %190
%192 = load i32, i32* %88
%193 = load i32*, i32** %32
%194 = load i32, i32* %193
%195 = icmp slt i32 %192, %194
br i1 %195, label %196, label %230
196: ; preds = %191
%197 = load i32*, i32** %34
%198 = load i32, i32* %88
%199 = sext i32 %198 to i64
%200 = getelementptr inbounds i32, i32* %197, i64 %199
%201 = load i32, i32* %200
%202 = icmp eq i32 %201, 0
br i1 %202, label %203, label %204
203: ; preds = %196
br label %227
204: ; preds = %196
%205 = load i32, i32* %124
%206 = add nsw i32 %205, 1
store i32 %206, i32* %124
%207 = load i32*, i32** %34
%208 = load i32, i32* %88
%209 = sext i32 %208 to i64
%210 = getelementptr inbounds i32, i32* %207, i64 %209
%211 = load i32, i32* %210
%212 = icmp sgt i32 %211, 0
br i1 %212, label %213, label %216
213: ; preds = %204
%214 = load i32, i32* %125
%215 = add nsw i32 %214, 1
store i32 %215, i32* %125
br label %216
216: ; preds = %213, %204
%217 = load i32*, i32** %34
%218 = load i32, i32* %88
%219 = sext i32 %218 to i64
%220 = getelementptr inbounds i32, i32* %217, i64 %219
%221 = load i32, i32* %220
%222 = icmp slt i32 %221, 0
br i1 %222, label %223, label %226
223: ; preds = %216
%224 = load i32, i32* %126
%225 = add nsw i32 %224, 1
store i32 %225, i32* %126
br label %226
226: ; preds = %223, %216
br label %227
227: ; preds = %226, %203
%228 = load i32, i32* %88
%229 = add nsw i32 %228, 1
store i32 %229, i32* %88
br label %191
230: ; preds = %191
br label %234
231: ; preds = %183
%232 = load i32*, i32** %32
%233 = load i32, i32* %232
store i32 %233, i32* %124
br label %234
234: ; preds = %231, %230
%235 = load i32*, i32** %32
%236 = load i32, i32* %235
store i32 %236, i32* @frd_se.nkcoords
store i32 1, i32* %96
%237 = load i8*, i8** %37
%238 = getelementptr inbounds i8, i8* %237, i64 4002
%239 = load i8*, i8** %50
%240 = load i32*, i32** %52
%241 = load i32*, i32** %53
%242 = load i32*, i32** %54
%243 = load i32*, i32** %34
%244 = load i32*, i32** %51
%245 = load i32*, i32** %47
%246 = call i32 @frdset(i8* %238, i8* %239, i32* %95, i32* %240, i32* %241, i32* %242, i32* %243, i32* %94, i32* %124, i32* %244, i32* %126, i32* %125, i32* %96, i32* %245)
%247 = load double*, double** %39
%248 = load i32*, i32** %44
%249 = load double*, double** %49
%250 = load i32*, i32** %43
%251 = load i8*, i8** %45
%252 = load i32*, i32** %36
%253 = load i32*, i32** %35
%254 = load i32*, i32** %61
%255 = load i8*, i8** %57
%256 = load i32*, i32** %41
%257 = load i32*, i32** %42
%258 = call i32 @frdheader(i32* @frd_se.icounter, double* %135, double* %247, double* %134, i32* %248, double* %249, i32* %86, i32* %250, i32* %94, i8* %251, i32* %252, i32* %253, i32* %254, i8* %255, i32* %256, i32* %257)
%259 = load i8*, i8** %60
%260 = load i32*, i32** %59
%261 = load i32, i32* %260
%262 = mul nsw i32 %261, 243
%263 = sext i32 %262 to i64
%264 = getelementptr inbounds i8, i8* %259, i64 %263
%265 = call i64 @strcmp1(i8* %264, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%266 = icmp eq i64 %265, 0
br i1 %266, label %267, label %270
267: ; preds = %234
%268 = load i32*, i32** %61
%269 = call i32 @fprintf(i32* %268, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.4, i64 0, i64 0))
br label %309
270: ; preds = %234
%271 = load i8*, i8** %60
%272 = load i32*, i32** %59
%273 = load i32, i32* %272
%274 = mul nsw i32 %273, 243
%275 = sext i32 %274 to i64
%276 = getelementptr inbounds i8, i8* %271, i64 %275
%277 = call i64 @strcmp1(i8* %276, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%278 = icmp eq i64 %277, 0
br i1 %278, label %279, label %282
279: ; preds = %270
%280 = load i32*, i32** %61
%281 = call i32 @fprintf(i32* %280, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.6, i64 0, i64 0))
br label %308
282: ; preds = %270
%283 = load i8*, i8** %60
%284 = load i32*, i32** %59
%285 = load i32, i32* %284
%286 = mul nsw i32 %285, 243
%287 = sext i32 %286 to i64
%288 = getelementptr inbounds i8, i8* %283, i64 %287
%289 = call i64 @strcmp1(i8* %288, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%290 = icmp eq i64 %289, 0
br i1 %290, label %291, label %294
291: ; preds = %282
%292 = load i32*, i32** %61
%293 = call i32 @fprintf(i32* %292, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.8, i64 0, i64 0))
br label %307
294: ; preds = %282
%295 = load i8*, i8** %60
%296 = load i32*, i32** %59
%297 = load i32, i32* %296
%298 = mul nsw i32 %297, 243
%299 = sext i32 %298 to i64
%300 = getelementptr inbounds i8, i8* %295, i64 %299
%301 = call i64 @strcmp1(i8* %300, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.9, i64 0, i64 0))
%302 = icmp eq i64 %301, 0
br i1 %302, label %303, label %306
303: ; preds = %294
%304 = load i32*, i32** %61
%305 = call i32 @fprintf(i32* %304, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.10, i64 0, i64 0))
br label %306
306: ; preds = %303, %294
br label %307
307: ; preds = %306, %291
br label %308
308: ; preds = %307, %279
br label %309
309: ; preds = %308, %267
%310 = load i32*, i32** %61
%311 = call i32 @fprintf(i32* %310, i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.11, i64 0, i64 0))
%312 = load i32*, i32** %61
%313 = call i32 @fprintf(i32* %312, i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.12, i64 0, i64 0))
%314 = load double*, double** %58
%315 = load i32*, i32** %32
%316 = load i32, i32* %315
%317 = mul nsw i32 2, %316
%318 = load i32*, i32** %59
%319 = load i32, i32* %318
%320 = mul nsw i32 %317, %319
%321 = sext i32 %320 to i64
%322 = getelementptr inbounds double, double* %314, i64 %321
%323 = load double*, double** %58
%324 = load i32*, i32** %34
%325 = getelementptr inbounds [4 x i8], [4 x i8]* %63, i64 0, i64 0
%326 = load i32*, i32** %52
%327 = load i32*, i32** %53
%328 = load i32*, i32** %54
%329 = load i32*, i32** %47
%330 = getelementptr inbounds [4 x i32], [4 x i32]* %129, i64 0, i64 0
%331 = getelementptr inbounds [2 x i32], [2 x i32]* %130, i64 0, i64 0
%332 = getelementptr inbounds [2 x i32], [2 x i32]* %131, i64 0, i64 0
%333 = getelementptr inbounds [4 x i8], [4 x i8]* %64, i64 0, i64 0
%334 = load i32*, i32** %61
%335 = load i8*, i8** %57
%336 = getelementptr inbounds [4 x i8], [4 x i8]* %65, i64 0, i64 0
%337 = call i32 @frdselect(double* %322, double* %323, i32* %95, i32* @frd_se.nkcoords, i32* %324, i8* %325, i32* %326, i32* %327, i32* %328, i32* %329, i32* %128, i32* %330, i32* %331, i32* %332, i32* %96, i8* %333, i32* %334, i8* %335, i8* %336)
%338 = load i32*, i32** %61
%339 = call i32 @fclose(i32* %338)
%340 = load i8*, i8** %103
ret void
}

LLVM IR (-O2):
@frd_se.icounter = internal global i32 0
@frd_se.nkcoords = internal global i32 0
@__const.frd_se.ifieldtensor = [4 x i32] [i32 1, i32 1, i32 0, i32 0]
@.str = [5 x i8] c".frd\00"
@.str.1 = [3 x i8] c"ab\00"
@.str.2 = [51 x i8] c"*ERROR in frd: cannot open frd file for writing...\00"
@.str.3 = [12 x i8] c"SHAPEENERGY\00"
@.str.4 = [25 x i8] c" -4 SENENER 2 1\0A\00"
@.str.5 = [5 x i8] c"MASS\00"
@.str.6 = [25 x i8] c" -4 SENMASS 2 1\0A\00"
@.str.7 = [13 x i8] c"DISPLACEMENT\00"
@.str.8 = [25 x i8] c" -4 SENDISP 2 1\0A\00"
@.str.9 = [15 x i8] c"EIGENFREQUENCY\00"
@.str.10 = [25 x i8] c" -4 SENFREQ 2 1\0A\00"
@.str.11 = [35 x i8] c" -5 DFDN 1 1 1 0\0A\00"
@.str.12 = [35 x i8] c" -5 DFDNFIL 1 1 2 0\0A\00"
define void @frd_se(double* nocapture readnone %0, i32* nocapture %1, double* nocapture readnone %2, i32* %3, i32* %4, i32* %5, i8* %6, double* nocapture readnone %7, double* %8, i32* nocapture readnone %9, i32* %10, i32* %11, i32* %12, i32* %13, i8* %14, i32* nocapture readnone %15, i32* %16, i32* nocapture readnone %17, double* %18, i8* %19, i32* %20, i32* %21, i32* %22, i32* %23, double* nocapture readnone %24, i8* %25, i8* %26, double* %27, i32* nocapture %28, i8* %29) {
%31 = alloca i32
%32 = alloca i32
%33 = alloca i32
%34 = alloca [132 x i8]
%35 = alloca i32
%36 = alloca i32
%37 = alloca i32
%38 = alloca i32
%39 = alloca i32
%40 = alloca i32
%41 = alloca i32
%42 = alloca i32
%43 = alloca [4 x i32]
%44 = alloca i64
%45 = alloca i64
%46 = alloca double
%47 = alloca double
%48 = bitcast i32* %31 to i8*
store i32 3222816, i32* %31
%49 = bitcast i32* %32 to i8*
store i32 3288352, i32* %32
%50 = bitcast i32* %33 to i8*
store i32 3353888, i32* %33
%51 = getelementptr inbounds [132 x i8], [132 x i8]* %34, i64 0, i64 0
%52 = bitcast i32* %35 to i8*
%53 = bitcast i32* %36 to i8*
%54 = bitcast i32* %37 to i8*
%55 = bitcast i32* %38 to i8*
%56 = tail call i8* @llvm.stacksave()
%57 = bitcast i32* %39 to i8*
%58 = bitcast i32* %40 to i8*
%59 = bitcast i32* %41 to i8*
%60 = bitcast i32* %42 to i8*
store i32 2, i32* %42
%61 = bitcast [4 x i32]* %43 to i8*
%62 = bitcast i64* %44 to i8*
store i64 4294967296, i64* %44
%63 = bitcast i64* %45 to i8*
store i64 2, i64* %45
%64 = bitcast double* %46 to i8*
%65 = bitcast double* %47 to i8*
%66 = call i32 @strcpy(i8* %51, i8* %25)
%67 = call i32 @strcat(i8* %51, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str, i64 0, i64 0))
%68 = call i32* @fopen(i8* %51, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
%69 = icmp eq i32* %68, null
br i1 %69, label %70, label %73
70: ; preds = %30
%71 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([51 x i8], [51 x i8]* @.str.2, i64 0, i64 0))
%72 = call i32 @exit(i32 0)
unreachable
73: ; preds = %30
%74 = call i32 @atan(i32 1)
%75 = sitofp i32 %74 to double
%76 = fmul double %75, 4.000000e+00
store double %76, double* %46
store i32 0, i32* %35
store double 1.000000e+00, double* %47
%77 = load i32, i32* %4
%78 = icmp eq i32 %77, 0
%79 = load i32, i32* %1
br i1 %78, label %126, label %80
80: ; preds = %73
%81 = icmp sgt i32 %79, 0
br i1 %81, label %82, label %147
82: ; preds = %80
%83 = zext i32 %79 to i64
%84 = and i64 %83, 1
%85 = icmp eq i32 %79, 1
br i1 %85, label %127, label %86
86: ; preds = %82
%87 = and i64 %83, 4294967294
br label %88
88: ; preds = %119, %86
%89 = phi i64 [ 0, %86 ], [ %123, %119 ]
%90 = phi i32 [ 0, %86 ], [ %122, %119 ]
%91 = phi i32 [ 0, %86 ], [ %121, %119 ]
%92 = phi i32 [ 0, %86 ], [ %120, %119 ]
%93 = phi i64 [ 0, %86 ], [ %124, %119 ]
%94 = getelementptr inbounds i32, i32* %3, i64 %89
%95 = load i32, i32* %94
%96 = icmp eq i32 %95, 0
br i1 %96, label %104, label %97
97: ; preds = %88
%98 = add nsw i32 %90, 1
%99 = icmp sgt i32 %95, 0
br i1 %99, label %100, label %102
100: ; preds = %97
%101 = add nsw i32 %92, 1
br label %104
102: ; preds = %97
%103 = add nsw i32 %91, 1
br label %104
104: ; preds = %100, %102, %88
%105 = phi i32 [ %101, %100 ], [ %92, %102 ], [ %92, %88 ]
%106 = phi i32 [ %91, %100 ], [ %103, %102 ], [ %91, %88 ]
%107 = phi i32 [ %98, %100 ], [ %98, %102 ], [ %90, %88 ]
%108 = or i64 %89, 1
%109 = getelementptr inbounds i32, i32* %3, i64 %108
%110 = load i32, i32* %109
%111 = icmp eq i32 %110, 0
br i1 %111, label %119, label %112
112: ; preds = %104
%113 = add nsw i32 %107, 1
%114 = icmp sgt i32 %110, 0
br i1 %114, label %117, label %115
115: ; preds = %112
%116 = add nsw i32 %106, 1
br label %119
117: ; preds = %112
%118 = add nsw i32 %105, 1
br label %119
119: ; preds = %117, %115, %104
%120 = phi i32 [ %118, %117 ], [ %105, %115 ], [ %105, %104 ]
%121 = phi i32 [ %106, %117 ], [ %116, %115 ], [ %106, %104 ]
%122 = phi i32 [ %113, %117 ], [ %113, %115 ], [ %107, %104 ]
%123 = add nuw nsw i64 %89, 2
%124 = add i64 %93, 2
%125 = icmp eq i64 %124, %87
br i1 %125, label %127, label %88
126: ; preds = %73
store i32 %79, i32* %39
br label %151
127: ; preds = %119, %82
%128 = phi i32 [ undef, %82 ], [ %120, %119 ]
%129 = phi i32 [ undef, %82 ], [ %121, %119 ]
%130 = phi i32 [ undef, %82 ], [ %122, %119 ]
%131 = phi i64 [ 0, %82 ], [ %123, %119 ]
%132 = phi i32 [ 0, %82 ], [ %122, %119 ]
%133 = phi i32 [ 0, %82 ], [ %121, %119 ]
%134 = phi i32 [ 0, %82 ], [ %120, %119 ]
%135 = icmp eq i64 %84, 0
br i1 %135, label %147, label %136
136: ; preds = %127
%137 = getelementptr inbounds i32, i32* %3, i64 %131
%138 = load i32, i32* %137
%139 = icmp eq i32 %138, 0
br i1 %139, label %147, label %140
140: ; preds = %136
%141 = add nsw i32 %132, 1
%142 = icmp sgt i32 %138, 0
br i1 %142, label %145, label %143
143: ; preds = %140
%144 = add nsw i32 %133, 1
br label %147
145: ; preds = %140
%146 = add nsw i32 %134, 1
br label %147
147: ; preds = %127, %145, %143, %136, %80
%148 = phi i32 [ 0, %80 ], [ %128, %127 ], [ %146, %145 ], [ %134, %143 ], [ %134, %136 ]
%149 = phi i32 [ 0, %80 ], [ %129, %127 ], [ %133, %145 ], [ %144, %143 ], [ %133, %136 ]
%150 = phi i32 [ 0, %80 ], [ %130, %127 ], [ %141, %145 ], [ %141, %143 ], [ %132, %136 ]
store i32 %150, i32* %39
store i32 %149, i32* %41
store i32 %148, i32* %40
br label %151
151: ; preds = %147, %126
store i32 %79, i32* @frd_se.nkcoords
store i32 1, i32* %38
%152 = getelementptr inbounds i8, i8* %6, i64 4002
%153 = call i32 @frdset(i8* %152, i8* %19, i32* %37, i32* %21, i32* %22, i32* %23, i32* %3, i32* %36, i32* %39, i32* %20, i32* %41, i32* %40, i32* %38, i32* %16)
%154 = call i32 @frdheader(i32* @frd_se.icounter, double* %47, double* %8, double* %46, i32* %13, double* %18, i32* %35, i32* %12, i32* %36, i8* %14, i32* %5, i32* %4, i32* %68, i8* %26, i32* %10, i32* %11)
%155 = load i32, i32* %28
%156 = mul nsw i32 %155, 243
%157 = sext i32 %156 to i64
%158 = getelementptr inbounds i8, i8* %29, i64 %157
%159 = call i64 @strcmp1(i8* %158, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%160 = icmp eq i64 %159, 0
br i1 %160, label %182, label %161
161: ; preds = %151
%162 = load i32, i32* %28
%163 = mul nsw i32 %162, 243
%164 = sext i32 %163 to i64
%165 = getelementptr inbounds i8, i8* %29, i64 %164
%166 = call i64 @strcmp1(i8* %165, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0))
%167 = icmp eq i64 %166, 0
br i1 %167, label %182, label %168
168: ; preds = %161
%169 = load i32, i32* %28
%170 = mul nsw i32 %169, 243
%171 = sext i32 %170 to i64
%172 = getelementptr inbounds i8, i8* %29, i64 %171
%173 = call i64 @strcmp1(i8* %172, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%174 = icmp eq i64 %173, 0
br i1 %174, label %182, label %175
175: ; preds = %168
%176 = load i32, i32* %28
%177 = mul nsw i32 %176, 243
%178 = sext i32 %177 to i64
%179 = getelementptr inbounds i8, i8* %29, i64 %178
%180 = call i64 @strcmp1(i8* %179, i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.9, i64 0, i64 0))
%181 = icmp eq i64 %180, 0
br i1 %181, label %182, label %185
182: ; preds = %175, %168, %161, %151
%183 = phi i8* [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.4, i64 0, i64 0), %151 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.6, i64 0, i64 0), %161 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.8, i64 0, i64 0), %168 ], [ getelementptr inbounds ([25 x i8], [25 x i8]* @.str.10, i64 0, i64 0), %175 ]
%184 = call i64 @fwrite(i8* %183, i64 24, i64 1, i32* %68)
br label %185
185: ; preds = %182, %175
%186 = call i64 @fwrite(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.11, i64 0, i64 0), i64 34, i64 1, i32* %68)
%187 = call i64 @fwrite(i8* getelementptr inbounds ([35 x i8], [35 x i8]* @.str.12, i64 0, i64 0), i64 34, i64 1, i32* %68)
%188 = load i32, i32* %1
%189 = shl nsw i32 %188, 1
%190 = load i32, i32* %28
%191 = mul nsw i32 %189, %190
%192 = sext i32 %191 to i64
%193 = getelementptr inbounds double, double* %27, i64 %192
%194 = getelementptr inbounds [4 x i32], [4 x i32]* %43, i64 0, i64 0
%195 = bitcast i64* %44 to i32*
%196 = bitcast i64* %45 to i32*
%197 = call i32 @frdselect(double* %193, double* %27, i32* %37, i32* @frd_se.nkcoords, i32* %3, i8* %48, i32* %21, i32* %22, i32* %23, i32* %16, i32* %42, i32* %194, i32* %195, i32* %196, i32* %38, i8* %49, i32* %68, i8* %26, i8* %50)
%198 = call i32 @fclose(i32* %68)
ret void
}