// File: /workspace/github_c_makefile_star2_O1/markpeerdeman[P]mbemm/src/emath/parse.c
// Function: parse
void parse(char *name, mesh theMesh)
/* This is the main parse function. This function is called somewhere from
 * the mainline. It reads the inputdeck, identified with the filename 'name'.
 * All database dlls are filled (elements,points(nodes), tractions and disps
 */
{ FILE *fp;
  static char theKeyword[80];
  element elm;
  if ( (fp=fopen(name,"r"))==(FILE *)NULL ) evaluate_level(RED,50);
  evaluate_level(GREEN,51);

  /* do something when a keyword is encountered: */
  while (!feof(fp))
  { read_keyword(fp,theKeyword);
    if (!strcmp(theKeyword,"NODES"))         read_points(fp,theMesh); else
    if (!strcmp(theKeyword,"ELEMENTS"))      read_elements(fp,theMesh); else
    if (!strcmp(theKeyword,"TRACTIONS"))     read_tractions(fp,theMesh); else
    if (!strcmp(theKeyword,"DISPLACEMENTS")) read_displacements(fp,theMesh); else
    if (!strcmp(theKeyword,"MATERIAL"))      read_material(fp); else
    if (!strcmp(theKeyword,"WRITE_UNIVERSAL")) write_universal_req(); else
    if (!strcmp(theKeyword,"WRITE_SPECIAL")) write_special_req(); else
    if (!strcmp(theKeyword,"WRITE_OBJ"))     write_obj_req(); else
    if (!strcmp(theKeyword,"LARGE_DISPLACEMENTS")) large_displacements_req(); else
    if (!strcmp(theKeyword,"CNODES"))        skip_C_nodes(fp); else
    if (!strcmp(theKeyword,"SOLUTION"))	     skip_solutionvector(fp); else
    if (!strcmp(theKeyword,"END"))           break; else
    evaluate_level(YELLOW,53);
  }

  if ((WRITE_SPECIAL==NO)&&(WRITE_UNIVERSAL==NO)&&(WRITE_OBJ==NO))
  { evaluate_level(YELLOW,68);
  }

  if ( (modulus_of_elasticity==0.0) || (poissons_ratio==0.0) )
  { evaluate_level(YELLOW,63);
    modulus_of_elasticity=210000.0;
    poissons_ratio=0.29;
  }


/* evaluate_level(GREEN,60); */
fclose(fp);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
leaq 0x9091(%rip), %rsi      # 0xfca2
callq 0x1160
movq %rax, %rbx
testq %rax, %rax
jne 0x6c2d
movl $0x2, %edi
movl $0x32, %esi
callq 0xbc50
xorl %edi, %edi
movl $0x33, %esi
callq 0xbc50
movq %rbx, %rdi
callq 0x1110
testl %eax, %eax
je 0x6ce7
leaq 0xe7d8(%rip), %rax      # 0x15428
cmpl $0x0, (%rax)
jne 0x6c7c
leaq 0xe7d0(%rip), %rax      # 0x1542c
cmpl $0x0, (%rax)
jne 0x6c7c
leaq 0xe7c8(%rip), %rax      # 0x15430
cmpl $0x0, (%rax)
jne 0x6c7c
movl $0x1, %edi
movl $0x44, %esi
callq 0xbc50
leaq 0xe785(%rip), %r14      # 0x15408
movsd (%r14), %xmm1
pxor %xmm0, %xmm0
ucomisd %xmm0, %xmm1
leaq 0xe779(%rip), %r15      # 0x15410
jne 0x6c9b
jnp 0x6ca8
movsd (%r15), %xmm1
ucomisd %xmm0, %xmm1
jne 0x6cd1
jp 0x6cd1
movl $0x1, %edi
movl $0x3f, %esi
callq 0xbc50
movabsq $0x4109a28000000000, %rax # imm = 0x4109A28000000000
movq %rax, (%r14)
movabsq $0x3fd28f5c28f5c28f, %rax # imm = 0x3FD28F5C28F5C28F
movq %rax, (%r15)
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x1080
movabsq $0x4e4f495443415254, %r12 # imm = 0x4E4F495443415254
leaq 0xe998(%rip), %r15      # 0x15690
movl $0x45444f4e, %r13d      # imm = 0x45444F4E
movabsq $0x53544e454d454c45, %rbp # imm = 0x53544E454D454C45
leaq 0x120afcff(%r12), %rax
movq %rax, (%rsp)
movq %rbx, %rdi
movq %r15, %rsi
callq 0x658c
movl 0xe96b(%rip), %eax      # 0x15690
xorl %r13d, %eax
movzwl 0xe965(%rip), %ecx      # 0x15694
xorl $0x53, %ecx
orl %eax, %ecx
je 0x6ece
movq 0xe94f(%rip), %rax      # 0x15690
xorq %rbp, %rax
movzbl 0xe94d(%rip), %ecx      # 0x15698
orq %rax, %rcx
je 0x6edb
movq 0xe935(%rip), %rax      # 0x15690
xorq %r12, %rax
movzwl 0xe933(%rip), %ecx      # 0x15698
xorq $0x53, %rcx
orq %rax, %rcx
je 0x6ee8
movq 0xe917(%rip), %rax      # 0x15690
movabsq $0x4543414c50534944, %rcx # imm = 0x4543414C50534944
xorq %rcx, %rax
movq 0xe909(%rip), %rcx      # 0x15696
movabsq $0x53544e454d4543, %rdx # imm = 0x53544E454D4543
xorq %rdx, %rcx
orq %rax, %rcx
je 0x6ef5
movq 0xe8e6(%rip), %rax      # 0x15690
movabsq $0x4c4149524554414d, %rcx # imm = 0x4C4149524554414D
xorq %rcx, %rax
movzbl 0xe8da(%rip), %ecx      # 0x15698
orq %rax, %rcx
je 0x6f1d
movdqa 0xe8c1(%rip), %xmm0     # 0x15690
pcmpeqb 0x8139(%rip), %xmm0     # 0xef10
pmovmskb %xmm0, %eax
cmpl $0xffff, %eax           # imm = 0xFFFF
je 0x6f27
movq 0xe8a3(%rip), %rax      # 0x15690
movabsq $0x50535f4554495257, %rcx # imm = 0x50535F4554495257
xorq %rcx, %rax
movq 0xe895(%rip), %rcx      # 0x15696
movabsq $0x4c414943455053, %rdx # imm = 0x4C414943455053
xorq %rdx, %rcx
orq %rax, %rcx
je 0x6f3f
movq 0xe872(%rip), %rax      # 0x15690
movabsq $0x424f5f4554495257, %rcx # imm = 0x424F5F4554495257
xorq %rcx, %rax
movzwl 0xe866(%rip), %ecx      # 0x15698
xorq $0x4a, %rcx
orq %rax, %rcx
je 0x6f62
movd 0xe859(%rip), %xmm0     # 0x156a0
pcmpeqb 0x80d1(%rip), %xmm0     # 0xef20
movdqa 0xe839(%rip), %xmm1     # 0x15690
pcmpeqb 0x80d1(%rip), %xmm1     # 0xef30
pand %xmm0, %xmm1
pmovmskb %xmm1, %eax
cmpl $0xffff, %eax           # imm = 0xFFFF
je 0x6f8c
movl 0xe818(%rip), %eax      # 0x15690
movl $0x444f4e43, %ecx       # imm = 0x444F4E43
xorl %ecx, %eax
movl 0xe80e(%rip), %ecx      # 0x15693
movl $0x534544, %edx         # imm = 0x534544
xorl %edx, %ecx
orl %eax, %ecx
je 0x6faa
movq 0xe7f5(%rip), %rax      # 0x15690
xorq (%rsp), %rax
movzbl 0xe7f2(%rip), %ecx      # 0x15698
orq %rax, %rcx
je 0x6fb7
cmpl $0x444e45, 0xe7d7(%rip) # imm = 0x444E45
je 0x6c49
movl $0x1, %edi
movl $0x35, %esi
jmp 0x6fa0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6637
jmp 0x6f08
movq %rbx, %rdi
movq %r14, %rsi
callq 0x6a9e
jmp 0x6f08
movq 0x18(%r14), %rdi
movl $0x0, 0x10(%rdi)
jmp 0x6f00
movq 0x10(%r14), %rdi
movl $0x1, 0x10(%rdi)
movq %rbx, %rsi
callq 0xd048
movq %rbx, %rdi
callq 0x1110
testl %eax, %eax
je 0x6d14
jmp 0x6c49
movq %rbx, %rdi
callq 0x6b1f
jmp 0x6f08
leaq 0xe4fe(%rip), %rax      # 0x1542c
movl $0x1, (%rax)
xorl %eax, %eax
leaq 0xe4eb(%rip), %rcx      # 0x15428
jmp 0x6f55
leaq 0xe4e2(%rip), %rax      # 0x15428
movl $0x1, (%rax)
xorl %eax, %eax
leaq 0xe4d7(%rip), %rcx      # 0x1542c
movl %eax, (%rcx)
leaq 0xe4d2(%rip), %rcx      # 0x15430
movl %eax, (%rcx)
jmp 0x6f08
xorl %eax, %eax
leaq 0xe4bd(%rip), %rcx      # 0x15428
movl %eax, (%rcx)
leaq 0xe4b8(%rip), %rcx      # 0x1542c
movl %eax, (%rcx)
leaq 0xe4b3(%rip), %rax      # 0x15430
movl $0x1, (%rax)
xorl %edi, %edi
movl $0x41, %esi
jmp 0x6fa0
leaq 0xe4a5(%rip), %rax      # 0x15438
movl $0x1, (%rax)
xorl %edi, %edi
movl $0x45, %esi
callq 0xbc50
jmp 0x6f08
movq %rbx, %rdi
callq 0x6876
jmp 0x6f08
movq %rbx, %rdi
callq 0x6734
jmp 0x6f08