// File: /workspace/github_c_makefile_star2_O1/lucvoo[P]sparse-dev/dissect.c
// Function: do_statement
static struct symbol *do_statement(usage_t mode, struct statement *stmt)
{
	struct symbol *ret = &void_ctype;

	if (stmt) switch (stmt->type) {
	default:
		warning(stmt->pos, "bad stmt->type: %d", stmt->type);

	case STMT_NONE:
	case STMT_RANGE:
	case STMT_CONTEXT:

	break; case STMT_DECLARATION:
		do_sym_list(stmt->declaration);

	break; case STMT_EXPRESSION:
		ret = do_expression(mode, stmt->expression);

	break; case STMT_RETURN: {
		struct symbol *type = dissect_ctx->ctype.base_type;
		do_expression(u_lval(base_type(type)), stmt->expression);
	}

	break; case STMT_ASM:
		do_expression(U_R_VAL, stmt->asm_string);
		do_asm_xputs(U_W_VAL, stmt->asm_outputs);
		do_asm_xputs(U_R_VAL, stmt->asm_inputs);

	break; case STMT_COMPOUND: {
		int count;

		count = statement_list_size(stmt->stmts);
		DO_LIST(stmt->stmts, st,
			ret = do_statement(--count ? U_VOID : mode, st));
	}

	break; case STMT_ITERATOR:
		do_sym_list(stmt->iterator_syms);
		do_statement(U_VOID, stmt->iterator_pre_statement);
		do_expression(U_R_VAL, stmt->iterator_pre_condition);
		do_statement(U_VOID, stmt->iterator_post_statement);
		do_statement(U_VOID, stmt->iterator_statement);
		do_expression(U_R_VAL, stmt->iterator_post_condition);

	break; case STMT_IF:
		do_expression(U_R_VAL, stmt->if_conditional);
		do_statement(U_VOID, stmt->if_true);
		do_statement(U_VOID, stmt->if_false);

	break; case STMT_SWITCH:
		do_expression(U_R_VAL, stmt->switch_expression);
		do_statement(U_VOID, stmt->switch_statement);

	break; case STMT_CASE:
		do_expression(U_R_VAL, stmt->case_expression);
		do_expression(U_R_VAL, stmt->case_to);
		do_statement(U_VOID, stmt->case_statement);

	break; case STMT_GOTO:
		do_expression(U_R_PTR, stmt->goto_expression);

	break; case STMT_LABEL:
		do_statement(mode, stmt->label_statement);

	}

	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movl %edi, %ebp
xorl %r13d, %r13d
leaq 0x6093d(%rip), %rbx     # 0x73460
leaq 0x339e2(%rip), %r15     # 0x4650c
testq %r14, %r14
je 0x12d6c
movl (%r14), %edx
cmpl $0x9, %edx
jne 0x12b4f
testb $0x1, %r13b
jne 0x12b46
movq %rbx, 0x8(%rsp)
movq 0x20(%r14), %r14
movb $0x1, %r13b
jmp 0x12b2a
cmpl $0xd, %edx
ja 0x12d37
movl %edx, %eax
movslq (%r15,%rax,4), %rax
addq %r15, %rax
jmpq *%rax
movq 0x10(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
movq 0x18(%r14), %rsi
xorl %ebp, %ebp
xorl %edi, %edi
callq 0x12b06
jmp 0x12b3b
movq 0x10(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
movq 0x18(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
testb $0x1, %r13b
jne 0x12ba7
movq %rbx, 0x8(%rsp)
movq 0x20(%r14), %r14
jmp 0x12bca
movq 0x10(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
testb $0x1, %r13b
jne 0x12bc6
movq %rbx, 0x8(%rsp)
movq 0x18(%r14), %r14
movb $0x1, %r13b
xorl %ebp, %ebp
jmp 0x12b2a
movq 0x20(%r14), %rdi
callq 0x12062
movq 0x28(%r14), %rsi
xorl %edi, %edi
callq 0x12b06
movq 0x30(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
movq 0x40(%r14), %rsi
xorl %edi, %edi
callq 0x12b06
movq 0x38(%r14), %rsi
xorl %edi, %edi
callq 0x12b06
movq 0x48(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
testb $0x1, %r13b
movq 0x8(%rsp), %rbx
jne 0x12d76
leaq 0x60830(%rip), %rbx     # 0x73460
jmp 0x12d76
movq 0x10(%r14), %rsi
movl %ebp, %edi
callq 0x1235c
movq %rax, %rbx
jmp 0x12d6c
movq 0x18(%r14), %rsi
movl $0x400, %edi            # imm = 0x400
jmp 0x12d67
movq 0x5bf73(%rip), %rax     # 0x6ebd0
movq 0x60(%rax), %rdi
callq 0x12d88
movl $0xfd, %ecx
andl (%rax), %ecx
cmpl $0x4, %ecx
jne 0x12d4b
testb $0x2, 0x69(%rax)
sete %cl
jmp 0x12d4d
movq 0x10(%r14), %rdi
callq 0x12062
jmp 0x12d6c
movq 0x10(%r14), %rsi
movl $0x4, %edi
callq 0x1235c
movq 0x18(%r14), %rsi
movl $0x8, %edi
callq 0x130c3
movq 0x20(%r14), %rsi
movl $0x4, %edi
callq 0x130c3
jmp 0x12d6c
movq 0x10(%r14), %rdi
callq 0x1de8c
movl %eax, %r15d
movq 0x10(%r14), %rax
movq %rax, 0x10(%rsp)
testq %rax, %rax
je 0x12d6c
leaq 0x6077c(%rip), %rbx     # 0x73460
movq 0x10(%rsp), %r14
movzwl (%r14), %eax
testb %al, %al
jle 0x12d2a
xorl %r12d, %r12d
movq 0x18(%r14,%r12,8), %rsi
movzwl %ax, %eax
cmpl $0x100, %eax            # imm = 0x100
jb 0x12d08
testq %rsi, %rsi
je 0x12d1b
decl %r15d
movl $0x0, %edi
cmovel %ebp, %edi
callq 0x12b06
movq %rax, %rbx
incq %r12
movl (%r14), %eax
movsbq %al, %rcx
cmpq %rcx, %r12
jl 0x12cf4
movq 0x10(%r14), %r14
cmpq 0x10(%rsp), %r14
jne 0x12ce9
jmp 0x12d6c
movq 0x4(%r14), %rdi
leaq 0x3383d(%rip), %rsi     # 0x4657f
xorl %eax, %eax
callq 0x133dc
jmp 0x12d6c
xorl %ecx, %ecx
cmpq 0x5523c(%rip), %rax     # 0x67f90
movzbl %cl, %eax
leal 0x4(%rax,%rax), %eax
movl $0x6, %edi
cmovnel %eax, %edi
movq 0x10(%r14), %rsi
callq 0x1235c
testb $0x1, %r13b
cmovneq 0x8(%rsp), %rbx
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq