// File: /workspace/github_cpp_makefile_star2_O1/manikandan5[P]Image-Matching-Stitching-Warping/./CImg.h
// Function: cimg_library::CImg<double>::_load_ascii(_IO_FILE*, char const*)
CImg<T>& _load_ascii(std::FILE *const file, const char *const filename) {
      if (!file && !filename)
        throw CImgArgumentException(_cimg_instance
                                    "load_ascii(): Specified filename is (null).",
                                    cimg_instance);

      std::FILE *const nfile = file?file:cimg::fopen(filename,"rb");
      char line[256] = { 0 };
      int err = std::fscanf(nfile,"%255[^\n]",line);
      unsigned int dx = 0, dy = 1, dz = 1, dc = 1;
      std::sscanf(line,"%u%*c%u%*c%u%*c%u",&dx,&dy,&dz,&dc);
      err = std::fscanf(nfile,"%*[^0-9.eE+-]");
      if (!dx || !dy || !dz || !dc) {
        if (!file) cimg::fclose(nfile);
        throw CImgIOException(_cimg_instance
                              "load_ascii(): Invalid ascii header in file '%s', image dimensions are set "
                              "to (%u,%u,%u,%u).",
                              cimg_instance,
                              filename?filename:"(FILE*)",dx,dy,dz,dc);
      }
      assign(dx,dy,dz,dc);
      const unsigned long siz = size();
      unsigned long off = 0;
      double val;
      T *ptr = _data;
      for (err = 1, off = 0; off<siz && err==1; ++off) {
        err = std::fscanf(nfile,"%lf%*[^0-9.eE+-]",&val);
        *(ptr++) = (T)val;
      }
      if (err!=1)
        cimg::warn(_cimg_instance
                   "load_ascii(): Only %lu/%lu values read from file '%s'.",
                   cimg_instance,
                   off-1,siz,filename?filename:"(FILE*)");

      if (!file) cimg::fclose(nfile);
      return *this;
    }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x138, %rsp            # imm = 0x138
