// File: /workspace/github_c_makefile_star2_O2/xemul[P]cylang/tokenizer.c
// Function: read_cblocks
static int read_cblocks(struct cy_token *t, struct cy_file *f)
{
	int ret;

	t->v.t = CY_V_CBLOCK;
	t->v.v_cblk = malloc(sizeof(struct cy_cblock));
	INIT_LIST_HEAD(&t->v.v_cblk->h);

	while (1) {
		struct cy_ctoken *cb;

		cb = malloc(sizeof(*cb));

		ret = cy_read_next_token(f, &cb->t);
		if (ret <= 0) {
			free(cb);
			return ret;
		}

		if (cb->t.typ->priv == OP_CBLOCK || cb->t.typ->priv == OP_CBLOCK_SHORT) {
			ret = read_cblocks(&cb->t, f);
			if (ret <= 0) {
				free(cb);
				return ret;
			}
		} else if (cb->t.typ->priv == OP_CBLOCK_END) {
			free(cb);
			return 1;
		} else if (cb->t.typ->priv == OP_COMMENT) {
			free(cb);
			continue;
		}

		list_add_tail(&cb->l, &t->v.v_cblk->h);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %r15
movl $0x5, 0x18(%rdi)
pushq $0x10
popq %rdi
callq 0x3180
movq %rax, 0x20(%r15)
movq %rax, 0x8(%rax)
movq %rax, (%rax)
pushq $0x38
popq %rdi
leaq 0x3850(%rip), %r12      # 0x70f4
pushq $0x1
popq %r13
callq 0x3180
movq %rax, %rbx
andq $0x0, 0x18(%rax)
andl $0x0, 0x28(%rax)
leaq 0x10(%rax), %rbp
movq 0x8(%r14), %rax
movq 0x10(%r14), %rcx
cmpq %rcx, %rax
je 0x3a15
movzbl (%rax), %edx
cmpl $0x9, %edx
je 0x38ec
cmpl $0x20, %edx
je 0x38ec
cmpl $0xa, %edx
jne 0x38f5
incl 0x18(%r14)
movl $0x1, 0x1c(%r14)
incq %rax
movq %rax, 0x8(%r14)
jmp 0x38c5
movq %rax, 0x10(%rbx)
movl 0x18(%r14), %edx
movl %edx, 0x20(%rbx)
movl 0x1c(%r14), %esi
movl %esi, 0x24(%rbx)
movzbl (%rax), %edi
cmpq $0x27, %rdi
ja 0x3920
movabsq $0x8c00000000, %r8      # imm = 0x8C00000000
btq %rdi, %r8
jb 0x3967
xorl %edi, %edi
cmpq %rcx, %rax
jae 0x3a37
movsbl (%rax), %r8d
testl %edi, %edi
je 0x3951
cmpl %r8d, %edi
je 0x3970
cmpb $0xa, %r8b
jne 0x3967
incl %edx
movl %edx, 0x18(%r14)
movl $0x1, 0x1c(%r14)
movl %r13d, %esi
jmp 0x3967
cmpb $0x9, %r8b
je 0x3981
movzbl %r8b, %r8d
cmpl $0xa, %r8d
je 0x3976
cmpl $0x20, %r8d
je 0x3981
incq %rax
movq %rax, 0x8(%r14)
jmp 0x3922
cmpb $0xa, %r8b
jne 0x3981
incl %edx
movl %edx, 0x18(%r14)
movl %r13d, %esi
jmp 0x3983
incl %esi
movl %esi, 0x1c(%r14)
movb $0x0, (%rax)
incq 0x8(%r14)
cmpb $0x1, 0x20(%r14)
jne 0x39a9
movq 0x10(%rbx), %rsi
movl 0x20(%rbx), %edx
movl 0x24(%rbx), %ecx
movq %r12, %rdi
xorl %eax, %eax
callq 0x30b0
movq %rbp, %rdi
callq 0x35c8
testl %eax, %eax
jle 0x3a32
movq 0x18(%rbx), %rax
movq 0x10(%rax), %rax
cmpq $0x70000001, %rax       # imm = 0x70000001
je 0x39df
cmpq $0x70000005, %rax       # imm = 0x70000005
je 0x39df
cmpq $0x7fffffff, %rax       # imm = 0x7FFFFFFF
je 0x3a05
cmpq $0x70000002, %rax       # imm = 0x70000002
jne 0x39ee
jmp 0x3a59
movq %rbp, %rdi
movq %r14, %rsi
callq 0x386f
testl %eax, %eax
jle 0x3a32
movq 0x20(%r15), %rax
movq (%rax), %rcx
movq %rbx, (%rax)
movq %rax, 0x8(%rbx)
movq %rcx, (%rbx)
movq %rbx, 0x8(%rcx)
jmp 0x3a0d
movq %rbx, %rdi
callq 0x3030
pushq $0x38
popq %rdi
jmp 0x38a4
xorl %r13d, %r13d
movq %rbx, %rdi
callq 0x3030
movl %r13d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %r13d
jmp 0x3a18
movq 0x75ba(%rip), %rax      # 0xaff8
movq (%rax), %rcx
leaq 0x3687(%rip), %rdi      # 0x70cf
pushq $0x24
popq %rsi
pushq $0x1
popq %rdx
callq 0x3210
pushq $-0x1
popq %r13
jmp 0x3a18
movq %rbx, %rdi
callq 0x3030
pushq $0x1
popq %r13
jmp 0x3a20