// File: /workspace/github_c_makefile_star2_O2/baskerville[P]bspwm/src/query.c
// Function: query_node
void query_node(node_t *n, FILE *rsp)
{
	if (n == NULL) {
		fprintf(rsp, "null");
	} else {
		fprintf(rsp, "{");
		fprintf(rsp, "\"id\":%u,", n->id);
		fprintf(rsp, "\"splitType\":\"%s\",", SPLIT_TYPE_STR(n->split_type));
		fprintf(rsp, "\"splitRatio\":%lf,", n->split_ratio);
		fprintf(rsp, "\"vacant\":%s,", BOOL_STR(n->vacant));
		fprintf(rsp, "\"hidden\":%s,", BOOL_STR(n->hidden));
		fprintf(rsp, "\"sticky\":%s,", BOOL_STR(n->sticky));
		fprintf(rsp, "\"private\":%s,", BOOL_STR(n->private));
		fprintf(rsp, "\"locked\":%s,", BOOL_STR(n->locked));
		fprintf(rsp, "\"marked\":%s,", BOOL_STR(n->marked));
		fprintf(rsp, "\"presel\":");
		query_presel(n->presel, rsp);
		fprintf(rsp,",");
		fprintf(rsp, "\"rectangle\":");
		query_rectangle(n->rectangle, rsp);
		fprintf(rsp,",");
		fprintf(rsp, "\"constraints\":");
		query_constraints(n->constraints, rsp);
		fprintf(rsp,",");
		fprintf(rsp, "\"firstChild\":");
		query_node(n->first_child, rsp);
		fprintf(rsp,",");
		fprintf(rsp, "\"secondChild\":");
		query_node(n->second_child, rsp);
		fprintf(rsp,",");
		fprintf(rsp, "\"client\":");
		query_client(n->client, rsp);
		fprintf(rsp, "}");
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
testq %rdi, %rdi
je 0x177fa
movq %rdi, %r14
pushq $0x7b
popq %rdi
movq %rbx, %rsi
callq 0x4420
movl (%r14), %edx
leaq 0x8845(%rip), %rsi      # 0x1fe1a
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
cmpl $0x0, 0x4(%r14)
leaq 0x8738(%rip), %rax      # 0x1fd23
leaq 0x873d(%rip), %rdx      # 0x1fd2f
cmoveq %rax, %rdx
leaq 0x88f2(%rip), %rsi      # 0x1feef
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
movsd 0x8(%r14), %xmm0
leaq 0x88ed(%rip), %rsi      # 0x1ff01
movq %rbx, %rdi
movb $0x1, %al
callq 0x4a30
leaq 0x8362(%rip), %r12      # 0x1f987
cmpb $0x0, 0x24(%r14)
leaq 0x835b(%rip), %r15      # 0x1f98c
movq %r15, %rdx
cmovneq %r12, %rdx
leaq 0x88d4(%rip), %rsi      # 0x1ff13
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
cmpb $0x0, 0x25(%r14)
movq %r15, %rdx
cmovneq %r12, %rdx
leaq 0x88c4(%rip), %rsi      # 0x1ff20
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
cmpb $0x0, 0x26(%r14)
movq %r15, %rdx
cmovneq %r12, %rdx
leaq 0x88b4(%rip), %rsi      # 0x1ff2d
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
cmpb $0x0, 0x27(%r14)
movq %r15, %rdx
cmovneq %r12, %rdx
leaq 0x88a4(%rip), %rsi      # 0x1ff3a
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
cmpb $0x0, 0x28(%r14)
movq %r15, %rdx
cmovneq %r12, %rdx
leaq 0x8895(%rip), %rsi      # 0x1ff48
movq %rbx, %rdi
xorl %eax, %eax
callq 0x4a30
cmpb $0x0, 0x29(%r14)
cmovneq %r12, %r15
leaq 0x8888(%rip), %rsi      # 0x1ff55
movq %rbx, %rdi
movq %r15, %rdx
xorl %eax, %eax
callq 0x4a30
leaq 0x8881(%rip), %rdi      # 0x1ff62
pushq $0x9
popq %r15
pushq $0x1
popq %r12
movq %r15, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x49e0
movq 0x10(%r14), %rdi
movq %rbx, %rsi
callq 0x1781d
pushq $0x2c
popq %rbp
movl %ebp, %edi
movq %rbx, %rsi
callq 0x4420
leaq 0x877c(%rip), %rdi      # 0x1fe93
pushq $0xc
popq %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x49e0
movq 0x18(%r14), %rdi
movq %rbx, %rsi
callq 0x1743e
movl %ebp, %edi
movq %rbx, %rsi
callq 0x4420
leaq 0x882a(%rip), %rdi      # 0x1ff6c
pushq $0xe
popq %r13
movq %r13, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x49e0
movl 0x20(%r14), %edi
movq %rbx, %rsi
callq 0x1787f
movl %ebp, %edi
movq %rbx, %rsi
callq 0x4420
leaq 0x880a(%rip), %rdi      # 0x1ff7b
pushq $0xd
popq %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x49e0
movq 0x30(%r14), %rdi
movq %rbx, %rsi
callq 0x175a6
movl %ebp, %edi
movq %rbx, %rsi
callq 0x4420
leaq 0x87ed(%rip), %rdi      # 0x1ff89
movq %r13, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x49e0
movq 0x38(%r14), %rdi
movq %rbx, %rsi
callq 0x175a6
movl %ebp, %edi
movq %rbx, %rsi
callq 0x4420
leaq 0x87d1(%rip), %rdi      # 0x1ff98
movq %r15, %rsi
movq %r12, %rdx
movq %rbx, %rcx
callq 0x49e0
movq 0x48(%r14), %rdi
movq %rbx, %rsi
callq 0x1789b
pushq $0x7d
popq %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x4420
leaq 0x86e9(%rip), %rdi      # 0x1feea
pushq $0x4
popq %rsi
pushq $0x1
popq %rdx
movq %rbx, %rcx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x49e0