LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: goLanguageEndDoWhileLoop
static void goLanguageEndDoWhileLoop(FILE* outputFile, Boolean open, int indent) {
    if (open) {
        doIndent(indent + 1);
        fprintf(outputFile, "if !");
    } else {
        startBlock(indent + 1);
        doIndent(indent + 2);
        fputs("break", outputFile);
        terminateBlock(indent + 1);
        terminateBlock(indent);
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %r14d
movq %rdi, %rbx
leal 0x1(%r14), %ebp
testw %si, %si
je 0x1035d
movl %ebp, %edi
callq 0x4284
leaq 0x3440(%rip), %rdi      # 0x13787
movl $0x4, %esi
movl $0x1, %edx
movq %rbx, %rcx
popq %rbx
popq %r14
popq %rbp
jmp 0x3210
movl %ebp, %edi
callq 0x42c1
leal 0x2(%r14), %edi
callq 0x4284
leaq 0x31c2(%rip), %rdi      # 0x13536
movq %rbx, %rsi
callq 0x3110
movl %ebp, %edi
callq 0x42f1
movl %r14d, %edi
popq %rbx
popq %r14
popq %rbp
jmp 0x42f1
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: goLanguageArrayDeclaration
static void goLanguageArrayDeclaration(FILE* f, const char* scope, const char* type, const char* name, long int suffix, int size, Boolean init) {
    fprintf(f, "var %s", name);
    if (suffix >= 0) {
        fprintf(f, "%ld", suffix);
    }
    if (init) {
        fprintf(f, " =");
    }
    if (size >= 0) {
        fprintf(f, " [%d]%s", size, type);
    } else {
        fprintf(f, " []%s", type);
    }
    if (init) {
        fprintf(f, "{");
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r9d, %ebp
movq %r8, %r15
movq %rdx, %r14
movq %rdi, %rbx
movzwl 0x30(%rsp), %r12d
leaq 0x32d7(%rip), %rsi      # 0x13687
movq %rcx, %rdx
xorl %eax, %eax
callq 0x3160
testq %r15, %r15
js 0x103d3
leaq 0x1275(%rip), %rsi      # 0x1163b
movq %rbx, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x3160
testw %r12w, %r12w
je 0x103f2
leaq 0x33ac(%rip), %rdi      # 0x1378c
movl $0x2, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x3210
testl %ebp, %ebp
js 0x1040e
leaq 0x3392(%rip), %rsi      # 0x1378f
movq %rbx, %rdi
movl %ebp, %edx
movq %r14, %rcx
xorl %eax, %eax
callq 0x3160
jmp 0x10422
leaq 0x3382(%rip), %rsi      # 0x13797
movq %rbx, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3160
testw %r12w, %r12w
je 0x1043d
movl $0x7b, %edi
movq %rbx, %rsi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x3130
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: goLanguageStateTransition
static void goLanguageStateTransition(FILE* f, int ch, long int destination, const char* accept) {
    fprintf(f, "{");
    if (ch == -1) {
        fprintf(f, "-1");
    } else if (ch == '\'' || ch == '\\') {
        fprintf(f, "'\\%c'", ch);
    } else if (' ' <= ch && ch <= '~') {
        fprintf(f, "'%c'", ch);
    } else {
        fprintf(f, "'\\x%02x'", ch);
    }
    if (strcmp(accept, "nil") == 0) {
        fprintf(f, ", %ld, %s},\n", destination, accept);
    } else {
        fprintf(f, ", %ld, &%s},\n", destination, accept);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %r12d
movq %rdi, %r15
movl $0x7b, %edi
movq %r15, %rsi
callq 0x3130
cmpl $0x5c, %r12d
je 0x1053c
cmpl $0x27, %r12d
je 0x1053c
cmpl $-0x1, %r12d
jne 0x1058e
leaq 0x30e9(%rip), %rdi      # 0x13611
movl $0x2, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x3210
jmp 0x10550
leaq 0x30d1(%rip), %rsi      # 0x13614
movq %r15, %rdi
movl %r12d, %edx
xorl %eax, %eax
callq 0x3160
leaq 0x3035(%rip), %rsi      # 0x1358c
movq %rbx, %rdi
callq 0x3240
testl %eax, %eax
leaq 0x3256(%rip), %rax      # 0x137be
leaq 0x325c(%rip), %rsi      # 0x137cb
cmoveq %rax, %rsi
movq %r15, %rdi
movq %r14, %rdx
movq %rbx, %rcx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x3160
leal -0x20(%r12), %eax
cmpl $0x5e, %eax
ja 0x105a1
leaq 0x307b(%rip), %rsi      # 0x1361a
jmp 0x10543
leaq 0x3077(%rip), %rsi      # 0x1361f
jmp 0x10543
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: goLanguageParameterDeclarationName
static void goLanguageParameterDeclarationName(FILE* f, const char* str, int nrSpaces) {
    if (nrFunctionParameters > 0) {
        fprintf(f, ",");
    }
    spaces(f, nrSpaces, nrFunctionParameters > 0? 1: 0);
    fputs(str, f);
    nrFunctionParameters++;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x0, 0xb6df(%rip)      # 0x1bd20
jle 0x10650
movl $0x2c, %edi
movq %rbx, %rsi
callq 0x3130
xorl %r15d, %r15d
cmpl $0x0, 0xb6c6(%rip)      # 0x1bd20
setg %r15b
cmpl %r15d, %ebp
cmovgl %ebp, %r15d
testl %r15d, %r15d
je 0x1067c
movl $0x20, %edi
movq %rbx, %rsi
callq 0x3130
decl %r15d
jne 0x1066a
movq %r14, %rdi
movq %rbx, %rsi
callq 0x3110
incl 0xb693(%rip)            # 0x1bd20
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: goLanguageStartFunctionCall
static void goLanguageStartFunctionCall(FILE* f, const char*functionName, const char* returnType, const char* assignTo) {
    if (returnType != NULL && assignTo != NULL) {
        fprintf(f, "var %s %s = ", assignTo, returnType);
    } else if (assignTo != NULL) {
        fprintf(f, "%s = ", returnType);
    }
    fprintf(f, "%s(", functionName);
    nrFunctionParameters = 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rax
movq %rsi, %rbx
movq %rdi, %r14
testq %rdx, %rdx
sete %dl
testq %rcx, %rcx
sete %sil
orb %dl, %sil
jne 0x10751
leaq 0x30a7(%rip), %rsi      # 0x137e6
movq %r14, %rdi
movq %rcx, %rdx
movq %rax, %rcx
xorl %eax, %eax
callq 0x3160
jmp 0x1076a
testq %rcx, %rcx
je 0x1076a
leaq 0x3007(%rip), %rsi      # 0x13764
movq %r14, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0x3160
leaq 0x3071(%rip), %rsi      # 0x137e2
movq %r14, %rdi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x3160
movl $0x0, 0xb598(%rip)      # 0x1bd20
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: rustLanguageArrayDeclaration
static void rustLanguageArrayDeclaration(FILE* f, const char* scope, const char* type, const char* name, long int suffix, int size, Boolean init) {
    fprintf(f, "const %s", name);
    if (suffix >= 0) {
        fprintf(f, "%ld", suffix);
    }
    if (size >= 0) {
        fprintf(f, ": [%s; %d]", type, size);
    } else {
        fprintf(f, ": [%s]", type);
    }
    if (init) {
        fprintf(f, " = [");
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %r9d, %ebp
movq %r8, %r15
movq %rdx, %r14
movq %rdi, %rbx
movzwl 0x30(%rsp), %r12d
leaq 0x2f40(%rip), %rsi      # 0x1380f
movq %rcx, %rdx
xorl %eax, %eax
callq 0x3160
testq %r15, %r15
js 0x108f2
leaq 0xd56(%rip), %rsi       # 0x1163b
movq %rbx, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x3160
testl %ebp, %ebp
js 0x1090e
leaq 0x2f1b(%rip), %rsi      # 0x13818
movq %rbx, %rdi
movq %r14, %rdx
movl %ebp, %ecx
xorl %eax, %eax
callq 0x3160
jmp 0x10922
leaq 0x2f0e(%rip), %rsi      # 0x13823
movq %rbx, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3160
testw %r12w, %r12w
je 0x10949
leaq 0x2e07(%rip), %rdi      # 0x13736
movl $0x4, %esi
movl $0x1, %edx
movq %rbx, %rcx
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x3210
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: rustLanguageStateTransition
static void rustLanguageStateTransition(FILE* f, int ch, long int destination, const char* accept) {
    fprintf(f, "DFAState {ch: ");
    if (ch == -1) {
        fputs("0xff", f);
    } else {
        fprintf(f, "0x%02x", (unsigned) ch);
        switch (ch) {
            case '/': case '!':
                fprintf(f, "/* %c */", ch);
                break;
            case '\t':
                fputs("/*\\t*/", f);
                break;
            case '\n':
                fputs("/*\\n*/", f);
                break;
            case '\r':
                fputs("/*\\r*/", f);
                break;
            default:
                if (' ' <= ch && ch < 127) {
                    fprintf(f, "/*%c*/", ch);
                }
        }
    }
    if (destination == -1) {
        fprintf(f, ", next: 0xffffffff");
    } else {
        fprintf(f, ", next: %ld", destination);
    }
    if (strcmp(accept, "nil") == 0) {
        fprintf(f, ", llTokenSet: None},\n");
    } else {
        fprintf(f, ", llTokenSet: Some(%s)},\n", accept);
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movq %rdx, %r15
movl %esi, %r12d
movq %rdi, %rbx
leaq 0x2e4b(%rip), %rdi      # 0x13840
movl $0xe, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x3210
cmpl $-0x1, %r12d
je 0x10a53
leaq 0x2e40(%rip), %rsi      # 0x13854
movq %rbx, %rdi
movl %r12d, %edx
xorl %eax, %eax
callq 0x3160
cmpl $0xc, %r12d
jle 0x10a5c
cmpl $0xd, %r12d
je 0x10a75
cmpl $0x2f, %r12d
je 0x10a3d
cmpl $0x21, %r12d
jne 0x10b18
leaq 0x2e17(%rip), %rsi      # 0x1385b
movq %rbx, %rdi
movl %r12d, %edx
xorl %eax, %eax
callq 0x3160
jmp 0x10a8d
leaq 0x2df5(%rip), %rdi      # 0x1384f
jmp 0x10a85
cmpl $0x9, %r12d
je 0x10a7e
cmpl $0xa, %r12d
jne 0x10b18
leaq 0x2df8(%rip), %rdi      # 0x1386b
jmp 0x10a85
leaq 0x2df6(%rip), %rdi      # 0x13872
jmp 0x10a85
leaq 0x2ddf(%rip), %rdi      # 0x13864
movq %rbx, %rsi
callq 0x3110
cmpq $-0x1, %r15
je 0x10aa9
leaq 0x2df9(%rip), %rsi      # 0x13893
movq %rbx, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x3160
jmp 0x10ac2
leaq 0x2dd0(%rip), %rdi      # 0x13880
movl $0x12, %esi
movl $0x1, %edx
movq %rbx, %rcx
callq 0x3210
leaq 0x2ac3(%rip), %rsi      # 0x1358c
movq %r14, %rdi
callq 0x3240
testl %eax, %eax
je 0x10af4
leaq 0x2dd9(%rip), %rsi      # 0x138b5
movq %rbx, %rdi
movq %r14, %rdx
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x3160
leaq 0x2da4(%rip), %rdi      # 0x1389f
movl $0x15, %esi
movl $0x1, %edx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x3210
leal -0x20(%r12), %eax
cmpl $0x5e, %eax
ja 0x10a8d
leaq 0x2d4c(%rip), %rsi      # 0x13879
jmp 0x10a44
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: rustLanguageStartFunctionDeclaration
static void rustLanguageStartFunctionDeclaration(FILE* f, const char* functionName, const char* type) {
    if (globalIndent == 0) {
        fprintf(f, "    ");
        globalIndent = 1;
    }
    fprintf(f, "fn %s(&mut self", functionName);
    returnType = type;
    nrFunctionParameters = 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
leaq 0x8f53(%rip), %r12      # 0x19af0
cmpl $0x0, (%r12)
jne 0x10bc5
leaq 0x2b02(%rip), %rdi      # 0x136ad
movl $0x4, %esi
movl $0x1, %edx
movq %r15, %rcx
callq 0x3210
movl $0x1, (%r12)
leaq 0x2d03(%rip), %rsi      # 0x138cf
movq %r15, %rdi
movq %r14, %rdx
xorl %eax, %eax
callq 0x3160
movq %rbx, 0xb158(%rip)      # 0x1bd38
movl $0x1, 0xb136(%rip)      # 0x1bd20
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/theovosse[P]llgen/lang.c
// Function: rustLanguageParameterDeclarationName
static void rustLanguageParameterDeclarationName(FILE* f, const char* str, int nrSpaces) {
    if (nrFunctionParameters > 0) {
        fputc(',', f);
    }
    spaces(f, nrSpaces, nrFunctionParameters > 0? 1: 0);
    fputs(str, f);
    fputc(':', f);
    nrFunctionParameters++;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
cmpl $0x0, 0xb114(%rip)      # 0x1bd20
jle 0x10c1b
movl $0x2c, %edi
movq %rbx, %rsi
callq 0x3130
xorl %r15d, %r15d
cmpl $0x0, 0xb0fb(%rip)      # 0x1bd20
setg %r15b
cmpl %r15d, %ebp
cmovgl %ebp, %r15d
testl %r15d, %r15d
je 0x10c47
movl $0x20, %edi
movq %rbx, %rsi
callq 0x3130
decl %r15d
jne 0x10c35
movq %r14, %rdi
movq %rbx, %rsi
callq 0x3110
movl $0x3a, %edi
movq %rbx, %rsi
callq 0x3130
incl 0xb0bb(%rip)            # 0x1bd20
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/openshmem-org[P]openshmem-examples/c/bar.c
// Function: main
int
main()
{
    int me, npes;
    int i;

    for (i = 0; i < SHMEM_BARRIER_SYNC_SIZE; i += 1) {
        pSync[i] = SHMEM_SYNC_VALUE;
    }

    shmem_init();
    me = shmem_my_pe();
    npes = shmem_n_pes();

    if (me == 0) {
        shmem_int_p(&x, 4, 1);
    }

    shmem_barrier(0, 0, npes, pSync);

    printf("%d: x = %d\n", me, x);

    shmem_finalize();

    return 0;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq $-0x1, 0x2ec6(%rip) # 0x4070
callq 0x1090
callq 0x1080
movl %eax, %ebx
callq 0x1060
movl %eax, %ebp
testl %ebx, %ebx
jne 0x11d7
leaq 0x2e98(%rip), %rdi      # 0x4060
movl $0x4, %esi
movl $0x1, %edx
callq 0x1040
leaq 0x2e92(%rip), %rcx      # 0x4070
xorl %edi, %edi
xorl %esi, %esi
movl %ebp, %edx
callq 0x1050
movl 0x2e71(%rip), %edx      # 0x4060
leaq 0xe0e(%rip), %rdi       # 0x2004
movl %ebx, %esi
xorl %eax, %eax
callq 0x1030
callq 0x1070
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mabdi[P]bunney/bunny-exec.c
// Function: prepare_shm
static void prepare_shm(void) {
  _u8 buf[128];
  _u32 i;

#ifdef __CYGWIN__
  if (!getenv("CYGWIN")) {
    debug("Sorry, you need to enable SHM support in Cygwin first:\n"
          "  1. Install Cygwin IPC service ('cygserver-config').\n"
          "  2. Launch the service ('net start cygserver').\n"
          "  3. Export 'CYGWIN=server' to your environment.\n");
    exit(1);
  }
#endif /* __CYGWIN__ */
    
  if (!(outfile=fdopen(99,"a"))) fatal("unable to create a FILE object");

  shmid = shmget(0, OUTPUT_BUF + sizeof(struct shm_record), IPC_CREAT | 0600);
  if (shmid < 0) pfatal("unable to get %d kB of shared memory", OUTPUT_BUF / 1024);

  shmreg = shmat(shmid, 0, 0);
  if (!shmreg || (long)shmreg == -1) pfatal("unable to attach shared memory");

  sprintf(buf,"%u",shmid);
  setenv("BUNNY_SHMID",buf,1);

  shmreg->length      = OUTPUT_BUF;
  shmreg->child_crash = 0;

  for (i=0;i<16;i++)
    shmreg->func_quota[i] = func_limit;

}

// Assembly:
pushq %r14
pushq %rbx
subq $0x88, %rsp
leaq 0x132a(%rip), %rsi      # 0x30a1
movl $0x63, %edi
callq 0x1100
movq %rax, 0x33f8(%rip)      # 0x5180
testq %rax, %rax
je 0x1e2d
movl $0x80054, %esi          # imm = 0x80054
xorl %edi, %edi
movl $0x380, %edx            # imm = 0x380
callq 0x1070
movl %eax, 0x33e0(%rip)      # 0x5188
movl %eax, %edi
xorl %esi, %esi
xorl %edx, %edx
callq 0x1190
movq %rax, 0x33d6(%rip)      # 0x5190
incq %rax
cmpq $0x1, %rax
jbe 0x1e28
movl 0x33bf(%rip), %edx      # 0x5188
leaq 0x150f(%rip), %rsi      # 0x32df
xorl %r14d, %r14d
movq %rsp, %rbx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x1030
leaq 0x1343(%rip), %rdi      # 0x312a
movq %rbx, %rsi
movl $0x1, %edx
callq 0x11e0
movq 0x3395(%rip), %rax      # 0x5190
movl $0x80000, 0x4(%rax)     # imm = 0x80000
movl $0x0, 0x10(%rax)
movl 0x3349(%rip), %ecx      # 0x5158
movl %ecx, 0x14(%rax,%r14,4)
incq %r14
cmpq $0x10, %r14
jne 0x1e09
addq $0x88, %rsp
popq %rbx
popq %r14
retq
callq 0x1280
callq 0x12d6
// File: /workspace/github_c_makefile_star2_O1/mabdi[P]bunney/bunny-exec.c
// Function: timeout
static void timeout(int sig) {
  struct timeval t;
  _u32 i;

  if (timeout_done) return;

  gettimeofday(&t,0);
  
  i = (t.tv_sec - start_time.tv_sec) * 1000 + (t.tv_usec - start_time.tv_usec) / 1000;
  
  if (i > time_limit) exitflags |= EXITF_TIMEOUT; else {
    i = (t.tv_sec - last_time.tv_sec) * 1000 + (t.tv_usec - last_time.tv_usec) / 1000;
      if (i > stuck_limit) exitflags |= EXITF_STUCK; else return;
  }  

  timeout_done = 1;

#ifdef DEBUG_TRACE
    printf("[bunny-exec] Execution timed out (diff = %u), orig_pid = %u, shmreg->lock = %u...\n",
           i, orig_pid, shmreg->lock);
#endif /* DEBUG_TRACE */

  /* Just let report_kids() take its course, it's safer than calling non-reentrant code
     from here. */

  if (orig_pid > 0) kill(orig_pid,SIGKILL);
  
}

// Assembly:
cmpb $0x0, 0x2cd8(%rip)      # 0x5199
jne 0x257b
pushq %rbx
subq $0x10, %rsp
movq %rsp, %rbx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1200
movq (%rbx), %rsi
movq 0x8(%rbx), %rcx
movl 0x2c7a(%rip), %eax      # 0x5160
movl %esi, %edx
subl %eax, %edx
imull $0x3e8, %edx, %r8d      # imm = 0x3E8
movq %rcx, %rax
subq 0x2c6d(%rip), %rax      # 0x5168
movabsq $0x20c49ba5e353f7cf, %rdi # imm = 0x20C49BA5E353F7CF
imulq %rdi
movq %rdx, %rax
shrq $0x3f, %rax
shrq $0x7, %rdx
addl %eax, %edx
addl %r8d, %edx
movb $0x1, %al
cmpl %edx, 0x2c30(%rip)      # 0x5150
leaq 0x10(%rsp), %rsp
popq %rbx
jb 0x255a
subl 0x2c42(%rip), %esi      # 0x5170
imull $0x3e8, %esi, %esi      # imm = 0x3E8
subq 0x2c3d(%rip), %rcx      # 0x5178
movq %rcx, %rax
imulq %rdi
movq %rdx, %rax
shrq $0x3f, %rax
shrq $0x7, %rdx
addl %eax, %edx
addl %esi, %edx
movb $0x4, %al
cmpl %edx, 0x2bfc(%rip)      # 0x5154
jae 0x257b
orb %al, 0x2c3a(%rip)       # 0x519a
movb $0x1, 0x2c32(%rip)      # 0x5199
movl 0x2c2f(%rip), %edi      # 0x519c
testl %edi, %edi
jle 0x257b
movl $0x9, %esi
jmp 0x11a0
retq
// File: /workspace/github_c_makefile_star2_O1/mabdi[P]bunney/bunny-exec.c
// Function: handle_kill
static void handle_kill(int sig) {
  _u32 i;

#ifdef DEBUG_TRACE
  printf("[bunny-exec] Received signal %u.\n",sig);
#endif /* DEBUG_TRACE */
  
  shmctl(shmid, IPC_RMID, 0);
  
  if (orig_pid > 0) kill(orig_pid,SIGKILL);
  for (i=0;i<proc_cnt;i++) 
    if (procs[i].pid) kill(procs[i].pid,SIGKILL);

  exit(1);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl 0x2c02(%rip), %edi      # 0x5188
xorl %esi, %esi
xorl %edx, %edx
callq 0x10c0
movl 0x2c07(%rip), %edi      # 0x519c
testl %edi, %edi
jle 0x25a3
movl $0x9, %esi
callq 0x11a0
cmpl $0x0, 0x2bf6(%rip)      # 0x51a0
je 0x25db
xorl %ebx, %ebx
xorl %r14d, %r14d
movq 0x2bf0(%rip), %rax      # 0x51a8
movl (%rax,%rbx), %edi
testl %edi, %edi
je 0x25c9
movl $0x9, %esi
callq 0x11a0
incq %r14
movl 0x2bce(%rip), %eax      # 0x51a0
addq $0x40, %rbx
cmpq %rax, %r14
jb 0x25b1
movl $0x1, %edi
callq 0x1130
// File: /workspace/github_c_makefile_star2_O1/mabdi[P]bunney/bunny-exec.c
// Function: read_shm
static _u8 read_shm(void* ptr, _u32 siz) {
  _s32 avail;

  /* Races here are OK, because the amount of data to be read can only increase
     with time. */

  do {
    avail = shmreg->write_off - shmreg->read_off;
    if (avail < 0) avail += shmreg->length;
    if (avail >= siz) break;
    if (report_kids()) return 1;
    sched_yield();
  } while (1);

  do {
    while (shmreg->lock)
      if (report_kids()) return 1; else sched_yield();
    atomic_inc(&shmreg->lock);
    if (shmreg->lock == 1) break;
    atomic_dec(&shmreg->lock);
    if (shmreg->lock < 0 || shmreg->lock > 1)
      fatal("SHM spinlock state corrupted (up at %d)",shmreg->lock);
  } while (1);

  if (shmreg->read_off + siz >= shmreg->length) {
    _u32 copy1 = shmreg->length - shmreg->read_off, siz2 = siz - copy1;
    memcpy(ptr, (void*) shmreg->data + shmreg->read_off, copy1);
    ptr += copy1;
    memcpy(ptr, (void*) shmreg->data, siz2);
  } else
    memcpy(ptr, (void*) shmreg->data + shmreg->read_off, siz);

  shmreg->read_off = (shmreg->read_off + siz) % (shmreg->length);

  atomic_dec(&shmreg->lock);

  return 0;

}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movq 0x2b8c(%rip), %rcx      # 0x5190
movl 0x8(%rcx), %eax
subl 0xc(%rcx), %eax
jns 0x260f
addl 0x4(%rcx), %eax
cmpl %ebx, %eax
jae 0x265b
callq 0x2757
testb %al, %al
jne 0x2670
callq 0x11c0
jmp 0x25fd
callq 0x11c0
jmp 0x265b
lock
incl (%rax)
movq 0x2b5c(%rip), %rbp      # 0x5190
movl (%rbp), %eax
cmpl $0x1, %eax
je 0x2681
lock
decl (%rbp)
movq 0x2b49(%rip), %rdi      # 0x5190
cmpl $0x0, (%rdi)
js 0x26eb
movl (%rdi), %eax
cmpl $0x2, %eax
jge 0x26eb
movq 0x2b2e(%rip), %rax      # 0x5190
cmpl $0x0, (%rax)
je 0x262a
callq 0x2757
testb %al, %al
je 0x2623
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl 0xc(%rbp), %eax
addl %ebx, %eax
cmpl 0x4(%rbp), %eax
jae 0x269d
movl 0xc(%rbp), %eax
leaq (%rax,%rbp), %rsi
addq $0x54, %rsi
movl %ebx, %edx
movq %r14, %rdi
jmp 0x26d1
movl 0x4(%rbp), %r15d
subl 0xc(%rbp), %r15d
movl %ebx, %r12d
subl %r15d, %r12d
leaq 0x54(%rbp), %r13
movl 0xc(%rbp), %eax
leaq (%rax,%rbp), %rsi
addq $0x54, %rsi
movq %r14, %rdi
movq %r15, %rdx
callq 0x10b0
addq %r15, %r14
movq %r14, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x10b0
addl 0xc(%rbp), %ebx
movl %ebx, %eax
xorl %edx, %edx
divl 0x4(%rbp)
xorl %eax, %eax
movl %edx, 0xc(%rbp)
lock
decl (%rbp)
jmp 0x2672
callq 0x1780
// File: /workspace/github_c_makefile_star2_O1/mabdi[P]bunney/bunny-exec.c
// Function: get_procentry
static _s32 get_procentry(_u32 pid,_u8 make_new) {
  _u32 rno;

  for (rno=0;rno<proc_cnt;rno++) 
    if (procs[rno].pid == pid) return rno;

  if (!make_new) return -1;
  
  proc_cnt++;
  
  if ((proc_cnt % ALLOC_CHUNK) == 1) {
    procs = realloc(procs,(proc_cnt + ALLOC_CHUNK) * sizeof(struct proc_state));
    if (!procs) fatal("out of memory");
    memset((void*)(procs+rno),0,sizeof(struct proc_state) * ALLOC_CHUNK);
  }

  procs[rno].pid = pid;
  
  return rno;

}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %eax
movl %edi, %ebp
movl 0x2888(%rip), %esi      # 0x51a0
xorl %ebx, %ebx
testl %esi, %esi
je 0x2935
movq 0x2883(%rip), %rcx      # 0x51a8
cmpl %ebp, (%rcx)
je 0x299e
incl %ebx
addq $0x40, %rcx
cmpl %ebx, %esi
jne 0x2925
movl %esi, %ebx
testb %al, %al
je 0x2999
leal 0x1(%rsi), %eax
movl %eax, 0x285e(%rip)      # 0x51a0
andl $0x7f, %eax
movl %ebx, %r14d
cmpl $0x1, %eax
jne 0x2988
movq 0x2854(%rip), %rdi      # 0x51a8
addl $0x81, %esi
shlq $0x6, %rsi
callq 0x1210
movq %rax, 0x283e(%rip)      # 0x51a8
testq %rax, %rax
je 0x29a5
movq %r14, %rcx
shlq $0x6, %rcx
addq %rcx, %rax
movl $0x2000, %edx           # imm = 0x2000
movq %rax, %rdi
xorl %esi, %esi
callq 0x1060
movq 0x2819(%rip), %rax      # 0x51a8
shlq $0x6, %r14
movl %ebp, (%rax,%r14)
jmp 0x299e
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl %ebx, %eax
popq %rbx
popq %r14
popq %rbp
retq
callq 0x1815
// File: /workspace/github_c_makefile_star2_O1/lmcilroy[P]lzm/lzdata.c
// Function: usage
static void
usage(void)
{
	printf("usage: lzdata [options] <files...>\n");
	printf("	--filesize <size>	file size (MB)\n");
	printf("	--chunksize <size>	chunk size (KB)\n");
	printf("	--minlitlen <len>	minimum literal length\n");
	printf("	--maxlitlen <len>	minimum literal length\n");
	printf("	--minmatchlen <len>	minimum match length\n");
	printf("	--maxmatchlen <len>	minimum match length\n");
	printf("	--minoffset <len>	minimum offset length\n");
	printf("	--maxoffset <len>	minimum offset length\n");
	printf("	--matchprob <prob>	probability of match [0..1]\n");
	printf("	--litlenscale <val>	literal length scale (> 0)\n");
	printf("	--matchlenscale <val>	match length scale (> 0)\n");
	printf("	--randomseed <val>	random number seed\n");
	printf("	--verbose		report details used\n");
	printf("	--help			this help\n");
}

// Assembly:
pushq %rax
leaq 0x6cb(%rip), %rdi       # 0x23e1
callq 0x1050
leaq 0x6e2(%rip), %rdi       # 0x2404
callq 0x1050
leaq 0x6f8(%rip), %rdi       # 0x2426
callq 0x1050
leaq 0x710(%rip), %rdi       # 0x244a
callq 0x1050
leaq 0x72e(%rip), %rdi       # 0x2474
callq 0x1050
leaq 0x74c(%rip), %rdi       # 0x249e
callq 0x1050
leaq 0x76a(%rip), %rdi       # 0x24c8
callq 0x1050
leaq 0x788(%rip), %rdi       # 0x24f2
callq 0x1050
leaq 0x7a5(%rip), %rdi       # 0x251b
callq 0x1050
leaq 0x7c2(%rip), %rdi       # 0x2544
callq 0x1050
leaq 0x7e6(%rip), %rdi       # 0x2574
callq 0x1050
leaq 0x80a(%rip), %rdi       # 0x25a4
callq 0x1050
leaq 0x82e(%rip), %rdi       # 0x25d4
callq 0x1050
leaq 0x849(%rip), %rdi       # 0x25fb
callq 0x1050
leaq 0x85d(%rip), %rdi       # 0x261b
popq %rax
jmp 0x1050
// File: /workspace/github_c_makefile_star2_O1/lmcilroy[P]lzm/lzdata.c
// Function: gen_literal
static unsigned int
gen_literal(unsigned char * const buffer, unsigned int pos,
    const unsigned int size, struct lzdata_args * const args)
{
	unsigned int length;
	unsigned int end;

	length = args->lit_len_scale / (1 - rngd()) -
	    args->lit_len_scale + args->min_lit_len;

	if (length > args->max_lit_len)
		length = args->max_lit_len;

	if (pos + length > size)
		length = size - pos;

	LOG("L %d %d\n", pos, length);

	args->literals++;
	args->literal_bytes += length;

	end = pos + length;

	if (end > 3) {
		while (pos < end - 3) {
			writemem32(&buffer[pos], rngl());
			pos += 4;
		}
	}

	while (pos < end)
		buffer[pos++] = rngl();

	return pos;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rcx, %r15
movl %edx, %ebp
movl %esi, %ebx
movq %rdi, %r14
movsd 0x38(%rcx), %xmm0
movsd %xmm0, 0x8(%rsp)
callq 0x1150
movsd 0x216(%rip), %xmm1      # 0x2008
subsd %xmm0, %xmm1
movsd 0x8(%rsp), %xmm0
divsd %xmm1, %xmm0
subsd 0x38(%r15), %xmm0
movapd %xmm0, %xmm1
movl 0x14(%r15), %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %rax
movl 0x18(%r15), %ecx
cmpl %eax, %ecx
cmovbl %ecx, %eax
leal (%rax,%rbx), %ecx
movl %ebp, %r12d
subl %ebx, %r12d
cmpl %ebp, %ecx
cmovbel %eax, %r12d
incq 0x50(%r15)
addq %r12, 0x60(%r15)
addl %ebx, %r12d
cmpl $0x4, %r12d
jb 0x1e64
leal -0x3(%r12), %ebp
cmpl %ebx, %ebp
jbe 0x1e64
movl %ebx, %r15d
callq 0x10b0
movl %eax, (%r14,%r15)
addl $0x4, %ebx
cmpl %ebp, %ebx
jb 0x1e51
cmpl %r12d, %ebx
jae 0x1e91
movl %ebx, %ebx
movl %r12d, %eax
addq %rbx, %r14
movq %rbx, %r12
subq %rax, %r12
xorl %r15d, %r15d
callq 0x10b0
movb %al, (%r14,%r15)
incq %r15
movq %r12, %rax
addq %r15, %rax
jne 0x1e7a
addl %r15d, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/sissm.c
// Function: sissmSegfaultSigaction
void sissmSegfaultSigaction( int signal, siginfo_t *si, void *arg )
{
    int j, nptrs;
    void *buffer[BT_BUF_SIZE];
    char **strings;
    time_t curtime;
    struct tm *loctime;

    nptrs = backtrace( buffer, BT_BUF_SIZE );
    // printf("Caught segfault at address %p\n", si->si_addr);
    // printf( "backtrace() returned %d addresses\n", nptrs );

    // The call backtrace_symbols_fd(buffer, nptrs, STDOUT_FILENO) would
    // produce similar output to the following:
    //
    strings = backtrace_symbols(buffer, nptrs);
    if (strings == NULL) {
        perror( "backtrace_symbols" );
        if ( segfaultFPW != NULL ) {
            fprintf( segfaultFPW, "Segfault Backtrace Error\n" );
            fclose( segfaultFPW );
        };
        exit( EXIT_FAILURE );
    }

    curtime = time (NULL);
    loctime = localtime (&curtime);
    if (NULL != segfaultFPW) fprintf( segfaultFPW, "Crash Time: %s\n", asctime(loctime) );
    for ( j = 0; j < nptrs; j++ ) {
        printf( "%s\n", strings[j] );
        fprintf( segfaultFPW, "%s\n", strings[j] );
    }
    if ( segfaultFPW != NULL ) fclose( segfaultFPW );

    free(strings);
    exit( EXIT_FAILURE );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x8010, %rsp           # imm = 0x8010
leaq 0x10(%rsp), %rbx
movq %rbx, %rdi
movl $0x1000, %esi           # imm = 0x1000
callq 0x8130
movl %eax, %ebp
movq %rbx, %rdi
movl %eax, %esi
callq 0x80d0
testq %rax, %rax
jne 0x85b3
leaq 0x12aba(%rip), %rdi     # 0x1b030
callq 0x8330
movq 0x21986(%rip), %rcx     # 0x29f08
testq %rcx, %rcx
je 0x85a9
leaq 0x12ab4(%rip), %rdi     # 0x1b042
movl $0x19, %esi
movl $0x1, %edx
callq 0x8390
movq 0x21964(%rip), %rdi     # 0x29f08
callq 0x8100
movl $0x1, %edi
callq 0x8370
movq %rax, %rbx
xorl %edi, %edi
callq 0x82a0
leaq 0x8(%rsp), %rdi
movq %rax, (%rdi)
callq 0x8070
movq 0x21937(%rip), %r14     # 0x29f08
testq %r14, %r14
je 0x85f2
movq %rax, %rdi
callq 0x8140
leaq 0x12a77(%rip), %rsi     # 0x1b05c
movq %r14, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0x8250
testl %ebp, %ebp
jle 0x8629
movl %ebp, %r15d
leaq 0x12dc6(%rip), %r14     # 0x1b3c6
xorl %r12d, %r12d
movq (%rbx,%r12,8), %rdi
callq 0x8090
movq 0x218f5(%rip), %rdi     # 0x29f08
movq (%rbx,%r12,8), %rdx
movq %r14, %rsi
xorl %eax, %eax
callq 0x8250
incq %r12
cmpq %r12, %r15
jne 0x8603
movq 0x218d8(%rip), %rdi     # 0x29f08
testq %rdi, %rdi
je 0x863a
callq 0x8100
movq %rbx, %rdi
callq 0x8040
jmp 0x85a9
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/sissm.c
// Function: sissmSegfaultInstall
int sissmSegfaultInstall( char *sissmCfgFileName )
{
    struct sigaction sa;
    char crashFilename[256];
    time_t curtime;
    struct tm *loctime;

    memset( &sa, 0, sizeof(struct sigaction) );
    sigemptyset( &sa.sa_mask );
    sa.sa_sigaction = sissmSegfaultSigaction;
    sa.sa_flags = SA_SIGINFO;

    sigaction(SIGSEGV, &sa, NULL);                                       // invalid memory access
    sigaction(SIGFPE,  &sa, NULL);                                              // divide-by-zero
    sigaction(SIGABRT, &sa, NULL);                                              // stack smashing

    strlcpy( crashFilename, sissmCfgFileName, 256 );
    strlcat( crashFilename, ".crashreport", 256 );
    segfaultFPW = fopen( crashFilename, "at" );

    curtime = time (NULL);
    loctime = localtime (&curtime);
    if ( NULL != segfaultFPW ) {
        fprintf( segfaultFPW, "\n\n------\nInitialized Crash Reporter: %s\n", asctime(loctime) );
        fflush( segfaultFPW );
    }

    return (segfaultFPW == NULL);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x1a0, %rsp            # imm = 0x1A0
movq %rdi, %rbx
leaq 0x8(%rsp), %r14
movl $0x98, %edx
movq %r14, %rdi
xorl %esi, %esi
callq 0x81b0
leaq 0x10(%rsp), %r15
movq %r15, %rdi
callq 0x8260
leaq -0x141(%rip), %rax      # 0x853d
movq %rax, -0x8(%r15)
movl $0x4, 0x80(%r15)
movl $0xb, %edi
movq %r14, %rsi
xorl %edx, %edx
callq 0x80a0
movl $0x8, %edi
movq %r14, %rsi
xorl %edx, %edx
callq 0x80a0
movl $0x6, %edi
movq %r14, %rsi
xorl %edx, %edx
callq 0x80a0
leaq 0xa0(%rsp), %r14
movl $0x100, %edx            # imm = 0x100
movq %r14, %rdi
movq %rbx, %rsi
callq 0xf038
leaq 0x12993(%rip), %rsi     # 0x1b06c
movl $0x100, %edx            # imm = 0x100
movq %r14, %rdi
callq 0xefc4
leaq 0x15263(%rip), %rsi     # 0x1d950
movq %r14, %rdi
callq 0x8320
movq %rax, 0x2180c(%rip)     # 0x29f08
xorl %edi, %edi
callq 0x82a0
movq %rsp, %rdi
movq %rax, (%rdi)
callq 0x8070
movq 0x217f3(%rip), %rbx     # 0x29f08
testq %rbx, %rbx
je 0x8742
movq %rax, %rdi
callq 0x8140
leaq 0x12950(%rip), %rsi     # 0x1b079
movq %rbx, %rdi
movq %rax, %rdx
xorl %eax, %eax
callq 0x8250
movq 0x217cb(%rip), %rdi     # 0x29f08
callq 0x82c0
xorl %eax, %eax
cmpq $0x0, 0x217bc(%rip)     # 0x29f08
sete %al
addq $0x1a0, %rsp            # imm = 0x1A0
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/sissm.c
// Function: sissmDiagnostics
int sissmDiagnostics( void )
{
    int errCode = 0;

    // Check RCON configuration
    //
    if ( (sissmConfig.rconPort < 1024) || (sissmConfig.rconPort > 32767) ) {
        printf("\n** CONFIGURATION ERROR: Invalid Rcon Port is set in .cfg\n");
        printf("Please fix rconPort '%d'.\n", sissmConfig.rconPort );
        errCode = 1;
    }
    if (0 == strlen( sissmConfig.rconPassword) ) {
        printf("\n** CONFIGURATION ERROR: Rcon password is not set in .cfg\n");
        printf("Please fix rconPassword\n");
        errCode = 1;
    }
    if ( 0 == strncmp( "000.000.000.000", reformatIP( sissmConfig.rconIP ), 16 ))  {
        printf("\n** CONFIGURATION ERROR: Invalid server IP set in .cfg\n"); 
        printf("Please fix rconIP '%s'\n", sissmConfig.rconIP );
        errCode = 1;
    }

    // Check critical files
    //
    if ( !isReadable( sissmConfig.gameLogFile ) ) {
        printf("\n** CONFIGURATION ERROR: Game log file not found or unable to read in .cfg\n");
        printf("Please fix gameLogFile: '%s'\n", sissmConfig.gameLogFile );
        errCode = 1;
    }

    if ( errCode ) {
        printf("\nPress ^C now, or SISSM will proceed to run in 15 seconds\n");
        sleep( 15 );
    }

    return errCode;
}

// Assembly:
pushq %rbx
movl $0xffff8000, %eax       # imm = 0xFFFF8000
addl 0x21c55(%rip), %eax     # 0x2a718
xorl %ebx, %ebx
cmpl $0xffff83ff, %eax       # imm = 0xFFFF83FF
ja 0x8af1
leaq 0x1294d(%rip), %rdi     # 0x1b420
callq 0x8090
movl 0x21c3a(%rip), %esi     # 0x2a718
leaq 0x126fb(%rip), %rdi     # 0x1b1e0
xorl %eax, %eax
callq 0x8180
movl $0x1, %ebx
cmpb $0x0, 0x21c24(%rip)     # 0x2a71c
jne 0x8b17
leaq 0x12959(%rip), %rdi     # 0x1b45a
callq 0x8090
leaq 0x12987(%rip), %rdi     # 0x1b494
callq 0x8090
movl $0x1, %ebx
leaq 0x21ffe(%rip), %rdi     # 0x2ab1c
callq 0xf711
leaq 0x126d1(%rip), %rdi     # 0x1b1fb
movl $0x10, %edx
movq %rax, %rsi
callq 0x8080
testl %eax, %eax
jne 0x8b61
leaq 0x1296a(%rip), %rdi     # 0x1b4ac
callq 0x8090
leaq 0x126bd(%rip), %rdi     # 0x1b20b
leaq 0x21fc7(%rip), %rsi     # 0x2ab1c
xorl %eax, %eax
callq 0x8180
movl $0x1, %ebx
leaq 0x223b4(%rip), %rdi     # 0x2af1c
callq 0xf7b0
testl %eax, %eax
jne 0x8b97
leaq 0x1296b(%rip), %rdi     # 0x1b4e3
callq 0x8090
leaq 0x1269f(%rip), %rdi     # 0x1b223
leaq 0x22391(%rip), %rsi     # 0x2af1c
xorl %eax, %eax
callq 0x8180
movl $0x1, %ebx
testl %ebx, %ebx
je 0x8bb1
leaq 0x1298c(%rip), %rdi     # 0x1b52e
callq 0x8090
movl $0xf, %edi
callq 0x83a0
movl %ebx, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/sissm.c
// Function: sissm_terminal
int sissm_terminal( int argc, char *argv[] )
{
    int paramError = 1;
#ifdef _WIN32
    logPrintfInit( 2, "nul", 1 );
#else
    logPrintfInit( 2, "/dev/null", 1 );
#endif
    if ( argc == 5 ) {
        rdrvTerminal( argv[2], argv[3], argv[4] );
    }
    else if ( paramError ) {
        printf("\n\nSISSM RCON Terminal Tool\n./sissm -t [hostname/IP][port#][rconpassword]");
        printf("\nExample  ./sissm -t 127.0.0.1 27015 myRconPassword\n\n");
    }
    return 0;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %ebp
leaq 0x12459(%rip), %rsi     # 0x1b3ca
movl $0x2, %edi
movl $0x1, %edx
callq 0x1a1fc
cmpl $0x5, %ebp
jne 0x8f98
movq 0x10(%rbx), %rdi
movq 0x18(%rbx), %rsi
movq 0x20(%rbx), %rdx
callq 0x9946
jmp 0x8fb2
leaq 0x12435(%rip), %rdi     # 0x1b3d4
xorl %eax, %eax
callq 0x8180
leaq 0x125bb(%rip), %rdi     # 0x1b568
callq 0x8090
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/sissm.c
// Function: main
int main( int argc, char *argv[] ) 
{
    int errCode;
    int terminalMode = 0;

    if ( argc > 1 )  {
        if ( 0 == strncmp( argv[1], "-t", 2 ) )  {
            terminalMode = 1;
            errCode = sissm_terminal( argc, argv );
        }
    }
    if (!terminalMode) 
        errCode = sissm_main( argc, argv );

    return( errCode );

}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %ebp
cmpl $0x2, %edi
jl 0x8fe1
movq 0x8(%rbx), %rdi
leaq 0x1244a(%rip), %rsi     # 0x1b41d
movl $0x2, %edx
callq 0x8080
testl %eax, %eax
je 0x8ff1
movl %ebp, %edi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x8e57
movl %ebp, %edi
movq %rbx, %rsi
callq 0x8f62
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/cfs.c
// Function: cfsCreate
cfsPtr cfsCreate( char *fileName ) 
{
    cfsPtr pCfs = NULL;
    FILE    *fpr;

    if ( NULL != (fpr = fopen( fileName, "rt" )) ) {
        if ( NULL != (pCfs = (cfsPtr) calloc ( 1, sizeof( cfsObj )))) {
            strlcpy( pCfs->cfsFilename, fileName, CFS_FILENAME_MAX );
            pCfs->fpr = fpr;
        }
    }
    return( pCfs );
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x12e80(%rip), %rsi     # 0x1be93
callq 0x8320
testq %rax, %rax
je 0x9050
movq %rax, %r15
movl $0x1, %edi
movl $0x408, %esi            # imm = 0x408
callq 0x8210
testq %rax, %rax
je 0x9050
movq %rax, %r14
movl $0x400, %edx            # imm = 0x400
movq %rax, %rdi
movq %rbx, %rsi
callq 0xf038
movq %r15, 0x400(%r14)
jmp 0x9053
xorl %r14d, %r14d
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/cfs.c
// Function: cfsDestroy
void cfsDestroy( cfsPtr pCfs )
{
    if ( NULL != pCfs )  {
        if ( NULL != pCfs ) fclose( pCfs->fpr );
        free( pCfs );
    }
    return;
}

// Assembly:
testq %rdi, %rdi
je 0x907a
pushq %rbx
movq %rdi, %rbx
movq 0x400(%rdi), %rdi
callq 0x8100
movq %rbx, %rdi
popq %rbx
jmp 0x8040
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/cfs.c
// Function: cfsFetchNum
double cfsFetchNum( cfsPtr pCfs, char *varName, double defaultValue )
{
    double retValue;
    char   defaultValueString[256];
    char   *w;

    snprintf( defaultValueString, 256, "%lf", defaultValue );
    w = cfsFetchStr( pCfs, varName, defaultValueString );

    if ( 1 != sscanf( w, "%lf", &retValue )) retValue = defaultValue;

    return( retValue );
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x118, %rsp            # imm = 0x118
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x13e2f(%rip), %r15     # 0x1d0c0
leaq 0x10(%rsp), %r12
movl $0x100, %esi            # imm = 0x100
movq %r12, %rdi
movq %r15, %rdx
movsd %xmm0, 0x8(%rsp)
movb $0x1, %al
callq 0x8190
movq %r14, %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq 0x907b
leaq 0x22a7d(%rip), %rdi     # 0x2bd40
movq %rsp, %rdx
movq %r15, %rsi
xorl %eax, %eax
callq 0x82d0
cmpl $0x1, %eax
je 0x92e0
movsd 0x8(%rsp), %xmm0
movsd %xmm0, (%rsp)
movsd (%rsp), %xmm0
addq $0x118, %rsp            # imm = 0x118
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/rdrv.c
// Function: rdrvLogFile
void rdrvLogFile( char *buf, int n, char *fileName )
{
    int   i;
    FILE *fpw;

    if (fileName != NULL) {
        if (strlen( fileName ) != 0) {
            if (NULL != (fpw = fopen( fileName, "wb" ))) {
                for ( i = 0; i<n; i++ ) { fprintf( fpw, "%c", buf[i] ); }
                fclose( fpw );
            }
        }
    }
    return;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
testq %rdx, %rdx
je 0x9351
cmpb $0x0, (%rdx)
je 0x9351
movl %esi, %ebp
movq %rdi, %rbx
leaq 0x1228b(%rip), %rsi     # 0x1b59d
movq %rdx, %rdi
callq 0x8320
testq %rax, %rax
je 0x9351
movq %rax, %r14
testl %ebp, %ebp
jle 0x9341
movl %ebp, %r15d
xorl %r12d, %r12d
movsbl (%rbx,%r12), %edi
movq %r14, %rsi
callq 0x81e0
incq %r12
cmpq %r12, %r15
jne 0x932c
movq %r14, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x8100
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/rdrv.c
// Function: rdrvSend
int rdrvSend( rdrvObj *rPtr, int msgtype, char *rconcmd )
{
    char buf[BUFSIZE_T];
    int  errCode, outlen;
    // int  i;

    // bzero( buf, BUFSIZE_T );
    memset( buf, 0, BUFSIZE_T );
    buf[8] = msgtype;
    strlcpy( &buf[12], rconcmd, BUFSIZE_T-12 );
    buf[ strlen( rconcmd ) + 13 ] = 0 ;
    buf[ strlen( rconcmd ) + 14 ] = 0 ;
    outlen = (int) strlen( rconcmd ) + 14;
    buf[0] = outlen - 4;
    buf[4] = 1; buf[5] = 2; buf[6] = 3; buf[7] = 4;

    rPtr->serverlen = sizeof( rPtr->serveraddr );
    // sendto(fd, buf, outlen, 0, (const struct sockaddr *) &serveraddr, serverlen);
#ifdef _WIN32
    errCode = 0;
    // send( rPtr->sockfd, buf, outlen, 0);
    errCode = (-1 == send( rPtr->sockfd, buf, outlen, 0 ));
#else
    // errCode = write( rPtr->sockfd, buf, outlen );
    errCode = (-1 == send( rPtr->sockfd, buf, outlen, MSG_NOSIGNAL));
#endif

#if RDRV_DEBUGPRINT
    printf("Sent: ");
    for (i=0; i<outlen; i++) printf("%02x ", 0xff & buf[i]);  // printf("%03d %02x\n", i, buf[i]);
    printf("\n");
#endif

    return( errCode == -1 );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x400, %rsp            # imm = 0x400
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %r14
movq %rsp, %rbx
movl $0x400, %edx            # imm = 0x400
movq %rbx, %rdi
xorl %esi, %esi
callq 0x81b0
leaq 0xc(%rsp), %r12
movb %bpl, -0x4(%r12)
movl $0x3f4, %edx            # imm = 0x3F4
movq %r12, %rdi
movq %r15, %rsi
callq 0xf038
movq %r15, %rdi
callq 0x8120
movw $0x0, 0xd(%rax,%rbx)
leal 0xa(%rax), %ecx
movb %cl, -0xc(%r12)
movl $0x4030201, -0x8(%r12)  # imm = 0x4030201
movl $0x10, 0x168(%r14)
movl 0x154(%r14), %edi
addl $0xe, %eax
movslq %eax, %rdx
movq %rbx, %rsi
movl $0x4000, %ecx           # imm = 0x4000
callq 0x8160
xorl %eax, %eax
addq $0x400, %rsp            # imm = 0x400
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/rdrv.c
// Function: rdrvReceive
int rdrvReceive( rdrvObj *rPtr, char *bufin )
{
    int n, i;

    for ( i = 0; i<20; i++ ) {
#ifdef _WIN32
        n = recv( rPtr->sockfd, bufin, BUFSIZE_R, 0);
#else
        n = read( rPtr->sockfd, bufin, BUFSIZE_R );
#endif
        if ( n != -1 ) break;
        usleep( RDRV_DELAY_RCVPOLL20 ); 
   }
    if ( n != -1 ) {

#if RDRV_DEBUGPRINT
        printf("Rcvd: ");
        for (i=0; i<n; i++) printf("%02x ", 0xff & bufin[i]);  // printf("%03d %02x\n", i, bufin[i]);
        printf("\n");
#endif

        if ( n < RCVHDRSIZE ) {
            n = -1;
        }
        else {
            n = n - RCVHDRSIZE;
            if ( n != 0 ) {
                for (i = 0; i<n; i++) {
                    bufin[i] = bufin[i+RCVHDRSIZE];
                }
            }
        }
    }
    return( n );
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movl $0x14, %ebp
movl 0x154(%r14), %edi
movl $0x4000, %edx           # imm = 0x4000
movq %rbx, %rsi
callq 0x81f0
cmpl $-0x1, %eax
jne 0x942f
movl $0x186a0, %edi          # imm = 0x186A0
callq 0x83f0
decl %ebp
jne 0x9403
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
cmpl $0xc, %eax
jl 0x9457
movl %eax, %ebp
addl $-0xc, %ebp
je 0x9455
cmpl $0xc, %eax
je 0x9457
leaq 0xc(%rbx), %rsi
movl %ebp, %edx
movq %rbx, %rdi
callq 0x8300
jmp 0x9457
xorl %ebp, %ebp
movl %ebp, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/rdrv.c
// Function: rdrvInit
rdrvObj *rdrvInit( char *hostName, int portNo, char *rconPassword )
{
#ifdef _WIN32
    WSADATA  wsaData;
#endif
    rdrvObj *rPtr;

    rPtr = (rdrvObj *) calloc( 1, sizeof( rdrvObj ) );
    rPtr->isConnected = 0;
    if (NULL != rPtr) {
        rPtr->sockfd = -1;
        strlcpy(rPtr->rconPassword, rconPassword, RCONPASSMAX);
        rPtr->portNo = portNo;
        strlcpy(rPtr->hostName, hostName, RCONHOSTMAX);
#ifdef _WIN32
        WSAStartup(MAKEWORD(2,2), &wsaData);
#endif
    }
    return( rPtr );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %r15
movl %esi, %ebp
movq %rdi, %rbx
movl $0x1, %edi
movl $0x170, %esi            # imm = 0x170
callq 0x8210
movq %rax, %r14
movl $0x0, 0x16c(%rax)
testq %rax, %rax
je 0x9680
movl $0xffffffff, 0x154(%r14) # imm = 0xFFFFFFFF
movq %r14, %rdi
addq $0x104, %rdi            # imm = 0x104
movl $0x50, %edx
movq %r15, %rsi
callq 0xf038
movl %ebp, 0x100(%r14)
movl $0x100, %edx            # imm = 0x100
movq %r14, %rdi
movq %rbx, %rsi
callq 0xf038
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/rdrv.c
// Function: rdrvXmtRcv
int rdrvXmtRcv( rdrvObj *rPtr, int msgType, char *rconCmd, char *rconResp )
{
    int n, errCode = 0, retryCount = 0;

    while ( retryCount++ < 5 ) {
        if ( 0 == (errCode = rdrvSend( rPtr, msgType, rconCmd ))) {
            usleep( RDRV_DELAY_XMT2RCV );
            n = rdrvReceive( rPtr, rconResp );
            if ( n >= 0 ) break;
            if ( n <  0 ) usleep( RDRV_DELAY_RETRANSMIT );
        }
    }
    if ( errCode || ( retryCount >= 5) ) n = -1;
    
    return( n );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r14
movl %esi, %ebp
movq %rdi, %r15
callq 0x935a
movl $0x2710, %edi           # imm = 0x2710
callq 0x83f0
movq %r15, %rdi
movq %rbx, %rsi
callq 0x93f4
testl %eax, %eax
jns 0x973f
xorl %r12d, %r12d
movl $0x7a120, %edi          # imm = 0x7A120
callq 0x83f0
cmpl $0x4, %r12d
je 0x973a
movq %r15, %rdi
movl %ebp, %esi
movq %r14, %rdx
callq 0x935a
movl $0x2710, %edi           # imm = 0x2710
callq 0x83f0
movq %r15, %rdi
movq %rbx, %rsi
callq 0x93f4
incl %r12d
testl %eax, %eax
js 0x96f3
cmpl $0x4, %r12d
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmovael %ecx, %eax
jmp 0x973f
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/schroeder-lvb[P]sissm/src/rdrv.c
// Function: rdrvCommand
int rdrvCommand( rdrvObj *rPtr, int msgType, char *rconCmd, char *rconResp, int *bytesRead )
{
    int         bytesRead2, errCode;
    static char rconRespCont[BUFSIZE_R];                // for receiving continuation buffer
    static char *rconCmdBlank = "";                               // for sending null string  

    errCode = _rdrvCommand( rPtr, msgType, rconCmd, rconResp, bytesRead );

    while (0 == errCode ) {

        // The above response code postfixes the data with "0x00 0x00" representing end of message
        // BUT this "0x00 0x00" will be missing if data has additional continuation packet(s)
        //
        errCode = _rdrvCommand( rPtr, 0, rconCmdBlank, rconRespCont, &bytesRead2 );
        if ( bytesRead2 <= 2) break;    // if there is no continuation, break out

        logPrintf(LOG_LEVEL_INFO, "rdrv", "Continuation RCON packet %02x %02x %02x containing ::%s::", 
            rconRespCont[0], rconRespCont[1], rconRespCont[2], &rconRespCont[3] );

        // Concatenate the continuation data to the end of master receive buffer
        // First 3 bytes of cont response should be { 0x00 0x00 0x80 } so we skip that
        //
        if (( *bytesRead + bytesRead2 - 3 ) >=  BUFSIZE_R ) break;   // memory bounds safety check
        memcpy( &rconResp[ *bytesRead ], &rconRespCont[ 3 ], bytesRead2 - 3 );
        *bytesRead += (bytesRead2 - 3);          // update totoal size not including 3 byte header
        
    }

    return( errCode );
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r8, %rbx
movq %rcx, %r14
movq %rdi, %r15
callq 0x9817
movl %eax, %r12d
testl %eax, %eax
je 0x977d
movl %r12d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x231bf(%rip), %r13     # 0x2c943
movq %r15, %rdi
xorl %esi, %esi
leaq 0x11f81(%rip), %rdx     # 0x1b711
leaq 0x231a9(%rip), %rcx     # 0x2c940
leaq 0x14(%rsp), %r8
callq 0x9817
movl %eax, %r12d
movslq 0x14(%rsp), %rbp
cmpq $0x3, %rbp
jl 0x976b
movsbl 0x2318a(%rip), %ecx     # 0x2c940
movsbl 0x23183(%rip), %r8d     # 0x2c941
movsbl 0x2317c(%rip), %r9d     # 0x2c942
movq %r13, (%rsp)
movl $0x2, %edi
leaq 0x11dca(%rip), %rsi     # 0x1b5a0
leaq 0x11e40(%rip), %rdx     # 0x1b61d
xorl %eax, %eax
callq 0x1a227
movslq (%rbx), %rdi
leal (%rdi,%rbp), %eax
cmpl $0x4002, %eax           # imm = 0x4002
jg 0x976b
addq %r14, %rdi
addq $-0x3, %rbp
movq %r13, %rsi
movq %rbp, %rdx
callq 0x8290
addl %ebp, (%rbx)
testl %r12d, %r12d
je 0x9784
jmp 0x976b