LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image.hpp
// Function: stbi__hdr_gettoken(stbi__context*, char*)
static char *stbi__hdr_gettoken(stbi__context *z, char *buffer)
{
   int len=0;
   char c = '\0';

   c = (char) stbi__get8(z);

   while (!stbi__at_eof(z) && c != '\n') {
      buffer[len++] = c;
      if (len == STBI__HDR_BUFLEN-1) {
         // flush to end of line
         while (!stbi__at_eof(z) && stbi__get8(z) != '\n')
            ;
         break;
      }
      c = (char) stbi__get8(z);
   }

   buffer[len] = 0;
   return buffer;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0xb8(%rdi), %rax
cmpq 0xc0(%rdi), %rax
jb 0x2269e
cmpl $0x0, 0x30(%r14)
je 0x22674
movq 0x28(%r14), %rdi
leaq 0x38(%r14), %r15
movl 0x34(%r14), %edx
movq %r15, %rsi
callq *0x10(%r14)
testl %eax, %eax
je 0x22678
movq %r15, 0xb8(%r14)
cltq
addq %r15, %rax
movq %rax, 0xc0(%r14)
jmp 0x22697
xorl %ebp, %ebp
jmp 0x226ac
movl $0x0, 0x30(%r14)
movq %r15, 0xb8(%r14)
leaq 0x39(%r14), %rax
movq %rax, 0xc0(%r14)
movb $0x0, 0x38(%r14)
movq 0xb8(%r14), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0xb8(%r14)
movb (%rax), %bpl
leaq 0x38(%r14), %r15
leaq 0x39(%r14), %r12
xorl %r13d, %r13d
cmpq $0x0, 0x10(%r14)
je 0x226d1
movq 0x28(%r14), %rdi
callq *0x20(%r14)
testl %eax, %eax
je 0x226e4
cmpl $0x0, 0x30(%r14)
je 0x226e8
movq 0xb8(%r14), %rax
cmpq 0xc0(%r14), %rax
setb %al
jmp 0x226ea
movb $0x1, %al
jmp 0x226ea
xorl %eax, %eax
cmpb $0xa, %bpl
je 0x2282d
testb %al, %al
je 0x2282d
movb %bpl, (%rbx,%r13)
cmpq $0x3fe, %r13            # imm = 0x3FE
je 0x22784
movq 0xb8(%r14), %rax
cmpq 0xc0(%r14), %rax
jb 0x2276e
cmpl $0x0, 0x30(%r14)
je 0x22748
movq 0x28(%r14), %rdi
movl 0x34(%r14), %edx
movq %r15, %rsi
callq *0x10(%r14)
testl %eax, %eax
je 0x2274c
movq %r15, 0xb8(%r14)
cltq
addq %r15, %rax
movq %rax, 0xc0(%r14)
jmp 0x22767
xorl %ebp, %ebp
jmp 0x2277c
movl $0x0, 0x30(%r14)
movq %r15, 0xb8(%r14)
movq %r12, 0xc0(%r14)
movb $0x0, 0x38(%r14)
movq 0xb8(%r14), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0xb8(%r14)
movb (%rax), %bpl
incq %r13
jmp 0x226b7
cmpq $0x0, 0x10(%r14)
je 0x227a2
movq 0x28(%r14), %rdi
callq *0x20(%r14)
testl %eax, %eax
je 0x227b2
cmpl $0x0, 0x30(%r14)
je 0x22827
movq 0xb8(%r14), %rax
cmpq 0xc0(%r14), %rax
jae 0x22827
movq 0xb8(%r14), %rax
cmpq 0xc0(%r14), %rax
jb 0x22813
cmpl $0x0, 0x30(%r14)
je 0x22784
movq 0x28(%r14), %rdi
movl 0x34(%r14), %edx
movq %r15, %rsi
callq *0x10(%r14)
testl %eax, %eax
je 0x227f1
movq %r15, 0xb8(%r14)
cltq
addq %r15, %rax
movq %rax, 0xc0(%r14)
jmp 0x2280c
movl $0x0, 0x30(%r14)
movq %r15, 0xb8(%r14)
movq %r12, 0xc0(%r14)
movb $0x0, 0x38(%r14)
movq 0xb8(%r14), %rax
leaq 0x1(%rax), %rcx
movq %rcx, 0xb8(%r14)
cmpb $0xa, (%rax)
jne 0x22784
movl $0x3ff, %r13d           # imm = 0x3FF
movb $0x0, (%rbx,%r13)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image.hpp
// Function: stbi__hdr_convert(float*, unsigned char*, int)
static void stbi__hdr_convert(float *output, stbi_uc *input, int req_comp)
{
   if ( input[3] != 0 ) {
      float f1;
      // Exponent
      f1 = (float) ldexp(1.0f, input[3] - (int)(128 + 8));
      if (req_comp <= 2)
         output[0] = (input[0] + input[1] + input[2]) * f1 / 3;
      else {
         output[0] = input[0] * f1;
         output[1] = input[1] * f1;
         output[2] = input[2] * f1;
      }
      if (req_comp == 2) output[1] = 1;
      if (req_comp == 4) output[3] = 1;
   } else {
      switch (req_comp) {
         case 4: output[3] = 1; /* fallthrough */
         case 3: output[0] = output[1] = output[2] = 0;
                 break;
         case 2: output[1] = 1; /* fallthrough */
         case 1: output[0] = 0;
                 break;
      }
   }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edx, %r14d
movq %rdi, %rbx
movzbl 0x3(%rsi), %edi
testl %edi, %edi
je 0x2289b
movq %rsi, %r15
addl $0xffffff78, %edi       # imm = 0xFFFFFF78
movss 0xa3ac(%rip), %xmm0     # 0x2cc14
callq 0x4420
movzbl (%r15), %eax
cmpl $0x2, %r14d
jg 0x228c7
movzbl 0x1(%r15), %ecx
addl %eax, %ecx
movzbl 0x2(%r15), %eax
addl %ecx, %eax
cvtsi2ss %eax, %xmm1
mulss %xmm1, %xmm0
divss 0xa387(%rip), %xmm0     # 0x2cc1c
movss %xmm0, (%rbx)
jmp 0x228fd
decl %r14d
cmpl $0x3, %r14d
ja 0x22930
leaq 0xa4a9(%rip), %rax      # 0x2cd58
movslq (%rax,%r14,4), %rcx
addq %rax, %rcx
jmpq *%rcx
movl $0x3f800000, 0x4(%rbx)  # imm = 0x3F800000
movl $0x0, (%rbx)
jmp 0x22930
cvtsi2ss %eax, %xmm1
mulss %xmm0, %xmm1
movss %xmm1, (%rbx)
movzbl 0x1(%r15), %eax
xorps %xmm1, %xmm1
cvtsi2ss %eax, %xmm1
mulss %xmm0, %xmm1
movss %xmm1, 0x4(%rbx)
movzbl 0x2(%r15), %eax
xorps %xmm1, %xmm1
cvtsi2ss %eax, %xmm1
mulss %xmm0, %xmm1
movss %xmm1, 0x8(%rbx)
cmpl $0x4, %r14d
je 0x22912
cmpl $0x2, %r14d
jne 0x22930
movl $0x3f800000, 0x4(%rbx)  # imm = 0x3F800000
jmp 0x22930
movl $0x3f800000, 0xc(%rbx)  # imm = 0x3F800000
jmp 0x22930
movl $0x3f800000, 0xc(%rbx)  # imm = 0x3F800000
movl $0x0, 0x8(%rbx)
movq $0x0, (%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image.hpp
// Function: stbi__fill_bits(stbi__zbuf*)
static void stbi__fill_bits(stbi__zbuf *z)
{
   do {
      STBI_ASSERT(z->code_buffer < (1U << z->num_bits));
      z->code_buffer |= (unsigned int) stbi__zget8(z) << z->num_bits;
      z->num_bits += 8;
   } while (z->num_bits <= 24);
}

// Assembly:
pushq %rax
movl 0x10(%rdi), %ecx
movl 0x14(%rdi), %eax
movl %eax, %edx
shrl %cl, %edx
testl %edx, %edx
jne 0x22b6f
movq (%rdi), %rsi
xorl %edx, %edx
cmpq 0x8(%rdi), %rsi
jae 0x22b59
leaq 0x1(%rsi), %rdx
movq %rdx, (%rdi)
movzbl (%rsi), %edx
shll %cl, %edx
orl %edx, %eax
movl %eax, 0x14(%rdi)
leal 0x8(%rcx), %edx
movl %edx, 0x10(%rdi)
cmpl $0x11, %ecx
movl %edx, %ecx
jl 0x22b3c
popq %rax
retq
leaq 0xad6a(%rip), %rdi      # 0x2d8e0
leaq 0xa75c(%rip), %rsi      # 0x2d2d9
leaq 0xad81(%rip), %rcx      # 0x2d905
movl $0xdee, %edx            # imm = 0xDEE
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image.hpp
// Function: stbi__zexpand(stbi__zbuf*, char*, int)
static int stbi__zexpand(stbi__zbuf *z, char *zout, int n)  // need to make room for n bytes
{
   char *q;
   int cur, limit, old_limit;
   z->zout = zout;
   if (!z->z_expandable) return stbi__err("output buffer limit","Corrupt PNG");
   cur   = (int) (z->zout     - z->zout_start);
   limit = old_limit = (int) (z->zout_end - z->zout_start);
   while (cur + n > limit)
      limit *= 2;
   q = (char *) STBI_REALLOC_SIZED(z->zout_start, old_limit, limit);
   STBI_NOTUSED(old_limit);
   if (q == NULL) return stbi__err("outofmem", "Out of memory");
   z->zout_start = q;
   z->zout       = q + cur;
   z->zout_end   = q + limit;
   return 1;
}

// Assembly:
movq %rsi, 0x18(%rdi)
cmpl $0x0, 0x30(%rdi)
je 0x22be7
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movq 0x20(%rdi), %rdi
subq %rdi, %r14
movl 0x28(%rbx), %eax
subl %edi, %eax
addl %r14d, %edx
movl %eax, %ecx
leal (%rcx,%rcx), %eax
cmpl %ecx, %edx
jg 0x22bb2
movslq %ecx, %r15
movq %r15, %rsi
callq 0x4520
testq %rax, %rax
je 0x22bf8
movq %rax, 0x20(%rbx)
movslq %r14d, %rcx
addq %rax, %rcx
movq %rcx, 0x18(%rbx)
addq %rax, %r15
movq %r15, 0x28(%rbx)
movl $0x1, %eax
jmp 0x22c08
leaq 0xad9a(%rip), %rax      # 0x2d988
movq %rax, 0x157bb(%rip)     # 0x383b0
xorl %eax, %eax
retq
leaq 0xa60a(%rip), %rax      # 0x2d209
movq %rax, 0x157aa(%rip)     # 0x383b0
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image.hpp
// Function: stbi__psd_info(stbi__context*, int*, int*, int*)
static int stbi__psd_info(stbi__context *s, int *x, int *y, int *comp)
{
   int channelCount;
   if (stbi__get32be(s) != 0x38425053) {
       stbi__rewind( s );
       return 0;
   }
   if (stbi__get16be(s) != 1) {
       stbi__rewind( s );
       return 0;
   }
   stbi__skip(s, 6);
   channelCount = stbi__get16be(s);
   if (channelCount < 0 || channelCount > 16) {
       stbi__rewind( s );
       return 0;
   }
   *y = stbi__get32be(s);
   *x = stbi__get32be(s);
   if (stbi__get16be(s) != 8) {
       stbi__rewind( s );
       return 0;
   }
   if (stbi__get16be(s) != 3) {
       stbi__rewind( s );
       return 0;
   }
   *comp = 4;
   return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r14
movq %rdx, %r12
movq %rsi, %r15
movq %rdi, %rbx
callq 0x1e01c
movl %eax, %ebp
shll $0x10, %ebp
movq %rbx, %rdi
callq 0x1e01c
orl %ebp, %eax
cmpl $0x38425053, %eax       # imm = 0x38425053
jne 0x22cf8
movq %rbx, %rdi
callq 0x1e01c
cmpl $0x1, %eax
jne 0x22cf8
cmpq $0x0, 0x10(%rbx)
je 0x22c86
movq 0xc0(%rbx), %rcx
movl 0xb8(%rbx), %edx
movl %ecx, %eax
subl %edx, %eax
cmpl $0x5, %eax
jg 0x22c86
movq %rcx, 0xb8(%rbx)
movq 0x28(%rbx), %rdi
movl $0x6, %esi
subl %eax, %esi
callq *0x18(%rbx)
jmp 0x22c8e
addq $0x6, 0xb8(%rbx)
movq %rbx, %rdi
callq 0x1e01c
cmpl $0x11, %eax
jae 0x22cf8
movq %rbx, %rdi
callq 0x1e01c
movl %eax, %ebp
shll $0x10, %ebp
movq %rbx, %rdi
callq 0x1e01c
orl %ebp, %eax
movl %eax, (%r12)
movq %rbx, %rdi
callq 0x1e01c
movl %eax, %ebp
shll $0x10, %ebp
movq %rbx, %rdi
callq 0x1e01c
orl %ebp, %eax
movl %eax, (%r15)
movq %rbx, %rdi
callq 0x1e01c
cmpl $0x8, %eax
jne 0x22cf8
movq %rbx, %rdi
callq 0x1e01c
cmpl $0x3, %eax
jne 0x22cf8
movl $0x4, (%r14)
movl $0x1, %eax
jmp 0x22d08
movups 0xc8(%rbx), %xmm0
movups %xmm0, 0xb8(%rbx)
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image.hpp
// Function: stbi__hdr_info(stbi__context*, int*, int*, int*)
static int stbi__hdr_info(stbi__context *s, int *x, int *y, int *comp)
{
   char buffer[STBI__HDR_BUFLEN];
   char *token;
   int valid = 0;

   if (stbi__hdr_test(s) == 0) {
       stbi__rewind( s );
       return 0;
   }

   for(;;) {
      token = stbi__hdr_gettoken(s,buffer);
      if (token[0] == 0) break;
      if (strcmp(token, "FORMAT=32-bit_rle_rgbe") == 0) valid = 1;
   }

   if (!valid) {
       stbi__rewind( s );
       return 0;
   }
   token = stbi__hdr_gettoken(s,buffer);
   if (strncmp(token, "-Y ", 3)) {
       stbi__rewind( s );
       return 0;
   }
   token += 3;
   *y = (int) strtol(token, &token, 10);
   while (*token == ' ') ++token;
   if (strncmp(token, "+X ", 3)) {
       stbi__rewind( s );
       return 0;
   }
   token += 3;
   *x = (int) strtol(token, NULL, 10);
   *comp = 3;
   return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x418, %rsp            # imm = 0x418
movq %rcx, %rbx
movq %rdx, %r12
movq %rsi, %r14
movq %rdi, %r15
callq 0x14d2f
testl %eax, %eax
je 0x23218
leaq 0x10(%rsp), %r13
movq %r15, %rdi
movq %r13, %rsi
callq 0x22620
cmpb $0x0, (%r13)
je 0x23214
movq %rbx, 0x8(%rsp)
xorl %ebp, %ebp
movl $0x1, %ebx
leaq 0x10(%rsp), %r13
movdqu 0x17(%rsp), %xmm0
pcmpeqb 0x9b16(%rip), %xmm0     # 0x2cc50
movdqa 0x10(%rsp), %xmm1
pcmpeqb 0x9b18(%rip), %xmm1     # 0x2cc60
pand %xmm0, %xmm1
pmovmskb %xmm1, %eax
cmpl $0xffff, %eax           # imm = 0xFFFF
cmovel %ebx, %ebp
movq %r15, %rdi
movq %r13, %rsi
callq 0x22620
cmpb $0x0, 0x10(%rsp)
jne 0x2312c
movq %r13, (%rsp)
testl %ebp, %ebp
je 0x23218
movq %r15, %rdi
movq %r13, %rsi
callq 0x22620
movl $0x592d, %eax           # imm = 0x592D
xorl 0x10(%rsp), %eax
movq %r13, (%rsp)
movzbl 0x12(%rsp), %ecx
xorl $0x20, %ecx
orw %ax, %cx
jne 0x23218
leaq 0x13(%rsp), %rdi
movq %rsp, %r13
movq %rdi, (%r13)
movq %r13, %rsi
movl $0xa, %edx
callq 0x4450
movl %eax, (%r12)
movq (%r13), %r12
decq %r12
cmpb $0x20, 0x1(%r12)
leaq 0x1(%r12), %r12
je 0x231bf
movq %r12, (%rsp)
leaq 0xa662(%rip), %rsi      # 0x2d839
movl $0x3, %edx
movq %r12, %rdi
callq 0x4180
testl %eax, %eax
movq 0x8(%rsp), %rbx
jne 0x23218
addq $0x3, %r12
movq %r12, (%rsp)
movq %r12, %rdi
xorl %esi, %esi
movl $0xa, %edx
callq 0x4450
movl %eax, (%r14)
movl $0x3, (%rbx)
movl $0x1, %eax
jmp 0x2322c
movq %r13, (%rsp)
movdqu 0xc8(%r15), %xmm0
movdqu %xmm0, 0xb8(%r15)
xorl %eax, %eax
addq $0x418, %rsp            # imm = 0x418
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbi_write_bmp
STBIWDEF int stbi_write_bmp(char const *filename, int x, int y, int comp, const void *data)
{
   stbi__write_context s;
   if (stbi__start_write_file(&s,filename)) {
      int r = stbi_write_bmp_core(&s, x, y, comp, data);
      stbi__end_write_file(&s);
      return r;
   } else
      return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %rbx
movl %ecx, %ebp
movl %edx, %r14d
movl %esi, %r12d
leaq 0xa8c5(%rip), %rsi      # 0x2e12f
callq 0x4380
movq %rax, %r15
leaq 0x1f09(%rip), %rax      # 0x25782
movq %rax, (%rsp)
movq %r15, 0x8(%rsp)
testq %r15, %r15
je 0x238a6
movq %rsp, %rdi
movl %r12d, %esi
movl %r14d, %edx
movl %ebp, %ecx
movq %rbx, %r8
callq 0x237e7
movl %eax, %ebx
movq %r15, %rdi
callq 0x4300
jmp 0x238a8
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbi_write_tga
int stbi_write_tga(char const *filename, int x, int y, int comp, const void *data)
{
   stbi__write_context s;
   if (stbi__start_write_file(&s,filename)) {
      int r = stbi_write_tga_core(&s, x, y, comp, (void *) data);
      stbi__end_write_file(&s);
      return r;
   } else
      return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %rbx
movl %ecx, %ebp
movl %edx, %r14d
movl %esi, %r12d
leaq 0xa48b(%rip), %rsi      # 0x2e12f
callq 0x4380
movq %rax, %r15
leaq 0x1acf(%rip), %rax      # 0x25782
movq %rax, (%rsp)
movq %r15, 0x8(%rsp)
testq %r15, %r15
je 0x23ce0
movq %rsp, %rdi
movl %r12d, %esi
movl %r14d, %edx
movl %ebp, %ecx
movq %rbx, %r8
callq 0x238de
movl %eax, %ebx
movq %r15, %rdi
callq 0x4300
jmp 0x23ce2
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__linear_to_rgbe(unsigned char*, float*)
void stbiw__linear_to_rgbe(unsigned char *rgbe, float *linear)
{
   int exponent;
   float maxcomp = stbiw__max(linear[0], stbiw__max(linear[1], linear[2]));

   if (maxcomp < 1e-32f) {
      rgbe[0] = rgbe[1] = rgbe[2] = rgbe[3] = 0;
   } else {
      float normalize = (float) frexp(maxcomp, &exponent) * 256.0f/maxcomp;

      rgbe[0] = (unsigned char)(linear[0] * normalize);
      rgbe[1] = (unsigned char)(linear[1] * normalize);
      rgbe[2] = (unsigned char)(linear[2] * normalize);
      rgbe[3] = (unsigned char)(exponent + 128);
   }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movss (%rsi), %xmm1
movss 0x4(%rsi), %xmm2
maxss 0x8(%rsi), %xmm2
movaps %xmm1, %xmm0
maxss %xmm2, %xmm0
movss 0x9d0e(%rip), %xmm2     # 0x2da28
ucomiss %xmm0, %xmm2
jbe 0x23d27
movl $0x0, (%rbx)
jmp 0x23d87
movq %rsi, %r14
leaq 0xc(%rsp), %r15
movq %r15, %rdi
movss %xmm1, 0x8(%rsp)
movss %xmm0, 0x4(%rsp)
callq 0x40c0
movb (%r15), %al
mulss 0x9cde(%rip), %xmm0     # 0x2da2c
divss 0x4(%rsp), %xmm0
movss 0x8(%rsp), %xmm1
mulss %xmm0, %xmm1
cvttss2si %xmm1, %ecx
movb %cl, (%rbx)
movss 0x4(%r14), %xmm1
mulss %xmm0, %xmm1
cvttss2si %xmm1, %ecx
movb %cl, 0x1(%rbx)
mulss 0x8(%r14), %xmm0
cvttss2si %xmm0, %ecx
movb %cl, 0x2(%rbx)
addb $-0x80, %al
movb %al, 0x3(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__write_run_data(stbi__write_context*, int, unsigned char)
void stbiw__write_run_data(stbi__write_context *s, int length, unsigned char databyte)
{
   unsigned char lengthbyte = STBIW_UCHAR(length+128);
   STBIW_ASSERT(length+128 <= 255);
   s->func(s->context, &lengthbyte, 1);
   s->func(s->context, &databyte, 1);
}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movb %dl, 0xf(%rsp)
leal -0x80(%rsi), %eax
movb %al, 0xe(%rsp)
cmpl $0x80, %esi
jge 0x23dd2
movq %rdi, %rbx
movq 0x8(%rdi), %rdi
leaq 0xe(%rsp), %rsi
movl $0x1, %edx
callq *(%rbx)
movq 0x8(%rbx), %rdi
leaq 0xf(%rsp), %rsi
movl $0x1, %edx
callq *(%rbx)
addq $0x10, %rsp
popq %rbx
retq
leaq 0xa1c7(%rip), %rdi      # 0x2dfa0
leaq 0xa1d2(%rip), %rsi      # 0x2dfb2
leaq 0xa1e8(%rip), %rcx      # 0x2dfcf
movl $0x1f5, %edx            # imm = 0x1F5
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__write_dump_data(stbi__write_context*, int, unsigned char*)
void stbiw__write_dump_data(stbi__write_context *s, int length, unsigned char *data)
{
   unsigned char lengthbyte = STBIW_UCHAR(length);
   STBIW_ASSERT(length <= 128); // inconsistent with spec but consistent with official code
   s->func(s->context, &lengthbyte, 1);
   s->func(s->context, data, length);
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %esi, %ebp
movb %bpl, 0xf(%rsp)
cmpl $0x81, %esi
jge 0x23e32
movq %rdx, %r14
movq %rdi, %rbx
movq 0x8(%rdi), %rdi
leaq 0xf(%rsp), %rsi
movl $0x1, %edx
callq *(%rbx)
movq 0x8(%rbx), %rdi
movq %r14, %rsi
movl %ebp, %edx
callq *(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
leaq 0xa1dc(%rip), %rdi      # 0x2e015
leaq 0xa172(%rip), %rsi      # 0x2dfb2
leaq 0xa1dc(%rip), %rcx      # 0x2e023
movl $0x1fd, %edx            # imm = 0x1FD
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbi_write_hdr_core(stbi__write_context*, int, int, int, float*)
static int stbi_write_hdr_core(stbi__write_context *s, int x, int y, int comp, float *data)
{
   if (y <= 0 || x <= 0 || data == NULL)
      return 0;
   else {
      // Each component is stored separately. Allocate scratch space for full output scanline.
      unsigned char *scratch = (unsigned char *) STBIW_MALLOC(x*4);
      int i, len;
      char buffer[128];
      char header[] = "#?RADIANCE\n# Written by stb_image_write.h\nFORMAT=32-bit_rle_rgbe\n";
      s->func(s->context, header, sizeof(header)-1);

      len = sprintf(buffer, "EXPOSURE=          1.0000000000000\n\n-Y %d +X %d\n", y, x);
      s->func(s->context, buffer, len);

      for(i=0; i < y; i++)
         stbiw__write_hdr_scanline(s, x, comp, scratch, data + comp*i*x);
      STBIW_FREE(scratch);
      return 1;
   }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movl %ecx, 0x4(%rsp)
movl %edx, %ebp
movq %rdi, 0x8(%rsp)
testl %edx, %edx
setle %al
testl %esi, %esi
setle %cl
orb %al, %cl
testq %r8, %r8
sete %dl
xorl %eax, %eax
orb %cl, %dl
jne 0x24366
movl %esi, %r14d
leal (,%r14,4), %edi
movq %r8, %r15
callq 0x4400
movq %rax, %r12
leaq 0x9f2a(%rip), %rsi      # 0x2e200
leaq 0x90(%rsp), %rax
movl $0x8, %ecx
movq %rax, %rdi
rep  movsq (%rsi), %es:(%rdi)
movw $0xa, 0x40(%rax)
movq 0x8(%rsp), %rbx
movq 0x8(%rbx), %rdi
movq %rax, %rsi
movl $0x41, %edx
callq *(%rbx)
leaq 0x9e9b(%rip), %rsi      # 0x2e1a4
xorl %r13d, %r13d
leaq 0x10(%rsp), %rdi
movl %ebp, %edx
movl %r14d, %ecx
xorl %eax, %eax
callq 0x40b0
movq 0x8(%rbx), %rdi
leaq 0x10(%rsp), %rsi
movl %eax, %edx
callq *(%rbx)
movl %ebp, %eax
movl 0x4(%rsp), %ebp
imull %r14d, %ebp
movl %eax, %ebx
movslq %r13d, %r13
leaq (%r15,%r13,4), %r8
movq 0x8(%rsp), %rdi
movl %r14d, %esi
movl 0x4(%rsp), %edx
movq %r12, %rcx
callq 0x23e51
addl %ebp, %r13d
decq %rbx
jne 0x24336
movq %r12, %rdi
callq 0x4390
movl $0x1, %eax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbi_write_hdr
int stbi_write_hdr(char const *filename, int x, int y, int comp, const float *data)
{
   stbi__write_context s;
   if (stbi__start_write_file(&s,filename)) {
      int r = stbi_write_hdr_core(&s, x, y, comp, (float *) data);
      stbi__end_write_file(&s);
      return r;
   } else
      return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %rbx
movl %ecx, %ebp
movl %edx, %r14d
movl %esi, %r12d
leaq 0x9d99(%rip), %rsi      # 0x2e12f
callq 0x4380
movq %rax, %r15
leaq 0x13dd(%rip), %rax      # 0x25782
movq %rax, (%rsp)
movq %r15, 0x8(%rsp)
testq %r15, %r15
je 0x243d2
movq %rsp, %rdi
movl %r12d, %esi
movl %r14d, %edx
movl %ebp, %ecx
movq %rbx, %r8
callq 0x24281
movl %eax, %ebx
movq %r15, %rdi
callq 0x4300
jmp 0x243d4
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__sbgrowf(void**, int, int)
static void *stbiw__sbgrowf(void **arr, int increment, int itemsize)
{
   int m = *arr ? 2*stbiw__sbm(*arr)+increment : increment+1;
   void *p = STBIW_REALLOC_SIZED(*arr ? stbiw__sbraw(*arr) : 0, *arr ? (stbiw__sbm(*arr)*itemsize + sizeof(int)*2) : 0, itemsize * m + sizeof(int)*2);
   STBIW_ASSERT(p);
   if (p) {
      if (!*arr) ((int *) p)[1] = 0;
      *arr = (void *) ((int *) p + 2);
      stbiw__sbm(*arr) = m;
   }
   return *arr;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x24c32
movl -0x8(%rax), %ecx
leal 0x1(,%rcx,2), %ebp
jmp 0x24c37
movl $0x2, %ebp
leaq -0x8(%rax), %rdi
testq %rax, %rax
cmoveq %rax, %rdi
imull %ebp, %esi
movslq %esi, %rsi
addq $0x8, %rsi
callq 0x4520
testq %rax, %rax
je 0x24c76
cmpq $0x0, (%rbx)
jne 0x24c63
movl $0x0, 0x4(%rax)
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, (%rbx)
movl %ebp, (%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0x73aa(%rip), %rdi      # 0x2c027
leaq 0x932e(%rip), %rsi      # 0x2dfb2
leaq 0x954a(%rip), %rcx      # 0x2e1d5
movl $0x29b, %edx            # imm = 0x29B
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__zlib_flushf(unsigned char*, unsigned int*, int*)
static unsigned char *stbiw__zlib_flushf(unsigned char *data, unsigned int *bitbuffer, int *bitcount)
{
   while (*bitcount >= 8) {
      stbiw__sbpush(data, STBIW_UCHAR(*bitbuffer));
      *bitbuffer >>= 8;
      *bitcount -= 8;
   }
   return data;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, 0x8(%rsp)
cmpl $0x8, (%rdx)
jl 0x24cf9
movq %rdx, %rbx
movq %rsi, %r14
leaq 0x8(%rsp), %r15
movq 0x8(%rsp), %rax
testq %rax, %rax
je 0x24cc7
movl -0x4(%rax), %ecx
incl %ecx
cmpl -0x8(%rax), %ecx
jl 0x24cd4
movq %r15, %rdi
movl $0x1, %esi
callq 0x24c18
movb (%r14), %al
movq 0x8(%rsp), %rcx
movslq -0x4(%rcx), %rdx
leal 0x1(%rdx), %esi
movl %esi, -0x4(%rcx)
movb %al, (%rcx,%rdx)
shrl $0x8, (%r14)
movl (%rbx), %eax
leal -0x8(%rax), %ecx
movl %ecx, (%rbx)
cmpl $0xf, %eax
jg 0x24cb3
movq 0x8(%rsp), %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbi_write_png
STBIWDEF int stbi_write_png(char const *filename, int x, int y, int comp, const void *data, int stride_bytes)
{
   FILE *f;
   int len;
   unsigned char *png = stbi_write_png_to_mem((unsigned char *) data, stride_bytes, x, y, comp, &len);
   if (png == NULL) return 0;
   f = fopen(filename, "wb");
   if (!f) { STBIW_FREE(png); return 0; }
   fwrite(png, 1, len, f);
   fclose(f);
   STBIW_FREE(png);
   return 1;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %r9d, %r10d
movl %ecx, %eax
movl %edx, %ecx
movl %esi, %edx
movq %rdi, %r14
leaq 0xc(%rsp), %r9
movq %r8, %rdi
movl %r10d, %esi
movl %eax, %r8d
callq 0x24d08
testq %rax, %rax
je 0x25371
movq %rax, %rbx
leaq 0x8df2(%rip), %rsi      # 0x2e12f
movq %r14, %rdi
callq 0x4380
testq %rax, %rax
je 0x25375
movq %rax, %r14
movslq 0xc(%rsp), %rdx
movl $0x1, %esi
movq %rbx, %rdi
movq %rax, %rcx
callq 0x4630
movq %r14, %rdi
callq 0x4300
movl $0x1, %ebp
jmp 0x25377
xorl %ebp, %ebp
jmp 0x2537f
xorl %ebp, %ebp
movq %rbx, %rdi
callq 0x4390
movl %ebp, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbi_write_png_to_func
STBIWDEF int stbi_write_png_to_func(stbi_write_func *func, void *context, int x, int y, int comp, const void *data, int stride_bytes)
{
   int len;
   unsigned char *png = stbi_write_png_to_mem((unsigned char *) data, stride_bytes, x, y, comp, &len);
   if (png == NULL) return 0;
   func(context, png, len);
   STBIW_FREE(png);
   return 1;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %r9, %rax
movq %rsi, %r14
movq %rdi, %rbx
movl 0x30(%rsp), %esi
leaq 0xc(%rsp), %r9
movq %rax, %rdi
callq 0x24d08
testq %rax, %rax
je 0x253d0
movq %rax, %r15
movl 0xc(%rsp), %edx
movq %r14, %rdi
movq %rax, %rsi
callq *%rbx
movq %r15, %rdi
callq 0x4390
movl $0x1, %eax
jmp 0x253d2
xorl %eax, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__outfile(stbi__write_context*, int, int, int, int, int, int, void*, int, int, char const*, ...)
static int stbiw__outfile(stbi__write_context *s, int rgb_dir, int vdir, int x, int y, int comp, int expand_mono, void *data, int alpha, int pad, const char *fmt, ...)
{
   if (y < 0 || x < 0) {
      return 0;
   } else {
      va_list v;
      va_start(v, fmt);
      stbiw__writefv(s, fmt, v);
      va_end(v);
      stbiw__write_pixels(s,rgb_dir,vdir,x,y,comp,data,alpha,pad, expand_mono);
      return 1;
   }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
testb %al, %al
je 0x25431
movaps %xmm0, 0x80(%rsp)
movaps %xmm1, 0x90(%rsp)
movaps %xmm2, 0xa0(%rsp)
movaps %xmm3, 0xb0(%rsp)
movaps %xmm4, 0xc0(%rsp)
movaps %xmm5, 0xd0(%rsp)
movaps %xmm6, 0xe0(%rsp)
movaps %xmm7, 0xf0(%rsp)
movl %r8d, %eax
movl %ecx, 0x4(%rsp)
orl %ecx, %eax
js 0x25537
movl %r9d, %r13d
movl %r8d, %ebp
movq %rdi, %r14
movq 0x160(%rsp), %rsi
leaq 0x50(%rsp), %rax
leaq 0x30(%rsp), %rdx
movq %rax, 0x10(%rdx)
leaq 0x168(%rsp), %rax
movq %rax, 0x8(%rdx)
movabsq $0x3000000030, %rax     # imm = 0x3000000030
movq %rax, (%rdx)
callq 0x2554b
movl $0x0, 0x14(%rsp)
testl %ebp, %ebp
jle 0x25530
movl 0x150(%rsp), %r15d
movl 0x140(%rsp), %r12d
movslq %r13d, %r13
movl %ebp, %ebx
movslq 0x4(%rsp), %rax
movl %eax, %ecx
movq %rcx, 0x18(%rsp)
leaq -0x1(%rbx), %rcx
imulq %r13, %rax
imulq %rax, %rcx
addq 0x148(%rsp), %rcx
movq %rcx, 0x8(%rsp)
negq %rax
movq %rax, 0x20(%rsp)
movq %rbx, 0x28(%rsp)
cmpl $0x0, 0x4(%rsp)
jle 0x25501
movq 0x8(%rsp), %rbp
movq 0x18(%rsp), %rbx
movq %r14, %rdi
movl %r13d, %esi
movl %r15d, %edx
movl %r12d, %ecx
movq %rbp, %r8
callq 0x25684
addq %r13, %rbp
decq %rbx
jne 0x254e5
movq 0x28(%rsp), %rbx
decq %rbx
movq 0x8(%r14), %rdi
leaq 0x14(%rsp), %rsi
movl 0x158(%rsp), %edx
callq *(%r14)
movq 0x8(%rsp), %rax
addq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
testq %rbx, %rbx
jne 0x254cf
movl $0x1, %eax
jmp 0x25539
xorl %eax, %eax
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__writefv(stbi__write_context*, char const*, __va_list_tag*)
static void stbiw__writefv(stbi__write_context *s, const char *fmt, va_list v)
{
   while (*fmt) {
      switch (*fmt++) {
         case ' ': break;
         case '1': { unsigned char x = STBIW_UCHAR(va_arg(v, int));
                     s->func(s->context,&x,1);
                     break; }
         case '2': { int x = va_arg(v,int);
                     unsigned char b[2];
                     b[0] = STBIW_UCHAR(x);
                     b[1] = STBIW_UCHAR(x>>8);
                     s->func(s->context,b,2);
                     break; }
         case '4': { stbiw_uint32 x = va_arg(v,int);
                     unsigned char b[4];
                     b[0]=STBIW_UCHAR(x);
                     b[1]=STBIW_UCHAR(x>>8);
                     b[2]=STBIW_UCHAR(x>>16);
                     b[3]=STBIW_UCHAR(x>>24);
                     s->func(s->context,b,4);
                     break; }
         default:
            STBIW_ASSERT(0);
            return;
      }
   }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movb (%rsi), %al
testb %al, %al
je 0x25656
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
incq %r14
leaq 0x1(%rsp), %r12
leaq 0x2(%rsp), %r13
leaq 0x4(%rsp), %rbp
movzbl %al, %eax
cmpl $0x31, %eax
jg 0x255ab
cmpl $0x20, %eax
je 0x25648
cmpl $0x31, %eax
jne 0x25665
movl (%rbx), %ecx
cmpq $0x28, %rcx
ja 0x25607
movq %rcx, %rax
addq 0x10(%rbx), %rax
addl $0x8, %ecx
movl %ecx, (%rbx)
jmp 0x25613
cmpl $0x32, %eax
je 0x255cf
cmpl $0x34, %eax
jne 0x25665
movl (%rbx), %ecx
cmpq $0x28, %rcx
ja 0x25627
movq %rcx, %rax
addq 0x10(%rbx), %rax
addl $0x8, %ecx
movl %ecx, (%rbx)
jmp 0x25633
movl (%rbx), %ecx
cmpq $0x28, %rcx
ja 0x255e5
movq %rcx, %rax
addq 0x10(%rbx), %rax
addl $0x8, %ecx
movl %ecx, (%rbx)
jmp 0x255f1
movq 0x8(%rbx), %rax
leaq 0x8(%rax), %rcx
movq %rcx, 0x8(%rbx)
movzwl (%rax), %eax
movw %ax, 0x2(%rsp)
movq 0x8(%r15), %rdi
movq %r13, %rsi
movl $0x2, %edx
jmp 0x25645
movq 0x8(%rbx), %rax
leaq 0x8(%rax), %rcx
movq %rcx, 0x8(%rbx)
movb (%rax), %al
movb %al, 0x1(%rsp)
movq 0x8(%r15), %rdi
movq %r12, %rsi
movl $0x1, %edx
jmp 0x25645
movq 0x8(%rbx), %rax
leaq 0x8(%rax), %rcx
movq %rcx, 0x8(%rbx)
movl (%rax), %eax
movl %eax, 0x4(%rsp)
movq 0x8(%r15), %rdi
movq %rbp, %rsi
movl $0x4, %edx
callq *(%r15)
movb (%r14), %al
incq %r14
testb %al, %al
jne 0x2557b
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x82cb(%rip), %rdi      # 0x2d937
leaq 0x893f(%rip), %rsi      # 0x2dfb2
leaq 0x8ad0(%rip), %rcx      # 0x2e14a
movl $0x109, %edx            # imm = 0x109
callq 0x4200
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/core/stb_image_write.hpp
// Function: stbiw__write_pixel(stbi__write_context*, int, int, int, int, unsigned char*)
static void stbiw__write_pixel(stbi__write_context *s, int rgb_dir, int comp, int write_alpha, int expand_mono, unsigned char *d)
{
   unsigned char bg[3] = { 255, 0, 255}, px[3];
   int k;

   if (write_alpha < 0)
      s->func(s->context, &d[comp - 1], 1);

   switch (comp) {
      case 1:
         s->func(s->context,d,1);
         break;
      case 2:
         if (expand_mono)
            stbiw__write3(s, d[0], d[0], d[0]); // monochrome bmp
         else
            s->func(s->context, d, 1);  // monochrome TGA
         break;
      case 4:
         if (!write_alpha) {
            // composite against pink background
            for (k = 0; k < 3; ++k)
               px[k] = bg[k] + ((d[k] - bg[k]) * d[3]) / 255;
            stbiw__write3(s, px[1 - rgb_dir], px[1], px[1 + rgb_dir]);
            break;
         }
         /* FALLTHROUGH */
      case 3:
         stbiw__write3(s, d[1 - rgb_dir], d[1], d[1 + rgb_dir]);
         break;
   }
   if (write_alpha > 0)
      s->func(s->context, &d[comp - 1], 1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %r8, %r14
movl %edx, %ebp
movl %esi, %r15d
movq %rdi, %rbx
leal -0x1(%r15), %eax
cmpl $0x3, %eax
ja 0x256fd
leaq 0x83bf(%rip), %rdx      # 0x2da68
movslq (%rdx,%rax,4), %rax
addq %rdx, %rax
jmpq *%rax
testl %ecx, %ecx
je 0x256c8
movb (%r14), %al
leaq 0xf(%rsp), %rsi
movb %al, (%rsi)
movb %al, 0x1(%rsi)
movb %al, 0x2(%rsi)
jmp 0x256f2
movq 0x8(%rbx), %rdi
movq %r14, %rsi
movl $0x1, %edx
jmp 0x256fb
testl %ebp, %ebp
je 0x25721
movb 0x2(%r14), %al
movb (%r14), %cl
movb 0x1(%r14), %dl
leaq 0x15(%rsp), %rsi
movb %al, (%rsi)
movb %dl, 0x1(%rsi)
movb %cl, 0x2(%rsi)
movq 0x8(%rbx), %rdi
movl $0x3, %edx
callq *(%rbx)
testl %ebp, %ebp
jle 0x25716
movq 0x8(%rbx), %rdi
movslq %r15d, %rax
leaq (%r14,%rax), %rsi
decq %rsi
movl $0x1, %edx
callq *(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movzbl 0x3(%r14), %eax
xorl %ecx, %ecx
leaq 0x8465(%rip), %rdx      # 0x2db94
movzbl (%rcx,%rdx), %esi
movzbl (%r14,%rcx), %edi
subl %esi, %edi
imull %eax, %edi
movslq %edi, %rdi
imulq $-0x7f7f7f7f, %rdi, %r8 # imm = 0x80808081
shrq $0x20, %r8
addl %r8d, %edi
movl %edi, %r8d
shrl $0x1f, %r8d
shrl $0x7, %edi
addl %r8d, %edi
addb %sil, %dil
movb %dil, 0xc(%rsp,%rcx)
incq %rcx
cmpq $0x3, %rcx
jne 0x2572f
movb 0xe(%rsp), %al
movb 0xc(%rsp), %cl
movb 0xd(%rsp), %dl
leaq 0x12(%rsp), %rsi
jmp 0x256ea
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/Frame.cpp
// Function: Frame::setColor(Sample const&, RGB)
void
Frame::setColor(Sample const & s, RGB c)
{
  c.clip(0, 1);

  int xi = (int)std::floor(s.x() * image.width());
  int yi = (int)std::floor((1 - s.y()) * image.height());

  unsigned char * pixel = image.pixel(yi, xi);
  pixel[0] = c.getBMPR(0, 1);
  pixel[1] = c.getBMPG(0, 1);
  pixel[2] = c.getBMPB(0, 1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
xorpd %xmm0, %xmm0
maxsd (%rdx), %xmm0
movsd 0x68a5(%rip), %xmm2     # 0x2c140
movapd %xmm2, %xmm1
minsd %xmm0, %xmm1
movsd %xmm1, 0x8(%rsp)
movsd %xmm1, (%rdx)
xorpd %xmm0, %xmm0
maxsd 0x8(%rdx), %xmm0
movapd %xmm2, %xmm1
minsd %xmm0, %xmm1
movsd %xmm1, 0x8(%rdx)
xorpd %xmm0, %xmm0
maxsd 0x10(%rdx), %xmm0
movapd %xmm2, %xmm1
minsd %xmm0, %xmm1
movsd %xmm1, 0x10(%rdx)
movl 0x8(%rdi), %ebp
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
mulsd (%rsi), %xmm0
callq 0x4550
cvttsd2si %xmm0, %r12d
movsd 0x6847(%rip), %xmm1     # 0x2c140
subsd 0x8(%r15), %xmm1
xorps %xmm0, %xmm0
cvtsi2sdl 0xc(%r14), %xmm0
mulsd %xmm1, %xmm0
callq 0x4550
cvttsd2si %xmm0, %ecx
movq 0x18(%r14), %rax
imull %ebp, %ecx
addl %r12d, %ecx
movslq 0x10(%r14), %rdx
movslq %ecx, %rcx
imulq %rdx, %rcx
movsd 0x8916(%rip), %xmm0     # 0x2e248
movsd 0x8(%rsp), %xmm1
mulsd %xmm0, %xmm1
xorpd %xmm2, %xmm2
addsd %xmm2, %xmm1
cvttsd2si %xmm1, %edx
movb %dl, (%rax,%rcx)
movsd 0x8(%rbx), %xmm1
mulsd %xmm0, %xmm1
addsd %xmm2, %xmm1
cvttsd2si %xmm1, %edx
movb %dl, 0x1(%rax,%rcx)
mulsd 0x10(%rbx), %xmm0
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %edx
movb %dl, 0x2(%rax,%rcx)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/Lights.cpp
// Function: AreaLight::getShadowRays(Vec3 const&, bool&) const
vector<Ray>
AreaLight::getShadowRays(Vec3 const & position, bool & use_dist) const
{
  use_dist = true;
  vector<Ray> v;

  // generated rays from position to all the offset point lights
  for (double i = -1; i < 2; i++)
    for (double j = -1; j < 2; j++)
        for (double k = -1; k < 2; k++)
          v.push_back(Ray::fromOriginAndEnd(position, pos_ 
                                          + Vec3(i*offset_, j*offset_, k*offset_)));
  return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movb $0x1, (%rcx)
xorpd %xmm0, %xmm0
movupd %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movabsq $0x3ff0000000000000, %rbp # imm = 0x3FF0000000000000
leaq 0x18(%rsp), %r12
movl %eax, (%rsp)
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd %xmm0, 0x8(%rsp)
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
movl %eax, 0x4(%rsp)
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movsd %xmm0, 0x10(%rsp)
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
xorps %xmm0, %xmm0
cvtsi2sd %r13d, %xmm0
movsd 0x38(%r15), %xmm1
movapd %xmm1, %xmm2
mulsd %xmm1, %xmm0
mulsd 0x8(%rsp), %xmm1
mulsd 0x10(%rsp), %xmm2
addsd 0x40(%r15), %xmm1
addsd 0x48(%r15), %xmm2
addsd 0x50(%r15), %xmm0
movsd (%r14), %xmm3
movsd 0x8(%r14), %xmm4
subsd %xmm3, %xmm1
subsd %xmm4, %xmm2
movsd 0x10(%r14), %xmm5
subsd %xmm5, %xmm0
movsd %xmm3, 0x18(%rsp)
movsd %xmm4, 0x20(%rsp)
movsd %xmm5, 0x28(%rsp)
movsd %xmm1, 0x30(%rsp)
movsd %xmm2, 0x38(%rsp)
movsd %xmm0, 0x40(%rsp)
movabsq $0x7ff0000000000000, %rax # imm = 0x7FF0000000000000
movq %rax, 0x48(%rsp)
movq %rbp, 0x50(%rsp)
movq %rbx, %rdi
movq %r12, %rsi
callq 0x26456
incl %r13d
cmpl $0x2, %r13d
jne 0x260a4
movl 0x4(%rsp), %eax
incl %eax
cmpl $0x2, %eax
jne 0x2608d
movl (%rsp), %eax
incl %eax
cmpl $0x2, %eax
jne 0x26078
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x2618b
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x4320
movq %r14, %rdi
callq 0x45c0
nop
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/Primitives.cpp
// Function: Primitive::Primitive(RGB const&, Material const&, Mat4 const&)
Primitive::Primitive(RGB const & c, Material const & m, Mat4 const & modelToWorld)
{
  c_ = c;
  m_ = m;
  modelToWorld_ = modelToWorld;
  worldToModel_ = modelToWorld.inverse();
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x88, %rsp
movq %rdi, %rbx
leaq 0x115fc(%rip), %rax     # 0x37c80
movq %rax, (%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x108(%rdi)
movq $0x0, 0x118(%rdi)
movsd (%rsi), %xmm0
movsd %xmm0, 0x108(%rdi)
movsd 0x8(%rsi), %xmm0
movsd %xmm0, 0x110(%rdi)
movsd 0x10(%rsi), %xmm0
movsd %xmm0, 0x118(%rdi)
movups (%rdx), %xmm0
movups 0x10(%rdx), %xmm1
movups %xmm0, 0x120(%rdi)
movups %xmm1, 0x130(%rdi)
movsd (%rcx), %xmm0
movsd %xmm0, 0x8(%rdi)
movsd 0x8(%rcx), %xmm0
movsd %xmm0, 0x10(%rdi)
movsd 0x10(%rcx), %xmm0
movsd %xmm0, 0x18(%rdi)
movsd 0x18(%rcx), %xmm0
movsd %xmm0, 0x20(%rdi)
movsd 0x20(%rcx), %xmm0
movsd %xmm0, 0x28(%rdi)
movsd 0x28(%rcx), %xmm0
movsd %xmm0, 0x30(%rdi)
movsd 0x30(%rcx), %xmm0
movsd %xmm0, 0x38(%rdi)
movsd 0x38(%rcx), %xmm0
movsd %xmm0, 0x40(%rdi)
movsd 0x40(%rcx), %xmm0
movsd %xmm0, 0x48(%rdi)
movsd 0x48(%rcx), %xmm0
movsd %xmm0, 0x50(%rdi)
movsd 0x50(%rcx), %xmm0
movsd %xmm0, 0x58(%rdi)
movsd 0x58(%rcx), %xmm0
movsd %xmm0, 0x60(%rdi)
movsd 0x60(%rcx), %xmm0
movsd %xmm0, 0x68(%rdi)
movsd 0x68(%rcx), %xmm0
movsd %xmm0, 0x70(%rdi)
movsd 0x70(%rcx), %xmm0
movsd %xmm0, 0x78(%rdi)
movsd 0x78(%rcx), %xmm0
movsd %xmm0, 0x80(%rdi)
leaq 0x8(%rsp), %r14
movq %r14, %rdi
movq %rcx, %rsi
callq 0x279cc
movsd (%r14), %xmm0
movsd %xmm0, 0x88(%rbx)
movsd 0x8(%r14), %xmm0
movsd %xmm0, 0x90(%rbx)
movsd 0x10(%r14), %xmm0
movsd %xmm0, 0x98(%rbx)
movsd 0x18(%r14), %xmm0
movsd %xmm0, 0xa0(%rbx)
movsd 0x20(%r14), %xmm0
movsd %xmm0, 0xa8(%rbx)
movsd 0x28(%r14), %xmm0
movsd %xmm0, 0xb0(%rbx)
movsd 0x30(%r14), %xmm0
movsd %xmm0, 0xb8(%rbx)
movsd 0x38(%r14), %xmm0
movsd %xmm0, 0xc0(%rbx)
movsd 0x40(%r14), %xmm0
movsd %xmm0, 0xc8(%rbx)
movsd 0x48(%r14), %xmm0
movsd %xmm0, 0xd0(%rbx)
movsd 0x50(%r14), %xmm0
movsd %xmm0, 0xd8(%rbx)
movsd 0x58(%r14), %xmm0
movsd %xmm0, 0xe0(%rbx)
movsd 0x60(%r14), %xmm0
movsd %xmm0, 0xe8(%rbx)
movsd 0x68(%r14), %xmm0
movsd %xmm0, 0xf0(%rbx)
movsd 0x70(%r14), %xmm0
movsd %xmm0, 0xf8(%rbx)
movsd 0x78(%r14), %xmm0
movsd %xmm0, 0x100(%rbx)
addq $0x88, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/Primitives.cpp
// Function: Sphere::calculateNormal(Vec3 const&) const
Vec3
Sphere::calculateNormal(Vec3 const & position) const
{ 
  // norm is the point's position in the model coordinates
  Vec3 norm = worldToModel_ * position;
  // restoring the normal back to the world coordinates
  return Vec3(worldToModel_.transpose() * Vec4(norm, 0), 3).normalize();
}

// Assembly:
pushq %rbx
subq $0x20, %rsp
movq %rdi, %rbx
movsd (%rdx), %xmm7
movsd 0x8(%rdx), %xmm11
movsd 0x10(%rdx), %xmm9
movsd 0x88(%rsi), %xmm3
movsd 0x90(%rsi), %xmm1
movapd %xmm11, %xmm0
mulsd %xmm1, %xmm0
movapd %xmm3, %xmm2
mulsd %xmm7, %xmm2
addsd %xmm0, %xmm2
movsd 0x98(%rsi), %xmm0
movapd %xmm0, %xmm12
mulsd %xmm9, %xmm12
addsd %xmm2, %xmm12
movsd 0xa8(%rsi), %xmm8
movsd 0xb0(%rsi), %xmm4
movapd %xmm11, %xmm2
mulsd %xmm4, %xmm2
movapd %xmm8, %xmm5
mulsd %xmm7, %xmm5
addsd %xmm2, %xmm5
movsd 0xb8(%rsi), %xmm13
movsd %xmm13, 0x8(%rsp)
mulsd %xmm9, %xmm13
addsd %xmm5, %xmm13
movsd 0xc8(%rsi), %xmm10
movsd 0xd0(%rsi), %xmm6
movapd %xmm11, %xmm5
mulsd %xmm6, %xmm5
movapd %xmm10, %xmm15
mulsd %xmm7, %xmm15
addsd %xmm5, %xmm15
movsd 0xd8(%rsi), %xmm5
movapd %xmm5, %xmm14
mulsd %xmm9, %xmm14
addsd %xmm15, %xmm14
movsd 0xf0(%rsi), %xmm15
mulsd %xmm15, %xmm11
movsd 0xe8(%rsi), %xmm2
movsd %xmm2, 0x10(%rsp)
mulsd %xmm2, %xmm7
addsd %xmm11, %xmm7
addsd 0xa0(%rsi), %xmm12
addsd 0xc0(%rsi), %xmm13
movsd 0xf8(%rsi), %xmm2
mulsd %xmm2, %xmm9
addsd %xmm7, %xmm9
addsd 0x100(%rsi), %xmm9
xorpd %xmm7, %xmm7
ucomisd %xmm7, %xmm9
movapd %xmm12, %xmm11
divsd %xmm9, %xmm11
jne 0x26d4b
jp 0x26d4b
movapd %xmm12, %xmm11
addsd 0xe0(%rsi), %xmm14
movapd %xmm13, %xmm12
divsd %xmm9, %xmm12
jne 0x26d67
jp 0x26d67
movapd %xmm13, %xmm12
movapd %xmm14, %xmm13
divsd %xmm9, %xmm13
jne 0x26d7a
jp 0x26d7a
movapd %xmm14, %xmm13
mulsd %xmm12, %xmm8
mulsd %xmm11, %xmm3
addsd %xmm8, %xmm3
mulsd %xmm13, %xmm10
addsd %xmm3, %xmm10
movsd 0x10(%rsp), %xmm3
mulsd %xmm7, %xmm3
addsd %xmm10, %xmm3
mulsd %xmm12, %xmm4
mulsd %xmm11, %xmm1
addsd %xmm4, %xmm1
mulsd %xmm13, %xmm6
addsd %xmm1, %xmm6
mulsd %xmm7, %xmm15
addsd %xmm6, %xmm15
movsd 0x8(%rsp), %xmm1
mulsd %xmm12, %xmm1
mulsd %xmm11, %xmm0
addsd %xmm1, %xmm0
mulsd %xmm13, %xmm5
addsd %xmm0, %xmm5
mulsd %xmm7, %xmm2
addsd %xmm5, %xmm2
movapd %xmm15, %xmm0
mulsd %xmm15, %xmm0
movapd %xmm3, %xmm1
mulsd %xmm3, %xmm1
addsd %xmm0, %xmm1
movapd %xmm2, %xmm0
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
ucomisd %xmm7, %xmm0
jb 0x26e16
sqrtsd %xmm0, %xmm0
jmp 0x26e41
movsd %xmm15, 0x8(%rsp)
movsd %xmm3, 0x10(%rsp)
movsd %xmm2, 0x18(%rsp)
callq 0x4280
movsd 0x18(%rsp), %xmm2
movsd 0x10(%rsp), %xmm3
movsd 0x8(%rsp), %xmm15
movsd 0x52f7(%rip), %xmm1     # 0x2c140
divsd %xmm0, %xmm1
mulsd %xmm1, %xmm3
mulsd %xmm1, %xmm15
mulsd %xmm2, %xmm1
movsd %xmm3, (%rbx)
movsd %xmm15, 0x8(%rbx)
movsd %xmm1, 0x10(%rbx)
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/View.cpp
// Function: View::View(Vec3 const&, Vec3 const&, Vec3 const&, Vec3 const&, Vec3 const&, int, int, int)
View::View(Vec3 const & eye, Vec3 const & ll, Vec3 const & ul, Vec3 const & lr, Vec3 const & ur,
           int pixels_wide, int pixels_high, int rays_per_pixel_edge)
{
  eye_ = eye;	 // you should use this for the viewing ray
  LL_ = ll;
  UL_ = ul;
  LR_ = lr;
  UR_ = ur;
  pixels_wide_ = pixels_wide;
  pixels_high_ = pixels_high;
  rays_per_pixel_edge_ = rays_per_pixel_edge;
}

// Assembly:
pushq %rbx
movl 0x20(%rsp), %eax
movl 0x18(%rsp), %r10d
movl 0x10(%rsp), %r11d
leaq 0xff6a(%rip), %rbx      # 0x37d50
movq %rbx, (%rdi)
movsd (%rsi), %xmm0
movsd %xmm0, 0x8(%rdi)
movsd 0x8(%rsi), %xmm0
movsd %xmm0, 0x10(%rdi)
movsd 0x10(%rsi), %xmm0
movsd %xmm0, 0x18(%rdi)
movsd (%rdx), %xmm0
movsd %xmm0, 0x20(%rdi)
movsd 0x8(%rdx), %xmm0
movsd %xmm0, 0x28(%rdi)
movsd 0x10(%rdx), %xmm0
movsd %xmm0, 0x30(%rdi)
movsd (%rcx), %xmm0
movsd %xmm0, 0x38(%rdi)
movsd 0x8(%rcx), %xmm0
movsd %xmm0, 0x40(%rdi)
movsd 0x10(%rcx), %xmm0
movsd %xmm0, 0x48(%rdi)
movsd (%r8), %xmm0
movsd %xmm0, 0x50(%rdi)
movsd 0x8(%r8), %xmm0
movsd %xmm0, 0x58(%rdi)
movsd 0x10(%r8), %xmm0
movsd %xmm0, 0x60(%rdi)
movsd (%r9), %xmm0
movsd %xmm0, 0x68(%rdi)
movsd 0x8(%r9), %xmm0
movsd %xmm0, 0x70(%rdi)
movsd 0x10(%r9), %xmm0
movsd %xmm0, 0x78(%rdi)
movl %r11d, 0x80(%rdi)
movl %r10d, 0x84(%rdi)
movl %eax, 0x88(%rdi)
popq %rbx
retq
// File: /workspace/github_cpp_makefile_star2_O1/srajangarg[P]raytracer/src/View.cpp
// Function: View::getSample(int, int, int, Sample&) const
void
View::getSample(int pixel_x, int pixel_y, int ray_index, Sample & s) const
{
  // Some random jitter to break up patterns
  double jitter_x = 0.25 * (std::rand() / (double)RAND_MAX);
  double jitter_y = 0.25 * (std::rand() / (double)RAND_MAX);

  double pixel_sub_x = (ray_index % rays_per_pixel_edge_ + 0.5 + jitter_x) / (double)rays_per_pixel_edge_;
  double pixel_sub_y = (ray_index / rays_per_pixel_edge_ + 0.5 + jitter_y) / (double)rays_per_pixel_edge_;

  s.setX((pixel_x + pixel_sub_x) / (double)pixels_wide_);
  s.setY((pixel_y + pixel_sub_y) / (double)pixels_high_);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %r8, %rbx
movl %ecx, %r12d
movl %edx, %ebp
movl %esi, %r15d
movq %rdi, %r14
callq 0x40f0
cvtsi2sd %eax, %xmm0
divsd 0x64e3(%rip), %xmm0     # 0x2e3b0
mulsd 0x64e3(%rip), %xmm0     # 0x2e3b8
movsd %xmm0, 0x8(%rsp)
callq 0x40f0
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
movl 0x88(%r14), %ecx
movl %r12d, %eax
cltd
idivl %ecx
divsd 0x64b4(%rip), %xmm0     # 0x2e3b0
mulsd 0x64b4(%rip), %xmm0     # 0x2e3b8
cvtsi2sd %edx, %xmm1
movsd 0x64b0(%rip), %xmm2     # 0x2e3c0
addsd %xmm2, %xmm1
addsd 0x8(%rsp), %xmm1
cvtsi2sd %ecx, %xmm3
divsd %xmm3, %xmm1
cvtsi2sd %eax, %xmm4
addsd %xmm2, %xmm4
addsd %xmm0, %xmm4
divsd %xmm3, %xmm4
xorps %xmm0, %xmm0
cvtsi2sd %r15d, %xmm0
addsd %xmm1, %xmm0
xorps %xmm1, %xmm1
cvtsi2sdl 0x80(%r14), %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, (%rbx)
xorps %xmm0, %xmm0
cvtsi2sd %ebp, %xmm0
addsd %xmm4, %xmm0
xorps %xmm1, %xmm1
cvtsi2sdl 0x84(%r14), %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, 0x8(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/nvanbenschoten[P]total-order-multicast/src/process.cc
// Function: process::ClientsForProcessList(std::vector<net::Address, std::allocator<net::Address>> const&)
UdpClientMap ClientsForProcessList(const ProcessList& processes) {
  UdpClientMap clients(processes.size());
  for (auto const& addr : processes) {
    clients.emplace(addr, std::make_shared<udp::Client>(addr, kAckTimeout));
  }
  return clients;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r15
movq 0x8(%rsi), %rax
subq (%rsi), %rax
movq %rdi, %rbx
sarq $0x3, %rax
movabsq $-0x3333333333333333, %rsi # imm = 0xCCCCCCCCCCCCCCCD
imulq %rax, %rsi
leaq 0x8(%rsp), %rdx
leaq 0x6(%rsp), %rcx
leaq 0x7(%rsp), %r8
callq 0x7a90
movq (%r15), %r14
movq 0x8(%r15), %rbp
cmpq %rbp, %r14
je 0x5ff1
leaq 0xe168(%rip), %r15      # 0x14118
leaq 0x8(%rsp), %r12
leaq 0x6(%rsp), %r13
movq %r12, %rdi
movq %r13, %rsi
movq %r14, %rdx
movq %r15, %rcx
callq 0x7b42
movq %rbx, %rdi
movq %r14, %rsi
movq %r12, %rdx
callq 0x7f60
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x5fe8
callq 0x78bc
addq $0x28, %r14
cmpq %rbp, %r14
jne 0x5fba
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0x601a
movq %rax, %r14
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0x601a
callq 0x78bc
movq %rbx, %rdi
callq 0x7936
movq %r14, %rdi
callq 0x5650
// File: /workspace/github_cpp_makefile_star2_O1/nvanbenschoten[P]total-order-multicast/src/process.cc
// Function: process::RandomUint32()
uint32_t RandomUint32() {
  // Static thread local to avoid expensive initialization cost on every call,
  // while maintaining thread safety.
  static thread_local std::random_device r;
  static thread_local std::seed_seq seed{r(), r(), r(), r(), r()};
  static thread_local std::default_random_engine random_engine(seed);

  std::uniform_int_distribution<uint32_t> distribution(0, UINT32_MAX);
  return distribution(random_engine);
}

// Assembly:
pushq %rax
cmpb $0x0, %fs:-0x58
je 0x6076
cmpb $0x0, %fs:-0x38
je 0x607d
cmpb $0x0, %fs:-0x28
je 0x6084
movabsq $-0x100000000, %rax     # imm = 0xFFFFFFFF00000000
movq %rsp, %rdi
movq %rax, (%rdi)
movq %fs:0x0, %rax
leaq -0x30(%rax), %rsi
movq %rdi, %rdx
callq 0x87d8
popq %rcx
retq
callq 0x56f2
jmp 0x6036
callq 0x572c
jmp 0x6041
callq 0x57c3
jmp 0x604c
// File: /workspace/github_cpp_makefile_star2_O1/nvanbenschoten[P]total-order-multicast/src/process.cc
// Function: process::MessageTypeFromBuf(char*, unsigned long)
std::experimental::optional<uint32_t> MessageTypeFromBuf(char* buf, size_t n) {
  // Check to make sure the size of the buffer is at least the size of the type
  // field.
  if (n < sizeof(uint32_t)) {
    return {};
  }

  // Read the first 32-bits and convert to host endianness.
  uint32_t* buf_type = reinterpret_cast<uint32_t*>(buf);
  return ntohl(*buf_type);
}

// Assembly:
movq %rdi, %rax
cmpq $0x3, %rdx
ja 0x609f
movq $0x0, (%rax)
xorl %ecx, %ecx
jmp 0x60a7
movl (%rsi), %ecx
bswapl %ecx
movl %ecx, (%rax)
movb $0x1, %cl
movb %cl, 0x4(%rax)
retq