LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/pcalutil.c
// Function: mk_filespec
char *mk_filespec (char *filespec, char *path, char *name)
{
   char *p;
   
   *filespec = '\0';
   
   /* copy name intact if absolute; else merge path and relative name */
   
   /* if name starts with "~/", translate it for user */
   if (strncmp(name, "~/", 2) == 0 && (p = getenv(HOME_DIR)) != NULL) {
      strcpy(filespec, p);
      TERM_PATH(filespec);
      name += 2;   /* skip "~/" */
   }
   else if (*name != START_PATH) {   /* relative path */
      /* if path starts with "~/", translate it for user */
      if (strncmp(path, "~/", 2) == 0 && (p = getenv(HOME_DIR)) != NULL) {
         strcpy(filespec, p);
         TERM_PATH(filespec);
         path += 2;   /* skip "~/"; append rest below */
      }
      strcat(filespec, path);
      TERM_PATH(filespec);
   }
   
   return strcat(filespec, name);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movb $0x0, (%rdi)
leaq 0x132f7(%rip), %rsi     # 0x1e518
movl $0x2, %edx
movq %rbx, %rdi
callq 0x5090
testl %eax, %eax
je 0xb28d
cmpb $0x2f, (%rbx)
je 0xb320
leaq 0x132d6(%rip), %rsi     # 0x1e518
movl $0x2, %edx
movq %r15, %rdi
callq 0x5090
testl %eax, %eax
jne 0xb2ed
leaq 0xaea4(%rip), %rdi      # 0x16102
callq 0x5040
testq %rax, %rax
je 0xb2ed
movq %r14, %rdi
movq %rax, %rsi
callq 0x50a0
cmpb $0x0, (%r14)
je 0xb2d7
movq %r14, %rdi
callq 0x5100
addq %r14, %rax
decq %rax
jmp 0xb2d9
leaq 0xae6e(%rip), %rdi      # 0x16102
callq 0x5040
testq %rax, %rax
je 0xb232
movq %r14, %rdi
movq %rax, %rsi
callq 0x50a0
cmpb $0x0, (%r14)
je 0xb2bf
movq %r14, %rdi
callq 0x5100
addq %r14, %rax
decq %rax
jmp 0xb2c1
xorl %eax, %eax
testq %rax, %rax
je 0xb2d1
cmpb $0x2f, (%rax)
je 0xb2d1
movw $0x2f, 0x1(%rax)
addq $0x2, %rbx
jmp 0xb320
xorl %eax, %eax
testq %rax, %rax
je 0xb2e9
cmpb $0x2f, (%rax)
je 0xb2e9
movw $0x2f, 0x1(%rax)
addq $0x2, %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x52e0
cmpb $0x0, (%r14)
je 0xb30e
movq %r14, %rdi
callq 0x5100
addq %r14, %rax
decq %rax
jmp 0xb310
xorl %eax, %eax
testq %rax, %rax
je 0xb320
cmpb $0x2f, (%rax)
je 0xb320
movw $0x2f, 0x1(%rax)
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x52e0
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/pcalutil.c
// Function: find_executable
char *find_executable (char *prog)
{
   char *pathvar, *p, *pnext;
   struct stat st;
   static char filepath[STRSIZ];
   
   /* if 'prog' is an absolute/relative path name or environment variable
      'PATH' does not exist, return 'prog'; otherwise, search the directories
      specified in 'PATH' for the executable
   */
   if (strchr(prog, END_PATH) == 0 && (p = getenv(PATH_ENV_VAR)) != 0) {
      pathvar = alloc(strlen(p) + 1);
      strcpy(pathvar, p);

      /* assumes PATH is of form "dir1:dir2:...:dirN"; strtok() would be handy
         here, but not everybody has it yet
      */
      for (p = pathvar; *p; p = pnext) {
         if ((pnext = strchr(p, ':')) != NULL) *pnext++ = '\0';
         else pnext = p + strlen(p);

         /* assume the executable lives in the path, and construct its
            complete file name
         */
         filepath[0] = '\0';
         if (strcmp(p, ".") != 0) {
            strcat(filepath, p);
            strcat(filepath, "/");
         }
         strcat(filepath, prog);
         
         /* check that file a) exists, b) is a "normal" file, and c) is
            executable - if so, return its full path
          */
         if (stat(filepath, &st) >= 0 &&
             (st.st_mode & S_IFMT) == S_IFREG &&
             access(filepath, X_OK) == 0) {
            free(pathvar);
            return filepath;
         }
      }
      free(pathvar);
   }
   
   return prog;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdi, %rbx
movl $0x2f, %esi
callq 0x5120
testq %rax, %rax
jne 0xb467
leaq 0x131bd(%rip), %rdi     # 0x1e51b
callq 0x5040
testq %rax, %rax
je 0xb467
movq %rax, %r14
movq %rax, %rdi
callq 0x5100
leal 0x1(%rax), %edi
callq 0x9ce0
movq %rax, %rbp
movq %rax, %rdi
movq %r14, %rsi
callq 0x50a0
cmpb $0x0, (%rbp)
je 0xb45f
leaq 0xad1c(%rip), %r12      # 0x160ba
leaq 0x2239b(%rip), %r15     # 0x2d740
leaq 0x8(%rsp), %r13
movq %rbp, (%rsp)
movq %rbp, %r14
movq %r14, %rbp
movq %r14, %rdi
movl $0x3a, %esi
callq 0x5120
testq %rax, %rax
je 0xb3d1
movq %rax, %r14
incq %r14
movb $0x0, (%rax)
jmp 0xb3df
movq %rbp, %rdi
callq 0x5100
movq %rax, %r14
addq %rbp, %r14
movb $0x0, 0x2235a(%rip)     # 0x2d740
movq %rbp, %rdi
movq %r12, %rsi
callq 0x5200
testl %eax, %eax
je 0xb40f
movq %r15, %rdi
movq %rbp, %rsi
callq 0x52e0
movq %r15, %rdi
callq 0x5100
movw $0x2f, (%rax,%r15)
movq %r15, %rdi
movq %rbx, %rsi
callq 0x52e0
movq %r15, %rdi
movq %r13, %rsi
callq 0x5220
testl %eax, %eax
js 0xb44c
movl 0x20(%rsp), %eax
movl $0xf000, %ecx           # imm = 0xF000
andl %ecx, %eax
cmpl $0x8000, %eax           # imm = 0x8000
jne 0xb44c
movq %r15, %rdi
movl $0x1, %esi
callq 0x5280
testl %eax, %eax
je 0xb458
cmpb $0x0, (%r14)
jne 0xb3b1
jmp 0xb45b
movq %r15, %rbx
movq (%rsp), %rbp
movq %rbp, %rdi
callq 0x5050
movq %rbx, %rax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_token
int get_token (char *token)
{
   KWD_F *p;
   
   for (p = pp_info; p->name; p++) {
      if (ci_strncmp(token, p->name, MIN_PPTOK_LEN) == 0) return p - pp_info;
   }
   
   return PP_OTHER;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
leaq 0x1cd1a(%rip), %r15     # 0x28800
movq (%r15), %rsi
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testq %rsi, %rsi
je 0xbb25
movq %rdi, %r14
xorl %r12d, %r12d
movq %r14, %rdi
movl $0x3, %edx
callq 0x9d60
testl %eax, %eax
je 0xbb1a
movq 0x18(%r15,%r12), %rsi
addq $0x18, %r12
testq %rsi, %rsi
jne 0xbaf9
jmp 0xbb25
shrq $0x3, %r12
imull $0xaaaaaaab, %r12d, %ebx # imm = 0xAAAAAAAB
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: do_define_sym_val
int do_define_sym_val (char *sym, char *val)
{
   int i;
   
   i = find_sym_name(sym);
   if (i == PP_SYM_UNDEF) return PP_SYM_UNDEF;
   
   if (pp_val[i]) {
      free(pp_val[i]);
      pp_val[i]=NULL;
   }
   
   if (val) strcpy(pp_val[i] = alloc(strlen(val)+1), val); 
   else pp_val[i]=NULL;
   
   return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
callq 0xc1a1
cmpl $-0x1, %eax
je 0xbba9
movslq %eax, %r14
leaq 0x21fe3(%rip), %r15     # 0x2db50
movq (%r15,%r14,8), %rdi
testq %rdi, %rdi
je 0xbb83
callq 0x5050
movq $0x0, (%r15,%r14,8)
testq %rbx, %rbx
je 0xbbb0
movq %rbx, %rdi
callq 0x5100
leal 0x1(%rax), %edi
callq 0x9ce0
movq %rax, (%r15,%r14,8)
movq %rax, %rdi
movq %rbx, %rsi
callq 0x50a0
jmp 0xbbb8
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xbbba
movq $0x0, (%r15,%r14,8)
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: clear_syms
void clear_syms (void)
{
   int i;
   
   for (i = 0; i < MAX_PP_SYMS; i++) {
      if (pp_sym[i]) {
         free(pp_sym[i]);
         pp_sym[i] = NULL;
      }
      if (pp_val[i]) {
         free(pp_val[i]);
         pp_val[i] = NULL;
      }
   }
   return;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
xorl %ebx, %ebx
leaq 0x2176e(%rip), %r14     # 0x2d830
leaq 0x21a87(%rip), %r15     # 0x2db50
movq (%rbx,%r14), %rdi
testq %rdi, %rdi
je 0xc0df
callq 0x5050
movq $0x0, (%rbx,%r14)
movq (%rbx,%r15), %rdi
testq %rdi, %rdi
je 0xc0f5
callq 0x5050
movq $0x0, (%rbx,%r15)
addq $0x8, %rbx
cmpq $0x320, %rbx            # imm = 0x320
jne 0xc0c9
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: cleanup
void cleanup (void)
{
   int i, j;
   year_info *py, *pny;
   month_info *pm;
   day_info *pd, *pnd;
   
   for (py = head; py; py = pny) {   /* main data structure */
      pny = py->next;
      for (i = 0; i < 12; i++) {
         if ((pm = py->month[i]) == NULL) continue;
         for (j = 0; j < LAST_NOTE_DAY; j++) {
            for (pd = pm->day[j]; pd; pd = pnd) {
               pnd = pd->next;
               free(pd->text);
               free(pd);
            }
         }
         free(pm);
      }
      free(py);
   }
   
   clear_syms();   /* symbol table */

   return;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
leaq 0x20186(%rip), %rax     # 0x2c2a0
movq (%rax), %rbx
testq %rbx, %rbx
je 0xc18e
movq 0x68(%rbx), %rax
movq %rax, (%rsp)
xorl %r13d, %r13d
movq 0x8(%rbx,%r13,8), %r14
testq %r14, %r14
je 0xc171
xorl %ebp, %ebp
movq 0x8(%r14,%rbp,8), %r15
testq %r15, %r15
je 0xc160
movq 0x8(%r15), %rdi
movq 0x10(%r15), %r12
callq 0x5050
movq %r15, %rdi
callq 0x5050
movq %r12, %r15
testq %r12, %r12
jne 0xc143
incq %rbp
cmpq $0x2d, %rbp
jne 0xc139
movq %r14, %rdi
callq 0x5050
incq %r13
cmpq $0xc, %r13
jne 0xc12d
movq %rbx, %rdi
callq 0x5050
movq (%rsp), %rax
movq %rax, %rbx
testq %rax, %rax
jne 0xc122
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0xc0b4
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: do_define
int do_define (char *sym)
{
   int i;
   
   if (!sym) {   /* null argument - clear all definitions */
      clear_syms();
      return 0;
   }
   
   if (DEBUG(DEBUG_PP)) fprintf(stderr, "defining %s\n", sym);
   
   if (do_ifdef(sym)) return 0;   /* already defined? */
      
   for (i = 0; i < MAX_PP_SYMS; i++) {   /* find room for it */
      if (!pp_sym[i]) {
         strcpy(pp_sym[i] = alloc(strlen(sym)+1), sym);
         return 0;
      }
   }
   
   fprintf(stderr, E_SYMFULL, progname, sym);

   return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
testq %rdi, %rdi
je 0xc276
movq %rdi, %rbx
leaq 0x204b9(%rip), %rax     # 0x2c6dc
testb $0x20, (%rax)
jne 0xc2a4
movq %rbx, %rdi
callq 0x9275
testl %eax, %eax
jne 0xc29c
xorl %r14d, %r14d
leaq 0x215f2(%rip), %r15     # 0x2d830
cmpq $0x0, (%r14,%r15)
je 0xc27d
addq $0x8, %r14
cmpq $0x320, %r14            # imm = 0x320
jne 0xc23e
movq 0x1bd97(%rip), %rax     # 0x27ff0
movq (%rax), %rdi
leaq 0x12b9c(%rip), %rsi     # 0x1edff
leaq 0x205c6(%rip), %rdx     # 0x2c830
movq %rbx, %rcx
xorl %eax, %eax
callq 0x5210
jmp 0xc29c
callq 0xc0b4
jmp 0xc29c
movq %rbx, %rdi
callq 0x5100
leal 0x1(%rax), %edi
callq 0x9ce0
movq %rax, (%r14,%r15)
movq %rax, %rdi
movq %rbx, %rsi
callq 0x50a0
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
movq 0x1bd45(%rip), %rax     # 0x27ff0
movq (%rax), %rdi
leaq 0x12b75(%rip), %rsi     # 0x1ee2a
movq %rbx, %rdx
xorl %eax, %eax
callq 0x5210
jmp 0xc228
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: do_undef
int do_undef (char *sym)
{
   int i;
   
   if (!sym) return 0;

   if (DEBUG(DEBUG_PP)) fprintf(stderr, "undefining %s\n", sym);

   if ((i = find_sym_name(sym)) != PP_SYM_UNDEF) {
      if (pp_val[i]) {
         free(pp_val[i]);
         pp_val[i] = NULL;
      }
      free(pp_sym[i]);
      pp_sym[i] = NULL;
   }
   
   return 0;
}

// Assembly:
testq %rdi, %rdi
je 0xc328
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x20405(%rip), %rax     # 0x2c6dc
testb $0x20, (%rax)
jne 0xc32b
movq %rbx, %rdi
callq 0xc1a1
cmpl $-0x1, %eax
je 0xc321
movslq %eax, %rbx
leaq 0x2185d(%rip), %r14     # 0x2db50
movq (%r14,%rbx,8), %rdi
testq %rdi, %rdi
je 0xc309
callq 0x5050
movq $0x0, (%r14,%rbx,8)
leaq 0x21520(%rip), %r14     # 0x2d830
movq (%r14,%rbx,8), %rdi
callq 0x5050
movq $0x0, (%r14,%rbx,8)
addq $0x8, %rsp
popq %rbx
popq %r14
xorl %eax, %eax
retq
movq 0x1bcbe(%rip), %rax     # 0x27ff0
movq (%rax), %rdi
leaq 0x12aec(%rip), %rsi     # 0x1ee28
movq %rbx, %rdx
xorl %eax, %eax
callq 0x5210
jmp 0xc2dc
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: find_year
year_info *find_year (int year, int insert)
{
   year_info *pyear, *plast, *p;
   
   for (plast = NULL, pyear = head;   /* search linked list */
        pyear && pyear->year < year;
        plast = pyear, pyear = pyear->next)
      ;
   
   if (pyear && pyear->year == year) return pyear;   /* found - return it */

   if (insert) {   /* not found - insert it if requested */
      int i;
      p = (year_info *) alloc((int) sizeof(year_info));   /* create new record */
      p->year = year;
      for (i = 0; i < (int)(ARRAYSIZE(p->month)); i++) p->month[i] = NULL;
      p->next = pyear;   /* link it in */
      return *(plast ? &plast->next : &head) = p;
   }
   else return NULL;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebp
leaq 0x1fe99(%rip), %r14     # 0x2c2a0
movq (%r14), %rbx
testq %rbx, %rbx
je 0xc429
movl (%rbx), %eax
cmpl %ebp, %eax
jge 0xc42e
movq %rbx, %r15
movq 0x68(%rbx), %rbx
testq %rbx, %rbx
je 0xc435
movl (%rbx), %eax
cmpl %ebp, %eax
jl 0xc415
jmp 0xc431
xorl %r15d, %r15d
jmp 0xc435
xorl %r15d, %r15d
cmpl %ebp, %eax
je 0xc47a
testl %esi, %esi
je 0xc478
movl $0x70, %edi
callq 0x9ce0
movl %ebp, (%rax)
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rax)
movups %xmm0, 0x18(%rax)
movups %xmm0, 0x28(%rax)
movups %xmm0, 0x38(%rax)
movups %xmm0, 0x48(%rax)
movups %xmm0, 0x58(%rax)
movq %rbx, 0x68(%rax)
testq %r15, %r15
je 0xc470
addq $0x68, %r15
movq %r15, %r14
movq %rax, (%r14)
movq %rax, %rbx
jmp 0xc47a
xorl %ebx, %ebx
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: odox_easter_from_april1
int odox_easter_from_april1 (int year)
{
   int a, b, leap;
   
   a = ( ( ((year-1) % METONIC) + 1 ) * METONIC + 15 ) % 30;
   leap = IS_LEAP(year) ? 1 : 0;
   b = (calc_weekday(1,1,year) + 90 + leap + a + 2) % 7;
   b = 7 - b + 3 + a;

   /* In 1923, 13 days  were added to the new greek calendar */
   if (year <= 1923) b -= 13;

   return (b);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movl %edi, %ebx
xorl %eax, %eax
testb $0x3, %bl
jne 0xc754
imull $0xc28f5c29, %ebx, %ecx # imm = 0xC28F5C29
addl $0x51eb850, %ecx        # imm = 0x51EB850
movl %ecx, %edx
rorl $0x2, %edx
movl $0x1, %eax
cmpl $0x28f5c28, %edx        # imm = 0x28F5C28
ja 0xc754
rorl $0x4, %ecx
xorl %eax, %eax
cmpl $0xa3d70b, %ecx         # imm = 0xA3D70B
setb %al
leal -0x1(%rbx), %ecx
movslq %ecx, %rcx
imulq $0x6bca1af3, %rcx, %rcx # imm = 0x6BCA1AF3
movq %rcx, %rdx
shrq $0x3f, %rdx
shrq $0x20, %rcx
sarl $0x3, %ecx
addl %edx, %ecx
leal (%rcx,%rcx,8), %edx
leal (%rcx,%rdx,2), %ecx
negl %ecx
addl %ebx, %ecx
decl %ecx
leal (%rcx,%rcx,8), %edx
leal (%rcx,%rdx,2), %r14d
leal (%rcx,%rdx,2), %ecx
addl $0x22, %ecx
movslq %ecx, %rcx
imulq $-0x77777777, %rcx, %rcx # imm = 0x88888889
shrq $0x20, %rcx
leal (%rcx,%r14), %r15d
addl $0x22, %r15d
movl %r15d, %ecx
shrl $0x1f, %ecx
sarl $0x4, %r15d
addl %ecx, %r15d
movl %r15d, %ecx
shll $0x5, %ecx
addl %r15d, %r15d
subl %ecx, %r15d
leal (%r15,%r14), %r12d
addl $0x22, %r12d
addl %eax, %r12d
movl $0x1, %edi
movl $0x1, %esi
movl %ebx, %edx
callq 0xa53f
movl %r12d, %ecx
addl %eax, %ecx
addl %r12d, %eax
addl $0x5c, %eax
movslq %eax, %rdx
imulq $-0x6db6db6d, %rdx, %rax # imm = 0x92492493
shrq $0x20, %rax
addl %eax, %ecx
addl $0x5c, %ecx
movl %ecx, %eax
shrl $0x1f, %eax
sarl $0x2, %ecx
addl %eax, %ecx
leal (,%rcx,8), %eax
subl %ecx, %eax
cmpl $0x784, %ebx            # imm = 0x784
leal 0x1f(%r15,%r14), %ecx
leal 0x2c(%r15,%r14), %esi
cmovll %ecx, %esi
subl %edx, %eax
addl %esi, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: find_odox_easter
int find_odox_easter (date_str *pdate)   /* pointer into date array */
{
   date_str *sv_pdate = pdate;
   int offs;
   
   /* easter is days from 1st April for easter sun */
   offs = odox_easter_from_april1(curr_year);
   odox_add(offs);
   
   /* return number of dates added (always 1 in this routine) */
   return pdate - sv_pdate;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x20da6(%rip), %r15     # 0x2d5e0
movl (%r15), %edi
callq 0xc717
movl %eax, %r14d
testl %eax, %eax
jle 0xc863
leal -0x1e(%r14), %eax
xorl %ebp, %ebp
cmpl $0x1f, %r14d
setge %bpl
cmovll %r14d, %eax
orl $0x4, %ebp
movl %eax, %r14d
jmp 0xc86c
addl $0x1f, %r14d
movl $0x3, %ebp
leaq 0x1fe69(%rip), %rax     # 0x2c6dc
testb $0x2, (%rax)
jne 0xc894
movl %ebp, (%rbx)
movl %r14d, 0x4(%rbx)
movl (%r15), %eax
movl %eax, 0x8(%rbx)
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq 0x1b755(%rip), %rax     # 0x27ff0
movq (%rax), %rdi
movl (%r15), %edx
leaq 0x1258f(%rip), %rsi     # 0x1ee37
movl %ebp, %ecx
movl %r14d, %r8d
xorl %eax, %eax
callq 0x5210
jmp 0xc878
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: find_odox_stgeorge
int find_odox_stgeorge (date_str *pdate)   /* pointer into date array */
{
   date_str *sv_pdate = pdate;
   int offs;
   
   /* offs is days from 1st April for easter sun */
   offs = odox_easter_from_april1(curr_year);
   if (offs >= 23) {   /* it's before easter; will move to easter Mon */
      offs++;
      odox_add(offs);
   } 
   else ADD_DATE(APR, 23, curr_year);

   /* return number of dates added */
   return pdate - sv_pdate;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x20d19(%rip), %r15     # 0x2d5e0
movl (%r15), %edi
callq 0xc717
cmpl $0x17, %eax
jl 0xc91a
leal 0x1(%rax), %ecx
leal -0x1d(%rax), %ebp
xorl %r14d, %r14d
cmpl $0x1e, %eax
setge %r14b
cmovll %ecx, %ebp
orl $0x4, %r14d
leaq 0x1fdea(%rip), %rax     # 0x2c6dc
testb $0x2, (%rax)
je 0xc931
movq 0x1b6f2(%rip), %rax     # 0x27ff0
movq (%rax), %rdi
movl (%r15), %edx
leaq 0x1252c(%rip), %rsi     # 0x1ee37
movl %r14d, %ecx
movl %ebp, %r8d
xorl %eax, %eax
callq 0x5210
jmp 0xc931
leaq 0x1fdbb(%rip), %rax     # 0x2c6dc
movl $0x17, %ebp
movl $0x4, %r14d
testb $0x2, (%rax)
jne 0xc94d
movl %r14d, (%rbx)
movl %ebp, 0x4(%rbx)
movl (%r15), %eax
movl %eax, 0x8(%rbx)
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
callq 0x551f
jmp 0xc931
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: find_odox_marcus
int find_odox_marcus (date_str *pdate)   /* pointer into date array */
{
   date_str *sv_pdate = pdate;
   int offs;
   
   /* offs is days from 1st April for easter sun */
   offs = odox_easter_from_april1(curr_year);
   if (offs >= 25) {   /* it's before easter; will move to easter Tue */
      offs += 2;
      odox_add(offs);
   } 
   else ADD_DATE(APR, 25, curr_year);

   /* return number of dates added */
   return pdate - sv_pdate;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x20c7b(%rip), %r15     # 0x2d5e0
movl (%r15), %edi
callq 0xc717
cmpl $0x19, %eax
jl 0xc9b8
leal 0x2(%rax), %ecx
leal -0x1c(%rax), %ebp
xorl %r14d, %r14d
cmpl $0x1d, %eax
setge %r14b
cmovll %ecx, %ebp
orl $0x4, %r14d
leaq 0x1fd4c(%rip), %rax     # 0x2c6dc
testb $0x2, (%rax)
je 0xc9cf
movq 0x1b654(%rip), %rax     # 0x27ff0
movq (%rax), %rdi
movl (%r15), %edx
leaq 0x1248e(%rip), %rsi     # 0x1ee37
movl %r14d, %ecx
movl %ebp, %r8d
xorl %eax, %eax
callq 0x5210
jmp 0xc9cf
leaq 0x1fd1d(%rip), %rax     # 0x2c6dc
movl $0x19, %ebp
movl $0x4, %r14d
testb $0x2, (%rax)
jne 0xc9eb
movl %r14d, (%rbx)
movl %ebp, 0x4(%rbx)
movl (%r15), %eax
movl %eax, 0x8(%rbx)
movl $0x1, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
callq 0x5547
jmp 0xc9cf
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_month
int get_month (char *cp, int numeric_ok, int year_ok)
{
   int mm;
   
   if (!cp) return NOT_MONTH;

   if (get_keywd(cp) == DT_ALL) return ALL_MONTHS;

   if (year_ok && get_keywd(cp) == DT_YEAR) return ENTIRE_YEAR;
   
   if (numeric_ok && isdigit((int)*cp)) mm = atoi(cp);
   else {
      /* accept month names in the active 'input' language only */
      for (mm = JAN; mm <= DEC; mm++) {
         /* Need to shorten length of string compare by 1 character when the
            last character is '*' so that event like '2nd Sunday in May*'
            don't report 'no match for wildcard'.
         */
         if ((ci_strncmp(cp, months_ml[input_language][mm-1], 
                         strlen(cp) - ((*(cp + strlen(cp) - 1) == '*') ? 1 : 0)) == 0))
            break;
      }
   }
   
   return mm >= JAN && mm <= DEC ? mm : NOT_MONTH;
}

// Assembly:
testq %rdi, %rdi
je 0xcaa9
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %r14d
movl %esi, %ebp
movq %rdi, %rbx
callq 0xcae2
testl %eax, %eax
je 0xcaaf
testl %r14d, %r14d
je 0xca38
movq %rbx, %rdi
callq 0xcae2
movl %eax, %ecx
movl $0xd, %eax
cmpl $0x4, %ecx
je 0xcad3
testl %ebp, %ebp
je 0xca4f
callq 0x5340
movq (%rax), %rax
movsbq (%rbx), %rcx
testb $0x8, 0x1(%rax,%rcx,2)
jne 0xcab8
xorl %r14d, %r14d
leaq 0x20db7(%rip), %r12     # 0x2d810
leaq 0x1d1e0(%rip), %r13     # 0x29c40
movslq (%r12), %rax
leaq (%rax,%rax,2), %rax
shlq $0x5, %rax
addq %r13, %rax
movq (%rax,%r14,8), %r15
movq %rbx, %rdi
callq 0x5100
xorl %ecx, %ecx
cmpb $0x2a, -0x1(%rbx,%rax)
sete %cl
subl %ecx, %eax
movq %rbx, %rdi
movq %r15, %rsi
movl %eax, %edx
callq 0x9d60
testl %eax, %eax
je 0xcab3
incq %r14
cmpq $0xc, %r14
jne 0xca60
movl $0xd, %r14d
jmp 0xcac3
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
xorl %eax, %eax
jmp 0xcad3
incl %r14d
jmp 0xcac3
movq %rbx, %rdi
callq 0x52d0
movl %eax, %r14d
leal -0x1(%r14), %eax
cmpl $0xc, %eax
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmovbl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_keywd
int get_keywd (char *cp)
{
   KWD *k;
   
   if (!cp) return DT_OTHER;
   
   for (k = keywds; k->name && ci_strncmp(cp, k->name, strlen(k->name)); k++)
      ;
   
   return k->code;
}

// Assembly:
testq %rdi, %rdi
je 0xcb35
pushq %r15
pushq %r14
pushq %rbx
leaq 0x1c04d(%rip), %r15     # 0x28b40
movq (%r15), %r14
testq %r14, %r14
je 0xcb2b
movq %rdi, %rbx
leaq 0x1c03b(%rip), %r15     # 0x28b40
movq %r14, %rdi
callq 0x5100
movq %rbx, %rdi
movq %r14, %rsi
movl %eax, %edx
callq 0x9d60
testl %eax, %eax
je 0xcb2b
movq 0x10(%r15), %r14
addq $0x10, %r15
testq %r14, %r14
jne 0xcb05
movl 0x8(%r15), %eax
popq %rbx
popq %r14
popq %r15
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_weekday
int get_weekday (char *cp, int wild_ok)
{
   int w;
   
   if (!cp) return NOT_WEEKDAY;

   if (wild_ok) {   /* try wildcards first */
      for (w = WILD_FIRST_WKD; w <= WILD_LAST_WKD; w++) {
         if (ci_strncmp(cp, days[w], strlen(days[w])) == 0) return w;
      }
      if ((w = get_phase(cp)) != MOON_OTHER) return w + WILD_FIRST_MOON;
   }
   
   /* accept day names in the active 'input' language only */
   for (w = SUN; w <= SAT; w++) {
      int compare_count;
      /* To allow for proper detection of the day-of-week name in constructs
         from the configuration file like 'all Fridays in Oct' (i.e. with the
         plural form of the day-of-week name), we need to compare the fewest
         number of characters of the 2 strings.
      */
      compare_count = 
         (strlen(cp) < strlen(days_ml[input_language][w])) ? 
         strlen(cp) : strlen(days_ml[input_language][w]);
      
      if (ci_strncmp(cp, days_ml[input_language][w], compare_count) == 0) return w;
   }
   
   return NOT_WEEKDAY;
}

// Assembly:
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
testq %rdi, %rdi
je 0xcc1d
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
testl %esi, %esi
je 0xcba3
movl $0x7, %ebx
leaq 0x1bc29(%rip), %r12     # 0x28790
movq (%r12,%rbx,8), %r15
movq %r15, %rdi
callq 0x5100
movq %r14, %rdi
movq %r15, %rsi
movl %eax, %edx
callq 0x9d60
testl %eax, %eax
je 0xcc09
incq %rbx
cmpq $0xe, %rbx
jne 0xcb67
movq %r14, %rdi
callq 0xcc1e
cmpl $-0x1, %eax
je 0xcba3
addl $0xe, %eax
jmp 0xcc0f
leaq 0x1d996(%rip), %r13     # 0x2a540
xorl %ebp, %ebp
movq %r14, %rdi
callq 0x5100
movq %rax, %r15
leaq 0x20c52(%rip), %rax     # 0x2d810
movslq (%rax), %rax
imulq $0x8c, %rax, %r12
addq %r13, %r12
movq %r12, %rdi
callq 0x5100
cmpq %rax, %r15
jb 0xcbdb
movq %rax, %r15
movq %r14, %rdi
movq %r12, %rsi
movl %r15d, %edx
callq 0x9d60
movl %ebp, %ecx
testl %eax, %eax
je 0xcbf1
movl %ebx, %ecx
je 0xcc0d
incq %rbp
addq $0x14, %r13
movl %ecx, %ebx
cmpq $0x7, %rbp
jne 0xcbac
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xcc0f
movl %ebx, %eax
jmp 0xcc0f
movl %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_phase
int get_phase (char *cp)
{
   KWD *p;
   
   if (!cp) return MOON_OTHER;
   
   for (p = phases; p->name && ci_strcmp(cp, p->name); p++)
      ;
   
   return p->code;
}

// Assembly:
testq %rdi, %rdi
je 0xcc65
pushq %r14
pushq %rbx
pushq %rax
leaq 0x1bfa2(%rip), %r14     # 0x28bd0
movq (%r14), %rsi
testq %rsi, %rsi
je 0xcc59
movq %rdi, %rbx
leaq 0x1bf90(%rip), %r14     # 0x28bd0
movq %rbx, %rdi
callq 0x9d00
testl %eax, %eax
je 0xcc59
movq 0x10(%r14), %rsi
addq $0x10, %r14
testq %rsi, %rsi
jne 0xcc40
movl 0x8(%r14), %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_ordinal
int get_ordinal (char *cp, int *pval)
{
   KWD_O *o;
   int val;
   char **psuf;
   
   if (!cp) return ORD_OTHER;

   if (isdigit((int)*cp) || *cp == '-') {   /* numeric? */
      if ((val = atoi(cp)) == 0) return ORD_OTHER;
      
      if (*cp == '-') cp++;   /* skip over number */
         
      cp += strspn(cp, DIGITS);
      
      for (psuf = ord_suffix; *psuf; psuf++) {   /* find suffix */
         if (ci_strcmp(cp, *psuf) == 0) {
            *pval = val;
            return val < 0 ? ORD_NEGNUM : ORD_POSNUM;
         }
      }
      return ORD_OTHER;
   }
   
   /* look for word in ordinals list */

   for (o = ordinals; o->name && ci_strncmp(cp, o->name, MIN_ORD_LEN); o++)
      ;
   
   *pval = o->value;
   return o->code;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
xorl %ebp, %ebp
testq %rdi, %rdi
je 0xcd4c
movq %rsi, %rbx
movq %rdi, %r14
callq 0x5340
movsbq (%r14), %r12
cmpq $0x2d, %r12
je 0xcce2
movq (%rax), %rax
movzwl (%rax,%r12,2), %eax
andl $0x800, %eax            # imm = 0x800
jne 0xcce2
leaq 0x1bc47(%rip), %r15     # 0x288f0
movq (%r15), %rsi
testq %rsi, %rsi
je 0xccd6
leaq 0x1bc38(%rip), %r15     # 0x288f0
movq %r14, %rdi
movl $0x4, %edx
callq 0x9d60
testl %eax, %eax
je 0xccd6
movq 0x10(%r15), %rsi
addq $0x10, %r15
testq %rsi, %rsi
jne 0xccb8
movl 0xc(%r15), %eax
movl %eax, (%rbx)
movl 0x8(%r15), %ebp
jmp 0xcd4c
movq %r14, %rdi
callq 0x52d0
testl %eax, %eax
je 0xcd4c
movl %eax, %r15d
xorl %eax, %eax
cmpb $0x2d, %r12b
sete %al
addq %rax, %r14
leaq 0x91a4(%rip), %rsi      # 0x15ea8
movq %r14, %rdi
callq 0x51a0
leaq 0x1bd2d(%rip), %r12     # 0x28a40
movq (%r12), %rsi
testq %rsi, %rsi
je 0xcd4c
addq %rax, %r14
addq $0x8, %r12
movq %r14, %rdi
callq 0x9d00
testl %eax, %eax
je 0xcd3e
movq (%r12), %rsi
addq $0x8, %r12
testq %rsi, %rsi
jne 0xcd23
jmp 0xcd4c
movl %r15d, (%rbx)
sarl $0x1f, %r15d
orl $0x1, %r15d
movl %r15d, %ebp
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_prep
int get_prep (char *cp)
{
   KWD *p;
   
   if (!cp) return PR_OTHER;

   for (p = preps; p->name && ci_strncmp(cp, p->name, MIN_PREP_LEN); p++)
      ;
   
   return p->code;
}

// Assembly:
testq %rdi, %rdi
je 0xcda3
pushq %r14
pushq %rbx
pushq %rax
leaq 0x1bd09(%rip), %r14     # 0x28a70
movq (%r14), %rsi
testq %rsi, %rsi
je 0xcd97
movq %rdi, %rbx
leaq 0x1bcf7(%rip), %r14     # 0x28a70
movq %rbx, %rdi
movl $0x9, %edx
callq 0x9d60
testl %eax, %eax
je 0xcd97
movq 0x10(%r14), %rsi
addq $0x10, %r14
testq %rsi, %rsi
jne 0xcd79
movl 0x8(%r14), %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: get_predef_event
int get_predef_event (char *cp)
{
   KWD_H *p;
   
   for (p = predef_events; p->name; p++) {
      if (ci_strncmp(cp, p->name, strlen(p->name)) == 0) return p - predef_events;
   }
   
   return NOT_PREDEF_EVENT;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
leaq 0x1bbc7(%rip), %r12     # 0x28980
movq (%r12), %r15
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
testq %r15, %r15
je 0xce01
movq %rdi, %r14
xorl %r13d, %r13d
movq %r15, %rdi
callq 0x5100
movq %r14, %rdi
movq %r15, %rsi
movl %eax, %edx
callq 0x9d60
testl %eax, %eax
je 0xcdf6
movq 0x18(%r12,%r13), %r15
addq $0x18, %r13
testq %r15, %r15
jne 0xcdcd
jmp 0xce01
shrq $0x3, %r13
imull $0xaaaaaaab, %r13d, %ebx # imm = 0xAAAAAAAB
movl %ebx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: date_type
int date_type (char *cp, int *pn, int *pv)
{
   int n, v;
   
   /* look for weekdays first, to catch wildcards "1q", "3q", etc. */
   if ((n = get_weekday(cp, TRUE)) != NOT_WEEKDAY) {   /* weekday name? */
      return (*pn = n, DT_WEEKDAY);
   }
   
   if ((n = get_predef_event(cp)) != NOT_PREDEF_EVENT) {   /* pre-defined event? */
      return (*pn = n, DT_PREDEF_EVENT);
   }
   
   if ((n = get_ordinal(cp, &v)) != ORD_OTHER) {   /* ordinal? */
      return (*pn = n, *pv = v, DT_ORDINAL);
   }
   
   if (isdigit((int)*cp)) {   /* other digit? */
      return (IS_NUMERIC(cp) ||
              (date_style == EUR_DATES && IS_EURDATE(cp))) ?
         DT_EURDATE : DT_DATE;
   }
   
   /* "all" can be either a keyword or a month wildcard - look for the former
      usage first */
   
   if ((n = get_keywd(cp)) != DT_OTHER) return n;
   
   if ((n = get_month(cp, FALSE, FALSE)) != NOT_MONTH) {   /* month name? */
      return (*pn = n, DT_MONTH);
   }
   
   return DT_OTHER;   /* unrecognized keyword - give up */
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movl $0x1, %esi
callq 0xcb3b
cmpl $-0x1, %eax
je 0xce38
movl %eax, (%r14)
movl $0x9, %eax
jmp 0xce6f
movq %rbx, %rdi
callq 0xcda9
cmpl $-0x1, %eax
je 0xce4f
movl %eax, (%r14)
movl $0xa, %eax
jmp 0xce6f
leaq 0xc(%rsp), %rsi
movq %rbx, %rdi
callq 0xcc6b
testl %eax, %eax
je 0xce79
movl %eax, (%r14)
movl 0xc(%rsp), %eax
movl %eax, (%r15)
movl $0x8, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
callq 0x5340
movq (%rax), %r15
movsbq (%rbx), %rax
testb $0x8, 0x1(%r15,%rax,2)
jne 0xceb5
movq %rbx, %rdi
callq 0xcae2
cmpl $-0x1, %eax
jne 0xce6f
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0xc9f2
cmpl $-0x1, %eax
je 0xcf02
movl %eax, (%r14)
movl $0x5, %eax
jmp 0xce6f
leaq 0x8fec(%rip), %rsi      # 0x15ea8
movq %rbx, %rdi
callq 0x51a0
movsbq (%rbx,%rax), %rdx
testq %rdx, %rdx
je 0xcef8
movq %rax, %rcx
leaq 0x1f714(%rip), %rsi     # 0x2c5ec
movl $0x6, %eax
cmpl $0x1, (%rsi)
jne 0xce6f
testb $0x4, (%r15,%rdx,2)
je 0xce6f
xorl %eax, %eax
cmpb $0x1, 0x1(%rbx,%rcx)
adcl $0x6, %eax
jmp 0xce6f
movl $0x7, %eax
jmp 0xce6f
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0xce6f
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: enter_note
int enter_note (int mm, char **pword, int n)
{
   int valid;
   
   /* expand "note all" into all twelve months */
   if (mm == ALL_MONTHS || mm == ENTIRE_YEAR) {
      valid = FALSE;   /* is at least one note box valid? */
      for (mm = JAN; mm <= DEC; mm++) {
         valid |= enter_day_info(mm,
                                 note_day(mm, n, curr_year),
                                 curr_year, NOTE_TEXT,
                                 pword+1) == PARSE_OK;
      }
      return valid ? PARSE_OK : PARSE_NOMATCH;
   }
   
   return enter_day_info(mm, note_day(mm, n, curr_year), curr_year, NOTE_TEXT, pword+1);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %ebp
movq %rsi, %rbx
cmpl $0xd, %edi
je 0xd3c7
movl %edi, %r14d
testl %edi, %edi
jne 0xd422
addq $0x8, %rbx
movl $0x1, %r14d
xorl %r15d, %r15d
leaq 0x20205(%rip), %r12     # 0x2d5e0
movl (%r12), %edx
movl %r14d, %edi
movl %ebp, %esi
callq 0xa7ad
movl (%r12), %edx
movl %r14d, %edi
movl %eax, %esi
movl $0x2, %ecx
movq %rbx, %r8
callq 0xcf0c
xorl $0x1, %eax
orl %eax, %r15d
incl %r14d
cmpl $0xd, %r14d
jne 0xd3db
xorl %eax, %eax
testl %r15d, %r15d
sete %al
leal (%rax,%rax,2), %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x201b7(%rip), %r15     # 0x2d5e0
movl (%r15), %edx
movl %r14d, %edi
movl %ebp, %esi
callq 0xa7ad
movl (%r15), %edx
addq $0x8, %rbx
movl %r14d, %edi
movl %eax, %esi
movl $0x2, %ecx
movq %rbx, %r8
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0xcf0c
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/readfile.c
// Function: process_event_specification
int process_event_specification (char **pword, int *ptext_type, char ***pptext)
{
   int rtn, match;
   date_str *pd;
   
   /* parse date spec and enter information for each match */
   if ((rtn = parse_date(pword, ptext_type, pptext)) == PARSE_OK) {
      match = FALSE;
      for (pd = candidate_dates; pd->mm; pd++) {

         if (pd->yy == -1) {
            if (DEBUG(DEBUG_DATES)) {
               fprintf(stderr, "Bypassing invalidated candidate date: yyyy-%02d-%02d.\n", pd->mm, pd->dd);
            }
         }
         else {
            if (DEBUG(DEBUG_DATES)) {
               fprintf(stderr, "Processing candidate date: %4d-%02d-%02d\n", pd->yy, pd->mm, pd->dd);
            }
            
            if (delete_entry) {
               match |= delete_day_info(pd->mm, pd->dd, pd->yy, *ptext_type, *pptext) == PARSE_OK;
            }
            else {
               match |= enter_day_info(pd->mm, pd->dd, pd->yy, *ptext_type, *pptext) == PARSE_OK;
            }
         }
      }
      rtn = match ? PARSE_OK : PARSE_NOMATCH;
   }
   return rtn;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
callq 0xd53d
testl %eax, %eax
jne 0xd52e
movl 0x20a05(%rip), %ecx     # 0x2de80
testl %ecx, %ecx
je 0xd529
leaq 0x20a02(%rip), %r13     # 0x2de8c
leaq 0x1f24b(%rip), %rbp     # 0x2c6dc
movq 0x1ab58(%rip), %r15     # 0x27ff0
xorl %r12d, %r12d
movl -0x4(%r13), %edx
movl (%rbp), %eax
cmpl $-0x1, %edx
je 0xd4cd
testb $0x2, %al
jne 0xd505
movl -0xc(%r13), %edi
movl -0x8(%r13), %esi
movl -0x4(%r13), %edx
movl (%r14), %ecx
movq (%rbx), %r8
cmpb $0x1, 0x21af0(%rip)     # 0x2efb4
jne 0xd4ec
callq 0xd1d9
jmp 0xd4f1
testb $0x2, %al
je 0xd4f7
movq (%r15), %rdi
movl -0x8(%r13), %eax
leaq 0x119c4(%rip), %rsi     # 0x1eea3
movl %ecx, %edx
movl %eax, %ecx
xorl %eax, %eax
callq 0x5210
jmp 0xd4f7
callq 0xcf0c
xorl $0x1, %eax
orl %eax, %r12d
movl (%r13), %ecx
addq $0xc, %r13
testl %ecx, %ecx
jne 0xd49b
jmp 0xd51c
movq (%r15), %rdi
movl -0x8(%r13), %r8d
leaq 0x119c7(%rip), %rsi     # 0x1eeda
xorl %eax, %eax
callq 0x5210
jmp 0xd4ab
xorl %eax, %eax
testl %r12d, %r12d
sete %al
leal (%rax,%rax,2), %eax
jmp 0xd52e
movl $0x3, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/writefil.c
// Function: ps_prtday_bw
void ps_prtday_bw (void)
{
   printf("%% print 'day' in 'color' (black, gray, outline, or outline-gray; cf. pcaldefs.h)\n");
   printf("%% using single value in 'dategray' as gray shade\n");
   printf("%%\n");
   printf("/prtday {					%% black and white version\n");
   printf("	gsave\n");
   printf("	day 3 string cvs			%% convert day to string\n");
   printf("	[\n");
   printf("		{ show }				%% black (0)\n");
   printf("		{ dategray setgray show }		%% gray (1)\n");
   printf("		{ true charpath stroke }		%% outline (2)\n");
   printf("		{ true charpath gsave			%% outline-gray (3)\n");
   printf("		  dategray setgray fill\n");
   printf("		  grestore stroke }\n");
   printf("	] color get exec			%% execute operators for color\n");
   printf("	grestore\n");
   printf("} bind def\n\n");
   return;
}

// Assembly:
pushq %rax
leaq 0x10edc(%rip), %rdi     # 0x1efec
xorl %eax, %eax
callq 0x5130
leaq 0x10f21(%rip), %rdi     # 0x1f03f
xorl %eax, %eax
callq 0x5130
leaq 0x1384a(%rip), %rdi     # 0x21976
xorl %eax, %eax
callq 0x5130
leaq 0x10f38(%rip), %rdi     # 0x1f072
xorl %eax, %eax
callq 0x5130
leaq 0x155a3(%rip), %rdi     # 0x236eb
callq 0x50b0
leaq 0x10f48(%rip), %rdi     # 0x1f09c
xorl %eax, %eax
callq 0x5130
leaq 0x15c11(%rip), %rdi     # 0x23d73
callq 0x50b0
leaq 0x10f5c(%rip), %rdi     # 0x1f0ca
xorl %eax, %eax
callq 0x5130
leaq 0x10f6a(%rip), %rdi     # 0x1f0e6
xorl %eax, %eax
callq 0x5130
leaq 0x10f86(%rip), %rdi     # 0x1f110
xorl %eax, %eax
callq 0x5130
leaq 0x10fa4(%rip), %rdi     # 0x1f13c
xorl %eax, %eax
callq 0x5130
leaq 0x145f1(%rip), %rdi     # 0x22797
callq 0x50b0
leaq 0x145ff(%rip), %rdi     # 0x227b1
callq 0x50b0
leaq 0x10fad(%rip), %rdi     # 0x1f16b
xorl %eax, %eax
callq 0x5130
leaq 0x1558e(%rip), %rdi     # 0x2375a
callq 0x50b0
leaq 0x12b7d(%rip), %rdi     # 0x20d55
popq %rax
jmp 0x50b0
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/writefil.c
// Function: print_word
char *print_word (char *p)
{
   char c, buf[STRSIZ];
   int first = TRUE;   /* flag to avoid printing null strings */

   if (*p == '\0' || *(p += strspn(p, WHITESPACE)) == '\0') return NULL;
   
   while ((c = *p) && !isspace(c & CHAR_MSK)) {
      if (c == '%' && p[1] != '\0') {
         p = expand_fmt(buf, p + 1);
         if (*buf && first) {
            printf("(");
            first = FALSE;
         }
         PUTSTR(isalnum, buf, stdout);
      } 
      else {
         if (first) printf("(");
         first = FALSE;
         PUTCHAR(isalnum, c, stdout);
         p++;
      }
   }
   
   if (!first) printf(")");
   
   return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
cmpb $0x0, (%rdi)
je 0x11b4f
movq %rdi, %rbx
leaq 0xcada(%rip), %rsi      # 0x1e507
callq 0x51a0
cmpb $0x0, (%rbx,%rax)
je 0x11b4f
addq %rax, %rbx
movb (%rbx), %r12b
testb %r12b, %r12b
je 0x11b53
callq 0x5340
movq %rax, %r14
movl $0x1, %r15d
movq 0x16560(%rip), %rbp     # 0x27fc0
leaq 0x10940(%rip), %r13     # 0x223a7
movzbl %r12b, %r12d
movq (%r14), %rax
testb $0x20, 0x1(%rax,%r12,2)
jne 0x11b47
cmpl $0x25, %r12d
jne 0x11af9
cmpb $0x0, 0x1(%rbx)
je 0x11af9
incq %rbx
movq %rsp, %rdi
movq %rbx, %rsi
callq 0x13989
movq %rax, %rbx
cmpb $0x0, (%rsp)
setne %al
testl %r15d, %r15d
setne %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x11ab8
movl $0x28, %edi
callq 0x5060
xorl %r15d, %r15d
movb (%rsp), %al
testb %al, %al
je 0x11b3b
leaq 0x1(%rsp), %r12
movzbl %al, %edx
movq %r13, %rsi
cmpb $0x20, %al
je 0x11ae1
movq (%r14), %rax
testb $0x8, (%rax,%rdx,2)
leaq 0xd3a0(%rip), %rsi      # 0x1ee7c
je 0x11ae1
movq %r13, %rsi
movq (%rbp), %rdi
xorl %eax, %eax
callq 0x5210
movb (%r12), %al
incq %r12
testb %al, %al
jne 0x11ac4
jmp 0x11b3b
testl %r15d, %r15d
je 0x11b08
movl $0x28, %edi
callq 0x5060
movq (%rbp), %rdi
movq %r13, %rsi
cmpl $0x20, %r12d
je 0x11b2b
movq (%r14), %rax
testb $0x8, (%rax,%r12,2)
movq %r13, %rsi
leaq 0xd355(%rip), %rax      # 0x1ee7c
cmoveq %rax, %rsi
xorl %r15d, %r15d
movl %r12d, %edx
xorl %eax, %eax
callq 0x5210
incq %rbx
movb (%rbx), %r12b
testb %r12b, %r12b
jne 0x11a67
testl %r15d, %r15d
sete %al
jmp 0x11b55
xorl %ebx, %ebx
jmp 0x11b63
xorl %eax, %eax
testb %al, %al
je 0x11b63
movl $0x29, %edi
callq 0x5060
movq %rbx, %rax
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/writefil.c
// Function: set_rgb
char *set_rgb (char *s)
{
   static char buf[STRSIZ];
   char *p1, *p2;
   double val[3];
   int n;
   
   val[0] = val[1] = val[2] = 0;   /* defaults */
   
   /* extract 1 - 3 floating-point values from string */
   for (n = 1, p1 = s; n <= 3; n++, p1 = p2 + 1) {
      val[n-1] = atof(p1);
      if ((p2 = strchr(p1, RGB_CHAR)) == NULL) break;
   }
   
   /* single value is gray scale; assume anything else is [r g b] */
   if (n > 1) sprintf(buf, "[%.3f %.3f %.3f]", val[0], val[1], val[2]);
   else sprintf(buf, "%.3f", val[0]);

   return buf; 
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
movaps %xmm0, (%rsp)
movq $0x0, 0x10(%rsp)
xorl %r14d, %r14d
movq %rbx, %rdi
callq 0x50c0
movsd %xmm0, (%rsp,%r14,8)
movq %rbx, %rdi
movl $0x3a, %esi
callq 0x5120
testq %rax, %rax
je 0x11bcc
movq %rax, %rbx
incq %rbx
incq %r14
cmpq $0x3, %r14
jne 0x11b95
movl $0x4, %r14d
jmp 0x11bcf
incl %r14d
movsd (%rsp), %xmm0
cmpl $0x2, %r14d
jb 0x11bfd
movsd 0x8(%rsp), %xmm1
movsd 0x10(%rsp), %xmm2
leaq 0x1d413(%rip), %rdi     # 0x2f000
leaq 0x108d8(%rip), %rsi     # 0x224cc
movb $0x3, %al
callq 0x52f0
jmp 0x11c12
leaq 0x1d3fc(%rip), %rdi     # 0x2f000
leaq 0x41f0(%rip), %rsi      # 0x15dfb
movb $0x1, %al
callq 0x52f0
leaq 0x1d3e7(%rip), %rax     # 0x2f000
addq $0x18, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/writefil.c
// Function: write_calfile
void write_calfile (void)
{
   KWD *k;
   int i;
   
   /* look up the Pcal keywords (assumed present) for the -c output file */
   for (k = keywds; k->name; k++) {
      if (k->code == DT_NOTE) kw_note = k->name;
      if (k->code == DT_OPT)  kw_opt  = k->name;
      if (k->code == DT_YEAR) kw_year = k->name;
   }
   
   /* print the date style for subsequent use by Pcal */
   printf("%s -%c\n", kw_opt, date_style == USA_DATES ? F_USA_DATES :
          F_EUR_DATES);
   
   for (i = 0, this_month = init_month, this_year = init_year;
        i < nmonths;
        i++, BUMP_MONTH_AND_YEAR(this_month, this_year)) {
      print_dates(this_month, this_year);
   }

   return;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x16982(%rip), %rax     # 0x28b40
movq (%rax), %rcx
testq %rcx, %rcx
je 0x1220f
addq $0x10, %rax
leaq 0x1cdff(%rip), %rdx     # 0x2efd0
leaq 0x1ce08(%rip), %rsi     # 0x2efe0
leaq 0x1cdf9(%rip), %rdi     # 0x2efd8
movl -0x8(%rax), %r8d
movq %rdx, %r9
cmpl $0x1, %r8d
je 0x12200
cmpl $0x4, %r8d
je 0x121fd
cmpl $0x2, %r8d
jne 0x12203
movq %rdi, %r9
jmp 0x12200
movq %rsi, %r9
movq %rcx, (%r9)
movq (%rax), %rcx
addq $0x10, %rax
testq %rcx, %rcx
jne 0x121df
movq 0x1cdc2(%rip), %rsi     # 0x2efd8
leaq 0x1a3cf(%rip), %rax     # 0x2c5ec
xorl %ecx, %ecx
cmpl $0x0, (%rax)
setne %cl
leal 0x41(,%rcx,4), %edx
leaq 0xffe9(%rip), %rdi      # 0x2221c
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x5130
leaq 0x1b251(%rip), %rax     # 0x2d494
movl (%rax), %eax
movl %eax, 0x1cd79(%rip)     # 0x2efc4
leaq 0x1b246(%rip), %rax     # 0x2d498
movl (%rax), %eax
movl %eax, 0x1cd6e(%rip)     # 0x2efc8
leaq 0x1b23b(%rip), %r14     # 0x2d49c
cmpl $0x0, (%r14)
jle 0x1229f
movl 0x1cd57(%rip), %edi     # 0x2efc4
movl 0x1cd55(%rip), %esi     # 0x2efc8
callq 0x122a7
movl 0x1cd46(%rip), %eax     # 0x2efc4
cmpl $0xc, %eax
jne 0x12290
incl 0x1cd3f(%rip)           # 0x2efc8
movl $0x1, %eax
jmp 0x12292
incl %eax
incl %ebx
movl %eax, 0x1cd2a(%rip)     # 0x2efc4
cmpl (%r14), %ebx
jl 0x12267
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/writefil.c
// Function: print_dates
void print_dates (int month, int year)
{
   register int day;
   year_info *py;
   month_info *pm;
   register day_info *pd;
   unsigned long holidays;
   int has_holiday_text;
   static int save_year = 0;
   
   /* if no text for this year and month, return */
   
   if ((py = find_year(year, FALSE)) == NULL || (pm = py->month[month-1]) == NULL) {
      return;
   }
   
   /* print the year if it has changed */
   
   if (year != save_year) printf("%s %d\n", kw_year, save_year = year);

   /* walk array of day text pointers and linked lists of text */
   
   for (holidays = pm->holidays, day = 1;
        day < FIRST_NOTE_DAY;
        holidays >>= 1L, day++) {
      has_holiday_text = FALSE;
      for (pd = pm->day[day-1]; pd; pd = pd->next) {
         /* Bypass entries that specify an EPS image... */
         if (ci_strncmp(pd->text, "image:", 6) == 0) continue;
         if (date_style == USA_DATES) printf("%02d/%02d", month, day);
         else printf("%02d/%02d", day, month);
#ifdef KEEP_ASTERISKS
         printf(pd->is_holiday ? "*\t" : "\t");
#else
         printf("\t");
#endif
         this_day = day;
         RESET_DATE();   /* reset working date */
         print_text(pd->text);
         printf("\n");
         has_holiday_text |= pd->is_holiday;
      }
#ifdef KEEP_ASTERISKS
      /* was date flagged as holiday w/o associated text? */
      if ((holidays & 01) && !has_holiday_text) {
         if (date_style == USA_DATES) printf("%02d/%02d*\n", month, day);
         else printf("%02d/%02d*\n", day, month);
      }
#endif
   }

   return;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %ebp
movl %edi, %ebx
movl %esi, %edi
xorl %esi, %esi
callq 0xc3f7
testq %rax, %rax
je 0x123ba
movslq %ebx, %rcx
movq (%rax,%rcx,8), %rax
movq %rax, (%rsp)
testq %rax, %rax
je 0x123ba
cmpl %ebp, 0x1cdf2(%rip)     # 0x2f0d4
je 0x12301
movq 0x1ccf5(%rip), %rsi     # 0x2efe0
movl %ebp, 0x1cde3(%rip)     # 0x2f0d4
leaq 0x1026e(%rip), %rdi     # 0x22566
movl %ebp, %edx
xorl %eax, %eax
callq 0x5130
movl $0x1, %r14d
leaq 0xffef(%rip), %r15      # 0x222fd
leaq 0x1a2d7(%rip), %rbp     # 0x2c5ec
leaq 0x10251(%rip), %r12     # 0x2256d
movq (%rsp), %rax
movq (%rax,%r14,8), %r13
testq %r13, %r13
je 0x123ad
movq 0x8(%r13), %rdi
movq %r15, %rsi
movl $0x6, %edx
callq 0x9d60
testl %eax, %eax
je 0x123a4
cmpl $0x0, (%rbp)
je 0x12352
movq %r12, %rdi
movl %r14d, %esi
movl %ebx, %edx
jmp 0x1235a
movq %r12, %rdi
movl %ebx, %esi
movl %r14d, %edx
xorl %eax, %eax
callq 0x5130
movl $0x9, %edi
callq 0x5060
movl %r14d, 0x1cc76(%rip)    # 0x2efe8
movl 0x1cc4c(%rip), %eax     # 0x2efc4
movl %eax, 0x1cc6e(%rip)     # 0x2efec
movl %r14d, 0x1cc6b(%rip)    # 0x2eff0
movl 0x1cc3d(%rip), %eax     # 0x2efc8
movl %eax, 0x1cc63(%rip)     # 0x2eff4
movq 0x8(%r13), %rdi
callq 0x143af
movl $0xa, %edi
callq 0x5060
movq 0x10(%r13), %r13
jmp 0x12324
incq %r14
cmpq $0x20, %r14
jne 0x1231c
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O1/mmayer[P]pcal/src/writefil.c
// Function: print_html
void print_html (char *p)
{
   char c, buf[STRSIZ];
   
   while ((c = *p) != '\0') {
      if (c == '%' && p[1] != '\0') {
         p = expand_fmt(buf, p + 1);
         PUTSTR_CLEAN(isalnum, buf, stdout);
      }
      else if (c < ' ' || c > '\176') printf("&#%03d;", *p++ & CHAR_MSK);
      else printf("%c", *p++);
   }
   return;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xc8, %rsp
movq %rdi, %r14
leaq 0x1(%rsp), %r12
movq %rsp, %rbx
movq 0x15627(%rip), %r13     # 0x27fc0
leaq 0xfddd(%rip), %r15      # 0x2277d
movzbl (%r14), %esi
cmpl $0x25, %esi
je 0x129af
testl %esi, %esi
jne 0x129e9
jmp 0x12a08
cmpb $0x0, 0x1(%r14)
je 0x129e9
incq %r14
movq %rbx, %rdi
movq %r14, %rsi
callq 0x13989
movq %rax, %r14
movb (%rsp), %al
testb %al, %al
je 0x129a0
movq %r12, %rbp
movq (%r13), %rsi
movzbl %al, %edi
callq 0x51c0
movb (%rbp), %al
incq %rbp
testb %al, %al
jne 0x129d1
jmp 0x129a0
leal -0x7f(%rsi), %eax
incq %r14
cmpb $-0x60, %al
ja 0x129ff
movq %r15, %rdi
xorl %eax, %eax
callq 0x5130
jmp 0x129a0
movl %esi, %edi
callq 0x5060
jmp 0x129a0
addq $0xc8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq