	.file	"126702342.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"Argument is not a valid decimal number. Enter '-h' for help."
	.align 8
.LC1:
	.string	"Please provide one arg. Enter '-h' for help."
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	DWORD PTR -20[rbp], edi
	mov	QWORD PTR -32[rbp], rsi
	cmp	DWORD PTR -20[rbp], 2
	jne	.L2
	mov	rax, QWORD PTR -32[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	esi, 11624
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	je	.L3
	mov	eax, 0
	call	help
	mov	eax, 0
	jmp	.L4
.L3:
	mov	rax, QWORD PTR -32[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	valid_int
	mov	DWORD PTR -8[rbp], eax
	cmp	DWORD PTR -8[rbp], 0
	je	.L5
	mov	rax, QWORD PTR -32[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	convert
	jmp	.L6
.L5:
	lea	rdi, .LC0[rip]
	call	puts@PLT
	jmp	.L6
.L2:
	lea	rdi, .LC1[rip]
	call	puts@PLT
.L6:
	mov	eax, 0
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC2:
	.string	"Program to convert decimal to binary, and binary to hexadecimal. Enter one argument - a positive decimal number.\nExample: dec2bin 250 | bin2hec "
	.text
	.globl	help
	.type	help, @function
help:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC2[rip]
	call	puts@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	help, .-help
	.section	.rodata
.LC3:
	.string	"%d"
	.text
	.globl	convert
	.type	convert, @function
convert:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r15
	push	r14
	push	r13
	push	r12
	push	rbx
	sub	rsp, 72
	.cfi_offset 15, -24
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	mov	DWORD PTR -100[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -56[rbp], rax
	xor	eax, eax
	mov	rax, rsp
	mov	rbx, rax
	mov	eax, DWORD PTR -100[rbp]
	mov	edi, eax
	call	get_byte
	mov	DWORD PTR -76[rbp], eax
	mov	eax, DWORD PTR -76[rbp]
	movsx	rdx, eax
	sub	rdx, 1
	mov	QWORD PTR -72[rbp], rdx
	movsx	rdx, eax
	mov	r14, rdx
	mov	r15d, 0
	movsx	rdx, eax
	mov	r12, rdx
	mov	r13d, 0
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	eax, 16
	sub	rax, 1
	add	rax, rdx
	mov	esi, 16
	mov	edx, 0
	div	rsi
	imul	rax, rax, 16
	mov	rcx, rax
	and	rcx, -4096
	mov	rdx, rsp
	sub	rdx, rcx
.L9:
	cmp	rsp, rdx
	je	.L10
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	jmp	.L9
.L10:
	mov	rdx, rax
	and	edx, 4095
	sub	rsp, rdx
	mov	rdx, rax
	and	edx, 4095
	test	rdx, rdx
	je	.L11
	and	eax, 4095
	sub	rax, 8
	add	rax, rsp
	or	QWORD PTR [rax], 0
.L11:
	mov	rax, rsp
	add	rax, 3
	shr	rax, 2
	sal	rax, 2
	mov	QWORD PTR -64[rbp], rax
	mov	DWORD PTR -80[rbp], 0
	jmp	.L12
.L13:
	mov	eax, DWORD PTR -80[rbp]
	mov	edx, DWORD PTR -100[rbp]
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	movsx	eax, al
	and	eax, 1
	mov	ecx, eax
	mov	rax, QWORD PTR -64[rbp]
	mov	edx, DWORD PTR -80[rbp]
	movsx	rdx, edx
	mov	DWORD PTR [rax+rdx*4], ecx
	add	DWORD PTR -80[rbp], 1
.L12:
	mov	eax, DWORD PTR -80[rbp]
	cmp	eax, DWORD PTR -76[rbp]
	jl	.L13
	mov	eax, DWORD PTR -76[rbp]
	sub	eax, 1
	mov	DWORD PTR -84[rbp], eax
	jmp	.L14
.L15:
	mov	rax, QWORD PTR -64[rbp]
	mov	edx, DWORD PTR -84[rbp]
	movsx	rdx, edx
	mov	eax, DWORD PTR [rax+rdx*4]
	mov	esi, eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	sub	DWORD PTR -84[rbp], 1
.L14:
	cmp	DWORD PTR -84[rbp], 0
	jns	.L15
	mov	edi, 10
	call	putchar@PLT
	mov	rsp, rbx
	nop
	mov	rax, QWORD PTR -56[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	lea	rsp, -40[rbp]
	pop	rbx
	pop	r12
	pop	r13
	pop	r14
	pop	r15
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	convert, .-convert
	.globl	valid_int
	.type	valid_int, @function
valid_int:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	jmp	.L18
.L21:
	call	__ctype_b_loc@PLT
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -8[rbp]
	movzx	eax, BYTE PTR [rax]
	movsx	rax, al
	add	rax, rax
	add	rax, rdx
	movzx	eax, WORD PTR [rax]
	movzx	eax, ax
	and	eax, 2048
	test	eax, eax
	jne	.L19
	mov	eax, 0
	jmp	.L20
.L19:
	add	QWORD PTR -8[rbp], 1
.L18:
	mov	rax, QWORD PTR -8[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L21
	mov	eax, 1
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	valid_int, .-valid_int
	.globl	get_byte
	.type	get_byte, @function
get_byte:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -4[rbp], 0
	jmp	.L23
.L24:
	sar	DWORD PTR -20[rbp], 8
	add	DWORD PTR -4[rbp], 1
.L23:
	cmp	DWORD PTR -20[rbp], 0
	jne	.L24
	mov	eax, DWORD PTR -4[rbp]
	sal	eax, 3
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	get_byte, .-get_byte
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"126702342.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Argument is not a valid decimal number. Enter '-h' "
	.ascii	"for help.\000"
	.align	2
.LC1:
	.ascii	"Please provide one arg. Enter '-h' for help.\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-16]
	cmp	r3, #2
	bne	.L2
	ldr	r3, [fp, #-20]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L7
	mov	r0, r3
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L3
	bl	help
	mov	r3, #0
	b	.L4
.L3:
	ldr	r3, [fp, #-20]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	valid_int
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L5
	ldr	r3, [fp, #-20]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	str	r0, [fp, #-8]
	ldr	r0, [fp, #-8]
	bl	convert
	b	.L6
.L5:
	ldr	r0, .L7+4
	bl	puts
	b	.L6
.L2:
	ldr	r0, .L7+8
	bl	puts
.L6:
	mov	r3, #0
.L4:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L8:
	.align	2
.L7:
	.word	11624
	.word	.LC0
	.word	.LC1
	.size	main, .-main
	.section	.rodata
	.align	2
.LC2:
	.ascii	"Program to convert decimal to binary, and binary to"
	.ascii	" hexadecimal. Enter one argument - a positive decim"
	.ascii	"al number.\012Example: dec2bin 250 | bin2hec \000"
	.text
	.align	2
	.global	help
	.syntax unified
	.arm
	.fpu softvfp
	.type	help, %function
help:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L10
	bl	puts
	nop
	pop	{fp, pc}
.L11:
	.align	2
.L10:
	.word	.LC2
	.size	help, .-help
	.section	.rodata
	.align	2
.LC3:
	.ascii	"%d\000"
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	convert
	.syntax unified
	.arm
	.fpu softvfp
	.type	convert, %function
convert:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #36
	str	r0, [fp, #-40]
	ldr	r3, .L18
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, sp
	mov	r4, r3
	ldr	r0, [fp, #-40]
	bl	get_byte
	str	r0, [fp, #-28]
	ldr	ip, [fp, #-28]
	sub	r3, ip, #1
	str	r3, [fp, #-24]
	mov	r3, ip
	mov	r0, r3
	mov	r1, #0
	mov	r2, #0
	mov	r3, #0
	lsl	r3, r1, #5
	orr	r3, r3, r0, lsr #27
	lsl	r2, r0, #5
	mov	r3, ip
	mov	r0, r3
	mov	r1, #0
	mov	r2, #0
	mov	r3, #0
	lsl	r3, r1, #5
	orr	r3, r3, r0, lsr #27
	lsl	r2, r0, #5
	mov	r3, ip
	lsl	r3, r3, #2
	add	r3, r3, #7
	lsr	r3, r3, #3
	lsl	r3, r3, #3
	sub	sp, sp, r3
	mov	r3, sp
	add	r3, r3, #3
	lsr	r3, r3, #2
	lsl	r3, r3, #2
	str	r3, [fp, #-20]
	mov	r3, #0
	str	r3, [fp, #-32]
	b	.L13
.L14:
	ldr	r2, [fp, #-40]
	ldr	r3, [fp, #-32]
	asr	r3, r2, r3
	and	r3, r3, #255
	and	r1, r3, #1
	ldr	r3, [fp, #-20]
	ldr	r2, [fp, #-32]
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	str	r3, [fp, #-32]
.L13:
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-28]
	cmp	r2, r3
	blt	.L14
	ldr	r3, [fp, #-28]
	sub	r3, r3, #1
	str	r3, [fp, #-36]
	b	.L15
.L16:
	ldr	r3, [fp, #-20]
	ldr	r2, [fp, #-36]
	ldr	r3, [r3, r2, lsl #2]
	mov	r1, r3
	ldr	r0, .L18+4
	bl	printf
	ldr	r3, [fp, #-36]
	sub	r3, r3, #1
	str	r3, [fp, #-36]
.L15:
	ldr	r3, [fp, #-36]
	cmp	r3, #0
	bge	.L16
	mov	r0, #10
	bl	putchar
	mov	sp, r4
	nop
	ldr	r3, .L18
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L17
	bl	__stack_chk_fail
.L17:
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L19:
	.align	2
.L18:
	.word	.LC4
	.word	.LC3
	.size	convert, .-convert
	.align	2
	.global	valid_int
	.syntax unified
	.arm
	.fpu softvfp
	.type	valid_int, %function
valid_int:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	b	.L21
.L24:
	bl	__ctype_b_loc
	mov	r3, r0
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	ldrb	r3, [r3]	@ zero_extendqisi2
	lsl	r3, r3, #1
	add	r3, r2, r3
	ldrh	r3, [r3]
	and	r3, r3, #2048
	cmp	r3, #0
	bne	.L22
	mov	r3, #0
	b	.L23
.L22:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L21:
	ldr	r3, [fp, #-8]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L24
	mov	r3, #1
.L23:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	valid_int, .-valid_int
	.align	2
	.global	get_byte
	.syntax unified
	.arm
	.fpu softvfp
	.type	get_byte, %function
get_byte:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L26
.L27:
	ldr	r3, [fp, #-16]
	asr	r3, r3, #8
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L26:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L27
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #3
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	get_byte, .-get_byte
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
