// File: /workspace/github_c_makefile_star2_O3/AndreIglesias[P]quick_ls/libft/libstd/depo/.././src//c/stdio/ft_printf/aux/print_address.c
// Function: print_address
int	print_address(unsigned long p, t_flags flags, int size, int npre)
{
	int	i;
	int	nb;
	int	z;

	i = (sizeof(p) << 3) - 20;
	size = a_size(i, p, &z);
	nb = write(flags.fd, " ", 1 * (flags.space && size));
	if (!flags.minus && (!(flags.zero && !flags.precision) || !size))
		nb += ft_width(flags, size, npre);
	nb += write(flags.fd, "+", 1 * (flags.plus && size));
	if (size)
		nb += write(flags.fd, "0x", 2);
	if (!flags.minus && (flags.zero && !flags.precision) && size)
		nb += ft_zero(flags, size);
	if (size)
		nb += ft_repet_fd('0', flags.precision - size, flags.fd);
	while (size && i >= 0)
	{
		if (z-- <= 0)
			nb += ft_putchar_fd(hex_digit((p >> i) & 0xf), flags.fd);
		i -= 4;
	}
	if (flags.minus)
		nb += ft_width(flags, size, npre);
	return (nb);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movl %edx, %r12d
movq %rdi, %r14
movl $0x2c, %ecx
xorl %ebx, %ebx
leaq 0xa0(%rsp), %rsi
xorl %ebp, %ebp
xorl %eax, %eax
movq %r14, %rdx
shrq %cl, %rdx
testb $0xf, %dl
je 0x4884
testl %eax, %eax
je 0x4888
testl %ebp, %ebp
cmovel %eax, %ebx
cmovel %eax, %ebp
jmp 0x4894
incl %eax
jmp 0x4894
xorl %eax, %eax
movl $0xffffffff, %ebx       # imm = 0xFFFFFFFF
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
addq $-0x4, %rcx
cmpq $-0x4, %rcx
jne 0x486b
xorl %eax, %eax
testq %r14, %r14
movl $0xc, %ecx
cmovel %eax, %ecx
movl 0x10(%rsi), %eax
movl 0x38(%rsi), %r15d
movq %rax, 0x60(%rsp)
testl %eax, %eax
setne %al
movl %ecx, 0x44(%rsp)
subl %ebp, %ecx
movl %ecx, 0x48(%rsp)
setne %cl
andb %al, %cl
movzbl %cl, %edx
leaq 0x19b4(%rip), %rsi      # 0x6289
movl %r15d, %edi
callq 0x1060
leaq 0xa0(%rsp), %rcx
movq %rax, %r13
movl 0xc(%rcx), %eax
movl %eax, 0x4c(%rsp)
testl %eax, %eax
movl %r12d, 0x5c(%rsp)
jne 0x4943
cmpl $0x0, 0x4(%rcx)
je 0x490a
cmpl $0x0, 0x18(%rcx)
jne 0x490a
cmpl %ebp, 0x44(%rsp)
jne 0x4943
movups (%rcx), %xmm0
movups 0x10(%rcx), %xmm1
movups 0x20(%rcx), %xmm2
movups 0x2c(%rcx), %xmm3
movups %xmm3, 0x2c(%rsp)
movups %xmm2, 0x20(%rsp)
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
movl 0x48(%rsp), %edi
movl %r12d, %esi
callq 0x46f9
leaq 0xa0(%rsp), %rcx
addl %eax, %r13d
movq %r13, 0x50(%rsp)
movl 0x44(%rsp), %r13d
cmpl %ebp, %r13d
setne %al
movl 0x8(%rcx), %ecx
movl %ecx, 0x58(%rsp)
testl %ecx, %ecx
setne %cl
andb %al, %cl
movzbl %cl, %edx
leaq 0x1a1c(%rip), %rsi      # 0x6387
movl %r15d, %edi
callq 0x1060
movq %rax, %r12
addl 0x50(%rsp), %r12d
cmpl %ebp, %r13d
je 0x4997
leaq 0x1ac8(%rip), %rsi      # 0x644f
movl $0x2, %edx
movl %r15d, %edi
callq 0x1060
addl %eax, %r12d
leaq 0xa0(%rsp), %rax
movl 0x18(%rax), %r13d
cmpl $0x0, 0x4c(%rsp)
jne 0x49f1
cmpl $0x0, 0x4(%rax)
je 0x49f1
testl %r13d, %r13d
jne 0x49f1
cmpl %ebp, 0x44(%rsp)
je 0x49f1
movl 0x14(%rax), %eax
xorl %ecx, %ecx
movl 0x48(%rsp), %ebp
testl %ebp, %ebp
cmovgl %ebp, %ecx
movq 0x60(%rsp), %rdx
addl 0x58(%rsp), %edx
addl %ecx, %edx
negl %edx
leal (%rax,%rdx), %esi
addl $-0x2, %esi
movl $0x30, %edi
movl %r15d, %edx
callq 0x4b68
addl %r12d, %eax
movl %eax, %r12d
jmp 0x49fb
cmpl %ebp, 0x44(%rsp)
movl 0x48(%rsp), %ebp
je 0x4a56
subl %ebp, %r13d
movl $0x30, %edi
movl %r13d, %esi
movl %r15d, %edx
callq 0x4b68
addl %r12d, %eax
movl $0x2c, %r13d
movl %eax, %r12d
testl %ebx, %ebx
jg 0x4a4a
movq %r14, %rax
movl %r13d, %ecx
shrq %cl, %rax
andl $0xf, %eax
leal 0x30(%rax), %ecx
leal 0x57(%rax), %edx
cmpl $0xa, %eax
movzbl %cl, %eax
movzbl %dl, %ecx
cmovbl %eax, %ecx
movzbl %cl, %edi
movl %r15d, %esi
callq 0x4ad8
addl %eax, %r12d
addq $-0x4, %r13
decl %ebx
cmpq $-0x4, %r13
jne 0x4a1a
cmpl $0x0, 0x4c(%rsp)
je 0x4a98
leaq 0xa0(%rsp), %rax
movups (%rax), %xmm0
movups 0x10(%rax), %xmm1
movups 0x20(%rax), %xmm2
movups 0x2c(%rax), %xmm3
movups %xmm3, 0x2c(%rsp)
movups %xmm2, 0x20(%rsp)
movups %xmm1, 0x10(%rsp)
movups %xmm0, (%rsp)
movl %ebp, %edi
movl 0x5c(%rsp), %esi
callq 0x46f9
addl %r12d, %eax
movl %eax, %r12d
movl %r12d, %eax
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopw (%rax,%rax)