movq %rdi, %r12
movq %rsi, %rax
orq %rdx, %rax
je 0x3dc8d
movq %rdx, %rbx
movq %rsi, %r14
movq %rsi, 0x18(%rsp)
testq %rsi, %rsi
jne 0x3da7a
leaq 0x56346(%rip), %rsi     # 0x93db5
movq %rbx, %rdi
callq 0x3ceb3
movq %rax, %r14
movq %rbx, 0x10(%rsp)
leaq 0x30(%rsp), %r13
movl $0x100, %edx            # imm = 0x100
movq %r13, %rdi
xorl %esi, %esi
callq 0x4290
leaq 0x565a2(%rip), %rsi     # 0x9403c
movq %r14, %rdi
movq %r13, %rdx
xorl %eax, %eax
callq 0x49e0
leaq 0xc(%rsp), %rbp
movl $0x0, (%rbp)
movl $0x1, %eax
leaq 0x8(%rsp), %rcx
movl %eax, (%rcx)
leaq 0x4(%rsp), %r8
movl %eax, (%r8)
movq %rsp, %r9
movl %eax, (%r9)
leaq 0x56571(%rip), %rsi     # 0x94045
movq %r13, %rdi
movq %rbp, %rdx
xorl %eax, %eax
callq 0x4530
leaq 0x56604(%rip), %rsi     # 0x940ec
movq %r14, %rdi
xorl %eax, %eax
callq 0x49e0
movl (%rbp), %esi
testl %esi, %esi
je 0x3dcfa
movl 0x8(%rsp), %edx
testl %edx, %edx
je 0x3dcfa
movl 0x4(%rsp), %ecx
testl %ecx, %ecx
je 0x3dcfa
movl (%rsp), %r8d
testl %r8d, %r8d
je 0x3dcfa
movq %r12, %rdi
callq 0xbc3e
movl (%r12), %eax
movl 0x4(%r12), %ecx
imulq %rax, %rcx
movl 0x8(%r12), %eax
movl 0xc(%r12), %r15d
imulq %rax, %r15
imulq %rcx, %r15
testq %r15, %r15
je 0x3dba9
movq %r12, 0x20(%rsp)
movq 0x18(%r12), %r12
movl $0x1, %r10d
leaq 0x56584(%rip), %r13     # 0x940e9
leaq 0x28(%rsp), %rbp
movq %r10, %rbx
movq %r14, %rdi
movq %r13, %rsi
movq %rbp, %rdx
xorl %eax, %eax
callq 0x49e0
movsd 0x28(%rsp), %xmm0
movsd %xmm0, -0x8(%r12,%rbx,8)
cmpl $0x1, %eax
sete %cl
leaq 0x1(%rbx), %r10
cmpq %r15, %rbx
jae 0x3db9e
cmpl $0x1, %eax
je 0x3db6a
addq $-0x2, %r10
movq 0x20(%rsp), %r12
jmp 0x3dbb2
movb $0x1, %cl
movq $-0x1, %r10
testb %cl, %cl
jne 0x3dc25
leaq 0x3577b(%rip), %rax     # 0x73338
cmpb $0x0, 0x10(%r12)
leaq 0x36b48(%rip), %r11     # 0x74712
cmovneq %rax, %r11
movq 0x10(%rsp), %rax
testq %rax, %rax
movl (%r12), %esi
movl 0x4(%r12), %edx
movl 0x8(%r12), %ecx
movl 0xc(%r12), %r8d
movq 0x18(%r12), %r9
leaq 0x564ec(%rip), %rbx     # 0x940e1
cmovneq %rax, %rbx
subq $0x8, %rsp
movq %r12, %r13
leaq 0x55fe8(%rip), %r12     # 0x93bef
leaq 0x564ec(%rip), %rdi     # 0x940fa
xorl %eax, %eax
pushq %rbx
pushq %r15
pushq %r10
pushq %r12
movq %r13, %r12
pushq %r11
callq 0xbb52
addq $0x30, %rsp
cmpq $0x0, 0x18(%rsp)
je 0x3dc42
movq %r12, %rax
addq $0x138, %rsp            # imm = 0x138
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
testq %r14, %r14
je 0x3dc7d
movq 0x6f35a(%rip), %rax     # 0xacfa8
cmpq %r14, (%rax)
je 0x3dc2d
movq 0x6f32e(%rip), %rax     # 0xacf88
cmpq %r14, (%rax)
je 0x3dc2d
movq %r14, %rdi
callq 0x4540
testl %eax, %eax
je 0x3dc2d
leaq 0x55e5a(%rip), %rdi     # 0x93acc
movl %eax, %esi
xorl %eax, %eax
callq 0xbb52
jmp 0x3dc2d
leaq 0x55e1e(%rip), %rdi     # 0x93aa2
xorl %eax, %eax
callq 0xbb52
jmp 0x3dc2d
movl $0x4008, %edi           # imm = 0x4008
callq 0x4210
movq %rax, %r14
movl (%r12), %edx
movl 0x4(%r12), %ecx
movl 0x8(%r12), %r8d
movl 0xc(%r12), %r9d
leaq 0x35684(%rip), %rax     # 0x73338
leaq 0x36a57(%rip), %r10     # 0x74712
cmpb $0x0, 0x10(%r12)
cmovneq %rax, %r10
subq $0x8, %rsp
leaq 0x55f1f(%rip), %r11     # 0x93bef
leaq 0x5630b(%rip), %rsi     # 0x93fe2
movq %r14, %rdi
xorl %eax, %eax
pushq %r11
pushq %r10
pushq 0x18(%r12)
callq 0xc196
addq $0x20, %rsp
leaq 0x6ef2b(%rip), %rsi     # 0xacc20
jmp 0x3dd9d
cmpq $0x0, 0x18(%rsp)
jne 0x3dd0a
movq %r14, %rdi
callq 0x3845e
movl $0x4008, %edi           # imm = 0x4008
callq 0x4210
movq %rax, %r14
leaq 0x3561a(%rip), %rax     # 0x73338
leaq 0x369ed(%rip), %r10     # 0x74712
movq %r12, %rbx
cmpb $0x0, 0x10(%r12)
cmovneq %rax, %r10
movq 0x10(%rsp), %rax
testq %rax, %rax
movl (%r12), %edx
movl 0x4(%r12), %ecx
movl 0x8(%r12), %r8d
movl 0xc(%r12), %r9d
leaq 0x5638d(%rip), %r11     # 0x940e1
cmovneq %rax, %r11
movl 0xc(%rsp), %r15d
movl 0x8(%rsp), %r12d
movl 0x4(%rsp), %r13d
movl (%rsp), %ebp
leaq 0x562e6(%rip), %rsi     # 0x94057
movq %r14, %rdi
xorl %eax, %eax
pushq %rbp
pushq %r13
pushq %r12
pushq %r15
pushq %r11
leaq 0x55e69(%rip), %r11     # 0x93bef
pushq %r11
pushq %r10
pushq 0x18(%rbx)
callq 0x385b4
addq $0x40, %rsp
leaq 0x6ef53(%rip), %rsi     # 0xaccf0
movq 0x6f22c(%rip), %rdx     # 0xacfd0
movq %r14, %rdi
callq 0x4900
jmp 0x3ddae
movq %rax, %rbx
movq %r14, %rdi
callq 0x43b0
movq %rbx, %rdi
callq 0x4950
nop