LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O3/barabo[P]advanced-shell-history/src/_ash_log.cpp
// Function: usage(std::ostream&)
void usage(ostream & out) {
  out << "\n\nThis program is not intended to be executed manually.\n\n"
      << "NOTE: See the man page for more details.\n";
  Flag::show_help(out);
  exit(1);
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
leaq 0x10fcd(%rip), %rsi     # 0x776ec
callq 0x73a0
leaq 0x10ffb(%rip), %rsi     # 0x77726
movq %rax, %rdi
callq 0x73a0
movq %rbx, %rdi
callq 0x6add8
movl $0x1, %edi
callq 0x7480
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: thread_report
void *thread_report(void *arg) {
    int count, i;
    char *pk, *dn;
    leda_device_data_t property[2];

    pthread_detach(pthread_self());
    
    count = g_devices_count;
    
    snprintf(property[0].key, MAX_PARAM_NAME_LENGTH, "brightness");
    property[0].type = LEDA_TYPE_INT;
    snprintf(property[1].key, MAX_PARAM_NAME_LENGTH, "power");
    property[1].type = LEDA_TYPE_BOOL;
    
    while (g_running) {
        for (i = 0; i < count; i++) {
            pk = g_devices[i].pk;
            dn = g_devices[i].dn;
            if (g_devices[i].online == 1) {
                snprintf(property[0].value, MAX_PARAM_VALUE_LENGTH, "%d", get_led_brightness(pk, dn));
                snprintf(property[1].value, MAX_PARAM_VALUE_LENGTH, "%d", get_led_power(pk, dn));
                leda_report_properties(pk, dn, property, 2);
                leda_report_event(pk, dn, "ledBroken", NULL, 0);
            }
            usleep(10*1000000/count);
        }
        sleep(1);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1098, %rsp           # imm = 0x1098
callq 0x1140
movq %rax, %rdi
callq 0x1190
movl 0x2c7d(%rip), %r13d     # 0x41a0
movabsq $0x656e746867697262, %rax # imm = 0x656E746867697262
movq %rax, -0x10bc(%rbp)
movl $0x737365, -0x10b5(%rbp) # imm = 0x737365
movl $0x0, -0x10c0(%rbp)
movw $0x72, -0x874(%rbp)
movabsq $0x65776f7000000001, %rax # imm = 0x65776F7000000001
movq %rax, -0x87c(%rbp)
cmpl $0x0, 0x2bcf(%rip)      # 0x4138
je 0x1668
imulq $0x3c, %r13, %r14
movq %r14, -0x30(%rbp)
testl %r13d, %r13d
jle 0x1651
xorl %r15d, %r15d
movq 0x2c1e(%rip), %r12      # 0x41a8
cmpl $0x1, 0x30(%r12,%r15)
jne 0x1633
leaq (%r12,%r15), %rbx
leaq (%r12,%r15), %r14
addq $0x10, %r14
movq %r14, %rsi
callq 0x134c
cltq
imulq $0x3c, %rax, %rax
movl 0x38(%r12,%rax), %ecx
movl $0x800, %esi            # imm = 0x800
leaq -0x107c(%rbp), %rdi
leaq 0xa4d(%rip), %r12       # 0x2015
movq %r12, %rdx
xorl %eax, %eax
callq 0x1050
movq %r14, %rsi
callq 0x134c
movq 0x2bc7(%rip), %rcx      # 0x41a8
cltq
imulq $0x3c, %rax, %rax
movl 0x34(%rcx,%rax), %ecx
movl $0x800, %esi            # imm = 0x800
leaq -0x838(%rbp), %rdi
movq %r12, %rdx
xorl %eax, %eax
callq 0x1050
movq %rbx, %rdi
movq %r14, %rsi
leaq -0x10c0(%rbp), %rdx
movl $0x2, %ecx
callq 0x11d0
movq %rbx, %rdi
movq %r14, %rsi
movq -0x30(%rbp), %r14
leaq 0x9ef(%rip), %rdx       # 0x2018
xorl %ecx, %ecx
xorl %r8d, %r8d
callq 0x1110
movl $0x989680, %eax         # imm = 0x989680
xorl %edx, %edx
divl %r13d
movl %eax, %edi
callq 0x1150
addq $0x3c, %r15
cmpq %r15, %r14
jne 0x1583
movl $0x1, %edi
callq 0x1130
cmpl $0x0, 0x2ad6(%rip)      # 0x4138
jne 0x1577
addq $0x1098, %rsp           # imm = 0x1098
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: load_device_from_csv
int load_device_from_csv(char *path)
{
    FILE *fp;
    char ch;
    int line = 0, i;
    device_t invalid = {0};
    char tmp[128] = {0};
    
    fp = fopen(path, "r+");
    if (!fp) {
        printf("open file:%s error!\n", path);
        return -1;
    }
    
    while (NULL != fgets(&tmp[0], sizeof(tmp), fp)) {
       line++;
    }
    fseek(fp, 0, SEEK_SET);
    
    g_devices_count = line - 1;
    g_devices = malloc(g_devices_count * sizeof(device_t));
    memset(g_devices, 0, g_devices_count * sizeof(device_t));
    for (i = 0; i < line; i++) {
        if (i == 0) {
            fscanf(fp, "%s\n", &tmp[0]);
        } else {
            fscanf(fp, "%[^','],%[^','],%s\n", &g_devices[i - 1].dn[0], &tmp[0], &g_devices[i - 1].pk[0]);
        }        
    }
    fclose(fp);

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rdi, %r14
xorps %xmm0, %xmm0
movaps %xmm0, -0x40(%rbp)
movaps %xmm0, -0x50(%rbp)
movaps %xmm0, -0x60(%rbp)
movaps %xmm0, -0x70(%rbp)
movaps %xmm0, -0x80(%rbp)
movaps %xmm0, -0x90(%rbp)
movaps %xmm0, -0xa0(%rbp)
movaps %xmm0, -0xb0(%rbp)
leaq 0x94c(%rip), %rsi       # 0x2052
callq 0x10c0
testq %rax, %rax
je 0x17e3
movq %rax, %rbx
movq $-0x78, %r15
xorl %r13d, %r13d
leaq -0xb0(%rbp), %r14
movq %r14, %rdi
movl $0x80, %esi
movq %rbx, %rdx
callq 0x10d0
decq %r13
addq $0x3c, %r15
testq %rax, %rax
jne 0x1728
movq %rbx, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x1080
movl $0xfffffffe, %eax       # imm = 0xFFFFFFFE
subl %r13d, %eax
movl %eax, 0x2a42(%rip)      # 0x41a0
movl $0x1, %edi
movq %r15, %rsi
callq 0x11f0
movq %rax, 0x2a36(%rip)      # 0x41a8
cmpl $-0x1, %r13d
je 0x17d7
notq %r13
movq $-0x3c, %r15
leaq -0xb0(%rbp), %r12
xorl %r14d, %r14d
subq $0x1, %r14
jae 0x17a8
movq %rbx, %rdi
leaq 0x921(%rip), %rsi       # 0x20bd
movq %r12, %rdx
xorl %eax, %eax
callq 0x1060
jmp 0x17ce
movq 0x29f9(%rip), %r8       # 0x41a8
leaq (%r8,%r15), %rdx
addq $0x10, %rdx
addq %r15, %r8
movq %rbx, %rdi
leaq 0x8a6(%rip), %rsi       # 0x206a
movq %r12, %rcx
xorl %eax, %eax
callq 0x1060
addq $0x3c, %r15
decq %r13
jne 0x178c
movq %rbx, %rdi
callq 0x1200
xorl %eax, %eax
jmp 0x17f9
leaq 0x86b(%rip), %rdi       # 0x2055
movq %r14, %rsi
xorl %eax, %eax
callq 0x1030
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: unload_device_list
void unload_device_list()
{
    if (g_devices) {
        free(g_devices);
        g_devices = NULL;
    }
    g_devices_count = 0;
}

// Assembly:
movq 0x2996(%rip), %rdi      # 0x41a8
testq %rdi, %rdi
je 0x182c
pushq %rbp
movq %rsp, %rbp
callq 0x10f0
movq $0x0, 0x297d(%rip) # 0x41a8
popq %rbp
movl $0x0, 0x296a(%rip)      # 0x41a0
retq
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: cb_state_changed
static void cb_state_changed(leda_conn_state_e state, void *usr)
{
    int ret = -1;
    printf("connection state: %s\n", !state ? "connected" : "disconnected");
    if (LEDA_WS_CONNECTED == state) {
        g_is_connected = 1;
    } else {
        g_is_connected = 0;
    }
    pthread_mutex_lock(&g_mtx_online);
    pthread_cond_signal(&g_cond_conn_state_changed);
    pthread_mutex_unlock(&g_mtx_online);
    return;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
xorl %ebx, %ebx
testl %edi, %edi
sete %bl
leaq 0x5b2(%rip), %rax       # 0x20c4
leaq 0x5a8(%rip), %rsi       # 0x20c1
cmoveq %rax, %rsi
leaq 0x587(%rip), %rdi       # 0x20ab
xorl %eax, %eax
callq 0x1030
movl %ebx, 0x2673(%rip)      # 0x41a4
leaq 0x2640(%rip), %rbx      # 0x4178
movq %rbx, %rdi
callq 0x1230
leaq 0x2601(%rip), %rdi      # 0x4148
callq 0x1090
movq %rbx, %rdi
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0x1240
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: cb_get_property
static int cb_get_property(const char *pk, const char *dn,
                                       leda_device_data_t properties[], 
                                       int properties_count, 
                                       void *usr_data)
{
    int i;
    for (i = 0; i < properties_count; i++) {
        if (strcmp(properties[i].key, "power") == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_led_power(pk, dn));
            properties[i].type = LEDA_TYPE_BOOL;
        } else if (strcmp(properties[i].key, "brightness") == 0) {
            snprintf(properties[i].value, MAX_PARAM_VALUE_LENGTH, "%d", get_led_brightness(pk, dn));
            properties[i].type = LEDA_TYPE_INT;
        } else {
            return LEDA_ERROR_PROPERTY_NOT_EXIST;
        }
    }

    return LE_SUCCESS;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
testl %ecx, %ecx
jle 0x1c1b
movq %rdx, %rbx
movq %rsi, %r14
movl %ecx, %r12d
addq $0x44, %rbx
leaq -0x40(%rbx), %r13
movq %r13, %rdi
leaq 0x484(%rip), %rsi       # 0x200f
callq 0x11a0
testl %eax, %eax
je 0x1bc8
movq %r13, %rdi
leaq 0x466(%rip), %rsi       # 0x2004
callq 0x11a0
testl %eax, %eax
jne 0x1c20
movq %r14, %rsi
callq 0x134c
movq 0x25f2(%rip), %rcx      # 0x41a8
cltq
imulq $0x3c, %rax, %rax
addq %rcx, %rax
addq $0x38, %rax
xorl %r15d, %r15d
jmp 0x1bea
movq %r14, %rsi
callq 0x134c
movq 0x25d1(%rip), %rcx      # 0x41a8
cltq
imulq $0x3c, %rax, %rax
addq %rcx, %rax
addq $0x34, %rax
movl $0x1, %r15d
movl (%rax), %ecx
xorl %r13d, %r13d
movl $0x800, %esi            # imm = 0x800
movq %rbx, %rdi
leaq 0x417(%rip), %rdx       # 0x2015
xorl %eax, %eax
callq 0x1050
movl %r15d, -0x44(%rbx)
addq $0x844, %rbx            # imm = 0x844
decq %r12
jne 0x1b7d
jmp 0x1c26
xorl %r13d, %r13d
jmp 0x1c26
movl $0x1a9ca, %r13d         # imm = 0x1A9CA
movl %r13d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: cb_set_property
static int cb_set_property(const char *pk, const char *dn,
                                       const leda_device_data_t properties[], 
                                       int properties_count, 
                                       void *usr_data)
{
    int ret = LE_ERROR_UNKNOWN, i;

    for (i = 0; i < properties_count; i++) {
        if (0 == strcmp("brightness", properties[i].key)) {
            ret = set_led_brightness(pk, dn, atoi(properties[i].value));
        } else if (0 == strcmp("power", properties[i].key)) {
            ret = set_led_power(pk, dn, atoi(properties[i].value));
        } else {
            return LEDA_ERROR_PROPERTY_NOT_EXIST;
        }
        if (ret != LE_SUCCESS) {
            break;
        }
    }
    return ret;
}

// Assembly:
testl %ecx, %ecx
jle 0x1ce4
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rsi, %r14
movq 0x254d(%rip), %r12      # 0x41a8
movl %ecx, %r15d
addq $0x44, %rbx
leaq -0x40(%rbx), %r13
leaq 0x397(%rip), %rdi       # 0x2004
movq %r13, %rsi
callq 0x11a0
testl %eax, %eax
je 0x1cb1
leaq 0x38f(%rip), %rdi       # 0x200f
movq %r13, %rsi
callq 0x11a0
testl %eax, %eax
jne 0x1cf1
movq %rbx, %rdi
callq 0x1170
cmpl $0x1, %eax
ja 0x1cea
movl %eax, %r13d
movq %r14, %rsi
callq 0x134c
cltq
imulq $0x3c, %rax, %rax
movl %r13d, 0x34(%r12,%rax)
jmp 0x1cd4
movq %rbx, %rdi
callq 0x1170
cmpl $0x5, %eax
ja 0x1cea
movl %eax, %r13d
movq %r14, %rsi
callq 0x134c
cltq
imulq $0x3c, %rax, %rax
movl %r13d, 0x38(%r12,%rax)
addq $0x844, %rbx            # imm = 0x844
decq %r15
jne 0x1c62
xorl %eax, %eax
jmp 0x1cf6
movl $0x186a0, %eax          # imm = 0x186A0
retq
movl $0x186a7, %eax          # imm = 0x186A7
jmp 0x1cf6
movl $0x1a9ca, %eax          # imm = 0x1A9CA
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/back1127[P]linkedge-thing-access-websocket_client_sdk/demo/linux/demo.c
// Function: cb_call_service
static int cb_call_service(const char *pk, const char *dn, const char *method_name, const leda_device_data_t *data, int count, 
                            leda_device_data_t *output, void *usr)
{
    if (!method_name || !output) {
        return LE_ERROR_INVAILD_PARAM;
    }
    if (0 == strcmp("blink", method_name)) {
        printf("%s:%s blinking\n", pk, dn);
        return LE_SUCCESS;
    } else {
        return LEDA_ERROR_SERVICE_NOT_EXIST;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
testq %rdx, %rdx
sete %al
testq %r9, %r9
sete %cl
movl $0x186a1, %r15d         # imm = 0x186A1
orb %al, %cl
jne 0x1d5b
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x39c(%rip), %rdi       # 0x20ce
movq %rdx, %rsi
callq 0x11a0
movl $0x1a9cd, %r15d         # imm = 0x1A9CD
testl %eax, %eax
jne 0x1d5b
leaq 0x389(%rip), %rdi       # 0x20d4
xorl %r15d, %r15d
movq %r14, %rsi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x1030
movl %r15d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/armor.c
// Function: wear
int wear()
{
	struct linked_list *item;
	struct object *obj;

	if (cur_armor != NULL) {
		msg("You are already wearing some.");
		after = FALSE;
		return 0;
	}
	if ((item = get_item("wear", ARMOR)) == NULL)
		return 0;
	obj = OBJPTR(item);
	if (obj->o_type != ARMOR) {
		msg("You can't wear that.");
		return 0;
	}
	waste_time();
	msg("Wearing %s.", a_magic[obj->o_which].mi_name);
	cur_armor = obj;
	setoflg(obj,ISKNOW);
	nochange = FALSE;
  return 0;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
leaq 0x27131(%rip), %r14     # 0x2d858
cmpq $0x0, (%r14)
je 0x674f
leaq 0x188d0(%rip), %rdi     # 0x1f004
xorl %eax, %eax
callq 0xb620
leaq 0x23bcb(%rip), %rax     # 0x2a30d
movb $0x0, (%rax)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x188cc(%rip), %rdi     # 0x1f022
movl $0x5d, %esi
callq 0x10749
testq %rax, %rax
je 0x6745
movq 0x10(%rax), %rbx
cmpl $0x5d, 0x20(%rbx)
jne 0x67b0
xorl %eax, %eax
callq 0xc9bc
movslq 0x28(%rbx), %rax
shlq $0x4, %rax
leaq 0x256db(%rip), %rcx     # 0x2be60
movq (%rcx,%rax), %rsi
leaq 0x188ac(%rip), %rdi     # 0x1f03c
xorl %eax, %eax
callq 0xb620
movq %rbx, (%r14)
movl $0x2, %esi
movq %rbx, %rdi
callq 0x9553
leaq 0x270f5(%rip), %rax     # 0x2d8a3
jmp 0x6742
leaq 0x18870(%rip), %rdi     # 0x1f027
xorl %eax, %eax
callq 0xb620
jmp 0x6745
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/armor.c
// Function: take_off
int take_off()
{
	struct object *obj;

	if ((obj = cur_armor) == NULL) {
		msg("Not wearing any armor.");
		return 0;
	}
	if (!dropcheck(cur_armor))
		return 0;
	cur_armor = NULL;
	msg("Was wearing %c) %s",pack_char(obj),inv_name(obj,TRUE));
	nochange = FALSE;
  return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
leaq 0x2708d(%rip), %r14     # 0x2d858
movq (%r14), %rbx
testq %rbx, %rbx
je 0x681d
movq %rbx, %rdi
callq 0x1b54e
testb %al, %al
je 0x682b
movq $0x0, (%r14)
movq %rbx, %rdi
callq 0x10495
movsbl %al, %ebp
movq %rbx, %rdi
movl $0x1, %esi
callq 0x1aa04
leaq 0x1885a(%rip), %rdi     # 0x1f05f
movl %ebp, %esi
movq %rax, %rdx
xorl %eax, %eax
callq 0xb620
leaq 0x2708b(%rip), %rax     # 0x2d8a3
movb $0x0, (%rax)
jmp 0x682b
leaq 0x18824(%rip), %rdi     # 0x1f048
xorl %eax, %eax
callq 0xb620
xorl %eax, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/armor.c
// Function: initarmor
void initarmor(struct object *obj,int what)
{
	struct init_armor *iwa;
	struct magic_item *mi;

	obj->o_type = ARMOR;
	obj->o_which = what;
	iwa = &armors[what];
	mi = &a_magic[what];
	obj->o_vol = iwa->a_vol;
	obj->o_ac = iwa->a_class;
	obj->o_weight = iwa->a_wght;
	obj->o_typname = things[TYP_ARMOR].mi_name;
}

// Assembly:
movl $0x5d, 0x20(%rdi)
movl %esi, 0x28(%rdi)
movslq %esi, %rax
leaq (%rax,%rax,2), %rax
leaq 0x256c6(%rip), %rcx     # 0x2bf10
movl (%rcx,%rax,4), %edx
movl %edx, 0x34(%rdi)
movq 0x4(%rcx,%rax,4), %rax
movq %rax, 0x40(%rdi)
leaq 0x25570(%rip), %rax     # 0x2bdd0
movq 0x40(%rax), %rax
movq %rax, 0x18(%rdi)
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/armor.c
// Function: hurt_armor
bool hurt_armor(struct object *obj)
{
	int type, ac;

	if (obj != NULL) {
		if (o_on(obj, ISPROT) || (o_on(obj, ISBLESS) && rnd(100) < 10))
			return FALSE;
		ac = obj->o_ac;
		type = obj->o_which;
		if (type != PADDED && type != LEATHER)
			if ((type == STUDDED && ac < 8) || (type != STUDDED && ac < 9))
				return TRUE;
	}
	return FALSE;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
testq %rdi, %rdi
je 0x68d8
movq %rdi, %rbx
movl $0x10, %esi
callq 0x9531
testb %al, %al
jne 0x68d8
movl $0x20, %esi
movq %rbx, %rdi
callq 0x9531
testb %al, %al
je 0x68a6
xorl %ebp, %ebp
movl $0x64, %edi
xorl %eax, %eax
callq 0xc674
cmpl $0xa, %eax
jl 0x68da
movl 0x28(%rbx), %eax
testl $0xfffffffb, %eax       # imm = 0xFFFFFFFB
je 0x68d8
movl 0x34(%rbx), %ecx
cmpl $0x2, %eax
sete %dl
cmpl $0x8, %ecx
setl %sil
movb $0x1, %bpl
testb %sil, %dl
jne 0x68da
cmpl $0x2, %eax
setne %al
cmpl $0x9, %ecx
setl %cl
testb %cl, %al
jne 0x68da
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/chase.c
// Function: runners
int runners()
{
	struct thing *tp;
	struct linked_list *mon,*nextmon;

	for (mon = mlist; mon != NULL; mon = nextmon) {
		tp = THINGPTR(mon);
		nextmon = next(mon);
		if (off(*tp, ISHELD) && on(*tp, ISRUN)) {
			if (tp->t_nomove > 0)
				if (--tp->t_nomove > 0)
					continue;
			if (on(*tp, ISHASTE))
				if (do_chase(mon) == -1)
					continue;
			if (off(*tp, ISSLOW) || tp->t_turn)
				if (do_chase(mon) == -1)
					continue;
			tp->t_turn ^= TRUE;
		}
	}
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x26f50(%rip), %rax     # 0x2d840
movq (%rax), %r14
testq %r14, %r14
je 0x6973
movq %r14, %rbx
movq (%r14), %r14
movq 0x10(%rbx), %r15
movq 0x78(%r15), %rax
movl %eax, %ecx
andl $0x104, %ecx            # imm = 0x104
cmpl $0x4, %ecx
jne 0x68f3
movl 0x84(%r15), %ecx
testl %ecx, %ecx
jle 0x692d
leal -0x1(%rcx), %edx
movl %edx, 0x84(%r15)
cmpl $0x1, %ecx
jne 0x68f3
testw %ax, %ax
jns 0x6943
movq %rbx, %rdi
callq 0x697b
cmpl $-0x1, %eax
je 0x68f3
movq 0x78(%r15), %rax
btl $0xe, %eax
jae 0x6954
movb 0x8c(%r15), %al
cmpb $0x1, %al
jne 0x6968
movq %rbx, %rdi
callq 0x697b
cmpl $-0x1, %eax
je 0x68f3
movb 0x8c(%r15), %al
xorb $0x1, %al
movb %al, 0x8c(%r15)
jmp 0x68f3
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/chase.c
// Function: cansee
bool cansee(int y,int x)
{
	struct room *rer;
	struct coord tp;

	if (pl_on(ISBLIND))
		return FALSE;
	/*
	 * We can only see if the hero in the same room as
	 * the coordinate and the room is lit or if it is close.
	 */
	if (DISTANCE(y, x, hero.y, hero.x) < 3)
		return TRUE;
	tp.y = y;
	tp.x = x;
	rer = roomin(&tp);
	if (rer != NULL && levtype != MAZELEV)
		if (rer == player.t_room && !rf_on(rer,ISDARK))
			return TRUE;
	return FALSE;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movl %edi, %r14d
movl $0x1, %edi
callq 0x9513
testb %al, %al
je 0x6fb4
xorl %ebx, %ebx
jmp 0x6fd7
leaq 0x26ca5(%rip), %r15     # 0x2dc60
movl 0x50(%r15), %eax
movl 0x54(%r15), %ecx
subl %ebp, %eax
imull %eax, %eax
subl %r14d, %ecx
imull %ecx, %ecx
addl %eax, %ecx
movb $0x1, %bl
cmpl $0x3, %ecx
jae 0x6fe4
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rsp, %rdi
movl %r14d, 0x4(%rdi)
movl %ebp, (%rdi)
callq 0x701c
testq %rax, %rax
je 0x6fb0
leaq 0x26866(%rip), %rcx     # 0x2d864
cmpl $0x2, (%rcx)
je 0x6fb0
cmpq 0x70(%r15), %rax
jne 0x6fb0
movl $0x1, %esi
movq %rax, %rdi
callq 0x13d18
testl %eax, %eax
jne 0x6fb0
jmp 0x6fd7
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/chase.c
// Function: roomin
struct room *roomin(struct coord *cp)
{
	struct room *rp;

	if (cordok(cp->y, cp->x)) {
		for (rp = rooms; rp < &rooms[MAXROOMS]; rp += 1)
			if (inroom(rp, cp))
				return rp;
	}
	return NULL;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movl (%rdi), %esi
movl 0x4(%rdi), %edi
callq 0x94ef
testb %al, %al
je 0x707f
movl (%rbx), %ecx
xorl %eax, %eax
leaq 0x26877(%rip), %rsi     # 0x2d8b0
xorl %edx, %edx
movl (%rsi,%rdx), %edi
cmpl %ecx, %edi
jg 0x706d
movl 0x8(%rsi,%rdx), %r8d
addl %r8d, %edi
decl %edi
cmpl %edi, %ecx
jg 0x706d
movl 0x4(%rbx), %edi
movl 0x4(%rsi,%rdx), %r8d
cmpl %edi, %r8d
jg 0x706d
movl 0xc(%rsi,%rdx), %r9d
addl %r9d, %r8d
decl %r8d
cmpl %r8d, %edi
jle 0x7083
leaq 0x68(%rdx), %rdi
cmpq $0x340, %rdx            # imm = 0x340
movq %rdi, %rdx
jb 0x703b
jmp 0x708d
xorl %eax, %eax
jmp 0x708d
addq 0x22e86(%rip), %rdx     # 0x29f10
movq %rdx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/chase.c
// Function: diag_ok
bool diag_ok(struct coord *sp,struct coord *ep)
{
	if (ep->x == sp->x || ep->y == sp->y)
		return TRUE;
	if (step_ok(mvinch(ep->y,sp->x)) && step_ok(mvinch(sp->y,ep->x)))
		return TRUE;
	return FALSE;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl (%rdi), %edx
movb $0x1, %bl
cmpl %edx, (%rsi)
je 0x74ad
movq %rsi, %r15
movq %rdi, %r12
movl 0x4(%rsi), %esi
cmpl 0x4(%rdi), %esi
je 0x74ad
movl $0xffffffff, %r14d      # imm = 0xFFFFFFFF
movq 0x22ada(%rip), %r13     # 0x29f30
movq (%r13), %rdi
callq 0x6490
movl $0xffffffff, %edi       # imm = 0xFFFFFFFF
cmpl $-0x1, %eax
je 0x7474
movq (%r13), %rdi
callq 0x6330
movl %eax, %edi
callq 0xb8d5
testb %al, %al
je 0x74ab
movq (%r13), %rdi
movl 0x4(%r12), %esi
movl (%r15), %edx
callq 0x6490
cmpl $-0x1, %eax
je 0x749f
movq (%r13), %rdi
callq 0x6330
movl %eax, %r14d
movq %r14, %rdi
callq 0xb8d5
testb %al, %al
jne 0x74ad
xorl %ebx, %ebx
movl %ebx, %eax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/chase.c
// Function: runto
struct linked_list *find_mons(int y,int x)
{
	struct linked_list *item;
	struct thing *th;

	for (item = mlist; item != NULL; item = next(item)) {
		th = THINGPTR(item);
		if (th->t_pos.y == y && th->t_pos.x == x)
			return item;
	}
	return NULL;
}

// Assembly:
leaq 0x26380(%rip), %rax     # 0x2d840
movq (%rax), %rax
testq %rax, %rax
je 0x74ff
movl (%rdi), %edx
movl 0x4(%rdi), %edi
movq 0x10(%rax), %rcx
cmpl %edi, 0x54(%rcx)
jne 0x74db
cmpl %edx, 0x50(%rcx)
je 0x74e5
movq (%rax), %rax
testq %rax, %rax
jne 0x74cd
jmp 0x74ff
movq 0x78(%rcx), %rax
testb $0x2, %al
jne 0x74ff
movq %rsi, 0x60(%rcx)
andq $-0x107, %rax           # imm = 0xFEF9
orq $0x4, %rax
movq %rax, 0x78(%rcx)
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/command.c
// Function: quit
void quit(int a)
{
	char ch, good;
	/*
	 * Reset the signal in case we got here via an interrupt
	 */
	if (signal(SIGINT, quit) != quit)
		mpos = 0;
	msg("Really quit? [y/n/s]");
/*	ch = tolower(readchar());*/
	ch = readchar();
	if (ch == 'y') {
		clear();
		move(LINES-1, 0);
		refresh();
		score(purse, CHICKEN, 0);
		byebye(0);
	}
	else if (ch == 's') {
		good = save_game();
		if (good) {
			wclear(cw);
			draw(cw);
			endwin();
			byebye(0);
		}
	}
	else {
		signal(SIGINT, quit);
		wmove(cw, 0, 0);
		wclrtoeol(cw);
		draw(cw);
		mpos = 0;
		count = 0;
		nochange = FALSE;
	}
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
leaq -0xa(%rip), %rbx        # 0x8186
movl $0x2, %edi
movq %rbx, %rsi
callq 0x6280
cmpq %rbx, %rax
je 0x81af
leaq 0x256c7(%rip), %rax     # 0x2d870
movl $0x0, (%rax)
leaq 0x17244(%rip), %rdi     # 0x1f3fa
xorl %eax, %eax
callq 0xb620
xorl %eax, %eax
callq 0xb94c
cmpb $0x73, %al
je 0x8213
movzbl %al, %eax
cmpl $0x79, %eax
jne 0x8249
movq 0x21d59(%rip), %rbx     # 0x29f30
movq (%rbx), %rdi
callq 0x6120
movq (%rbx), %rdi
movq 0x21dc7(%rip), %rax     # 0x29fb0
movl (%rax), %esi
decl %esi
xorl %edx, %edx
callq 0x6490
movq (%rbx), %rdi
callq 0x6200
leaq 0x25669(%rip), %rax     # 0x2d86c
movl (%rax), %edi
movl $0x1, %esi
xorl %edx, %edx
callq 0x12eea
jmp 0x823a
xorl %eax, %eax
callq 0x14030
testb %al, %al
je 0x829b
leaq 0x287bb(%rip), %rbx     # 0x309e0
movq (%rbx), %rdi
callq 0x6120
movq (%rbx), %rdi
callq 0x6200
callq 0x6530
xorl %edi, %edi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
jmp 0xc65c
leaq -0xca(%rip), %rsi       # 0x8186
movl $0x2, %edi
callq 0x6280
leaq 0x2877f(%rip), %rbx     # 0x309e0
movq (%rbx), %rdi
xorl %ebp, %ebp
xorl %esi, %esi
xorl %edx, %edx
callq 0x6490
movq (%rbx), %rdi
callq 0x64a0
movq (%rbx), %rdi
callq 0x6200
leaq 0x255ea(%rip), %rax     # 0x2d870
movl %ebp, (%rax)
leaq 0x255f5(%rip), %rax     # 0x2d884
movl %ebp, (%rax)
leaq 0x2560b(%rip), %rax     # 0x2d8a3
movb $0x0, (%rax)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/command.c
// Function: d_level
int d_level()
{
	if (winat(hero.y, hero.x) != STAIRS)
		msg("I see no way down.");
	else {
		if (pl_on(ISHELD)) {
			msg("You are being held.");
			return 0;
		}
		level++;
		new_level(NORMLEV);
	}
  return 0;
}

// Assembly:
pushq %rax
leaq 0x255f2(%rip), %rax     # 0x2dc60
movl 0x50(%rax), %esi
movl 0x54(%rax), %edi
callq 0x9492
cmpb $0x25, %al
jne 0x8694
movl $0x100, %edi            # imm = 0x100
callq 0x9513
testb %al, %al
je 0x86a4
leaq 0x16ee3(%rip), %rdi     # 0x1f575
jmp 0x869b
leaq 0x16ec7(%rip), %rdi     # 0x1f562
xorl %eax, %eax
callq 0xb620
jmp 0x86b4
leaq 0x21c45(%rip), %rax     # 0x2a2f0
incl (%rax)
xorl %edi, %edi
callq 0xf534
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/command.c
// Function: u_level
int u_level()
{
	if (winat(hero.y, hero.x) == STAIRS)  {
		if (pl_on(ISHELD)) {
			msg("You are being held.");
			return 0;
		}
		else {				/* player not held here */
			if (amulet) {
				level--;
				if (level == 0)
					total_winner();
				new_level(NORMLEV);
				msg("You feel a wrenching sensation in your gut.");
				return 0;
			}
		}
	}
	msg("I see no way up.");
  return 0;
}

// Assembly:
pushq %rbx
leaq 0x255a0(%rip), %rax     # 0x2dc60
movl 0x50(%rax), %esi
movl 0x54(%rax), %edi
callq 0x9492
leaq 0x16ee3(%rip), %rbx     # 0x1f5b5
cmpb $0x25, %al
jne 0x8719
movl $0x100, %edi            # imm = 0x100
callq 0x9513
testb %al, %al
je 0x86ed
leaq 0x16e8a(%rip), %rbx     # 0x1f575
jmp 0x8719
leaq 0x251ad(%rip), %rax     # 0x2d8a1
cmpb $0x1, (%rax)
jne 0x8719
leaq 0x21bf0(%rip), %rax     # 0x2a2f0
decl (%rax)
jne 0x870b
xorl %eax, %eax
callq 0x13782
xorl %edi, %edi
callq 0xf534
leaq 0x16e70(%rip), %rbx     # 0x1f589
movq %rbx, %rdi
xorl %eax, %eax
callq 0xb620
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/command.c
// Function: call
int call()
{
	struct object *obj;
	struct linked_list *item;
	char **guess, *elsewise;
	int wh;

	if ((item = get_item("call", 0)) == NULL)
		return 0;
	obj = OBJPTR(item);
	wh = obj->o_which;
	switch (obj->o_type) {
	case RING:
		guess = r_guess;
		elsewise = (r_guess[wh] != NULL ? r_guess[wh] : r_stones[wh]);
	when POTION:
		guess = p_guess;
		elsewise = (p_guess[wh] != NULL ? p_guess[wh] : p_colors[wh]);
	when SCROLL:
		guess = s_guess;
		elsewise = (s_guess[wh] != NULL ? s_guess[wh] : s_names[wh]);
	when STICK:
		guess = ws_guess;
		elsewise =(ws_guess[wh] != NULL ?
			ws_guess[wh] : ws_stuff[wh].ws_made);
	otherwise:
		msg("You can't call %ss anything",obj->o_typname);
		return 0;
	}
	msg("Was called \"%s\"", elsewise);
	msg(callit);
	if (guess[wh] != NULL)
		free(guess[wh]);
	strcpy(prbuf, elsewise);
	if (get_str(prbuf, cw) == NORM) {
		guess[wh] = new(strlen(prbuf) + 1);
		strcpy(guess[wh], prbuf);
	}
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
leaq 0x16d88(%rip), %rdi     # 0x1f5eb
xorl %esi, %esi
callq 0x10749
testq %rax, %rax
je 0x89d8
movq 0x10(%rax), %rax
movslq 0x28(%rax), %r15
movl 0x20(%rax), %ecx
cmpl $0x3c, %ecx
jg 0x88c4
cmpl $0x21, %ecx
je 0x890c
cmpl $0x2f, %ecx
jne 0x88f5
leaq 0x27a78(%rip), %r12     # 0x30310
movq (%r12,%r15,8), %rbx
testq %rbx, %rbx
jne 0x895d
leaq (%r15,%r15,2), %rax
leaq 0x27ec0(%rip), %rcx     # 0x30770
leaq (%rcx,%rax,8), %rax
addq $0x8, %rax
leaq 0x27a51(%rip), %r12     # 0x30310
jmp 0x895a
cmpl $0x3f, %ecx
je 0x8934
cmpl $0x3d, %ecx
jne 0x88f5
leaq 0x2796b(%rip), %r12     # 0x30240
movq (%r12,%r15,8), %rbx
testq %rbx, %rbx
jne 0x895d
movq %r15, %rax
shlq $0x3, %rax
addq 0x215fc(%rip), %rax     # 0x29ee8
leaq 0x2794d(%rip), %r12     # 0x30240
jmp 0x895a
movq 0x18(%rax), %rsi
leaq 0x16cf0(%rip), %rdi     # 0x1f5f0
xorl %eax, %eax
callq 0xb620
jmp 0x89d8
leaq 0x2787d(%rip), %r12     # 0x30190
movq (%r12,%r15,8), %rbx
testq %rbx, %rbx
jne 0x895d
leaq (,%r15,8), %rax
addq 0x215b5(%rip), %rax     # 0x29ee0
leaq 0x2785e(%rip), %r12     # 0x30190
jmp 0x895a
leaq 0x27785(%rip), %r12     # 0x300c0
movq (%r12,%r15,8), %rbx
testq %rbx, %rbx
jne 0x895d
leaq (,%r15,8), %rax
addq 0x21675(%rip), %rax     # 0x29fc8
leaq 0x27766(%rip), %r12     # 0x300c0
movq (%rax), %rbx
leaq 0x16ca8(%rip), %rdi     # 0x1f60c
movq %rbx, %rsi
xorl %eax, %eax
callq 0xb620
leaq 0x21a21(%rip), %rdi     # 0x2a396
xorl %eax, %eax
callq 0xb620
movq (%r12,%r15,8), %rdi
testq %rdi, %rdi
je 0x898a
callq 0x6050
leaq 0x254ff(%rip), %r14     # 0x2de90
movq %r14, %rdi
movq %rbx, %rsi
callq 0x60e0
leaq 0x2803d(%rip), %rax     # 0x309e0
movq (%rax), %rsi
movq %r14, %rdi
callq 0xfd31
testl %eax, %eax
jne 0x89d8
leaq 0x254d7(%rip), %rbx     # 0x2de90
movq %rbx, %rdi
callq 0x6170
leal 0x1(%rax), %edi
callq 0xbe2a
movq %rax, (%r12,%r15,8)
movq %rax, %rdi
movq %rbx, %rsi
callq 0x60e0
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemon.c
// Function: d_insert
struct delayed_action *d_insert(int (*func)(),int arg,int type,int time)
{
	struct delayed_action *dev;

	if (demoncnt < MAXDAEMONS) {
		dev = &d_list[demoncnt];
		dev->d_type = type;
		dev->d_time = time;
		dev->d_func = func;
		dev->d_arg = arg;
		demoncnt += 1;
		return dev;
	}
	return NULL;
}

// Assembly:
leaq 0x24e8d(%rip), %r8      # 0x2d87c
movslq (%r8), %r9
cmpq $0x13, %r9
jg 0x8a1b
leaq (%r9,%r9,2), %rax
leaq 0x24bfd(%rip), %r10     # 0x2d600
leaq (%r10,%rax,8), %rax
movl %edx, (%rax)
movl %ecx, 0x14(%rax)
movq %rdi, 0x8(%rax)
movl %esi, 0x10(%rax)
leal 0x1(%r9), %ecx
movl %ecx, (%r8)
retq
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemon.c
// Function: d_delete
int d_delete(struct delayed_action *wire)
{
	struct delayed_action *d1, *d2;

	for (d1 = d_list; d1 < &d_list[demoncnt]; d1++) {
		if (wire == d1) {
			for (d2 = d1 + 1; d2 < &d_list[demoncnt]; d2++)
				*d1++ = *d2;
			demoncnt -= 1;
			d1 = &d_list[demoncnt];
			d1->d_type = EMPTY;
			d1->d_func = EMPTY;
			return 0;
		}
	}
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x24e52(%rip), %r14     # 0x2d87c
movslq (%r14), %rbx
testq %rbx, %rbx
jle 0x8ad4
movq %rdi, %rcx
leaq (%rbx,%rbx,2), %rax
leaq 0x24bbc(%rip), %r15     # 0x2d600
leaq (%r15,%rax,8), %rax
leaq 0x24be1(%rip), %r8      # 0x2d630
xorl %edx, %edx
leaq (%r15,%rdx), %rdi
leaq (%rdx,%r15), %rsi
addq $0x18, %rsi
cmpq %rcx, %rdi
je 0x8a71
addq $0x18, %rdx
addq $0x18, %r8
cmpq %rax, %rsi
jb 0x8a51
jmp 0x8ad4
cmpq %rax, %rsi
jae 0x8ab7
cmpq %rax, %r8
cmovaq %r8, %rax
subq %r15, %rax
addq $-0x30, %rax
xorl %ecx, %ecx
cmpq %rdx, %rax
setne %cl
subq %rcx, %rax
subq %rdx, %rax
movabsq $-0x5555555555555555, %rdx # imm = 0xAAAAAAAAAAAAAAAB
mulq %rdx
shrq $0x4, %rdx
addq %rcx, %rdx
leaq (%rdx,%rdx,2), %rax
leaq 0x18(,%rax,8), %rdx
callq 0x63f0
decl %ebx
movl %ebx, (%r14)
movslq %ebx, %rax
leaq (%rax,%rax,2), %rax
movl $0x0, (%r15,%rax,8)
movq $0x0, 0x8(%r15,%rax,8)
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemon.c
// Function: do_daemons
void do_daemons(int flag)
{
	struct delayed_action *dev;

	for (dev = d_list; dev < &d_list[demoncnt]; dev++)
		if (dev->d_type == flag && dev->d_time == DAEMON)
			(*dev->d_func)(dev->d_arg);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
leaq 0x24d25(%rip), %r14     # 0x2d87c
movl (%r14), %eax
testl %eax, %eax
jle 0x8b9b
movl %edi, %ebx
leaq 0x24a99(%rip), %r15     # 0x2d600
movq %r15, %r12
cmpl %ebx, (%r12)
jne 0x8b87
cmpl $-0x1, 0x14(%r12)
jne 0x8b87
movl 0x10(%r12), %edi
xorl %eax, %eax
callq *0x8(%r12)
movl (%r14), %eax
addq $0x18, %r12
movslq %eax, %rcx
leaq (%rcx,%rcx,2), %rcx
leaq (%r15,%rcx,8), %rcx
cmpq %rcx, %r12
jb 0x8b6a
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemon.c
// Function: lengthen
void lengthen(int (*func)(),int xtime)
{
	struct delayed_action *wire;

	for (wire = d_list; wire < &d_list[demoncnt]; wire++)
		if (wire->d_type != EMPTY && func == wire->d_func)
			wire->d_time += xtime;
}

// Assembly:
leaq 0x24c97(%rip), %rax     # 0x2d87c
movslq (%rax), %rax
testq %rax, %rax
jle 0x8c13
leaq (%rax,%rax,2), %rcx
leaq 0x24a08(%rip), %rax     # 0x2d600
leaq (%rax,%rcx,8), %rcx
cmpl $0x0, (%rax)
je 0x8c0a
cmpq %rdi, 0x8(%rax)
jne 0x8c0a
addl %esi, 0x14(%rax)
addq $0x18, %rax
cmpq %rcx, %rax
jb 0x8bfc
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemon.c
// Function: extinguish
void extinguish(int (*func)())
{
	struct delayed_action *dev;

	for (dev = d_list; dev < &d_list[demoncnt]; dev++)
		if (dev->d_type != EMPTY && func == dev->d_func)
			d_delete(dev);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
leaq 0x24c59(%rip), %r15     # 0x2d87c
movl (%r15), %eax
testl %eax, %eax
jle 0x8c62
movq %rdi, %rbx
leaq 0x249cc(%rip), %r12     # 0x2d600
movq %r12, %r14
cmpl $0x0, (%r14)
je 0x8c4e
cmpq %rbx, 0x8(%r14)
jne 0x8c4e
movq %r14, %rdi
callq 0x8a1e
movl (%r15), %eax
addq $0x18, %r14
movslq %eax, %rcx
leaq (%rcx,%rcx,2), %rcx
leaq (%r12,%rcx,8), %rcx
cmpq %rcx, %r14
jb 0x8c37
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemon.c
// Function: do_fuses
void do_fuses()
{
	struct delayed_action *dev;

	for (dev = d_list; dev < &d_list[demoncnt]; dev++) {
		if (dev->d_type == AFTER && dev->d_time > DAEMON) {
			if (--dev->d_time == 0) {
				(*dev->d_func)(dev->d_arg);
				d_delete(dev);
			}
		}
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x24c02(%rip), %r14     # 0x2d87c
movl (%r14), %eax
testl %eax, %eax
jle 0x8cc5
leaq 0x24978(%rip), %r15     # 0x2d600
movq %r15, %rbx
cmpl $0x2, (%rbx)
jne 0x8cb1
movl 0x14(%rbx), %ecx
testl %ecx, %ecx
js 0x8cb1
decl %ecx
movl %ecx, 0x14(%rbx)
jne 0x8cb1
movl 0x10(%rbx), %edi
xorl %eax, %eax
callq *0x8(%rbx)
movq %rbx, %rdi
callq 0x8a1e
movl (%r14), %eax
addq $0x18, %rbx
movslq %eax, %rcx
leaq (%rcx,%rcx,2), %rcx
leaq (%r15,%rcx,8), %rcx
cmpq %rcx, %rbx
jb 0x8c8b
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: doctor
int doctor(int fromfuse)
{
	int *thp, lv, ohp, ccon;

	lv = him->s_lvl;
	thp = &him->s_hpt;
	ohp = *thp;
	quiet += 1;

	ccon = him->s_ef.a_con;
	if (ccon > 16 && !isfight)
		*thp += rnd(ccon - 15);
	if (lv < 8) {
		if (quiet > 20 - lv * 2)
			*thp += 1;
	}
	else {
		if (quiet >= 3)
			*thp += rnd(lv - 7) + 1;
	}
	if (isring(LEFT, R_REGEN))
		*thp += 1;
	if (isring(RIGHT, R_REGEN))
		*thp += 1;
	if (pl_on(ISREGEN))
		*thp += 1;
	if (ohp != *thp) {
		nochange = FALSE;
		if (*thp > him->s_maxhp)
			*thp = him->s_maxhp;
		quiet = 0;
	}
  return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
leaq 0x25065(%rip), %r12     # 0x2dd60
movq (%r12), %r14
movl 0x28(%r14), %ebx
movl 0x30(%r14), %ebp
leaq 0x24b7e(%rip), %r15     # 0x2d88c
incl (%r15)
movl 0x1c(%r14), %edi
movl %ebp, %eax
cmpl $0x11, %edi
jl 0x8d3c
leaq 0x24b75(%rip), %rax     # 0x2d898
cmpb $0x0, (%rax)
movl %ebp, %eax
jne 0x8d3c
addl $-0xf, %edi
xorl %eax, %eax
callq 0xc674
addl 0x30(%r14), %eax
movl %eax, 0x30(%r14)
movl (%r15), %ecx
cmpl $0x7, %ebx
jg 0x8d55
addl %ebx, %ebx
movl $0x14, %edx
subl %ebx, %edx
cmpl %edx, %ecx
jle 0x8d72
incl %eax
jmp 0x8d6e
cmpl $0x3, %ecx
jl 0x8d72
addl $-0x7, %ebx
movl %ebx, %edi
xorl %eax, %eax
callq 0xc674
movl 0x30(%r14), %ecx
addl %ecx, %eax
incl %eax
movl %eax, 0x30(%r14)
xorl %edi, %edi
movl $0x9, %esi
callq 0x12c17
testb %al, %al
je 0x8d86
incl 0x30(%r14)
movl $0x1, %edi
movl $0x9, %esi
callq 0x12c17
testb %al, %al
je 0x8d9d
incl 0x30(%r14)
movl $0x400, %edi            # imm = 0x400
callq 0x9513
movl 0x30(%r14), %ecx
testb %al, %al
je 0x8db5
incl %ecx
movl %ecx, 0x30(%r14)
cmpl %ecx, %ebp
je 0x8dd9
leaq 0x24ae3(%rip), %rax     # 0x2d8a3
movb $0x0, (%rax)
movq (%r12), %rax
movl 0x34(%rax), %eax
cmpl %eax, %ecx
jle 0x8dd2
movl %eax, 0x30(%r14)
movl $0x0, (%r15)
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: rollwand
int rollwand(int fromfuse)
{

	if (++between >= 4) {
		if (roll(1, 6) == 4) {
			if (levtype != POSTLEV)		/* no monsters for posts */
				wanderer();
			extinguish(rollwand);
			fuse(swander, TRUE, WANDERTIME);
		}
		between = 0;
	}
  return 0;
}

// Assembly:
movl 0x249db(%rip), %eax     # 0x2d7e0
leal 0x1(%rax), %ecx
movl %ecx, 0x249d2(%rip)     # 0x2d7e0
cmpl $0x3, %eax
jl 0x8e6b
pushq %rax
movl $0x1, %edi
movl $0x6, %esi
callq 0xc695
cmpl $0x4, %eax
jne 0x8e5d
leaq 0x24a35(%rip), %rax     # 0x2d864
cmpl $0x1, (%rax)
je 0x8e3b
xorl %eax, %eax
callq 0xd880
leaq -0x43(%rip), %rdi       # 0x8dff
callq 0x8c14
leaq -0x6a(%rip), %rdi       # 0x8de4
movl $0x1, %esi
movl $0x46, %edx
callq 0x8ba7
movl $0x0, 0x24979(%rip)     # 0x2d7e0
addq $0x8, %rsp
xorl %eax, %eax
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: unconfuse
int unconfuse(int fromfuse)
{
	if (pl_on(ISHUH))
		msg("You feel less confused now.");
	player.t_flags &= ~ISHUH;
  return 0;
}

// Assembly:
pushq %rax
movl $0x200, %edi            # imm = 0x200
callq 0x9513
testb %al, %al
je 0x8e8b
leaq 0x167b9(%rip), %rdi     # 0x1f63d
xorl %eax, %eax
callq 0xb620
leaq 0x24dce(%rip), %rax     # 0x2dc60
andb $-0x3, 0x79(%rax)
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: sight
int sight(int fromfuse)
{
	if (pl_on(ISBLIND))
		msg("The veil of darkness lifts.");
	player.t_flags &= ~ISBLIND;
	light(&hero);
  return 0;
}

// Assembly:
pushq %rax
movl $0x1, %edi
callq 0x9513
testb %al, %al
je 0x8ec5
leaq 0x1679b(%rip), %rdi     # 0x1f659
xorl %eax, %eax
callq 0xb620
leaq 0x24d94(%rip), %rdi     # 0x2dc60
andb $-0x2, 0x78(%rdi)
addq $0x50, %rdi
callq 0xeba8
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: nohaste
int nohaste(int fromfuse)
{
	if (pl_on(ISHASTE))
		msg("You feel yourself slowing down.");
	player.t_flags &= ~ISHASTE;
  return 0;
}

// Assembly:
pushq %rax
movl $0x8000, %edi           # imm = 0x8000
callq 0x9513
testb %al, %al
je 0x8efa
leaq 0x16782(%rip), %rdi     # 0x1f675
xorl %eax, %eax
callq 0xb620
leaq 0x24d5f(%rip), %rax     # 0x2dc60
andb $0x7f, 0x79(%rax)
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: stomach
int stomach(int fromfuse)
{
	int oldfood, old_hunger;

	old_hunger = hungry_state;
	if (food_left <= 0) {		 /* the hero is fainting */
		if (--food_left == -150) {
			msg("Your stomach writhes with hunger pains.");
		}
		else if (food_left < -350) {
			msg("You starve to death !!");
			msg(" ");
			death(K_STARVE);
		}
		if (player.t_nocmd > 0 || rnd(100) > 20)
			return 0;
		player.t_nocmd = rnd(8)+4;
		msg("You faint.");
		running = FALSE;
		count = 0;
		hungry_state = F_FAINT;
	}
	else {
		oldfood = food_left;
		food_left -= ringfood + foodlev - amulet;
		if (player.t_nocmd > 0)		/* wait till he can move */
			return 0;
		if (food_left < WEAKTIME && oldfood >= WEAKTIME) {
			msg("You are starting to feel weak.");
			hungry_state = F_WEAK;
		}
		else if(food_left < HUNGTIME && oldfood >= HUNGTIME) {
			msg("Getting hungry.");
			hungry_state = F_HUNGRY;
		}
	}
	if (old_hunger != hungry_state)
	    updpack();				/* new pack weight */
	wghtchk(FALSE);
  return 0;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x2497b(%rip), %r14     # 0x2d890
movl (%r14), %ebx
leaq 0x213e1(%rip), %rdx     # 0x2a300
movl (%rdx), %eax
testl %eax, %eax
jle 0x8f8c
leaq 0x24968(%rip), %rcx     # 0x2d894
movl (%rcx), %esi
leaq 0x213d3(%rip), %rcx     # 0x2a308
leaq 0x24965(%rip), %rdi     # 0x2d8a1
addl (%rcx), %esi
movzbl (%rdi), %edi
movl %eax, %ecx
subl %esi, %ecx
addl %edi, %ecx
movl %ecx, (%rdx)
leaq 0x24d10(%rip), %rdx     # 0x2dc60
cmpl $0x0, 0x88(%rdx)
jg 0x9075
cmpl $0x96, %eax
jb 0x903e
cmpl $0x95, %ecx
jg 0x903e
leaq 0x16764(%rip), %rdi     # 0x1f6df
xorl %eax, %eax
callq 0xb620
movl $0x2, %eax
jmp 0x9060
leal -0x1(%rax), %ecx
movl %ecx, (%rdx)
cmpl $0xffffff6a, %ecx       # imm = 0xFFFFFF6A
jne 0x8fa9
leaq 0x166f5(%rip), %rdi     # 0x1f695
xorl %eax, %eax
callq 0xb620
jmp 0x8fd6
cmpl $0xfffffea2, %eax       # imm = 0xFFFFFEA2
jg 0x8fd6
leaq 0x16706(%rip), %rdi     # 0x1f6bd
xorl %eax, %eax
callq 0xb620
leaq 0x1823b(%rip), %rdi     # 0x21200
xorl %eax, %eax
callq 0xb620
movl $0xfffffff7, %edi       # imm = 0xFFFFFFF7
callq 0x12c60
leaq 0x24c83(%rip), %r15     # 0x2dc60
cmpl $0x0, 0x88(%r15)
jg 0x9075
movl $0x64, %edi
xorl %eax, %eax
callq 0xc674
cmpl $0x14, %eax
jg 0x9075
movl $0x8, %edi
xorl %eax, %eax
callq 0xc674
addl $0x4, %eax
movl %eax, 0x88(%r15)
leaq 0x166bb(%rip), %rdi     # 0x1f6d4
xorl %eax, %eax
callq 0xb620
leaq 0x24875(%rip), %rax     # 0x2d89c
movb $0x0, (%rax)
leaq 0x24853(%rip), %rax     # 0x2d884
movl $0x0, (%rax)
movl $0x3, %eax
jmp 0x9060
cmpl $0x12c, %eax            # imm = 0x12C
jb 0x906e
cmpl $0x12b, %ecx            # imm = 0x12B
jg 0x906e
leaq 0x166aa(%rip), %rdi     # 0x1f6fe
xorl %eax, %eax
callq 0xb620
movl $0x1, %eax
movl %eax, (%r14)
cmpl %eax, %ebx
je 0x906e
xorl %eax, %eax
callq 0x9560
xorl %edi, %edi
callq 0x9889
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: noteth
int noteth(int fromfuse)
{
	int ch;

	if (pl_on(ISETHER)) {
		msg("You begin to feel more corporeal.");
		ch = player.t_oldch;
		if (dead_end(ch)) {
			msg("You materialize in %s.",identify(ch));
			msg(" ");
			death(K_STONE);	/* can't materialize in walls */
		}
	}
	player.t_flags &= ~ISETHER;
  return 0;
}

// Assembly:
pushq %rbx
movl $0x10000, %edi          # imm = 0x10000
callq 0x9513
testb %al, %al
je 0x90e3
leaq 0x1667b(%rip), %rdi     # 0x1f70e
xorl %eax, %eax
callq 0xb620
leaq 0x24bbf(%rip), %rax     # 0x2dc60
movsbl 0x8f(%rax), %ebx
movl %ebx, %edi
callq 0xb91a
testb %al, %al
je 0x90e3
movl %ebx, %edi
callq 0x7f63
leaq 0x1666f(%rip), %rdi     # 0x1f730
movq %rax, %rsi
xorl %eax, %eax
callq 0xb620
leaq 0x1812e(%rip), %rdi     # 0x21200
xorl %eax, %eax
callq 0xb620
movl $0xfffffff6, %edi       # imm = 0xFFFFFFF6
callq 0x12c60
leaq 0x24b76(%rip), %rax     # 0x2dc60
andb $-0x2, 0x7a(%rax)
xorl %eax, %eax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: sapem
int sapem(int fromfuse)
{
	chg_abil(rnd(4) + 1, -1, TRUE);
	fuse(sapem, TRUE, 150);
	nochange = FALSE;
  return 0;
}

// Assembly:
pushq %rax
movl $0x4, %edi
xorl %eax, %eax
callq 0xc674
leal 0x1(%rax), %edi
movl $0xffffffff, %esi       # imm = 0xFFFFFFFF
movl $0x1, %edx
callq 0x11d8e
leaq -0x26(%rip), %rdi       # 0x90f2
movl $0x1, %esi
movl $0x96, %edx
callq 0x8ba7
leaq 0x24775(%rip), %rax     # 0x2d8a3
movb $0x0, (%rax)
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: notslow
int notslow(int fromfuse)
{
	if (pl_on(ISSLOW))
		msg("You no longer feel hindered.");
	player.t_flags &= ~ISSLOW;
  return 0;
}

// Assembly:
pushq %rax
movl $0x4000, %edi           # imm = 0x4000
callq 0x9513
testb %al, %al
je 0x9152
leaq 0x165fc(%rip), %rdi     # 0x1f747
xorl %eax, %eax
callq 0xb620
leaq 0x24b07(%rip), %rax     # 0x2dc60
andb $-0x41, 0x79(%rax)
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: notregen
int notregen(int fromfuse)
{
	if (pl_on(ISREGEN))
		msg("You no longer feel bolstered.");
	player.t_flags &= ~ISREGEN;
  return 0;
}

// Assembly:
pushq %rax
movl $0x400, %edi            # imm = 0x400
callq 0x9513
testb %al, %al
je 0x917e
leaq 0x165ed(%rip), %rdi     # 0x1f764
xorl %eax, %eax
callq 0xb620
leaq 0x24adb(%rip), %rax     # 0x2dc60
andb $-0x5, 0x79(%rax)
xorl %eax, %eax
popq %rcx
retq
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/daemons.c
// Function: notinvinc
int notinvinc(int fromfuse)
{
	if (pl_on(ISINVINC))
		msg("You no longer feel invincible.");
	player.t_flags &= ~ISINVINC;
  return 0;
}

// Assembly:
pushq %rax
movl $0x8, %edi
callq 0x9513
testb %al, %al
je 0x91aa
leaq 0x165df(%rip), %rdi     # 0x1f782
xorl %eax, %eax
callq 0xb620
leaq 0x24aaf(%rip), %rax     # 0x2dc60
andb $-0x9, 0x78(%rax)
xorl %eax, %eax
popq %rcx
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/disply.c
// Function: dispmons
void dispmons()
{
	int ch, y, x;
	struct thing *it;
	struct linked_list *item;

	for (item = mlist; item != NULL; item = next(item)) {
		it = THINGPTR(item);
		y = it->t_pos.y;
		x = it->t_pos.x;
		mvwaddch(cw, y, x, it->t_type);
		it->t_flags |= ISFOUND;
		if (it->t_type == 'M')			/* if a mimic */
			it->t_disguise = 'M';		/* give it away */
	}
	draw(cw);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
leaq 0x24419(%rip), %rax     # 0x2d840
movq (%rax), %rbx
testq %rbx, %rbx
je 0x947e
leaq 0x275aa(%rip), %r14     # 0x309e0
movq 0x10(%rbx), %r15
movl 0x50(%r15), %edx
movl 0x54(%r15), %esi
movq (%r14), %rdi
callq 0x6490
cmpl $-0x1, %eax
je 0x945f
movq (%r14), %rdi
movsbl 0x8d(%r15), %esi
callq 0x64c0
orb $0x8, 0x78(%r15)
cmpb $0x4d, 0x8d(%r15)
jne 0x9476
movb $0x4d, 0x8e(%r15)
movq (%rbx), %rbx
testq %rbx, %rbx
jne 0x9436
leaq 0x2755b(%rip), %rax     # 0x309e0
movq (%rax), %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x6200
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/disply.c
// Function: winat
char winat(int y,int x)
{
	unsigned long ch;

	if (mvwinch(mw,y,x) == ' ')
		ch = mvinch(y, x);			/* non-monsters */
	else
		ch = winch(mw);				/* monsters */
	return ch;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %esi, %ebx
movl %edi, %ebp
leaq 0x2754f(%rip), %r14     # 0x309f0
movq (%r14), %rdi
movl %ebp, %esi
movl %ebx, %edx
callq 0x6490
cmpl $-0x1, %eax
je 0x94de
leaq 0x27537(%rip), %r14     # 0x309f0
movq (%r14), %rdi
callq 0x6330
cmpl $0x20, %eax
jne 0x94de
movq 0x20a63(%rip), %r14     # 0x29f30
movq (%r14), %rdi
movl %ebp, %esi
movl %ebx, %edx
callq 0x6490
cmpl $-0x1, %eax
je 0x94eb
movq (%r14), %rdi
callq 0x6330
popq %rbx
popq %r14
popq %rbp
retq
movb $-0x1, %al
jmp 0x94e6
// File: /workspace/github_c_makefile_star2_O3/ajpaulson[P]srogue11/disply.c
// Function: o_off
bool o_off(struct object *what,long bit)
{
	int flag;

	flag = FALSE;
	if (what != NULL)
		flag = !(what->o_flags & bit);
	return flag;
}

// Assembly:
testq %rdi, %rdi
je 0x9550
movslq 0x38(%rdi), %rax
testq %rsi, %rax
sete %al
retq
xorl %eax, %eax
retq