LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: 4n6ist[P]usn_analytics/lib/usnrecord.cpp
// Function: UsnExecuted::StoreRecord(UsnMain*, unsigned short)
int UsnExecuted::StoreRecord(UsnMain* um, uint16_t _exe_cnt) {
  usn = um->usn;
  timestamp_s = um->timestamp_s;
  file_name = um->file_name;
  exe_name = file_name.substr(0, file_name.size()-12); // "-XXXXXXXX.pf" length 
  transform(exe_name.begin(), exe_name.end(), exe_name.begin(), ::tolower);  
  exe_cnt = _exe_cnt;
  rec_cnt = um->rec_cnt;
  reasons_s = um->reasons_s;  
  time_taken = um->time_taken;
  cid = um->cid;
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movw %dx, %ax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movw %ax, -0x12(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x60(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, (%rdi)
movq -0x10(%rbp), %rsi
addq $0x12, %rsi
addq $0x8, %rdi
callq 0x3050
movq -0x60(%rbp), %rdi
movq -0x10(%rbp), %rsi
addq $0x3a, %rsi
addq $0x4a, %rdi
callq 0x3050
movq -0x60(%rbp), %rdi
movq %rdi, %rax
addq $0x4a, %rax
movq %rax, -0x68(%rbp)
addq $0x4a, %rdi
callq 0x3220
movq -0x68(%rbp), %rsi
movq %rax, %rcx
subq $0xc, %rcx
leaq -0x38(%rbp), %rdi
xorl %eax, %eax
movl %eax, %edx
callq 0x3360
movq -0x60(%rbp), %rdi
addq $0x28, %rdi
leaq -0x38(%rbp), %rsi
callq 0x3450
leaq -0x38(%rbp), %rdi
callq 0x31d0
movq -0x60(%rbp), %rdi
addq $0x28, %rdi
callq 0x32c0
movq -0x60(%rbp), %rdi
movq %rax, -0x40(%rbp)
addq $0x28, %rdi
callq 0x31b0
movq -0x60(%rbp), %rdi
movq %rax, -0x48(%rbp)
addq $0x28, %rdi
callq 0x32c0
movq %rax, -0x50(%rbp)
movq -0x40(%rbp), %rdi
movq -0x48(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq 0xfe91(%rip), %rcx      # 0x26fd0
callq 0x175a0
movq -0x60(%rbp), %rdi
movq %rax, -0x58(%rbp)
movw -0x12(%rbp), %ax
movw %ax, 0x48(%rdi)
movq -0x10(%rbp), %rax
movw 0x8(%rax), %ax
movw %ax, 0x8a(%rdi)
movq -0x10(%rbp), %rsi
addq $0x5e, %rsi
addq $0x6a, %rdi
callq 0x3050
movq -0x60(%rbp), %rax
movq -0x10(%rbp), %rcx
movsd 0x32(%rcx), %xmm0
movsd %xmm0, 0x8c(%rax)
movq -0x10(%rbp), %rcx
movl 0xa2(%rcx), %ecx
movl %ecx, 0x94(%rax)
xorl %eax, %eax
addq $0x70, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: 4n6ist[P]usn_analytics/lib/usnrecord.cpp
// Function: UsnExecuted::WriteExecutedRecord(_IO_FILE*)
int UsnExecuted::WriteExecutedRecord(FILE *fp) {
  fprintf(fp, "\"%llu\"\t", usn);
  fprintf(fp, "\"%s\"\t", timestamp_s.c_str());
  fprintf(fp, "\"%s\"\t", exe_name.c_str());
  fprintf(fp, "\"%u\"\t", exe_cnt);
  fprintf(fp, "\"%s\"\t", file_name.c_str());
  fprintf(fp, "\"%s\"\t", reasons_s.c_str());
  fprintf(fp, "\"%u\"\t", rec_cnt);
  fprintf(fp, "\"%f\"\t", time_taken);
  fprintf(fp, "\"%u\"\t", cid);
  fprintf(fp, "\n");
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq (%rax), %rdx
leaq 0x5541(%rip), %rsi      # 0x1c717
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
addq $0x8, %rdi
callq 0x3120
movq -0x38(%rbp), %rdi
movq %rax, %rdx
leaq 0x552c(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
addq $0x28, %rdi
callq 0x3120
movq -0x30(%rbp), %rdi
movq %rax, %rdx
leaq 0x5502(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movzwl 0x48(%rax), %edx
leaq 0x54db(%rip), %rsi      # 0x1c71f
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
addq $0x4a, %rdi
callq 0x3120
movq -0x28(%rbp), %rdi
movq %rax, %rdx
leaq 0x54be(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
addq $0x6a, %rdi
callq 0x3120
movq -0x20(%rbp), %rdi
movq %rax, %rdx
leaq 0x5494(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movzwl 0x8a(%rax), %edx
leaq 0x546a(%rip), %rsi      # 0x1c71f
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movsd 0x8c(%rax), %xmm0
leaq 0x547c(%rip), %rsi      # 0x1c74f
movb $0x1, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movl 0x94(%rax), %edx
leaq 0x5430(%rip), %rsi      # 0x1c71f
movb $0x0, %al
callq 0x34d0
movq -0x10(%rbp), %rdi
leaq 0x5690(%rip), %rsi      # 0x1c991
movb $0x0, %al
callq 0x34d0
xorl %eax, %eax
addq $0x40, %rsp
popq %rbp
retq
// File: 4n6ist[P]usn_analytics/lib/usnrecord.cpp
// Function: UsnOpened::StoreRecord(UsnMain*)
int UsnOpened::StoreRecord(UsnMain* um) {
  usn = um->usn;
  timestamp_s = um->timestamp_s;
  file_path = um->file_path;
  file_name = um->file_name;
  reasons_s = um->reasons_s;  
  rec_cnt = um->rec_cnt;
  time_taken = um->time_taken;
  cid = um->cid;
  pid = um->pid;
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, (%rdi)
movq -0x10(%rbp), %rsi
addq $0x12, %rsi
addq $0x8, %rdi
callq 0x3050
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rsi
addq $0xaa, %rsi
addq $0x28, %rdi
callq 0x3050
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rsi
addq $0x3a, %rsi
addq $0x48, %rdi
callq 0x3050
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rsi
addq $0x5e, %rsi
addq $0x68, %rdi
callq 0x3050
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
movw 0x8(%rcx), %cx
movw %cx, 0x88(%rax)
movq -0x10(%rbp), %rcx
movsd 0x32(%rcx), %xmm0
movsd %xmm0, 0x8a(%rax)
movq -0x10(%rbp), %rcx
movl 0xa2(%rcx), %ecx
movl %ecx, 0x92(%rax)
movq -0x10(%rbp), %rcx
movl 0xa6(%rcx), %ecx
movl %ecx, 0x96(%rax)
xorl %eax, %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: 4n6ist[P]usn_analytics/lib/usnrecord.cpp
// Function: UsnOpened::WriteOpenedRecord(_IO_FILE*)
int UsnOpened::WriteOpenedRecord(FILE *fp) {
  fprintf(fp, "\"%llu\"\t", usn);
  fprintf(fp, "\"%s\"\t", timestamp_s.c_str());
  fprintf(fp, "\"%s\"\t", file_path.c_str());
  fprintf(fp, "\"%s\"\t", file_name.c_str());
  fprintf(fp, "\"%s\"\t", reasons_s.c_str());
  fprintf(fp, "\"%u\"\t", rec_cnt);
  fprintf(fp, "\"%f\"\t", time_taken);
  fprintf(fp, "\"%u\"\t", cid);
  fprintf(fp, "\"%u\"\t", pid);
  fprintf(fp, "\n");
  return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq (%rax), %rdx
leaq 0x52c1(%rip), %rsi      # 0x1c717
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
addq $0x8, %rdi
callq 0x3120
movq -0x38(%rbp), %rdi
movq %rax, %rdx
leaq 0x52ac(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
addq $0x28, %rdi
callq 0x3120
movq -0x30(%rbp), %rdi
movq %rax, %rdx
leaq 0x5282(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x28(%rbp)
addq $0x48, %rdi
callq 0x3120
movq -0x28(%rbp), %rdi
movq %rax, %rdx
leaq 0x5258(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
addq $0x68, %rdi
callq 0x3120
movq -0x20(%rbp), %rdi
movq %rax, %rdx
leaq 0x522e(%rip), %rsi      # 0x1c72c
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movzwl 0x88(%rax), %edx
leaq 0x5204(%rip), %rsi      # 0x1c71f
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movsd 0x8a(%rax), %xmm0
leaq 0x5216(%rip), %rsi      # 0x1c74f
movb $0x1, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movl 0x92(%rax), %edx
leaq 0x51ca(%rip), %rsi      # 0x1c71f
movb $0x0, %al
callq 0x34d0
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rdi
movl 0x96(%rax), %edx
leaq 0x51ae(%rip), %rsi      # 0x1c71f
movb $0x0, %al
callq 0x34d0
movq -0x10(%rbp), %rdi
leaq 0x540e(%rip), %rsi      # 0x1c991
movb $0x0, %al
callq 0x34d0
xorl %eax, %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: timer::~timer()
timer::~timer() {
  clock_t c_end;
  time_t t_end;
  c_end = clock();
  t_end = time(NULL);
  printf("CPU Time: %f\n", (double)(c_end-c_start) / CLOCKS_PER_SEC);
  printf("Processed Time: %ld(s)\n", (t_end-t_start));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
callq 0x31e0
movq %rax, -0x10(%rbp)
xorl %eax, %eax
movl %eax, %edi
callq 0x3300
movq -0x20(%rbp), %rcx
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rcx), %rcx
subq %rcx, %rax
cvtsi2sd %rax, %xmm0
movsd 0x5023(%rip), %xmm1     # 0x1c758
divsd %xmm1, %xmm0
leaq 0x5020(%rip), %rdi      # 0x1c760
movb $0x1, %al
callq 0x3060
jmp 0x17749
movq -0x20(%rbp), %rax
movq -0x18(%rbp), %rsi
movq 0x8(%rax), %rax
subq %rax, %rsi
leaq 0x500f(%rip), %rdi      # 0x1c76e
xorl %eax, %eax
callq 0x3060
jmp 0x17768
addq $0x20, %rsp
popq %rbp
retq
movq %rax, %rdi
callq 0xa1d0
nopw %cs:(%rax,%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: is_empty_dir(char const*)
bool is_empty_dir(const char *out_dname){
  DIR *pdir;

  if((pdir = opendir(out_dname)) == NULL)
    return false;

  struct dirent *pent;

  // check there is at least one file
  for(pent = readdir(pdir); pent != NULL; pent = readdir(pdir)) {
    if(strcmp(pent->d_name, ".") != 0 && strcmp(pent->d_name, "..") != 0) {// ignore "." and ".."
      closedir(pdir);
      return false;
    }
  }
  closedir(pdir);
  return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x3500
movq %rax, -0x18(%rbp)
cmpq $0x0, %rax
jne 0x177a5
movb $0x0, -0x1(%rbp)
jmp 0x17818
movq -0x18(%rbp), %rdi
callq 0x3510
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x1780b
movq -0x20(%rbp), %rdi
addq $0x13, %rdi
leaq 0x4fbf(%rip), %rsi      # 0x1c787
callq 0x34c0
cmpl $0x0, %eax
je 0x177fa
movq -0x20(%rbp), %rdi
addq $0x13, %rdi
leaq 0x4fa5(%rip), %rsi      # 0x1c786
callq 0x34c0
cmpl $0x0, %eax
je 0x177fa
movq -0x18(%rbp), %rdi
callq 0x3550
movb $0x0, -0x1(%rbp)
jmp 0x17818
jmp 0x177fc
movq -0x18(%rbp), %rdi
callq 0x3510
movq %rax, -0x20(%rbp)
jmp 0x177b2
movq -0x18(%rbp), %rdi
callq 0x3550
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: get_file_size(char const*)
uint64_t get_file_size(const char *in_fname) {
  FILE *fp;
#ifdef _WIN32
  struct __stat64 st;
#elif __APPLE__
  struct stat st;
#else
  struct stat64 st;
#endif
  int fd;

  fd = open(in_fname, O_RDONLY);
  if (fd == -1)
    perror("cant open file");

  fp = fdopen(fd, "rb");

  if (fp == NULL)
    perror("cant open file");

#ifdef _WIN32
  if (_fstat64(fd, &st) == -1)
#elif __APPLE__
  if (fstat(fd, &st) == -1)
#else
  if (fstat64(fd, &st) == -1)
#endif
    perror("cant get file state");

  if (fclose(fp) != 0)
    perror("cant close file");

  return st.st_size;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
xorl %esi, %esi
movb $0x0, %al
callq 0x3240
movl %eax, -0xa4(%rbp)
cmpl $-0x1, -0xa4(%rbp)
jne 0x17867
leaq 0x4f27(%rip), %rdi      # 0x1c789
callq 0x32a0
movl -0xa4(%rbp), %edi
leaq 0x47d4(%rip), %rsi      # 0x1c048
callq 0x33a0
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x17890
leaq 0x4efe(%rip), %rdi      # 0x1c789
callq 0x32a0
movl -0xa4(%rbp), %edi
leaq -0xa0(%rbp), %rsi
callq 0x35f0
cmpl $-0x1, %eax
jne 0x178b3
leaq 0x4eea(%rip), %rdi      # 0x1c798
callq 0x32a0
movq -0x10(%rbp), %rdi
callq 0x3330
cmpl $0x0, %eax
je 0x178cd
leaq 0x4ee4(%rip), %rdi      # 0x1c7ac
callq 0x32a0
movq -0x70(%rbp), %rax
addq $0xb0, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: is_valid_usn(unsigned long)
bool is_valid_usn(uint64_t value) {
  if (value > 10000000000000) // means 10T
	  return false;
  else 
	  return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movabsq $0x9184e72a000, %rax    # imm = 0x9184E72A000
cmpq %rax, -0x10(%rbp)
jbe 0x178fe
movb $0x0, -0x1(%rbp)
jmp 0x17902
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nopl (%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: is_valid_ts(unsigned long)
bool is_valid_ts(uint64_t value) {
  // 11644473600 seconds from 1601/01/01 to 1970/01/01
  time_t epoch = value/(10*1000*1000) - 11644473600L;
  // unix epoch 946684800 is 2000/01/01, 2524608000 is 2050/01/01, 4102444800 is 2100/01/01
  if(epoch < 946684800 || epoch > 2524608000)
    return false;
  else
    return true;  
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movl $0x989680, %ecx         # imm = 0x989680
xorl %edx, %edx
divq %rcx
movabsq $0x2b6109100, %rcx      # imm = 0x2B6109100
subq %rcx, %rax
movq %rax, -0x18(%rbp)
cmpq $0x386d4380, -0x18(%rbp) # imm = 0x386D4380
jl 0x1794c
movl $0x967a7600, %eax       # imm = 0x967A7600
cmpq %rax, -0x18(%rbp)
jle 0x17952
movb $0x0, -0x1(%rbp)
jmp 0x17956
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
popq %rbp
retq
nopl (%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: parse_datetime[abi:cxx11](unsigned long, bool)
string parse_datetime(uint64_t _time, bool lt) {
  char buf[32];
  struct tm *tm_info;
  time_t epoch;

  // 11644473600 seconds from 1601/01/01 to 1970/01/01
  epoch = _time/(10*1000*1000) - 11644473600L;

  if(lt)
    tm_info = localtime(&epoch);
  else
    tm_info = gmtime(&epoch);

  strftime(buf, 20, "%Y/%m/%d %H:%M:%S", tm_info);
  
  return string(buf);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x78(%rbp)
movb %dl, %al
movq %rdi, %rcx
movq %rcx, -0x70(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
andb $0x1, %al
movb %al, -0x11(%rbp)
movq -0x10(%rbp), %rax
movl $0x989680, %ecx         # imm = 0x989680
xorl %edx, %edx
divq %rcx
movabsq $0x2b6109100, %rcx      # imm = 0x2B6109100
subq %rcx, %rax
movq %rax, -0x50(%rbp)
testb $0x1, -0x11(%rbp)
je 0x179b9
leaq -0x50(%rbp), %rdi
callq 0x3250
movq %rax, -0x48(%rbp)
jmp 0x179c6
leaq -0x50(%rbp), %rdi
callq 0x32d0
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rcx
leaq 0x4deb(%rip), %rdx      # 0x1c7bc
leaq -0x40(%rbp), %rdi
movq %rdi, -0x88(%rbp)
movl $0x14, %esi
callq 0x3280
leaq -0x51(%rbp), %rdi
movq %rdi, -0x80(%rbp)
callq 0x35d0
movq -0x78(%rbp), %rdi
movq -0x88(%rbp), %rsi
movq -0x80(%rbp), %rdx
callq 0xa400
jmp 0x17a09
leaq -0x51(%rbp), %rdi
callq 0x33c0
movq -0x70(%rbp), %rax
addq $0x90, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x51(%rbp), %rdi
callq 0x33c0
movq -0x60(%rbp), %rdi
callq 0x35c0
nopl (%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: parse_datetime_iso8601[abi:cxx11](unsigned long, bool)
string parse_datetime_iso8601(uint64_t _time, bool lt) {
  char buf[32];
  struct tm *tm_info;
  time_t epoch;

  // 11644473600 seconds from 1601/01/01 to 1970/01/01
  epoch = _time/(10*1000*1000) - 11644473600L;

  if(lt)
    tm_info = localtime(&epoch);
  else
    tm_info = gmtime(&epoch);

  strftime(buf, 16, "%Y%m%dT%H%M%S", tm_info);
  
  return string(buf);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x78(%rbp)
movb %dl, %al
movq %rdi, %rcx
movq %rcx, -0x70(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
andb $0x1, %al
movb %al, -0x11(%rbp)
movq -0x10(%rbp), %rax
movl $0x989680, %ecx         # imm = 0x989680
xorl %edx, %edx
divq %rcx
movabsq $0x2b6109100, %rcx      # imm = 0x2B6109100
subq %rcx, %rax
movq %rax, -0x50(%rbp)
testb $0x1, -0x11(%rbp)
je 0x17a99
leaq -0x50(%rbp), %rdi
callq 0x3250
movq %rax, -0x48(%rbp)
jmp 0x17aa6
leaq -0x50(%rbp), %rdi
callq 0x32d0
movq %rax, -0x48(%rbp)
movq -0x48(%rbp), %rcx
leaq 0x4d1d(%rip), %rdx      # 0x1c7ce
leaq -0x40(%rbp), %rdi
movq %rdi, -0x88(%rbp)
movl $0x10, %esi
callq 0x3280
leaq -0x51(%rbp), %rdi
movq %rdi, -0x80(%rbp)
callq 0x35d0
movq -0x78(%rbp), %rdi
movq -0x88(%rbp), %rsi
movq -0x80(%rbp), %rdx
callq 0xa400
jmp 0x17ae9
leaq -0x51(%rbp), %rdi
callq 0x33c0
movq -0x70(%rbp), %rax
addq $0x90, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x60(%rbp)
movl %eax, -0x64(%rbp)
leaq -0x51(%rbp), %rdi
callq 0x33c0
movq -0x60(%rbp), %rdi
callq 0x35c0
nopl (%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: join(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, char const*)
string join(const vector<string>& v, const char* delim = 0) {
  std::string s;
  if (!v.empty()) {
    s += v[0];
    for (decltype(v.size()) i = 1, c = v.size(); i < c; ++i) {
      if (delim) s += delim;
      s += v[i];
    }
  }
  return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x50(%rbp)
movq %rdi, %rax
movq %rax, -0x48(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movb $0x0, -0x19(%rbp)
callq 0x34b0
movq -0x10(%rbp), %rdi
callq 0x1a0f0
testb $0x1, %al
jne 0x17e7f
movq -0x10(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x1a130
movq -0x50(%rbp), %rdi
movq %rax, %rsi
callq 0x3470
jmp 0x17e04
movq $0x1, -0x38(%rbp)
movq -0x10(%rbp), %rdi
callq 0x1a150
movq %rax, -0x40(%rbp)
movq -0x38(%rbp), %rax
cmpq -0x40(%rbp), %rax
jae 0x17e7d
cmpq $0x0, -0x18(%rbp)
je 0x17e52
movq -0x50(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x3310
jmp 0x17e39
jmp 0x17e52
movq -0x50(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
callq 0x31d0
jmp 0x17e9c
movq -0x10(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x1a130
movq -0x50(%rbp), %rdi
movq %rax, %rsi
callq 0x3470
jmp 0x17e6d
jmp 0x17e6f
movq -0x38(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x38(%rbp)
jmp 0x17e19
jmp 0x17e7f
movb $0x1, -0x19(%rbp)
testb $0x1, -0x19(%rbp)
jne 0x17e92
movq -0x50(%rbp), %rdi
callq 0x31d0
movq -0x48(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
movq -0x28(%rbp), %rdi
callq 0x35c0
nopw %cs:(%rax,%rax)
// File: 4n6ist[P]usn_analytics/lib/utils.cpp
// Function: get_timezone_str[abi:cxx11](bool)
string get_timezone_str(bool lt) {
  if (lt) {
    time_t t1, t2;
    time(&t1);
    struct tm *tm_info;
    int tz_hour, tz_min;
    char tzstr[16];

    tm_info = localtime(&t1);
    tz_hour = tm_info->tm_hour;
    tz_min = tm_info->tm_min;	

    tm_info = gmtime(&t1);
    tz_hour -= tm_info->tm_hour;
    tz_min -= tm_info->tm_min;

    t2 = mktime(tm_info);

    if(t1-t2 > 0 && tz_hour < 0)
      tz_hour += 24;

    if(tz_min < 0) {
      tz_min += 60;  
      tz_hour--;
    }
    
    if(tz_hour >= 0)
      sprintf(tzstr, "+%02d:%02d", tz_hour, tz_min); 
    else
      sprintf(tzstr, "%02d:%02d", tz_hour, tz_min);

    return string(tzstr);
  }
  else 
    return "+00:00";
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x68(%rbp)
movb %sil, %al
movq %rdi, %rcx
movq %rcx, -0x60(%rbp)
movq %rdi, -0x8(%rbp)
andb $0x1, %al
movb %al, -0x9(%rbp)
testb $0x1, -0x9(%rbp)
je 0x1a08d
leaq -0x18(%rbp), %rdi
callq 0x3300
leaq -0x18(%rbp), %rdi
callq 0x3250
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, -0x30(%rbp)
leaq -0x18(%rbp), %rdi
callq 0x32d0
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movl 0x8(%rax), %ecx
movl -0x2c(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rax
movl 0x4(%rax), %ecx
movl -0x30(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x30(%rbp)
movq -0x28(%rbp), %rdi
callq 0x31f0
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
subq -0x20(%rbp), %rax
cmpq $0x0, %rax
jle 0x19ffb
cmpl $0x0, -0x2c(%rbp)
jge 0x19ffb
movl -0x2c(%rbp), %eax
addl $0x18, %eax
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x30(%rbp)
jge 0x1a013
movl -0x30(%rbp), %eax
addl $0x3c, %eax
movl %eax, -0x30(%rbp)
movl -0x2c(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x2c(%rbp)
cmpl $0x0, -0x2c(%rbp)
jl 0x1a033
leaq -0x40(%rbp), %rdi
movl -0x2c(%rbp), %edx
movl -0x30(%rbp), %ecx
leaq 0x28db(%rip), %rsi      # 0x1c905
movb $0x0, %al
callq 0x30a0
jmp 0x1a04b
leaq -0x40(%rbp), %rdi
movl -0x2c(%rbp), %edx
movl -0x30(%rbp), %ecx
leaq 0x28c2(%rip), %rsi      # 0x1c906
movb $0x0, %al
callq 0x30a0
leaq -0x41(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x35d0
movq -0x68(%rbp), %rdi
movq -0x70(%rbp), %rdx
leaq -0x40(%rbp), %rsi
callq 0xa400
jmp 0x1a06b
leaq -0x41(%rbp), %rdi
callq 0x33c0
jmp 0x1a0d2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x41(%rbp), %rdi
callq 0x33c0
jmp 0x1a0df
leaq -0x55(%rbp), %rdi
movq %rdi, -0x78(%rbp)
callq 0x35d0
movq -0x68(%rbp), %rdi
movq -0x78(%rbp), %rdx
leaq 0x2867(%rip), %rsi      # 0x1c910
callq 0xa400
jmp 0x1a0b0
leaq -0x55(%rbp), %rdi
callq 0x33c0
jmp 0x1a0d2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x55(%rbp), %rdi
callq 0x33c0
jmp 0x1a0df
movq -0x60(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
movq -0x50(%rbp), %rdi
callq 0x35c0
nopl (%rax,%rax)
// File: 4n6ist[P]usn_analytics/src/main.cpp
// Function: usage()
void usage(void) {
	printf("USN Analytics (https://www.kazamiya.net/usn_analytics/) v.201801\n\n");
	printf("Usage  : usn_analytics.exe [-ru] -o output input\n\n");
	printf("     -r: parse all of USN_RECORD and write to all.csv with raw style\n");
	printf("     -u: treat a timestamp as UTC (default: Local Time)\n");
	printf(" -o out: specify a output directory\n");
	printf("     in: specify a bunch of data including USN_RECORD\n\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x1b45(%rip), %rdi      # 0x1c950
movb $0x0, %al
callq 0x3060
leaq 0x1b7a(%rip), %rdi      # 0x1c993
movb $0x0, %al
callq 0x3060
leaq 0x1b9f(%rip), %rdi      # 0x1c9c6
movb $0x0, %al
callq 0x3060
leaq 0x1bd7(%rip), %rdi      # 0x1ca0c
movb $0x0, %al
callq 0x3060
leaq 0x1c02(%rip), %rdi      # 0x1ca45
movb $0x0, %al
callq 0x3060
leaq 0x1c19(%rip), %rdi      # 0x1ca6a
movb $0x0, %al
callq 0x3060
popq %rbp
retq
nopw (%rax,%rax)
// File: 4n6ist[P]usn_analytics/src/main.cpp
// Function: process(char*, char*)
void process(char *ifname, char *odname) {
    
  UsnJrnl usnjrnl = UsnJrnl(ifname, odname);

  printf("Search USNRECORD");
  usnjrnl.GetAllUsnOffset();
  if (raw == true) {
    usnjrnl.WriteAllRecords(odname, lt);
  } else {
    usnjrnl.PreProcess();
    printf("Check records");
    usnjrnl.CheckRecords();
    printf("Path construction");
    usnjrnl.PostProcess();
    printf("Write records");
    usnjrnl.WriteBundledRecords(odname, lt);
    printf("Check executed trace");
    usnjrnl.WriteExecutedRecords(odname, lt);
    printf("Check opened trace");
    usnjrnl.WriteOpenedRecords(odname, lt);
    printf("Check suspicious trace");
    usnjrnl.WriteSuspiciousInfo();
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x120, %rsp            # imm = 0x120
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rsi
movq -0x10(%rbp), %rdx
leaq -0x108(%rbp), %rdi
callq 0x38e0
leaq 0x1c14(%rip), %rdi      # 0x1caa2
xorl %eax, %eax
callq 0x3060
jmp 0x1ae97
leaq -0x108(%rbp), %rdi
callq 0x3c40
jmp 0x1aea5
movb 0xc49c(%rip), %al       # 0x27347
andb $0x1, %al
movzbl %al, %eax
cmpl $0x1, %eax
jne 0x1aef9
movq -0x10(%rbp), %rsi
movzbl 0xc480(%rip), %edx      # 0x27340
andl $0x1, %edx
leaq -0x108(%rbp), %rdi
callq 0x9af0
jmp 0x1aed1
jmp 0x1afe7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x110(%rbp)
movl %eax, -0x114(%rbp)
leaq -0x108(%rbp), %rdi
callq 0x3850
jmp 0x1affc
leaq -0x108(%rbp), %rdi
callq 0x3e70
jmp 0x1af07
leaq 0x1ba5(%rip), %rdi      # 0x1cab3
xorl %eax, %eax
callq 0x3060
jmp 0x1af17
leaq -0x108(%rbp), %rdi
callq 0x40a0
jmp 0x1af25
leaq 0x1b95(%rip), %rdi      # 0x1cac1
xorl %eax, %eax
callq 0x3060
jmp 0x1af35
leaq -0x108(%rbp), %rdi
callq 0x6750
jmp 0x1af43
leaq 0x1b89(%rip), %rdi      # 0x1cad3
xorl %eax, %eax
callq 0x3060
jmp 0x1af53
movq -0x10(%rbp), %rsi
movzbl 0xc3e2(%rip), %edx      # 0x27340
andl $0x1, %edx
leaq -0x108(%rbp), %rdi
callq 0x6d00
jmp 0x1af6f
leaq 0x1b6b(%rip), %rdi      # 0x1cae1
xorl %eax, %eax
callq 0x3060
jmp 0x1af7f
movq -0x10(%rbp), %rsi
movzbl 0xc3b6(%rip), %edx      # 0x27340
andl $0x1, %edx
leaq -0x108(%rbp), %rdi
callq 0x7240
jmp 0x1af9b
leaq 0x1b54(%rip), %rdi      # 0x1caf6
xorl %eax, %eax
callq 0x3060
jmp 0x1afab
movq -0x10(%rbp), %rsi
movzbl 0xc38a(%rip), %edx      # 0x27340
andl $0x1, %edx
leaq -0x108(%rbp), %rdi
callq 0x7c10
jmp 0x1afc7
leaq 0x1b3b(%rip), %rdi      # 0x1cb09
xorl %eax, %eax
callq 0x3060
jmp 0x1afd7
leaq -0x108(%rbp), %rdi
callq 0x8460
jmp 0x1afe5
jmp 0x1afe7
leaq -0x108(%rbp), %rdi
callq 0x3850
addq $0x120, %rsp            # imm = 0x120
popq %rbp
retq
movq -0x110(%rbp), %rdi
callq 0x35c0
nopl (%rax,%rax)
// File: QiumingLu[P]conhash/conhash.cc
// Function: ConHash::AddNode(Node const&)
void ConHash::AddNode(const Node& node) {
  assert(node.replicas > 0);
  for (int i = 0; i < node.replicas; ++i) {
    uint32_t key = Hash(node.identify, i);
    vnodes_.insert(std::make_pair(key, node));
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x70(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x0, 0x20(%rax)
jle 0x33a7
jmp 0x33c6
leaq 0x2cbf(%rip), %rdi      # 0x606d
leaq 0x2cca(%rip), %rsi      # 0x607f
movl $0xd, %edx
leaq 0x2cc9(%rip), %rcx      # 0x608a
callq 0x20f0
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
movq -0x10(%rbp), %rcx
cmpl 0x20(%rcx), %eax
jge 0x3456
movq -0x70(%rbp), %rdi
movq -0x10(%rbp), %rsi
movl -0x14(%rbp), %edx
callq 0x3470
movl %eax, -0x18(%rbp)
movq -0x10(%rbp), %rdx
leaq -0x48(%rbp), %rdi
movq %rdi, -0x88(%rbp)
leaq -0x18(%rbp), %rsi
callq 0x36c0
movq -0x70(%rbp), %rdi
movq -0x88(%rbp), %rsi
callq 0x3680
movb %dl, -0x79(%rbp)
movq %rax, -0x78(%rbp)
jmp 0x341d
movb -0x79(%rbp), %al
movq -0x78(%rbp), %rcx
movq %rcx, -0x68(%rbp)
movb %al, -0x60(%rbp)
leaq -0x48(%rbp), %rdi
callq 0x3700
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x33cd
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x48(%rbp), %rdi
callq 0x3700
jmp 0x345f
addq $0x90, %rsp
popq %rbp
retq
movq -0x50(%rbp), %rdi
callq 0x2280
nopl (%rax,%rax)
// File: QiumingLu[P]conhash/conhash.cc
// Function: ConHash::Hash(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, int)
uint32_t ConHash::Hash(const std::string& identify, int i) {
  char buf[128];
  int len = snprintf(buf, sizeof(buf), "%s#%d", identify.c_str(), i);
  assert(len > 0);
  uint32_t out;
  MurmurHash3_x86_32(buf, len, 0, &out);
  return out;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
leaq -0xa0(%rbp), %rax
movq %rax, -0xb0(%rbp)
movq -0x10(%rbp), %rdi
callq 0x2090
movq -0xb0(%rbp), %rdi
movq %rax, %rcx
movl -0x14(%rbp), %r8d
movl $0x80, %esi
leaq 0x2bf7(%rip), %rdx      # 0x60ae
movb $0x0, %al
callq 0x2260
movl %eax, -0xa4(%rbp)
cmpl $0x0, -0xa4(%rbp)
jle 0x34cf
jmp 0x34ee
leaq 0x2bde(%rip), %rdi      # 0x60b4
leaq 0x2ba2(%rip), %rsi      # 0x607f
movl $0x2f, %edx
leaq 0x2bd3(%rip), %rcx      # 0x60bc
callq 0x20f0
leaq -0xa0(%rbp), %rdi
movl -0xa4(%rbp), %esi
xorl %edx, %edx
leaq -0xa8(%rbp), %rcx
callq 0x4860
movl -0xa8(%rbp), %eax
addq $0xb0, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: QiumingLu[P]conhash/conhash.cc
// Function: ConHash::Lookup(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, Node*)
bool ConHash::Lookup(const std::string& object, Node* node) {
  if (vnodes_.empty()) {
    return false;
  }

  uint32_t key;
  MurmurHash3_x86_32(object.c_str(), static_cast<int>(object.size()), 0, &key);

  std::map<uint32_t, Node>::iterator it = vnodes_.upper_bound(key);
  if (it == vnodes_.end()) {
    *node = vnodes_.begin()->second;
  } else {
    *node = it->second;
  }
  return true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rdi
movq %rdi, -0x48(%rbp)
callq 0x3750
testb $0x1, %al
jne 0x35a7
jmp 0x35b0
movb $0x0, -0x1(%rbp)
jmp 0x364d
movq -0x18(%rbp), %rdi
callq 0x2090
movq %rax, -0x50(%rbp)
movq -0x18(%rbp), %rdi
callq 0x2110
movq -0x50(%rbp), %rdi
movl %eax, %esi
xorl %edx, %edx
leaq -0x24(%rbp), %rcx
callq 0x4860
movq -0x48(%rbp), %rdi
leaq -0x24(%rbp), %rsi
callq 0x3770
movq -0x48(%rbp), %rdi
movq %rax, -0x30(%rbp)
callq 0x37d0
movq %rax, -0x38(%rbp)
leaq -0x30(%rbp), %rdi
leaq -0x38(%rbp), %rsi
callq 0x37a0
testb $0x1, %al
jne 0x3608
jmp 0x3630
movq -0x48(%rbp), %rdi
callq 0x3800
movq %rax, -0x40(%rbp)
leaq -0x40(%rbp), %rdi
callq 0x3830
movq %rax, %rsi
addq $0x8, %rsi
movq -0x20(%rbp), %rdi
callq 0x3850
jmp 0x3649
leaq -0x30(%rbp), %rdi
callq 0x3830
movq %rax, %rsi
addq $0x8, %rsi
movq -0x20(%rbp), %rdi
callq 0x3850
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/main.cpp
// Function: help(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void help(string fn) {
	fprintf(stderr, "Usage: %s [other flags ...]\n", fn.c_str());
	fprintf(stderr, "\n");
	fprintf(stderr, "flags include:\n");
	fprintf(stderr, "  --max-tick (number)\n    limit execution tick to given number of ticks maximum.\n");
	fprintf(stderr, "  --ban-block (wire|torch|repeater|comparator)\n    if given circuit contains the block, rejects the execution.\n");
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq 0xac00(%rip), %rax      # 0xcfe0
movq (%rax), %rax
movq %rax, 0x8(%rsp)
callq 0x20a0
movq 0x8(%rsp), %rdi
movq %rax, %rdx
leaq 0x6c30(%rip), %rsi      # 0x902c
movb $0x0, %al
callq 0x2230
movq 0xabd6(%rip), %rax      # 0xcfe0
movq (%rax), %rdi
leaq 0x6da8(%rip), %rsi      # 0x91bc
movb $0x0, %al
callq 0x2230
movq 0xabbe(%rip), %rax      # 0xcfe0
movq (%rax), %rdi
leaq 0x6c1d(%rip), %rsi      # 0x9049
movb $0x0, %al
callq 0x2230
movq 0xaba6(%rip), %rax      # 0xcfe0
movq (%rax), %rdi
leaq 0x6c15(%rip), %rsi      # 0x9059
movb $0x0, %al
callq 0x2230
movq 0xab8e(%rip), %rax      # 0xcfe0
movq (%rax), %rdi
leaq 0x6c4f(%rip), %rsi      # 0x90ab
movb $0x0, %al
callq 0x2230
addq $0x18, %rsp
retq
nopl (%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/bytestream.cpp
// Function: bytereader::close()
void bytereader::close() {
	if (fp) {
		fclose(fp);
		fp = nullptr;
		pos = len = 0;
	}
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, (%rax)
je 0x8170
movq 0x8(%rsp), %rax
movq (%rax), %rdi
callq 0x2160
movq 0x8(%rsp), %rax
movq $0x0, (%rax)
movl $0x0, 0x14(%rax)
movl $0x0, 0x10(%rax)
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/bytestream.cpp
// Function: bytereader::read_byte()
byte bytereader::read_byte() {
	if (pos == len) {
		if ((len = fread(buf, 1, 1048576, fp)) <= 0) {
			throw EOF_ERROR;
		}
		pos = 0;
	}
	return buf[pos++];
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq 0x10(%rsp), %rcx
movq %rcx, 0x8(%rsp)
movl 0x10(%rcx), %eax
cmpl 0x14(%rcx), %eax
jne 0x81f2
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rdi
movq (%rax), %rcx
movl $0x1, %esi
movl $0x100000, %edx         # imm = 0x100000
callq 0x2250
movq 0x8(%rsp), %rcx
movl %eax, 0x14(%rcx)
cmpl $0x0, %eax
jg 0x81e6
movl $0x4, %edi
callq 0x20c0
movq %rax, %rdi
movl $0xffffffff, (%rdi)     # imm = 0xFFFFFFFF
movq 0x4deb(%rip), %rsi      # 0xcfc8
xorl %eax, %eax
movl %eax, %edx
callq 0x2280
movq 0x8(%rsp), %rax
movl $0x0, 0x10(%rax)
movq 0x8(%rsp), %rdx
movq 0x8(%rdx), %rax
movl 0x10(%rdx), %ecx
movl %ecx, %esi
addl $0x1, %esi
movl %esi, 0x10(%rdx)
movslq %ecx, %rcx
movb (%rax,%rcx), %al
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/bytestream.cpp
// Function: bytereader::read_int()
int bytereader::read_int() {
	u32 x;
	int i;
	for (i=0; i<4; ++i) {
		(x <<= 8) |= read_byte();
	}
	return (int)x;
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movq 0x10(%rsp), %rax
movq %rax, (%rsp)
movl $0x0, 0x8(%rsp)
cmpl $0x4, 0x8(%rsp)
jge 0x826d
movq (%rsp), %rdi
callq 0x8180
movzbl %al, %eax
movl 0xc(%rsp), %ecx
shll $0x8, %ecx
movl %ecx, 0xc(%rsp)
orl 0xc(%rsp), %eax
movl %eax, 0xc(%rsp)
movl 0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x8(%rsp)
jmp 0x823a
movl 0xc(%rsp), %eax
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/node.cpp
// Function: wire::update(int, int)
bool wire::update(int power, int side) {
	int calculated_power = std::max({power, side - 1, 0});
	if (this->power == calculated_power) {
		return false;
	}
	this->power = calculated_power;
	return true;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movl %esi, 0x34(%rsp)
movl %edx, 0x30(%rsp)
movq 0x38(%rsp), %rax
movq %rax, (%rsp)
movl 0x34(%rsp), %eax
movl %eax, 0xc(%rsp)
movl 0x30(%rsp), %eax
subl $0x1, %eax
movl %eax, 0x10(%rsp)
movl $0x0, 0x14(%rsp)
leaq 0xc(%rsp), %rax
movq %rax, 0x18(%rsp)
movq $0x3, 0x20(%rsp)
movq 0x18(%rsp), %rdi
movq 0x20(%rsp), %rsi
callq 0x87a0
movl %eax, %ecx
movq (%rsp), %rax
movl %ecx, 0x2c(%rsp)
movl 0x38(%rax), %eax
cmpl 0x2c(%rsp), %eax
jne 0x8361
movb $0x0, 0x47(%rsp)
jmp 0x8371
movq (%rsp), %rax
movl 0x2c(%rsp), %ecx
movl %ecx, 0x38(%rax)
movb $0x1, 0x47(%rsp)
movb 0x47(%rsp), %al
andb $0x1, %al
addq $0x48, %rsp
retq
nopl (%rax)
// File: kipa00[P]AplusB-mc/interpreter/node.cpp
// Function: torch::update(int)
bool torch::update(int power) {
	int calculated_power = power ? 0 : 15;
	if (this->power == calculated_power) {
		return false;
	}
	this->power = calculated_power;
	return true;
}

// Assembly:
movq %rdi, -0x10(%rsp)
movl %esi, -0x14(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x20(%rsp)
movl -0x14(%rsp), %esi
movl $0xf, %ecx
xorl %edx, %edx
cmpl $0x0, %esi
cmovnel %edx, %ecx
movl %ecx, -0x18(%rsp)
movl 0x38(%rax), %eax
cmpl -0x18(%rsp), %eax
jne 0x83f8
movb $0x0, -0x1(%rsp)
jmp 0x8409
movq -0x20(%rsp), %rax
movl -0x18(%rsp), %ecx
movl %ecx, 0x38(%rax)
movb $0x1, -0x1(%rsp)
movb -0x1(%rsp), %al
andb $0x1, %al
retq
// File: kipa00[P]AplusB-mc/interpreter/node.cpp
// Function: repeater::update(int, int)
bool repeater::update(int power, int side) {
	if (side) {
		if (lock == side) {
			return false;
		}
		lock = side;
		return true;
	}
	int calculated_power = power ? 15 : 0;
	if (this->power == calculated_power && lock == side) {
		return false;
	}
	this->lock = side;
	this->power = calculated_power;
	return true;
}

// Assembly:
movq %rdi, -0x10(%rsp)
movl %esi, -0x14(%rsp)
movl %edx, -0x18(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x28(%rsp)
cmpl $0x0, -0x18(%rsp)
je 0x8496
movq -0x28(%rsp), %rax
movl 0x40(%rax), %eax
cmpl -0x18(%rsp), %eax
jne 0x8483
movb $0x0, -0x1(%rsp)
jmp 0x84e6
movq -0x28(%rsp), %rax
movl -0x18(%rsp), %ecx
movl %ecx, 0x40(%rax)
movb $0x1, -0x1(%rsp)
jmp 0x84e6
movq -0x28(%rsp), %rax
movl -0x14(%rsp), %esi
xorl %ecx, %ecx
movl $0xf, %edx
cmpl $0x0, %esi
cmovnel %edx, %ecx
movl %ecx, -0x1c(%rsp)
movl 0x38(%rax), %eax
cmpl -0x1c(%rsp), %eax
jne 0x84ce
movq -0x28(%rsp), %rax
movl 0x40(%rax), %eax
cmpl -0x18(%rsp), %eax
jne 0x84ce
movb $0x0, -0x1(%rsp)
jmp 0x84e6
movq -0x28(%rsp), %rax
movl -0x18(%rsp), %ecx
movl %ecx, 0x40(%rax)
movl -0x1c(%rsp), %ecx
movl %ecx, 0x38(%rax)
movb $0x1, -0x1(%rsp)
movb -0x1(%rsp), %al
andb $0x1, %al
retq
nopl (%rax)
// File: kipa00[P]AplusB-mc/interpreter/node.cpp
// Function: comparator::update(int, int)
bool comparator::update(int power, int side) {
	int calculated_power = power >= side ? power : 0;
	if (this->power == calculated_power) {
		return false;
	}
	this->power = calculated_power;
	return true;
}

// Assembly:
movq %rdi, -0x10(%rsp)
movl %esi, -0x14(%rsp)
movl %edx, -0x18(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x28(%rsp)
movl -0x14(%rsp), %eax
cmpl -0x18(%rsp), %eax
jl 0x855b
movl -0x14(%rsp), %eax
movl %eax, -0x2c(%rsp)
jmp 0x8563
xorl %eax, %eax
movl %eax, -0x2c(%rsp)
jmp 0x8563
movq -0x28(%rsp), %rax
movl -0x2c(%rsp), %ecx
movl %ecx, -0x1c(%rsp)
movl 0x38(%rax), %eax
cmpl -0x1c(%rsp), %eax
jne 0x8580
movb $0x0, -0x1(%rsp)
jmp 0x8591
movq -0x28(%rsp), %rax
movl -0x1c(%rsp), %ecx
movl %ecx, 0x38(%rax)
movb $0x1, -0x1(%rsp)
movb -0x1(%rsp), %al
andb $0x1, %al
retq
nopl (%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/node.cpp
// Function: subtractor::update(int, int)
bool subtractor::update(int power, int side) {
	int calculated_power = std::max(power - side, 0);
	if (this->power == calculated_power) {
		return false;
	}
	this->power = calculated_power;
	return true;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movl %esi, 0x24(%rsp)
movl %edx, 0x20(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
movl 0x24(%rsp), %eax
subl 0x20(%rsp), %eax
movl %eax, 0x18(%rsp)
movl $0x0, 0x14(%rsp)
leaq 0x18(%rsp), %rdi
leaq 0x14(%rsp), %rsi
callq 0x4820
movq %rax, %rcx
movq 0x8(%rsp), %rax
movl (%rcx), %ecx
movl %ecx, 0x1c(%rsp)
movl 0x38(%rax), %eax
cmpl 0x1c(%rsp), %eax
jne 0x863c
movb $0x0, 0x37(%rsp)
jmp 0x864d
movq 0x8(%rsp), %rax
movl 0x1c(%rsp), %ecx
movl %ecx, 0x38(%rax)
movb $0x1, 0x37(%rsp)
movb 0x37(%rsp), %al
andb $0x1, %al
addq $0x38, %rsp
retq
nopl (%rax,%rax)
// File: kipa00[P]AplusB-mc/interpreter/node.cpp
// Function: lever::set_as(int)
bool lever::set_as(int power) {
	power = power ? 15 : 0;
	if (this->power == power) {
		return false;
	}
	this->power = power;
	return true;
}

// Assembly:
movq %rdi, -0x10(%rsp)
movl %esi, -0x14(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x20(%rsp)
movl -0x14(%rsp), %esi
xorl %ecx, %ecx
movl $0xf, %edx
cmpl $0x0, %esi
cmovnel %edx, %ecx
movl %ecx, -0x14(%rsp)
movl 0x38(%rax), %eax
cmpl -0x14(%rsp), %eax
jne 0x86e8
movb $0x0, -0x1(%rsp)
jmp 0x86f9
movq -0x20(%rsp), %rax
movl -0x14(%rsp), %ecx
movl %ecx, 0x38(%rax)
movb $0x1, -0x1(%rsp)
movb -0x1(%rsp), %al
andb $0x1, %al
retq
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: validityRegisters(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
bool validityRegisters(string reg)
{
	if(reg=="A"||reg=="B"||reg=="C"||reg=="D"||reg=="E"||reg=="H"||reg=="L")
		return true;
	else
		return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x18(%rbp)
movq %rdi, -0x10(%rbp)
leaq 0x1184b(%rip), %rsi     # 0x15062
callq 0x50a0
testb $0x1, %al
jne 0x389a
movq -0x18(%rbp), %rdi
leaq 0x117f5(%rip), %rsi     # 0x15020
callq 0x50a0
testb $0x1, %al
jne 0x389a
movq -0x18(%rbp), %rdi
leaq 0x117d5(%rip), %rsi     # 0x15014
callq 0x50a0
testb $0x1, %al
jne 0x389a
movq -0x18(%rbp), %rdi
leaq 0x117e1(%rip), %rsi     # 0x15034
callq 0x50a0
testb $0x1, %al
jne 0x389a
movq -0x18(%rbp), %rdi
leaq 0x1179d(%rip), %rsi     # 0x15004
callq 0x50a0
testb $0x1, %al
jne 0x389a
movq -0x18(%rbp), %rdi
leaq 0x1178b(%rip), %rsi     # 0x15006
callq 0x50a0
testb $0x1, %al
jne 0x389a
movq -0x18(%rbp), %rdi
leaq 0x11779(%rip), %rsi     # 0x15008
callq 0x50a0
testb $0x1, %al
jne 0x389a
jmp 0x38a0
movb $0x1, -0x1(%rbp)
jmp 0x38a4
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x20, %rsp
popq %rbp
retq
nop
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: validityRegisterPair(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
bool validityRegisterPair(string reg)
{
	if(reg=="B"||reg=="D"||reg=="H"||reg=="M")
		return true;
	else 
		return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x18(%rbp)
movq %rdi, -0x10(%rbp)
leaq 0x11739(%rip), %rsi     # 0x15020
callq 0x50a0
testb $0x1, %al
jne 0x392e
movq -0x18(%rbp), %rdi
leaq 0x11739(%rip), %rsi     # 0x15034
callq 0x50a0
testb $0x1, %al
jne 0x392e
movq -0x18(%rbp), %rdi
leaq 0x116f7(%rip), %rsi     # 0x15006
callq 0x50a0
testb $0x1, %al
jne 0x392e
movq -0x18(%rbp), %rdi
leaq 0x116ed(%rip), %rsi     # 0x15010
callq 0x50a0
testb $0x1, %al
jne 0x392e
jmp 0x3934
movb $0x1, -0x1(%rbp)
jmp 0x3938
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: registerNumber(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
int registerNumber(string str)
{
	if(str=="A")
		return 0;
	if(str=="B")
		return 1;
	if(str=="C")
		return 2;
	if(str=="D")
		return 3;
	if(str=="E")
		return 4;
	if(str=="H")
		return 5;
	if(str=="L")
		return 6;
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x18(%rbp)
movq %rdi, -0x10(%rbp)
leaq 0x116db(%rip), %rsi     # 0x15062
callq 0x50a0
testb $0x1, %al
jne 0x3992
jmp 0x399e
movl $0x0, -0x4(%rbp)
jmp 0x3a65
movq -0x18(%rbp), %rdi
leaq 0x11677(%rip), %rsi     # 0x15020
callq 0x50a0
testb $0x1, %al
jne 0x39b4
jmp 0x39c0
movl $0x1, -0x4(%rbp)
jmp 0x3a65
movq -0x18(%rbp), %rdi
leaq 0x11649(%rip), %rsi     # 0x15014
callq 0x50a0
testb $0x1, %al
jne 0x39d6
jmp 0x39e2
movl $0x2, -0x4(%rbp)
jmp 0x3a65
movq -0x18(%rbp), %rdi
leaq 0x11647(%rip), %rsi     # 0x15034
callq 0x50a0
testb $0x1, %al
jne 0x39f8
jmp 0x3a01
movl $0x3, -0x4(%rbp)
jmp 0x3a65
movq -0x18(%rbp), %rdi
leaq 0x115f8(%rip), %rsi     # 0x15004
callq 0x50a0
testb $0x1, %al
jne 0x3a17
jmp 0x3a20
movl $0x4, -0x4(%rbp)
jmp 0x3a65
movq -0x18(%rbp), %rdi
leaq 0x115db(%rip), %rsi     # 0x15006
callq 0x50a0
testb $0x1, %al
jne 0x3a36
jmp 0x3a3f
movl $0x5, -0x4(%rbp)
jmp 0x3a65
movq -0x18(%rbp), %rdi
leaq 0x115be(%rip), %rsi     # 0x15008
callq 0x50a0
testb $0x1, %al
jne 0x3a55
jmp 0x3a5e
movl $0x6, -0x4(%rbp)
jmp 0x3a65
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: itos[abi:cxx11](int)
string itos(int integer)
{	
		stringstream ss; 
  		ss<<integer;  
  		string s;  
  		ss>>s; 
	return s;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1c0, %rsp            # imm = 0x1C0
movq %rdi, -0x1b8(%rbp)
movq %rdi, %rax
movq %rax, -0x1b0(%rbp)
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
leaq -0x198(%rbp), %rdi
callq 0x31f0
leaq -0x188(%rbp), %rdi
movl -0xc(%rbp), %esi
callq 0x3420
jmp 0x3ab0
movq -0x1b8(%rbp), %rdi
movb $0x0, -0x1a5(%rbp)
callq 0x3390
movq -0x1b8(%rbp), %rsi
leaq -0x198(%rbp), %rdi
callq 0x3350
jmp 0x3ad8
movb $0x1, -0x1a5(%rbp)
testb $0x1, -0x1a5(%rbp)
jne 0x3b2a
jmp 0x3b1e
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
jmp 0x3b46
movq -0x1b8(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1a0(%rbp)
movl %eax, -0x1a4(%rbp)
callq 0x3190
jmp 0x3b46
movq -0x1b8(%rbp), %rdi
callq 0x3190
leaq -0x198(%rbp), %rdi
callq 0x3210
movq -0x1b0(%rbp), %rax
addq $0x1c0, %rsp            # imm = 0x1C0
popq %rbp
retq
leaq -0x198(%rbp), %rdi
callq 0x3210
movq -0x1a0(%rbp), %rdi
callq 0x3430
nop
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: split(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
string split(string s)
{
string p="ABC";
	int i=0;
	while(s[i]!=' ' && s[i]!='\0')		
	{
					p[i]=s[i];
					i++;
	}	
		p[i]='\0';
		return p;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rsi, -0x48(%rbp)
movq %rdi, -0x38(%rbp)
movq %rdi, %rax
movq %rax, -0x40(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movb $0x0, -0x11(%rbp)
leaq -0x12(%rbp), %rdi
movq %rdi, -0x30(%rbp)
callq 0x3440
movq -0x38(%rbp), %rdi
movq -0x30(%rbp), %rdx
leaq 0x11470(%rip), %rsi     # 0x15012
callq 0x50d0
jmp 0x3ba9
leaq -0x12(%rbp), %rdi
callq 0x32f0
movl $0x0, -0x28(%rbp)
movq -0x48(%rbp), %rdi
movslq -0x28(%rbp), %rsi
callq 0x34a0
movq %rax, -0x50(%rbp)
jmp 0x3bcc
movq -0x50(%rbp), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x20, %ecx
movb %al, -0x51(%rbp)
je 0x3c00
movq -0x48(%rbp), %rdi
movslq -0x28(%rbp), %rsi
callq 0x34a0
movq %rax, -0x60(%rbp)
jmp 0x3bf0
movq -0x60(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x51(%rbp)
movb -0x51(%rbp), %al
testb $0x1, %al
jne 0x3c09
jmp 0x3c7d
movq -0x48(%rbp), %rdi
movslq -0x28(%rbp), %rsi
callq 0x34a0
movq %rax, -0x68(%rbp)
jmp 0x3c1c
movq -0x38(%rbp), %rdi
movq -0x68(%rbp), %rax
movb (%rax), %al
movb %al, -0x71(%rbp)
movslq -0x28(%rbp), %rsi
callq 0x34a0
movq %rax, -0x70(%rbp)
jmp 0x3c38
movq -0x70(%rbp), %rax
movb -0x71(%rbp), %cl
movb %cl, (%rax)
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0x3bb9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
leaq -0x12(%rbp), %rdi
callq 0x32f0
jmp 0x3cb7
movq -0x38(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x20(%rbp)
movl %eax, -0x24(%rbp)
callq 0x3190
jmp 0x3cb7
movq -0x38(%rbp), %rdi
movslq -0x28(%rbp), %rsi
callq 0x34a0
movq %rax, -0x80(%rbp)
jmp 0x3c90
movq -0x80(%rbp), %rax
movb $0x0, (%rax)
movb $0x1, -0x11(%rbp)
testb $0x1, -0x11(%rbp)
jne 0x3caa
movq -0x38(%rbp), %rdi
callq 0x3190
movq -0x40(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
movq -0x20(%rbp), %rdi
callq 0x3430
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: validityData(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
bool validityData(string a)
{
	int l=a.length();
	if(l==2)
	{
		if((a[0]>='0'&&a[0]<='9')||(a[0]>='A'&&a[0]<='F'))
		{
			if((a[1]>='0'&&a[1]<='9')||(a[1]>='A'&&a[1]<='F'))
				return true;
			else 
				return false;
		}
		else
			return false;
	}
	else 
		return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x20(%rbp)
movq %rdi, -0x10(%rbp)
callq 0x33b0
movl %eax, -0x14(%rbp)
cmpl $0x2, -0x14(%rbp)
jne 0x3da0
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jl 0x3d0c
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x39, %eax
jle 0x3d36
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x41, %eax
jl 0x3d9a
movq -0x20(%rbp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x46, %eax
jg 0x3d9a
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jl 0x3d62
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x39, %eax
jle 0x3d8e
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x41, %eax
jl 0x3d94
movq -0x20(%rbp), %rdi
movl $0x1, %esi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x46, %eax
jg 0x3d94
movb $0x1, -0x1(%rbp)
jmp 0x3da4
movb $0x0, -0x1(%rbp)
jmp 0x3da4
movb $0x0, -0x1(%rbp)
jmp 0x3da4
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x20, %rsp
popq %rbp
retq
nop
// File: sthapliyal37[P]Microprocessor_8085_Updated/Validation.cpp
// Function: validityAddress(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
bool validityAddress(string data)
{
	bool flag;
	int l=data.length();
	if(l==4)
	{
		for(int i=0;i<l;i++)
			if(( data[i]>='0' && data[i]<='9')||( data[i]>='A' && data[i]<='F' ))
				flag = true;
			else
				flag = false;
		return flag;
	}
	else
		return false;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x28(%rbp)
movq %rdi, -0x10(%rbp)
callq 0x33b0
movl %eax, -0x18(%rbp)
cmpl $0x4, -0x18(%rbp)
jne 0x3e56
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x18(%rbp), %eax
jge 0x3e4c
movq -0x28(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x30, %eax
jl 0x3e0b
movq -0x28(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x39, %eax
jle 0x3e35
movq -0x28(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x41, %eax
jl 0x3e3b
movq -0x28(%rbp), %rdi
movslq -0x1c(%rbp), %rsi
callq 0x34a0
movsbl (%rax), %eax
cmpl $0x46, %eax
jg 0x3e3b
movb $0x1, -0x11(%rbp)
jmp 0x3e3f
movb $0x0, -0x11(%rbp)
jmp 0x3e41
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x3dd9
movb -0x11(%rbp), %al
andb $0x1, %al
movb %al, -0x1(%rbp)
jmp 0x3e5a
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)